diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2011-07-18 15:25:38 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2011-07-18 15:25:38 (GMT) |
commit | 3f2d88f748a15d841268e06fd684a17058e63f02 (patch) | |
tree | cec1bcb89b7f64d9fd6750a9fe013c99cd23bfef /doc/button.n | |
parent | b390d733d5dfb03cc7146d7195a5efa8e137722b (diff) | |
download | tk-3f2d88f748a15d841268e06fd684a17058e63f02.zip tk-3f2d88f748a15d841268e06fd684a17058e63f02.tar.gz tk-3f2d88f748a15d841268e06fd684a17058e63f02.tar.bz2 |
More small documentation improvements.
Diffstat (limited to 'doc/button.n')
-rw-r--r-- | doc/button.n | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/doc/button.n b/doc/button.n index d568246..d4f1af3 100644 --- a/doc/button.n +++ b/doc/button.n @@ -57,14 +57,14 @@ The empty string is the default value. .OP \-state state State Specifies one of three states for the button: \fBnormal\fR, \fBactive\fR, or \fBdisabled\fR. In normal state the button is displayed using the -\fBforeground\fR and \fBbackground\fR options. The active state is +\fB\-foreground\fR and \fB\-background\fR options. The active state is typically used when the pointer is over the button. In active state -the button is displayed using the \fBactiveForeground\fR and -\fBactiveBackground\fR options. Disabled state means that the button +the button is displayed using the \fB\-activeforeground\fR and +\fB\-activebackground\fR options. Disabled state means that the button should be insensitive: the default bindings will refuse to activate the widget and will ignore mouse button presses. -In this state the \fBdisabledForeground\fR and -\fBbackground\fR options determine how the button is displayed. +In this state the \fB\-disabledforeground\fR and +\fB\-background\fR options determine how the button is displayed. .OP \-width width Width Specifies a desired width for the button. If an image or bitmap is being displayed in the button then the value is in @@ -91,12 +91,12 @@ there must not exist a window named \fIpathName\fR, but A button is a widget that displays a textual string, bitmap or image. If text is displayed, it must all be in a single font, but it can occupy multiple lines on the screen (if it contains newlines -or if wrapping occurs because of the \fBwrapLength\fR option) and +or if wrapping occurs because of the \fB\-wraplength\fR option) and one of the characters may optionally be underlined using the -\fBunderline\fR option. +\fB\-underline\fR option. It can display itself in either of three different ways, according to -the \fBstate\fR option; +the \fB\-state\fR option; it can be made to appear raised, sunken, or flat; and it can be made to flash. When a user invokes the button (by pressing mouse button 1 with the cursor over the @@ -188,18 +188,18 @@ This is the classic Tk demonstration: .PP .CS - \fBbutton\fR .b \-text "Hello, World!" \-command exit - pack .b +\fBbutton\fR .b \-text "Hello, World!" \-command exit +pack .b .CE .PP This example demonstrates how to handle button accelerators: .PP .CS - \fBbutton\fR .b1 \-text Hello \-underline 0 - \fBbutton\fR .b2 \-text World \-underline 0 - bind . <Key\-h> {.b1 flash; .b1 invoke} - bind . <Key\-w> {.b2 flash; .b2 invoke} - pack .b1 .b2 +\fBbutton\fR .b1 \-text Hello \-underline 0 +\fBbutton\fR .b2 \-text World \-underline 0 +bind . <Key\-h> {.b1 flash; .b1 invoke} +bind . <Key\-w> {.b2 flash; .b2 invoke} +pack .b1 .b2 .CE .SH "SEE ALSO" ttk::button(n) |