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

PDAcroForm.flatten(PDField list, refreshAppearances boolean) flattens all form fields instead of specified ones.

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.5, 2.0.6, 2.0.7
    • Fix Version/s: 2.0.10, 3.0.0 PDFBox
    • Component/s: AcroForm
    • Labels:
      None

      Description

      Thanks for the excellent PDF library. For my use case I need to flatten a subset of the AcroForm fields. I was attempting to use the PDAcroForm.flatten call, passing in my field list. However, after the method is called, all the fields are gone.

      The method itself appears to remove all PDFAnnotationWidgets from each page and at the end clears the acroform's field set.

      Is the javadoc description (This will flatten the specified form fields.) just misleading? Could a flatten call for a subset of fields be added?

      Thanks

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                msahyoun Maruan Sahyoun
                Reporter:
                cdonaher Cristin Donaher
              • Votes:
                3 Vote for this issue
                Watchers:
                8 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: