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

Support duplex entry in ViewerPreferences

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.6
    • Fix Version/s: 2.0.7, 3.0.0 PDFBox
    • Component/s: PDModel
    • Labels:
      None

      Description

      The attached SO question inspired me to support the duplex entry in ViewerPreferences, even if it isn't what the person asked for. Adobe Reader supports it, i.e. their print dialog changes depending on the entry.

      To test this feature, create a PDF with 2 pages and use this code:

      PDDocumentCatalog documentCatalog = document.getDocumentCatalog();
      PDViewerPreferences viewerPreferences = new PDViewerPreferences(new COSDictionary());
      viewerPreferences.setDuplex(PDViewerPreferences.DUPLEX.DuplexFlipShortEdge);
      documentCatalog.setViewerPreferences(viewerPreferences);
      

      This will show the calender duplex mode in the print dialog.

        Attachments

          Activity

            People

            • Assignee:
              tilman Tilman Hausherr
              Reporter:
              tilman Tilman Hausherr
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: