Skip to content
This repository has been archived by the owner on Apr 25, 2018. It is now read-only.

Commit

Permalink
Move char codes from high surrogate pair range into private use.
Browse files Browse the repository at this point in the history
  • Loading branch information
brendandahl authored and ltetzlaff committed Apr 24, 2018
1 parent 653f0c9 commit e4855e6
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/core/fonts.js
Original file line number Diff line number Diff line change
Expand Up @@ -467,6 +467,8 @@ var ProblematicCharRanges = new Int32Array([
0x3164, 0x3165,
// Chars that is used in complex-script shaping.
0xAA60, 0xAA80,
// Unicode high surrogates.
0xD800, 0xE000,
// Specials Unicode block.
0xFFF0, 0x10000
]);
Expand Down
1 change: 1 addition & 0 deletions test/pdfs/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@
!bug1175962.pdf
!bug1020226.pdf
!basicapi.pdf
!issue2884_reduced.pdf
!mixedfonts.pdf
!shading_extend.pdf
!noembed-identity.pdf
Expand Down
Binary file added test/pdfs/issue2884_reduced.pdf
Binary file not shown.
8 changes: 8 additions & 0 deletions test/test_manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -1345,6 +1345,14 @@
"lastPage": 1,
"type": "eq"
},
{ "id": "issue2884_reduced",
"file": "pdfs/issue2884_reduced.pdf",
"md5": "18386542fc82affa2a5d3722549f8211",
"rounds": 1,
"link": false,
"lastPage": 1,
"type": "eq"
},
{ "id": "bug956965",
"file": "pdfs/bug956965.pdf",
"md5": "9b2f1176c797ee84e989a507e745f89d",
Expand Down
2 changes: 1 addition & 1 deletion test/unit/fonts_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ var checkProblematicCharRanges = function checkProblematicCharRanges() {

describe('Fonts', function() {
it('checkProblematicCharRanges', function() {
var EXPECTED_PERCENTAGE = 45;
var EXPECTED_PERCENTAGE = 100;
var result = checkProblematicCharRanges();

expect(result.percentage).toBeLessThan(EXPECTED_PERCENTAGE);
Expand Down

0 comments on commit e4855e6

Please sign in to comment.