Copyright: Copyright (c) 1994, Oracle Corporation.
Citation: Copyright (c) 1994, Oracle Corporation.


Entry Topic
Untitled

ORACLE TERMINAL™ USER'S GUIDE

PREFACE

Purpose

Audience

How To Use This Manual

Conventions Used In This Manual

UNDERSTANDING ORACLE TERMINAL

Resources

Resource Files

ResourceFileTypes

KeyBindings

Connecting Functions with Keys

Logical Attributes

Defining a Style

Character-Mode DeviceAttributes

DeviceClasses

DeviceClassHierarchies

TerminalDefinitions

DefaultDevice

Families ofApplications

Components andFamilies

ComponentNames

Conflicting Bindings

EDITING ORACLE TERMINAL RESOURCES

Before You Start

The Resource Editor

The Product Documentation

The Computer Platform

Selecting

Accelerator Keys

Menu Icons

Switching Windows

Pushbutton Labels

Getting Help

Main Tasks

To Modify a Key Binding

Typing Key Names

Using Macro Mode

To Create or Modify a Product Action

To Create a Logical Attribute

To Delete a Logical Attribute

To Modify a Logical Attribute

Aspects of an Attribute

Changing Attribute Values

Fonts

Patterns

Colors

To Create a Terminal Definition

To Delete a Terminal Definition

To Modify a Terminal Definition

Device Characteristics

Coordinate Styles

Box Characters

Device Attributes

Key Bindings and Encodings

To Set the Default Device

Common Subtasks

To Specify a Device

To Specify a Product

To Choose a Component

To Open a Resource File

To Close a Resource File

To Cancel Your Modifications

To Save Your Modifications

To Generate Compiled Key Bindings

To Quit the Editor

Window Descriptions

Main Window

Key Binding Windows

Key Binding Editor

Key Binding Preview

Key Binding Definition

Product Action Editor

Product Action Definition

Logical Attribute Windows

OT Attributes

Logical Attribute Editor

Edit Attribute Node

Device Definition Windows

Device Class Editor

Device Display Definition

Box Character Definition

X Table Definition

Y Table Definition

Device Attribute Definition

Modifier Key Definition

Standard Key Definition

User Key Definition


This help file created via:

Oracle Book to Microsoft Help Version 1.0s

© 1994 Oracle Corporation Inc.

Authored by KM .


ORACLE TERMINALä USER'S GUIDE
 ORACLE TERMINAL™ USER'S GUIDE

       Oracle Terminal User's Guide

       Part Number A11700-1

       Version 2.0

       August, 1993

      Contributing Author: Charles Dupree  Technical contributors: Xiao-Yu Ding, William Kaufman  Editorial contributors: Doug Asherman, Robert Fish, Ronald Hayden

       Copyright© Oracle Corporation 1993

        All rights reserved.  Printed in the U.S.A.

        This software/documentation contains proprietary information of  Oracle Corporation; it is provided under a license agreement  containing restrictions on use and disclosure and is also protected by  copyright law. Reverse engineering of the software is prohibited. If  this software/documentation is delivered to a U.S. Government  Agency of the Department of Defense, then it is delivered with  Restricted Rights and the following legend is applicable:

RESTRICTED RIGHTS LEGEND

Use, duplication or disclosure by the Government is subject to  restrictions as set forth in subparagraph (c)(1)(ii) of DFARS  252.227-7013, Rights in Technical Data and Computer Software  (October 1988).  	Oracle Corporation, 500 Oracle Parkway, Redwood City, CA  94065.

  If this software/documentation is delivered to a U.S. Government  Agency not within the Department of Defense, then it is delivered  with "Restricted Rights," as defined in FAR 52.227-14, Rights in Data  - General, including Alternate III (June 1987).  The information in this document is subject to change without notice. If  you find any problems in the documentation, please report them to us in  writing. Oracle Corporation does not warrant that this document is  error-free.

Oracle Terminal is a trademark of Oracle Corporation.

Macintosh is a trademark of Apple Computer, Inc.

MS-Windows is a trademark of Microsoft Corporation.

UNIX is a trademark of AT&T Bell Laboratories.

DEC is a trademark of Digital Equipment Corporation.


 PREFACE


 Purpose

  This document describes the Oracle Terminal resource editor, which allows you to configure applications based on Oracle Terminal.  You  can use this editor to:

  •	change the keystrokes that perform application  functions

  •	modify aspects of an application's appearance, such as  fonts and  colors

  •	provide for differences in hardware and firmware  using terminal  definitions and device class information

  You can use this configuration data with a single application or with a  group of related applications.  You can also provide configurations  based on terminal type.  You can only configure applications with the Oracle Terminal resource  editor if the applications were built with Oracle Terminal support.


 Audience

  This document is aimed at those responsible for system configuration and administration, and at sophisticated users who want to configure their systems.  The next section briefly describes the structure of the document, so you can decide where to start.


 How To Use This Manual

  To modify resource data with the Oracle Terminal resource editor, follow the sequence shown in Figure 1:

  1.	Be sure you understand the concepts in Chapter 1: resources and  structures of    resources, key bindings, logical attributes, terminal  definitions and device classes.

  2.	Gather the information that is specific to your application or  computer system, as   described in the section "Before You Start" in  Chapter 2.

  3.	Follow the instructions in Chapter 2 to configure an application  with  the Oracle     Terminal resource editor.

FIGURE 1:  Structure of This Document


 Conventions Used In This Manual

  This document uses the following conventions to highlight special types of information:

  Bold type indicates a new term being introduced.

  SMALL CAPITALS indicate an application function.

  Monospaced text is used in examples.

  "Menu/Item" indicates the choice Item from the menu Menu, as in

  "File/Open" for the Open item of the File menu.


 UNDERSTANDING ORACLE TERMINAL

  This chapter explains essential terms and concepts for users of  applications that employ Oracle Terminal routines.  This information  can help you decide which resource to change and help you locate it in  the application's resource hierarchy.  If you are familiar with these  concepts, see Chapter 2 for instructions on how to configure  applications.


 Resources

  Resources are collections of related data.  An application built with Oracle Terminal support includes resources that describe its behavior and appearance.  For applications like these, Oracle Terminal facilities store and distribute the three types of information shown in Table 1-1.

Table 1-1:

Resource Elements	Type	Purpose  input
mapping	associates key sequences with application functions	a key  bindings
output mapping	describes the user's choices for the "look" of an  application	a logical  attribute structures
device description	specifies the input and output capabilities of a  character-mode terminal	a device classes and terminal definitions

 The Oracle Terminal resource editor has facilities for editing all these  resource types.  See chapter 2, "Editing Oracle Terminal Resources", for  descriptions of the tasks involved.  The rest of this chapter discusses  the resource types in more detail, and describes their structuring into  files and hierarchies.


 Resource Files

  Oracle Terminal resources describe the current "look and feel" of an application or a family of applications.  Application developers can assemble resources into structures such as component families (see "Families of Applications" for details).  Resources and structures of resources are stored in files, from which Oracle Terminal facilities extract the information and make it available to applications.

  You can use resource files to organize configuration information for  different purposes.  Each set of resource files defines an operating  environment; loading a new set into your application, or restarting it  with the new set, changes the look and feel of the application.  For  information on how to load the resource data, see the documentation  for your application.

  If you want to change key bindings, logical attribute values, terminal  definitions, or default devices, you need to know the name of the file  that contains the information.  When you provide this file name to the  Oracle Terminal resource editor, it makes the resource information in  the file available for editing.  See your application's documentation  for such file names.


 ResourceFileTypes

  Character-mode applications built on Oracle Terminal use standard resources that describe a device's physical capabilities.  These resources are stored in the terminal definitions file.

  Applications define their own bindings and attributes.  This  information is stored in one or more application-specific  resource files.  Applications can also load information from  the terminal definitions file, treating it like any other resource file.


 KeyBindings

  In many ways the "feel" of an application is most obvious when you choose a function to perform, whether by typing a command, picking an item from a menu, or selecting something with a mouse.  Many applications expect or allow users to type keys and key sequences to indicate their choices.  For example, on some systems you can initiate a search for a text string by typing Command-F; on others, you initiate the same function by typing CTRL-S.

  Oracle Terminal's key binding facilities make it easy to change the  keys attached to various functions of an application.  This flexibility  also helps you ensure that similar functions are bound to similar keys  so that a consistent feel is maintained throughout a group of  application functions.  You can attach a function to the same key for all  users or provide a variety of methods to suit different groups of users.   However, only the application programmer can change the functions  that are available for binding.


 Connecting Functions with Keys

  A key binding connects a key you type to a function that an application performs.  When you bind a key to a function, the program performs that function when you type that keystroke.  Figure 1-1 shows this relationship between a function called NEXT FIELD and the Tab key on a sample keyboard.

FIGURE 1-1:  A Single Key Binding

  Key bindings allow for different preferences.  For example, two people  who type on similar keyboards might find different keys easy to  remember.  To accommodate them, you could bind the NEXT FIELD  function to the TAB key on one keyboard and the F5 key on the other, as  shown in Figure 1-2.   FIGURE 1-2:  A Function Bound  To Two Keys

  Bindings help to integrate a variety of keyboards and make an  application feel similar on each of them.  Figure 1-3 shows how the  NEXT FIELD function might be bound to the TAB key on two keyboards  whose layouts differ.  You can use this flexibility to make an  application use the same (or similar) keys on all keyboards.

FIGURE 1-3:  A Function Bound to Two Keyboard Layouts

  See "To Modify a Key Binding" in chapter 2, "Editing Oracle Terminal  Resources" for instructions on using the Oracle Terminal resource  editor  to change key bindings.


 Logical Attributes

  The appearance of an application, its "look," arises from many factors.  Among these are familiar attributes of a window such as font and background pattern.  The Oracle Terminal resource editor allows you to configure an application to suit your taste and habits.  (This applies only to applications built with Oracle Terminal facilities.)

  A logical attribute describes the appearance of  one piece of an application, such as a field or a window.  Applications  are free to choose which pieces of themselves you can configure.  For  example, an application may allow you to configure the appearance of  fields into which you type, but not allow you to configure the  appearance of certain titles.  See the documentation for your  application to determine which aspects of it can be configured.


 Defining a Style

  A logical attribute represents one style of rendering material on a device (that is, of displaying or printing it).  The rendering style is defined by the following data:

font	You can specify the font face, size, and style: bold, italic, underlined, and so on.
foreground and background color	You can specify the color used for drawing or printing, as well as the color of the background, in a manner that is specific to your system.
background pattern	You can choose a background pattern from a palette of the patterns available on your system.
character-mode device attribute (CMDEVAT)	You can specify the device characteristic to use if this logical attribute is applied on a character- mode platform.
  When an application runs on a character-mode platform, it uses the  character-mode device attribute and ignores the other information.   On a platform with a bitmapped or block-mode device, the  application uses the font, color, and pattern information and ignores  the character-mode attribute.


 Character-Mode DeviceAttributes

  The character-mode device attribute is usually a name that is defined in a terminal definition, or termdef, resource the application uses.  (See your product documentation to find out how its resource files are structured and where its termdef information resides.)  The termdef resource for each device class associates that name with the escape sequence or other command string that produces the effect.

  For instance, one logical attribute might describe the appearance of  the field that is currently available for editing.  If its character-mode  device attribute is "ReverseBold", then applying this attribute on a  character-mode platform generates something like this:  If you change the device attribute from "ReverseBold" to  "UnderlineBold", then applying the attribute on the same platform  might produce something more like this:  Figure 1-4 shows a window in which the text field uses the logical  attribute's  font, color, and pattern information.  Changing the text  field's attribute values could produce a window like that shown in  Figure 1-5.

FIGURE 1-4:  Logical Attributes

FIGURE 1-5:  Window With New Text Field Attributes


 DeviceClasses

  Applications that run on many types of devices need information about each device's capabilities.  For example, an application might highlight the current field in a form; the appearance of a highlighted field on a VT100-style device could be quite different than on a Macintosh.  Device-class resources provide part of this information by listing the device types on which an application is expected to run.  (The application might run correctly on other device types, but the application's behavior is only defined for those device listed in the device-class resource.)  Oracle Terminal combines this with information in logical attributes to target device characteristics with application functions.


 DeviceClassHierarchies

  Device class resources contain only device names and the hierarchies into which they are organized.  Oracle Terminal combines this information with logical attribute data to determine display characteristics.  Thus you can use device class hierarchies to change the scope to which logical attributes apply.  Applications can simply list terminal types or put them into groups  and hierarchies.  For instance, several terminals from a single  manufacturer might share enough features to be gathered into a single  group.  The features common to all can then be specified once at the  root  of the group, leaving only the differences to be specified separately.    The partial structure in Figure 1-6 illustrates a device class hierarchy  with some terminal types and windowing systems that are frequently  encountered.

FIGURE 1-6:  Device Class Hierarchy


 TerminalDefinitions

  A terminal definition, or termdef, resource contains specific information on the capabilities of a single terminal type.  Termdef resources apply only to character-mode terminals (or emulators).  Termdef resources allow you to describe many aspects of a terminal's  capabilities and behavior, including:

•	the height and width of the screen

•	whether the terminal has graphics capabilities

•	how screen coordinates are described

•	whether attributes (such as color and bolding) persist  on the  screen after the text has been deleted

•	the commands for

•	setting up the terminal and resetting its state

•	clearing the current line or the entire screen

•	moving the up, down, right, left, or to the end of  the line

•	creating a scrolling region

•	scrolling up or down

•	drawing boxes on the screen

•	names and encodings for device attributes such as bold  and  underline (and combinations such as ReverseBold and  UnderlineBold)

•	names and encodings for modifier keys (such as  Control or Shift),  standard keys (Return, Tab), and user-definable keys (Print,  Remove, Help)


 DefaultDevice

  Some applications provide default interface settings that are appropriate for a default terminal device.  Oracle Terminal allows you to set this default device.  For example, you can tell an application that the default device type  for your installation is a VT100-style device.  From then on, the  application assumes that it is running on a VT100-style terminal unless  that information is overridden at run time, or until the default device  type is changed.  By default, the application uses the information on  device characteristics and key codes that is appropriate for VT100  devices.       For instructions on how to set the default device, see "To Set the Default Device" in  chapter 2, "Editing Oracle Terminal Resources".


 Families ofApplications

  Resources are organized into hierarchies for ease of sharing among applications.  You can make use of the hierarchy to assign key bindings for groups of components in a single declaration; for example, you can assign the TAB key to NEXT FIELD for several components at once by modifying their common parent in the hierarchy.  You can also provide for exceptions for certain groups of users or certain applications.  This section describes some of the hierarchies into which Oracle Terminal resources can be constructed.


 Components andFamilies

  A set of applications built with Oracle Terminal support can be called a family.  Each operation performed by a member of this family is called a component.

  A component represents exactly one operation from the user's point of  view; the designers of an application designate the components that  you can configure.  Thus, operations like "Open" and "Save" could each  be components, or they could both be part of a component called, say,  "File Operations", depending on the application.

  Given these definitions, the set of functions performed by the entire  family of applications is called a component  family.


 ComponentNames

  The "name" of a component consists of the name of the component family, the names of any groups that contain the component, and the component name itself, separated by periods:

family.group1.group2.component

  As an example, take some applications that help users enter data by  providing forms on a terminal screen.  Call this family of applications  macintosh-sqlforms, and its subgroups runform and design.  Then  the names of the groups are

macintosh-sqlforms.runform

macintosh-sqlforms.design

  Suppose the group  macintosh-sqlforms.runform  contains a component called help.  The  component's full name is then  macintosh-sqlforms.runform.help.  Figure 1-7  shows a graphic representation of this component.  Each circle represents a node in the hierarchy.  The topmost level of  the hierarchy is the family, on the left side of this figure.

FIGURE 1-7:  A Family of Components

  Each node in the hierarchy is associated with a set of resources.  By  choosing the appropriate node to modify, you can configure certain  aspects of the entire family of components or of a group of components.   For instance, you might assign the F1 key to HELP for every function by  changing a key binding for the component-family macintosh-sqlforms.  This binding then applies to all  components in the family, except for those that specifically override  the binding.


 Conflicting Bindings

  You can override family or group settings for individual components.   In fact, a component's key bindings and logical attribute values are  those of the family, plus those of any group that contains the component, plus those specific to the component itself.  If there are conflicts, such as a key that is bound to different functions at the family and component levels, the more specific binding or value takes precedence.  Thus, the values you set for  macintosh-sqlforms.runform.help override any conflicting settings for macintosh-sqlforms or  macintosh-sqlforms.runform.


 EDITING ORACLE TERMINAL RESOURCES

  This chapter tells you how to use the Oracle Terminal resource editor to  modify key bindings, logical attributes, and terminal definitions.  It  assumes that you understand the following concepts, discussed in  Chapter 1:

•	key bindings

•	logical attributes

•	terminal definitions

•	resources and resource files

•	components and component families.

  If these concepts are unfamiliar, see the explanations in Chapter 1  before continuing.  This chapter describes the tasks involved in a step-by-step fashion.   Some steps are used in two or more tasks; for instance, you open a  resource file the same way whether you plan to modify a key binding  or a terminal definition.  Such steps are described in detail in the  "Common Subtasks" section of this chapter, and reference is made to  that description where appropriate. The Oracle Terminal resource editor has uses beyond those described  in this document.  Developers of Toolkit-based applications should  consult the appropriate documentation for assistance with the Oracle  Terminal application programming interface (API) and other aspects of  Oracle Terminal that relate to the creation of new products.  This  chapter discusses only the configuration of existing products built with  Oracle Terminal support.


 Before You Start

  The instructions in this document assume certain things about your  knowledge of the computer  system on which you want to configure an application, and about the  tools and data available to  you.


 The Resource Editor

  You must know how to access and run the Oracle Terminal resource  editor ot.

  The editor works on many hardware and software platforms  employing a variety of  methods to start programs.  Use the methods  appropriate to your system to start ot: for  instance, you might type in a command on one system, double-click an  icon on a second system, and type a function key on a third.  For  information specific to your system, see theInstallation  and User's Guide for the package that included Oracle  Terminal.

  The Oracle Terminal resource editor is usually configured during  installation to use appropriate key bindings for your terminal.  If not,  or if it cannot find the resource file it needs, it uses a minimal default  configuration.  On character-mode terminals, you can get a list of the  key bindings Oracle Terminal is currently using by selecting  "Help/Show Keys" in the main window.


 The Product Documentation

  You must know what resource you want to configure and what value  you want it to have.

  Therefore you should consult the product documentation to determine  exactly what aspects of its behavior and appearance are represented in  Oracle Terminal resources.

  This chapter cannot tell you which resource you should change to  produce the desired effect on your application, nor can it describe the  possible values for every resource used by Oracle Terminal-based  applications; it supplements the documentation for the product you  want to configure.  Applications can define their own resources and  specify the legitimate values for them.  Such information is therefore  specific to your application and the computer platform on which it  runs.  Consult the documentation on the application itself to determine  what data to change and what new values to supply.

  For example, this chapter tells you how to modify the values of key  bindings.  To determine which functions of the product you can  rebind, and which keys you can use instead of the normal ones, see  your product documentation.


 The Computer Platform

  You must be able to perform the following operations on the computer  in question:

  •	move among and enter text into the fields  provided for that purpose (for example, by selecting a field with  a mouse or by typing the Tab key until the field is focused)

  •	choose items from menus, whether with a mouse or  with keys

  •	select an object on your screen


 Selecting

  The rest of this document uses the word select to  indicate that you should use  whatever method is appropriate to your system to choose the object or  menu item.  When  instructions tell you to select an item from a menu, you can use the   menu directly, or you can use  accelerator keys or icons that perform the same functions.  (Only the  four major functions have  icons attached to them.)

  On a mouse-based system, for example, you can select an object or  item by pointing the mouse cursor at the object and clicking the mouse  button.  In most cases, double-clicking the mouse button produces the  same effect as selecting the object and accepting it with "OK" or "Edit"  or the equivalent.

  On a character-mode terminal, on the other hand, you might access  menus with the Keypad-0 key, move to a different field with the Tab  key, select a choice by typing SPACE or RETURN, and cancel a menu  with Keypad-*.  You can get a list of the key bindings on your  character-mode terminals; for instructions see the "Getting Help"  section in this chapter.


 Accelerator Keys

  On most platforms, each menu item is associated with an accelerator  key, so you can select a menu  item with a keystroke or two.  If a menu item has an accelerator, it is  shown on the menu next to  the item's name.  For example, you can choose "File/Open", or you can  type the accelerator, which  is often either Escape-O or Control-O; either method selects the menu  item.  Any time instructions  tell you to select an item from the menu, you can type the accelerator  key with the same effect.


 Menu Icons

  Depending on the platform, the main window (which you see when you  start the editor) includes  four icons or four pushbuttons that are equivalent to the items under the  "Functions" menu.  Any  time instructions tell you to select an item from the "Functions" menu,  you can select the associated  icon with the same effect.

Pushbutton	Icon	"Functions/"  Menu  Item
Input	Keycap	Edit keys
Output	Artist's palette	Edit attributes
Device	Terminal	Edit device
Generate	Grinder	Generate

The exact icon images you see depend on the platform.  Figure 2-1  shows an example.

FIGURE 2-1:  Main Window Icons


 Switching Windows

  The Oracle Terminal resource editor generates "windows" in which you  perform various  operations; this is true even on character-mode teriminals.  Depending  on the platform on which  you work, you can switch windows in various ways, such as selecting a  window with a mouse or  typing a function key to rotate windows.  The resource editor also  provides a "Windows" menu  from which you can select the name of the window you want to  activate.  This menu is available on  all platforms, but is otherwise equivalent to the platform-specific  methods of switching windows.


 Pushbutton Labels

  The Oracle Terminal resource editor uses two kinds of pushbutton,  distinguished by the presence  or absence of ellipses (...) at the end of the label.   Pushbuttons that end with ellipses lead to the next stage in the  task, producing a new window in which you make choices or enter  information.  Pushbuttons that do not end with ellipses perform  an action when you select them.


 Getting Help

  Most windows you encounter while running the resource editor have a  "Help" pushbutton, which  you can select to get a brief description of the current window and its  contents.

  There are a few  exceptions:

•	the main window has a "Help" menu  rather than a  pushbutton

•	some dialog windows, such as those for opening files  or choosing  colors, are the platform's native windows, and are not connected  to the Oracle Terminal help system (though you may be able to  get help from another source if your platform provides it)

•	two windows were simple enough to need no help,  one for  choosing a pattern and the other presented when you select  "Help/About" to see version numbers and other background  information

  Many platforms also have a "Help" key, such as F1 for Microsoft  Windows or the "Help" key on some character-mode platforms.  On  character-mode platforms, you can select "Help/Show Keys" to  determine the bindings of "Help" and other commands.


 Main Tasks

  This section describes the steps involved in performing the task that  brought you to theOracle Terminal User's  Guide.   For example, your goal might be to modify a key binding, create a  new terminal definition, or set the default device; this section contains  instructions for such tasks.

  "Common Subtasks" in this chapter provides details on opening and  closing files, quitting the resource editor, and so on.


 To Modify a Key Binding

  Before you begin this task, you should know:

•	the resource file that contains the binding

•	the product, and the product component whose  binding you  want to chang

•	the key you want to bind to that component and the  device type  on which the key appears

  Consult your product documentation for this information.

  Step 1.	Open the resource file and specify the  device and product.

  These common tasks are described in:

  •	"To Open a Resource File"

  •	"To Specify a Device"

  •	"To Specify a Product"

  You can specify the device and the product in either order.

  Step 2.	Select "Functions/Edit  Keys".

  On a bitmapped platform, the editor presents a window with a  graphical representation of the components in the product you  specified.  On a character-mode platform, it also displays a list of  ancestors (components that contain the current component) and a list of  the components at the current level.

  Step 3.	Select the component for which the  binding  applies

  See "To Choose a Component" for details on this common task.  For information on the pushbutton labeled "Product Actions", see "To  Create or Modify a Product Action" in this chapter.

  Step 4. 	Select "Edit Key  Bindings".

  The editor presents a table of the component's actions and the keys to  which they are bound.  Figure 2-2 shows examples of this table.

FIGURE 2-2:  Key Binding Table

  Step 5.	Enter the new binding in the  table.

  Select the appropriate cell in the table and enter the key sequence. The "Typing Key Names" and "Using Macro Mode" sections of this task tell you about the two ways to enter key sequences.

  You can also add new actions and their associated bindings, especially when updating new versions of software tools. (The names of all actions are defined by the applications, though; you cannot create a  new function by naming it and binding it.) To do so, select Insert Row  and enter the name and binding in the new row.


(optional)  Step 6.	Examine  the effect of your modification.

  If you want to determine whether the binding you entered makes  sense on your current platform, select "OK" when you finish editing  bindings.  Then select "Preview Key Bindings".

  The editor runs the same syntax check that the Generate function uses  to compile bindings.  If the file contains errors, the editor reports them;  you must fix them before using the resource file with the application.

  The list that results from "Preview Key Bindings" also includes all the  applicable key bindings for the specified node, including those that are  defined at more general (higher-level) nodes.  Figure 2-3 shows  examples.

FIGURE 2-3:  Key Binding Preview

  Keep in mind that this syntax check applies only to the platform on  which you are running Oracle Terminal.  If you plan to use the  bindings on a different platform, you must check the syntax there.  For  example, you can edit key bindings for a character-mode terminal on a  Macintosh; but you can only determine whether your bindings are  correct by checking them on the character-mode terminal

  Step 7.	Save your  modifications.

If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications".

  Step 8.	Generate a compiled version of the  new bindings.

  See "To Generate Compiled Key Bindings" in this chapter for details.


 Typing Key Names

  You can indicate a key by typing out its full name, such as entering the  nine characters in the  string "Backspace".  This method has the virtue of flexibility, since it lets  you enter the names of  keys that may not exist on the keyboard in front of you.

  To show that two keys are to be pressed in sequence, enter their names  one after the other, separated by a space, as in "F1 x".  To indicate that  two keys are to be pressed at once, as with the Control or Shift keys on  many keyboards, put a plus sign (+) between their names:  "Control+x".  Figure 2-2 illustrates both cases.

  On character-mode terminals, you can use any key name that is  defined as a Modifier, Standard Key or User Key in the terminal  definition (termdef) for the device class.

  On bitmapped platforms, you can use any key name that is defined by  the platform.


 Using Macro Mode

  You can also indicate a key by entering macro mode and typing the key  rather than typing its name.  This produces the same text string as if you had typed it, but this  method is simpler  because you can use a key without being certain of its proper name.  If  the sequence is long, macro  mode can help reduce typing and mistakes.

  The names of physical keys are not standardized; devices by different  manufacturers can vary widely.  Therefore you should use macro  mode on a device of the type you want to configure to avoid problems  caused by conflicting key names.

  To enter a key name in macro mode from the Key Binding Definition  window:

   Step 1.	Select "Table/Macro Mode" (or the  "Macro Mode"  pushbutton).

  This produces a window like the examples in Figure 2-4.

FIGURE 2-4:  Macro Mode

  Step 2.	Choose a delimiter  character.

  Type a character that is not used in the key name.  When you finish  typing the key name, you will use this character to indicate that you  are done.  Once you type the delimiter character, the window shows you the key  sequence that erases the current string, as shown in Figure 2-5.

FIGURE 2-5:  Leaving Macro Mode

  Step 3.	Type the key sequence to which you  are binding the  action.

  If you make a mistake, use the "erase" key named in the window, and  re-enter the key

 sequence.

  Step 4.	Type the delimiter character you  specified in Step  2.

You have now entered the new binding, and can continue with Step 6  of the main task.


 To Create or Modify a Product Action

  Before you begin this task, you should know:

  •	the resource file that contains the product  action, or  that should contain it

  •	the component and the device (or windowing system)  to which  the action applies

  •	the product's name and code for the action you plan to  create or  modify

  Consult your product documentation for this information.

  Step 1.	Open the resource file and specify the  device and product.

  These common tasks are described in:

  •	"To Open a Resource File"

  •	"To Specify a Terminal Device"

  •	"To Specify a Product"

  You can specify the terminal device and the product in either order.

  Step 2.	Select "Functions/Edit  Keys".

  On a bitmapped platform, the editor presents a window with a  graphical representation

of the components in the product you  specified.  On a character-mode platform, it also

displays a list of  ancestors (components that contain the current component) and a list

of  the components at the current level.

  Step 3.	Select "Product  Actions...".

  This produces a similar window with different pushbuttons.

  Step 4.	Select the component to which the  action  applies.

  See "To Choose a Component" for details on this common task

  Step 5.	Select "Edit Actions...".

  The editor presents a table of the component's actions, codes, and  descriptions.  Some examples are shown in Figure 2-6.

FIGURE 2-6:  Product Actions

  Step 6.	Enter the new action in the table, or  edit an existing  one.

  Select the appropriate cell in the table and enter the name of the action,  its product code, and a description or comment.  The action name  appears in key binding tables once you save the file and generate new  bindings.  You can use the pushbuttons to duplicate an existing row, insert a new  row above the selected one, or delete the selected one.  To erase all your changes and return to the previous window, select  "Cancel".

  Step 7.	Select "OK" to accept your  changes.

  To return directly to the main window, select "OK" two more times.  To modify the

product actions of another component, return to Step 4.

  Step 8.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.


 To Create a Logical Attribute

  Before you begin this task, you should know:

•	the resource file and attribute list that  should  contain the new logical attribute

•	the device to which the attribute applies

•	the logical attribute you want to create

•	the logical attribute you want to duplicate, if you plan  to copy an  existing one

  Consult your product documentation for this information.

  Step 1.	Open the resource file and specify the  device and product.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device

•	"To Specify a Product"

  You can specify the terminal device and the product in either order.

  Step 2.	Select "Functions/Edit  Attributes".

  The editor presents the names of the logical attributes in the current  attribute list, as in the examples of Figure 2-7.  You can choose a  different attribute list from the same file from the  popup list labeled  "Attribute List".

FIGURE 2-7:  Logical Attributes

  Step 3.	Select the appropriate logical  attribute list from the popup  list.

  Step 4.	Enter the name of the new logical  attribute in "Attribute  Name".

  This activates the "Add" and "Duplicate" buttons.

  Step 5.	To create a new logical attribute,  select "Add". To copy an existing logical attribute, select the one you want to copy,  then select "Duplicate".

  At this point you can edit the settings for the new logical attribute with  "Edit..."; see "To Modify a Logical Attribute" in this  chapter for details

  Step 6.	Select "OK" to accept your  changes.

  Step 7.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.

  Notes

If an existing logical attribute is similar to the one you are creating, you  can save some time by  duplicating the similar attribute and modifying only the aspects that  differ.


 To Delete a Logical Attribute

   Before you begin this task, you should know:

•	the resource file and attribute list that  contain the  logical

•	the logical attribute you want to delete

  Consult your product documentation for this information.

  Step 1.	Open the resource file and specify the  device and product.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device"

•	"To Specify a Product"

  You can specify the terminal device and the product in either order.

  Step 2.	Select "Functions/Edit  Attributes".

  The editor presents the names of the logical attributes in the current  attribute list, as in the examples of Figure 2-8.  You can select other  attribute lists in the same file with the "Attribute List" popup list.

FIGURE 2-8:  Logical Attributes

  Step 3.	Select the appropriate logical  attribute list from the popup  list.

  Step 4.	Choose the logical attribute you  want to delete, and select  "Delete".

  Step 5.	Select "OK" to accept your  changes.

  Step 6.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.


 To Modify a Logical Attribute

  Before you begin this task, you should know:

•	the resource file that contains the logical  attribute

•	the logical attribute whose value you want to change  and the  component that contains it

•	the device type to which the attribute value applies

•	the new value for the attribute

  Consult your product documentation for this information.

  Step 1.	Open the resource file and specify the  device and product.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device"

•	"To Specify a Product"

  You can specify the terminal device and the product in either order.

  Step 2.	Select "Functions/Edit  Attributes".

  The editor presents the names of the logical attributes and logical  attribute lists in the product you specified.  Figure 2-9 shows some  examples.

FIGURE 2-9:  Logical Attributes

  Step 3. 	Select the appropriate  logical attribute list from the popup list.

  Step 4.	Select the attribute you want to  change, then select "Edit".

  The editor presents a window with a graphical representation of the  devices in the product you specified.  It also shows a list of ancestor  devices (groups that contain the current device) and a list of the devices  at the current level.

Step 5.	Select the device to which the  attribute applies, then select  "Edit Attributes".

  You choose a device like you choose a component; see "To Choose a  Component" in this chapter for details.  The editor presents a form for editing attributes; Figure 2-10 shows  examples.

Step 6. 	Provide the new  values.

  The editor presents a form showing the information you can attach to a  logical attribute; Figure 2-10 shows some typical examples.  Provide  values for the aspects that are important and leave the rest as they first  appear on the form (some attributes have default values, while others  are blank).  "Changing Attribute Values" in this task tells you how to  modify the various pieces of data.  The "Aspects of an Attribute" section in this task describes the aspects  of a logical attribute that you can change.  See your product  documentation for the values that are appropriate for your system and  product.

FIGURE 2-10:  Editing Logical Attributes

Step 7.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications".


 Aspects of an Attribute

  Table 2-1 lists the aspects of a logical attribute that you can change with  the Oracle Terminal  resource editor, and briefly describes each aspect.  The character-mode  device attribute is the only  aspect supported for character-mode devices.

  As with other Oracle Terminal resource data, consult your product  documentation to determine precisely how your product interprets this  data.

TABLE 2-1:  Aspects of a Logical Attribute

Name	Definition
Character Mode Device Attribute	Name of the device  attribute to be used when representing the logical attribute on a  character- mode terminal device; this name is associated with a command  sequence in the terminal  definition's "Attributes" table (see "To Modify a Terminal Definition" in  this chapter for details)
Pattern	Pattern to use in the  background; selecting this aspect causes the editor to present a palette  from  which you can choose a pattern (see Figure 2-11 for an example)
Foreground, Background	Colors of the area to which the  attribute applies; selecting one causes the editor to present a color  dialog with which you can edit the color (see Figure2-12)
Face	Name of the font face,  such as "times", "palatino" or "helvetica"
Size	Size of the font in  hundreths of a point
Style	Font style, such as "italic"  or "shadow
Weight	Font weight, such  as "light" or "bold"
Width	Font width, such as  "dense" or "expand
Image	Indicates whether  the rectangle behind the text should be drawn in the background color
Kerning	Allows or  disallows adjustments to interword spacing
Nearest	Allows or disallows attempts to  approximate font size, style, weight and width by substituting a similar  font if the requested font is not available
Can Synthesize	Allows  or disallows attempts to scale, embolden, or  otherwise modify the font  algorithmically if the  requested  font is not available


 Changing Attribute Values

  To change the value of an aspect of the attribute, select the aspect on  the form and supply its new  value.  For example, choose a style from the popup list; change the  character-mode device attribute   by typing the new value into the field.


Fonts
 Fonts  When you modify font information, such as style or weight, on  bitmapped platforms, you can  select "Apply Font" to see the effect of your changes on the sample text  ("Font").   To set the aspects called Image, Kerning, Nearest, and Can Synthesize,  select the left-most of the two checkboxes beside the name.  This  indicates that you want to set the value, and makes the right checkbox  available.

  To set the value of the aspect, select the right checkbox for TRUE and  leave it unselected for FALSE.  For example, you can ensure that no  kerning takes place by selecting the left checkbox next to Kerning and  leaving the right one unselected; you can allow applications to  substitute a similar font by selecting both checkboxes next to Nearest.

  To get the platform's default value for that aspect, leave both  checkboxes unselected.


Patterns
 Patterns  On platforms that support it, you can select Pattern to choose from a  palette of patterns; an example  is shown in Figure 2-11:

FIGURE 2-11:  Patterns


Colors
Colors On platforms that support it, you can select Foreground or Background  to edit the colors.  The  manner in which you specify color is system-dependent and varies  considerably; one example is  shown in Figure 2-12.

FIGURE 2-12:  Color Dialog


 To Create a Terminal Definition

   Before you begin this task, you should know:

•	the resource file that should contain the  new  terminal definition (or termdef)

•	the device name you want to add

•	the device you want to duplicate, if you plan to copy an  existing  one

  Consult your device and product documentation for this information.

  Step 1.	Open the resource file and specify the  device.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device"

  Step 2.	Select "Functions/Edit  Device".

  On a bitmapped platform, the editor presents a window with a  graphical representation of the devices in the product you specified.   On a character-mode platform, it also displays a list of ancestors  (groups that contain the current device) and a list of the devices at the  current level.  Figure 2-13 shows some examples.

FIGURE 2-13:  New Devices

  Step 3.	Enter the name of the new device in  "Device Class  Name".

  This activates the "Add" and "Duplicate" buttons.

  Step 4.	To create a new device, select its  parent node, then select  "Add".  To copy an existing device, select the one you want to copy,  then select Duplicate".

  At this point you can edit the settings for the new device with "Edit  Device..."; see "To Modify a Terminal Definition" in this  chapter for  details.

  Step 5.	Select "OK" to accept your  changes.

  Step 6.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.

  Notes

  If the new device is similar to an existing one, you can duplicate it and  change those aspects that  differ rather than entering all the data by hand.


 To Delete a Terminal Definition

    Before you begin this task, you should know:

•	the resource file that should contain the  new  terminal definition (or termdef)

•	the device name you want to add

•	the device you want to duplicate, if you plan to copy an  existing  one

  Consult your device and product documentation for this information.

  Step 1.	Open the resource file and specify the  device.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device"

  Step 2.	Select "Functions/Edit  Device".

  On a bitmapped platform, the editor presents a window with a  graphical representation of the devices in the product you specified.   On a character-mode platform, it also displays a list of ancestors  (groups that contain the current device) and a list of the devices at the  current level.  Figure 2-14 shows some examples.

FIGURE 2-14:  Devices

  Step 3.	Choose the node you want to delete,  and select "Delete".

  Step 4.	Select "OK" to accept your  changes.

  Step 5.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.


 To Modify a Terminal Definition

   Before you begin this task, you should know:

•	the resource file that contains the terminal  definition (or termdef)

•	the device whose definition you want to modify

•	the new values for the device characteristics or key  encodings

  Consult your device and product documentation for this information.

  Step 1.	Open the resource file and specify the  device.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device"

  Step 2.	Select "Functions/Edit  Device".

  On a bitmapped platform, the editor presents a window with a  graphical representation of the devices in the product you specified.   On a character-mode platform, it also displays a list of ancestors  (groups that contain the current device) and a list of the devices at the  current level.

  Step 3.	Specify the device you want to  modify, and select "Edit  Device".

  See "To Choose a Component" in this chapter for details on this  common task.

  Step 4. 	Supply the new values.

  The editor presents a form showing device characteristics whose values  can be used by Oracle Terminal-based applications.  To supply a new  value for a device characteristic, select the text field next to its name  and type in the appropriate value.  Figure 2-15 shows some typical  examples of this form.  See "Device Characteristics" in this task for a  description of the contents of this form.

  You can modify encodings for keys and device attributes by selecting  the pushbuttons "Attributes", "Modifiers", "Standard Keys", and "User  Keys"; see "Device Attributes" and "Key Bindings and Encodings" in  this task for details.

  FIGURE 2-15:  Editing a Termdef Resource

  Step 5.	Save your  modifications.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.


Device Characteristics

  Applications built using Oracle Terminal can define their own device  characteristics and decide  how to interpret their values.  Oracle Terminal provides some basic  characteristics by default,  which are therefore often used as defaults by applications built with it.   Table 2-2 lists these default characteristics.

TABLE 2-2:  Device Characteristics

Name	Definition
Screen width	Width of the  screen in characters
Screen height	Height of the  screen in lines
Terminal setup	Character sequence for setting up the terminal
Terminal reset	Character  sequence for resetting the terminal
Clear screen	Character  sequence for clearing the screen
Clear to end of line	Character sequence for clearing the line from the current cursor  position to the end of the current  line
Goto XY	Character sequence for  moving the cursor to a specific X,Y position; use x and y to indicate  the placement of the two coordinates, as in "e[y;xH"
Create scroll region	Character sequence for creating a scrolling region from a subset  of the available lines; must be  blank if the device does not support hardware scrolling; use t and b to  indicate the placement of the top and bottom lines, as in "e[t;br"
Cursor left, right, up, down	Character sequences for moving the cursor  one position in the specified direction
Scroll up, down	Character sequences for scrolling the scrolling region one line in  the specified direction; must be  blank if the device does not support hardware scrolling
Graphics device	Indicates whether the device has graphics capability
Graphics on, off	Character sequences for telling the  device whether to interpret input as graphics data
Coordinate base	Base  number from which coordinates are calculated, usually 0 or 1
Coordinate style	Indicates how coordinate values should be encoded for the device:   -  "Single char" for devices that accept an ASCII character and use  its value, such as "A" for the  value 65   "String" for devices that accept a string and convert it to a  number, such as "65" for the value 65   -  "Table" for devices with more complex methods of encoding,  represented in a table of coordinate values and command sequences  (see Figure 2-16 for an example)  X Table, Y Table Tables whose entries translate coordinates into  command sequences; used if you selected "table"  coordinate style (see Figure 2-16)
Attribute persistence	Indicates whether the attribute persists on the screen after its  contents are gone (devices differ as to  whether or not attributes must be explicitly cleared; this aspect is  particularly important for users of  Wyse, Hewlett-Packard, and similar terminals)
Box characters	Characters for drawing boxes on a screen or a printer (see Figure  2-17)


Colors
Coordinate Styles  Some devices use schemes for encoding coordinate values that are more  complex than the simple  ones designated "single char" and "string".  For such devices, you can  provide a table of values to  indicate what command sequence the application should send for each  coordinate value.

  If you choose "table" as the coordinate style, the "X Table" and "Y  Table" choices become available.  Selecting one of these causes the  editor to present a table in which you can enter coordinate values and  command sequences.  Figure 2-16 shows examples of the table for an X  coordinate.  To change a value, select the cell that contains it, and enter  the new value.  Select "OK" to accept your changes, "Cancel" to forget  them.

FIGURE 2-16:  X-coordinate Values


Colors
Box Characters  Devices with various levels of graphics capabilities use a variety of  encoding methods for box- drawing commands.  The box-characters table allows you to specify the  command sequence that  draws each part of a box for a screen or a printer.

  When you select "Box Characters" the editor presents you with a table  of box characteristics and the commands that draw them on screens and  printers.  To specify the command your device uses, select the field in  the "Screen" column beside the characteristic's name, and enter the  command sequence.   Select "OK" to accept your changes, "Cancel" to  forget them.  Figure 2-17 shows a sample table of box characters:

FIGURE 2-17:  Box Characters


Device Attributes

  When you select the "Attributes" pushbutton, the editor presents the  Device Attribute table with  the names and encodings for character-mode device attributes; Figure  2-18 shows examples.  You  can add a new name and supply the appropriate encoding for it, but you  should be careful about  modifying or deleting existing attribute names because other  applications may expect the names to  be defined (you can change the encodings as you please).

  Once you define an attribute by supplying its name and its encoding,  you can use the attribute name as the character-mode device aspect of  logical attributes.  For example, most resource files define such  attributes as Bold, Underline, and Blinking.  If your device has some  additional feature you want to use, you can add a new row to the  Device Attributes table (row order is not important), and specify a  name and encoding for the feature.  Then you can edit a logical  attribute and supply your newly-created name as the Character-Mode  Device Attribute.

FIGURE 2-18:  Device Attributes


 Key Bindings and Encodings

  The keys on a terminal keyboard fall into three classes: modifiers,  standard keys, and user keys.   This section describes the classes.

  When you edit a terminal definition, you can:

•	bind modifier keys

•	specify encodings for standard keys

•	specify encodings for user-definable keys

  For example, when you modify a key binding, you must supply the  names of the keys you want to use, as in "Control+Tab".  You can bind  "Control" to a key with "Modifiers", and specify your device's encoding  of "Tab" with "Standard Keys".  (The plus sign in "Control+Tab" is part  of the key binding syntax; see "To Modify a Key Binding" in this  chapter. You can supply bindings for modifier keys such as Control, Alt,  Escape, and Shift with "Modifiers"; see Figure 2-19 for an example of  the table in which you edit bindings.  Take care when changing the  names of these keys; other applications may require that the names be  defined

FIGURE 2-19:  Modifier Keys

  You can supply encodings for standard keys and user keys to show  what escape sequence or other character string your terminal uses to  indicate that these keys have been pressed.  Take care when changing  the names of these keys; other applications may require that the names  be defined.  You can specify encodings for:

•	standard keys such as Return, Tab, and  Space with  "Standard Keys";

 see Figure 2-20

FIGURE 2-20:  Standard Keys

•	user-definable keys such as keypad and function keys  with"User  Keys"; see Figure 2-21

FIGURE 2-21:  User Keys


 To Set the Default Device

   Before you begin this task, you should know:

•	the resource file whose default device you  want to  set

•	the name of the proposed default device (which must  refer to a  device whose termdef information is known to Oracle Terminal)

  Consult your device or product documentation if necessary.

  Step 1.	Open the resource file and specify the  device.

  These common tasks are described in:

•	"To Open a Resource File"

•	"To Specify a Terminal Device"

Step 2.	Select "Functions/Edit  Device".

  The editor presents a window with a graphical representation of the  devices in the product you specified.  It also shows a list of ancestor  devices (groups that contain the current device) and a list of the devices  at the current level.  Figure 2-22 shows some examples.

FIGURE 2-22:  Devices

  Near the bottom of the window Ia popup list called "Select Default  Device".

  Step 3.	Select the default device type you  want from the popup  list.

  If your current platform uses a windowing system, its name will also  be in the list.  selecting it as the default device indicates that you  expect most users of this resource file will use that windowing system  (regardless of the hardware running it).  Selecting a device name  indicates that you expect most users of this file will use character-mode  terminals of the specified type

 Step 4.	Save your  modification.

  If you have finished changing the resource data in this file, save the  data as described in "To Save Your Modifications" in this chapter.


 Common Subtasks

  This section describes the steps involved in performing a number of  subsidiary tasks, each of which is used by two or more main tasks.  For  example, every main task requires you to open a resource file, and  you eventually finish editing and want to quit; this section contains  instructions for such tasks.

  Main Tasks" in this chapter focuses on higher-level tasks such as  modifying key bindings and creating terminal definitions.


 To Specify a Device

  Step 1.	Open the resource  file.

See "To Open a Resource File" in this chapter for details

Figure 2-23 shows some samples of the editor's main window.

FIGURE 2-23:  Main Window

..

  Step 2.	Select the appropriate device (or  platform) from the Device  popup list.

  The editor presents the list of the device types described in the current  resource file.  The list may also include the windowing system running on your  platform (such as Motif or Windows), if any.  Select the device or  windowing system for which you want to modify bindings, encodings,  and attributes.  Usually this means the platform on which you are  editing the resource.


 To Specify a Product

  Step 1.	Open the resource  file.

  See "To Open a Resource File" in this chapter for details.

Figure 2-23 shows some samples of the editor's main window.

  Step 2.	Select the appropriate product from  the Product popup  list.

  The editor presents the list of products described in this resource file.   As usual, the name you choose remains visible in the popup list.


 To Choose a Component

  Before you begin this task, you should know the name of the node in  the component or device hierarchy whose resources you want to  modify.

  To modify resource data, you must locate the component, device, or  device class to which it applies.  All three resource types are presented  as hierarchies; Figure 2-24 shows some examples.  By choosing the  appropriate component, device or device class from the hierarchy, you  determine the situations in which your modification takes effect, and  when it is overridden by more specific instructions.  The left side of the  tree represented on the screen is the more general (affects more  functions, applications, or devices), while the right side is more specific  (affects fewer).

FIGURE 2-24:  Component and Device Hierarchies

In each case, the process of choosing a node in the hierarchy is the  same:

  Step 1.	Locate the appropriate node in the  hierarchy.

  You can move around the hierarchy

  - by moving the scroll bars (if available on your platform)

  - by selecting a device or component

  For example, you might use a mouse to select a node, or you might  move the focus to the appropriate list and select a node from it.  As you  select nodes from the hierarchy, your view shifts to bring the selected  node to the center.

..When you select a node, the resource editor highlights it in a manner  appropriate to your platform, such as changing its color or drawing a  different character.

  Step 2.	Select the node.

  You can select it from the graphic view of the hierarchy on some  platforms;and you can always select the node name from the  "Component" or "Device" list.

Notes

  Placing your modifications in an inappropriate spot in the hierarchy can  cause the modifications to  apply too broadly, too narrowly, or to the wrong node.  If a  modification applies in too many  circumstances, try to move the resource value in question to a more  specific node in the hierarchy.   The resource editor shows more specific node to the right of more  general ones; therefore, look for a  new home for the resource to the right of its current home.  If the  modification does not apply in  enough circumstances, try moving it to a new home to the left of its  current one.


 To Open a Resource File

  Before you begin this task, you should know the name and location of  the resource file that you want to open.  Consult your product  documentation for this information.  You can open as many resource files as your system's capabilities (such  as memory and file handles) can support; the resource editor places no  limit on the number of open files.

  Step 1.	If you have not yet started the  resource editor ot, do so.

  Use the standard methods for your platform to start the resource  editor.   For details on these methods, see theInstallation and  User's Guide for the package that included Oracle Terminal.  If you are just starting ot, skip to Step 4 and  continue from there; otherwise, continue with Step 2.

  Step 2.	If ot is  already running, return to  the main window.

  If you have been editing a resource file, save or discard changes to  close the current window.  Saving changes when you close a window  does not save the changes to the file; for that purpose, see "To Save  Your Modifications" in this chapter.

  Figure 2-25 shows examples of the resource editor's main window.

FIGURE 2-25:  Main Window

  Step 3.	Choose "File/Open".

  The editor presents the Open File Dialog window, whose appearance  is quite platform-specific; Figure 2-26 shows examples.  The  appearance of your window may be quite different.

FIGURE 2-26 Open File Dialog Window

  Step 4.	Choose a file and select  "Open".

  If the name of the resource file you want to modify does not appear in  the file list, look in other directories by selecting one from the list or by  moving around your file system to locate the relevant one.  When the  file's name appears in the list, select its name, then select "Open".

  You can open and modify as many resource files as your system's  memory permits, and you can modify as many of each file's resources  in a single session as you choose. Remember, though, that each open  resource file requires some memory so close files when you finish with  them if possible.  See "To Close a Resource File" in this chapter for  details.


 To Close a Resource File

  You can close one resource file while leaving the rest open (or you can  close the only file currently open).  This makes its data unavailable for  editing until you open the file again, thus preventing inadvertent  modifications.  Closing resource files also reduces the memory required by the resource editor

  Step 1.	Return to the main  window.

  Use "OK" and "Cancel" buttons if necessary to close current windows.   If you have modified the resource data, the editor asks whether you  want to retain your changes when you close the window; choose "Yes"  or "No" as appropriate.  Accepting these changes, however, does not  save them in the resource file; the next step takes care of that.

  Figure 2-27 shows examples of the resource editor's main window.

FIGURE 2-27:  Main Window

  Step 2.	Select "File/Close".

  If you have modified but not saved the file, the editor gives you one  more chance to save it.    Once you close this file, you can proceed to work with files that are  already open, or open others.


 To Cancel Your Modifications

  You can tell the resource editor to cancel all the modifications you have  made since the last time you opened the file (by starting the editor or  with "File/Open") or saved it (whether you saved it directly with  "File/Save" or as part of the "File/Close" or "File/Quit" operations).   The resource editor can only access the contents of the file and of  memory; thus it cannot revert to an earlier version of the file.

  You can cancel modifications in three ways:

•	You can edit the original  resource data by selecting "File/Revert

  This choice is only available in the main window after resource data  has changed.  When you select and confirm "File/Revert", the editor replaces the  resource data in memory with the data from the file.  You can proceed  to edit it as usual.

•	You can cancel changes  and reduce memory usage by closing the  resource file without saving it.

  See "To Close a Resource File" in this chapter for details; select "No"  when the editor asks if you want to save the file.  After closing the resource file, open another (see "To Open a Resource  File" in this chapter), or switch to a different window to edit a file that  is already open.

•	You can cancel changes  by quitting the resource editor without  saving the file.

  See "To Quit the Editor" in this chapter for details; select "No" when the  editor asks if you want to save the file.


 To Save Your Modifications

  You must save the resource file if you want the modifications to affect  your applications.  You must also compile any modified key bindings  after you save the resource file.  See "To  Generate Compiled Key Bindings" in this chapter for details.

  In addition, you may want to save intermediate versions of the file  when making many changes in a single session.  You can also save the  contents of the resource file under a different name.

  You can accomplish this task in three ways:

•	You can save  modifications by selecting "File/Save" or "File/Save  As".

  These menu items are disabled if you have not modified the file since  you last opened or saved it.  Once you save the file, you can continue  to edit it and any other open files.

  To save the resource file with a different name, choose "File/Save As"  and supply the new filename.  If you plan to use the new file with an  application, make sure the application can find the file under the new  name, or rename the file.

•	You can save  modifications and reduce memory usage by closing  the resource file.

  See "To Close a Resource File" in this chapter for details; select "Yes"  when the editor asks if you want to save the file.  After closing the resource file, open another (see "To Open a Resource  File" in this chapter), or switch to a different window to edit a file that  is already open.

•	You can save modifications by quitting the  resource editor and  saving the file.

  See "To Quit the Editor" in this chapter for details; select "Yes" when  the editor asks if you want to save the file.


 To Generate Compiled Key Bindings

  When you finish modifying key bindings for this resource file, you  must compile your modifications to make them available to application  programs.  Before performing this task, you must save the file; see "To  Save Your Modifications" in this chapter.

  Step 1.	Return to the main  window.

  Use "OK" and "Cancel" buttons if necessary to close current windows.   If you have modified the resource data, the editor asks whether you  want to retain your changes when you close the window; choose "Yes"  or "No" as appropriate.  Accepting these changes, however, does not  save them in the resource file; that happens in the next step.  Figure 2-28 shows examples of the resource editor's main window.

  FIGURE 2-28:  Main Window

  Step 2.	Save the resource  file.

  See "To Save Your Modifications" for details on this common task.  The Generate function works on the resource data in the file, not the  data in memory.  Therefore, be sure to save your modifications to the  file before generating compiled bindings.

  Step 3.	Select  "Functions/Generate".

  Step 4.	Save the resource file again with the  newly generated  data.

  See "To Save Your Modifications" for details on this common task.


 To Quit the Editor

  Before you quit the Oracle Terminal resource editor, be sure to save  the resource file if you want to keep your modifications.  If you quit   without saving your changes, the editor warns you that the changes  will be lost and allows you to return to editing the file by choosing  Cancel.  If you changed key bindings, you must compile them after  saving the file; see "To Save Your Modifications" for details.

  Step 1.	Return to the main  window.

  Use the "OK" and "Cancel" buttons if necessary to close current  windows.  If you have modified the resource data, the editor asks  whether you want to retain your changes when you close the window;  choose "Yes" or "No" as appropriate.  Accepting these changes,  however, does not save them in the resource file; see "To Save Your  Modifications" in this chapter for details.  Figure 2-29 shows examples of the resource editor's main window.

FIGURE 2-29:  Main Window

  Step 2.	Select "File/Quit".

  The editor exits and you return to your operating system.


 Window Descriptions

  This appendix contains the brief descriptions of  windows and their contents that you get when you  ask the resource editor for help.  To get help in the  main window, select "Help/Help System"; in most  other windows, select the "Help" button (a few  windows, such as Open File Dialog, do not have  "Help" buttons).  The windows fall into four categories:

  •	the main window

  •	windows for binding keys

  •	windows for creating and modifying logical attributes

  •	windows for creating and modifying terminal  definitions and device hierarchies

  Each window description includes the title and  purpose of the window, and tells you briefly how  to use its pushbuttons, lists, and other controls.


Key Binding Windows
Main Window

  From this window you choose a task to perform.  You can use menus, accelerator keys, or icons to:

•	modify key bindings with "Functions/Edit  Keys"; see To Modify a Key Binding"

•	modify logical attributes with "Functions/Edit  Attributes"; see "To Create or Modify a Logical Attribute"

•	modify terminal/device resources with  "Functions/Edit Device"; see "To Create or Modify a Terminal Definition"

•	specify the default device type for this resource  file with "Functions/Edit Device"; see "To Set the Default Device"

•	generate compiled key bindings with  "Function/Generate"; see "To Generate Compiled Key Bindings"

As part of these tasks, you sometimes need to  perform other activities from this window:

•	open and close resource files, or save the  current contents and continue editing from the  "File" menu; see "To Open a Resource File,"  "To Close a Resource File," and "To Save Your Modifications"

•	select the product to which your modifications  will apply from the "Product" popup list; see  "To Specify a Product"

•	select the device (or windowing system) to  which your modifications will apply from the  "Device" popup list; see "To Specify a Device"

•	switch windows from the "Windows" menu;  see "Switching Windows"

•	request this  text, see the "About" screen, or get  a list of key bindings the editor uses on your  character-mode platform: use the "Help"  menu


Key Binding Windows

  This section describes all the windows you can encounter that are specific to binding keys.


 Key Binding Editor

  In this window you select the component whose resource data you want to modify.  Then you take one of three actions:

  •	Edit Key Bindings modifies the key  bindings  assigned for this component

  •	Preview Bindings checks the syntax of the  current key bindings (in memory), and displays  all the bindings for this node including those  defined at higher levels

  •	If your bindings have syntactic errors, such as  unrecognized key or action names, the editor  alerts you to them.  The editor must have  correct resource data to construct an accurate  list of bindings, so you must fix errors before  using the resource file with your application.   (For more information,  see  "To Modify a Key Binding.")

  •	Product Actions modifies the list of actions  the component can perform, with their product codes and descriptions  (For more information, see "To Create or Modify a Product Action" .)

  If the component in question is not visible, you can  change your view of the component hierarchy by  selecting different nodes at the current level, or by  selecting their ancestors (to the left) or their  children (to the right).

  For more detail, see  "To Choose a Component or Device".


 Key Binding Preview

  This window shows all the key bindings that apply to this node of the component hierarchy.  The list includes key bindings in the node itself, as well as any applicable bindings from nodes that include it.

  When you finish examining the list, select "OK" to  return to the Key Binding Editor.


 Key Binding Definition

  In this window you modify the keys assigned to the component's actions.  If you are developing an OT- based product, you can also modify the list of the component's actions.  To modify a key binding, select the table field to the  right of the action in question.  Then you can type  the name of the key sequence, as in the strings  "Control+x" or "PF1 PF2"; or you can select "Enter  Macro Mode" and type the key sequence itself  (that is, you can hold down Control and type X,  rather than typing the characters in the string  "Control+x").  For details, see "Typing Key Names" and "Using Macro Mode".  The window also contains these pushbuttons :

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  •	Duplicate Row makes a copy of the selected  row

  •	Insert Row adds an empty row above the  selected one

  •	Delete Row deletes the selected row from  the table .  For more information, see "To Modify a Key Binding."


 Product Action Editor

  In this window you select the component whose actions you want to modify.  Then you select "Edit Actions"

.  You can change your view of the hierarchy by

  •	moving the scrollbars if your platform  supports them

  •	selecting different nodes at the current level

  •	selecting ancestors of the current level (to the  left) or children (to the right)

  For more information, see "To Choose a Component or Device".


 Product Action Definition

  In this window you modify the list of actions the component can perform, and supply a numeric code and a brief description for each action.  When you modify key bindings, you associate these actions with keys.

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  •	Duplicate Row makes a copy of the selected  row

  •	Insert Row adds an empty row above the  selected one

  •	Delete Row deletes the selected row from  the table


 Logical Attribute Windows

  This section describes all the windows you can encounter that are specific to logical attributes.


 OT Attributes

  In this window you select a logical attribute to modify.  You can also create, delete, and copy logical attributes here.

  •	Attribute List includes the names of all the  logical attribute lists in the current file; select  the one that contains the attribute in question

  •	Attribute includes the names of all the logical  attributes in the current attribute list; select the  attribute you want to modify

  •	Attribute Name is the field in which you  specify a new name for an attribute you are  adding, or one you are renaming

  •	OK accepts any changes you made in this  window (such as adding or deleting attributes)  and closes the window

  •	Cancel discards any changes you made in  this window and closes the window

  •	Add creates a new logical attribute whose  name you supply in the "Logical Attribute"  field, and adds it to the current attribute list

  •	Delete removes the selected logical attribute  from the current attribute list

  •	Rename substitutes the name you supply in  the "Logical Attribute" field for the name of the  logical attribute you select from the "Attribute"  list

  •	Duplicate makes a copy of the logical  attribute you select from the "Attribute" list,  using the name you supply in the "Logical  Attribute" field

  •	Edit indicates that you want to modify the  logical attribute resource, and takes you to the  next window in that process   For more information, see "To Create or Modify a Logical Attribute".


 Logical Attribute Editor

  In this window you select a device to which the logical attribute applies.  You can also add, delete rename devices here.

  To modify the resource data for the logical  attribute on a device, select the device, then select  "Edit Attributes".

  You can modify the hierarchy:

  •	OK accepts any changes you made in this window (such as adding or deleting logical attributes) and closes the window

  •	Cancel discards any changes you made in this window and closes the window (changes are discarded even if you have brought up subwindows, made changes, and accepted that much with "OK")

  •	Add creates a child of the selected node,  using the name you supply in "Device Name"

  •	Delete deletes the selected node

  •	Rename substitutes the name you supply in  "Device Name" for that of the selected node

  You can change your view of the hierarchy by

  •	moving the scrollbars if your platform  supports them

  •	selecting different nodes at the current level

  •	selecting ancestors of the current level (to the  left) or children (to the right)

  For more information, see "To Choose a Component or Device".


 Edit Attribute Node

  In this window you modify the logical attribute resource data for the given device.  See "Aspects of an Attribute"  for descriptions of the resource data.

  For more information, see "To Create or Modify a Logical Attribute".


 Device Definition Windows

  This section describes all the windows you can encounter that are specific to defining device capabilities.


 Device Class Editor

  In this window you specify the default device type for the current resource file.  You can also select the device class whose terminal definition data you want to modify, and add, delete, or rename a device class.  To specify the default device type for this file, select  one from the "Select Default Device" popup list.   (See "To Set the Default Device" for details.)  To modify the terminal definition (termdef) data,  select the device class, then select "Edit Device".   (See "To Create or Modify a Terminal Definition" for  instructions.)  You can modify the hierarchy:

  •	OK accepts any changes you made in this window (such as adding or deleting logical attributes) and closes the window

  •	Cancel discards any changes you made in this window and closes the window (changes are discarded even if you have brought up subwindows, made changes, and accepted that much with "OK")

  •	Add creates a child of the selected node,  using the name you supply in "Device Class  Name"

  •	Delete deletes the selected node

  •	Rename substitutes the name you supply in  "Device Class Name" for that of the selected  node

  You can change your view of the hierarchy by

  •	moving the scrollbars if your platform  supports them

  •	selecting different nodes at the current level

  •	selecting ancestors of the current level (to the  left) or children (to the right)

  For more information, see "To Choose a Component or Device".


 Device Display Definition

  In this window you specify the device encodings for a number of standard device capabilities. See "Device Characteristics"  for descriptions of the  resource data in this window.

  •	Box Characters allows you to specify the  characters to be used for drawing boxes on a  screen or printer

  •	X Table and Y Table allow you to specify  the encodings for coordinate specifications

  •	Attributes allows you to specify encodings  for character-mode device attributes

  •	Modifiers allows you to specify bindings for  keys such as "Shift" and "Control"

  •	Standard Keys allows you to specify  bindings for keys such as "Return" and "Tab"

  •	User Keys allows you to specify bindings for  keypad keys, function keys, and so on

  For more information, see "To Create or Modify a Terminal Definition".


 Box Character Definition

  In this window you specify the characters to be used for drawing boxes on a screen or printer.

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  See "Box Characters"  for details.


 X Table Definition

  In this window you specify the escape sequences that indicate the various values of the x coordinate.

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  See  "Coordinate Styles"  for details.


 Y Table Definition

  In this window you specify the escape sequences that indicate the various values of the y coordinate.

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  See  "Coordinate Styles"  for details.


 Device Attribute Definition

  In this window you specify encoding for character- mode device attributes.  Once you specify the encoding for a name here, you can use that name to indicate the character-mode device attribute for logical attributes.

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  •	Duplicate Row makes a copy of the selected  row

  •	Insert Row adds an empty row above the  selected one

  •	Delete Row deletes the selected row from  the table

  See "Device Attributes" for more on these encodings.


 Modifier Key Definition

  In this window you specify bindings for modifier keys such as "Shift" and "Control".

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  See  "Key Bindings and Encodings"  for more on these  bindings.


 Standard Key Definition

   In this window you specify bindings for standard keys such as "Return" and "Tab".

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  See  "Key Bindings and Encodings"  for descriptions of these  bindings.


 User Key Definition

In this window you specify bindings for user keys such as function and keypad keys.

  •	OK accepts any changes you have made and  closes the window

  •	Cancel erases your changes and reverts to  the resource data that was current before you  reached this window, then closes the window

  •	Duplicate Row makes a copy of the selected  row

  •	Insert Row adds an empty row above the  selected one

  •	Delete Row deletes the selected row from  the table

  See  "Key Bindings and Encodings"  for descriptions of these  bindings.