OptionBox.st
changeset 63 f4eaf04d1eaf
parent 59 450ce95a72a4
child 77 565b052f5277
equal deleted inserted replaced
62:7cc1e330da47 63:f4eaf04d1eaf
    19 
    19 
    20 OptionBox comment:'
    20 OptionBox 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/libwidg/OptionBox.st,v 1.8 1994-10-10 03:02:29 claus Exp $
    24 $Header: /cvs/stx/stx/libwidg/OptionBox.st,v 1.9 1994-11-17 14:38:21 claus Exp $
    25 '!
    25 '!
    26 
    26 
    27 !OptionBox class methodsFor:'documentation'!
    27 !OptionBox 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/libwidg/OptionBox.st,v 1.8 1994-10-10 03:02:29 claus Exp $
    45 $Header: /cvs/stx/stx/libwidg/OptionBox.st,v 1.9 1994-11-17 14:38:21 claus Exp $
    46 "
    46 "
    47 !
    47 !
    48 
    48 
    49 documentation
    49 documentation
    50 "
    50 "
   198 	WarnBitmap := Form fromFile:'Warning.xbm' resolution:100 on:Display 
   198 	WarnBitmap := Form fromFile:'Warning.xbm' resolution:100 on:Display 
   199     ].
   199     ].
   200     formLabel form:WarnBitmap
   200     formLabel form:WarnBitmap
   201 ! !
   201 ! !
   202 
   202 
   203 !OptionBox methodsFor:'private'!
   203 !OptionBox methodsFor:'queries'!
   204 
   204 
   205 positionOffset
   205 positionOffset
   206     "return the delta, by which the box should be displayed
   206     "return the delta, by which the box should be displayed
   207      from the mouse pointer. Value returned here makes
   207      from the mouse pointer. Value returned here makes
   208      okButton appear under the cursor"
   208      okButton appear under the cursor"
   209 
   209 
   210     ^ (buttons last originRelativeTo:self) + (buttons last extent // 2)
   210     ^ (buttons last originRelativeTo:self) + (buttons last extent // 2)
   211 !
       
   212 
       
   213 resize
       
   214     "resize myself to make everything fit into myself"
       
   215 
       
   216     super extent:(self preferedExtent)
       
   217 !
   211 !
   218 
   212 
   219 preferedExtent 
   213 preferedExtent 
   220     "return a size to make everything fit into myself"
   214     "return a size to make everything fit into myself"
   221 
   215