- From: Wendell Piez <wapiez@mulberrytech.com>
- Date: Wed, 27 Jun 2001 15:58:45 +0100
- To: "Jon Ferraiolo" <jferraio@Adobe.COM>
- Cc: www-svg@w3.org
Hi Jon, To extend your example, if we had <svg width="90px" height="90px" viewBox="0 0 900 900"> <rect x="0" y="0" width="450px" height="450px" fill="blue"/> <rect x="50%" y="50%" width="5in" height="5in" fill="green"/> </svg> The first rectangle (which happens to be square) will be in the upper-left corner and occupy one-quarter the area of the initial (also square) viewport. The second rectangle will be the same size, but will appear at the lower right of the viewport. This is because the 'in' unit is also subject to the transformation (which is why it's a bad idea to use it except in special circumstances). 1in is always 90px, whatever 'px' happens to be. Correct? (Both the Adobe viewer and Batik show it like this.) Would the following statement be better than my last attempt? "An unlabelled measure, e.g. width='100', gives user units, which are equivalent to 'px', are initially system-dependent, and may also be affected by operations that change the working scale such as viewBox transformations. Since 'absolute' units such as 'in' and 'cm' are actually defined relative to user units, they cannot be assumed to correspond to 'real' inches and centimeters except when (a) no transformations are being applied, and (b) an untransformed 'px' unit (user unit) happens actually to be 1/90 of an inch (regardless of actual pixel size). I think it may seem more complex than it actually is. The bottom line as it stands seems to be: 'px' is always the same as user units; both px and user units are relative to context (being not only system-dependent, inasmuch as they are initially 'negotiated', but also subject to transformations); 'absolute' units are defined relative to px (and thus to context), and so are not really "absolute". Thanks again for your patience on this, and sorry to be such trouble. Regards, Wendell ====================================================================== Wendell Piez mailto:wapiez@mulberrytech.com Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================
Received on Wednesday, 27 June 2001 15:55:45 UTC