The Option File
When Rogue Wave® Views Studio is launched, it reads an option file to set up its properties. You can alter the predefined configuration by using an additional option file and setting its path to the ILVSTOPTIONFILE environment variable or the stOptionFile resource. Rogue Wave Views Studio loads your option file after loading the $ILVHOME/studio/data/studio.opt file.
When building a Rogue Wave Views Studio extension, you can use the IlvStudio member function addOptionFile(const char*) before calling the initialize function to programmatically add an option file that will be loaded for all the users. Your option file is loaded after the studio.opt file and before the option file specified by the final user, if any (with the environment variable or resource).
The option file has the following syntax:
Studio {
<option-1> <value-1>;
// ...
<option-n> <value-n>;
}
Configuration Options
Rogue Wave Views Studio provides you with the following configuration options:
alignmentSpacing <size> lets you specify the value used when aligning objects with a given space distribution. The default value is 5.
bitmapAlias "<oldName>" "<newName>" makes Rogue Wave Views Studio use the bitmap
<newName> instead of
<oldName>. This option can be used several times.
bufferBackground "<colorName>" lets you specify the default background color of the buffer windows when they are created. If this option is not specified, the new buffer has the same background as the current buffer.
bufferSize <width> x <height> lets you specify the dimensions of the panels when they are created.
For example:
studio {
bufferSize 400 x 200;
}
If this option is not specified, the new buffer has the same size as the current buffer.
command <commandDeclaration> lets you directly declare a command in the
.opt file. See the section
Rogue Wave Views Studio Command File for the syntax of command declarations. This option can be used several times.
For example:
studio {
command ShowScriptEditor {
label "&scriptEditor";
prompt "&scriptEditorP";
bitmap "icsced.gif";
category script;
}
commandFile "<cmdFile>" lets you specify a command declaration file (
.cmd) file that Rogue Wave Views Studio loads after loading the
studio.cmd file provided. The
ILVPATH environment variable is used to locate the specified file. This option can be repeated.
For example:
studio {
commandFile "mystudio.cmd";
}
dataFileExtension "<extension>" lets you specify the Rogue Wave Views data file extension. The default value is
.ilv.
defaultBufferName <name> lets you specify the name of a new buffer. The default value is
noname.
For example:
studio {
defaultBufferName newBuffer;
}
defaultDragDropPalette "<palette name>" lets you specify the palette that is selected by default when the Palettes panel is initialized.
The following option lets you add a palette:
dragDropPalette "<palette name>"
{ <option-1 <value-1>;
...
<option-n <value-n>;
}
<palette name> is the name of the new palette. It must be unique.
The following is a list of options that can be used in the palette description:
dataFileName "<filename>" specifies the file name of the palette data.
label "<label>" specifies the label of the palette in the tree gadget.
bitmap "<bitmap>" specifies the name of the bitmap representing the palette in the tree gadget.
path "<palette1>" [... "<paletteN>"] [-before "<paletteX>"] specifies the location of the palette in the tree gadget.
palette1 ... paletteN are the names of the parent nodes, and
palette1 is the root node. If you want your palette to be inserted before another palette, use the
-before keyword followed by the name of the palette. If the path is not specified, the new node is added as a root node in the tree gadget.
containerClass "<class>" specifies the class name of the container to be used. The default value is
"IlvGadgetContainer".
containerWidth <width> specifies the width of the container used when creating the palette container.
containerHeight <height> specifies the height of the container used when creating the palette container.
editionName "<name>" lets you specify the name of your Rogue Wave Views Studio edition. Use this option to identify the specialization of your Rogue Wave Views Studio extension. The specified name appears in the Studio Information Panel.
For example:
studio {
editionName "Script Edition";
}
fileBrowserType "<filter>" "<message>" lets you add a file type to the Rogue Wave Views Studio file browser. This option can be repeated. Use this option if you extend Rogue Wave Views Studio to load your own file type. See also the
fileLoader option.
For example:
studio {
fileBrowserType "*.js" "&scriptFilesFilter";
}
fileLoader "<extension>" "<commandName>" lets you specify the command to be executed to load a file that has a given extension. This option can be repeated. See also the
fileBrowserType option. For example:
studio {
fileLoader "js" "LoadScript";
}
fontFoundries <foundryList> lets you customize the font foundries listed by the Font Selector. Note that the font foundries only apply to X11 platforms.
For example:
studio {
fontFoundries {
"sun",
"dec",
"sony",
"myFoundry"
}
}
fontNames <fontList> lets you customize the preferred font names used by the Resource panel.
For example:
studio {
fontNames {
"fixed",
"normal",
"myfont"
}
}
hideGenericInspector <true/false> lets you hide the Generic inspector when the editor is launched. This option defaults to
false.
ignoringSize <true/false> lets you save the data file without saving the size of the gadget buffers. This option defaults to false. Use this option if you do not want the size of the buffer to be saved in the data file.
ignoringBackground <true/false> lets you save the data file without saving the background color of the gadget buffers. This option defaults to
false. Use this option if you want your panels to have the default background color.
include "<fileName>" lets you load another option file in your
.opt file. The specified file is searched for in
ILVPATH.
For example:
studio {
include "myfile.opt";
}
infoPanelDuration <seconds> lets you specify the period of time (in seconds) during which the Information panel is displayed when the editor is launched. The default value is
5 seconds.
For example:
studio {
infoPanelDuration 10;
}
infoPanelTitle "<title>" lets you specify the title of the Information panel.
language "<languageName>" "<commandLabel>" "<commandPrompt>" lets you define a command selecting
<languageName> as the current language of the
IlvDisplay. This option can be repeated. The name of the defined command is
SetLanguage_<languageName>, and its label and prompt are specified by
<commandLabel> and
<commandPrompt> respectively.
For example:
studio {
language "en_US" "English (U.S.)" "Speak English (U.S.)";
}
defines the following command:
command SetLanguage_en_US {
label "English (U.S.)";
prompt "Speak English (U.S.)";
}
Use this option if you provide a message database for <languageName>.
messageDB "<dbname>" lets you load a multilingual message database specified by
<dbname>.
For example:
studio {
messageDB "mymessages.dbm";
}
movingPointer <true/false> lets you specify whether you want the editor to move the mouse pointer to the center of a newly opened window (
true) or not (
false).
For example:
studio {
movingPointer true;
}
objectInteractor <interactorName> lets you add an interactor name to the predefined interactor list used by the Interactor dialog box (activated by the
SetObjectInteractor command). Use this option if you want to add an object interactor to Rogue Wave Views Studio.
For example:
studio {
objectInteractor MyInteractor;
}
panel <panelDescription> lets you directly specify panel properties in the
.opt file. This option can be repeated. See
Rogue Wave Views Studio Panel Description File for the syntax of panel description. Unlike the panel descriptions you specify in a separate
.pnl file, the panel description you provide in the
.opt file is loaded before the provided
studio.pnl file.
For example:
studio {
panel "Classes" {
topView true;
}
}
panelFile "<pnlFile>" lets you specify the panel description file (
.pnl) file that Rogue Wave Views Studio will load after the
studio.pnl file provided has been loaded. The
ILVPATH environment variable is used to locate the specified file. This option can be repeated.
playerSpeed <milliseconds> lets you specify the event player speed in milliseconds. The default value is
500.
recentFileListLength <length> lets you specify the length of the recent file list that appears in the File menu. This option defaults to
6.
removeDragDropPalette "<palette name>" lets you remove a predefined palette from the tree gadget in the Palettes panel.
removeToolBarItem <commandName> <toolBarName> lets you remove a command from a named tool bar. Use this option if you want to hide an icon in a tool bar defined in the delivered
studio.opt file.
For example:
studio {
removeToolBarItem SelectSpinBoxMode IlvStGadgetBuffer;
}
sortingRequirements <true/false> sorts, if
true, the state requirements in the State Inspector.
startUpCommand <commandName> lets you specify the command that will be executed when the editor is launched. This option can be repeated.
For example:
studio {
startUpCommand EditStates;
}
studioName "<name>" lets you customize the name of your Rogue Wave Views Studio extension, saved in the
.iva file. The default string is
"Views Studio".
For example:
studio {
studioName "My Studio Extension";
}
studioShortName "<name>" lets you change the "short name" of the editor. This name is displayed in the title bar of the Main window, before the application name. The default string is
"ivstudio".
For example:
studio {
studioShortName "mystudio";
}
toolBarItem <commandName> <toolBarName> [-before <refCommandName>] lets you add a command
<commandName> in the tool bar
<toolBarName>. This option can be repeated. Optionally, you can specify a command
<refCommandName> before which you want to insert the new command by using the keyword
-before.
For example:
studio {
toolBarItem SelectLabelMode IlvStGadgetBuffer -before
SelectFocusMode;
}
toolBarCommands <name> <commands> lets you define a new tool bar. The defined tool bar can then be used by any panel.
toolBarItemHeight <height> lets you specify the height of the tool bar items. Use this option if you want to use bigger icons. See also
toolBarItemWidth.
toolBarItemWidth <width> lets you specify the width of the tool bar items. Use this option if you want to use bigger icons. See also
toolBarItemHeight.
Example
The following option file sets the default directories for the generated files and adds three editing modes to the Gadgets buffer window tool bar.
// /usr/smith/mystudio.opt: My configuration file.
studio {
defaultHeaderDir "include";
defaultSrcDir "src";
defaultObjDir "obj";
defaultHeaderFileScope "myinclude/";
toolBarItem SelectLabelMode
IlvStGadgetBuffer -before SelectActiveMode;
toolBarItem SelectLabelListMode
IlvStGadgetBuffer -before SelectActiveMode;
toolBarItem SelectReliefLineMode
IlvStGadgetBuffer -before SelectActiveMode;
}
If the file mystudio.opt file is saved in the directory /usr/smith, the ILVSTOPTIONFILE environment variable must be set to the access path to this file, as shown below:
On Microsoft® Windows® platforms:
set ILVSTOPTIONFILE=/usr/smith/mystudio.opt
On UNIX® platforms:
setenv ILVSTOPTIONFILE /usr/smith/mystudio.opt
Version 6.0
Copyright © 2015, Rogue Wave Software, Inc. All Rights Reserved.