Class OperationViewerPreferences


  • public class OperationViewerPreferences
    extends Object
    Allows to change PDF reader specific settings and dialog defaults. **Important:** Whether these parameters actually have an effect, depends directly on their support in the application used to display the PDF. **Important:** Only few of those settings are actually \"enforced\" and most PDF readers will provide the viewer with the means to circumvent or even alter those settings.
    • Constructor Detail

      • OperationViewerPreferences

        public OperationViewerPreferences()
    • Method Detail

      • getCenterWindow

        @Nullable
        public @Nullable Boolean getCenterWindow()
        If true, the PDF reader window is moved to the center of the screen.
        Returns:
        centerWindow
      • setCenterWindow

        public void setCenterWindow​(Boolean centerWindow)
      • getDisplayDocTitle

        @Nullable
        public @Nullable Boolean getDisplayDocTitle()
        If true, the document title of the document is displayed in the title bar of the PDF reader instead of the file name.
        Returns:
        displayDocTitle
      • setDisplayDocTitle

        public void setDisplayDocTitle​(Boolean displayDocTitle)
      • getDuplex

        @Nullable
        public @Nullable OperationViewerPreferences.DuplexEnum getDuplex()
        Sets whether and how pages are to be printed on both sides. (This setting is only a dialog default and can be changed by the user at any time). * simplex = Print on one side. * duplexFlipLongEdge = Print on both sides and flip over the longer edge of the page. * duplexFlipShortEdge = Print on both sides and flip over the shorter side edge. * none = Use the default settings of the display program.
        Returns:
        duplex
      • getFitWindow

        @Nullable
        public @Nullable Boolean getFitWindow()
        If true, the window size of the PDF reader will be tried to fit the first page of the document.
        Returns:
        fitWindow
      • setFitWindow

        public void setFitWindow​(Boolean fitWindow)
      • getHideMenuBar

        @Nullable
        public @Nullable Boolean getHideMenuBar()
        If true, the menu bars of the PDF reader are hidden for the display of this document.
        Returns:
        hideMenuBar
      • setHideMenuBar

        public void setHideMenuBar​(Boolean hideMenuBar)
      • getHideToolbar

        @Nullable
        public @Nullable Boolean getHideToolbar()
        If true, the toolbars of the PDF reader are hidden for the display of this document.
        Returns:
        hideToolbar
      • setHideToolbar

        public void setHideToolbar​(Boolean hideToolbar)
      • getHideWindowUI

        @Nullable
        public @Nullable Boolean getHideWindowUI()
        If true, the scrollbars and other navigation features of the PDF reader are hidden for the display of this document.
        Returns:
        hideWindowUI
      • setHideWindowUI

        public void setHideWindowUI​(Boolean hideWindowUI)
      • getNonFullScreenPageMode

        @Nullable
        public @Nullable OperationViewerPreferences.NonFullScreenPageModeEnum getNonFullScreenPageMode()
        Konfiguriert die Anzeige des Dokuments, wenn das Dokument nicht im Vollbildmodus betrachtet wird. Dies konfiguriert in erste Linie welche Navigationsansicht für den Betrachter geöffnet werden soll. * none = Weder die Inhaltsübersicht, noch die Miniaturansicht der Seiten sollen angezeigt werden. * outlines = Die Inhaltsübersicht des Dokuments soll angezeigt werden. * thumbnails = Die Miniaturansicht der Seiten des Dokuments soll angezeigt werden. * optionalContents = Die Layer (Optional Content Groups) des Dokuments sollen angezeigt werden.
        Returns:
        nonFullScreenPageMode
      • getNumCopies

        @Nullable
        public @Nullable Integer getNumCopies()
        Specifies how many copies of the document are to be printed. (This setting is only a dialog default and can be changed by the user at any time). minimum: 1
        Returns:
        numCopies
      • setNumCopies

        public void setNumCopies​(Integer numCopies)
      • getPrintArea

        @Nullable
        public @Nullable OperationViewerPreferences.PrintAreaEnum getPrintArea()
        Used to select the box that should be scaled. * media\\_box = The page's physical dimensions. * crop\\_box = The visible (printable) page area. * bleed\\_box = Untrimmed content position on the page (content dimensions plus trim box). * trim\\_box = Trimmed content position on the page (final content dimensions). * art\\_box = Position for special page content (images).
        Returns:
        printArea
      • getPrintClip

        @Nullable
        public @Nullable OperationViewerPreferences.PrintClipEnum getPrintClip()
        Used to select the box that should be scaled. * media\\_box = The page's physical dimensions. * crop\\_box = The visible (printable) page area. * bleed\\_box = Untrimmed content position on the page (content dimensions plus trim box). * trim\\_box = Trimmed content position on the page (final content dimensions). * art\\_box = Position for special page content (images).
        Returns:
        printClip
      • getPrintPageRange

        @Nullable
        public @Nullable String getPrintPageRange()
        Specifies which page(s) to print. For the page number, either a single page, a range of pages or a list (separated by commas) can be specified (e.g. \"1,5-6,9\"). The specification of all pages is done with \"\\*\". (This setting is only a dialog default and can be changed by the user at any time).
        Returns:
        printPageRange
      • setPrintPageRange

        public void setPrintPageRange​(String printPageRange)
      • getPrintScaling

        @Nullable
        public @Nullable OperationViewerPreferences.PrintScalingEnum getPrintScaling()
        Selects the page * scaling mode for printouts of the document. (This setting is only a dialog default and can be changed by the user at any time). * readerDefault = Use the scaling functions provided by the display program. * noPrintScaling = Do no page scaling and print the pages in original size.
        Returns:
        printScaling
      • getPrintTraySelection

        @Nullable
        public @Nullable OperationViewerPreferences.PrintTraySelectionEnum getPrintTraySelection()
        Selects the default setting for how print trays should be selected for printing the pages of the document. (This setting is only a dialog default and can be changed by the user at any time). * readerDefault = Use the default settings of the display program. * byPDFSize = Try to determine the necessary paper size and the used print tray automatically based on the size of the pages of the document.
        Returns:
        printTraySelection
      • getTextDirection

        @Nullable
        public @Nullable OperationViewerPreferences.TextDirectionEnum getTextDirection()
        Specifies the text reading direction for the display program's read aloud. * leftToRight = From left to right. * rightToLeft = From right to left. (Including vertical fonts, such as: Chinese, Japanese, Korean, etc.).
        Returns:
        textDirection
      • getViewArea

        @Nullable
        public @Nullable OperationViewerPreferences.ViewAreaEnum getViewArea()
        Used to select the box that should be scaled. * media\\_box = The page's physical dimensions. * crop\\_box = The visible (printable) page area. * bleed\\_box = Untrimmed content position on the page (content dimensions plus trim box). * trim\\_box = Trimmed content position on the page (final content dimensions). * art\\_box = Position for special page content (images).
        Returns:
        viewArea
      • getViewClip

        @Nullable
        public @Nullable OperationViewerPreferences.ViewClipEnum getViewClip()
        Used to select the box that should be scaled. * media\\_box = The page's physical dimensions. * crop\\_box = The visible (printable) page area. * bleed\\_box = Untrimmed content position on the page (content dimensions plus trim box). * trim\\_box = Trimmed content position on the page (final content dimensions). * art\\_box = Position for special page content (images).
        Returns:
        viewClip
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object