From: Keiron Liddle Date: Thu, 30 Aug 2001 08:50:00 +0000 (+0000) Subject: fixed dasharray units for small values that round to 0 X-Git-Tag: fop-0_20_3~73 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=e0f188c784787183e904380600233cb46b8277ff;p=xmlgraphics-fop.git fixed dasharray units for small values that round to 0 git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194445 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/org/apache/fop/svg/PDFGraphics2D.java b/src/org/apache/fop/svg/PDFGraphics2D.java index f38575d22..e8b3c4a0e 100644 --- a/src/org/apache/fop/svg/PDFGraphics2D.java +++ b/src/org/apache/fop/svg/PDFGraphics2D.java @@ -659,7 +659,13 @@ public class PDFGraphics2D extends AbstractGraphics2D { if (da != null) { currentStream.write("["); for (int count = 0; count < da.length; count++) { - currentStream.write("" + ((int)da[count])); + if(((int)da[count]) == 0) { + // the dasharray units in pdf are (whole) numbers + // in user space units, cannot be 0 + currentStream.write("1"); + } else { + currentStream.write("" + ((int)da[count])); + } if (count < da.length - 1) { currentStream.write(" "); }