{ <window> = } wtable <file>
or
{ <window>= } wtable {
<sub_panel_block>
}
Define a table window, i.e. a matrix of sub-panels.
<window>
A window identifier
whose contents are to be a matrix of sub-panels. If this is omitted, the
next free window will be used.
<file>
A text file containing
the layout and contents of one row of sub-panels. There is no default
file extension. If this parameter is not present, sub-panel details will
be expected to appear in a language block following the command line.
<sub_panel_block>
A language block, providing the layout and contents of one row of sub-panels.
-at=<atable>
An atable to be searched within callback procedures for this window. This
means that any identifiers within <atable>
referenced in a callback do not have to be prefixed by ~<atable>. This cannot be the
local atable.
-col=<color>
The background color of the window contents. If omitted, a default color is
used.
-dec=<n>
A specification of the window decoration to be added by the window manager.
Possible values are:
0 (or -no_dec) for no decoration at all,
1 for full decoration (the default),
>1 for custom decoration, see Window Decoration.
-dim=<screen_xy>
Define the dimensions of the window contents area in pixels. This is a 2-element numeric array.
If omitted, the area is computed to enclose all the defined sub-panels.
-emb=<string>
Embed the window
into a container provided by an external client. <string> is the name of an
embed container created by the embed command.
If the embed container does not exit or is invalid, this switch is ignored.
-fix
Create the window fixed size, i.e. non-resizable. This is the default
behavior unless window.resizable has previously
been set. Use -no_fix to make the window resizable.
When a table window is resizable it cannot be grown to a size larger than
the sum of its contents.
-fo=<font>
The font to be used for sub-panel text, which includes row/column headings
and row serial numbers . This must be a fixed font. If omitted, a default
fixed font is used.
-gap=<num>
The gap, in pixels, to be used between sub-panels. The default value is 4.
-geo=<screen_box>
The geometry of the window in screen coordinates, either just its position
(a 2-element array) or its full rectangle geometry (a 4-element array).
The default is the value of window.outrect.
-gh
The window should be initially ghosted, i.e. insensitive to user-interaction.
The default is the current value of window.ghosted.
-ic
Open the window in iconic form. The default is the value of window.open.
-inv
Open the window invisible. The default is the value of window.visibility.
-m=<num>
The size of the window margin, in pixels, within which sub-panels are positioned.
The default value is 4.
-mas
Define the window as a master window. When a master window is iconized,
this also iconizes all other windows.
-mb
Give the window a menubar for user buttons. If omitted, the window
will be created without a menubar.
-mf=<font>
The font to be used for menubar text. This must be a fixed font. If omitted
a default fixed font is used. This option has no effect on Windows systems,
where menubar font and color are controlled by the window manager.
-mul
Add a selection button to each row of sub-panels. Multiple rows may
be selected.
-num
Include the window slot number in the window's title. Use -no_num
to suppress it. The default behavior is governed by the value of the system
numeric window_numbers.
-ocol=<color>
The other color for use in the window, e.g. for text. If omitted, a default
color is used.
-pos=<screen_xy>
The position of the menu in screen coordinates. This is a 2-element array.
The default is the value of window.outrect[1:2].
-row=<num>
The total number of rows in the matrix. If omitted 0 is assumed.
-sel
Add a selection button to each row of sub-panels. Only one row may be
selected at any one time.
-ser
Add a serial number label to each row of sub-panels. If the -sel
or -mul switch is also present, serial numbers
are displayed in or alongside the selection buttons.
-sh=<string>
A shell name for communication with X application resources. If omitted, the value
panel is used.
-tb
Display the window icon in the Windows taskbar. The default behavior is
not to display it in the taskbar but only to display it on the desktop when
minimized. This switch has no meaning on Unix systems.
-tit=<string>
Provide a title for the window. The default is the value of window.title.
-v
Define vertical orientation. This reverses the display of rows/columns
so that a "row" will run down the matrix rather than across.
The default orientation is horizontal.
-vis=<num>
The number of visible rows in the matrix. This will define the initial size
of the window if not given by other means (e.g, -geo).
If omitted, a value of 6 is used if required.
The <sub_panel_block> or the contents of <file> is made up of definition statements each describing a sub-panel or providing control information for layout purposes. The sub-panels are assumed to define one logical row of the matrix.
The general form is:
{<name> :} <sub-panel> {<parameters>} {<switches>}
where:
<name>
A user-given name
for subsequent sub-panel reference purposes. If omitted, then a name is
derived as item<n>
where n is the index of the sub-panel within the row.
<sub_panel>
A sub-panel
definition, one of the following:
check_button - a toggle-button
combo_box - an interactive text input box with a pulldown menu for possible choices
dial - an interactive dial
gap - the spacing between sub-panels
options - a button and pulldown to select from
progress - a numeric progress bar
radio_box - a one-of-many list to select from
slider - an interactive slider
text - an interactive text input box
<parameters> and <switches>
These define the contents and geometry of sub-panels.
Selection may be made from sub-panels during command polling or during pop-up menu selection when used with the -m option.
Details of sub-panel attributes may be examined or set after window creation via the window structure member window.panels, or by a sub-panel’s column name.
Table windows are always created with scrollbars, which are only made visible when the window size is not large enough to accommodate all rows.
Create a table window with 1000 rows, each with 5 columns. Make 5 rows visible initially, and make one row at a time selectable.
window emp_table = wtable -row=1000,-sel,-vis=5 { sname: text -bc=white,-c=20,-head='Surname' cnames: text -bc=white,-c=32,-head='Forenames' sex: options <'Male','Female'>,-head='Sex' marital: check_button 'Married',-head='Married' empno: text -bc=white,-c=12,-head='Id' }
Commands: |
|
Identifiers: |
win# (window), window_numbers (numeric) |
Structures: |