A number of minor aspects of the behaviour of COGENT can be tailored through the application's options. These specify, for example, when warning and confirmation errors should be printed, or how printouts should be formatted. There are five categories of options: directories; printing options; fonts; warnings & confirmations; and miscellaneous.
The Options Window provides an interface to COGENT's options. Through this window, options may be inspected or changed (either temporarily or permanently). The precise layout of the Options Window depends on which category of option is being displayed. In all cases, however, it consists of three regions. The top row gives the category name, with a menu button that allows other option categories to be displayed. Beneath this is a row of four buttons which allow various operations over the particular category of options being displayed. Beneath this, is a set of widgets which show the values of the particular options in the category under view and which allow those values to be altered. Any alterations take immediate effect, but such alterations will only be stored for future use if they are also saved (with the Save button). It is also possible to return to a user's default values for the current category of options with the Reload button. The Help button causes the appropriate version of this window to appear (a different version will appear for each category of option), and the Done button causes the Options Window to close.
COGENT several different types of file: project/model files, print output files, import/export files, oos class files, script files, archive files, and help files. Each of these types of file may be stored in a different location. The locations are specified by five options specified under the File Locations section of the Options panel.
The project directory specifies where COGENT should look to find project files. Normally each user will keep all projects in a single directory, and this value will only need to be changed when, for example, viewing someone else's projects.
COGENT can produce printouts of models or projects in ASCII, PostScript or HTML. The print directory specifies the default directory in which COGENT should put such print files. It's probably sensible if you intend to keep electronic copies of your printouts that you keep them all in the same place. Note that the directory in which a printout is put can also be at print time from the panel that appears when the print function is invoked.
It is possible to export from a model to a plain text file (for editing with a standard text editor) and to then import that resulting file. The import/export directory specifies the default directory in which COGENT should put or find files containing exported or imported code. As in the case of printing, this directory can also be set at the time of invoking the import and export functions.
COGENT projects that are not in progress may be "archived" in order to save space. The archive directory specifies the directory in which COGENT stores and searches for archived projects. This directory cannot be set at the time of invoking the archive or extract functions.
COGENT uses a scripting language to guide model execution. The scripting language is quite powerful, allowing complex experimental designs to be specified. Novice users, however, may find the scripting language an unnecessary distraction. COGENT therefore allows the user to specify a set of default scripts, contained in the script directory. When a model is created, copies of all scripts in the script directory are associated with the new model. If COGENT is correctly installed, the user should not need to change this property, unless s/he wishes to install different default scripts.
OOS Class Directory
This property specifies the location of the OOS class directory. This directory should contain the Prolog definitions of each box type. If COGENT is correctly installed, the user should not need to change this property, unless s/he wishes to install different box classes.
The help URL specifies where COGENT should look for help files (like this one), in the form of a URL to be passed to a web browser. When help is invoked, the help file name is appended to the end of the Help URL, and the result is passed to your browser. By default, the help directory is /usr/local/lib/cogent/, and the help URL is:
(with appropriate modifications for your help directory). The effect is to present help pages without the index frame.
NOTE: Most COGENT options are saved as standard Xdefaults in the users .Xdefaults file. Directory paths are different because they relate to the machine on which COGENT is running, rather than the machine on which COGENT is displaying its output. As a result, COGENT stores directory paths in a different way: in a .cogentrc file in the user's home directory. If you don't have such a file, COGENT will create one for you, using default values for all the directory paths.
The Printing Options panel controls default settings for a number of options which govern the appearance and content of COGENT printouts. Note that a Print Options panel is also displayed when the print function is invoked. This subsidiary panel specified the options to be used for a particular printout, and allows default values specified in the main Printing Options panel to be over-ridden.
The Printing Options panel contains the following controls:
Print to file (default: FALSE; Xdefault name: Cogent.PrintToFile)
This option allows switching between sending output to a printer or saving it to a file. If the option is TRUE, output generated by print commands is saved in a file (with filename and directory as specified by the Print file and Print directory options discussed below). If the option is FALSE, output is printed using the command specified by the Print command option.
Print file (default: cogent.ps; Xdefault name: Cogent.PrintFile)
This option specifies the file in which printer output will be saved when Print to file is TRUE. The directory in which this file is placed is determined by the Print directory option.
Printer command (default: lp -c; Xdefault name: Cogent.PrintCommand)
The option's value specified the print command used by COGENT to print output. When the value of Print to file is FALSE, COGENT generates a file (in the format given by Output format), prints it (via this command) and then deletes its. Likely values of this option are lp -c (for SOLARIS and IRIX 5.X), lpr (for SUN OS 4.X), and ghostview to preview the PostScript without printing it.
Output format (default: 1 (i.e., PostScript); Xdefault name: Cogent.PrintFormat)
This option specifies the format in which print output is produced. Currently three formats are possible: Plain Text, PostScript, or HTML. Possible values are 0, 1 and 2 corresponding respectively to these formats.
Printer font size (default: 10; Xdefault name: Cogent.PrintFontSize)
This option controls the font size used in PostScript printouts generated by COGENT. It is ignored for other output formats.
Print new box on new page (default: FALSE; Xdefault name: Cogent.NewPage)
When this option is TRUE, COGENT will start the description of each box on a new printer page. If the option is FALSE, then COGENT will be less wasteful and only start a new page when absolutely necessary. Note that when Output page style is set to Two Up mode two logical pages are printed on each sheet of paper, so a new page in this context means the next logical page.
Output page style (default: 0 (i.e., Portrait); Xdefault name: Cogent.PageStyle)
This option controls the orientation and style of PostScript output. Possible values are 0, 1 and 2, corresponding to Portrait, Landscape, and Two Up, respectively. In Portrait style the long edge of the paper is vertical. In Landscape style the long edge is horizontal. Two Up page style consists of two logical pages per sheet of paper. The pages are oriented in portrait style, but reduced by a factor of 1.414 and printed side by side.
Show initial contents (default: TRUE; Xdefault name: Cogent.PrintInitialContents)
This option controls whether the initial contents of boxes are included in the printout.
Show current contents (default: TRUE; Xdefault name: Cogent.PrintCurrentContents)
This option controls whether the current contents of boxes are included in the printout.
Show conditions (default: TRUE; Xdefault name: Cogent.PrintConditions)
This option specifies whether the conditions within a box should be included in full in the printout. In some views, condition definitions are peripheral "implementation details", and setting this option to FALSE ensures that such details are excluded in the resulting printout.
Show messages (default: TRUE; Xdefault name: Cogent.PrintMessages)
This option specifies whether the log of message processed by each box should be included in the printout.
Recurse through subobjects (default: TRUE; Xdefault name: Cogent.RecursivePrint)
If this option is TRUE, details of all subboxes of compound boxes are included in the printout.
The Font Options panel allows modification of some fonts used on COGENT's windows. Alternate fonts may be used to give COGENT a personalised look, or simply if something bigger or smaller is preferred. The available fonts may be accessed using the "Set" buttons on the font optiosn panel.
Canvas font (default: lucidasans-12; Xdefault name: Cogent.CanvasFont)
This option controls the font used for drawing project and model names on the main history canvas and model subcanvases.
Output font (default: lucidasans-12; Xdefault name: Cogent.OutputFont)
This option controls the font used when displaying the current states of objects.
The COGENT execution engine (OOS) can be configured in a variety of ways. The following options are relevant:
OOS Binary Location (default: "oos"; Xdefault name: Cogent.OosBinary)
This string-valued property specifies the location of the OOS executable. For the standard configuration (with the executable compiled as "oos" and located on the user's path), the default value of "oos" is appropriate, but users with multiple versions of OOS available on their machines may wish to configure this option differently.
OOS Window Size (default: 5; Xdefault name: Cogent.OosWinSize)
This integer-valued option specifies the number of lines shown in the Prolog component of a COGENT run window.
Show debugging information (default: FALSE; Xdefault name: Cogent.OosDebug)
This boolean option determines the level of information printed in OOS's trace output window while a model is running. When the option is set, numerous additional messages concerning the processing state of OOS are printed.
Save message logs (default: TRUE; Xdefault name: Cogent.OosMessages)
This boolean option controls whether OOS creates messages logs whilst running. Message logs consist, for each box, of all messages sent to or from that box, and cna be viewed through the standard COGENT interface. The information contained in messages logs can be extremely useful for debugging purposes, but can also quickly fill most hard disks. Turn the option off if you are happy with a model's performance and running low on disk space.
Optimise (default: TRUE; Xdefault name: Cogent.OosOptimise)
If this boolean option is set OOS uses a number of code optimisation. It should only affect (and improve) a model's execution speed. It is primarily for development purposes.
The COGENT interface is capable of generating lots of warning and confirmation messages which require action from the user. Many of these messages can be suppressed by setting the appropriate control of the Warnings & Confirmations panel.
Warn on file errors? (default: TRUE; Xdefault name: Cogent.WarnFileErrors)
If TRUE, display a warning message whenever a file read/write fails.
Warn on Prolog syntax errors? (default: TRUE; Xdefault name: Cogent.WarnSyntaxErrors)
If TRUE, display a warning whenever a syntax error is detected in a Prolog term.
Warn on unrecognised Prolog? (default: TRUE; Xdefault name: Cogent.WarnUnrecognisedProlog)
If TRUE, display a warning whenever unrecognised Prolog is found in a project or model file.
Warn on allocation failure? (default: TRUE; Xdefault name: Cogent.WarnAllocationFailure)
If TRUE, display a warning whenever memory allocation fails.
Warn on miscellaneous errors? (default: TRUE; Xdefault name: Cogent.WarnMisc)
If TRUE, display a warning on any unexpected events not covered by the above.
Reassure on success? (default: FALSE; Xdefault name: Cogent.WarnOK)
If TRUE, display a reassuring message whenever a file operation is successfully completed.
Confirm project/model deletion? (default: TRUE; Xdefault name: Cogent.ConfirmDeleteModels)
If TRUE, seek confirmation from the user before deleting projects or models.
Confirm discard of edits? (default: FALSE; Xdefault name: Cogent.ConfirmDiscardEdits)
If TRUE, seek confirmation from the user before discarding edits from any files.
Confirm continue after syntax error? (default: FALSE; Xdefault name: Cogent.ConfirmContinueLoading)
If TRUE, seek confirmation from the user before continuing after a Prolog syntax error.
Confirm overwrite file? (default: FALSE; Xdefault name: Cogent.ConfirmOverwrite)
If TRUE, seek confirmation from the user before overwriting any files.
Confirm print? (default: TRUE; Xdefault name: Cogent.ConfirmPrint)
If TRUE, seek confirmation from the user before printing any files.
Confirm save on run? (default: FALSE; Xdefault name: Cogent.ConfirmSaveChanges)
If TRUE, seek confirmation from the user before saving a model at execution time.
A number of further options control other aspects of COGENT's operation.
Double click interval (default: 400; Xdefault name: Cogent.DoubleClickInterval)
This option specifies the maximum number of milliseconds that can elapse between two mouse clicks if they are to be interpreted as a double click.
Grid size (default: 5; Xdefault name: Cogent.GridSize)
When drawing boxes on a COGENT canvas, the boxes automatically align themselves on a grid. This value determines the size of that grid.
X Drift (default: 0; Xdefault name: Cogent.XDrift)
COGENT attempts to remember window positions across sessions. Window positioning is tricky, however, because window managers tend to add borders that make the true window position difficult to determine. This variable allows the user to correct any window drift in the X direction that the occurs because of border width. (Hint: For olvwm set this to 0; For fvwm2 set this to 5.)
Y Drift (default: 1; Xdefault name: Cogent.YDrift)
COGENT attempts to remember window positions across sessions. Window positioning is tricky, however, because window managers tend to add borders that make the true window position difficult to determine. This variable allows the user to correct any window drift in the Y direction that the occurs because of border width. (Hint: For olvwm set this to 1; For fvwm2 set this to 23.)
Numeric Precision (default: 2; Xdefault name: Cogent.NumericPrecision)
This value specifies the number of significant digits that COGENT stores and prints when presenting real numbers.
Box Highlight Colour (default: 18; Xdefault name: Cogent.HighlightColour)
This value is an index into COGENT's colour table. It specified the colour used to highlight boxes when they are selected. The default colour index (18) normally appears as red.
Summarise box contents? (default: FALSE; Xdefault name: Cogent.SummariseContents)
When this option is TRUE, and a box of rules or data is opened, COGENT will initially show the contents in summarised form. When FALSE, the contents of such boxes are initially shown in full detail. In either case, a toggle button on appropriate canvases allows the user to switch between summarised and expanded form.
Popup on create? (default: FALSE; Xdefault name: Cogent.PopupCreate)
If this option is TRUE, whenever on item (either a box or a box element) is created, the appropriate editor will be automatically opened up ready to edit the new object.
Scale history? (default: TRUE; Xdefault name: Cogent.ScaleHistory)
If this option is TRUE, the time-line display of project histories will use the creation time of models to scale the horizontal axis of the display. The horizontal distance between models on the display will then represent the difference in their creation times. If this option is FALSE, models will be spaced equally on the history display.
Scrollable canvases? (default: FALSE; Xdefault name: Cogent.CanvasScrollbars)
When this option is TRUE, COGENT adds horizontal and vertical scrollbars to all box/arrow canvases. This is desirable when a model has lots of components, but is otherwise unnecessary.
Remember window positions? (default: TRUE; Xdefault name: Cogent.SaveObjectInfo)
When this option is TRUE, COGENT records the size and position of all windows associated with each model and uses this information to recreate the display state (i.e., exact window sizes and positions) of that model when it is re-opened.
Create backup files? (default: FALSE; Xdefault name: Cogent.BackupFiles)
This option forces COGENT to maintain backup files of all models. Whilst this sounds like a good idea, in reality it is defeated by the obscure naming convention employed for files. Thus, even if backup is on, it can be difficult for the non-trained user to recover a backed-up file.
Smooth scrolling of text elements? (default: TRUE; Xdefault name: Cogent.SmoothScroll)
When TRUE, COGENT performs smooth scrolling of Initial Contents windows. This looks nice, but is impracticable on slow machines. When FALSE, jump scrolling is performed.