diff options
author | Glenn Adams <gadams@apache.org> | 2012-04-21 04:03:58 +0000 |
---|---|---|
committer | Glenn Adams <gadams@apache.org> | 2012-04-21 04:03:58 +0000 |
commit | c5ea5054c700f631617216832ec1e8f0ff4716bf (patch) | |
tree | 2c137417d6a11b8caa537ed98f33c674daa61c09 /src | |
parent | c8c417405ad26ba3d2a84ebed18c6d050b1288cf (diff) | |
download | xmlgraphics-fop-c5ea5054c700f631617216832ec1e8f0ff4716bf.tar.gz xmlgraphics-fop-c5ea5054c700f631617216832ec1e8f0ff4716bf.zip |
Bugzilla #50492: Removing experimental feature that violates XSL-FO and Unicode semantics by misinterpreting Basic Latin code points. Users must use private use codepoints to access font specific character mappings that have no assigned Unicode code point.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@1328579 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r-- | src/java/org/apache/fop/fonts/truetype/TTFFile.java | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/java/org/apache/fop/fonts/truetype/TTFFile.java b/src/java/org/apache/fop/fonts/truetype/TTFFile.java index bcbd73a6f..d8716c99f 100644 --- a/src/java/org/apache/fop/fonts/truetype/TTFFile.java +++ b/src/java/org/apache/fop/fonts/truetype/TTFFile.java @@ -420,6 +420,19 @@ public class TTFFile { unicodeMappings.add(new UnicodeMapping(glyphIdx, j)); mtxTab[glyphIdx].getUnicodeIndex().add(new Integer(j)); + /* + * Removing this feature, since it violates XSL-FO and Unicode + * semantics. All characters used in an XSL-FO file (once decoded from + * the document encoded) are interpreted as Unicode code points. + * This precludes using Unicode code points in the Basic Latin range + * for any purpose other than use as Basic Latin characters. In + * order to use characters in the Wingding or Symbols font, then + * the user must use the specific Unicode code point that is mapped + * to the desired glyph via the font's cmap tables. What this means + * is that the user must use an appropriate private use character + * as defined by the font manufacturer and supported by some cmap + * provided in the font. [GA] 2012-04-20 + * if (encodingID == 0 && j >= 0xF020 && j <= 0xF0FF) { //Experimental: Mapping 0xF020-0xF0FF to 0x0020-0x00FF //Tested with Wingdings and Symbol TTF fonts which map their @@ -431,6 +444,7 @@ public class TTFFile { mtxTab[glyphIdx].getUnicodeIndex().add(new Integer(mapped)); } } + */ // Also add winAnsiWidth List v = (List)ansiIndex.get(new Integer(j)); |