343
|
1 |
"
|
|
2 |
COPYRIGHT (c) 1997 by eXept Software AG
|
|
3 |
All Rights Reserved
|
|
4 |
|
|
5 |
This software is furnished under a license and may be used
|
|
6 |
only in accordance with the terms of that license and with the
|
|
7 |
inclusion of the above copyright notice. This software may not
|
|
8 |
be provided or otherwise made available to, or used by, any
|
|
9 |
other person. No title to or ownership of the software is
|
|
10 |
hereby transferred.
|
|
11 |
"
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
Object subclass:#TabWidget
|
350
|
16 |
instanceVariableNames:'tabView label origin extent inset lineNr'
|
343
|
17 |
classVariableNames:''
|
|
18 |
poolDictionaries:''
|
|
19 |
category:'Views-Interactors'
|
|
20 |
!
|
|
21 |
|
350
|
22 |
TabWidget subclass:#Window
|
343
|
23 |
instanceVariableNames:''
|
|
24 |
classVariableNames:''
|
|
25 |
poolDictionaries:''
|
|
26 |
privateIn:TabWidget
|
|
27 |
!
|
|
28 |
|
351
|
29 |
TabWidget subclass:#Mac
|
343
|
30 |
instanceVariableNames:''
|
|
31 |
classVariableNames:''
|
|
32 |
poolDictionaries:''
|
|
33 |
privateIn:TabWidget
|
|
34 |
!
|
|
35 |
|
351
|
36 |
TabWidget subclass:#Folder
|
343
|
37 |
instanceVariableNames:''
|
|
38 |
classVariableNames:''
|
|
39 |
poolDictionaries:''
|
|
40 |
privateIn:TabWidget
|
|
41 |
!
|
|
42 |
|
|
43 |
!TabWidget class methodsFor:'documentation'!
|
|
44 |
|
|
45 |
copyright
|
|
46 |
"
|
|
47 |
COPYRIGHT (c) 1997 by eXept Software AG
|
|
48 |
All Rights Reserved
|
|
49 |
|
|
50 |
This software is furnished under a license and may be used
|
|
51 |
only in accordance with the terms of that license and with the
|
|
52 |
inclusion of the above copyright notice. This software may not
|
|
53 |
be provided or otherwise made available to, or used by, any
|
|
54 |
other person. No title to or ownership of the software is
|
|
55 |
hereby transferred.
|
|
56 |
"
|
|
57 |
|
|
58 |
|
|
59 |
!
|
|
60 |
|
|
61 |
documentation
|
|
62 |
"
|
|
63 |
instances represent (& draw) the tabs of a tabWidget.
|
|
64 |
|
|
65 |
[author:]
|
|
66 |
Claus Atzkern
|
|
67 |
|
|
68 |
[see also:]
|
|
69 |
TabView
|
|
70 |
"
|
|
71 |
! !
|
|
72 |
|
|
73 |
!TabWidget class methodsFor:'instance creation'!
|
|
74 |
|
|
75 |
label:aLabel for:aTabView
|
|
76 |
"create tab
|
|
77 |
"
|
|
78 |
^ self new label:aLabel for:aTabView
|
|
79 |
! !
|
|
80 |
|
|
81 |
!TabWidget class methodsFor:'accessing'!
|
|
82 |
|
|
83 |
tabStyleOn:aView
|
|
84 |
"returns default tab style
|
|
85 |
"
|
|
86 |
|style selectedColor unselectedColor|
|
|
87 |
|
|
88 |
style := IdentityDictionary new.
|
|
89 |
selectedColor := Color gray:90.
|
|
90 |
unselectedColor := Color gray:75.
|
|
91 |
|
|
92 |
style at:#widget put:self.
|
|
93 |
|
|
94 |
style at:#shadowColorSelected
|
|
95 |
put:((selectedColor averageColorIn:(0@0 corner:7@7)) darkened on:aView device).
|
|
96 |
|
|
97 |
style at:#lightColorSelected
|
|
98 |
put:((selectedColor averageColorIn:(0@0 corner:7@7)) lightened on:aView device).
|
|
99 |
|
|
100 |
style at:#shadowColorUnselected
|
|
101 |
put:((unselectedColor averageColorIn:(0@0 corner:7@7)) darkened on:aView device).
|
|
102 |
|
|
103 |
style at:#lightColorUnselected
|
|
104 |
put:((unselectedColor averageColorIn:(0@0 corner:7@7)) lightened on:aView device).
|
|
105 |
|
351
|
106 |
style at:#unselectedColor put:unselectedColor.
|
|
107 |
style at:#selectedColor put:selectedColor.
|
|
108 |
style at:#labelColor put:(Color black).
|
|
109 |
style at:#selectionAtBottom put:false. "/ true: selected tab always moved to bottom
|
343
|
110 |
|
351
|
111 |
style at:#vspace put:0. "/ vertical tab space
|
|
112 |
style at:#hspace put:0. "/ horizontal tab space
|
|
113 |
style at:#leftOverLap put:0. "/ right tab overlaps left tab n pixels
|
|
114 |
style at:#lableTopInset put:4. "/ additional top label inset
|
|
115 |
style at:#labelBottomInset put:4. "/ additional bottom inset
|
|
116 |
style at:#expandSelection put:0@0. "/ expand selection extent x y when raised
|
|
117 |
style at:#fixedLabelSize put:false. "/ true: label size derives from preferred extent
|
343
|
118 |
|
|
119 |
|
|
120 |
^ style
|
|
121 |
!
|
|
122 |
|
|
123 |
widgetClass:aWidget
|
|
124 |
|wdg nm|
|
|
125 |
|
|
126 |
nm := aWidget asString.
|
|
127 |
|
|
128 |
(wdg := Smalltalk classNamed:(self name asString, '::', nm)) notNil ifTrue:[
|
|
129 |
^ wdg
|
|
130 |
].
|
|
131 |
^ Smalltalk classNamed:nm
|
|
132 |
! !
|
|
133 |
|
|
134 |
!TabWidget class methodsFor:'constants'!
|
|
135 |
|
|
136 |
defaultExtent
|
|
137 |
^ 80 @ 25
|
|
138 |
|
|
139 |
|
|
140 |
!
|
|
141 |
|
|
142 |
labelLeftInset
|
|
143 |
^ 4
|
350
|
144 |
!
|
|
145 |
|
|
146 |
labelRightInset
|
|
147 |
^ 4
|
343
|
148 |
! !
|
|
149 |
|
|
150 |
!TabWidget methodsFor:'accessing'!
|
|
151 |
|
|
152 |
extent
|
|
153 |
"return the tab extent
|
|
154 |
"
|
|
155 |
^ extent
|
|
156 |
!
|
|
157 |
|
|
158 |
extent:anExtent
|
|
159 |
"change the tab extent; no redraw
|
|
160 |
"
|
|
161 |
extent := anExtent
|
|
162 |
!
|
|
163 |
|
|
164 |
inset
|
|
165 |
"returns the bottom inset starting from 1.0
|
|
166 |
"
|
|
167 |
^ inset
|
|
168 |
!
|
|
169 |
|
|
170 |
inset:anInset
|
|
171 |
"change the bottom inset starting from 1.0; no redraw
|
|
172 |
"
|
|
173 |
inset := anInset
|
|
174 |
!
|
|
175 |
|
351
|
176 |
label
|
|
177 |
^ label
|
|
178 |
!
|
|
179 |
|
343
|
180 |
labelOrigin
|
|
181 |
"returns origin of label
|
|
182 |
"
|
|
183 |
^ (self labelOriginWithinFrame)
|
|
184 |
+ ((tabView styleAt:#leftOverLap) @ (tabView styleAt:#lableTopInset))
|
|
185 |
!
|
|
186 |
|
350
|
187 |
lineNr
|
|
188 |
"returns line number
|
|
189 |
"
|
|
190 |
^ lineNr
|
|
191 |
!
|
|
192 |
|
|
193 |
lineNr:aLineNr
|
|
194 |
"change line number
|
|
195 |
"
|
|
196 |
lineNr := aLineNr
|
|
197 |
!
|
|
198 |
|
343
|
199 |
origin
|
|
200 |
"returns the tab origin
|
|
201 |
"
|
|
202 |
^ origin
|
|
203 |
|
|
204 |
!
|
|
205 |
|
|
206 |
origin:anOrigin
|
|
207 |
"change the tab origin; no redraw
|
|
208 |
"
|
|
209 |
origin := anOrigin
|
|
210 |
|
|
211 |
!
|
|
212 |
|
|
213 |
origin:anOrigin extent:anExtent inset:anInset
|
|
214 |
"change origin, extent and bottom inset starting from 1.0; no redraw
|
|
215 |
"
|
|
216 |
origin := anOrigin.
|
|
217 |
extent := anExtent.
|
|
218 |
inset := anInset.
|
|
219 |
|
|
220 |
|
|
221 |
!
|
|
222 |
|
|
223 |
preferredExtent
|
|
224 |
"returns my preferred extent
|
|
225 |
"
|
|
226 |
|x y|
|
|
227 |
|
|
228 |
label isNil ifTrue:[
|
|
229 |
^ self class defaultExtent
|
|
230 |
].
|
350
|
231 |
x := (label widthOn:tabView)
|
|
232 |
+ (self class labelRightInset)
|
|
233 |
+ (self class labelLeftInset).
|
|
234 |
|
343
|
235 |
y := (label heightOn:tabView)
|
|
236 |
+ (tabView styleAt:#labelBottomInset)
|
|
237 |
+ (tabView styleAt:#lableTopInset).
|
|
238 |
|
|
239 |
^ ((self labelOrigin) + (x@y))
|
|
240 |
! !
|
|
241 |
|
|
242 |
!TabWidget methodsFor:'drawing'!
|
|
243 |
|
|
244 |
redraw:isSelected
|
|
245 |
"full redraw
|
|
246 |
"
|
|
247 |
|p y|
|
|
248 |
|
|
249 |
self redrawSelected:isSelected.
|
|
250 |
tabView paintColor:#labelColor.
|
|
251 |
p := origin + self labelOrigin.
|
|
252 |
y := p y.
|
|
253 |
|
|
254 |
label isString ifTrue:[
|
|
255 |
y := y + tabView font ascent
|
|
256 |
].
|
|
257 |
label displayOn:tabView x:(p x) y:y.
|
|
258 |
! !
|
|
259 |
|
|
260 |
!TabWidget methodsFor:'initialization'!
|
|
261 |
|
|
262 |
label:aLabel for:aTabView
|
|
263 |
"initialize attributes
|
|
264 |
"
|
|
265 |
tabView := aTabView.
|
|
266 |
label := aLabel.
|
|
267 |
! !
|
|
268 |
|
|
269 |
!TabWidget methodsFor:'queries'!
|
|
270 |
|
|
271 |
containsPoint:aPoint
|
|
272 |
"return true, if the aPoint is contained in the tab
|
|
273 |
"
|
|
274 |
|x|
|
|
275 |
|
|
276 |
x := aPoint x.
|
|
277 |
|
351
|
278 |
(x >= origin x and:[aPoint y >= origin y]) ifTrue:[
|
343
|
279 |
^ x < (origin x + extent x)
|
|
280 |
].
|
|
281 |
^ false.
|
|
282 |
! !
|
|
283 |
|
|
284 |
!TabWidget methodsFor:'redefine'!
|
|
285 |
|
|
286 |
labelOriginWithinFrame
|
|
287 |
"returns the offset from origin to the origin of the label
|
|
288 |
"
|
|
289 |
^ (self class labelLeftInset) @ 0
|
|
290 |
|
|
291 |
!
|
|
292 |
|
|
293 |
redrawSelected:isSelected
|
|
294 |
"full redraw excluding the label
|
|
295 |
"
|
|
296 |
^ self subclassResponsibility
|
|
297 |
!
|
|
298 |
|
|
299 |
styleChanged:anIdentifier to:someThing
|
|
300 |
"any style changed; could be redifined in subclass
|
|
301 |
"
|
|
302 |
|dark light|
|
|
303 |
|
|
304 |
anIdentifier == #selectedColor ifTrue:[
|
|
305 |
dark := #shadowColorSelected.
|
|
306 |
light := #lightColorSelected.
|
|
307 |
] ifFalse:[
|
|
308 |
anIdentifier == #unselectedColor ifFalse:[
|
|
309 |
^ self
|
|
310 |
].
|
|
311 |
dark := #shadowColorUnselected.
|
|
312 |
light := #lightColorUnselected.
|
|
313 |
].
|
|
314 |
tabView styleAt:dark put:((someThing averageColorIn:(0@0 corner:7@7)) darkened on:tabView device).
|
|
315 |
tabView styleAt:light put:((someThing averageColorIn:(0@0 corner:7@7)) lightened on:tabView device).
|
|
316 |
|
|
317 |
! !
|
|
318 |
|
|
319 |
!TabWidget::Window class methodsFor:'accessing'!
|
|
320 |
|
|
321 |
tabStyleOn:aView
|
|
322 |
|style col|
|
|
323 |
|
|
324 |
style := super tabStyleOn:aView.
|
|
325 |
|
351
|
326 |
style at:#fixedLabelSize put:true.
|
|
327 |
style at:#tabLevel put:2.
|
|
328 |
style at:#roundedEdges put:true.
|
|
329 |
style at:#expandSelection put:4@4.
|
|
330 |
style at:#selectionAtBottom put:true.
|
343
|
331 |
|
|
332 |
^ style
|
|
333 |
|
|
334 |
|
|
335 |
|
|
336 |
! !
|
|
337 |
|
|
338 |
!TabWidget::Window methodsFor:'redifined'!
|
|
339 |
|
|
340 |
labelOriginWithinFrame
|
|
341 |
|org|
|
|
342 |
|
|
343 |
org := super labelOriginWithinFrame.
|
|
344 |
^ org + (tabView styleAt:#tabLevel)
|
|
345 |
|
|
346 |
|
|
347 |
!
|
|
348 |
|
|
349 |
redrawSelected:isSelected
|
|
350 |
"redraw; set fill-color to aColor.
|
|
351 |
"
|
|
352 |
|polygon color y x ext xR yB tabLevel light roundedEdges shadowColor lightColor|
|
|
353 |
|
|
354 |
ext := (extent x) @ (tabView extent y - inset).
|
|
355 |
x := origin x.
|
|
356 |
y := origin y.
|
|
357 |
xR := x + ext x - 1.
|
|
358 |
yB := ext y - 1.
|
|
359 |
|
|
360 |
roundedEdges := tabView styleAt:#roundedEdges.
|
|
361 |
tabLevel := tabView styleAt:#tabLevel.
|
|
362 |
|
|
363 |
isSelected ifFalse:[
|
|
364 |
color := tabView styleAt:#unselectedColor.
|
|
365 |
shadowColor := tabView styleAt:#shadowColorUnselected.
|
|
366 |
lightColor := tabView styleAt:#lightColorUnselected.
|
|
367 |
] ifTrue:[
|
|
368 |
color := tabView styleAt:#selectedColor.
|
|
369 |
shadowColor := tabView styleAt:#shadowColorSelected.
|
|
370 |
lightColor := tabView styleAt:#lightColorSelected.
|
|
371 |
yB := yB + 1
|
|
372 |
].
|
|
373 |
|
|
374 |
|
|
375 |
tabView paint:color.
|
|
376 |
tabView fillRectangle:(Rectangle left:x top:y extent:ext).
|
|
377 |
|
|
378 |
roundedEdges ifTrue:[
|
|
379 |
tabView displayLineFromX:x y:y-1 toX:xR y:y-1.
|
|
380 |
tabView displayLineFromX:x+1 y:y-2 toX:xR-1 y:y-2.
|
|
381 |
tabView displayLineFromX:x+2 y:y-3 toX:xR-2 y:y-3.
|
|
382 |
|
|
383 |
tabView paint:lightColor.
|
|
384 |
|
|
385 |
0 to:tabLevel-1 do:[:i |
|
|
386 |
tabView displayPointX:x+i y:y-1.
|
|
387 |
tabView displayPointX:x+1+i y:y-1-1.
|
|
388 |
tabView displayLineFromX:x+2+i y:y-3-i toX:xR-1-i y:y-3-i. "/ top
|
|
389 |
].
|
|
390 |
|
|
391 |
tabView paint:shadowColor.
|
|
392 |
0 to:tabLevel-1 do:[:i |
|
|
393 |
tabView displayPointX:xR-i y:y.
|
|
394 |
tabView displayPointX:xR-i y:y-1.
|
|
395 |
tabView displayPointX:xR-1-i y:y-1-1.
|
|
396 |
].
|
|
397 |
tabView displayPointX:xR-2 y:y-1-1-1.
|
|
398 |
tabView displayPointX:xR-3 y:y-1-1-1.
|
|
399 |
].
|
|
400 |
|
|
401 |
tabView paint:lightColor.
|
|
402 |
0 to:tabLevel-1 do:[:i |
|
|
403 |
roundedEdges ifFalse:[
|
|
404 |
tabView displayLineFromX:x y:y+i toX:xR y:y+i. "/ upper edge
|
|
405 |
].
|
|
406 |
tabView displayLineFromX:x+i y:y toX:x+i y:yB. "/ left edge
|
|
407 |
].
|
|
408 |
tabView paint:shadowColor.
|
|
409 |
0 to:tabLevel-1 do:[:i |
|
|
410 |
tabView displayLineFromX:xR-i y:y+i toX:xR-i y:yB. "/ right edge
|
|
411 |
].
|
|
412 |
|
|
413 |
isSelected ifFalse:[
|
|
414 |
"/ bottom edge
|
|
415 |
tabView paint:lightColor.
|
|
416 |
tabView displayLineFromX:x-tabLevel-1 y:yB toX:xR+tabLevel+1 y:yB. "/ bottom edge
|
|
417 |
] ifTrue:[
|
|
418 |
"/ tabView paintColor:#labelColor.
|
|
419 |
"/ tabView lineStyle:#dashed.
|
|
420 |
"/ tabView displayRectangle:((origin extent:extent) insetBy:(3@4)).
|
|
421 |
"/ tabView lineStyle:#solid
|
|
422 |
]
|
|
423 |
|
|
424 |
|
|
425 |
! !
|
|
426 |
|
351
|
427 |
!TabWidget::Mac class methodsFor:'accessing'!
|
|
428 |
|
|
429 |
tabStyleOn:aView
|
|
430 |
|style col|
|
|
431 |
|
|
432 |
style := super tabStyleOn:aView.
|
|
433 |
|
|
434 |
style at:#fixedLabelSize put:true.
|
|
435 |
style at:#leftOverLap put:10.
|
|
436 |
style at:#selectionAtBottom put:true.
|
|
437 |
^ style
|
|
438 |
|
|
439 |
|
|
440 |
! !
|
|
441 |
|
|
442 |
!TabWidget::Mac class methodsFor:'constants'!
|
|
443 |
|
|
444 |
rightInset
|
|
445 |
^ 25 "/ 23
|
|
446 |
! !
|
|
447 |
|
|
448 |
!TabWidget::Mac methodsFor:'redefine'!
|
|
449 |
|
|
450 |
preferredExtent
|
|
451 |
|
|
452 |
^ (super preferredExtent) + ((self class rightInset) @ 0).
|
|
453 |
!
|
|
454 |
|
|
455 |
redrawSelected:isSelected
|
|
456 |
"full redraw; excluding the label
|
|
457 |
"
|
|
458 |
|polygon x y x1 eX eY color shadowColor lightColor|
|
|
459 |
|
|
460 |
isSelected ifFalse:[
|
|
461 |
color := tabView styleAt:#unselectedColor.
|
|
462 |
shadowColor := tabView styleAt:#shadowColorUnselected.
|
|
463 |
lightColor := tabView styleAt:#lightColorUnselected.
|
|
464 |
] ifTrue:[
|
|
465 |
color := tabView styleAt:#selectedColor.
|
|
466 |
shadowColor := tabView styleAt:#shadowColorSelected.
|
|
467 |
lightColor := tabView styleAt:#lightColorSelected.
|
|
468 |
].
|
|
469 |
|
|
470 |
polygon := Array new:5.
|
|
471 |
x := origin x.
|
|
472 |
y := origin y.
|
|
473 |
eX := x + extent x - 1.
|
|
474 |
eY := tabView extent y - inset.
|
|
475 |
x1 := eX - self class rightInset.
|
|
476 |
|
|
477 |
polygon at:1 put:(Point x:x y:eY).
|
|
478 |
polygon at:2 put:(Point x:x y:y).
|
|
479 |
polygon at:3 put:(Point x:x1 y:y).
|
|
480 |
polygon at:4 put:(Point x:eX y:(y+extent y)).
|
|
481 |
polygon at:5 put:(Point x:eX y:eY).
|
|
482 |
|
|
483 |
tabView paint:color.
|
|
484 |
tabView fillPolygon:polygon.
|
|
485 |
|
|
486 |
tabView paint:lightColor.
|
|
487 |
tabView displayLineFromX:x+1 y:eY toX:x+1 y:y+1.
|
|
488 |
tabView displayLineFromX:x+1 y:y+1 toX:x1-1 y:y+1.
|
|
489 |
|
|
490 |
tabView paintColor:#labelColor.
|
|
491 |
tabView displayPolygon:polygon.
|
|
492 |
|
|
493 |
isSelected ifFalse:[
|
|
494 |
tabView paint:shadowColor.
|
|
495 |
tabView displayLineFromX:x y:eY-1 toX:eX y:eY-1.
|
|
496 |
]
|
|
497 |
|
|
498 |
|
|
499 |
! !
|
|
500 |
|
350
|
501 |
!TabWidget::Folder class methodsFor:'accessing'!
|
|
502 |
|
|
503 |
tabStyleOn:aView
|
|
504 |
|style|
|
|
505 |
|
|
506 |
style := super tabStyleOn:aView.
|
|
507 |
|
351
|
508 |
style at:#hspace put:2.
|
|
509 |
style at:#vspace put:2.
|
|
510 |
style at:#labelBottomInset put:10.
|
|
511 |
style at:#expandSelection put:4@8.
|
350
|
512 |
|
|
513 |
^ style
|
|
514 |
|
|
515 |
|
|
516 |
! !
|
|
517 |
|
|
518 |
!TabWidget::Folder class methodsFor:'constants'!
|
|
519 |
|
|
520 |
folderTabSize
|
|
521 |
^ 4@4
|
|
522 |
|
|
523 |
|
|
524 |
! !
|
|
525 |
|
|
526 |
!TabWidget::Folder methodsFor:'redefined'!
|
|
527 |
|
|
528 |
labelOriginWithinFrame
|
|
529 |
|org|
|
|
530 |
|
|
531 |
org := super labelOriginWithinFrame.
|
|
532 |
org y:(org y + self class folderTabSize y).
|
|
533 |
^ org
|
|
534 |
|
|
535 |
!
|
|
536 |
|
|
537 |
redrawSelected:isSelected
|
|
538 |
"full redraw; excluding the label
|
|
539 |
"
|
|
540 |
|lightColor shadowColor polygon fs x y y1 y2 x1 x2 x3 eX eY level|
|
|
541 |
|
|
542 |
polygon := Array new:8.
|
|
543 |
x := origin x.
|
|
544 |
y := origin y.
|
|
545 |
eX := x + extent x - 1.
|
|
546 |
eY := tabView extent y - inset.
|
|
547 |
fs := self class folderTabSize.
|
|
548 |
x1 := fs x.
|
|
549 |
y1 := fs y.
|
|
550 |
y2 := y + y1.
|
|
551 |
x3 := x + x1.
|
|
552 |
x2 := 10.
|
|
553 |
level := 2.
|
|
554 |
|
|
555 |
polygon at:1 put:(Point x:x y:eY).
|
|
556 |
polygon at:2 put:(Point x:x y:y2).
|
|
557 |
polygon at:3 put:(Point x:x3 y:y).
|
|
558 |
polygon at:4 put:(Point x:(x3+x2) y:y).
|
|
559 |
polygon at:5 put:(Point x:(x3+x2+x1) y:y2).
|
|
560 |
polygon at:6 put:(Point x:(eX-x1) y:y2).
|
|
561 |
polygon at:7 put:(Point x:(eX) y:(y2+y1)).
|
|
562 |
polygon at:8 put:(Point x:(eX) y:eY).
|
|
563 |
|
|
564 |
isSelected ifFalse:[
|
|
565 |
tabView paintColor:#unselectedColor.
|
|
566 |
lightColor := tabView styleAt:#lightColorUnselected.
|
|
567 |
shadowColor := tabView styleAt:#shadowColorUnselected.
|
|
568 |
] ifTrue:[
|
|
569 |
tabView paintColor:#selectedColor.
|
|
570 |
lightColor := tabView styleAt:#lightColorSelected.
|
|
571 |
shadowColor := tabView styleAt:#shadowColorSelected.
|
|
572 |
].
|
|
573 |
|
|
574 |
tabView fillPolygon:polygon.
|
|
575 |
tabView paint:lightColor.
|
|
576 |
|
|
577 |
0 to:level do:[:i|
|
|
578 |
tabView displayLineFromX:(x+i) y:(eY) toX:(x+i) y:(y2).
|
|
579 |
tabView displayLineFromX:(x+1) y:(y2+i-1) toX:(x3+1) y:(y+i-1).
|
|
580 |
tabView displayLineFromX:(x3+1) y:(y+i) toX:(x3+x2) y:(y+i).
|
|
581 |
tabView displayLineFromX:(x3+x2) y:(y+i) toX:(x3+x2+x1) y:(y2+i).
|
|
582 |
tabView displayLineFromX:(x3+x2+x1) y:(y2+i) toX:(eX-x1) y:(y2+i).
|
|
583 |
].
|
|
584 |
|
|
585 |
tabView paint:shadowColor.
|
|
586 |
0 to:level do:[:i|
|
|
587 |
tabView displayLineFromX:(eX-x1) y:(y2+i+1) toX:eX y:(y2+y1+i).
|
|
588 |
tabView displayLineFromX:(eX-i) y:(y2+y1) toX:(eX-i) y:(eY).
|
|
589 |
tabView displayPointX:eX-x1-i y:y2+level
|
|
590 |
].
|
|
591 |
|
|
592 |
|
|
593 |
! !
|
|
594 |
|
343
|
595 |
!TabWidget class methodsFor:'documentation'!
|
|
596 |
|
|
597 |
version
|
351
|
598 |
^ '$Header: /cvs/stx/stx/libwidg2/TabWidget.st,v 1.3 1997-04-08 15:23:20 ca Exp $'
|
343
|
599 |
! !
|