Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-4909

Don't calculate font height for every glyph

    XMLWordPrintableJSON

Details

    Description

      LegacyPDFStreamEngine computes font height for every glyph and the computation is rather heavy, to work around all known problems.

      Instead of computing for every glyph, we can recompute only when the font changes. The SetFontAndSize operator will be invoked when the font changes so we can use that to compute and store the height to have it ready when needed in showGlyph.

       

      Attachments

        1. WithCapturingSetFontAndSize.png
          36 kB
          Alfred
        2. Untitled.png
          37 kB
          Alfred
        3. PDFBOX-4909.patch
          7 kB
          Alfred

        Activity

          People

            tilman Tilman Hausherr
            Faltiska Alfred
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: