Re: Path Coordinates

"A. J. Wilson" wrote:
> 
> I am attempting to manually code some SVG paths and, as far as I can
> tell, all coordinates that can be specified in the path cannot use unit
> designators.

Correct.

>  Do you see this as a shortcoming?

Yes, there are cases where it would add value, but on the other hand
viewports seem to deal in practice with what people would otherwise use
units in paths for.
> 
> I am specifically trying to set up a page size (SVG viewport) that
> mimics a 8" x 11.5" sheet of paper.  After that I want to draw paths
> on the paper and have it rendered correctly both on a  monitor and on a
> printer.

OK, you can do that.

> It seems that specifying path coordinates in pixel values defeats my
> purpose,
> because I do not know the resolution of the output device in advance.
> 
> What am I missing?

Two things. 

One, pixels have a particular meaning (se CSS2 spec) which is not the same
as the 1/600 or 1/720 inch dots that your printer makes. 

Two, one user coordinate=one CSS pixel is the *initial* state of the
mapping from user space to device space; you can alter this and most
graphics do alter it.

For example, suppose you have map data in lattitude and longitude. You can
use this data directly in SVG, by setting the viewBox appropriately. (Note
for cartographers: these are affine transformations - mapping form
arbitrary 3D spherical coordinate systems to arbitrary 2D coordinates is
not supported)

--
Chris

Received on Friday, 25 February 2000 15:01:25 UTC