Some Text
Label
Edit widget
Hi Robert - I want to make up some data fields that are easy to drop into my data objects. The idea is to attach a label and an edit widget (like slider for numbers, calendar chooser button for dates, etc), so that you get all of this when you drag the field onto the form. This actually works, as you see here. The label and edit widget are stick-out submorphs which works exactly right... ... until you set the scroll mode of the text to 'scroll' or 'auto'. In this case, it seems the submorphs get included in the clipping frame, and it's all wrong. Do you understand this well enough to point me at the code? My solution would be to allow a property like 'dontClipByTextOwner' on the stickout submorphs to suppress this particular feature (which may well be desirable in other situations). What do you think?
What you are asking for is more than just adding a new property, this involves making an exemption of how morphs (and their DOM representation) are managed. Right now there is only one clipping model: Every morph can clip its entire contents (its shape + submorphs). You want clipping that affects the shape (text is part of a TextMorph's shape) but not the submorphs. We can certainly do that but only by complicating the rendering system (and adding more morph properties). What's wrong with simply composing morphs? Have one owner for the text and the remaining "stickouts"? This should be fairly general and should allow to represent anything you want.