The Ultimate Java PDF Library SDK

Seamless PDF Integration for Java

Download Trial Purchase

JVM flags

JPedal includes a number of flags which can be added to the java command line to alter the way it operates. These are listed in the tables below. The values are all lower case.

For example, the command:

java -Dorg.jpedal.flattenForm=true -jar jpedal.jar $InputFile $OutputDirectory

Flattens out all the Forms, putting them on the page display, but No interactivity.

You can also set the values using System.setProperties() in Java but you must do this before accessing JPedal.

General JVM flags in JPedal

FlagDescription of JVM functionExample usage
org.jpedal. avoidCleanupRaster=”true”Tells JPedal to avoid reducing some large images as this can crash Java-Dorg.jpedal.avoidCleanupRaster=”true”
org.jpedal.fontdirsTells JPedal to register fonts on these directories and use fonts for unembedded fonts in PDF. It expects a comma separated list (directories do not need to exist so it is useful for cross-platform settings).-Dorg.jpedal.fontdirs= “C:/win/fonts, /usr/etc/X11/fonts/”
org.jpedal. useTTFontHinting(Added in 4.20) Tells JPedal to use Truetype font hinting. Default is false as some fonts contain instructions on which Apple has a patent.-Dorg.jpedal.useTTFontHinting= “true”
org.jpedal.memoryDownsamples images to save memory.-Dorg.jpedal.memory= true
org.jpedal.hiresMaintains images at highest resolution.-Dorg.jpedal.hires= true
org.jpedal. securityproviderInstructs JPedal to use an alternative Security library for encryption.-Dorg.jpedal.securityprovider= “org.bouncycastle.jce.provider.BouncyCastleProvider”
org.jpedal. CMYKprofileInstructs JPedal to use a different ICC profile (file ends .icm) from default for CMYK .-Dorg.jpedal.CMYKprofile= “C:/altProfile.icm”
org.jpedal. RGBprofileInstructs JPedal to use a different ICC profile (file ends .icm) from default for sRGB .-Dorg.jpedal.RGBprofile= “C:/altProfile.icm”
org.jpedal. downsampleNew downsampling class org.jpedal.images.SamplingFactory offers several options to improve memory usage and speed on PDFs with large images. This value can also be set programmatically.-Dorg.jpedal.downsample= “high”
org.jpedal. noURLaccessStop any URL from opening in browser. It also disables any tooltips. Settings are true, false or any message to display (which also stops access)-Dorg.jpedal.noURLaccess= “We have disabled URL links”
org.jpedal. fasterPNGRemove safety checks and write out as Indexed PNG.-Dorg.jpedal.fasterPNG= true
org.jpedal.flattenFormFlattens out all the Forms, putting them on the page display, but No interactivity.-Dorg.jpedal.flattenForm= true
org.jpedal.inclusiveLogFiltersOnly shows the messages which contain the values given by the flag. The values are given as comma-seperated values.-Dorg.jpedal.inclusiveLogFilter= “memory,error”

Extra flags in examples

FlagExampleDescription of UsageExample Use
org.jpedal. compress_jpegConvertPagesToHiResImages, ConvertPagesToImages(Not live in latest release) Write out JPeg files with user setting for JPEG compression quality (0= very samll, poor files, 1= very large files with no compression)-Dorg.jpedal.compress_jpeg= 0.5
org.jpedal. compress_tiffExtractClippedImages, ExtractImages, ConvertPagesToImagesWrite out Tiff files compressed-Dorg.jpedal.compress_tiff= true
ConvertPagesToImagesWrite out all images to one Tiff file-Dorg.jpedal.multipage_tiff=true
org.jpedal. jpeg_dpiExtractClippedImages, ExtractImages, ConvertPagesToImages(Not live in latest release) Write out Jpeg files compressed-Dorg.jpedal.jpeg_dpi= true
org.jpedal. opiExtractImagesInclude OPI metadata in XML information with images-Dorg.jpedal.opi= true
org.jpedal. startWindowSizeViewer(From 3.77b28) the startup size of the Viewer can be set on startup with value width x height-Dorg.jpedal.startWindowSize= 400×300
org.jpedal. pageViewerPage number to open document, if 4
org.jpedal. bookmarkViewerLocation to open document (either a bookmark or named destination), if valid.-Dorg.jpedal.bookmark= into
org.jpedal. thumbnailViewerFlag to disable thumbnails. Default is on.-Dorg.jpedal.thumbnail= false
org.jpedal. configureViewerViewerFlag to disable menu options from config file. See this link for details.-Dorg.jpedal.configureViewer= config.txt
org.jpedal. passwordViewerPassword to open file – set to null if not needed-Dorg.jpedal. password= “mypassword”
org.jpedal. Viewer.PrefsViewerLocation of Properties file to be used when opening Viewer-Dorg.jpedal.Viewer.Prefs= “C:prop.xml”
org.jpedal. defaultViewerScalingViewerFlag to enable user to startup with a specific scaling value (ie Fit Width, 25, 100, Fit Height). Value must be on scaling list or will be ignored.-Dorg.jpedal.defaultViewerScaling= “Fit Width”
org.jpedal. suppressViewerPopupsViewerFlag to enable user to suppress all popups at start.-Dorg.jpedal.suppressViewerPopups= true
org.jpedal.pageSizeConvertPagesToHiResImagesSet pagesize to scale up to (preserving aspect ratio). Values are width x height-Dorg.jpedal.pageSize= “1000×800”
org.jpedal. pageMaxScalingConvertPagesToHiResImagesSet maximum scaling allowed so rogue image does not cause hugh images-Dorg.jpedal.pageMaxScaling= 4
org.jpedal. pageSizeOverrides
ConvertPagesToHiResImagesSet whether pageSize or image scaling takes priority-Dorg.jpedal.pageSizeOverrides= “true”
org.jpedal. defaultPrinter
PrintPanelSet default printer to be used by JPedal-Dorg.jpedal.defaultPrinter= “Adobe PDF”
org.jpedal. printPaperSize
PrintPanelSet default paper size to print on-Dorg.jpedal.printPaperSize= “A4 (borderless)”
org.jpedal. separation
ConvertPagesToHiResImages/ ConvertPagesToImagesCreate multiple images with separate image, text and Vector content on each. Find out more details.-Dorg.jpedal.separation= “all”
org.jpedal. imageType
ConvertPagesToHiResImages/ ConvertPagesToImagesSet color type and color depth of the image to be saved out using a TYPE variable from a awt BufferedImage.-Dorg.jpedal.imageType= 2
IDRSolutions Limited 1999-2016