summaryrefslogtreecommitdiffstats
path: root/doc/coordinates.txt
diff options
context:
space:
mode:
authorMenTaLguY <mental@rydia.net>2006-01-16 02:36:01 +0000
committermental <mental@users.sourceforge.net>2006-01-16 02:36:01 +0000
commit179fa413b047bede6e32109e2ce82437c5fb8d34 (patch)
treea5a6ac2c1708bd02288fbd8edb2ff500ff2e0916 /doc/coordinates.txt
downloadinkscape-179fa413b047bede6e32109e2ce82437c5fb8d34.tar.gz
inkscape-179fa413b047bede6e32109e2ce82437c5fb8d34.zip
moving trunk for module inkscape
(bzr r1)
Diffstat (limited to 'doc/coordinates.txt')
-rw-r--r--doc/coordinates.txt53
1 files changed, 53 insertions, 0 deletions
diff --git a/doc/coordinates.txt b/doc/coordinates.txt
new file mode 100644
index 000000000..a68b5be59
--- /dev/null
+++ b/doc/coordinates.txt
@@ -0,0 +1,53 @@
+Please note that the behavior documented here (from Sodipodi) should be considered a bug.
+
+Inkscape should switch to the native SVG coordinate system.
+
+-mental
+
+Coordinate systems used by sodipodi
+
+1. Desktop coordinates
+
+Are the base coordinate system of all editing, UI etc.
+i.e. the ones user is directly seeing (maybe some time
+we'll make this configurable).
+
+0,0 is at lower-left
+X grows to the right
+Y grows upwards
+Only valid units are real-world ones (mm, cm...) - i.e.
+there is no such unit as pixel etc.
+If printed, 1 desktop mm should be 1mm on paper
+
+2. Document coordinates
+
+As we all know, SVG Y grows downwards. So document is
+placed at 0,HEIGHT, mirrored vertically, where HEIGHT
+is vieport height in desktop coordinates.
+Moreover SVG coordinate space is scaled by 0.8, so
+1mm in SVG space equals 1mm in desktop space.
+
+The full matrix looks like:
+
+[ 0.8 0.0 0.0 ]
+[ 0.0 -0.8 HEIGHT ]
+
+Where height equals SVG viewport height in real units
+i.e. if viewport is 210mmx297mm HEIGHT is also 297mm.
+
+Document coordinates are stored in desktop object,
+as doc2dt[] matrix, and not directly accessible to
+document itself. I.e. document renders it just as any
+normal SVG viewer should do.
+
+Technically SVG placement is achieved by specifying
+doc2dt transform to drawing parent canvas group.
+
+3. user coordinates
+
+These are as specified by SVG spec.
+1 px == 1 user unit
+1 pt == 1.25 px
+etc.
+
+31/08/2002 Lauris Kaplinski <lauris@kaplinski.com>