Index: pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java	(revision 1672455)
+++ pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java	(revision )
@@ -237,6 +237,23 @@
         Area clippingPath = getGraphicsState().getCurrentClippingPath();
         if (clippingPath != lastClip)
         {
+            // Java2D does not perform anti-aliasing on clipping paths, which means that thin lines
+            // can dissapear, as a workaround we detect rectangular clips and integer-align the
+            // coordinates ourselves, see PDFBOX-1288 and PDFBOX-2081
+            if (isRectangular(clippingPath))
+            {
+                Rectangle2D rect = clippingPath.getBounds2D();
+
+                double x1 = Math.floor(rect.getMinX());
+                double y1 = Math.floor(rect.getMinY());
+                double x2 = Math.ceil(rect.getMaxX());
+                double y2 = Math.ceil(rect.getMaxY());
+
+                rect.setRect(x1, y1, x2 - x1, y2 - y1);
+                clippingPath = new Area(rect);
+            }
+            
+            // update the clipping path
             graphics.setClip(clippingPath);
             lastClip = clippingPath;
         }
@@ -553,9 +570,9 @@
     /**
      * Returns true if the given path is rectangular.
      */
-    private boolean isRectangular(GeneralPath path)
+    private boolean isRectangular(Shape shape)
     {
-        PathIterator iter = path.getPathIterator(null);
+        PathIterator iter = shape.getPathIterator(null);
         double[] coords = new double[6];
         int count = 0;
         int[] xs = new int[4];
