/KUIP_SET_SHOW

Set or show various KUIP parameters and options.

/KUIP/SET_SHOW/STYLE [ option sgylen sgsize sgyspa sgbord wktype ]

OPTION C Option D='?'
SGYLEN R max Y LENgth of each menu item box D=0.025 R=0.005:0.25
SGSIZE R space available for the application D=0.8 R=0:0.90
SGYSPA R max Y length of space between menus D=0.02 R=-0.5:0.50
SGBORD R X or Y border for menus D=0.015 R=0:0.25
WKTYPE I Graphics workstation type D=0

OPTION:

'?' show current style
'C' Command line : select Command line input
'AN' Menu with Numbers : select general Alpha menu (with Numbers)
'AL' Menu with Letters : select general Alpha menu (with Letters)
'G' Graphics menu hardware : select Graphics menu (with hardware character fonts)
'GW' Graphics menu shadowed : select Graphics menu (with shadowed Width effect)
'GS' Graphics menu Software : select Graphics menu (with Software character fonts)
'GP' Panel keys : select Graphics menu (with Panel keys only, i.e. no command tree menu)
'XM' Motif/X11 : select Motif/X11 interface

Select the user dialog style (or working mode). The startup value is 'C' (command mode). The current value is returned by the system function $STYLE.

The G-styles are only available if the application program is calling KUWHAG instead of KUWHAT. When one of these options is choosen the remaining parameters control the geometrical layout of the menus on the screen and the graphics workstation type (in case HIGZ was not initialized).

Style 'XM' is only available if the program is calling KUWHAM. In that case switching to other styles is not possible.

/KUIP/SET_SHOW/PANEL line [ gkey ]

LINE R Line number D=0
GKEY C Graphics key value(s) D=' '

Set up a (user-definable) panel of commands with graphics keys. These keys are associated to pre-defined commands (or list of commands), which are generally corresponding to actions frequently executed.

The "panel interface" is available in "STYLE GP" and in KUIP/Motif (but not in the basic command mode). Nevertheless the syntax of the PANEL command is different in these two modes of interface. The "panel interface" is a lot more powerful in KUIP/Motif, which means that the command is more complex.

N.B. in "STYLE GP" only one panel of commands can be set up, whereas in KUIP/Motif there is no limitation.

Syntax of the command in "STYLE GP" :

PANEL x.y command where: x,y is the key position (column and row number) command is the complete command name (or list of commands) to be excuted when the button is pressed.

Examples:

PANEL 0 | reset the panel (in memory) PANEL 2.04 MESSAGE | initialize 4th key of 2nd line to MESSAGE PANEL 2.04 | clear 4th key of 2nd line

Note that the key number on the right of the decimal point must always be defined with two digits.

Keys ending with a minus sign make an additional request of keyboard input; the complete command line will be the key text, with a blank at the place of the minus, concatenated with the additional keyboard input. Example:

PANEL 1.03 'VEC/PRI-' | entering VAB will execute VEC/PRI VAB.

Keys ending with a double minus sign behave as above but no blank is put at the place of the double minus. Example:

PANEL 1.03 'VEC/PRI V--' | entering AB will execute VEC/PRI VAB

The dollar sign inside a key is replaced by additional keyboard input. Example:

PANEL 1.03 'VEC/PRI V($)' | entering 11:20 will execute VEC/PRI V(11:20)

Syntax of the command in "KUIP/Motif" :

All what is described above (for "STYLE GP") is still available. But the (more) general syntax in "KUIP/Motif" is:

PANEL x.y command [label] [pixmap] where: x,y is the key position (column and row number) command is the complete command name (or list of commands) to be excuted when the button is pressed. label (optional) is an alias name for this command. If specified, it is used for the button label (when the appropriate "View" option is selected) instead of the complete command (which is generally too long for a "user-friendly" button label. pixmap (optional) has to be specified when you want to have graphical keys instead of pure text labels.

In KUIP/Motif, the special value "0" for x.y (PANEL 0 ...) can be used for different purposes (according to the 2nd parameter value):

PANEL 0 D [title] [geometry]

can be use to display the current panel which is in memory with (optionals) a given title and geometry (size and position).

PANEL 0 C [title]

can be use to close the last panel, or the one corresponding to the given title.

Examples:

- PANEL 0 D 'This is my first panel' 500x300+500+600

displays the panel which has been set in memory by the key definition, and sets the title to ``This is my first panel'', the window size to ``500x300'' (WxH) and the window position to ``500 600'' in x and y. If no title and/or no geometry is specified one is given by default.

- PANEL 0 C 'This is my first panel'

closes (destroys and erases from the screen) the panel whith title ``This is my first panel''. If no title is specified the last created panel is closed by default.

As the "panel interface" is rather complex and powerful in KUIP-Motif, if you want to know all the possibilities, we invite you to refer to the KUIP User Guide (where you will also find picture illustrations).

/KUIP/SET_SHOW/NEWPANEL line col title width height xpos ypos

LINE I Number of lines D=5 R=1:30
COL I Number of columns D=5 R=1:30
TITLE C Panel Title D='NewPanel'
WIDTH I Panel width (in pixels) D=300 R=10:
HEIGHT I Panel height (in pixels) D=300 R=10:
XPOS I X Position (in pixels) D=0 R=0:
YPOS I Y Position (in pixels) D=0 R=0:

Set up a new panel with empty keys. This new panel must then be filled interactively.

/KUIP/SET_SHOW/COMMAND [ chpath ]

CHPATH C Path name for command line D=' '

Set a filter for the parsing of command lines. If it has been called, it means that whenever a command line is entered, if and only if it is not an existing command (not just ambiguous), it is inserted into the CHPATH string, with $n (n=1..9) being replaced by the n-th token of the command (tokens are separated by spaces), or $* being replaced by the whole command line. Examples:

COMMAND 'V/CR $*(10)' AA => V/CR AA(10) BB => V/CR BB(10) V/LIST => V/LIST COMMAND 'VECTOR/PLOT $1 555 $2' AA E => VECTOR/PLOT AA 555 E BB => VECTOR/PLOT BB 555 COMMAND => shows its current value COMMAND * => reset (equivalent to COMMAND $*)

Note that COMMAND and subsequent command lines can be used inside macros, excepted when producing macro statements (like EXEC, IF, GOTO, etc.). For example, the above examples would work also inside macros, while COMMAND 'EXEC $*' or COMMAND 'GOTO $1' will not.

/KUIP/SET_SHOW/APPLICATION path [ cmdex ]

PATH C Application name D=' '
CMDEX C Exit command D='EXIT'

Set the application name. This means that all input lines will be concatenated to the string PATH (until the command specified by the parameter CMDEX is executed, which resets the application to the null string). The value of CMDEX may be specified if the default value EXIT has to be changed (i.e. because already used by the application). APPLICATION can also be inserted in a macro: in this case at least 4 characters must be specified (i.e. APPL).

/KUIP/SET_SHOW/ROOT [ path ]

PATH C Root directory D='/'

Set the root for searching commands. If PATH='?' the current root is shown. This allows to access commands regardless of possible ambiguities with different menus. Commands are first searched starting from the current root: if a command is found it is executed. Only if a command is not found a second pass of search is done, starting now from the top root of the command tree (i.e. '/').

/KUIP/SET_SHOW/TIMING [ option ]

OPTION C Option D='ON'

OPTION:

'ON'
'OFF'
'ALL'

Set ON/OFF/ALL the timing of commands. If ON, the real time and the CPU time for the latest executed command (or macro) are presented. If ALL, the time is shown for each command being executed within a macro. The startup value is OFF.

/KUIP/SET_SHOW/PROMPT prompt

PROMPT C Prompt string D=' '

Set the prompt string for the command mode dialogue. If PROMPT is blank the current prompt is left unchanged. If PROMPT contains the character sequence '[]' the current command number is inserted between the square brackets.

/KUIP/SET_SHOW/BREAK [ option ]

OPTION C Option D='ON'

OPTION:

'ON'
'OFF'
'TB'
'?'

Set ON/OFF the break handling. If OPTION='?' the current value is shown. The startup value is ON.

Hitting the keyboard interrupt (CTRL/C on VMS or CTRL/Q on the Apollo) under break ON condition, the current command or macro execution will be interrupted and the user will get again the application prompt.

BREAK TB switch ON the traceback of the routines called, with their line numbers, when an error occurs. This allows the detection of the routines which provoked the error.

/KUIP/SET_SHOW/COLUMNS [ ncol ]

NCOL I Number of columns for terminal output D=80 R=-1:

Set the maximum number of columns for terminal output. If NCOL=0 the current number of columns is shown. If NCOL=-1 the current number of columns is taken from the environment variable COLUMNS. If COLUMNS is undefined the startup value is 80.

/KUIP/SET_SHOW/RECORDING [ nrec ]

NREC I Rate for recording on history file D=25 R=0:

Set the recording rate for the history file. Every NREC commands of the session the current history file is updated. If NREC=0 the history is not kept at all (i.e. the file is not written). See also the command LAST.

/KUIP/SET_SHOW/HOST_EDITOR [ editor top left width height dxpad dypad npads ]

EDITOR C Host editor command D='?'
TOP I Top position of the edit window D=20 R=0:
LEFT I Left position of the edit window D=20 R=0:
WIDTH I Width of the edit window D=0 R=0:
HEIGHT I Height of the edit window D=0 R=0:
DXPAD I X offset for help PAD windows D=30 R=0:
DYPAD I Y offset for help PAD windows D=20 R=0:
NPADS I Maximum number of shifted pads D=4 R=1:

Set the host command to invoke the editor. The EDIT command will invoke this editor. If EDITOR='?' the current host editor command is shown.

On Apollo the special value EDITOR='DM' invoke Display Manager pads. The special values EDITOR='WINDOW' and 'PAD' can be used to specify the window positions (in pixel units). 'WINDOW' defines the parameters for edit pads, while 'PAD' defines the parameters for read-only pads (e.g. used by 'HELP -EDIT').

On VMS the special values EDITOR='EDT' and 'TPU' invoke the callable editors. The startup time is considerably lower compared to spawning the editor as a subprocess. The callable EDT has one disadvantage though: after an error, e.g. trying to edit a file in a non-existing directory, subsequent calls will always fail. The TPU call can be augmented by command line options, e.g.

HOST_EDITOR TPU/DISP=DECW | DECwindow interface to EVE

On Unix a variety of editors are available, e.g.

HOST_EDITOR vi HOST_EDITOR 'emacs -geometry 80x48'

On Unix workstations it is possible to do asynchronous editing via the KUIP edit server, i.e. to start an editor in a separate window while the application can continue to receive commands. In order to do that the following conditions must be fulfilled:

- The KUIP edit server 'kuesvr' must be found in the search path. - The editor command set by HOST_EDITOR must end with an ampersand ('&'). - The environment variable 'DISPLAY' must be set.

The ampersand flags your intention to use the edit server if possible. If the edit server cannot be used the ampersand will be ignored, i.e. even with

HOST_EDITOR 'vi &'

the KUIP/EDIT command will block until the editor terminates if either the 'kuesvr' is not available or 'DISPLAY' is undefined. When using the edit server the editor command is expected to create its own window. 'vi' being a frequent choice, the above command is automatically interpreted as

HOST_EDITOR 'xterm -e vi &'

The startup value can be defined by the environment variable 'EDITOR'. Otherwise it is set to a system dependent default: 'DM' (Apollo), 'EDT' (VMS), 'XEDIT' (VM/CMS), 'vi' (Unix).

/KUIP/SET_SHOW/HOST_PAGER [ pager ]

PAGER C Host pager command D='?'

Set the host command to view a file in read-only mode. If OPTION='?' the current host pager command is shown. The 'HELP -EDIT' command will invoke this pager, e.g.

HOST_PAGER more

On Unix workstations the pager can be asynchronous by creating a separate window, e.g.

HOST_PAGER 'xterm -e view &' HOST_PAGER 'ved &'

On Apollo the special value PAGER='DM' defines the use of Display Manager read-only pads. The pad positions can be adjusted by the HOST_EDITOR command.

The startup value can be defined by the environment variables 'KUIPPAGER' or 'PAGER'. If neither of them is defined the value set by the HOST_EDITOR command is used. On VAX/VMS the startup value is 'TYPE/PAGE'.

/KUIP/SET_SHOW/HOST_PRINTER [ command filetype ]

COMMAND C Host printer command D='?'
FILETYPE C File extension D=' '

Set the host commands for printing files with KUIP/PRINT. The KUIP/PRINT command will use the host command matching the file extension or use the default command defined for FILETYPE=' '.

If COMMAND='?' the currently set commands are shown. If COMMAND=' ' the currently defined command is delete. The command string can contain '$*' and '$-' to indicate the position where the file name with/without file extension should be inserted. For example,

MANUAL / refman.tex latex HOST_PRINTER 'latex $* ; dvips $-' .tex KUIP/PRINT refman.tex

invokes the shell command 'latex refman.tex ; dvips refman'. The predefined defaults are not guaranteed to work since the actual print commands are very much installation dependent.

/KUIP/SET_SHOW/HOST_PSVIEWER [ psviewer ]

PSVIEWER C Host PostScript Viewer command D='?'

Set the host command to invoke the PostScript Viewer. The PSVIEW command will invoke this PostScript Viewer. If PSVIEWER='?' then the current viewer command is shown.

The startup value can be defined by the environment variables 'KUIPPSVIEWER' or 'PSVIEWER'.

On Unix workstations it is by default set to 'ghostview'. On VAX/VMS the default commands is 'VIEW/FORM=PS/INTERFACE=DECWINDOWS'.

/KUIP/SET_SHOW/HOST_SHELL [ shell ]

SHELL C Host shell command D='?'

Set the default host shell invoked by the KUIP/SHELL command. If OPTION='?' the current host shell is shown. The startup value is taken from the 'SHELL' environment variable.

/KUIP/SET_SHOW/RECALL_STYLE [ option ]

OPTION C Command recall and editing style D='?'

OPTION:

'?' show current setting
'KSH' Korn shell : Emacs like command line editing
'KSHO' Korn shell + Overwrite : like 'KSH' but overwrite instead of insert mode
'DCL' VAX/VMS DCL : DCL command line editing
'DCLO' VAX/VMS DCL + Overwrite : like 'DCL' but overwrite instead of insert mode
'NONE' disable command line editing

Set the command recall and editing style. If OPTION='?' the current style is shown. The startup value is 'DCL' on VAX/VMS, 'NONE' on Cray and Apollo DM pads, and 'KSH' on other systems.

If the terminal emulator returns ANSI escape sequences (hpterm doesn't!) the up/down arrow keys can be used to recall items from the command history list and the left/right arrow keys to move the cursor.

'KSH' style provides the following control keys for editing:

^A/^E : Move cursor to beginning/end of the line. ^F/^B : Move cursor forward/backward one character. ^D : Delete the character under the cursor. ^H, DEL : Delete the character to the left of the cursor. ^K : Kill from the cursor to the end of line. ^L : Redraw current line. ^O : Toggle overwrite/insert mode. Text added in overwrite mode (including yanks) overwrites existing text, while insert mode does not overwrite. ^P/^N : Move to previous/next item on history list. ^R/^S : Perform incremental reverse/forward search for string on the history list. Typing normal characters adds to the current search string and searches for a match. Typing ^R/^S marks the start of a new search, and moves on to the next match. Typing ^H or DEL deletes the last character from the search string, and searches from the starting location of the last search. Therefore, repeated DELs appear to unwind to the match nearest the point at which the last ^R or ^S was typed. If DEL is repeated until the search string is empty the search location begins from the start of the history list. Typing ESC or any other editing character accepts the current match and loads it into the buffer, terminating the search. ^T : Toggle the characters under and to the left of the cursor. ^U : Kill from the prompt to the end of line. ^Y : Yank previously killed text back at current location. Note that this will overwrite or insert, depending on the current mode. TAB : By default adds spaces to buffer to get to next TAB stop (just after every 8th column). LF, CR : Returns current buffer to the program.

'DCL' style provides the following control keys for editing:

BS/^E : Move cursor to beginning/end of the line. ^F/^D : Move cursor forward/backward one character. DEL : Delete the character to the left of the cursor. ^A : Toggle overwrite/insert mode. ^B : Move to previous item on history list. ^U : Delete from the beginning of the line to the cursor. TAB : Move to next TAB stop. LF, CR : Returns current buffer to the program.

/KUIP/SET_SHOW/VISIBILITY cmd [ chopt ]

CMD C Command name D=' '
CHOPT C ?, OFF, ON D='?'

CHOPT:

'?'
'OFF'
'ON'

Set or show the visibility attributes of a command.

If CHOPT='OFF':

- the command it is not executable anymore - STYLE G draws a shadowed box on the command - HELP may be still requested on the command

The startup value is ON.

/KUIP/SET_SHOW/DOLLAR [ option ]

OPTION C Substitution of environment variables D='?'

OPTION:

'?' show current setting
'ON' enable substitution
'OFF' disable substitution

Set or show the status of environment variable substitution.

This command allows to enable/disable the interpretation of environment variables in command lines. The startup value is 'ON', i.e. "$var" is substituted by the variable value.

Note that the system function "$ENV(var)" allows using environment variables even for 'DOLLAR OFF' .

/KUIP/SET_SHOW/FILECASE [ option ]

OPTION C Case conversion for filenames D='?'

OPTION:

'?' show current setting
'KEEP' filenames are kept as entered on the command line
'CONVERT' filenames are case converted
'RESTORE' restore previous FILECASE setting

Set or show the case conversion for filenames.

This command has only an effect on Unix systems to select whether filenames are kept as entered on the command line. The startup value is 'CONVERT', i.e. filenames are converted to lowercase.

On other systems filenames are always converted to uppercase.

The 'RESTORE' option set the conversion mode to the value effective before the last FILECASE KEEP/CONVERT command. E.g. the sequence

FILECASE KEEP; EDIT Read.Me; FILECASE RESTORE

forces case sensitivity for the EDIT command and restores the previous mode afterwards.

/KUIP/SET_SHOW/LCDIR [ directory ]

DIR*ECTORY C Directory name D=' '

Set or show the local working directory.

The current working directory is set to the given path name or the current directory is shown.

To show the current directory used LCDIR without argument. 'LCDIR ~' switches to the home directory. 'LCDIR .' switches back to the working directory at the time the program was started.