From: Jeremias Maerki Date: Thu, 27 Mar 2003 10:06:16 +0000 (+0000) Subject: Reduce debug output. A constant can be modified to enable more extensive log output. X-Git-Tag: Root_Temp_KnuthStylePageBreaking~1726 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=e0436de4f251b3d881b19cb39d5c31f75df54daf;p=xmlgraphics-fop.git Reduce debug output. A constant can be modified to enable more extensive log output. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@196147 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/java/org/apache/fop/fonts/truetype/TTFFile.java b/src/java/org/apache/fop/fonts/truetype/TTFFile.java index e377088cd..157d0d569 100644 --- a/src/java/org/apache/fop/fonts/truetype/TTFFile.java +++ b/src/java/org/apache/fop/fonts/truetype/TTFFile.java @@ -72,6 +72,9 @@ public class TTFFile extends AbstractLogEnabled { static final int MAX_CHAR_CODE = 255; static final int ENC_BUF_SIZE = 1024; + /** Set to true to get even more debug output than with level DEBUG */ + public static final boolean TRACE_ENABLED = false; + private String encoding = "WinAnsiEncoding"; // Default encoding private short firstChar = 0; @@ -783,7 +786,9 @@ public class TTFFile extends AbstractLogEnabled { int mtxSize = Math.max(numberOfGlyphs, nhmtx); mtxTab = new TTFMtxEntry[mtxSize]; - getLogger().debug("*** Widths array: \n"); + if (TRACE_ENABLED) { + getLogger().debug("*** Widths array: \n"); + } for (int i = 0; i < mtxSize; i++) { mtxTab[i] = new TTFMtxEntry(); } @@ -791,9 +796,11 @@ public class TTFFile extends AbstractLogEnabled { mtxTab[i].setWx(in.readTTFUShort()); mtxTab[i].setLsb(in.readTTFUShort()); - if (getLogger().isDebugEnabled()) { - getLogger().debug(" width[" + i + "] = " - + convertTTFUnit2PDFUnit(mtxTab[i].getWx()) + ";"); + if (TRACE_ENABLED) { + if (getLogger().isDebugEnabled()) { + getLogger().debug(" width[" + i + "] = " + + convertTTFUnit2PDFUnit(mtxTab[i].getWx()) + ";"); + } } }