mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-19 22:58:07 +02:00
increased size of loaded font
This commit is contained in:
parent
0a11c8bc91
commit
60127b0830
1 changed files with 3 additions and 1 deletions
4
fonts.js
4
fonts.js
|
@ -975,7 +975,7 @@ var Font = (function Font() {
|
|||
|
||||
// Create a new file to hold the new version of our truetype with a new
|
||||
// header and new offsets
|
||||
var ttf = new Uint8Array(kMaxFontFileSize);
|
||||
var ttf = new Uint8Array(kMaxFontFileSize*3);
|
||||
|
||||
// The offsets object holds at the same time a representation of where
|
||||
// to write the table entry information about a table and another offset
|
||||
|
@ -1102,6 +1102,8 @@ var Font = (function Font() {
|
|||
for (var i = 0; i < tables.length; i++) {
|
||||
var table = tables[i];
|
||||
var tableData = table.data;
|
||||
if (tableData.length + offsets.currentOffset > ttf.length)
|
||||
log('blah');
|
||||
ttf.set(tableData, offsets.currentOffset);
|
||||
offsets.currentOffset += tableData.length;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue