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

John Hewson updated PDFBOX-2303:
--------------------------------

    Description: 
FontBox's TTF GlyphTable reads the entire glyph table and constructs an object 
for each glyph. However this is very slow for large external fonts (e.g. Asian) 
such as "STXihei" which is 15.7MB and has 37255 glyphs. On my machine it takes 
around 9 seconds for PDFBox to load that font just to render 15 glyphs from it.

We can modify GlyphTable to make it lazy so that glyphs are read individually 
only when needed.

  was:
FontBox's TTF GlyphTable reads the entire glyph table and constructs an object 
for each glyph. However this is very slow for large external fonts (e.g. Asian) 
such as "STXihei" which is 15.7MB and has 37,255 glyphs. On my machine it takes 
around 9 seconds for PDFBox to load that font just to render 15 glyphs from it.

We can modify GlyphTable to make it lazy so that glyphs are read individually 
only when needed.


> Lazy loading of glyphs in TrueType fonts
> ----------------------------------------
>
>                 Key: PDFBOX-2303
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-2303
>             Project: PDFBox
>          Issue Type: Improvement
>          Components: FontBox
>    Affects Versions: 2.0.0
>            Reporter: John Hewson
>            Assignee: John Hewson
>            Priority: Minor
>
> FontBox's TTF GlyphTable reads the entire glyph table and constructs an 
> object for each glyph. However this is very slow for large external fonts 
> (e.g. Asian) such as "STXihei" which is 15.7MB and has 37255 glyphs. On my 
> machine it takes around 9 seconds for PDFBox to load that font just to render 
> 15 glyphs from it.
> We can modify GlyphTable to make it lazy so that glyphs are read individually 
> only when needed.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to