|
1 " |
|
2 COPYRIGHT (c) 1994 by Claus Gittinger |
|
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 HorizontalScroller subclass:#HorizontalMiniScroller |
|
14 instanceVariableNames:'' |
|
15 classVariableNames:'' |
|
16 poolDictionaries:'' |
|
17 category:'Views-Interactors' |
|
18 ! |
|
19 |
|
20 HorizontalMiniScroller comment:' |
|
21 COPYRIGHT (c) 1994 by Claus Gittinger |
|
22 All Rights Reserved |
|
23 |
|
24 $Header: /cvs/stx/stx/libwidg/HorizontalMiniScroller.st,v 1.1 1994-08-07 13:21:59 claus Exp $ |
|
25 '! |
|
26 |
|
27 !HorizontalMiniScroller class methodsFor:'documentation'! |
|
28 |
|
29 copyright |
|
30 " |
|
31 COPYRIGHT (c) 1994 by Claus Gittinger |
|
32 All Rights Reserved |
|
33 |
|
34 This software is furnished under a license and may be used |
|
35 only in accordance with the terms of that license and with the |
|
36 inclusion of the above copyright notice. This software may not |
|
37 be provided or otherwise made available to, or used by, any |
|
38 other person. No title to or ownership of the software is |
|
39 hereby transferred. |
|
40 " |
|
41 ! |
|
42 |
|
43 version |
|
44 " |
|
45 $Header: /cvs/stx/stx/libwidg/HorizontalMiniScroller.st,v 1.1 1994-08-07 13:21:59 claus Exp $ |
|
46 " |
|
47 ! |
|
48 |
|
49 documentation |
|
50 " |
|
51 like a scroller, but takingless screen space. |
|
52 " |
|
53 ! ! |
|
54 |
|
55 !HorizontalMiniScroller methodsFor:'initialization'! |
|
56 |
|
57 computeInitialExtent |
|
58 "make my height very small" |
|
59 |
|
60 |w h mm| |
|
61 |
|
62 w := self class defaultExtent x. |
|
63 mm := (thumbLevel ~~ 0) ifTrue:[2.5] ifFalse:[2.0]. |
|
64 h := (device verticalPixelPerMillimeter asFloat * mm) rounded. |
|
65 self extent:w @ h. |
|
66 ! |
|
67 |
|
68 initStyle |
|
69 super initStyle. |
|
70 style == #iris ifTrue:[ |
|
71 tallyLevel := 0. |
|
72 tallyMarks := 0. |
|
73 thumbSoftEdge := false. |
|
74 thumbLevel := 2. |
|
75 ]. |
|
76 ((style ~~ #normal) and:[style ~~ #mswindows]) ifTrue:[ |
|
77 style == #st80 ifTrue:[ |
|
78 self level:1. |
|
79 self borderWidth:0. |
|
80 inset := 1. |
|
81 ] ifFalse:[ |
|
82 self level:-1. |
|
83 self borderWidth:0 |
|
84 ]. |
|
85 ]. |
|
86 shadowForm := lightForm := nil. |
|
87 fixThumbHeight := false |
|
88 ! ! |