'From Squeak3.2gamma of 12 January 2002 [latest update: #4743] on 6 February 2002 at 12:23:22 pm'! "Change Set: FixPropLayout Date: 6 February 2002 Author: Andreas Raab Fixes a problem of proportional layouts incorrectly computing their minimum extent."! !LayoutFrame methodsFor: 'layout' stamp: 'ar 2/5/2002 20:05'! minExtentFrom: minExtent "Return the minimal extent the given bounds can be represented in" | widthFraction heightFraction width height | widthFraction _ 1.0. leftFraction ifNotNil:[widthFraction _ widthFraction + leftFraction]. rightFraction ifNotNil:[widthFraction _ widthFraction + rightFraction]. heightFraction _ 1.0. topFraction ifNotNil:[heightFraction _ heightFraction + topFraction]. bottomFraction ifNotNil:[heightFraction _ heightFraction + bottomFraction]. width _ minExtent x * widthFraction. height _ minExtent y * heightFraction. leftOffset ifNotNil:[width _ width + leftOffset]. rightOffset ifNotNil:[width _ width + rightOffset]. topOffset ifNotNil:[height _ height + topOffset]. bottomOffset ifNotNil:[height _ height + bottomOffset]. ^width truncated @ height truncated! ! !LayoutFrame class methodsFor: 'as yet unclassified' stamp: 'ar 2/5/2002 00:07'! fractions: fractionsOrNil ^self fractions: fractionsOrNil offsets: nil! ! !LayoutFrame class methodsFor: 'as yet unclassified' stamp: 'ar 2/5/2002 20:06'! offsets: offsetsOrNil ^self fractions: nil offsets: offsetsOrNil! ! !ProportionalLayout methodsFor: 'layout' stamp: 'ar 2/5/2002 20:05'! minExtentOf: aMorph in: newBounds "Return the minimal size aMorph's children would require given the new bounds" | min extent frame | min _ 0@0. aMorph submorphsDo:[:m| "Map the minimal size of the child through the layout frame. Note: This is done here and not in the child because its specific for proportional layouts. Perhaps we'll generalize this for table layouts but I'm not sure how and when." extent _ m minExtent. frame _ m layoutFrame. frame ifNotNil:[extent _ frame minExtentFrom: extent]. min _ min max: extent]. ^min! !