]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
handles path transform properly, makes a difference to the line width
authorKeiron Liddle <keiron@apache.org>
Mon, 22 Oct 2001 07:27:30 +0000 (07:27 +0000)
committerKeiron Liddle <keiron@apache.org>
Mon, 22 Oct 2001 07:27:30 +0000 (07:27 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194518 13f79535-47bb-0310-9956-ffa450edef68

src/org/apache/fop/svg/PDFGraphics2D.java

index 7fc44b2949d0022a481fe91e5ccff00cb2048dae..63493cacc60f744c254c1ba2cbd072b3d8f6bca3 100644 (file)
@@ -511,7 +511,17 @@ public class PDFGraphics2D extends AbstractGraphics2D {
         applyPaint(getPaint(), false);
         applyStroke(getStroke());
 
-        PathIterator iter = s.getPathIterator(getTransform());
+        AffineTransform trans = getTransform();
+        double[] tranvals = new double[6];
+        trans.getMatrix(tranvals);
+        currentStream.write(PDFNumber.doubleOut(tranvals[0]) + " "
+                            + PDFNumber.doubleOut(tranvals[1]) + " "
+                            + PDFNumber.doubleOut(tranvals[2]) + " "
+                            + PDFNumber.doubleOut(tranvals[3]) + " "
+                            + PDFNumber.doubleOut(tranvals[4]) + " "
+                            + PDFNumber.doubleOut(tranvals[5]) + " cm\n");
+
+        PathIterator iter = s.getPathIterator(new AffineTransform());
         while (!iter.isDone()) {
             double vals[] = new double[6];
             int type = iter.currentSegment(vals);