pdf-raku / PDF-Font-Loader-raku

Font loader for the PDF tool-chain
Artistic License 2.0
1 stars 3 forks source link

Variable CMap encoding not supported #9

Closed dwarring closed 3 years ago

dwarring commented 3 years ago

Example PDF with variable encoding attached. See font /F2 8 0 R on page 1 and CMap 9 0 R ttfont_demo_jp.pdf

dwarring commented 3 years ago

Latest PDF::Font::Loader now does a pretty good job of reading that PDF as demonstrated by latest output of PDF::To::Cairo's pdf2image.raku outout (attached). tst-001

I also needed to implement CMAP begincidrange ... endcidrange mappings to read the fonts from this PDF

Still more work needed to ensure we can write updated CMaps before closing this ticket.

dwarring commented 3 years ago

Work underway on cmap-refactor branch to move CMAP serialization to the encoder. To close this ticket and, more generally, accurately update CMAPs.

dwarring commented 3 years ago

partially implemented with 0.5.6 release, which can read, read CMaps, encode/decode, but not update CMaps

dwarring commented 3 years ago

I found this Adobe repo which contains a number of standard CMAPs.

Possibly, this module should have built-in support for these encodings which are multibyte and variable.

For now, I can use some examples from here to test multibyte encodings.