Manual Pages for UNIX Darwin command on man iwidgets_buttonbox
MyWebUniversity

Manual Pages for UNIX Darwin command on man iwidgets_buttonbox

iwidgets::buttonbox(1) [incr Widgets] iwidgets::buttonbox(1)

NAME

iwidgets::buttonbox - Create and manipulate a manager widget for but-

tons

SYNOPSIS

iiwwiiddggeettss::::bbuuttttoonnbbooxx pathName ?options? IINNHHEERRIITTAANNCCEE

itk::Widget <- iwidgets::buttonbox

SSTTAANNDDAARRDD OOPPTTIIOONNSS bbaacckkggrroouunndd ccuurrssoorr See the "options" manual entry for details on the standard options.

WWIIDDGGEETT-SSPPEECCIIFFIICC OOPPTTIIOONNSS

Name: oorriieenntt Class: OOrriieenntt

Command-Line Switch: -oorriieenntt

Orientation of the button box: hhoorriizzoonnttaall or vveerrttiiccaall. The default is horizontal. Name: ppaaddXX Class: PPaaddXX

Command-Line Switch: -ppaaddxx

Specifies a non-negative padding distance to leave between the

button group and the outer edge of the button box in the x

direction. The value may be given in any of the forms accept-

able to TTkkGGeettPPiixxeellss. The default is 5 pixels. Name: ppaaddYY Class: PPaaddYY

Command-Line Switch: -ppaaddyy

Specifies a non-negative padding distance to leave between the

button group and the outer edge of the button box in the y

direction. The value may be given in any of the forms accept-

able to TTkkGGeettPPiixxeellss. The default is 5 pixels.

DESCRIPTION

The iiwwiiddggeettss::::bbuuttttoonnbbooxx command creates a manager widget for control-

ling buttons. The button box also supports the display and invocation

of a default button. The button box can be configured either horizon-

tally or vertically. MMEETTHHOODDSS The iiwwiiddggeettss::::bbuuttttoonnbbooxx command creates a new Tcl command whose name is pathName. This command may be used to invoke various operations on the widget. It has the following general form: pathName option ?arg arg ...? Option and the args determine the exact behavior of the command. Many of the widget commands for the buttonbox take as one argument an

indicator of which button of the button box to operate on. These indi-

cators are called indexes and allow reference and manipulation of but-

tons regardless of their current map state. buttonbox indexes may be specified in any of the following forms: number Specifies the button numerically, where 0 corresponds to

the left/top-most button of the button box.

eenndd Indicates the right/bottom-most button of the button box.

ddeeffaauulltt Indicates the current default button of the button box. This is the button with the default ring displayed. pattern If the index doesn't satisfy one of the above forms then

this form is used. Pattern is pattern-matched against the

tag of each button in the button box, in order from left/top to right/left, until a matching entry is found. The rules of TTccllSSttrriinnggMMaattcchh are used.

WWIIDDGGEETT-SSPPEECCIIFFIICC MMEETTHHOODDSS

pathName aadddd tag args Add a button distinguished by tag to the end of the button box. If additional arguments are present they specify options to be applied to the button. See PPuusshhBBuuttttoonn for information on the options available. pathName bbuuttttoonnccoonnffiigguurree index ?options? This command is similar to the ccoonnffiigguurree command, except that it

applies to the options for an individual button, whereas ccoonnffiigg-

uurree applies to the options for the button box as a whole. Options may have any of the values accepted by the PPuusshhBBuuttttoonn command. If options are specified, options are modified as indicated in the command and the command returns an empty string. If no options are specified, returns a list describing the current options for entry index (see TTkkCCoonnffiigguurreeIInnffoo for information on the format of this list). pathName ccggeett option Returns the current value of the configuration option given by

option. Option may have any of the values accepted by the iiwwiidd-

ggeettss::::bbuuttttoonnbbooxx command. pathName ccoonnffiigguurree ?option? ?value option value ...? Query or modify the configuration options of the widget. If no

option is specified, returns a list describing all of the avail-

able options for pathName (see TTkkCCoonnffiigguurreeIInnffoo for information on the format of this list). If option is specified with no value, then the command returns a list describing the one named option (this list will be identical to the corresponding sublist of the value returned if no option is specified). If one or

more option-value pairs are specified, then the command modifies

the given widget option(s) to have the given value(s); in this case the command returns an empty string. Option may have any of the values accepted by the iiwwiiddggeettss::::bbuuttttoonnbbooxx command. pathName ddeeffaauulltt index Sets the default button to the button given by index. This causes the default ring to appear arround the specified button. pathName ddeelleettee index Deletes the button given by index from the button box. pathName hhiiddee index

Hides the button denoted by index. This doesn't remove the but-

ton permanently, just inhibits its display. pathName iinnddeexx index Returns the numerical index corresponding to index. pathName iinnsseerrtt index tag ?option value option value ...? Same as the aadddd command except that it inserts the new button just before the one given by index, instead of appending to the end of the button box. The option, and value arguments have the same interpretation as for the aadddd widget command. pathName iinnvvookkee ?index? Invoke the command associated with a button. If no arguments are given then the current default button is invoked, otherwise the argument is expected to be a button index. pathName sshhooww index Display a previously hidden button denoted by index. EEXXAAMMPPLLEE package require Iwidgets 4.0 iwidgets::buttonbox .bb

.bb add Yes -text Yes -command "puts Yes"

.bb add No -text No -command "puts No"

.bb add Maybe -text Maybe -command "puts Maybe"

.bb default Yes

pack .bb -expand yes -fill both

AUTHOR Bret A. Schuhmacher Mark L. Ulferts KKEEYYWWOORRDDSS buttonbox, pushbutton, button, widget Tk iwidgets::buttonbox(1)




Contact us      |      About us      |      Term of use      |       Copyright © 2000-2019 MyWebUniversity.com ™