Measurement units inside number boxes
Summary:
Might be worthwhile to modify Inkscape's UI where input of measurement values are used.
Measurement input fields currently use an edit box containing the number and a combo box to specify the measurement unit.
My suggestion is to use an edit box alone, with the user indicating the measurement unit after the number by typing its name e.g. "4.2px". A space may be optionally used if desired e.g. "4.2 px" (current locale is used to interpret and display decimal points).
Advantages:
\
- Less UI widgets to place, show/hide/enable, reflect to/from, etc.
\ - Less chance of accidentally using the wrong unit by forgetting to change the combo box selection.
\ - Ability to use multi-unit measures e.g. "2p4" to indicate 2 picas and 4 pts, common in typography, or things like "6ft 2in".
- When doing business forms. E.g. Instead of having width and height inputs share a single combo box for units, someone needing a rectangle 6" x 7 picas can enter those measurements without having to use one or the other unit.
- Percent symbol (%) can be used where appropriate to indicate a percentage of some contextual distance e.g. a document dimension, lessening the need for users to figure out the computed distance.
Thorsten Wilms t_w_@freenet.de: How is the user supposed to switch the unit of the current measurement,
then? For example if the current height says 1.23 in and the user now
wants to know the measurement in mm?
That may have marginal utility? Afaik with my own user base, no one requested unit conversions. One problem is that if the number was already correct in magnitude, they want only the unit to change w/o conversion.
It might be because the use cases are already handled e.g. a person needs a shape to be 12 cm tall but with 3 pts added. So instead of typing in 12 and switching the combo box from cm to pt and then adding 3 to the new number, he just types "12cm 3pt". If he needs the points subtracted, it's just "12cm -3pt".
It seems Photoshop uses unit names in their edit fields, but if one right-clicks the field it pops up a menu letting a different unit be chosen, and the conversion can be done like before. Inkscape also provides a menu (of alternate numbers) but it wouldn't be hard to add the unit names there (or just the names if the user clicks on a unit label; I think Photoshop does that).
Inkscape also handles math expressions in number fields, which is great, so there's already a parser there.
It doesn't have to be mutually exclusive. If a field contains no measurement units, the unit is decided by the combo box. So the decision to drop the combo boxes can be deferred as long as desired.
Version info
1.4.2