2013/9/25 Johan Engelen <jbc.engelen@...2592...>:
What will happen (in the case discussed in that paragraph) is that I draw a rectangle, set the width of that rectangle to 5mm, send the file to a friend, he opens it, draws another rectangle 5mm wide next to it and the sizes will be different. Because the "user units" to real-world units is set according to monitor DPI. This will then also not be close to a realworld printout. I'm arguing that the scheme proposed is not such a good idea.
If the rectangle has its sides expressed in mm, and the friend also uses mm to draw the new rectangle, they should have the same size regardless of screen DPI. If the user specifies the rectangle width to be 50 mm, we should write "50mm" to the XML, without converting it to user units. If the rectangle is inside a scaled group, and we want the UI to be independent of this, the width written to the XML should still be in mm, but compensated for the transform.
What would actually be weird is that a document which contains a mix of objects specified with real-world units and pixels would display differently depending on the monitor DPI. On the other hand, this is exactly what the SVG specification says should happen.
The advice in the SVG spec that all lengths except on the toplevel svg:svg element should be in user units does not match our use cases. All lengths should be in the default document unit.
Regards, Krzysztof