recompute label origin, if the form changes
authorClaus Gittinger <cg@exept.de>
Tue, 15 Aug 2000 16:11:53 +0200
changeset 2212 7475e8be57bb
parent 2211 3212dcc2538b
child 2213 6068f2786bd6
recompute label origin, if the form changes
OptionBox.st
--- a/OptionBox.st	Fri Aug 11 19:40:23 2000 +0200
+++ b/OptionBox.st	Tue Aug 15 16:11:53 2000 +0200
@@ -10,6 +10,8 @@
  hereby transferred.
 "
 
+"{ Package: 'stx:libwidg' }"
+
 DialogBox subclass:#OptionBox
 	instanceVariableNames:'formLabel textLabel buttons actions defaultButtonIndex'
 	classVariableNames:'WarnBitmap'
@@ -244,7 +246,12 @@
 form:aFormOrImage
     "set the image shown in the label-view"
 
-    formLabel form:aFormOrImage
+    |mm|
+
+    mm := ViewSpacing.
+    formLabel form:aFormOrImage.
+    textLabel origin:((mm + formLabel width + mm) @ mm).
+
 !
 
 formLabel
@@ -402,5 +409,5 @@
 !OptionBox class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg/OptionBox.st,v 1.42 2000-02-23 17:28:40 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/OptionBox.st,v 1.43 2000-08-15 14:11:53 cg Exp $'
 ! !