- NAME
- ::gridplus::gridplus - Create/control GridPlus window layouts.
- EXPORTS
- icons
- SYNOPSIS
- package require gridplus ?2.5?
- gridplus::gridplus mode ?option value(s) ...? ?layout?
- gridplus::gpclear ?item?
- gridplus::gpcopy ?item?
- gridplus::gpcut ?item?
- gridplus::gpfind item string ?direction?
- gridplus::gpfind_dialog ?item?
- gridplus::gpinsert item position value
- gridplus::gpmap itemlist valuelist ?direct|left|right?
- gridplus::gpmap itemlist elementlist array
- gridplus::gppaste ?item?
- gridplus::gpselect item match ?column?
- gridplus::gpselect item date
- gridplus::gpselect item {} -selectonly
- gridplus::gpset item value
- gridplus::gpset {item value ...}
- gridplus::gpset -selectonly item {}
- gridplus::gpunset {item ...}
- DESCRIPTION
- OPTIONS
- -action type
- -anchor position
- -attach position
- -autogroup group
- -background color
- -basename basename
- -borderwidth width
- -calcolor color/color
- -calrelief style
- -calselectcolor color/color
- -ccmd command
- -century year
- -cfmt format
- -checkbuttoncommand command
- -columnformat format
- -columnsort boolean
- -command command
- -compound position
- -date date
- -dateclear boolean
- -datecommand command
- -dateformat format
- -Dcmd command
- -dcmd command
- -dropdowncommand command
- -ecmd command
- -entrycommand command
- -errormessage message
- -fileicon icon
- -fixed size
- -foldericon icon
- -font font
- -foreground color
- -group groupname
- -height amount
- -icon icon
- -iconfile filename
- -iconpath path
- -icons boolean
- -in container
- -insertexpr expression
- -insertoptions options
- -justify position
- -labelanchor position
- -labelcolor color/color
- -labelstyle style/style
- -linerelief style
- -linewidth width
- -linkcolor color/color
- -linkcursor cursor
- -linkstyle style/style
- -menu menu
- -minx amount
- -miny amount
- -modal boolean
- -navbar boolean
- -navcommand command
- -navselect boolean
- -open boolean
- -optionset optionsetname
- -overrideredirect boolean
- -pad amount
- -padding amount
- -padx amount
- -pady amount
- -pattern regexp
- -prefix prefix
- -proc boolean
- -rcmd command
- -radiobuttoncommand command
- -relief style
- -resize directions
- -scroll scrollbars
- -selectfirst boolean
- -selectmode mode
- -selectonly
- -selecttoday boolean
- -show elements
- -sortfirst boolean
- -sortorder order
- -space spacing
- -spacestretch format
- -state state
- -sticky position
- -stretch format
- -style style
- -subst boolean
- -taborder order
- -tags boolean
- -takefocus boolean
- -text text
- -title text
- -topmost boolean
- -validate boolean
- -validateauto boolean
- -validatepopup boolean
- -validation text
- -variable name
- -variables boolean
- -wcmd command
- -weekstart day
- -widget type
- -width amount
- -windowcommand command
- -wrap mode
- -wraplength amount
- -wtitle text
- GRIDPLUS WIDGET OPTIONS
- &type
- &type:style/optionset
- .name
- .name=parameter
- :icon
- %group
- .name
- <
- <group
- >
- >group
- @name
- ?helptext
- ?!
- !
- !+
- !name
- !name?message
- !@name
- !@name?message
- |
- =
- +value
- -value
- *
- ~command
- #style
- integer1/integer2
- integer
- text
- GRIDPLUS GRID/LAYOUT
- COMMANDS
- gridplus add name ?option value(s) ...?
- -group groupname
- gridplus button name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to button
- gridplus calendar name ?option value(s) ...?
- -calcolor color/color
- -calrelief style
- -calselectcolor color/color
- -command command
- -date date
- -labelanchor position
- -navbar boolean
- -navcommand command
- -navselect boolean
- -padding amount
- -relief style
- -selecttoday boolean
- -title text
- -variable name
- -weekstart day
- gridplus checkbutton name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to checkbutton
- gridplus clear ?option value(s) ...? window
- -variables boolean
- window
- gridplus container name ?option value(s) ...?
- -height amount
- -padding amount
- -relief style
- -title text
- -sticky position
- -width amount
- gridplus date name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to date selector
- gridplus define definitions
- gridplus dropdown name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to dropdown
- gridplus entry name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to entry
- gridplus grid name ?option value(s) ...? layout
- -anchor position
- -attach position
- -cfmt format
- -columnformat format
- -labelanchor position
- -icon icon
- -iconfile filename
- -iconpath path
- -justify position
- -optionset optionsetname
- -pad amount
- -padding amount
- -padx amount
- -pady amount
- -prefix prefix
- -relief style
- -size width
- -space spacing
- -spacestretch format
- -state state
- -stretch format
- -style style
- -subst boolean
- -taborder order
- -title text
- -wraplength amount
- -wtitle text
- layout
- gridplus layout name ?option value(s) ...? layout
- -labelanchor position
- -optionset optionsetname
- -pad amount
- -padding amount
- -padx amount
- -pady amount
- -relief style
- -taborder order
- -title text
- -style style
- -subst boolean
- -wtitle text
- layout
- gridplus line name ?option value(s) ...?
- -background color
- -borderwidth width
- -linewidth width
- -optionset optionsetname
- -pad amount
- -padx amount
- -pady amount
- -title text
- gridplus link name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to link
- gridplus menu name ?option value(s) ...? layout
- -optionset optionsetname
- -prefix prefix
- -proc boolean
- -state state
- layout
- gridplus menubutton name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to menubutton
- gridplus notebook name ?option value(s) ...? layout
- -command command
- -optionset optionsetname
- -subst boolean
- -taborder order
- layout
- gridplus optionset name ?option value(s) ...?
- gridplus pack name ?option value(s) ...?
- -minx amount
- -miny amount
- -resize directions
- gridplus radiobutton name ?option value(s) ...? layout
- Alias for gridplus widget with the -widget option set to radiobutton
- gridplus set ?option value(s) ...?
- -century year
- -dateformat dateformat
- -errormessage text
- -group groupname
- -pattern pattern
- -prefix prefix
- -proc boolean
- -state state
- -text text
- -validation name
- gridplus tablelist name ?option value(s) ...? columns
- -action type
- -background color
- -columnsort boolean
- -command command
- -group groupname
- -height amount
- -insertexpr expression
- -insertoptions options
- -menu menu
- -options options
- -optionset optionsetname
- -padding amount
- -prefix prefix
- -proc boolean
- -relief style
- -scroll scrollbars
- -selectfirst boolean
- -sortfirst boolean
- -sortorder order
- -state state
- -tableoptions options
- -title text
- -validate boolean
- -width amount
- layout
- gridplus text name ?option value(s) ...?
- -autogroup group
- -background color
- -command command
- -font font
- -group groupname
- -height amount
- -iconfile filename
- -iconpath path
- -linkcolor color/color
- -linkursor cursor
- -linkstyle style/style
- -optionset optionsetname
- -padding amount
- -proc boolean
- -relief style
- -scroll scrollbars
- -state state
- -tags boolean
- -takefocus boolean
- -title text
- -width amount
- -wrap boolean
- gridplus tree name ?option value(s) ...?
- -action type
- -command command
- -fileicon icon
- -foldericon icon
- -height amount
- -iconfile filename
- -iconpath path
- -icons boolean
- -menu menu
- -open boolean
- -optionset optionsetname
- -padding amount
- -proc boolean
- -relief style
- -scroll scrollbars
- -title text
- -validate boolean
- -width amount
- gridplus widget name ?option value(s) ...? layout
- -anchor position
- -autogroup group
- -background color
- -basename basename
- -ccmd command
- -cfmt format
- -checkbuttoncommand command
- -columnformat format
- -compound position
- -dateclear boolean
- -datecommand command
- -Dcmd command
- -dcmd command
- -dropdowncommand command
- -ecmd command
- -entrycommand command
- -fixed size
- -foreground color
- -group groupname
- -icon icon
- -iconfile filename
- -iconpath path
- -justify position
- -labelanchor position
- -labelcolor color/color
- -labelstyle style/style
- -linkcolor color/color
- -linkcursor cursor
- -linkstyle style/style
- -optionset optionsetname
- -pad amount
- -padding amount
- -padx amount
- -pady amount
- -prefix prefix
- -proc boolean
- -rcmd command
- -radiobuttoncommand command
- -relief style
- -space spacing
- -spacestretch format
- -state state
- -stretch format
- -style style
- -subst boolean
- -taborder order
- -takefocus boolean
- -title text
- -validatemode mode
- -validatepopup boolean
- -widget type
- -width amount
- -wrap mode
- -wraplength amount
- -wtitle text
- layout
- gridplus window name ?option value(s) ...?
- -in container
- -modal boolean
- -topmost boolean
- -windowcommand command
- gpclear ?item?
- gpcopy ?item?
- gpcut ?item?
- gpfind item string ?direction?
- gpfind_dialog ?item?
- gpinsert item position value
- gpmap itemlist valuelist ?direct|left|right?
- gpmap itemlist elementlist array
- gpnav item target ?increment?
- gppaste ?item?
- gpselect item match ?column?
- gpselect item {} -selectonly
- -selectonly
- gpset item value
- gpset {item value ...}
- gpset -selectonly item {}
- -selectonly
- gpunset {item ...}
gridplus::gridplus - Create/control GridPlus window layouts..
package require gridplus ?2.5?
gridplus::gridplus mode ?option value(s) ...? ?layout?
gridplus::gpclear ?item?
gridplus::gpcopy ?item?
gridplus::gpcut ?item?
gridplus::gpfind item string ?direction?
gridplus::gpfind_dialog ?item?
gridplus::gpinsert item position value
gridplus::gpmap itemlist valuelist ?direct|left|right?
gridplus::gpmap itemlist elementlist array
gridplus::gpnav item target ?increment?
gridplus::gppaste ?item?
gridplus::gpselect item match ?column?
gridplus::gpselect item date
gridplus::gpselect item {} -selectonly
gridplus::gpset item value
gridplus::gpset {item value ...}
gridplus::gpset -selectonly item {}
gridplus::gpunset {item ...}
gridplus
gpclear
gpcopy
gpcut
gpfind
gpfind_dialog
gpinsert
gpmap
gpnav
gppaste
gpselect
gpset
gpunset
The GRIDPLUS package is used to create and layout the contents of Tk windows. The
package consists of thirteen commands:
- gridplus - Create/control screen layouts.
- gpclear - Clear (delete) selected text.
- gpcopy - Copy seleted text to clipboard.
- gpcut - Copy seleted text to clipboard and then delete.
- gpfind - Find and select specified string in text item.
- gpfind_dialog - Popup "Find" dialog box to find and select specified string in text item.
- gpinsert - Insert a row at a specfied position into a text or tablelist item.
- gpmap - Set values of GRIDPLUS widgets by mapping a list of items to a list of values or array elements.
- gpnav - Moves text display to specified label -or- Moves calendar display to specified month/year
- gppaste - Paste text from clipboard.
- gpselect - Select a specified row/node in a tablelist/tree widget -or- Moves calendar display to specified month/year and selects date.
- gpset - Set values of GRIDPLUS widgets -or- Set value of and moves calendar display to specified month/year.
- gpunset - Unset values of GRIDPLUS widgets.
Every mode does not necessarily support every option.
- -action
- Specifies the type of action to take when clicking on a line in a tablelist -or-
a node in a tree. Acceptable values are default (Default), double and single.
By default the selected line/node is highlighted. double highlights the line/node for
a single click and executes the item command for a double-click. single highlights
the line/node and executes the item command for a single-click.
- -anchor
- Specifies how to place the grid within the master when no row/column has any weight (Default: s).
- -attach
- Specifies where in a cell that the contents will be "attached". Valid values for this
option are n, w and "null" (Default). If the default value (null) is used the
contents will be attached to all points - meaning the contents will "stretch" to fill the cell.
The other values allow the contents to be attached (justified) to the top and/or left of the cell.
- -autogroup
- Specifies a string to identify a state group to be set to the "normal" state when the
associated entry/text widget is updated. When specified for an entry/widget grid, the group
is associated with all entry widgets in the grid.
- -background
- Specifies the background color.
- -basename
- Specifies the basename for widget values and commands. Normally the name of a widget value is based on
the name of the grid in which it is created. For example: If an entry widget called ".firstname" is
created in a grid is called ".person" the value is identified by "$(.person,firstname)". If the
basename is set to ".employee" the value will be identified by "$(.empoyee,firstname)". The same
principle is also applied to the default names of commands invoked by grid widgets.
- -borderwidth
- Specifies a non-negative value indicating the width of the 3-D border to draw
around the outside of a grid/layout (if such a border is being drawn; the relief
option typically determines this).
- -calcolor
- Specifies the Calendar foreground/background colors.
- -calrelief
- Specifies the 3-D effect desired for the Calendar border. Acceptable values
are raised, sunken, flat (Default), ridge, solid, groove
and theme. The value indicates how the interior of the Calendar should appear relative
to its exterior; for example, raised means the interior of the Calendar should appear
to protrude from the screen, relative to the exterior of the Calendar. When set to theme
the Tile theme style is used.
- -calselectcolor
- Specifies the Calendar foreground/background colors for a selected date.
- -ccmd
- Specifies command to executed when an associated checkbutton is selected.
Alias -checkbuttoncommand.
- -century
- Specifies a non-negative integer (1-99) to be used as the century window for entry
field date validations (Default: 50). Years after the window are considered to be in the
previous century. (Example: Assuming -dateformat is us, if the user enters
120160 this will be validated as 12/01/1960).
- -cfmt
- Specifies, on a per-column basis, the width of the left and right elements. The format is specifed as a list.
Each item in the list is applied to the corresponding column in the grid. Each item consists of up to two elements
separated by a "/" (left_width/right_width). Each element is optional. Where an element is not specified
the width of the column element will be based on the size of the largest widget (as normal). Acceptable formats are:
left_width , left_width/right_width, /right_width (Examples: 15 15/25 /25).
Alias -columnformat.
- -checkbuttoncommand
- Specifies command to executed when an associated checkbutton is selected.
Alias -ccmd.
- -columnformat
- Specifies, on a per-column basis, the width of the left and right elements. The format is specifed as a list.
Each item in the list is applied to the corresponding column in the grid. Each item consists of up to two elements
separated by a "/" (left_width/right_width). Each element is optional. Where an element is not specified
the width of the column element will be based on the size of the largest widget (as normal). Acceptable formats are:
left_width , left_width/right_width, /right_width (Examples: 15 15/25 /25).
Alias -cfmt.
- -columnsort
- Determines whether the column sort option is enabled for a tablelist.
A value of 0 means that column sort is disabled. 1 (Default) means
that column sort is enabled.
- -command
- Specifies command to executed when a Tablelist/Tree action is invoked, Notebook tab is selected,
Text is modified or a Calendar date selected.
- -compound
- Specifies (for a compound button) the position of the icon/image relative to the text.
Valid values for this option are bottom, center, left (Default), right
and top.
- -date
- Specifies the initial month/year display for a Calendar. The date must be in the format
specified by -dateformat. The day part of the date is not used (but
must be specified) unless the -selecttoday option is also specified.
- -dateclear
- Determines whether the pressing the Delete key will clear the content of a date selector field.
A value of 0 means that the Delete key will not clear the field. 1 (Default) means that
Delete key will clear the field.
- -datecommand
- Specifies command to executed when an date is selected from an associated dropdown date selector.
When specified for a date selector grid the command is associated with all date selector widgets
in the grid. Alias -Dcmd.
- -dateformat
- Specifies the date format for entry field date validations and calendar/date selector values.
Acceptable values are eu (dd.mm.yyyy), uk (dd/mm/yyyy) and us
(mm/dd/yyyy) (Default).
- -Dcmd
- Specifies command to executed when an date is selected from an associated dropdown date selector.
When specified for a date selector grid the command is associated with all date selector widgets
in the grid. Alias -datecommand.
- -dcmd
- Specifies command to executed when an item is selected from an associated dropdown list.
When specified for a dropdown/widget grid the command is associated with all dropdown widgets
in the grid. Alias -dropdowncommand.
- -dropdowncommand
- Specifies command to executed when an item is selected from an associated dropdown list.
When specified for a dropdown/widget grid the command is associated with all dropdown widgets
in the grid. Alias -dcmd.
- -ecmd
- Specifies command to executed, or event to be generated, when the enter/return key is pressed in
an associated entry widget. When specified for a entry/widget grid the command/event is associated with
all entry widgets in the grid. Alias -entrycommand.
- -entrycommand
- Specifies command to executed, or event to be generated, when the enter/return key is pressed in
an associated entry widget. When specified for a entry/widget grid the command/event is associated with
all entry widgets in the grid. Alias -ecmd.
- -errormessage
- Specifies a text string to be used as field validation error message text. A percent
("%") substitution can be used to include the validation text.
- -fileicon
- Specifies the default ICONS
package icon name to be used for tree "File" nodes.
- -fixed
- Specifies the maximum number of characters an entry widget will accept (Default 999999
characters). If the number of characters is set to null, the value will be taken from the width
of the entry widget.
- -foldericon
- Specifies the default ICONS
package icon name to be used for tree "Folder" nodes.
- -font
- Specifies the font to use when drawing text inside the text widget. This option
is ignored if the -tags option is set to "1".
- -foreground
- Specifies the foreground color.
- -group
- Specifies a text string to identify a state group. When creating grid widgets
this identifies to group to which the widgets belong. When using the set mode
this identfies the group of widgets which will be set to the specified -state.
- -height
- Specifies height (in lines) of tablelist or text item (Default: 10).
- -icon
- Specifies the default ICONS
package icon name to be used when ":" is used alone.
- -iconfile
- Specifies the ICONS
package icon library file name to be used (Default: tkIcons).
- -iconpath
- Specifies the path to the ICONS
package icon library file. (Default: [info library] -or [file join $::starkit::topdir lib]
if the "::starkit::" namespace exists).
- -icons
- Determines whether the Tree nodes display icons. A value of 0 means that the Tree will
not display icons. 1 (Default) means that the Tree will display icons.
- -in
- Specifies the name of a container in which to put the window. The default is for the window to
be created as a normal (managed) toplevel window.
- -insertexpr
- Specifies an expression to be executed for each line inserted into a tablelist.
If the expression evaluates to "true", the options specified by -insertoptions
are applied to the line. The expression must be in the format expected by the if
command. A percent subsitution facility is available to refer to column values in the
line. The column values are indexed from zero, for example, %1 is the second column.
- -insertoptions
- Specifies a list of tablelist options to be applied if -insertexpr evaluates to true.
If the column ID for the option is set to "*" then the option is applied to all columns
(in effect the whole line).
- -justify
- Specifies text label justify (Default: left).
- -labelanchor
- Specifies where to place the label. Allowed values are (clockwise from the top upper left corner):
nw, n, ne, en, e, es, se, s, sw, ws, w and wn. The default value is theme-dependent.
- -labelcolor
- Specifies the foreground color for both labels in a gridplus cell. The color for
the left and right labels are separated by a "/". Either may be null, in which
case the default color (black) is used.
- -labelstyle
- Specifies the label text style (bold or italic) for both labels in a
gridplus cell. The style for the left and right labels are separated by a "/".
Either may be null, in which case the default label text style is used. The label styles
may be a comma delimited list (Example: bold/bold,italic. If the style is to also
specify the font size (which must be an integer), the font size must appear first in the
list (Example: 12/12,bold).
- -linerelief
- Specifies the 3-D effect desired for the girdplus line. Acceptable values
are raised, sunken (Default), flat, ridge, solid, and
groove. The value indicates how the line should appear relative to its exterior;
for example, raised means the line should appear to protrude from the screen.
- -linewidth
- Specifies the width of a gridplus line (Default: 2).
- -linkcolor
- Specifies the link foreground color. The colors for "normal" and "mouseover" are
separated by a "/". Either may be null, in which case the default color (black) is used.
- -linkcursor
- Specifies the name of the mouse cursor to be displayed when the mouse pointer is over a link
(Default: arrow).
- -linkstyle
- Specifies the link style. The styles for "normal" and "mouseover" are separated by
a "/". Either may be null, in which case the default style (/underline) is used.
The "normal" and "mouseover" styles may be a comma delimited list (Example: bold/bold,underline.
If the style is to also specify the font size (which must be an integer), the font size must
appear first in the list (Example: 12/12,underline). Where the "mouseover" style is
based on the normal style, a "&" may be used (Example: 12,bold/&underline is the
same as 12,bold/12,bold,underline). The text widget supports the underline style only.
- -menu
- Specifies name of menu to pop-up when right-clicking to select a tablelist/tree item.
- -minx
- Specifies a value between 1 and 100 indicating the percentage of the initial size
of a window to which a window can be resized in the "x" direction. (Example: A value of 80
means the window can be resized in the "x" direction to 80% of its inital size).
- -miny
- Specifies a value between 1 and 100 indicating the percentage of the initial size
of a window to which a window can be resized in the "y" direction. (Example: A value of 80
means the window can be resized in the "y" direction to 80% of its inital size).
- -modal
- Determines whether the created top-level window will be modal. A value of 0 (Default)
means that window will not be modal. 1 means that the window will be modal.
- -navbar
- Determines whether the navigation bar ("navbar") is displayed for a Calendar.
A value of 0 means that the navbar is not displayed. 1 (Default) means
that the navbar is displayed.
- -navcommand
- Specifies command to executed when a Calendar navbar icon/action is invoked.
- -navselect
- Determines whether the date in the variable associated with a Calendar is automatically
selected when a navigation action displays the month/year calendar for the date. A value of 0
(Default) means that the date is not selected. 1 means that the date is selected.
- -open
- Determines whether children of a tree node should be displayed. A value of 0 (Default)
means that the children are hidden. 1 means that the children are displayed.
- -optionset
- Specfies optionset to be used. The optionset must have been previously created using
gridplus optionset.
- -overrideredirect
- Determines whether the override-redirect option is in effect.
Setting the override-redirect flag for a window causes it to be ignored by the window manager;
among other things, this means that the window will not be reparented from the root window into a
decorative frame and the user will not be able to manipulate the window using the normal window
manager mechanisms.
- -pad
- Specifies a non-negative value indicating how much extra space to request for
grids/layouts in both the X and Y directions. When computing how large a window it needs,
the widget will add this amount to the height and width it would normally need (as
determined by the width and height of the things displayed in the grid/layout); if
the geometry manager can satisfy this request, the grid/layout will end up with extra
internal space to the left and/or right, top and/or bottom of what it displays inside.
- -padding
- Specifies the amount of extra space to allocate for the widget. The padding is a list of
up to four length specifications left top right bottom. If fewer than four elements are
specified, bottom defaults to top, right defaults to left, and
top defaults to left.
- -padx
- Specifies a non-negative value indicating how much extra space to request for
grids/layouts in the X-direction. When computing how large a window it needs,
the widget will add this amount to the width it would normally need (as determined by
the width of the things displayed in the grid/layout); if the geometry manager can
satisfy this request, the grid/layout will end up with extra internal space to the
left and/or right of what it displays inside.
- -pady
- Specifies a non-negative value indicating how much extra space to request for
grids/layouts in the Y-direction. When computing how large a window it needs,
the widget will add this amount to the height it would normally need (as determined by
the width of the things displayed in the grid/layout); if the geometry manager can
satisfy this request, the grid/layout will end up with extra internal space to the
top and/or bottom of what it displays inside.
- -pattern
- Specifies a regular expression -or- procedure to be associated with a validation.
To specify a procedure use the proc:procname format.
- -prefix
- Specifies a prefix to be used to the GRIDPLUS generated callback/procedure names.
(Example: if the prefix is set to "myprefix" and the procedure name would
normally be "toolbar,save", the procedure name will be "myprefix:toolbar,save".
- -proc
- Determines whether gpProc will be invoked for a button/menu action rather than
a widget specific procedure. A value of 0 means that the widget specific procedure
should be invoked (Default). 1 means that gpProc should be invoked.
- -radiobuttoncommand
- Specifies command to executed when an associated radiobutton is selected.
Alias -rcmd.
- -rcmd
- Specifies command to executed when an associated radiobutton is selected.
Alias -radiobuttoncommand.
- -relief
- Specifies the 3-D effect desired for the gird/layout border. Acceptable values
are raised, sunken, flat (Default), ridge, solid, groove
and theme. The value indicates how the interior of the grid/layout should appear relative
to its exterior; for example, raised means the interior of the grid/layout should appear
to protrude from the screen, relative to the exterior of the grid/layout. When set to theme
the Tile theme style is used.
- -resize
- Specfies in which directions a window can be resized. Acceptable values are x,
y and xy. By default a window cannot be resized.
- -scroll
- Specfies whether the (tablelist or text) item should have scrollbars. Acceptable values
are x, y and xy. The value indicates which scrollbars should be used,
x (horizontal) and/or y (vertical).
- -selectfirst
- Determines whether the first line of a tablelist will be automatically selected when
the tablelist content is updated using gpset. A value of 0 (Default)
means that the first line will not be selected. 1 means that the first line will
be selected.
- -selectmode
- Specifies one of several styles for manipulating the selection. Acceptable values are
single, browse (Default), multiple, or extended.
- -selectonly
- Specifies that only the selection should be cleared (not the value) when specifying
a null ("{}") value when selecting/seting a calendar page/value using either gpselect
or gpset.
- -selecttoday
- Determines whether "today's" date is automatically selected when a Calendar is created.
If -date is also specified, this date is selected.
A value of 0 (Default) means that "today" will not be selected. 1 means that
"today" will be selected.
- -show
- Specifies a list containing zero or more of the following values, specifying which elements
of the tree to display. Acceptable values are tree (Display tree labels in column #0),
headings (Display the heading row). The default is tree headings.
- -sortfirst
- Determines whether the tablelist contents will be automatically sorted on the first
column when the tablelist content is updated using gpset. A value of 0 (Default)
means that the tablelist will not be sorted. 1 means that the tablelist will
be sorted.
- -sortorder
- Specifies the default order for tablelist sort when the tablelist content is updated using
gpset. Acceptable values are increasing (Default) and decreasing.
- -space
- Specifies a non-negative value indicating how much extra space to request for
between columns in grids/layouts (Default: 20).
- -spacestretch
- Specifies, on a per-link basis, whether the link between columns, or column and grid edge, can stretch.
The format is specifed as a list. Each item in the list is applied to the corresponding link in the grid. Each
element is a boolean value. A value of 0 means the link will not stretch (is "fixed"). 1 means the
link will stretch. The default value for format is "null" means that the edge links are fixed and the links between
columns stretch. If a single element is specified then all spaces will take that value. Otherwise, the first element
is the link between the left edge of the grid and the first column, the last element is the link between the last
column and the right edge of the grid. The number of elements in the list must match the number of links in a row.
The minimum number of elements is 2 (left and right edges) for a single column row. (Example: {0 0 1 0},
There are three columns. The link between the the first column and the left edge is fixed. The link betwen the first
and second columns is fixed. The link between the second and third columns can stretch. The link between the third
column and the right edge is fixed.
- -state
- Specifies the state which grid widgets will be created/set to. Acceptable values are
normal (Default) and disabled.
- -sticky
- Specifies where in the container that the contents will be "attached". Valid values for this
option are n, s, e, w (and combinations thereof) and "null" (Default).
- -stretch
- Specifies, on a per-column basis, whether the content of columns can stretch during resizing. The format is
specifed as a list. Each item in the list is the number identifying a column which is to stretch. The first column
is 0, the second 1, and so on. By default the content of columns cannot stretch.
- -style
- Specfies Tile style to be used. If there is an optionset with the same name as the
style, it will also be applied.
- -subst
- Determines whether null array variable substitution will be performed. A value of
0 means that subsitution is not performed. 1 means that substitution will
be performed (Default).
- -tableoptions
- Specifies a list of tablelist options. Acceptable values are stripe and separator.
- -taborder
- Specifies the primary direction of keyboard traversal (e.g., Tab and Shift-Tab) of
grid widgets. Acceptable values are column (Default) and row.
- -tags
- Determines whether the text widget will have tag processing enabled.
A value of 0 (Default) means that tag processing is not enabled. 1 means that tag
processing is enabled.
- -takefocus
- Determines whether the grid widgets accept the focus during keyboard traversal
(e.g., Tab and Shift-Tab). Before setting the focus to a window, the traversal scripts
consult the value of the takeFocus option. A value of 0 means that the grid widgets should
be skipped entirely during keyboard traversal. 1 means that the grid widgets should receive
the input focus.
- -text
- Specifies the text to be associated with a validation pattern.
- -title
- Specifies a string of text to be used as a border title. When this option is specified
the value of -relief is automatically set to theme (Use style defined for
Tile labelframe).
- -topmost
- Determines whether the created top-level window will be a "topmost" (stay on top) window.
A value of 0 (Default) means that window will not be topmost. 1 means that the
window will be topmost.
- -validate
- Determines whether entry validation will be performed when a Tablelist/Tree row/node is selected.
A value of 0 (Default) means that validation processing is not enabled. 1 means that
validation processing is enabled.
- -validateauto
- Determines whether entry validation will be performed automatically when an entry looses focus.
A value of 0 means that validations are performed only when explicity invoked. 1 (Default) means that
validations are performed automatically when an entry looses focus.
- -validatepopup
- Determines whether entry validation popup error messages are to be displayed. A value of 0
(Default) means that validation popups are not enabled. 1 means that validation popups are enabled.
- -validation
- Specifies the name of an entry field validation.
- -variable
- Specifies a the name of the variable to contain the selected date for a Calendar. By default, the
"null" array is used.
- -variables
- Determines whether the gridplus item variables are cleared when using the gridplus
clear command. A value of 1 (Default) means that the variables will be
cleared. 0 means that the variables will not be cleared.
- -wcmd
- Specifies command to executed when associated top-level window is closed/destroyed (Default:
gridplus clear and destroy the window).
Alias -windowcommand.
- -weekstart
- Specifies the starting day of the week for a Calendar. A value of 0 means "Sunday".
1 (Default) means "Monday".
- -widget
- Specifies the default widget type for the grid. Acceptable values are b (Button),
c (Checkbutton), d (Dropdown "combobox"), e (Entry), l (Link),
m (Menubutton), r (Radiobutton), w (Widget grid). Whole words can be specified
as only the first character is used. For example: "radiobutton" could be used instead of "r". By default
label widgets are created.
- -width
- Specifies width of button and entry widgets (Default 10 characters), tablelist and text widgets
(Default: 40 characters), tree widget (Default: 200 pixels).
- -windowcommand
- Specifies command to executed when associated top-level window is closed/destroyed (Default:
gridplus clear and destroy the window). Alias -wcmd.
- -wrap
- Specifies how to handle lines in the text that are too long to be displayed in a single
line of the text's window. Acceptable values are none, char or word. A
wrap mode of none means that each line of text appears as exactly one line on the screen;
extra characters that don't fit on the screen are not displayed. In the other modes each line of
text will be broken up into several screen lines if necessary to keep all the characters visible.
In char mode a screen line break may occur after any character; in word mode a line
break will only be made at word boundaries.
- -wraplength
- Specifies length at which to wrap text labels. By default no wrapping occurs.
- -wtitle
- Specifies a string of text to be used as a window title.
- &type
- The type of the widget (Example: &e). Acceptable values are b (Button),
c (Checkbutton), d (Dropdown "combobox"), D (Dropdown "date selector"), e (Entry),
l (Link), m (Menubutton), r (Radiobutton), w (Embedded Widget grid),
wc (Embedded Checkbutton grid), wd (Embedded Dropdown grid),
we (Embedded Entry grid), wl (Embedded Link grid),
wm (Embedded Menubutton grid), wr (Embedded Radiobutton grid).
- &type:style/optionset
- As above but with specified style/optionset.
- .name
- The name of the widget (Example: .b1).
- .proc=parameter
- The name of the widget. This is an optional way to define a widget name for buttons.
Using the example: .myproc=myparameter, the widget will be called ".myproc=myparameter",
the procedure called when the button is pressed will be "myproc" to which will be passed a parameter,
in this case "myparameter".
- :icon
- The name of the icon to be used for button (button) -or node (tree) (Example: :navback16).
The icon name can also be null (button), in which case the icon specified by the -icon
option is used.
- %group
- The name of the group to which widget belongs (Example: %mygroup1).
- <
- Create widget with disabled state. Overrides -state option.
- <group
- Specifies that widgets belonging to group will have state set to "disabled" when the
widget content is modified.
- >
- Create widget with normal state. Overrides -state option.
- >group
- Specifies that widgets belonging to group will have state set to "normal" when the
widget content is modified.
- @name
- Insert specfied grid/layout/widget (Example: @myoptions).
- ?helptext
- Specifies text to be used for widget pop-up/balloon help (Example: ?Print).
If the text contains spaces double quotes must be used (Example: "?Exit Application").
- ?!
- Specifies text to be used for widget pop-up/balloon help is set to be the same as the validation
error message.
- !
- Indicates that entry validations are to be perfomed (for the window containing the button/link/menu)
prior to evaluating the command.
- !+
- Indicates that entry validations are to be perfomed (for the window containing the button) prior to
evaluating the command. Additionally, if an entry loses focus to the button, the validation for the entry
losing focus will be performed first.
- !name
- Specifies name of validation to be used for entry (Example: !int).
- !name?message
- Specifies name of validation to be used for entry and the validation error message to be
displayed if the validation fails (Example: "!date?Must be a valid date").
- !@name
- Specifies name of validation to be used for entry. This format (prefixed "!@") indicates
that the entry may also be null. (Example: !@int - The value of the entry must be an
integer or may be left blank)
- !@name?message
- Specifies name of validation to be used for entry and the validation error message to be
displayed if the validation fails (Example: "!@date?Must be a valid date" - The value
of the entry must be a valid date or may be left blank).
- |
- Specifies that a vertical bar separator be created.
- =
- Specifies that a horizontal bar separator be created.
- +value
- Specifies that the widget should be created in selected mode (checkbutton/radiobutton) -or-
have focus (entry) -or- the dropdown list should be set to the specified list (dropdown) -or-
a "bullet" should be displayed (link) -or- the node is to be "Folder" type (tree). The use of
value is for dropdowns where the dropdown list should be set to the specified list with
the widget value set to the first item in the list -and- radiobuttons where it specifies the
value of the radiobutton Grid when this radiobutton is selected.
- -value
- Specifies that the widget should be created in deselected mode (checkbutton/radiobutton),
a separator line is displayed (menu) -or- widget is indented (link). The use of value is for
radiobuttons only an dspecifies the value of the radiobutton Grid when this radiobutton is
selected.
- *
- Specifies that the widget should display "*" for each character entered (entry).
- ~command
- Specifies that a command/event is invoked when the enter key is pressed while the widget has focus (entry),
that a command is invoked when a checkbutton/radiobutton is selected -or-
that a command is invoked when a list item is selected (dropdown). The command name is optional. If not
specified command name is based on the name of widget. This option may also be used to specify the name of
the command to be invoked for buttons and menu items.
- #style
- Specifies the style to be used when the widget is created. If "style" is "null" the default style for
the current theme is used.
- integer
- Specifies a positive integer which overrides the default size for the widget.
- integer1/integer2
- Specifies two positve integers which override the default "size" (integer1) and "fixed" number
of characters (integer2) for the entry widget. Both integer values are optional. If integer1 is not
specified the current default "size" is used for the entry. If integer2 is not specifed the fixed
number of characters is set to the same value as the specified/default "size".
- text
- Specifies text to be used as widget label. The text may also have an optional colon
(":") delimited sticky indicator: n, s, e, w (Default) or c
(Centre) (Example: "First Name:e").
In this section "grid" refers to a "GridPlus grid" and "layout" to a "GridPlus layout".
The positions of display items/widgets is defined as a combination of grid layouts and
layouts of grids.
The GridPlus grid command, and all of the GridPlus widget grid commands which are built
on the GridPlus grid, create a grid of widgets and labels. Any cell in a grid or entry
grid may contain a grid, any TK widget or a layout.
The grids are positioned using a layout. The layout is also a grid, but has different
options/properties. Any cell within a layout may contain a grid, any TK widget or another
layout.
GRID
The grid uses a relative placement facility. Each cell in the grid may have
0,1 or 2 elements. An element begining with "." is considered to be a path to a widget,
anything else is considered to be a text label. Each (non-empty) cell may contain a
combination of 1 or 2 elements. Normally this would be a widget and a text label, or a
widget only, but two widgets or labels is allowed. Each cell consists of two columns.
This allows widgets with labels to be easily created and automatically sized/lined-up
based on the size of the contents. The order in which the elements appear in the cell is
set by the order in which they are defined. The first element into the first column,
the second into the second column. If the cell contains a single element this will
span both columns. Each element may optionally have a colon (":") delimited sticky
indicator, n, s, e, w (Default) or c (Centre). A cell
with 0 elements creates an empty cell. A cell may also contain a vertical bar ("pipe"),
which will be displayed as a vertical bar separator -or- "=" which will be displayed as
a horizontal bar separator.
LAYOUT
The layout command has capabilities similar to that when using the relative
placement facility of the Tk grid widget. Each cell may optionally have a
delimited sticky indicator, n, s, e, w
(Default) or c (Centre). The sticky delimeter may be ":", "=",
"|" or "+". Normally the colon (":") delimeter is used. The other
options are available to control the grid weight for applications which have resizable
windows. Generally "=" should be used for grid cells which are to be resized horizontally,
"|" for vertical resizing and "+" for both horizontal and vertical resizing.
For text and tree items, where it is required that the item increases/decreases in size
as the widow is resized the colon (":") delimeter should be used. These rules are not absolute,
but should be used as a starting point. A cell may also contain a vertical bar ("pipe"),
which will be displayed as a vertical bar separator -or- "=" which will be displayed as a
horizontal bar separator.
- -
-
This increases the columnspan of the cell to the left. Several
-'s in a row will successively increase the columnspan. A -
may not follow a ^ or a x, nor may it be the first cell.
- x
-
This leaves an empty column between the cell on the left and
the cell on the right.
- ^
-
This extends the rowspan of the cell above the ^'s
in the grid. The number of ^'s in a row must match the number of
columns spanned by the cell above it.
The gridplus command is used to create and control TK screen layouts. It can
take several different forms, depending on the mode argument. The legal forms are:
- gridplus add name ?option value ...?
-
Adds a TK widget to a group.
- gridplus button name ?option value ...? layout
-
Creates a GRIDPLUS button grid.
layout
- Specifies the GRIDPLUS grid properties of buttons within the grid.
- gridplus calendar name ?option value ...?
-
Creates a GRIDPLUS calendar.
- gridplus checkbutton name ?option value ...? layout
-
Creates a GRIDPLUS checkbutton grid.
layout
- Specifies the GRIDPLUS grid properties of checkbuttons within the grid.
- gridplus clear ?option value ...? window
-
Clears all widgets and GRIDPLUS widget references for the specified window.
- gridplus container name ?option value ...?
-
Creates a GRIDPLUS container.
- gridplus define definitions
-
Creates GRIDPLUS widget definitions.
definitions
- Specifies the widget definitions.
- gridplus dropdown name ?option value ...? layout
-
Creates a GRIDPLUS dropdown grid.
layout
- Specifies the GRIDPLUS grid properties of dropdowns (comboboxes) within the grid.
- gridplus entry name ?option value ...? layout
-
Creates a GRIDPLUS entry grid.
layout
- Specifies the GRIDPLUS grid properties of entry fields within the grid.
- gridplus grid name ?option value ...? layout
-
Creates a GRIDPLUS grid.
layout
- Specifies the GRIDPLUS grid properties of items/widgets within the grid.
- gridplus layout name ?option value ...? layout
-
Creates a GRIDPLUS layout.
layout
- Specifies the GRIDPLUS layout properties of grids/layouts.
- gridplus link name ?option value ...? layout
-
Creates a GRIDPLUS link grid.
layout
- Specifies the GRIDPLUS grid properties of buttons within the grid.
- gridplus menu name ?option value ...? layout
-
Creates a GRIDPLUS menu.
layout
- Specifies the options.
- gridplus menubutton name ?option value ...? layout
-
Creates a GRIDPLUS menubutton grid.
layout
- Specifies the GRIDPLUS grid properties of menu buttons within the grid.
- gridplus notebook name ?option value ...? layout
-
Creates a GRIDPLUS notebook.
layout
- Specifies the names of grids/layouts within the notebook.
- gridplus optionset name options
-
Creates a GRIDPLUS Optionset.
- gridplus pack name ?option value ...?
-
Packs a GRIDPLUS layout according to the specified options.
- gridplus radiobutton name ?option value ...? layout
-
Creates a GRIDPLUS radiobutton grid.
layout
- Specifies the GRIDPLUS grid properties of radiobuttons within the grid.
- gridplus tablelist name ?option value ...? columns
-
Creates a GRIDPLUS tablelist.
columns
- Specifies the layout/options of columns within the tablelist.
- gridplus text name ?option value ...?
-
Creates a GRIDPLUS text widget.
- gridplus tree name ?option value ...?
-
Creates a GRIDPLUS tree widget.
- gridplus widget name ?option value ...? layout
-
Creates a GRIDPLUS widget grid.
layout
- Specifies the GRIDPLUS grid properties of widgets within the grid.
- gridplus window name ?option value ...?
-
Creates a toplevel window.
Copyright © 2009 Adrian Davis.