PDF CLI Parameters/text/shared/guide/pdf_params.xhpOH: info extracted from filter/source/pdf/pdfexport.cxxPDF;command line parametersconvert to PDF;command line parameters
PDF Export Command Line Parameters
The PDF filter accepts a string of options containing PDF properties for export.
Examples:
To skip the first page of a Draw document:soffice --convert-to 'pdf:draw_pdf_Export:{"PageRange":{"type":"string","value":"2-"}}' test.odgTo add a tiled watermark:soffice --convert-to 'pdf:draw_pdf_Export:{"TiledWatermark":{"type":"string","value":"draft"}}' test.odgTo encrypt a file:soffice --convert-to 'pdf:draw_pdf_Export:{"EncryptFile":{"type":"boolean","value":"true"},"DocumentOpenPassword":{"type":"string","value":"secret"}}' test.odgTo set version 1.5 (instead of the default 1.7):soffice --convert-to 'pdf:draw_pdf_Export:{"SelectPdfVersion":{"type":"long","value":"15"}}' test.odg
Index
General Properties
NameDescriptionTypeDefault ValuePageRange If this property is set, it indicates the range of pages to be exported. To export all the pages, leave this property unset.To export a selection, leave this property unset and set only the property Selection.stringEmpty (all pages are exported)SelectionAn any corresponding to the current selection in the document.AnyUseLosslessCompressionSpecifies if images are exported to PDF using a lossless compression format like PNG or compressed using the JPEG format.booleanfalseQualitySpecifies the quality of the JPG export. A higher value produces a higher-quality image and a larger file.Minimum inclusive value: 1. Represents the lowest value that can be used. The lower the value, the worse is the image quality and the smaller is the file size.Maximum inclusive value: 100. Represents the highest value that can be used. The higher the value, the better is the image quality and the larger is the file size.long90ReduceImageResolutionSpecifies if the resolution of each image is reduced to the resolution specified by the property MaxImageResolution.booleanfalseMaxImageResolutionIf the property ReduceImageResolution is set to true, all images will be reduced to the given value in DPI. Possible values are: 75, 150, 300, 600 and 1200.long300SelectPdfVersionSpecifies the PDF version to emit. Possible values are:0: PDF 1.7 (default choice).1: PDF/A-1b2: PDF/A-2b3: PDF/A-3b15: PDF 1.516: PDF 1.617: PDF 1.7long0PDFUAComplianceCreates an accessible PDF file that follows the requirements of the PDF/UA (ISO 14289) specification.booleanfalseUseTaggedPDFDetermines if PDFs are created using special accessibility tags.booleanfalseExportFormFieldsSpecifies whether form fields are exported as widgets or only their fixed print representation is exported.booleantrueFormsTypeSpecifies the submit format of a PDF form. Possible values are:0: Specifies that form type FDF is used.1: Specifies that form type PDF is used.2: Specifies that form type HTML is used.3: Specifies that form type XML is used.long0AllowDuplicateFieldNamesSpecifies whether multiple form fields exported are allowed to have the same field name. booleanfalseExportBookmarks Specifies if bookmarks are exported to PDF. booleantrueExportPlaceholders Export the placeholders fields visual markings only. The exported placeholder is ineffective.booleanfalseExportNotesSpecifies if notes are exported to PDF.booleanfalseExportNotesPagesSpecifies if notes pages are exported to PDF. (Notes pages are available in Impress documents only).booleanfalseExportOnlyNotesPagesIf the property ExportNotesPages is set to true, specifies if only notes pages are exported to PDF.booleanfalseExportNotesInMarginSpecifies if notes in margin are exported to PDF.booleanfalseExportHiddenSlidesFor %PRODUCTNAME Impress, exports slides not included in slide shows.booleanfalseIsSkipEmptyPagesSpecifies that automatically inserted empty pages are suppressed. This option is active only if storing Writer documents.booleanfalseEmbedStandardFontsSpecifies whether to embed the 14 standard PDF fonts or not.booleanfalseIsAddStreamSpecifies that a stream is inserted to the PDF file which contains the original document for archiving purposes.booleanfalseWatermarkSpecifies the text for a watermark to be drawn on every page of the exported PDF file.string(empty)WatermarkColorSpecifies the color of the watermark textlong8388223 (light green)WatermarkFontHeightSpecifies the font height of the watermark text.longWatermarkRotateAngleSpecifies angle of the watermark text.longWatermarkFontNameSpecifies font name of the watermark text.stringHelveticaTiledWatermarkSpecifies the tiled watermark text.stringUseReferenceXObjectWhen the option is enabled, then the reference XObject markup is used: this is a simple operation, but viewers have to support this markup to show vector images. Otherwise a fallback bitmap is shown in the viewer.booleanfalseIsRedactModebooleanfalseSinglePageSheetsIgnores each sheet’s paper size, print ranges and shown/hidden status and puts every sheet (even hidden sheets) on exactly one page.booleanfalse
Initial View
InitialViewSpecifies how the PDF document should be displayed when opened. Possible values are:0: Select the default viewer mode, neither outlines nor thumbnails.1: The document is opened with outline pane opened2: The document is opened with thumbnail pane openedlong0InitialPageSpecifies the page on which a PDF document should be opened in the viewer application.long1MagnificationSpecifies the action to be performed when the PDF document is opened. Possible values are:0: Opens with default zoom magnification.1: Opens magnified to fit the entire page within the window.2: Opens magnified to fit the entire page width within the window.3: Opens magnified to fit the entire width of its bounding box within the window (cuts out margins).4: Opens with the zoom level specified in the Zoom property.long0ZoomSpecifies the zoom level a PDF document is opened with. Only valid if Magnification is set to "4".long100PageLayoutSpecifies the page layout to be used when the document is opened. Possible values are:0: Display the pages according to the reader configuration.1: Display one page at a time.2: Display the pages in one column.3: Display the pages in two columns odd pages on the right, to have the odd pages on the left the FirstPageOnLeft property should be used as well.long0FirstPageOnLeftUsed with the value 3 of the PageLayout property above, true if the first page (odd) should be on the left side of the screen.booleanfalse
User Interface
ResizeWindowToInitialPageSpecifies that the PDF viewer window is opened showing whole initial page when the document is opened.booleanfalseCenterWindowSpecifies that the PDF viewer window is centered to the screen when the PDF document is opened.booleanfalseOpenInFullScreenModeSpecifies that the PDF viewer window is opened full screen, on top of all windows.booleanfalseDisplayPDFDocumentTitleSpecifies that the title of the document, if present in the document properties, is displayed in the PDF viewer window title bar.booleantrueHideViewerMenubarSpecifies whether to hide the PDF viewer menubar when the document is active.booleanfalseHideViewerToolbarSpecifies whether to hide the PDF viewer toolbar when the document is active.booleanfalseHideViewerWindowControlsSpecifies whether to hide the PDF viewer controls when the document is active.booleanfalseUseTransitionEffectsSpecifies slide transitions are exported to PDF. This option is active only if storing Impress documents.booleantrueOpenBookmarkLevelsSpecifies how many bookmark levels should be opened in the reader application when the PDF gets opened. Possible values are:-1: all bookmark levels are opened1–10: indicate a bookmark level (from 1 to 10)long-1
Links
ExportBookmarksToPDFDestinationSpecifies that the bookmarks contained in the source %PRODUCTNAME file should be exported to the PDF file as Named Destination.booleanfalseConvertOOoTargetToPDFTargetSpecifies that the target documents with .od[tpgs] extension, will have that extension changed to .pdf when the link is exported to PDF. The source document remains untouched.booleanfalseExportLinksRelativeFsysSpecifies that the file system related hyperlinks (file:// protocol) present in the document will be exported as relative to the source document location.booleanfalsePDFViewSelectionSpecifies the way the exported PDF will be viewed (experienced) by the user. Possible values are:0: Specifies that the PDF will be exported with all the links external to the document treated as URI. This is the Default1: Specifies that the PDF will be exported in order to be viewed through a PDF reader application only. Valid only if not exporting to PDF/A-1 (e.g. SelectPdfVersion not set to 1).2: Specifies that the PDF will be exported in order to be viewed through an Internet browser, using the PDF plug-in provided with it. The bookmark of the URI will be rendered compatible with the target bookmark generated with %PRODUCTNAME PDF Export feature (see ExportBookmarksToPDFDestination).long0
Security
EncryptFileIf true, selects to encrypt the PDF document with a password. The PDF file can be opened only when the user enters the correct password.booleanfalseDocumentOpenPasswordThis is the password that allows the user to open the PDF file when EncryptFile is set to true.stringRestrictPermissionsIf true, selects to restrict some permissions. The permissions can be changed only when the user enters the correct password.booleanfalsePermissionPasswordThis is the password that allows the user to access some permissions restricted if RestrictPermissions is set to true.stringPreparedPasswordsPreparedPermissionPasswordstringPrintingSpecifies what printing is allowed. Possible values are:0: The document cannot be printed.1: The document can be printed at low resolution only.2: The document can be printed at maximum resolution.long2ChangesSpecifies the changes that can be made to the document. Possible values are:0: The document cannot be changed.1: Inserting deleting and rotating pages is allowed.2: Filling of form field is allowed.3: Both filling of form field and commenting is allowed.4: All the changes of the previous selections are permitted, with the only exclusion of page extraction (copy).long4EnableCopyingOfContentSpecifies that the pages and the document content can be extracted to be used in other documents (copy and paste).booleantrueEnableTextAccessForAccessibilityToolsSpecifies that the document content can be extracted to be used in accessibility applications.booleantrue
Digital Signature
SignPDFIf true, sign the PDF.booleanfalseSignatureLocation Additional information about the digital signature, location of the signatory.stringSignatureReasonAdditional information about the digital signature, reason for signature.stringSignatureContactInfoAdditional information about the digital signature, signatory contact information.stringSignaturePasswordCertificate passwordstringSignatureCertificateSignCertificateSubjectNamestringSignatureTSADuring the PDF signing process, the timestamp authority URL will be used to obtain a digitally signed timestamp that is then embedded in the signature.string