equal
deleted
inserted
replaced
19 |
19 |
20 Ruler comment:' |
20 Ruler comment:' |
21 COPYRIGHT (c) 1991 by Claus Gittinger |
21 COPYRIGHT (c) 1991 by Claus Gittinger |
22 All Rights Reserved |
22 All Rights Reserved |
23 |
23 |
24 $Header: /cvs/stx/stx/libwidg2/Ruler.st,v 1.15 1995-05-03 00:42:50 claus Exp $ |
24 $Header: /cvs/stx/stx/libwidg2/Ruler.st,v 1.16 1995-06-06 04:17:42 claus Exp $ |
25 '! |
25 '! |
26 |
26 |
27 !Ruler class methodsFor:'documentation'! |
27 !Ruler class methodsFor:'documentation'! |
28 |
28 |
29 copyright |
29 copyright |
40 " |
40 " |
41 ! |
41 ! |
42 |
42 |
43 version |
43 version |
44 " |
44 " |
45 $Header: /cvs/stx/stx/libwidg2/Ruler.st,v 1.15 1995-05-03 00:42:50 claus Exp $ |
45 $Header: /cvs/stx/stx/libwidg2/Ruler.st,v 1.16 1995-06-06 04:17:42 claus Exp $ |
46 " |
46 " |
47 ! |
47 ! |
48 |
48 |
49 documentation |
49 documentation |
50 " |
50 " |
301 !Ruler methodsFor:'initialization'! |
301 !Ruler methodsFor:'initialization'! |
302 |
302 |
303 initialize |
303 initialize |
304 super initialize. |
304 super initialize. |
305 |
305 |
306 viewBackground := StyleSheet colorAt:#rulerBackgroundColor default:viewBackground. |
306 viewBackground := styleSheet colorAt:#rulerBackgroundColor default:viewBackground. |
307 fgColor := StyleSheet colorAt:#rulerForegroundColor. |
307 fgColor := styleSheet colorAt:#rulerForegroundColor. |
308 fgColor isNil ifTrue:[ |
308 fgColor isNil ifTrue:[ |
309 fgColor := StyleSheet colorAt:#foregroundColor. |
309 fgColor := styleSheet colorAt:#foregroundColor. |
310 ]. |
310 ]. |
311 fgColor isNil ifTrue:[ |
311 fgColor isNil ifTrue:[ |
312 viewBackground brightness > 0.5 ifTrue:[ |
312 viewBackground brightness > 0.5 ifTrue:[ |
313 fgColor := Black. |
313 fgColor := Black. |
314 ] ifFalse:[ |
314 ] ifFalse:[ |
324 (Smalltalk language == #english) ifTrue:[ |
324 (Smalltalk language == #english) ifTrue:[ |
325 metric := #inch |
325 metric := #inch |
326 ] ifFalse:[ |
326 ] ifFalse:[ |
327 metric := #mm |
327 metric := #mm |
328 ]. |
328 ]. |
329 metric := StyleSheet at:#rulerMetric default:metric. |
329 metric := styleSheet at:#rulerMetric default:metric. |
330 |
330 |
331 showUnit := true. |
331 showUnit := true. |
332 |
332 |
333 scale := 1. |
333 scale := 1. |
334 |
334 |