|
|
|
@ -20,8 +20,8 @@ if (typeof PDFJS === 'undefined') {
@@ -20,8 +20,8 @@ if (typeof PDFJS === 'undefined') {
|
|
|
|
|
(typeof window !== 'undefined' ? window : this).PDFJS = {}; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
PDFJS.version = '1.3.52'; |
|
|
|
|
PDFJS.build = 'e93512f'; |
|
|
|
|
PDFJS.version = '1.3.54'; |
|
|
|
|
PDFJS.build = 'e180d01'; |
|
|
|
|
|
|
|
|
|
(function pdfjsWrapper() { |
|
|
|
|
// Use strict in our context only - users might not want it
|
|
|
|
@ -24573,11 +24573,15 @@ var Font = (function FontClosure() {
@@ -24573,11 +24573,15 @@ var Font = (function FontClosure() {
|
|
|
|
|
}; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function getRanges(glyphs) { |
|
|
|
|
function getRanges(glyphs, numGlyphs) { |
|
|
|
|
// Array.sort() sorts by characters, not numerically, so convert to an
|
|
|
|
|
// array of characters.
|
|
|
|
|
var codes = []; |
|
|
|
|
for (var charCode in glyphs) { |
|
|
|
|
// Remove an invalid glyph ID mappings to make OTS happy.
|
|
|
|
|
if (glyphs[charCode] >= numGlyphs) { |
|
|
|
|
continue; |
|
|
|
|
} |
|
|
|
|
codes.push({ fontCharCode: charCode | 0, glyphId: glyphs[charCode] }); |
|
|
|
|
} |
|
|
|
|
codes.sort(function fontGetRangesSort(a, b) { |
|
|
|
@ -24606,8 +24610,8 @@ var Font = (function FontClosure() {
@@ -24606,8 +24610,8 @@ var Font = (function FontClosure() {
|
|
|
|
|
return ranges; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function createCmapTable(glyphs) { |
|
|
|
|
var ranges = getRanges(glyphs); |
|
|
|
|
function createCmapTable(glyphs, numGlyphs) { |
|
|
|
|
var ranges = getRanges(glyphs, numGlyphs); |
|
|
|
|
var numTables = ranges[ranges.length - 1][1] > 0xFFFF ? 2 : 1; |
|
|
|
|
var cmap = '\x00\x00' + // version
|
|
|
|
|
string16(numTables) + // numTables
|
|
|
|
@ -26110,7 +26114,7 @@ var Font = (function FontClosure() {
@@ -26110,7 +26114,7 @@ var Font = (function FontClosure() {
|
|
|
|
|
this.toFontChar = newMapping.toFontChar; |
|
|
|
|
tables.cmap = { |
|
|
|
|
tag: 'cmap', |
|
|
|
|
data: createCmapTable(newMapping.charCodeToGlyphId) |
|
|
|
|
data: createCmapTable(newMapping.charCodeToGlyphId, numGlyphs) |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
if (!tables['OS/2'] || !validateOS2Table(tables['OS/2'])) { |
|
|
|
@ -26248,7 +26252,8 @@ var Font = (function FontClosure() {
@@ -26248,7 +26252,8 @@ var Font = (function FontClosure() {
|
|
|
|
|
builder.addTable('OS/2', createOS2Table(properties, |
|
|
|
|
newMapping.charCodeToGlyphId)); |
|
|
|
|
// Character to glyphs mapping
|
|
|
|
|
builder.addTable('cmap', createCmapTable(newMapping.charCodeToGlyphId)); |
|
|
|
|
builder.addTable('cmap', createCmapTable(newMapping.charCodeToGlyphId, |
|
|
|
|
numGlyphs)); |
|
|
|
|
// Font header
|
|
|
|
|
builder.addTable('head', |
|
|
|
|
'\x00\x01\x00\x00' + // Version number
|
|
|
|
|