Enum FitToPaperModes

    • Enum Constant Detail

      • FixedPixelWidth

        public static final FitToPaperModes FixedPixelWidth
        Fit an exact number of pixels onto each PDF page. Useful when an optimal pixel width is known or printing documents to match a Chrome browser window display
      • Automatic

        public static final FitToPaperModes Automatic
        Measures minimum HTML content width after it is rendered by the browser and calculates zoom based on the width of the content. Useful when fitting a wide content or content of unknown width onto a PDF page
      • AutomaticFit

        public static final FitToPaperModes AutomaticFit
        Measures minimum HTML content width after it is rendered by the browser using the smallest view port possible Useful when fitting smaller content onto a wide page
      • ContinuousFeed

        public static final FitToPaperModes ContinuousFeed
        Creates a single page PDF which will force its entire content's width and height to fit into one page. Can be used for a consumer bill or receipt. Useful when printing bill or receipt
    • Method Detail

      • values

        public static FitToPaperModes[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (FitToPaperModes c : FitToPaperModes.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static FitToPaperModes valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null