gauge%
Implements: control<%>
A gauge is a horizontal or vertical bar for displaying the output
value of a bounded integer quantity. Each gauge has an adjustable
range, and the gauge's current value is always between 0 and its
range, inclusive. Use
set-value to set the value of the gauge.
( -> instantiate gauge% () (label _) (range _) (parent _) [(style _)] [(enabled _)] [(vert-margin _)] [(horiz-margin _)] [(min-width _)] [(min-height _)] [(stretchable-width _)] [(stretchable-height _)])gauge% object
label : string (up to 200 characters) or #f
range : exact integer in [1, 10000]
parent : frame%, dialog%, panel%, or pane% object
style = : list of symbols in '(horizontal)'(horizontal vertical)
enabled = : boolean
#t
vert-margin = : exact integer in [0, 1000]
2
horiz-margin = : exact integer in [0, 1000]
2
min-width = : exact integer in [0, 10000]
0
min-height = : exact integer in [0, 10000]
0
stretchable-width = : boolean
#t for 'horizontal style, #f for 'vertical
stretchable-height = : boolean#t for 'vertical style, #f for 'horizontal
If label is a string, it is used as the gauge label; otherwise
the gauge does not display a label.
If an ampersand (``&'') occurs in
label, it is specially parsed; under Windows and X, the character
following an ampersand is underlined in the displayed control to
indicate a keyboard mnemonic. (Under Mac OS, mnemonic underlines are
not shown.) The mnemonic is meaningless for a gauge (as far as
on-traverse-char is concerned),
but it is supported for consistentcy with other control types. A
programmer may assign a meaning to the mneumonic, e.g., by overriding
on-traverse-char.
The range argument is an integer specifying the maximum value of
the gauge (inclusive). The minimum gauge value is always 0.
The style list must include either 'horizontal,
specifying a horizontal gauge, or 'vertical, specifying
a vertical gauge.
For information about the
enabled
argument, see window<%>. For information about the
horiz-margin and vert-margin
arguments, see subarea<%>. For information about the
min-width, min-height, stretchable-width, and stretchable-height
arguments, see area<%>.
Methods
get-range
get-value
set-range
set-value
All Methods
accept-drop-files from window<%>
client->screen from window<%>
command from control<%>
enable from window<%>
focus from window<%>
get-client-size from window<%>
get-cursor from window<%>
get-graphical-min-size from area<%>
get-height from window<%>
get-label from window<%>
get-parent from area<%>
get-plain-label from window<%>
get-range from gauge%
get-size from window<%>
get-top-level-window from area<%>
get-value from gauge%
get-width from window<%>
get-x from window<%>
get-y from window<%>
has-focus? from window<%>
horiz-margin from subarea<%>
is-enabled? from window<%>
is-shown? from window<%>
min-height from area<%>
min-width from area<%>
on-drop-file from window<%>
on-focus from window<%>
on-move from window<%>
on-size from window<%>
on-subwindow-char from window<%>
on-subwindow-event from window<%>
on-superwindow-enable from window<%>
on-superwindow-show from window<%>
popup-menu from window<%>
refresh from window<%>
screen->client from window<%>
set-cursor from window<%>
set-label from window<%>
set-range from gauge%
set-value from gauge%
show from window<%>
stretchable-height from area<%>
stretchable-width from area<%>
vert-margin from subarea<%>