Parent Topic: IWORKS
Preferences
Certain configuration items for ImageWorks may be stored in an ImageWorks
preference file. The preference file is named imageworks.prf (or
imagewor.prf on systems with an 8.3 name space like Microsoft Windows 3.1).
The preference file is a simple text file containing text lines with
a preference name, a colon and a value. For instance, the preference file
can control the default cursor colour in ImageWorks; the preference name
is ``CursorColour''. The following line in the preference file would set
the default cursor colour:
CursorColour: Red
Much like other PCI files, it is possible to have a preference file in
various locations: in the local directory, your home directory,
the group procedure directory, and the system-wide procedure directory. If
more than one of these files is found, they will all be read in order with
the most local files being processed last and taking precedence over the
more global files.
- imageworks.prf (most local)
- $HOME/imageworks.prf
- $PCIGROUP/etc/imageworks.prf
- $PCIHOME/etc/imageworks.prf (most global)
See Also: Motif Customization
Adding Menu Items
The Menu preference can be used to add menu items to the ImageWorks
main menubar menus. In fact new menus can also be added.
The data arguments to the Menu preference have the following fields.
- field 1: The name of the procedure to run if the entry is selected, or
an empty string in double quotes if this item is to be a new
pulldown menu.
- field 2: The visible text to be placed on the menu item.
- field 3: The name of the pulldown menu under which to place the new
menu item, or the name of the new pulldown menu if field 2 is
an empty string. The existing pulldown menus in ImageWorks are
named FileMI, EditMI, ViewMI, ToolsMI and HelpMI.
- field 4: The name of the new menu item (should be unique).
The names of all the menu items in ImageWorks can be established by
running the DUMPMENU procedure in the ImageWorks modelling window.
Example:
This item in the preference file would add a new menu item to the Tools
menu (which is named ToolsMI). The new entry would be named BounceMI, and
have visible text "Bounce...". When selected the EASI+ procedure BOUNCE.EAS
would be run.
Menu: BOUNCE "Bounce..." ToolsMI BounceMI
The following example would create a new menu called Misc (and named
MiscMI), and add one item to that menu which would invoke the EASI+
procedure AUTOLOAD.EAS.
Menu: "" "Misc" MiscMI
Menu: AUTOLOAD "Auto Load" MiscMI AutoLoadMI
See Also: Disabling Menu Items
Disabling Menu Items
The Disable-Menu preference can be used to remove menu items, or whole menus
from the ImageWorks main menubar. This is primarily useful for making a
simplified version of ImageWorks available, or to remove a menu item so that
a replacement can be provided using the ``Menu'' preference.
The data arguments to the Disable-Menu preference are the list of names
leading to the particular menu item to be disabled. The names of all the
menu items in ImageWorks can be established by running the DUMPMENU procedure
in the ImageWorks modelling window.
The Disable-Menu preference is applied to the ImageWorks menubar before
the Menu preference, so it is possible to disable a PCI provided menu item,
and replace it with a user provided EASI script.
Example:
The following preferences would remove the filter item on the Tools menu
and remove the entire View menu.
Disable-Menu: ToolsMI FilterMI
Disable-Menu: ViewMI
See Also: Adding Menu Items
Button Bar
The Button Bar preference can be used to decide whether or not the Button
Bar should be shown. By default the Button Bar is shown. To change this
default behaviour, the following can be added to the preference file:
IWHasButtonBar: False
See Also: Message Bar
Message Bar
The Message Bar preference can be used to decide whether or not the Message
Bar should be shown. By default the Message Bar is shown. To change this
default behaviour, the following can be added to the preference file:
IWHasMessageBar: False
In addition, the individual components of the Message Bar can be set to be
visible or not. By default, all the components of the Message Bar are set
to be visible. To change this default behaviour, the following
preferences can be used:
WMBHasMessage: False
WMBHasZoom: False
WMBHasCursor: False
WMBHasNumeric: False
WMBHasMapping: False
See Also: Button Bar
Cursor Colour
The CursorColour preference can be used to modify the default colour of the
cursor in the image display windows. The default is white, but this value
will be overridden if you change the colour in the Cursor Control
panel.
The value of this preference may be any recognised cursor colour, or
any RGB colour in the format ``(RGB: RRR GGG BBB)''.
Example:
The first line would set the default cursor colour to Red, while the second
would set the default colour to an explicit RGB value (red=200,
green=128, blue=64).
CursorColour: Red
CursorColour: (RGB: 200 128 64)
See Also: Cursor Control
Graphic Colour
The Graphic#Colour preference can be used to establish a default colour
for a specified graphic plane. The ``#'' sign is replaced by the number
of the graphic plane, and the argument value can be any recognised
colour name or RGB tuple.
Example:
Set the first three graphic plane colours to shades of grey.
Graphic1Colour: 50 50 50
Graphic2Colour: 125 125 125
Graphic3Colour: 200 200 200
See Also: Graphic Info
Naming A Colour
The NamedColour preference allows the user to defined a new named colour
to the system. This colour should appear in option menus used to select
a colour.
The value arguments to the NamedColour resource should be a name for the
new colour followed by the red, green, and blue components of that colour.
If the colour name is more than one word, it should be enclosed in double
quotes.
Example:
Create a new colour called Slate Grey with the specified RGB value.
NamedColour: "Slate Grey" 40 40 40
Default File Extensions
The DefaultExtensions preference allows the user to define the default
extension, or extensions they would like to see in database selection
dialogs. They can select multiple extensions they would like see; however,
on some systems (such as X/Motif) only the first extension will have an
effect.
Note that this preference only affects the primary file selection mechanism
for image and vector files, not the file selectors used to access ancillary
text files.
The list of extensions should be separated by vertical bar (pipe) symbols,
and there should be no space in the list of extensions. Each extension
should be formed with an asterix followed by a dot followed by the extension
as shown in the example below. In the example, the user requests to see
files with the extensions .pix (PCIDSK), .tif (TIFF) and .jpg (JPEG JFIF).
Example:
DefaultExtensions: *.pix|*.tif|*.jpg
Compact Vectors
The CompactVectors preference can be used to request that ImageWorks store
vectors in a more compact form in memory than is the default. However,
this imposes a price on redraw performance. The CompactVectors preference
can have the following values:
- OFF: Use the default (memory intensive, but fast) in memory storage form
for vectors.
- ON: Use a compact form to store the vectors in memory that is slower but
doesn't lose any information.
- 2D: Use the compact (ON) format, and don't bother storing a Z coordinate
for any of the vertices.
- Float: Use the compact (ON) format, and don't keep full double precision
(8 byte binary numbers) accuracy for vector points. Instead use
floats (4 byte binary numbers) imposing a modest penalty in speed
and accuracy in order to save more memory.
- 2D Float: Apply both the 2D and Float options at the same time.
The CompactVectors preference can be set, or overridden with an environment
variable called CompactVectors. The value of the environment has the same
interpretation as the preference.
Example:
CompactVectors: ON
Shape Save Limit
The ShapeSaveLimit preference allows the user to define the maximum
number of shapes that can be saved in the Vector Editor's undo/redo
buffer when changes are made with a vector editing operation. The
default for this preference is 100 shapes. Hence, if a user performs
a single vector editing operation that affects more than ShapeSaveLimit
shapes (such as a Move), then the changes caused by this operation will
not be saved in the undo/redo buffer so they cannot be undone, and all
of the previous editing changes will be cleared from the undo/redo buffer.
Start up options
The following options control the startup configuration of ImageWorks.
These options may be overridden by the use of command line options or
the presence of a PRM.PRM. Any changes to the configuration will be
saved when ImageWorks terminates.
DataX - The data x size
DataY - The data y size
ViewX - The viewer window x size
ViewY - The viewer window y size
Image8 - The number of 8-bit image planes
Image16 - The number of 16-bit image planes
Image32 - The number of 32-bit image planes
graphicPlanes - The number of graphic planes can be 8 or 16
Example:
DataX: 1000
DataY: 1000
ViewX: 512
ViewY: 512
Image8: 1
Image16: 1
Image32: 1
GraphicPlanes: 8
The lines above configure ImageWorks to have a 1000x1000 data size viewed
with a 512x512 window and has three different image planes. There is one
image plane for each of the available 8,16 and 32-bit types. There are
also 8 graphic planes.
Parent Topic: IWORKS
About PCI Help Gateway