--- a/StrokingWrapper.st Thu May 09 00:02:28 1996 +0200
+++ b/StrokingWrapper.st Thu May 09 00:14:40 1996 +0200
@@ -90,32 +90,46 @@
!StrokingWrapper methodsFor:'accessing'!
bounds
+ "return the boundary rectangle - here, must take care of the lineWidth"
+
^ component bounds + (lineWidth - 1)
"Created: 8.5.1996 / 23:22:43 / cg"
+ "Modified: 9.5.1996 / 00:09:06 / cg"
!
lineWidth
+ "return the lineWidth"
+
^ lineWidth
"Created: 8.5.1996 / 23:22:04 / cg"
+ "Modified: 9.5.1996 / 00:09:12 / cg"
!
lineWidth:aNumber
+ "set the lineWidth"
+
lineWidth := aNumber
"Created: 8.5.1996 / 23:22:13 / cg"
+ "Modified: 9.5.1996 / 00:09:17 / cg"
!
preferredBounds
+ "return the components bounds as preferredBounds"
+
^ self bounds
"Created: 8.5.1996 / 23:23:00 / cg"
+ "Modified: 9.5.1996 / 00:09:31 / cg"
! !
!StrokingWrapper methodsFor:'displaying'!
displayOn:aGC
+ "display myself - here, display the geometric object asStroked"
+
|prevLineWidth prevFg|
prevLineWidth := aGC lineWidth.
@@ -130,20 +144,23 @@
aGC paint:prevFg.
"Created: 8.5.1996 / 23:24:04 / cg"
- "Modified: 8.5.1996 / 23:54:22 / cg"
+ "Modified: 9.5.1996 / 00:11:17 / cg"
! !
!StrokingWrapper methodsFor:'initialization'!
initialize
+ "default my lineWidth to one pixel"
+
super initialize.
lineWidth := 1.
"Created: 8.5.1996 / 23:49:27 / cg"
+ "Modified: 9.5.1996 / 00:11:51 / cg"
! !
!StrokingWrapper class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview2/StrokingWrapper.st,v 1.1 1996-05-08 22:02:04 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview2/StrokingWrapper.st,v 1.2 1996-05-08 22:14:33 cg Exp $'
! !