1 |
578 |
markom |
<HTML>
|
2 |
|
|
<HEAD>
|
3 |
|
|
<TITLE>iwidgets2.2.0 User Commands - shell</TITLE>
|
4 |
|
|
</HEAD>
|
5 |
|
|
<BODY BGCOLOR="#FFFFFF">
|
6 |
|
|
<H1>iwidgets2.2.0 User Commands - shell</H1>
|
7 |
|
|
<HR>
|
8 |
|
|
<PRE>
|
9 |
|
|
|
10 |
|
|
</PRE>
|
11 |
|
|
<H2><HR ALIGN=LEFT WIDTH=70% SIZE=3></H2><PRE>
|
12 |
|
|
|
13 |
|
|
|
14 |
|
|
</PRE>
|
15 |
|
|
<H2>NAME</H2><PRE>
|
16 |
|
|
shell - Create and manipulate a shell widget
|
17 |
|
|
|
18 |
|
|
|
19 |
|
|
</PRE>
|
20 |
|
|
<H2>SYNOPSIS</H2><PRE>
|
21 |
|
|
<STRONG>shell</STRONG> <EM>pathName</EM> ?<EM>options</EM>?
|
22 |
|
|
|
23 |
|
|
|
24 |
|
|
</PRE>
|
25 |
|
|
<H2>INHERITANCE</H2><PRE>
|
26 |
|
|
itk::Toplevel <- shell
|
27 |
|
|
|
28 |
|
|
|
29 |
|
|
</PRE>
|
30 |
|
|
<H2>STANDARD OPTIONS</H2><PRE>
|
31 |
|
|
<STRONG>background</STRONG> <STRONG>cursor</STRONG> <STRONG>foreground</STRONG>
|
32 |
|
|
|
33 |
|
|
See the "options" manual entry for details on the standard
|
34 |
|
|
options.
|
35 |
|
|
|
36 |
|
|
|
37 |
|
|
</PRE>
|
38 |
|
|
<H2>WIDGET-SPECIFIC OPTIONS</H2><PRE>
|
39 |
|
|
Name: <STRONG>master</STRONG>
|
40 |
|
|
Class: <STRONG>Window</STRONG>
|
41 |
|
|
Command-Line Switch: <STRONG>-master</STRONG>
|
42 |
|
|
|
43 |
|
|
Defines the shell as being a transient window with the
|
44 |
|
|
master window given by the master option. The master
|
45 |
|
|
window should be either another existing toplevel win-
|
46 |
|
|
dow or {} for no master. The default is {} for shells
|
47 |
|
|
and "." for dialogs.
|
48 |
|
|
|
49 |
|
|
Name: <STRONG>modality</STRONG>
|
50 |
|
|
Class: <STRONG>Modality</STRONG>
|
51 |
|
|
Command-Line Switch: <STRONG>-modality</STRONG>
|
52 |
|
|
|
53 |
|
|
Allows the shell to grab control of the screen in one
|
54 |
|
|
of three different ways: <STRONG>application</STRONG>, <STRONG>system</STRONG>, or <STRONG>none</STRONG>.
|
55 |
|
|
Application modal prevents any other toplevel windows
|
56 |
|
|
within the application which are direct children of '.'
|
57 |
|
|
from gaining focus. System modal locks the screen and
|
58 |
|
|
prevents all windows from gaining focus regardless of
|
59 |
|
|
application. A modality of none performs no grabs at
|
60 |
|
|
all. The default is none.
|
61 |
|
|
|
62 |
|
|
Name: <STRONG>padX</STRONG>
|
63 |
|
|
Class: <STRONG>Pad</STRONG>
|
64 |
|
|
Command-Line Switch: <STRONG>-padx</STRONG>
|
65 |
|
|
|
66 |
|
|
Specifies a padding distance for the childsite in the
|
67 |
|
|
X-direction in any of the forms acceptable to
|
68 |
|
|
<STRONG>Tk_GetPixels</STRONG>. The default is 10.
|
69 |
|
|
|
70 |
|
|
Name: <STRONG>padY</STRONG>
|
71 |
|
|
Class: <STRONG>Pad</STRONG>
|
72 |
|
|
Command-Line Switch: <STRONG>-pady</STRONG>
|
73 |
|
|
Specifies a padding distance for the childsite in the
|
74 |
|
|
Y-direction in any of the forms acceptable to
|
75 |
|
|
<STRONG>Tk_GetPixels</STRONG>. The default is 10.
|
76 |
|
|
|
77 |
|
|
Name: <STRONG>title</STRONG>
|
78 |
|
|
Class: <STRONG>Title</STRONG>
|
79 |
|
|
Command-Line Switch: <STRONG>-title</STRONG>
|
80 |
|
|
|
81 |
|
|
String to be displayed in the title window decoration.
|
82 |
|
|
|
83 |
|
|
|
84 |
|
|
</PRE>
|
85 |
|
|
<H2><HR ALIGN=LEFT WIDTH=70% SIZE=3></H2><PRE>
|
86 |
|
|
|
87 |
|
|
|
88 |
|
|
|
89 |
|
|
</PRE>
|
90 |
|
|
<H2>DESCRIPTION</H2><PRE>
|
91 |
|
|
The <STRONG>shell</STRONG> command creates a shell which is a top level
|
92 |
|
|
widget which supports modal operation.
|
93 |
|
|
|
94 |
|
|
|
95 |
|
|
|
96 |
|
|
</PRE>
|
97 |
|
|
<H2>METHODS</H2><PRE>
|
98 |
|
|
The <STRONG>shell</STRONG> command create a new Tcl command whose name is
|
99 |
|
|
<EM>pathName</EM>. This command may be used to invoke various opera-
|
100 |
|
|
tions on the widget. It has the following general form:
|
101 |
|
|
|
102 |
|
|
<EM>pathName</EM> <EM>option</EM> ?<EM>arg</EM> <EM>arg</EM> ...?
|
103 |
|
|
|
104 |
|
|
<EM>Option</EM> and the <EM>arg</EM>s determine the exact behavior of the com-
|
105 |
|
|
mand. The following commands are possible for shell widg-
|
106 |
|
|
ets:
|
107 |
|
|
|
108 |
|
|
|
109 |
|
|
</PRE>
|
110 |
|
|
<H2>WIDGET-SPECIFIC METHODS</H2><PRE>
|
111 |
|
|
<EM>pathName</EM> <STRONG>activate</STRONG>
|
112 |
|
|
Display the shell and wait based on the modality. For
|
113 |
|
|
application and system modal activations, perform a
|
114 |
|
|
grab operation, and wait for the result. The result
|
115 |
|
|
may be returned via an argument to the <STRONG>deactivate</STRONG>
|
116 |
|
|
method.
|
117 |
|
|
|
118 |
|
|
<EM>pathName</EM> <STRONG>center</STRONG> ?<EM>widget</EM>?
|
119 |
|
|
Centers the shell with respect to another widget. The
|
120 |
|
|
widget argument is optional. If provided, it should be
|
121 |
|
|
the path of another widget with to center upon. If
|
122 |
|
|
absent, then the shell will be centered on the screen
|
123 |
|
|
as a whole.
|
124 |
|
|
|
125 |
|
|
<EM>pathName</EM> <STRONG>cget</STRONG> <EM>option</EM>
|
126 |
|
|
Returns the current value of the configuration option
|
127 |
|
|
given by <EM>option</EM>. <EM>Option</EM> may have any of the values
|
128 |
|
|
accepted by the <STRONG>shell</STRONG> command.
|
129 |
|
|
|
130 |
|
|
<EM>pathName</EM> <STRONG>childsite</STRONG>
|
131 |
|
|
Returns the pathname of the child site widget.
|
132 |
|
|
|
133 |
|
|
<EM>pathName</EM> <STRONG>configure</STRONG> ?<EM>option</EM>? ?<EM>value</EM> <EM>option</EM> <EM>value</EM> ...?
|
134 |
|
|
Query or modify the configuration options of the
|
135 |
|
|
widget. If no <EM>option</EM> is specified, returns a list
|
136 |
|
|
describing all of the available options for <EM>pathName</EM>
|
137 |
|
|
(see <STRONG>Tk_ConfigureInfo</STRONG> for information on the format of
|
138 |
|
|
this list). If <EM>option</EM> is specified with no <EM>value</EM>, then
|
139 |
|
|
the command returns a list describing the one named
|
140 |
|
|
option (this list will be identical to the correspond-
|
141 |
|
|
ing sublist of the value returned if no <EM>option</EM> is
|
142 |
|
|
specified). If one or more <EM>option</EM> - <EM>value</EM> pairs are
|
143 |
|
|
specified, then the command modifies the given widget
|
144 |
|
|
option(s) to have the given value(s); in this case the
|
145 |
|
|
command returns an empty string. <EM>Option</EM> may have any
|
146 |
|
|
of the values accepted by the <STRONG>shell</STRONG> command.
|
147 |
|
|
|
148 |
|
|
<EM>pathName</EM> <STRONG>deactivate</STRONG> ?<EM>arg</EM>?
|
149 |
|
|
Deactivate the display of the shell. The method takes
|
150 |
|
|
an optional argument to be passed to the <STRONG>activate</STRONG>
|
151 |
|
|
method which returns the value. The optional argument
|
152 |
|
|
is only effective for application and system modal dia-
|
153 |
|
|
logs.
|
154 |
|
|
|
155 |
|
|
|
156 |
|
|
|
157 |
|
|
</PRE>
|
158 |
|
|
<H2>COMPONENTS</H2><PRE>
|
159 |
|
|
Name: <STRONG>shellchildsite</STRONG>
|
160 |
|
|
Class: <STRONG>frame</STRONG>
|
161 |
|
|
|
162 |
|
|
The shellchildsite component is the user child site for
|
163 |
|
|
the shell. See the "frame" widget manual entry for
|
164 |
|
|
details on the shellchildsite component item.
|
165 |
|
|
|
166 |
|
|
|
167 |
|
|
|
168 |
|
|
</PRE>
|
169 |
|
|
<H2>EXAMPLE</H2><PRE>
|
170 |
|
|
shell .sh -modality application -padx 20 -pady 20 -title Shell
|
171 |
|
|
|
172 |
|
|
pack [label [.sh childsite].l -text SHELL]
|
173 |
|
|
|
174 |
|
|
.sh center
|
175 |
|
|
.sh activate
|
176 |
|
|
|
177 |
|
|
|
178 |
|
|
|
179 |
|
|
</PRE>
|
180 |
|
|
<H2>AUTHOR</H2><PRE>
|
181 |
|
|
Mark L. Ulferts
|
182 |
|
|
|
183 |
|
|
Kris Raney
|
184 |
|
|
|
185 |
|
|
|
186 |
|
|
</PRE>
|
187 |
|
|
<H2>KEYWORDS</H2><PRE>
|
188 |
|
|
shell, widget
|
189 |
|
|
|
190 |
|
|
|
191 |
|
|
|
192 |
|
|
|
193 |
|
|
</PRE>
|
194 |
|
|
</BODY>
|
195 |
|
|
</HTML>
|