Debian Codegraph @

pod/Labelframe.pod

raw
1 # Copyright (c) 1990-1994 The Regents of the University of California.
2 # Copyright (c) 1994-1996 Sun Microsystems, Inc.
3 # See the file "license.terms" for information on usage and redistribution
4 # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
5 # RCS: @(#) $Id: labelframe.n,v 1.1 2001/09/26 21:36:19 pspjuth Exp $
6
7 =head1 NAME
8
9 Tk::Labelframe - Create and manipulate Labelframe widgets
10
11 =for category Tk Generic Methods
12
13 =head1 SYNOPSIS
14
15 I<$labelframe> = I<$parent>-E<gt>B<Labelframe>(?I<options>?);
16
17 -borderwidth -highlightbackground -pady
18 -cursor -highlightcolor -relief
19 -font -highlightthickness -takefocus
20 -foreground -padx -text
21
22 =head1 WIDGET-SPECIFIC OPTIONS
23
24 =over 4
25
26 =item Option: B<-background>
27
28 =item Name: B<background>
29
30 =item Class: B<Background>
31
32 This option is the same as the standard B<background> option
33 except that its value may also be specified as an empty string.
34 In this case, the widget will display no background or border, and
35 no colors will be consumed from its colormap for its background
36 and border.
37
38 =item Option: B<-class>
39
40 =item Name: B<class>
41
42 =item Class: B<Class>
43
44 Specifies a class for the window.
45 This class will be used when querying the option database for
46 the window's other options, and it will also be used later for
47 other purposes such as bindings.
48 The B<class> option may not be changed with the B<configure>
49 method.
50
51 =item Option: B<-colormap>
52
53 =item Name: B<colormap>
54
55 =item Class: B<Colormap>
56
57 Specifies a colormap to use for the window.
58 The value may be either B<new>, in which case a new colormap is
59 created for the window and its children, or the name of another
60 window (which must be on the same screen and have the same visual
61 as $widget), in which case the new window will use the colormap
62 from the specified window.
63 If the B<colormap> option is not specified, the new window
64 uses the same colormap as its parent.
65 This option may not be changed with the B<configure>
66 method.
67
68 =item Option: B<-container>
69
70 =item Name: B<container>
71
72 =item Class: B<Container>
73
74 The value must be a boolean. If true, it means that this window will
75 be used as a container in which some other application will be embedded
76 (for example, a Tk toplevel can be embedded using the B<-use> option).
77 The window will support the appropriate window manager protocols for
78 things like geometry requests. The window should not have any
79 children of its own in this application.
80 This option may not be changed with the B<configure>
81 method.
82
83 =item Option: B<-height>
84
85 =item Name: B<height>
86
87 =item Class: B<Height>
88
89 Specifies the desired height for the window in any of the forms
90 acceptable to B<Tk_GetPixels>.
91 If this option is less than or equal to zero then the window will
92 not request any size at all.
93
94 =item Option: B<-labelanchor>
95
96 =item Name: B<labelAnchor>
97
98 =item Class: B<LabelAnchor>
99
100 Specifies where to place the label. A label is only displayed if the
101 B<-text> option is not the empty string.
102 Valid values for this option are (listing them clockwise)
103 B<nw>, B<n>, B<ne>, B<en>, B<e>, B<es>,
104 B<se>, B<s>,B<sw>, B<ws>, B<w> and B<wn>.
105 The default value is B<nw>.
106
107 =item Option: B<-labelwidget>
108
109 =item Name: B<labelWidget>
110
111 =item Class: B<LabelWidget>
112
113 Specifies a widget to use as label. This overrides any B<-text>
114 option. The widget must exist before being used as B<-labelwidget>
115 and if it is not a descendant of this window, it will be raised
116 above it in the stacking order.
117
118 =item Option: B<-visual>
119
120 =item Name: B<visual>
121
122 =item Class: B<Visual>
123
124 Specifies visual information for the new window in any of the
125 forms accepted by B<Tk_GetVisual>.
126 If this option is not specified, the new window will use the same
127 visual as its parent.
128 The B<visual> option may not be modified with the B<configure>
129 method.
130
131 =item Option: B<-width>
132
133 =item Name: B<width>
134
135 =item Class: B<Width>
136
137 Specifies the desired width for the window in any of the forms
138 acceptable to B<Tk_GetPixels>.
139 If this option is less than or equal to zero then the window will
140 not request any size at all.
141
142 =back
143
144 =head1 DESCRIPTION
145
146 The B<Labelframe> method creates a new window (given by the
147 $labelframe argument) and makes it into a Labelframe widget.
148 Additional
149 options, described above, may be specified on the command line
150 or in the option database
151 to configure aspects of the Labelframe such as its background color
152 and relief.
153
154 A Labelframe is a simple widget. Its primary purpose is to act as a
155 spacer or container for complex window layouts. It has the features
156 of a B<Frame> plus the ability to display a label.
157
158 =head1 WIDGET METHODS
159
160 The B<Labelframe> method
161 may be used to invoke various operations on the widget. It has the
162 following general form:
163
164 $widget->method(?arg arg ...?);
165
166 The following
167 methods are possible for Labelframe widgets:
168
169 =over 4
170
171 =item I<$widget>-E<gt>B<cget>(I<option>);
172
173 Returns the current value of the configuration option given
174 by I<option>.
175 I<Option> may have any of the values accepted by the B<Labelframe>
176 command.
177
178 =item I<$widget>-E<gt>B<configure>(?I<option>?, I<?value, option, value, ...>?);
179
180 Query or modify the configuration options of the widget.
181 If no I<option> is specified, returns a list describing all of
182 the available options for $widget (see L<Tk::configure> for
183 information on the format of this list). If I<option> is specified
184 with no I<value>, then the command returns a list describing the
185 one named option (this list will be identical to the corresponding
186 sublist of the value returned if no I<option> is specified). If
187 one or more I<option-value> pairs are specified, then the command
188 modifies the given widget option(s) to have the given value(s); in
189 this case the command returns an empty string.
190 I<Option> may have any of the values accepted by the B<Labelframe>
191 command.
192
193 =back
194
195 =head1 BINDINGS
196
197 When a new Labelframe is created, it has no default event bindings:
198 Labelframes are not intended to be interactive.
199
200 =head1 SEE ALSO
201
202 L<Tk::Frame>, L<Tk::Label>
203
204 =head1 KEYWORDS
205
206 Labelframe, widget