[ 
https://issues.apache.org/jira/browse/PDFBOX-6382?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Andreas Lehmkühler reassigned PDFBOX-6382:
------------------------------------------

    Assignee: Andreas Lehmkühler

> CFF CID font caches glyphs by CID, so each unmapped CID re-parses and keeps 
> its own .notdef copy
> ------------------------------------------------------------------------------------------------
>
>                 Key: PDFBOX-6382
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-6382
>             Project: PDFBox
>          Issue Type: Bug
>            Reporter: Joao Goncalves
>            Assignee: Andreas Lehmkühler
>            Priority: Major
>
> {{CFFCIDFont.getType2CharString(int cid)}} in fontbox returns the outline 
> program for a CID and caches it in {{{}charStringCache{}}}, an unbounded 
> {{HashMap}} keyed by CID. On a cache miss it maps the CID to a glyph id 
> (GID), using GID 0 (.notdef) for any CID not in the charset, parses that 
> glyph's charstring including subroutine inlining, and stores the result under 
> the CID. The charstring depends only on the GID, so every distinct CID that 
> falls back to .notdef gets its own full parse and its own retained copy. The 
> document controls the CIDs through its text and Encoding CMap. 
> {{CFFType1Font}} already caches by GID.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to