| 1 |
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| 2 |
<html> |
| 3 |
<!-- Created by GNU Texinfo 6.7, http://www.gnu.org/software/texinfo/ --> |
| 4 |
<head> |
| 5 |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> |
| 6 |
<title>options (GCL TK Manual)</title> |
| 7 |
|
| 8 |
<meta name="description" content="options (GCL TK Manual)"> |
| 9 |
<meta name="keywords" content="options (GCL TK Manual)"> |
| 10 |
<meta name="resource-type" content="document"> |
| 11 |
<meta name="distribution" content="global"> |
| 12 |
<meta name="Generator" content="makeinfo"> |
| 13 |
<link href="index.html" rel="start" title="Top"> |
| 14 |
<link href="wm.html#SEC_Contents" rel="contents" title="Table of Contents"> |
| 15 |
<link href="Control.html" rel="up" title="Control"> |
| 16 |
<link href="pack_002dold.html" rel="next" title="pack-old"> |
| 17 |
<link href="option.html" rel="prev" title="option"> |
| 18 |
<style type="text/css"> |
| 19 |
<!-- |
| 20 |
a.summary-letter {text-decoration: none} |
| 21 |
blockquote.indentedblock {margin-right: 0em} |
| 22 |
div.display {margin-left: 3.2em} |
| 23 |
div.example {margin-left: 3.2em} |
| 24 |
div.lisp {margin-left: 3.2em} |
| 25 |
kbd {font-style: oblique} |
| 26 |
pre.display {font-family: inherit} |
| 27 |
pre.format {font-family: inherit} |
| 28 |
pre.menu-comment {font-family: serif} |
| 29 |
pre.menu-preformatted {font-family: serif} |
| 30 |
span.nolinebreak {white-space: nowrap} |
| 31 |
span.roman {font-family: initial; font-weight: normal} |
| 32 |
span.sansserif {font-family: sans-serif; font-weight: normal} |
| 33 |
ul.no-bullet {list-style: none} |
| 34 |
--> |
| 35 |
</style> |
| 36 |
|
| 37 |
|
| 38 |
</head> |
| 39 |
|
| 40 |
<body lang="en"> |
| 41 |
<span id="options"></span><div class="header"> |
| 42 |
<p> |
| 43 |
Next: <a href="pack_002dold.html" accesskey="n" rel="next">pack-old</a>, Previous: <a href="option.html" accesskey="p" rel="prev">option</a>, Up: <a href="Control.html" accesskey="u" rel="up">Control</a> [<a href="wm.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p> |
| 44 |
</div> |
| 45 |
<hr> |
| 46 |
<span id="options-1"></span><h3 class="section">3.12 options</h3> |
| 47 |
|
| 48 |
<p>options \- Standard options supported by widgets |
| 49 |
</p> |
| 50 |
<span id="Description-23"></span><h4 class="unnumberedsubsec">Description</h4> |
| 51 |
<p>This manual entry describes the common configuration options supported |
| 52 |
by widgets in the Tk toolkit. Every widget does not necessarily support |
| 53 |
every option (see the manual entries for individual widgets for a list |
| 54 |
of the standard options supported by that widget), but if a widget does |
| 55 |
support an option with one of the names listed below, then the option |
| 56 |
has exactly the effect described below. |
| 57 |
</p> |
| 58 |
<p>In the descriptions below, |
| 59 |
“Name” refers to the option’s name in the option database (e.g. |
| 60 |
in .Xdefaults files). “Class” refers to the option’s class value |
| 61 |
in the option database. “Command-Line Switch” refers to the |
| 62 |
switch used in widget-creation and <b>configure</b> widget commands to |
| 63 |
set this value. For example, if an option’s command-line switch is |
| 64 |
<b>:foreground</b><span class="roman"> and there exists a widget </span><b>.a.b.c</b>, then the |
| 65 |
command |
| 66 |
</p> |
| 67 |
<div class="example"> |
| 68 |
<pre class="example"> |
| 69 |
|
| 70 |
(.a.b.c :configure :foreground "black")<!-- /@w --> |
| 71 |
</pre></div> |
| 72 |
|
| 73 |
<p>may be used to specify the value <b>black</b> for the option in the |
| 74 |
the widget <b>.a.b.c</b>. Command-line switches may be abbreviated, |
| 75 |
as long as the abbreviation is unambiguous. |
| 76 |
</p> |
| 77 |
|
| 78 |
<dl compact="compact"> |
| 79 |
<dt><code><b>:activebackground</b></code></dt> |
| 80 |
<dd><p align="right">Name=<code>"<b>activeBackground</b><span class="roman">"</span> Class=<code>"</code><b>Foreground</b>"</code> |
| 81 |
</p><br> |
| 82 |
|
| 83 |
<p>Specifies background color to use when drawing active elements. |
| 84 |
An element (a widget or portion of a widget) is active if the |
| 85 |
mouse cursor is positioned over the element and pressing a mouse button |
| 86 |
will cause some action to occur. |
| 87 |
</p></dd> |
| 88 |
</dl> |
| 89 |
|
| 90 |
|
| 91 |
<dl compact="compact"> |
| 92 |
<dt><code><b>:activeborderwidth</b></code></dt> |
| 93 |
<dd><p align="right">Name=<code>"<b>activeBorderWidth</b><span class="roman">"</span> Class=<code>"</code><b>BorderWidth</b>"</code> |
| 94 |
</p><br> |
| 95 |
|
| 96 |
<p>Specifies a non-negative value indicating |
| 97 |
the width of the 3-D border drawn around active elements. See above for |
| 98 |
definition of active elements. |
| 99 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 100 |
This option is typically only available in widgets displaying more |
| 101 |
than one element at a time (e.g. menus but not buttons). |
| 102 |
</p></dd> |
| 103 |
</dl> |
| 104 |
|
| 105 |
|
| 106 |
<dl compact="compact"> |
| 107 |
<dt><code><b>:activeforeground</b></code></dt> |
| 108 |
<dd><p align="right">Name=<code>"<b>activeForeground</b><span class="roman">"</span> Class=<code>"</code><b>Background</b>"</code> |
| 109 |
</p><br> |
| 110 |
|
| 111 |
<p>Specifies foreground color to use when drawing active elements. |
| 112 |
See above for definition of active elements. |
| 113 |
</p></dd> |
| 114 |
</dl> |
| 115 |
|
| 116 |
|
| 117 |
<dl compact="compact"> |
| 118 |
<dt><code><b>:anchor</b></code></dt> |
| 119 |
<dd><p align="right">Name=<code>"<b>anchor</b><span class="roman">"</span> Class=<code>"</code><b>Anchor</b>"</code> |
| 120 |
</p><br> |
| 121 |
|
| 122 |
<p>Specifies how the information in a widget (e.g. text or a bitmap) |
| 123 |
is to be displayed in the widget. |
| 124 |
Must be one of the values <b>n</b><span class="roman">, </span><b>ne</b><span class="roman">, </span><b>e</b><span class="roman">, </span><b>se</b>, |
| 125 |
<b>s</b><span class="roman">, </span><b>sw</b><span class="roman">, </span><b>w</b><span class="roman">, </span><b>nw</b><span class="roman">, or </span><b>center</b>. |
| 126 |
For example, <b>nw</b> means display the information such that its |
| 127 |
top-left corner is at the top-left corner of the widget. |
| 128 |
</p></dd> |
| 129 |
</dl> |
| 130 |
|
| 131 |
|
| 132 |
<dl compact="compact"> |
| 133 |
<dt><code><b>:background or :bg</b></code></dt> |
| 134 |
<dd><p align="right">Name=<code>"<b>background</b><span class="roman">"</span> Class=<code>"</code><b>Background</b>"</code> |
| 135 |
</p><br> |
| 136 |
|
| 137 |
<p>Specifies the normal background color to use when displaying the |
| 138 |
widget. |
| 139 |
</p></dd> |
| 140 |
</dl> |
| 141 |
|
| 142 |
|
| 143 |
<dl compact="compact"> |
| 144 |
<dt><code><b>:bitmap</b></code></dt> |
| 145 |
<dd><p align="right">Name=<code>"<b>bitmap</b><span class="roman">"</span> Class=<code>"</code><b>Bitmap</b>"</code> |
| 146 |
</p><br> |
| 147 |
|
| 148 |
<p>Specifies a bitmap to display in the widget, in any of the forms |
| 149 |
acceptable to <b>Tk_GetBitmap</b>. |
| 150 |
The exact way in which the bitmap is displayed may be affected by |
| 151 |
other options such as <b>anchor</b><span class="roman"> or </span><b>justify</b>. |
| 152 |
Typically, if this option is specified then it overrides other |
| 153 |
options that specify a textual value to display in the widget; |
| 154 |
the <b>bitmap</b> option may be reset to an empty string to re-enable |
| 155 |
a text display. |
| 156 |
</p></dd> |
| 157 |
</dl> |
| 158 |
|
| 159 |
|
| 160 |
<dl compact="compact"> |
| 161 |
<dt><code><b>:borderwidth or :bd</b></code></dt> |
| 162 |
<dd><p align="right">Name=<code>"<b>borderWidth</b><span class="roman">"</span> Class=<code>"</code><b>BorderWidth</b>"</code> |
| 163 |
</p><br> |
| 164 |
|
| 165 |
<p>Specifies a non-negative value indicating the width |
| 166 |
of the 3-D border to draw around the outside of the widget (if such a |
| 167 |
border is being drawn; the <b>relief</b> option typically determines |
| 168 |
this). The value may also be used when drawing 3-D effects in the |
| 169 |
interior of the widget. |
| 170 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 171 |
</p></dd> |
| 172 |
</dl> |
| 173 |
|
| 174 |
|
| 175 |
<dl compact="compact"> |
| 176 |
<dt><code><b>:cursor</b></code></dt> |
| 177 |
<dd><p align="right">Name=<code>"<b>cursor</b><span class="roman">"</span> Class=<code>"</code><b>Cursor</b>"</code> |
| 178 |
</p><br> |
| 179 |
|
| 180 |
<p>Specifies the mouse cursor to be used for the widget. |
| 181 |
The value may have any of the forms acceptable to <b>Tk_GetCursor</b>. |
| 182 |
</p></dd> |
| 183 |
</dl> |
| 184 |
|
| 185 |
|
| 186 |
<dl compact="compact"> |
| 187 |
<dt><code><b>:cursorbackground</b></code></dt> |
| 188 |
<dd><p align="right">Name=<code>"<b>cursorBackground</b><span class="roman">"</span> Class=<code>"</code><b>Foreground</b>"</code> |
| 189 |
</p><br> |
| 190 |
|
| 191 |
<p>Specifies the color to use as background in the area covered by the |
| 192 |
insertion cursor. This color will normally override either the normal |
| 193 |
background for the widget (or the selection background if the insertion |
| 194 |
cursor happens to fall in the selection). |
| 195 |
\fIThis option is obsolete and is gradually being replaced by |
| 196 |
the <b>insertBackground</b><span class="roman"> option.</span> |
| 197 |
</p></dd> |
| 198 |
</dl> |
| 199 |
|
| 200 |
|
| 201 |
<dl compact="compact"> |
| 202 |
<dt><code><b>:cursorborderwidth</b></code></dt> |
| 203 |
<dd><p align="right">Name=<code>"<b>cursorBorderWidth</b><span class="roman">"</span> Class=<code>"</code><b>BorderWidth</b>"</code> |
| 204 |
</p><br> |
| 205 |
|
| 206 |
<p>Specifies a non-negative value indicating the width |
| 207 |
of the 3-D border to draw around the insertion cursor. |
| 208 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 209 |
\fIThis option is obsolete and is gradually being replaced by |
| 210 |
the <b>insertBorderWidth</b><span class="roman"> option.</span> |
| 211 |
</p></dd> |
| 212 |
</dl> |
| 213 |
|
| 214 |
|
| 215 |
<dl compact="compact"> |
| 216 |
<dt><code><b>:cursorofftime</b></code></dt> |
| 217 |
<dd><p align="right">Name=<code>"<b>cursorOffTime</b><span class="roman">"</span> Class=<code>"</code><b>OffTime</b>"</code> |
| 218 |
</p><br> |
| 219 |
|
| 220 |
<p>Specifies a non-negative integer value indicating the number of |
| 221 |
milliseconds the cursor should remain “off” in each blink cycle. |
| 222 |
If this option is zero then the cursor doesn’t blink: it is on |
| 223 |
all the time. |
| 224 |
\fIThis option is obsolete and is gradually being replaced by |
| 225 |
the <b>insertOffTime</b><span class="roman"> option.</span> |
| 226 |
</p></dd> |
| 227 |
</dl> |
| 228 |
|
| 229 |
|
| 230 |
<dl compact="compact"> |
| 231 |
<dt><code><b>:cursorontime</b></code></dt> |
| 232 |
<dd><p align="right">Name=<code>"<b>cursorOnTime</b><span class="roman">"</span> Class=<code>"</code><b>OnTime</b>"</code> |
| 233 |
</p><br> |
| 234 |
|
| 235 |
<p>Specifies a non-negative integer value indicating the number of |
| 236 |
milliseconds the cursor should remain “on” in each blink cycle. |
| 237 |
\fIThis option is obsolete and is gradually being replaced by |
| 238 |
the <b>insertOnTime</b><span class="roman"> option.</span> |
| 239 |
</p></dd> |
| 240 |
</dl> |
| 241 |
|
| 242 |
|
| 243 |
<dl compact="compact"> |
| 244 |
<dt><code><b>:cursorwidth</b></code></dt> |
| 245 |
<dd><p align="right">Name=<code>"<b>cursorWidth</b><span class="roman">"</span> Class=<code>"</code><b>CursorWidth</b>"</code> |
| 246 |
</p><br> |
| 247 |
|
| 248 |
<p>Specifies a value indicating the total width of the insertion cursor. |
| 249 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 250 |
If a border has been specified for |
| 251 |
the cursor (using the <b>cursorBorderWidth</b> option), the border |
| 252 |
will be drawn inside the width specified by the <b>cursorWidth</b> |
| 253 |
option. |
| 254 |
\fIThis option is obsolete and is gradually being replaced by |
| 255 |
the <b>insertWidth</b><span class="roman"> option.</span> |
| 256 |
</p></dd> |
| 257 |
</dl> |
| 258 |
|
| 259 |
|
| 260 |
<dl compact="compact"> |
| 261 |
<dt><code><b>:disabledforeground</b></code></dt> |
| 262 |
<dd><p align="right">Name=<code>"<b>disabledForeground</b><span class="roman">"</span> Class=<code>"</code><b>DisabledForeground</b>"</code> |
| 263 |
</p><br> |
| 264 |
|
| 265 |
<p>Specifies foreground color to use when drawing a disabled element. |
| 266 |
If the option is specified as an empty string (which is typically the |
| 267 |
case on monochrome displays), disabled elements are drawn with the |
| 268 |
normal fooreground color but they are dimmed by drawing them |
| 269 |
with a stippled fill pattern. |
| 270 |
</p></dd> |
| 271 |
</dl> |
| 272 |
|
| 273 |
|
| 274 |
<dl compact="compact"> |
| 275 |
<dt><code><b>:exportselection</b></code></dt> |
| 276 |
<dd><p align="right">Name=<code>"<b>exportSelection</b><span class="roman">"</span> Class=<code>"</code><b>ExportSelection</b>"</code> |
| 277 |
</p><br> |
| 278 |
|
| 279 |
<p>Specifies whether or not a selection in the widget should also be |
| 280 |
the X selection. |
| 281 |
The value may have any of the forms accepted by <b>Tcl_GetBoolean</b>, |
| 282 |
such as <b>true</b><span class="roman">, </span><b>false</b><span class="roman">, </span><b>0</b><span class="roman">, </span><b>1</b><span class="roman">, </span><b>yes</b><span class="roman">, or </span><b>no</b>. |
| 283 |
If the selection is exported, then selecting in the widget deselects |
| 284 |
the current X selection, selecting outside the widget deselects any |
| 285 |
widget selection, and the widget will respond to selection retrieval |
| 286 |
requests when it has a selection. The default is usually for widgets |
| 287 |
to export selections. |
| 288 |
</p></dd> |
| 289 |
</dl> |
| 290 |
|
| 291 |
|
| 292 |
<dl compact="compact"> |
| 293 |
<dt><code><b>:font</b></code></dt> |
| 294 |
<dd><p align="right">Name=<code>"<b>font</b><span class="roman">"</span> Class=<code>"</code><b>Font</b>"</code> |
| 295 |
</p><br> |
| 296 |
|
| 297 |
<p>Specifies the font to use when drawing text inside the widget. |
| 298 |
</p></dd> |
| 299 |
</dl> |
| 300 |
|
| 301 |
|
| 302 |
<dl compact="compact"> |
| 303 |
<dt><code><b>:foreground or :fg</b></code></dt> |
| 304 |
<dd><p align="right">Name=<code>"<b>foreground</b><span class="roman">"</span> Class=<code>"</code><b>Foreground</b>"</code> |
| 305 |
</p><br> |
| 306 |
|
| 307 |
<p>Specifies the normal foreground color to use when displaying the widget. |
| 308 |
</p></dd> |
| 309 |
</dl> |
| 310 |
|
| 311 |
|
| 312 |
<dl compact="compact"> |
| 313 |
<dt><code><b>:geometry</b></code></dt> |
| 314 |
<dd><p align="right">Name=<code>"<b>geometry</b><span class="roman">"</span> Class=<code>"</code><b>Geometry</b>"</code> |
| 315 |
</p><br> |
| 316 |
|
| 317 |
<p>Specifies the desired geometry for the widget’s window, in the |
| 318 |
form <i>width</i><b>x</b><i>height</i><span class="roman">, where </span><i>width</i> is the desired |
| 319 |
width of the window and <i>height</i> is the desired height. The |
| 320 |
units for <i>width</i><span class="roman"> and </span><i>height</i> depend on the particular |
| 321 |
widget. For widgets displaying text the units are usually the |
| 322 |
size of the characters in the font being displayed; for other |
| 323 |
widgets the units are usually pixels. |
| 324 |
</p></dd> |
| 325 |
</dl> |
| 326 |
|
| 327 |
|
| 328 |
<dl compact="compact"> |
| 329 |
<dt><code><b>:insertbackground</b></code></dt> |
| 330 |
<dd><p align="right">Name=<code>"<b>insertBackground</b><span class="roman">"</span> Class=<code>"</code><b>Foreground</b>"</code> |
| 331 |
</p><br> |
| 332 |
|
| 333 |
<p>Specifies the color to use as background in the area covered by the |
| 334 |
insertion cursor. This color will normally override either the normal |
| 335 |
background for the widget (or the selection background if the insertion |
| 336 |
cursor happens to fall in the selection). |
| 337 |
</p></dd> |
| 338 |
</dl> |
| 339 |
|
| 340 |
|
| 341 |
<dl compact="compact"> |
| 342 |
<dt><code><b>:insertborderwidth</b></code></dt> |
| 343 |
<dd><p align="right">Name=<code>"<b>insertBorderWidth</b><span class="roman">"</span> Class=<code>"</code><b>BorderWidth</b>"</code> |
| 344 |
</p><br> |
| 345 |
|
| 346 |
<p>Specifies a non-negative value indicating the width |
| 347 |
of the 3-D border to draw around the insertion cursor. |
| 348 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 349 |
</p></dd> |
| 350 |
</dl> |
| 351 |
|
| 352 |
|
| 353 |
<dl compact="compact"> |
| 354 |
<dt><code><b>:insertofftime</b></code></dt> |
| 355 |
<dd><p align="right">Name=<code>"<b>insertOffTime</b><span class="roman">"</span> Class=<code>"</code><b>OffTime</b>"</code> |
| 356 |
</p><br> |
| 357 |
|
| 358 |
<p>Specifies a non-negative integer value indicating the number of |
| 359 |
milliseconds the insertion cursor should remain “off” in each blink cycle. |
| 360 |
If this option is zero then the cursor doesn’t blink: it is on |
| 361 |
all the time. |
| 362 |
</p></dd> |
| 363 |
</dl> |
| 364 |
|
| 365 |
|
| 366 |
<dl compact="compact"> |
| 367 |
<dt><code><b>:insertontime</b></code></dt> |
| 368 |
<dd><p align="right">Name=<code>"<b>insertOnTime</b><span class="roman">"</span> Class=<code>"</code><b>OnTime</b>"</code> |
| 369 |
</p><br> |
| 370 |
|
| 371 |
<p>Specifies a non-negative integer value indicating the number of |
| 372 |
milliseconds the insertion cursor should remain “on” in each blink cycle. |
| 373 |
</p></dd> |
| 374 |
</dl> |
| 375 |
|
| 376 |
|
| 377 |
<dl compact="compact"> |
| 378 |
<dt><code><b>:insertwidth</b></code></dt> |
| 379 |
<dd><p align="right">Name=<code>"<b>insertWidth</b><span class="roman">"</span> Class=<code>"</code><b>InsertWidth</b>"</code> |
| 380 |
</p><br> |
| 381 |
|
| 382 |
<p>Specifies a value indicating the total width of the insertion cursor. |
| 383 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 384 |
If a border has been specified for the insertion |
| 385 |
cursor (using the <b>insertBorderWidth</b> option), the border |
| 386 |
will be drawn inside the width specified by the <b>insertWidth</b> |
| 387 |
option. |
| 388 |
</p></dd> |
| 389 |
</dl> |
| 390 |
|
| 391 |
|
| 392 |
<dl compact="compact"> |
| 393 |
<dt><code><b>:orient</b></code></dt> |
| 394 |
<dd><p align="right">Name=<code>"<b>orient</b><span class="roman">"</span> Class=<code>"</code><b>Orient</b>"</code> |
| 395 |
</p><br> |
| 396 |
|
| 397 |
<p>For widgets that can lay themselves out with either a horizontal |
| 398 |
or vertical orientation, such as scrollbars, this option specifies |
| 399 |
which orientation should be used. Must be either <b>horizontal</b> |
| 400 |
or <b>vertical</b> or an abbreviation of one of these. |
| 401 |
</p></dd> |
| 402 |
</dl> |
| 403 |
|
| 404 |
|
| 405 |
<dl compact="compact"> |
| 406 |
<dt><code><b>:padx</b></code></dt> |
| 407 |
<dd><p align="right">Name=<code>"<b>padX</b><span class="roman">"</span> Class=<code>"</code><b>Pad</b>"</code> |
| 408 |
</p><br> |
| 409 |
|
| 410 |
<p>Specifies a non-negative value indicating how much extra space |
| 411 |
to request for the widget in the X-direction. |
| 412 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 413 |
When computing how large a window it needs, the widget will |
| 414 |
add this amount to the width it would normally need (as determined |
| 415 |
by the width of the things displayed in the widget); if the geometry |
| 416 |
manager can satisfy this request, the widget will end up with extra |
| 417 |
internal space to the left and/or right of what it displays inside. |
| 418 |
</p></dd> |
| 419 |
</dl> |
| 420 |
|
| 421 |
|
| 422 |
<dl compact="compact"> |
| 423 |
<dt><code><b>:pady</b></code></dt> |
| 424 |
<dd><p align="right">Name=<code>"<b>padY</b><span class="roman">"</span> Class=<code>"</code><b>Pad</b>"</code> |
| 425 |
</p><br> |
| 426 |
|
| 427 |
<p>Specifies a non-negative value indicating how much extra space |
| 428 |
to request for the widget in the Y-direction. |
| 429 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 430 |
When computing how large a window it needs, the widget will add |
| 431 |
this amount to the height it would normally need (as determined by |
| 432 |
the height of the things displayed in the widget); if the geometry |
| 433 |
manager can satisfy this request, the widget will end up with extra |
| 434 |
internal space above and/or below what it displays inside. |
| 435 |
</p></dd> |
| 436 |
</dl> |
| 437 |
|
| 438 |
|
| 439 |
<dl compact="compact"> |
| 440 |
<dt><code><b>:relief</b></code></dt> |
| 441 |
<dd><p align="right">Name=<code>"<b>relief</b><span class="roman">"</span> Class=<code>"</code><b>Relief</b>"</code> |
| 442 |
</p><br> |
| 443 |
|
| 444 |
<p>Specifies the 3-D effect desired for the widget. Acceptable |
| 445 |
values are <b>raised</b><span class="roman">, </span><b>sunken</b><span class="roman">, </span><b>flat</b><span class="roman">, </span><b>ridge</b>, |
| 446 |
and <b>groove</b>. |
| 447 |
The value |
| 448 |
indicates how the interior of the widget should appear relative |
| 449 |
to its exterior; for example, <b>raised</b> means the interior of |
| 450 |
the widget should appear to protrude from the screen, relative to |
| 451 |
the exterior of the widget. |
| 452 |
</p></dd> |
| 453 |
</dl> |
| 454 |
|
| 455 |
|
| 456 |
<dl compact="compact"> |
| 457 |
<dt><code><b>:repeatdelay</b></code></dt> |
| 458 |
<dd><p align="right">Name=<code>"<b>repeatDelay</b><span class="roman">"</span> Class=<code>"</code><b>RepeatDelay</b>"</code> |
| 459 |
</p><br> |
| 460 |
|
| 461 |
<p>Specifies the number of milliseconds a button or key must be held |
| 462 |
down before it begins to auto-repeat. Used, for example, on the |
| 463 |
up- and down-arrows in scrollbars. |
| 464 |
</p></dd> |
| 465 |
</dl> |
| 466 |
|
| 467 |
|
| 468 |
<dl compact="compact"> |
| 469 |
<dt><code><b>:repeatinterval</b></code></dt> |
| 470 |
<dd><p align="right">Name=<code>"<b>repeatInterval</b><span class="roman">"</span> Class=<code>"</code><b>RepeatInterval</b>"</code> |
| 471 |
</p><br> |
| 472 |
|
| 473 |
<p>Used in conjunction with <b>repeatDelay</b>: once auto-repeat |
| 474 |
begins, this option determines the number of milliseconds between |
| 475 |
auto-repeats. |
| 476 |
</p></dd> |
| 477 |
</dl> |
| 478 |
|
| 479 |
|
| 480 |
<dl compact="compact"> |
| 481 |
<dt><code><b>:scrollcommand</b></code></dt> |
| 482 |
<dd><p align="right">Name=<code>"<b>scrollCommand</b><span class="roman">"</span> Class=<code>"</code><b>ScrollCommand</b>"</code> |
| 483 |
</p><br> |
| 484 |
|
| 485 |
<p>Specifies the prefix for a command used to communicate with scrollbar |
| 486 |
widgets. When the view in the widget’s window changes (or |
| 487 |
whenever anything else occurs that could change the display in a |
| 488 |
scrollbar, such as a change in the total size of the widget’s |
| 489 |
contents), the widget will |
| 490 |
generate a Tcl command by concatenating the scroll command and four |
| 491 |
numbers. The four numbers are, in order: the total size of the |
| 492 |
widget’s contents, in unspecified units |
| 493 |
(“unit” is a widget-specific term; for widgets |
| 494 |
displaying text, the unit is a line); the maximum number of units that |
| 495 |
may be displayed at once in the widget’s window, given its current size; the |
| 496 |
index of the top-most or left-most unit currently visible in the window |
| 497 |
(index 0 corresponds to the first unit); and the index of the bottom-most |
| 498 |
or right-most unit currently visible in the window. This command is |
| 499 |
then passed to the Tcl interpreter for execution. Typically the |
| 500 |
<b>scrollCommand</b> option consists of the path name of a scrollbar |
| 501 |
widget followed by “set”, e.g. “.x.scrollbar set”: this will cause |
| 502 |
the scrollbar to be updated whenever the view in the window changes. |
| 503 |
If this option is not specified, then no command will be executed. |
| 504 |
</p> |
| 505 |
<p>The <b>scrollCommand</b> option is used for widgets that support scrolling |
| 506 |
in only one direction. |
| 507 |
For widgets that support scrolling in both directions, this |
| 508 |
option is replaced with the <b>xScrollCommand</b><span class="roman"> and </span><b>yScrollCommand</b> |
| 509 |
options. |
| 510 |
</p></dd> |
| 511 |
</dl> |
| 512 |
|
| 513 |
|
| 514 |
<dl compact="compact"> |
| 515 |
<dt><code><b>:selectbackground</b></code></dt> |
| 516 |
<dd><p align="right">Name=<code>"<b>selectBackground</b><span class="roman">"</span> Class=<code>"</code><b>Foreground</b>"</code> |
| 517 |
</p><br> |
| 518 |
|
| 519 |
<p>Specifies the background color to use when displaying selected |
| 520 |
items. |
| 521 |
</p></dd> |
| 522 |
</dl> |
| 523 |
|
| 524 |
|
| 525 |
<dl compact="compact"> |
| 526 |
<dt><code><b>:selectborderwidth</b></code></dt> |
| 527 |
<dd><p align="right">Name=<code>"<b>selectBorderWidth</b><span class="roman">"</span> Class=<code>"</code><b>BorderWidth</b>"</code> |
| 528 |
</p><br> |
| 529 |
|
| 530 |
<p>Specifies a non-negative value indicating the width |
| 531 |
of the 3-D border to draw around selected items. |
| 532 |
The value may have any of the forms acceptable to <b>Tk_GetPixels</b>. |
| 533 |
</p></dd> |
| 534 |
</dl> |
| 535 |
|
| 536 |
|
| 537 |
<dl compact="compact"> |
| 538 |
<dt><code><b>:selectforeground</b></code></dt> |
| 539 |
<dd><p align="right">Name=<code>"<b>selectForeground</b><span class="roman">"</span> Class=<code>"</code><b>Background</b>"</code> |
| 540 |
</p><br> |
| 541 |
|
| 542 |
<p>Specifies the foreground color to use when displaying selected |
| 543 |
items. |
| 544 |
</p></dd> |
| 545 |
</dl> |
| 546 |
|
| 547 |
|
| 548 |
<dl compact="compact"> |
| 549 |
<dt><code><b>:setgrid</b></code></dt> |
| 550 |
<dd><p align="right">Name=<code>"<b>setGrid</b><span class="roman">"</span> Class=<code>"</code><b>SetGrid</b>"</code> |
| 551 |
</p><br> |
| 552 |
|
| 553 |
<p>Specifies a boolean value that determines whether this widget controls the |
| 554 |
resizing grid for its top-level window. |
| 555 |
This option is typically used in text widgets, where the information |
| 556 |
in the widget has a natural size (the size of a character) and it makes |
| 557 |
sense for the window’s dimensions to be integral numbers of these units. |
| 558 |
These natural window sizes form a grid. |
| 559 |
If the <b>setGrid</b> option is set to true then the widget will |
| 560 |
communicate with the window manager so that when the user interactively |
| 561 |
resizes the top-level window that contains the widget, the dimensions of |
| 562 |
the window will be displayed to the user in grid units and the window |
| 563 |
size will be constrained to integral numbers of grid units. |
| 564 |
See the section GRIDDED GEOMETRY MANAGEMENT in the <b>wm</b> manual |
| 565 |
entry for more details. |
| 566 |
</p></dd> |
| 567 |
</dl> |
| 568 |
|
| 569 |
|
| 570 |
<dl compact="compact"> |
| 571 |
<dt><code><b>:text</b></code></dt> |
| 572 |
<dd><p align="right">Name=<code>"<b>text</b><span class="roman">"</span> Class=<code>"</code><b>Text</b>"</code> |
| 573 |
</p><br> |
| 574 |
|
| 575 |
<p>Specifies a string to be displayed inside the widget. The way in which |
| 576 |
the string is displayed depends on the particular widget and may be |
| 577 |
determined by other options, such as <b>anchor</b><span class="roman"> or </span><b>justify</b>. |
| 578 |
</p></dd> |
| 579 |
</dl> |
| 580 |
|
| 581 |
|
| 582 |
<dl compact="compact"> |
| 583 |
<dt><code><b>:textvariable</b></code></dt> |
| 584 |
<dd><p align="right">Name=<code>"<b>textVariable</b><span class="roman">"</span> Class=<code>"</code><b>Variable</b>"</code> |
| 585 |
</p><br> |
| 586 |
|
| 587 |
<p>Specifies the name of a variable. The value of the variable is a text |
| 588 |
string to be displayed inside the widget; if the variable value changes |
| 589 |
then the widget will automatically update itself to reflect the new value. |
| 590 |
The way in which the string is displayed in the widget depends on the |
| 591 |
particular widget and may be determined by other options, such as |
| 592 |
<b>anchor</b><span class="roman"> or </span><b>justify</b>. |
| 593 |
</p></dd> |
| 594 |
</dl> |
| 595 |
|
| 596 |
|
| 597 |
<dl compact="compact"> |
| 598 |
<dt><code><b>:underline</b></code></dt> |
| 599 |
<dd><p align="right">Name=<code>"<b>underline</b><span class="roman">"</span> Class=<code>"</code><b>Underline</b>"</code> |
| 600 |
</p><br> |
| 601 |
|
| 602 |
<p>Specifies the integer index of a character to underline in the widget. |
| 603 |
This option is typically used to indicate keyboard traversal characters |
| 604 |
in menu buttons and menu entries. 0 corresponds to the first character |
| 605 |
of the text displayed in the widget, 1 to the next character, and so |
| 606 |
on. |
| 607 |
</p></dd> |
| 608 |
</dl> |
| 609 |
|
| 610 |
|
| 611 |
<dl compact="compact"> |
| 612 |
<dt><code><b>:xscrollcommand</b></code></dt> |
| 613 |
<dd><p align="right">Name=<code>"<b>xScrollCommand</b><span class="roman">"</span> Class=<code>"</code><b>ScrollCommand</b>"</code> |
| 614 |
</p><br> |
| 615 |
|
| 616 |
<p>Specifies the prefix for a command used to communicate with horizontal |
| 617 |
scrollbars. This option is treated in the same way as the |
| 618 |
<b>scrollCommand</b> option, except that it is used for horizontal |
| 619 |
scrollbars associated with widgets that support both horizontal |
| 620 |
and vertical scrolling. |
| 621 |
See the description of <b>scrollCommand</b> for complete details |
| 622 |
on how this option is used. |
| 623 |
</p></dd> |
| 624 |
</dl> |
| 625 |
|
| 626 |
|
| 627 |
<dl compact="compact"> |
| 628 |
<dt><code><b>:yscrollcommand</b></code></dt> |
| 629 |
<dd><p align="right">Name=<code>"<b>yScrollCommand</b><span class="roman">"</span> Class=<code>"</code><b>ScrollCommand</b>"</code> |
| 630 |
</p><br> |
| 631 |
|
| 632 |
<p>Specifies the prefix for a command used to communicate with vertical |
| 633 |
scrollbars. This option is treated in the same way as the |
| 634 |
<b>scrollCommand</b> option, except that it is used for vertical |
| 635 |
scrollbars associated with widgets that support both horizontal |
| 636 |
and vertical scrolling. |
| 637 |
See the description of <b>scrollCommand</b> for complete details |
| 638 |
on how this option is used. |
| 639 |
</p> |
| 640 |
</dd> |
| 641 |
</dl> |
| 642 |
<span id="Keywords-26"></span><h4 class="unnumberedsubsec">Keywords</h4> |
| 643 |
<p>class, name, standard option, switch |
| 644 |
</p><hr> |
| 645 |
<div class="header"> |
| 646 |
<p> |
| 647 |
Next: <a href="pack_002dold.html" accesskey="n" rel="next">pack-old</a>, Previous: <a href="option.html" accesskey="p" rel="prev">option</a>, Up: <a href="Control.html" accesskey="u" rel="up">Control</a> [<a href="wm.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p> |
| 648 |
</div> |
| 649 |
|
| 650 |
|
| 651 |
|
| 652 |
</body> |
| 653 |
</html> |