[squeak-dev] More pluggable dialog fun (was Re: FileChooser/SaverDialog)

tim Rowledge tim at rowledge.org
Fri Nov 3 21:07:29 UTC 2017


Amongst other ‘fun’ issues, I can’t seem to spot how to make an input field have a sensible height - ie one that gives the chosen font decent room whilst not being far too large. (This is via ToolBuilder operations by the way, not raw morph access. )

If I make the panemorph of a dialogwindow have a vResizing of #shrinkWrap instead of the forced #rigid previously mentioned then I can set the listDirection to vertical and add an input field and a list and even get them is the right sort of places. Unfortunately there are then two curious problems:
a) the list size is stupid unless I force a minimumSize: XXX on the spec
b) the input field is 2 pixels high even if I *do* give it a minimumimum size.

I’d have thought it would make sense for an input field to default to a vertical size based on the font, since pretty much the by-definition purpose is to allow a single short line of text input. And similarly I would have thought that a list might benefit from an easy way to specify a minimum height (and may maximum?) based on a number of lines. 

What I’m trying to do now (getting well away from my original quest for a nicer snapshot/quit dialog) is make the typical users of pluggabledialog work even when the panemorph size is not fudged. It would be nice to have the ListChooser look good for a short list of senders/implementors (by shrinking vertically a bit) instead of the somewhat clunky (mis)use of the dialogwindow buttons - something that really ticks me when the code decides to make horizontal buttons instead of vertical. Also it would be nice for ListChooser to be able to grow a bit vertically when there is a long list to show, without going berserk and making a screen height monster.

Right now I’m thinking the dialog stuff needs some fairly serious rework. I don;t want to just tromp all over it a break other people’s stuff though, so if you’ve been using PluggableDialogWindow etc, let me know where/how/what-for. Or if you have idea for improving it.

tim
--
tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
"Daddy, what does FORMATTING DRIVE C mean?"




More information about the Squeak-dev mailing list