pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From le...@apache.org
Subject svn commit: r1554793 - in /pdfbox/branches/1.8: ./ pdfbox/src/main/java/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java
Date Thu, 02 Jan 2014 12:23:24 GMT
Author: lehmi
Date: Thu Jan  2 12:23:24 2014
New Revision: 1554793

URL: http://svn.apache.org/r1554793
Log:
PDFBOX-1733: close subpath to avoid the usage of line cap style

Modified:
    pdfbox/branches/1.8/   (props changed)
    pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java

Propchange: pdfbox/branches/1.8/
------------------------------------------------------------------------------
  Merged /pdfbox/trunk:r1554792

Modified: pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java?rev=1554793&r1=1554792&r2=1554793&view=diff
==============================================================================
--- pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java
(original)
+++ pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java
Thu Jan  2 12:23:24 2014
@@ -30,7 +30,7 @@ import org.apache.pdfbox.util.operator.O
  * Implementation of content stream operator for page drawer.
  *
  * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
+ * 
  */
 public class AppendRectangleToPath extends OperatorProcessor
 {
@@ -72,6 +72,9 @@ public class AppendRectangleToPath exten
         path.lineTo(xStart+width, yStart);
         path.lineTo(xStart+width, yStart+height);
         path.lineTo(xStart, yStart+height);
-        path.lineTo(xStart, yStart);
+        // close the subpath instead of adding the last line
+        // so that a possible set line cap style isn't taken into account
+        // at the "beginning" of the rectangle
+        path.closePath();
     }
 }



Mime
View raw message