OpenWindows User's Guide

Binder Properties

When you want to modify or add new bindings, use the Props menu or the Props keyboard key to display the Properties window. You fill in or change the information on these properties windows to specify your bindings.

There are two categories of Binder properties: Icon properties and File Type properties. These categories are described in the following sections.

The Apply and Reset buttons at the bottom of the Properties window apply or reset the changes made to both categories, Icon and File Type, at the same time. If you want to make both Icon and File Type changes, you only need to click SELECT on Apply once, after you have finished making both sets of changes.

Icon Properties

The Icon Properties window displays all the information used by DeskSet applications to display and operate on files. The icon properties determine how files of a particular type are displayed by DeskSet applications (such as File Manager), and what happens when files of that type are opened or printed.

You display the Icon Properties window by selecting an entry in the base window scrolling list and choosing Icon from the Props menu. The default Icon Properties window shows only the information needed to display a type of files, as shown in Figure 16-4.

Figure 16-4 Default Icon Properties Window

Graphic

You can click SELECT on the plus sign (+) button at the lower right of the window to expand the window to display the full set of properties, including information needed to open and print a class of files, as shown in Figure 16-5.

Figure 16-5 Expanded Icon Properties Window

Graphic

You can shrink the window back down to the smaller size by clicking SELECT on the minus sign (-) button at the bottom of the expanded window.

This section describes the fields in the expanded Icon Properties window.

Icon and Binder Entry Name

The Icon field shows the current icon and Binder database entry name. Use the text field to modify the entry name, and use the following fields to modify the appearance of the icon. Double-click SELECT on the temporary unique name to the right of the icon to modify the icon.

Image File

The Image File text field displays the path of the 32 by 32 pixel (XView format) icon that is bound to the current Binder entry. The icon is displayed in the base window scrolling list and the Icon field. This is the same icon displayed by the File Manager, Mail Tool, and other applications in the DeskSet environment.

Mask File

The Mask File text field displays the path of an icon color mask. A color mask defines the region of the icon to which the background color is applied. You can think of this as a stencil cut out overlaid on top of your icon before the background color is applied to the icon. If no icon mask file is specified, the entire icon is colored with the background color.

The icon mask does not have to be a 32 by 32 (XView format) pixel icon. If it is larger, only the first 32 by 32 (XView format) pixels in the top left corner of the icon are used.

For example, Figure 16-6shows the icon and the icon mask for the printtool-prog Binder entry. The image on the left is the icon image, and determines what is outlined in the foreground color. The image on the right is the icon mask, and determines the area of the icon colored with the background color.

Figure 16-6 The printtool-prog Icon and printtool-prog Icon Mask

GraphicGraphic

Image File and Mask File Line

These text lines specify the path (directory location) to the icon and the icon's mask--a stencil of the image that determines the area of the icon colored with the background color. To modify the current icon in its appearance on the workspace, do not modify these paths.

Foregr (Foreground) Color

The foreground color is the color that the icon itself is drawn (icon outline) within the File Manager and other DeskSet applications. If no value is given for this field, the foreground color is black.

If you want to pick a new foreground color, click SELECT on the window button to the right of the Foregr Color text field to invoke the Color Chooser application. See "Using the Color Chooser Palette with Binder " for more information.

Alternatively, you can type three numbers in the Foregr Color text field to indicate the amount each of red, green, and blue in the foreground color. Color saturation values range from 0 through 255. For example, 255 0 0 represents a bright, solid red color.

Backgr (Background) Color

The background color is the color the icon is colored within (the lines of the icon) the File Manager and other DeskSet applications. If no value is given for this field, the background color is white.

If you want to pick a new background color, click SELECT on the button to the right of the Backgr Color text field to invoke the Color Chooser. See the section "Using the Color Chooser Palette with Binder " for more information.

Alternatively, you can type three numbers in the Backgr Color text field to indicate the amount of red, green, and blue, respectively, of the background color. Color saturation values range from 0 through 255. For example, 0 255 0 represents a bright, solid green color.

Application

The Application text field defines the application that is invoked whenever any file defined by the current binding is opened in File Manager or other applications in the DeskSet environment. This text field is on the expanded portion of the Icon Properties window.


Note -

If there is a ToolTalk method available, applications do not use this field. Refer to the Desktop Integration Guide.


Print Method

The Print Method defines how a file is printed in the DeskSet environment. If no Print Method is specified, the default print method of the application the file is being printed from is used. This field is on the expanded portion of the Icon Properties window.


Note -

DeskSet applications such as File Manager and Print Tool expect print methods to be in this format: cat $FILE | (pipe1) | (pipe2) ... Defining a print method of another type may produce unexpected results with the deskset tools. See also Chapter 10, Print Tool, for information on overriding a default Print Method.


File Type Properties

You use the File Type Properties window to define the set of files that are bound to the icon, colors, and applications defined in the Icon Properties window.

You display the File Type properties by choosing File Types from the Props menu or the Category choice on the Properties window. The default File Type Properties window is shown in Figure 16-7.

Figure 16-7 Default File Type Properties window

Graphic

You can click SELECT on the plus sign (+) button to expand the window to display the full set of properties, including information needed to identify a class of files, as shown in Figure 16-8.

Figure 16-8 Expanded File Type Properties window

Graphic

You can shrink the window back down to the smaller size by clicking SELECT on the minus sign (-) button at the bottom of the expanded window.

This section describes the fields in the File Type Properties window.

File Type Scrolling List

Each entry in the File Type scrolling list defines how a file, or a group of files, is recognized by DeskSet applications. You can think of each entry in the File Type scrolling list as a class of files, which may consist of one file or many files. Each class of files in this scrolling list (each File Type entry) is bound to the Icon properties of the current Binder entry.


Note -

If you have two identical File Type entries in your Binder database, only the first one that the Binder reads is used. The first Binder entry to use the File Type entry is not necessarily the first Binder entry in the Binder base window scrolling list.


Pattern Text Field

Use the Pattern text field beneath the scrolling list to modify the name of a File Type entry. If the files are to be identified by a pattern, this pattern must be the name of the Binding entry. If the currently selected File Type is identified by Content, the Pattern text field is dimmed and unavailable.

When there are no items selected on the scrolling list, you can type a pattern into the Pattern text field and press Return to create a new File Type entry.

File Type Properties Window Buttons

You SELECT the buttons to the right of the File Type scrolling list to create and delete File Type entries, and to move them to and from a clipboard, as follows:

You use the Apply and Reset buttons at the bottom of the File Type Properties window to apply your File Type and Icon Properties changes to the current Binder entry, or to reset all the changes you've made since the last Apply.

Identify Choice Item

TheIdentify choice item determines how the current class of files (the selected File Type entry) is recognized by DeskSet applications, such as the File Manager. A class of files is recognized either by Name or by Content, as defined in the following sections:

Identify By Name

If the Identify choice is by Name, files are recognized by the pattern in the Pattern text field. In this case, the Pattern is often the name of an application. For example, Figure 16-9 shows the clock File Type entry that is bound to the clock-prog Binder entry. Any file called clock will be displayed by the File Manager with the clock icon and colors displayed in the base window scrolling list. (The icon and colors are defined by the clock-prog Icon properties.)

Figure 16-9 Clock File Type Entry

When the Identify choice is "by Name" and the Pattern text field contains an asterisk (*), the asterisk in the Pattern means "match any file name here." For example, the File Type Entry *.ps, shown in Figure 16-10, matches all files that end with.ps. These files are PostScript files, and are displayed in the DeskSet with the postscript-file icon displayed in the Binder base window scrolling list.

Figure 16-10 The *.ps File Type Entry

Graphic

An exception to the rule about matching the pattern with the file name occurs with the Binder entries default-app, default-dir, and default-doc. The File Manager application uses these entries to determine the bindings for its default application files, directories (folders), and documents. The File Type patterns for these bindings are default|app, default|dir, and default|doc. You will never, however, actually find a file called default|app, default|dir, or default|doc. See "Changing a Binding" for information about how to change these default File Manager bindings.

Identify by Content

If the Identify choice is by Content, files are recognized by matching file contents instead of the file name. When you choose by Content, the four fields underneath the Identify setting become active. These fields define what the file contents should be to define files of the current File Type, as follows:

See the magic manual page for advanced information about the Tag Type, Tag Mask, and Tag Value fields.

Figure 16-11 shows that PostScript files can be recognized by the string "%!" at the beginning of the file (Tag Offset = 0, Tag Type = String, Tag Value =%!). Note that PostScript files can also be recognized by files ending with.ps, as described previously in the section "Identify By Name".

Figure 16-11 The postscript-file Content File Type Entry

Graphic

Figure 16-12 shows the sun-raster File Type entry. This class of files is defined as all files starting with the Long value 0x59a66a95.

Figure 16-12 The sun-raster File Type Entry

Graphic