author | Stefan Vogel <sv@exept.de> |
Wed, 16 May 2018 08:37:31 +0200 | |
changeset 6320 | d52325b32f05 |
parent 6275 | 924ec06de44b |
child 6346 | 2494de2e1023 |
permissions | -rw-r--r-- |
6275 | 1 |
"{ Encoding: utf8 }" |
2 |
||
0 | 3 |
" |
5 | 4 |
COPYRIGHT (c) 1989 by Claus Gittinger |
60 | 5 |
All Rights Reserved |
0 | 6 |
|
7 |
This software is furnished under a license and may be used |
|
8 |
only in accordance with the terms of that license and with the |
|
9 |
inclusion of the above copyright notice. This software may not |
|
10 |
be provided or otherwise made available to, or used by, any |
|
11 |
other person. No title to or ownership of the software is |
|
12 |
hereby transferred. |
|
13 |
" |
|
2190 | 14 |
"{ Package: 'stx:libwidg' }" |
15 |
||
5516 | 16 |
"{ NameSpace: Smalltalk }" |
17 |
||
119 | 18 |
SimpleView subclass:#PanelView |
585 | 19 |
instanceVariableNames:'hLayout vLayout verticalSpace horizontalSpace mustRearrange |
4415 | 20 |
elementsChangeSize ignoreInvisibleComponents backgroundChannel' |
585 | 21 |
classVariableNames:'' |
22 |
poolDictionaries:'' |
|
23 |
category:'Views-Layout' |
|
0 | 24 |
! |
25 |
||
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
26 |
!PanelView class methodsFor:'documentation'! |
0 | 27 |
|
38 | 28 |
copyright |
29 |
" |
|
30 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
60 | 31 |
All Rights Reserved |
0 | 32 |
|
38 | 33 |
This software is furnished under a license and may be used |
34 |
only in accordance with the terms of that license and with the |
|
35 |
inclusion of the above copyright notice. This software may not |
|
36 |
be provided or otherwise made available to, or used by, any |
|
37 |
other person. No title to or ownership of the software is |
|
38 |
hereby transferred. |
|
39 |
" |
|
40 |
! |
|
0 | 41 |
|
38 | 42 |
documentation |
43 |
" |
|
127 | 44 |
this is a view for holding subviews. (layout-widget ?) |
38 | 45 |
|
46 |
Instances of PanelView try to get all their subviews into them, |
|
47 |
arranging subviews left-to-right, top-to-bottom. |
|
48 |
||
5951 | 49 |
If you don't like its layout, define a new subclass or use one of |
38 | 50 |
the existing subclasses: HorizontalPanelView and VerticalPanelView. |
60 | 51 |
|
127 | 52 |
The panel assumes, that the elements do not resize themselfes, after it |
53 |
became visible. This is not true for all widgets (buttons or labels may |
|
54 |
like to change). If you have changing elements, tell this to the panel |
|
55 |
with 'aPanel elementsChangeSize:true'. In that case, the panel will react |
|
56 |
to size changes, and reorganize things. |
|
57 |
||
63 | 58 |
PanelViews normally delay the actual positioning/sizing of their elements, |
60 | 59 |
until actually displayed. This is useful, if more elements are to |
60 |
be added, to avoid repeated configuration of the elements. |
|
61 |
||
62 |
If you want to query for the relative position of an element BEFORE |
|
63 |
the view is visible, you have to send #setChildPositionsIfChanged before |
|
63 | 64 |
doing so (otherwise, you may get invalid origins from the subviews). As |
65 |
an example, the modalBoxes do so before showing themselfes to ask for the |
|
66 |
position of the ok-button relative to the top-left box-origin, in order to |
|
67 |
position the ok-button under the mouse-pointer. |
|
68 |
||
585 | 69 |
[Instance variables:] |
63 | 70 |
|
5951 | 71 |
hLayout <Symbol> controls horizontal layout; ignored in this |
72 |
class, but used in Horizontal- and |
|
73 |
VerticalPanelViews. See more info there. |
|
63 | 74 |
|
5951 | 75 |
vLayout <Symbol> controls vertical layout; ignored in this |
76 |
class, but used in Horizontal- and |
|
77 |
VerticalPanelViews. See more info there. |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
78 |
|
5951 | 79 |
horizontalSpace <Integer> number of pixels to use as space between elements |
80 |
defaults to ViewSpacing, which is 1mm |
|
63 | 81 |
|
5951 | 82 |
verticalSpace <Integer> number of pixels to use as space between elements |
83 |
defaults to ViewSpacing, which is 1mm |
|
63 | 84 |
|
5951 | 85 |
mustRearrange <Boolean> internal flag, if rearrangement is needed |
63 | 86 |
|
5951 | 87 |
elementsChangeSize |
88 |
<Boolean> if true, the panel takes care of this situation. |
|
89 |
By default, this is false. |
|
125 | 90 |
|
5951 | 91 |
ignoreInvisibleComponents |
92 |
<Boolean> if true, invisible (i.e. hidden) views |
|
93 |
are not considered in the layout computation. |
|
94 |
If false, they will lead to additional space |
|
95 |
between visible components. |
|
96 |
The default is false. |
|
585 | 97 |
|
98 |
[author:] |
|
5951 | 99 |
Claus Gittinger |
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
100 |
" |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
101 |
! |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
102 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
103 |
examples |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
104 |
" |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
105 |
The generic panelView simply tries to get its |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
106 |
components arranged for fitting them all into |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
107 |
its area. No special layout is done, except for |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
108 |
horizontal/vertical spacings. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
109 |
The view is filled top-left to bottom-right |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
110 |
with subcomponents. Subcomponents are not resized. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
111 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
112 |
example: |
1604 | 113 |
[exBegin] |
114 |
|v p b1 b2 b3| |
|
115 |
||
116 |
v := StandardSystemView new. |
|
117 |
v label:'panel'. |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
118 |
|
1604 | 119 |
p := PanelView in:v. |
120 |
p origin:(0.0 @ 0.0) corner:(1.0 @ 1.0). |
|
121 |
b1 := Button label:'button1' in:p. |
|
122 |
b2 := Button label:'button2' in:p. |
|
123 |
b3 := Button label:'button3' in:p. |
|
124 |
v extent:300 @ 100. |
|
125 |
v open |
|
126 |
[exEnd] |
|
127 |
||
128 |
||
129 |
invisible component not considered in layout: |
|
130 |
[exBegin] |
|
131 |
|v p b1 b2 b3| |
|
132 |
||
133 |
v := StandardSystemView new. |
|
134 |
v label:'panel'. |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
135 |
|
1604 | 136 |
p := PanelView in:v. |
137 |
p origin:(0.0 @ 0.0) corner:(1.0 @ 1.0). |
|
138 |
b1 := Button label:'button1' in:p. |
|
139 |
b2 := Button label:'button2' in:p. |
|
140 |
b2 beInvisible. |
|
141 |
b3 := Button label:'button3' in:p. |
|
142 |
v extent:300 @ 100. |
|
143 |
v open |
|
144 |
[exEnd] |
|
145 |
||
146 |
invisible component considered in layout: |
|
147 |
[exBegin] |
|
148 |
|v p b1 b2 b3| |
|
149 |
||
150 |
v := StandardSystemView new. |
|
151 |
v label:'panel'. |
|
152 |
||
153 |
p := PanelView in:v. |
|
154 |
p origin:(0.0 @ 0.0) corner:(1.0 @ 1.0). |
|
155 |
p ignoreInvisibleComponents:false. |
|
156 |
b1 := Button label:'button1' in:p. |
|
157 |
b2 := Button label:'button2' in:p. |
|
158 |
b2 beInvisible. |
|
159 |
b3 := Button label:'button3' in:p. |
|
160 |
v extent:300 @ 100. |
|
161 |
v open |
|
162 |
[exEnd] |
|
38 | 163 |
" |
787
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
164 |
! ! |
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
165 |
|
202 | 166 |
!PanelView methodsFor:'accessing'! |
167 |
||
1959 | 168 |
elementsChangeSize |
169 |
"tell the panel if elements are to change their size by themselfes |
|
170 |
(for example, Labels or Buttons may do so if their contents changes). |
|
171 |
Setting this flag will make the panel reorganize the elements whenever |
|
172 |
any element changes its size." |
|
173 |
||
174 |
^ elementsChangeSize |
|
175 |
! |
|
176 |
||
202 | 177 |
elementsChangeSize:aBoolean |
178 |
"tell the panel if elements are to change their size by themselfes |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
179 |
(for example, Labels or Buttons may do so if their contents changes). |
202 | 180 |
Setting this flag will make the panel reorganize the elements whenever |
181 |
any element changes its size." |
|
182 |
||
3117
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
183 |
elementsChangeSize ~~ aBoolean ifTrue:[ |
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
184 |
elementsChangeSize := aBoolean. |
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
185 |
aBoolean ifTrue:[ |
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
186 |
self makeMyselfDependentOnSubviews. |
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
187 |
]. |
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
188 |
]. |
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
189 |
! |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
190 |
|
3843 | 191 |
hierarchicalIndexOfChild:aView |
192 |
^ aView hierarchicalIndexInList:subViews |
|
193 |
! |
|
194 |
||
1036 | 195 |
horizontalLayout |
196 |
"not supported by this view" |
|
197 |
||
198 |
^ nil |
|
199 |
! |
|
200 |
||
201 |
horizontalLayout:aLayoutSymbol |
|
202 |
"not supported by this view" |
|
203 |
||
204 |
! |
|
205 |
||
5905 | 206 |
horizontalLayout:layoutSymbolH verticalLayout:layoutSymbolV |
207 |
self horizontalLayout:layoutSymbolH. |
|
208 |
self verticalLayout:layoutSymbolV |
|
209 |
! |
|
210 |
||
1072 | 211 |
horizontalSpace |
212 |
"return the horizontal space between elements on pixels (default is 1mm)" |
|
213 |
||
214 |
^ horizontalSpace |
|
215 |
! |
|
216 |
||
202 | 217 |
horizontalSpace:numberOfPixels |
218 |
"set the horizontal space between elements on pixels (default is 1mm)" |
|
219 |
||
220 |
horizontalSpace ~= numberOfPixels ifTrue:[ |
|
221 |
horizontalSpace := numberOfPixels. |
|
222 |
self layoutChanged |
|
223 |
] |
|
224 |
! |
|
225 |
||
1423 | 226 |
ignoreInvisibleComponents |
227 |
"return the flag which controls if invisible (unrealized) |
|
228 |
components should be ignored in the layout computation. |
|
229 |
By default, it is false, which means that invisible components will |
|
230 |
lead to a visible space between visible components" |
|
231 |
||
232 |
^ ignoreInvisibleComponents |
|
233 |
! |
|
234 |
||
235 |
ignoreInvisibleComponents:aBoolean |
|
236 |
"set/clears the flag which controls if invisible (unrealized) |
|
237 |
components should be ignored in the layout computation. |
|
238 |
By default, it is false, which means that invisible components will |
|
2006 | 239 |
lead to a visible space between visible components." |
1423 | 240 |
|
1605
6ddd87c04fd5
recompute layout when ignoreInvisible* is changed.
Claus Gittinger <cg@exept.de>
parents:
1604
diff
changeset
|
241 |
(ignoreInvisibleComponents ~~ aBoolean) ifTrue:[ |
2006 | 242 |
aBoolean ifTrue:[ |
243 |
self makeMyselfDependentOnSubviews. |
|
244 |
]. |
|
1605
6ddd87c04fd5
recompute layout when ignoreInvisible* is changed.
Claus Gittinger <cg@exept.de>
parents:
1604
diff
changeset
|
245 |
ignoreInvisibleComponents := aBoolean. |
6ddd87c04fd5
recompute layout when ignoreInvisible* is changed.
Claus Gittinger <cg@exept.de>
parents:
1604
diff
changeset
|
246 |
self layoutChanged |
6ddd87c04fd5
recompute layout when ignoreInvisible* is changed.
Claus Gittinger <cg@exept.de>
parents:
1604
diff
changeset
|
247 |
] |
6ddd87c04fd5
recompute layout when ignoreInvisible* is changed.
Claus Gittinger <cg@exept.de>
parents:
1604
diff
changeset
|
248 |
|
6ddd87c04fd5
recompute layout when ignoreInvisible* is changed.
Claus Gittinger <cg@exept.de>
parents:
1604
diff
changeset
|
249 |
"Modified: / 20.7.1998 / 14:12:38 / cg" |
1423 | 250 |
! |
251 |
||
202 | 252 |
space:numberOfPixels |
253 |
"set the space between elements in pixels (default is 1mm) for both directions" |
|
254 |
||
255 |
(verticalSpace ~= numberOfPixels |
|
256 |
or:[horizontalSpace ~= numberOfPixels]) ifTrue:[ |
|
257 |
horizontalSpace := numberOfPixels. |
|
258 |
verticalSpace := numberOfPixels. |
|
259 |
self layoutChanged |
|
260 |
] |
|
261 |
! |
|
262 |
||
1036 | 263 |
verticalLayout |
264 |
"not supported by this view" |
|
265 |
||
266 |
^ nil |
|
267 |
! |
|
268 |
||
269 |
verticalLayout:aLayoutSymbol |
|
270 |
"not supported by this view" |
|
271 |
||
272 |
! |
|
273 |
||
1072 | 274 |
verticalSpace |
275 |
"return the vertical space between elements on pixels (default is 1mm)" |
|
276 |
||
277 |
^ verticalSpace |
|
278 |
! |
|
279 |
||
202 | 280 |
verticalSpace:numberOfPixels |
281 |
"set the vertical space between elements (in pixels). |
|
282 |
The default is computed for 1mm spacing." |
|
283 |
||
284 |
verticalSpace ~= numberOfPixels ifTrue:[ |
|
285 |
verticalSpace := numberOfPixels. |
|
286 |
self layoutChanged |
|
287 |
] |
|
288 |
! ! |
|
289 |
||
4415 | 290 |
!PanelView methodsFor:'accessing-channels'! |
291 |
||
292 |
backgroundChannel |
|
293 |
"return a valueHolder for background color" |
|
294 |
||
295 |
^ backgroundChannel |
|
296 |
||
297 |
"Modified: / 30.3.1999 / 13:49:28 / stefan" |
|
298 |
"Created: / 30.3.1999 / 13:50:55 / stefan" |
|
299 |
! |
|
300 |
||
301 |
backgroundChannel:aValueHolder |
|
302 |
"set the backgroundChannel - a valueHolder holding a color" |
|
303 |
||
304 |
|prev| |
|
305 |
||
306 |
prev := backgroundChannel. |
|
307 |
backgroundChannel := aValueHolder. |
|
308 |
self setupChannel:aValueHolder for:#backgroundColorChanged withOld:prev |
|
309 |
||
310 |
"Modified: / 31.10.1997 / 14:38:38 / cg" |
|
311 |
"Created: / 30.3.1999 / 13:48:42 / stefan" |
|
312 |
! ! |
|
313 |
||
202 | 314 |
!PanelView methodsFor:'adding & removing subviews'! |
315 |
||
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
316 |
addComponent:aComponent |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
317 |
"redefined to recompute layout when a component is added" |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
318 |
|
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
319 |
super addComponent:aComponent. |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
320 |
self addedView:aComponent |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
321 |
|
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
322 |
"Created: 28.1.1997 / 17:44:18 / cg" |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
323 |
! |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
324 |
|
202 | 325 |
addSubView:aView |
326 |
"redefined to recompute layout when a subview is added" |
|
327 |
||
328 |
super addSubView:aView. |
|
329 |
self addedView:aView |
|
330 |
! |
|
331 |
||
4406 | 332 |
addSubView:newView after:aViewOrNil |
202 | 333 |
"redefined to recompute layout when a subview is added" |
334 |
||
4406 | 335 |
super addSubView:newView after:aViewOrNil. |
787
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
336 |
self addedView:newView |
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
337 |
|
4406 | 338 |
"Modified: / 15-07-1996 / 10:15:04 / cg" |
339 |
"Modified (format): / 22-03-2012 / 10:37:42 / cg" |
|
202 | 340 |
! |
341 |
||
4406 | 342 |
addSubView:newView before:aViewOrNil |
202 | 343 |
"redefined to recompute layout when a subview is added" |
344 |
||
4406 | 345 |
super addSubView:newView before:aViewOrNil. |
787
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
346 |
self addedView:newView |
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
347 |
|
4406 | 348 |
"Modified: / 15-07-1996 / 10:14:39 / cg" |
349 |
"Modified (format): / 22-03-2012 / 10:37:46 / cg" |
|
202 | 350 |
! |
351 |
||
352 |
removeSubView:aView |
|
353 |
"redefined to recompute layout when a subview is removed" |
|
354 |
||
355 |
super removeSubView:aView. |
|
356 |
aView removeDependent:self. |
|
5536 | 357 |
self isBeingDestroyed ifFalse:[ |
358 |
self layoutChanged |
|
359 |
]. |
|
38 | 360 |
! ! |
0 | 361 |
|
1159 | 362 |
!PanelView methodsFor:'enumerating subviews'! |
363 |
||
364 |
changeSequenceOrderFor:aSubView to:anIndex |
|
3885 | 365 |
"change a subview's position in the subviews collection. |
366 |
This affects the arrangemnt of the views." |
|
367 |
||
1159 | 368 |
|success| |
369 |
||
370 |
success := super changeSequenceOrderFor:aSubView to:anIndex. |
|
371 |
||
372 |
success ifTrue:[ |
|
3885 | 373 |
self layoutChanged. |
1159 | 374 |
]. |
375 |
^ success |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
376 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
377 |
" |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
378 |
|panel comp1 comp2 comp3| |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
379 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
380 |
panel := HorizontalPanelView new. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
381 |
comp1 := Label label:'one' in:panel. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
382 |
comp2 := Label label:'two' in:panel. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
383 |
comp3 := Label label:'three' in:panel. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
384 |
panel open. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
385 |
Delay waitForSeconds:3. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
386 |
panel changeSequenceOrderFor:comp2 to:3. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
387 |
Delay waitForSeconds:3. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
388 |
panel changeSequenceOrderFor:comp2 to:1. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
389 |
" |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
390 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
391 |
"Modified: / 17.1.1998 / 00:13:43 / cg" |
1159 | 392 |
! ! |
393 |
||
2753 | 394 |
!PanelView methodsFor:'event handling'! |
0 | 395 |
|
4415 | 396 |
backgroundColorChanged |
397 |
"called to update the background color" |
|
398 |
||
399 |
|color| |
|
400 |
||
401 |
color := backgroundChannel value. |
|
402 |
self backgroundColor:color. |
|
403 |
! |
|
404 |
||
0 | 405 |
sizeChanged:how |
119 | 406 |
"my size has changed - must rearrange elements" |
407 |
||
0 | 408 |
super sizeChanged:how. |
4945 | 409 |
"/ self layoutChanged - no; leads to recursion |
410 |
realized ifTrue:[ |
|
411 |
self setChildPositions |
|
412 |
] ifFalse:[ |
|
413 |
mustRearrange := true |
|
414 |
]. |
|
125 | 415 |
! |
416 |
||
417 |
update:something with:aParameter from:changedObject |
|
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
418 |
"an element changed its size" |
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
419 |
|
125 | 420 |
something == #sizeOfView ifTrue:[ |
3117
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
421 |
elementsChangeSize ifTrue:[ |
2034
2efa727de60f
avoid useless work (ignore updates from changed components sometimes)
Claus Gittinger <cg@exept.de>
parents:
2006
diff
changeset
|
422 |
self layoutChanged. |
2efa727de60f
avoid useless work (ignore updates from changed components sometimes)
Claus Gittinger <cg@exept.de>
parents:
2006
diff
changeset
|
423 |
]. |
2006 | 424 |
^ self |
425 |
]. |
|
2190 | 426 |
"/ something == #preferredExtent ifTrue:[ |
3117
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
427 |
"/ elementsChangeSize ifTrue:[ |
2190 | 428 |
"/ self layoutChanged. |
429 |
"/ ]. |
|
430 |
"/ ^ self |
|
431 |
"/ ]. |
|
2006 | 432 |
something == #visibility ifTrue:[ |
3117
6d0c7aa281f2
#elementsChangeSize: do nothing, if instance var doesn't change
Stefan Vogel <sv@exept.de>
parents:
2753
diff
changeset
|
433 |
ignoreInvisibleComponents ifTrue:[ |
2034
2efa727de60f
avoid useless work (ignore updates from changed components sometimes)
Claus Gittinger <cg@exept.de>
parents:
2006
diff
changeset
|
434 |
self layoutChanged. |
2efa727de60f
avoid useless work (ignore updates from changed components sometimes)
Claus Gittinger <cg@exept.de>
parents:
2006
diff
changeset
|
435 |
]. |
2006 | 436 |
^ self |
125 | 437 |
]. |
438 |
^ super update:something with:aParameter from:changedObject |
|
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
439 |
|
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
440 |
"Modified: 28.1.1997 / 17:52:44 / cg" |
0 | 441 |
! ! |
442 |
||
1821
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
443 |
!PanelView methodsFor:'focus handling'! |
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
444 |
|
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
445 |
wantsFocusWithButtonPress |
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
446 |
"no, do not catch the keyboard focus on button click" |
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
447 |
|
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
448 |
^ false |
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
449 |
|
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
450 |
|
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
451 |
! ! |
b57cc9dc2c08
changed request-focus-with-Button press
Claus Gittinger <cg@exept.de>
parents:
1605
diff
changeset
|
452 |
|
6275 | 453 |
!PanelView methodsFor:'initialization & release'! |
202 | 454 |
|
455 |
initialize |
|
6076 | 456 |
<modifier: #super> "must be called if redefined" |
457 |
||
202 | 458 |
super initialize. |
459 |
||
460 |
hLayout := vLayout := #center. "/ notice, this is ignored in this class |
|
6076 | 461 |
"/ used by subclasses only |
202 | 462 |
verticalSpace := ViewSpacing. |
463 |
horizontalSpace := ViewSpacing. |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
464 |
mustRearrange := elementsChangeSize := false. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
465 |
ignoreInvisibleComponents := true. |
6076 | 466 |
|
467 |
"Modified: / 08-02-2017 / 00:35:19 / cg" |
|
202 | 468 |
! |
469 |
||
5516 | 470 |
mapped |
471 |
mustRearrange ifTrue:[ |
|
472 |
self setChildPositions |
|
473 |
]. |
|
474 |
super mapped |
|
475 |
! |
|
476 |
||
202 | 477 |
realize |
478 |
mustRearrange ifTrue:[ |
|
479 |
self setChildPositions |
|
480 |
]. |
|
481 |
super realize |
|
482 |
! |
|
483 |
||
6275 | 484 |
release |
485 |
backgroundChannel notNil ifTrue:[ |
|
486 |
backgroundChannel retractInterestsFor:self. |
|
487 |
backgroundChannel removeDependent:self. backgroundChannel := nil |
|
488 |
]. |
|
489 |
super release |
|
490 |
! |
|
491 |
||
1216
3506a6474c42
setChildPos if extent is set in create->resize->prefExtent
ca
parents:
1159
diff
changeset
|
492 |
resize |
3506a6474c42
setChildPos if extent is set in create->resize->prefExtent
ca
parents:
1159
diff
changeset
|
493 |
super resize. |
3506a6474c42
setChildPos if extent is set in create->resize->prefExtent
ca
parents:
1159
diff
changeset
|
494 |
mustRearrange ifTrue:[ |
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
495 |
self setChildPositions |
1216
3506a6474c42
setChildPos if extent is set in create->resize->prefExtent
ca
parents:
1159
diff
changeset
|
496 |
]. |
3506a6474c42
setChildPos if extent is set in create->resize->prefExtent
ca
parents:
1159
diff
changeset
|
497 |
! |
3506a6474c42
setChildPos if extent is set in create->resize->prefExtent
ca
parents:
1159
diff
changeset
|
498 |
|
202 | 499 |
setChildPositionsIfChanged |
500 |
"set all of my child positions - this is usually delayed, |
|
6165 | 501 |
until the panel is actually shown (since we do not know, if more |
202 | 502 |
elements are to be added) thus avoiding repositioning the elements |
6165 | 503 |
over and over. However, sometimes it is necessary to force positioning |
202 | 504 |
the elements, for example, before querying the relative position of |
6165 | 505 |
an element (modalBoxes do so, to position the OK-button under the mouse |
202 | 506 |
pointer)." |
507 |
||
508 |
mustRearrange ifTrue:[ |
|
5951 | 509 |
self setChildPositions |
202 | 510 |
]. |
6165 | 511 |
|
512 |
"Modified (comment): / 30-05-2017 / 17:36:26 / mawalch" |
|
202 | 513 |
! ! |
514 |
||
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
515 |
!PanelView methodsFor:'layout'! |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
516 |
|
3861 | 517 |
preferredExtent |
518 |
"return a good extent, one that makes subviews fit. |
|
519 |
Note that width is considered as given, and compute height here." |
|
520 |
||
521 |
|subViews xpos totalHeight maxHeightInRow first| |
|
522 |
||
523 |
"/ If I have an explicit preferredExtent.. |
|
524 |
explicitExtent notNil ifTrue:[ |
|
525 |
^ explicitExtent |
|
526 |
]. |
|
527 |
||
528 |
"/ If I have a cached preferredExtent value.. |
|
529 |
preferredExtent notNil ifTrue:[ |
|
530 |
^ preferredExtent |
|
531 |
]. |
|
532 |
||
533 |
subViews := self subViewsToConsider. |
|
534 |
subViews isEmptyOrNil ifTrue:[ |
|
535 |
^ super preferredExtent. |
|
536 |
]. |
|
537 |
||
538 |
xpos := horizontalSpace. |
|
539 |
||
540 |
totalHeight := 0. |
|
541 |
maxHeightInRow := 0. |
|
542 |
first := true. |
|
543 |
||
544 |
subViews do:[:eachChild | |childPreferredExtent| |
|
545 |
childPreferredExtent := eachChild preferredExtent. |
|
546 |
||
547 |
"go to next row, if this subview won't fit" |
|
548 |
first ifFalse: [ |
|
549 |
(xpos + childPreferredExtent x + horizontalSpace) > width |
|
550 |
ifTrue: [ |
|
551 |
xpos := horizontalSpace. |
|
552 |
totalHeight := totalHeight + maxHeightInRow + verticalSpace. |
|
553 |
maxHeightInRow := 0. |
|
554 |
] |
|
555 |
]. |
|
556 |
||
557 |
xpos := xpos + (childPreferredExtent x) + horizontalSpace. |
|
558 |
(maxHeightInRow < (childPreferredExtent y)) ifTrue:[ |
|
559 |
maxHeightInRow := childPreferredExtent y. |
|
560 |
]. |
|
561 |
first := false |
|
562 |
]. |
|
563 |
maxHeightInRow ~= 0 ifTrue:[ |
|
564 |
totalHeight := totalHeight + maxHeightInRow + verticalSpace. |
|
565 |
]. |
|
566 |
||
567 |
^ width @ totalHeight |
|
568 |
! |
|
569 |
||
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
570 |
setChildPositions |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
571 |
"(re)compute position of every child. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
572 |
This method is redefined for different layout characteristics - you may |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
573 |
even create subclasses with completely different geometry management." |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
574 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
575 |
|first xpos ypos maxHeightInRow thisRow subViews ext| |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
576 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
577 |
subViews := self subViewsToConsider. |
1423 | 578 |
subViews size == 0 ifTrue:[^ self]. |
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
579 |
|
3501 | 580 |
"/ self extentChangedFlag ifTrue:[ |
581 |
"/ ext := self computeExtent. |
|
582 |
"/ width := ext x. |
|
583 |
"/ height := ext y. |
|
584 |
"/ ]. |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
585 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
586 |
xpos := horizontalSpace. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
587 |
ypos := verticalSpace. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
588 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
589 |
maxHeightInRow := 0. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
590 |
first := true. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
591 |
thisRow := OrderedCollection new. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
592 |
subViews do:[:child | |
1423 | 593 |
"go to next row, if this subview won't fit" |
594 |
first ifFalse: [ |
|
595 |
(xpos + child widthIncludingBorder + horizontalSpace) > width |
|
596 |
ifTrue: [ |
|
597 |
thisRow notEmpty ifTrue:[ |
|
598 |
thisRow do:[:rowElement | |
|
599 |
rowElement heightIncludingBorder < maxHeightInRow ifTrue:[ |
|
600 |
rowElement top:(rowElement top + (maxHeightInRow - rowElement heightIncludingBorder)) |
|
601 |
] |
|
602 |
] |
|
603 |
]. |
|
604 |
ypos := ypos + verticalSpace + maxHeightInRow. |
|
605 |
xpos := horizontalSpace. |
|
606 |
maxHeightInRow := 0. |
|
607 |
thisRow := OrderedCollection new. |
|
608 |
] |
|
609 |
]. |
|
610 |
thisRow add:child. |
|
611 |
child origin:(xpos@ypos). |
|
612 |
xpos := xpos + (child widthIncludingBorder) + horizontalSpace. |
|
613 |
(maxHeightInRow < (child heightIncludingBorder)) ifTrue:[ |
|
614 |
maxHeightInRow := child heightIncludingBorder |
|
615 |
]. |
|
616 |
first := false |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
617 |
]. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
618 |
thisRow notEmpty ifTrue:[ |
1423 | 619 |
thisRow do:[:rowElement | |
620 |
rowElement heightIncludingBorder < maxHeightInRow ifTrue:[ |
|
621 |
rowElement top:(rowElement top + (maxHeightInRow - rowElement heightIncludingBorder)) |
|
622 |
] |
|
623 |
] |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
624 |
]. |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
625 |
mustRearrange := false |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
626 |
|
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
627 |
"Modified: / 17.1.1998 / 00:17:19 / cg" |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
628 |
! ! |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
629 |
|
0 | 630 |
!PanelView methodsFor:'private'! |
631 |
||
202 | 632 |
addedView:aView |
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
633 |
"added a new element - rearrange components" |
202 | 634 |
|
2006 | 635 |
(elementsChangeSize or:[ignoreInvisibleComponents]) ifTrue:[ |
636 |
aView addDependent:self |
|
787
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
637 |
]. |
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
638 |
aView resize. |
788
653fd742b5b0
extent handling when adding views
Claus Gittinger <cg@exept.de>
parents:
787
diff
changeset
|
639 |
"/ explicitExtent ~~ true ifTrue:[ |
653fd742b5b0
extent handling when adding views
Claus Gittinger <cg@exept.de>
parents:
787
diff
changeset
|
640 |
"/ self resize |
653fd742b5b0
extent handling when adding views
Claus Gittinger <cg@exept.de>
parents:
787
diff
changeset
|
641 |
"/ ]. |
202 | 642 |
self layoutChanged |
787
c568dfd06f11
recompute & resize to the preferredExtent when views are added
Claus Gittinger <cg@exept.de>
parents:
593
diff
changeset
|
643 |
|
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
644 |
"Modified: 28.1.1997 / 17:45:10 / cg" |
202 | 645 |
! |
646 |
||
0 | 647 |
layoutChanged |
119 | 648 |
"called whenever repositioning is required. If the panel view is |
649 |
already visible, reposition elements right now. Otherwise, remember |
|
650 |
that a repositioning is needed to do so when the view eventually becomes |
|
651 |
visible." |
|
652 |
||
4945 | 653 |
super layoutChanged. |
2198 | 654 |
realized ifTrue:[ |
655 |
self setChildPositions |
|
0 | 656 |
] ifFalse:[ |
2198 | 657 |
mustRearrange := true |
4945 | 658 |
]. |
0 | 659 |
! |
660 |
||
2006 | 661 |
makeMyselfDependentOnSubviews |
2527 | 662 |
subViews notNil ifTrue:[ |
2006 | 663 |
subViews do:[:aView | |
664 |
aView addDependent:self |
|
665 |
] |
|
666 |
] |
|
667 |
! |
|
668 |
||
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
669 |
subViewsToConsider |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
670 |
"return a collection of subviews which are to be considered in |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
671 |
the layout. If ignoreInvisibleComponents is true, only visible |
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
672 |
components are considered; otherwise, all are considered." |
0 | 673 |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
674 |
|subViews| |
1042 | 675 |
|
676 |
subViews := self subViews. |
|
3779 | 677 |
ignoreInvisibleComponents ifTrue:[ |
678 |
subViews size ~~ 0 ifTrue:[ |
|
679 |
subViews := subViews |
|
5907 | 680 |
select:[:v | |
5920 | 681 |
"/ if I am already realized, only consider realized subViews |
682 |
"/ otherwise, consider subViews which will be shown when I am. |
|
683 |
realized |
|
684 |
ifTrue:[v realized] |
|
685 |
ifFalse:[v isHiddenOnRealize not] |
|
3779 | 686 |
]. |
687 |
]. |
|
1042 | 688 |
]. |
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
689 |
^ subViews |
1042 | 690 |
|
1418
3397ec6b8419
added ignoreInvisibleComponents stuff
Claus Gittinger <cg@exept.de>
parents:
1216
diff
changeset
|
691 |
"Created: / 17.1.1998 / 00:17:05 / cg" |
0 | 692 |
! ! |
125 | 693 |
|
3863
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
694 |
!PanelView methodsFor:'queries'! |
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
695 |
|
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
696 |
isLayoutWrapper |
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
697 |
"answer true, if this view defines the layout of it's subviews" |
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
698 |
|
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
699 |
^ true |
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
700 |
! ! |
eceb130bb92b
UIPainter can now resize subviews of PanelViews
Stefan Vogel <sv@exept.de>
parents:
3861
diff
changeset
|
701 |
|
980
6079922a5519
eliminated references to subViews instance variable (will vanish)
Claus Gittinger <cg@exept.de>
parents:
788
diff
changeset
|
702 |
!PanelView class methodsFor:'documentation'! |
205 | 703 |
|
704 |
version |
|
5516 | 705 |
^ '$Header$' |
5907 | 706 |
! |
707 |
||
708 |
version_CVS |
|
709 |
^ '$Header$' |
|
205 | 710 |
! ! |
4945 | 711 |