From 9a633f26a0c1099ebe7de48e6d7e74c1aabd3c37 Mon Sep 17 00:00:00 2001 From: Yury Delendik Date: Wed, 13 Nov 2013 18:27:52 -0600 Subject: [PATCH] Fixes gidStart for CID fonts --- src/core/fonts.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/fonts.js b/src/core/fonts.js index 5f96a8b93..dae633038 100644 --- a/src/core/fonts.js +++ b/src/core/fonts.js @@ -5611,6 +5611,9 @@ var CFFFont = (function CFFFontClosure() { var unassignedUnicodeItems = []; var inverseEncoding = []; var gidStart = 0; + if (charsets[0] === '.notdef') { + gidStart = 1; + } // According to section 9.7.4.2 CIDFontType0C glyph selection should be // handled differently. if (this.properties.subtype === 'CIDFontType0C') { @@ -5643,9 +5646,6 @@ var CFFFont = (function CFFFontClosure() { inverseEncoding[gid] = charcode | 0; } } - if (charsets[0] === '.notdef') { - gidStart = 1; - } } for (var i = gidStart, ii = charsets.length; i < ii; i++) {