pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1862495 - /pdfbox/branches/issue4569/pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java
Date Wed, 03 Jul 2019 16:41:59 GMT
Author: tilman
Date: Wed Jul  3 16:41:59 2019
New Revision: 1862495

URL: http://svn.apache.org/viewvc?rev=1862495&view=rev
Log:
PDFBOX-4071: improve variable names

Modified:
    pdfbox/branches/issue4569/pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java

Modified: pdfbox/branches/issue4569/pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/issue4569/pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java?rev=1862495&r1=1862494&r2=1862495&view=diff
==============================================================================
--- pdfbox/branches/issue4569/pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java
(original)
+++ pdfbox/branches/issue4569/pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java
Wed Jul  3 16:41:59 2019
@@ -282,31 +282,31 @@ public class PageDrawer extends PDFGraph
     void drawTilingPattern(Graphics2D g, PDTilingPattern pattern, PDColorSpace colorSpace,
                                   PDColor color, Matrix patternMatrix) throws IOException
     {
-        Graphics2D oldGraphics = graphics;
+        Graphics2D savedGraphics = graphics;
         graphics = g;
 
-        GeneralPath oldLinePath = linePath;
+        GeneralPath savedLinePath = linePath;
         linePath = new GeneralPath();
-        int oldClipWindingRule = clipWindingRule;
+        int savedClipWindingRule = clipWindingRule;
         clipWindingRule = -1;
 
-        Area oldLastClip = lastClip;
+        Area savedLastClip = lastClip;
         lastClip = null;
-        Shape oldInitialClip = initialClip;
+        Shape savedInitialClip = initialClip;
         initialClip = null;
         
-        boolean oldFlipTG = flipTG;
+        boolean savedFlipTG = flipTG;
         flipTG = true;
 
         setRenderingHints();
         processTilingPattern(pattern, color, colorSpace, patternMatrix);
         
-        flipTG = oldFlipTG;
-        graphics = oldGraphics;
-        linePath = oldLinePath;
-        lastClip = oldLastClip;
-        initialClip = oldInitialClip;
-        clipWindingRule = oldClipWindingRule;
+        flipTG = savedFlipTG;
+        graphics = savedGraphics;
+        linePath = savedLinePath;
+        lastClip = savedLastClip;
+        initialClip = savedInitialClip;
+        clipWindingRule = savedClipWindingRule;
     }
 
     private float clampColor(float color)
@@ -1343,7 +1343,7 @@ public class PageDrawer extends PDFGraph
         // both the DPI xform and the CTM were already applied to the group, so all we do
         // here is draw it directly onto the Graphics2D device at the appropriate position
         PDRectangle bbox = group.getBBox();
-        AffineTransform prev = graphics.getTransform();
+        AffineTransform savedTransform = graphics.getTransform();
 
         Matrix m = new Matrix(xform);
         float xScale = Math.abs(m.getScalingFactorX());
@@ -1388,7 +1388,7 @@ public class PageDrawer extends PDFGraph
             }
         }
 
-        graphics.setTransform(prev);
+        graphics.setTransform(savedTransform);
     }
 
     /**
@@ -1423,9 +1423,9 @@ public class PageDrawer extends PDFGraph
         private TransparencyGroup(PDTransparencyGroup form, boolean isSoftMask, Matrix ctm,

                 PDColor backdropColor) throws IOException
         {
-            Graphics2D g2dOriginal = graphics;
-            Area lastClipOriginal = lastClip;
-            Shape oldInitialClip = initialClip;
+            Graphics2D savedGraphics = graphics;
+            Area savedLastClip = lastClip;
+            Shape savedInitialClip = initialClip;
 
             // get the CTM x Form Matrix transform
             Matrix transform = Matrix.concatenate(ctm, form.getMatrix());
@@ -1523,7 +1523,7 @@ public class PageDrawer extends PDFGraph
             g.translate(0, image.getHeight());
             g.scale(1, -1);
 
-            boolean oldFlipTG = flipTG;
+            boolean savedFlipTG = flipTG;
             flipTG = false;
 
             // apply device transform (DPI)
@@ -1565,11 +1565,11 @@ public class PageDrawer extends PDFGraph
             }
             finally 
             {
-                flipTG = oldFlipTG;
-                lastClip = lastClipOriginal;
+                flipTG = savedFlipTG;
+                lastClip = savedLastClip;
                 graphics.dispose();
-                graphics = g2dOriginal;
-                initialClip = oldInitialClip;
+                graphics = savedGraphics;
+                initialClip = savedInitialClip;
                 clipWindingRule = clipWindingRuleOriginal;
                 linePath = linePathOriginal;
                 pageSize = pageSizeOriginal;



Mime
View raw message