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

Error when rendering a PDF with annotations

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.8.8, 2.0.0
    • Fix Version/s: 1.8.9, 2.0.0
    • Component/s: Rendering
    • Labels:
      None

      Description

      I am using the 2.0.0-SNAPSHOT version deployed on the 23rd of December. When I try to render the attached PDF, I get the following error:
      java.io.IOException: Expected 'Font' dictionary but found 'Subtype'
      at org.apache.pdfbox.pdmodel.font.PDFontFactory.createFont(PDFontFactory.java:51) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.pdmodel.PDResources.getFont(PDResources.java:91) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.contentstream.operator.text.SetFontAndSize.process(SetFontAndSize.java:50) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:809) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:471) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.contentstream.PDFStreamEngine.processAnnotation(PDFStreamEngine.java:312) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.contentstream.PDFStreamEngine.showAnnotation(PDFStreamEngine.java:390) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.rendering.PageDrawer.showAnnotation(PageDrawer.java:776) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.rendering.PageDrawer.drawPage(PageDrawer.java:167) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.rendering.PDFRenderer.renderPage(PDFRenderer.java:204) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.rendering.PDFRenderer.renderImage(PDFRenderer.java:137) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]
      at org.apache.pdfbox.rendering.PDFRenderer.renderImage(PDFRenderer.java:70) ~[pdfbox-2.0.0-20141223.230019-865.jar:?]

      I tried to render the same PDF with the 1.8.7 version and it works. There seems to be a regression.

        Attachments

          Activity

            People

            • Assignee:
              lehmi Andreas Lehmkühler
              Reporter:
              kmorin Kevin Morin
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: