Re: [Usability] GtkEntry with units



On Jan 22, 2007, at 8:03 PM, Robert Staudinger wrote:
...
The option menu was my intuitive first thought as well, but I'm a bit
concerned it may not work out very well when the GtkEntry is stretched
to fit the overall dialog layout:
------------------------- --------
|123                     | cm <> |
------------------------- --------
vs.
----------------------------------
|123cm                           |
----------------------------------
where the latter would look much more natural.

If the field is really that wide, there is something wrong with the window layout. The width of fields should be at least roughly proportionate to the length of the data people are likely to enter in them (though it's best to avoid using more than two or three lengths in a single window).

Maybe a GtkEntryCompletion or GtkComboBoxEntry could be used to allow
for numeric and unit input in the same GtkEntry. That way the allowed
unit abbreviations can just typed straight away or alternatively
selected from the dropdown.
----------------------------------
|123cm                         <>|
----------------------------------

In a combo box, items selected from the menu replace the whole of the entered text. To replace just part of the text (the units of measurement) would be surprising.

Saving the extra widget would make dialogs look simpler (also
GtkComboBox that's now preferred over the deprecated GtkOptionMenu
takes up a lot of space for padding to make the dropdown-arrow easy to
hit.).
...

Unless it's misnaming on the part of the GTK developers, I don't know what it means for "GtkComboBox" to be "preferred over the deprecated GtkOptionMenu". Combo boxes and option menus are quite different controls, with different purposes and behaviors.

Cheers
--
Matthew Paul Thomas
http://mpt.net.nz/




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]