From bccf87ccbf0aef8db1601b8d4db2fd7e7bfb3bf5 Mon Sep 17 00:00:00 2001 From: Adrian Cumiskey Date: Wed, 22 Oct 2008 16:12:28 +0000 Subject: [PATCH] Improved name truncation warning. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_AFPGOCAResources@707112 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/fop/render/afp/modca/AbstractNamedAFPObject.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/java/org/apache/fop/render/afp/modca/AbstractNamedAFPObject.java b/src/java/org/apache/fop/render/afp/modca/AbstractNamedAFPObject.java index 558ad61ba..31a4b8430 100644 --- a/src/java/org/apache/fop/render/afp/modca/AbstractNamedAFPObject.java +++ b/src/java/org/apache/fop/render/afp/modca/AbstractNamedAFPObject.java @@ -71,8 +71,10 @@ public abstract class AbstractNamedAFPObject extends AbstractStructuredAFPObject if (name.length() < nameLen) { name = (name + " ").substring(0, nameLen); } else if (name.length() > nameLen) { - log.warn("Constructor:: name truncated to " + nameLen + " chars" + name); - name = name.substring(0, nameLen); + String truncatedName = name.substring(0, nameLen); + log.warn("Constructor:: name '" + name + "'" + + " truncated to " + nameLen + " chars" + + " ('" + truncatedName + "')"); } byte[] nameBytes = null; try { -- 2.39.5