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

CreateCheckBox example draws too large, clipped checkmark

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0.23
    • 2.0.24, 3.0.0 PDFBox
    • AcroForm
    • None
    • Windows 10 64-bit with JRE 15

    Description

      I am using the example code from CreateCheckBox of v2.0.23 to create a PDF with a rendered checkbox (https://github.com/apache/pdfbox/blob/2.0.23/examples/src/main/java/org/apache/pdfbox/examples/interactive/form/CreateCheckBox.java). Regardless of whether I use the original code or change .unCheck() to .check(), the checkmark drawn in the PDF (when the checkbox is checked) is too large and gets clipped (see attached image).

      I tried the latest Adobe Reader version and other PDF viewers as well as drawing into a different, pre-existing PDF document. The issue remains. In case it is relevant, I receive the following output when executing the code:

      Mai 17, 2021 10:51:17 AM org.apache.fontbox.ttf.CmapSubtable processSubtype14
      WARNING: Format 14 cmap table is not supported and will be ignored

      Attachments

        1. CheckBoxSample.pdf
          2 kB
          Andreas Unterweger
        2. .pdfbox.cache
          34 kB
          Andreas Unterweger
        3. checkbox.PNG
          8 kB
          Andreas Unterweger

        Activity

          People

            tilman Tilman Hausherr
            dustsigns Andreas Unterweger
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: