Debian Codegraph @

info/gcl-tk/frame.html

raw
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>frame (GCL TK Manual)</title>
7
8 <meta name="description" content="frame (GCL TK Manual)">
9 <meta name="keywords" content="frame (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="Widgets.html" rel="up" title="Widgets">
16 <link href="label.html" rel="next" title="label">
17 <link href="message.html" rel="prev" title="message">
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="frame"></span><div class="header">
42 <p>
43 Next: <a href="label.html" accesskey="n" rel="next">label</a>, Previous: <a href="message.html" accesskey="p" rel="prev">message</a>, Up: <a href="Widgets.html" accesskey="u" rel="up">Widgets</a> &nbsp; [<a href="wm.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
44 </div>
45 <hr>
46 <span id="frame-1"></span><h3 class="section">2.12 frame</h3>
47
48 <p>frame \- Create and manipulate frame widgets
49 </p><span id="Synopsis-11"></span><h4 class="unnumberedsubsec">Synopsis</h4>
50 <p><b>frame</b><i> </i><i>pathName </i><span class="roman">?</span><b>:class </b><i>className</i><span class="roman">? ?</span><i>options</i>?
51 </p><span id="Standard-Options-11"></span><h4 class="unnumberedsubsec">Standard Options</h4>
52
53
54 <div class="example">
55 <pre class="example">background cursor relief
56 borderWidth geometry
57 </pre></div>
58
59
60 <p>See <a href="options.html">options</a>, for more information.
61 </p><span id="Arguments-for-Frame"></span><h4 class="unnumberedsubsec">Arguments for Frame</h4>
62
63
64 <dl compact="compact">
65 <dt><code><b>:height</b></code></dt>
66 <dd><p align="right">Name=<code>&quot;<b>height</b><span class="roman">&quot;</span> Class=<code>&quot;</code><b>Height</b>&quot;</code>
67 </p><br>
68
69 <p>Specifies the desired height for the window in any of the forms
70 acceptable to <b>Tk_GetPixels</b>.
71 This option is only used if the <b>:geometry</b> option is
72 unspecified.
73 If this option is less than or equal to zero (and <b>:geometry</b>
74 is not specified) then the window will not request any size at
75 all.
76 </p></dd>
77 </dl>
78
79
80 <dl compact="compact">
81 <dt><code><b>:width</b></code></dt>
82 <dd><p align="right">Name=<code>&quot;<b>width</b><span class="roman">&quot;</span> Class=<code>&quot;</code><b>Width</b>&quot;</code>
83 </p><br>
84
85 <p>Specifies the desired width for the window in any of the forms
86 acceptable to <b>Tk_GetPixels</b>.
87 This option is only used if the <b>:geometry</b> option is
88 unspecified.
89 If this option is less than or equal to zero (and <b>:geometry</b>
90 is not specified) then the window will not request any size at
91 all.
92 </p></dd>
93 </dl>
94
95 <span id="Description-8"></span><h4 class="unnumberedsubsec">Description</h4>
96
97 <p>The <b>frame</b> command creates a new window (given by the
98 <i>pathName</i> argument) and makes it into a frame widget.
99 Additional
100 options, described above, may be specified on the command line
101 or in the option database
102 to configure aspects of the frame such as its background color
103 and relief. The <b>frame</b> command returns the
104 path name of the new window.
105 </p>
106 <p>A frame is a simple widget. Its primary purpose is to act as a
107 spacer or container for complex window layouts. The only features
108 of a frame are its background color and an optional 3-D border to make the
109 frame appear raised or sunken.
110 </p>
111 <p>In addition to the standard options listed above, a <b>:class</b>
112 option may be specified on the command line. If it is specified, then
113 the new widget&rsquo;s class will be set to <i>className</i> instead of
114 <b>Frame</b>. Changing the class of a frame widget may be useful
115 in order to use a special class name in database options referring
116 to this widget and its children. Note: <b>:class</b> is handled
117 differently than other command-line options and cannot be specified
118 using the option database (it has to be processed
119 before the other options are even looked up, since the new class
120 name will affect the lookup of the other options). In addition,
121 the <b>:class</b> option may not be queried or changed using the
122 <b>config</b> command described below.
123 </p>
124 <span id="A-Frame-Widget_0027s-Arguments"></span><h4 class="unnumberedsubsec">A Frame Widget&rsquo;s Arguments</h4>
125
126 <p>The <b>frame</b> command creates a new Tcl command whose
127 name is the same as the path name of the frame&rsquo;s window. This
128 command may be used to invoke various
129 operations on the widget. It has the following general form:
130 </p>
131 <div class="example">
132 <pre class="example"><i>pathName option </i><span class="roman">?</span><i>arg arg ...</i>?
133 </pre></div>
134
135 <p><i>PathName</i> is the name of the command, which is the same as
136 the frame widget&rsquo;s path name. <i>Option</i><span class="roman"> and the </span><i>arg</i>s
137 determine the exact behavior of the command. The following
138 commands are possible for frame widgets:
139 </p>
140 <dl compact="compact">
141 <dt><i>pathName </i><b>:configure</b><span class="roman"> ?</span><i>option</i><span class="roman">? </span><i>?value option value ...</i>?</dt>
142 <dd><p>Query or modify the configuration options of the widget.
143 If no <i>option</i> is specified, returns a list describing all of
144 the available options for <i>pathName</i><span class="roman"> (see </span><b>Tk_ConfigureInfo</b> for
145 information on the format of this list). If <i>option</i> is specified
146 with no <i>value</i>, then the command returns a list describing the
147 one named option (this list will be identical to the corresponding
148 sublist of the value returned if no <i>option</i> is specified). If
149 one or more <i>option:value</i> pairs are specified, then the command
150 modifies the given widget option(s) to have the given value(s); in
151 this case the command returns an empty string.
152 <i>Option</i><span class="roman"> may have any of the values accepted by the </span><b>frame</b>
153 command.
154 </p>
155 </dd>
156 </dl>
157 <span id="Bindings-5"></span><h4 class="unnumberedsubsec">Bindings</h4>
158
159 <p>When a new frame is created, it has no default event bindings:
160 frames are not intended to be interactive.
161 </p>
162 <span id="Keywords-11"></span><h4 class="unnumberedsubsec">Keywords</h4>
163 <p>frame, widget
164 </p><hr>
165 <div class="header">
166 <p>
167 Next: <a href="label.html" accesskey="n" rel="next">label</a>, Previous: <a href="message.html" accesskey="p" rel="prev">message</a>, Up: <a href="Widgets.html" accesskey="u" rel="up">Widgets</a> &nbsp; [<a href="wm.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
168 </div>
169
170
171
172 </body>
173 </html>