Problem with PluggableButtonMorph?
Kevin Fisher
kgf at golden.net
Wed Jan 17 04:35:24 UTC 2001
In my porting of my old Morphs to the new Alignment stuff, I noticed that my
PluggableButtonMorphs started misbehaving. Here's a quick example:
(PluggableButtonMorph new label: 'blah') openInWorld
If you execute the above snipped pre-alignment-rewrite, you'll get a nice
button sized properly around the label. If you execute it post-rewrite, the
button is a small off-side rectangle and the label sticks out of the end.
I compared the code pre- and post- rewrite and I don't see anything
obvious...the AlignmentMorph in PluggableButtonMorph>>label: looks to my eyes
to be okay (of course I'm still green with the new alignment code :).
Is this a new bug, or new functionality? :)
Incidentally I did notice a very small change to the AlignmentMorph behaviour
with respect to calculating it's extent. If you add some morphs to an
AlignmentMorph, the extent of the AlignmentMorph doesn't get updated to the
'new' extent until you open it in the world. In the pre-rewrite days, adding
the unmapped AlignmentMorph to another Morph would force the recalculation of
it's extent as though it had been opened in the World. Post rewrite, it does
not do this anymore (I used to use this little gimmick :). Could this be
related?
(Oh and this is in 2.9a, using an image with the most-up-to-date changes).
More information about the Squeak-dev
mailing list
|