pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1644577 - /pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java
Date Thu, 11 Dec 2014 08:04:48 GMT
Author: tilman
Date: Thu Dec 11 08:04:48 2014
New Revision: 1644577

URL: http://svn.apache.org/r1644577
Log:
PDFBOX-2552: normalize the rotation angle for all values

Modified:
    pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java

Modified: pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java?rev=1644577&r1=1644576&r2=1644577&view=diff
==============================================================================
--- pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java (original)
+++ pdfbox/branches/1.8/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDPage.java Thu Dec
11 08:04:48 2014
@@ -753,11 +753,11 @@ public class PDPage implements COSObject
         Dimension pageDimension = new Dimension( (int)widthPt, (int)heightPt );
         int rotationAngle = findRotation();
         // normalize the rotation angle
-        if (rotationAngle < 0)
+        while (rotationAngle < 0)
         {
             rotationAngle += 360;
         }
-        else if (rotationAngle >= 360)
+        while (rotationAngle >= 360)
         {
             rotationAngle -= 360;
         }



Mime
View raw message