17
|
1 |
"
|
|
2 |
COPYRIGHT (c) 1992 by Claus Gittinger
|
24
|
3 |
All Rights Reserved
|
17
|
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 |
|
49
|
13 |
'From Smalltalk/X, Version:2.10.5 on 30-apr-1995 at 1:46:29 am'!
|
|
14 |
|
|
15 |
Slider subclass:#HorizontalSlider
|
|
16 |
instanceVariableNames:''
|
|
17 |
classVariableNames:''
|
|
18 |
poolDictionaries:''
|
|
19 |
category:'Views-Interactors'
|
17
|
20 |
!
|
|
21 |
|
|
22 |
!HorizontalSlider class methodsFor:'documentation'!
|
|
23 |
|
|
24 |
copyright
|
|
25 |
"
|
|
26 |
COPYRIGHT (c) 1992 by Claus Gittinger
|
24
|
27 |
All Rights Reserved
|
17
|
28 |
|
|
29 |
This software is furnished under a license and may be used
|
|
30 |
only in accordance with the terms of that license and with the
|
|
31 |
inclusion of the above copyright notice. This software may not
|
|
32 |
be provided or otherwise made available to, or used by, any
|
|
33 |
other person. No title to or ownership of the software is
|
|
34 |
hereby transferred.
|
|
35 |
"
|
|
36 |
!
|
|
37 |
|
|
38 |
version
|
|
39 |
"
|
71
|
40 |
$Header: /cvs/stx/stx/libwidg2/HorizontalSlider.st,v 1.6 1995-08-30 18:06:18 claus Exp $
|
17
|
41 |
"
|
|
42 |
!
|
|
43 |
|
|
44 |
documentation
|
|
45 |
"
|
|
46 |
this class implements horizontal sliders.
|
|
47 |
"
|
|
48 |
! !
|
|
49 |
|
|
50 |
!HorizontalSlider methodsFor:'initialization'!
|
|
51 |
|
|
52 |
initialize
|
|
53 |
super initialize.
|
49
|
54 |
sliderHeight := (self horizontalPixelPerMillimeter:10) rounded.
|
|
55 |
orientation := #horizontal
|
17
|
56 |
! !
|
|
57 |
|
65
|
58 |
!HorizontalSlider methodsFor:'queries'!
|
|
59 |
|
|
60 |
preferredExtent
|
|
61 |
|w h|
|
|
62 |
|
|
63 |
w := self class defaultExtent x.
|
|
64 |
h := (device verticalPixelPerMillimeter asFloat * 6) rounded.
|
|
65 |
^ w @ h.
|
|
66 |
! !
|