mirror of
https://github.com/storytold/pdfcraft.git
synced 2026-11-10 13:01:29 +00:00
An embedded symbolic TrueType font with no /Encoding, no /ToUnicode and no glyph names (post 3.0) read its codes as WinAnsi in text extraction. A code now reads as Mac OS Roman when two things agree: the font's Macintosh Roman (1, 0) cmap subtable selects the glyph the code draws (ISO 32000-2 9.6.5.4), and that glyph sits where the standard Macintosh glyph order puts the code's Mac OS Roman character. pdf.js's issue2017r.pdf now extracts its accented line as PDFium does. Windows subsets in the same order whose codes are WinAnsi keep their reading, as do fonts that name their glyphs, fonts without a (1, 0) subtable and fonts whose (1, 0) subtable selects other glyphs. pdfcraft-fonts reads the same codes the same way for the editor. Glyph selection is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Pq7HyCHD1R3rywQBPCHXZA