mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-26 10:08:06 +02:00
Handle bidi ordering of PDF strings
This commit is contained in:
parent
d50773fb96
commit
2e1a88f39e
4 changed files with 393 additions and 3 deletions
10
src/fonts.js
10
src/fonts.js
|
@ -763,6 +763,16 @@ function getUnicodeRangeFor(value) {
|
|||
return -1;
|
||||
}
|
||||
|
||||
function isRTLRangeFor(value) {
|
||||
var range = UnicodeRanges[13];
|
||||
if (value >= range.begin && value < range.end)
|
||||
return true;
|
||||
range = UnicodeRanges[11];
|
||||
if (value >= range.begin && value < range.end)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
function isSpecialUnicode(unicode) {
|
||||
return (unicode <= 0x1F || (unicode >= 127 && unicode < kSizeOfGlyphArea)) ||
|
||||
(unicode >= kCmapGlyphOffset &&
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue