Adjuster
Balloon
Bitmap
BrowseEntry
Button
Canvas
Checkbutton
ColorEditor
Dialog
DirTree
Entry
ErrorDialog
FileSelect
Frame
HList
Label
LabEntry
LabFrame
Listbox
MainWindow
Menu
Menubutton
Message
NoteBook
Optionmenu
Pane
Photo
ProgressBar
Radiobutton
ROText
Scale
Scrollbar
Table
Text
TextUndo
Tiler
TList
Toplevel
Tree
In Chapter 13, "Miscellaneous Perl/Tk Methods" we discussed how to use the configure and cget methods on our widgets. This appendix shows the output from configure on each of the widgets we cover in this book. The program used to generate the data is as follows:
use Tk; use strict; my $mw = MainWindow->new; while (my $w = <DATA>) { next if $w =~ /^#/; chomp $w; print "\n\n====== $w\n"; my $o = $mw->$w; my(@o) = $o->configure; foreach my $opt (@o) { @$opt = map {defined($_) ? $_ : 'undef'} @$opt; printf "%s\t%s\t%s\t%s\t%s\n", @$opt; if ($$opt[4] =~ /^System/) { my ($r, $g, $b) = $mw->rgb($$opt[4]); print "$r $g $b\n"; } } } __DATA__ Adjuster Balloon Bitmap BrowseEntry Button ## ... list shortened ... Toplevel Tree
Option name |
.Xdefault's name |
Class name |
Default value |
Current value |
---|---|---|---|---|
-background |
background |
Background |
undef |
#d9d9d9 |
-bd |
borderWidth |
|||
-bg |
background |
|||
-borderwidth |
borderWidth |
BorderWidth |
0 |
0 |
-class |
class |
Class |
Frame |
Adjuster |
-colormap |
colormap |
Colormap |
undef |
|
-container |
container |
Container |
0 |
0 |
-cursor |
cursor |
Cursor |
undef |
|
-delay |
delay |
Delay |
1 |
1 |
-fg |
foreground |
|||
-foreground |
foreground |
Foreground |
black |
black |
-height |
height |
Height |
0 |
0 |
-highlightbackground |
highlightBackground |
HighlightBackground |
#d9d9d9 |
#d9d9d9 |
-highlightcolor |
highlightColor |
HighlightColor |
Black |
Black |
-highlightthickness |
highlightThickness |
HighlightThickness |
0 |
0 |
-label |
undef |
undef |
undef |
undef |
-labelPack |
undef |
undef |
undef |
|
-labelVariable |
undef |
undef |
undef |
undef |
-offset |
offset |
Offset |
0 0 |
ARRAY(0x82d6abc) |
-relief |
relief |
Relief |
flat |
flat |
-restore |
restore |
Restore |
1 |
1 |
-side |
side |
Side |
top |
top |
-takefocus |
takeFocus |
TakeFocus |
0 |
0 |
-tile |
tile |
Tile |
undef |
|
-visual |
visual |
Visual |
undef |
|
-widget |
widget |
Widget |
MainWindow=HASH(0x80f4ddc) |
MainWindow=HASH(0x80f4ddc) |
-width |
width |
Width |
0 |
0 |