QGIS API Documentation 3.41.0-Master (45a0abf3bec)
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
QgsLayoutExporter::PdfExportSettings Struct Reference

Contains settings relating to exporting layouts to PDF. More...

#include <qgslayoutexporter.h>

Public Member Functions

 PdfExportSettings ()
 

Public Attributes

bool appendGeoreference = true
 Indicates whether PDF export should append georeference data.
 
double dpi = -1
 Resolution to export layout at. If dpi <= 0 the default layout dpi will be used.
 
bool exportLayersAsSeperateFiles = false
 true if individual layers from the layout should be rendered to separate PDF files.
 
bool exportMetadata = true
 Indicates whether PDF export should include metadata generated from the layout's project's metadata.
 
QStringList exportThemes
 Optional list of map themes to export as Geospatial PDF layer groups.
 
QgsLayoutRenderContext::Flags flags = QgsLayoutRenderContext::Flags()
 Layout context flags, which control how the export will be created.
 
bool forceVectorOutput = false
 Set to true to force vector object exports, even when the resultant appearance will differ from the layout.
 
bool includeGeoPdfFeatures = true
 true if feature vector information (such as attributes) should be exported during Geospatial PDF exports.
 
QVector< qreal > predefinedMapScales
 A list of predefined scales to use with the layout.
 
bool rasterizeWholeImage = false
 Set to true to force whole layout to be rasterized while exporting.
 
bool simplifyGeometries = true
 Indicates whether vector geometries should be simplified to avoid redundant extraneous detail, such as vertices which are not visible at the specified dpi of the output.
 
Qgis::TextRenderFormat textRenderFormat = Qgis::TextRenderFormat::AlwaysOutlines
 Text rendering format, which controls how text should be rendered in the export (e.g.
 
bool useIso32000ExtensionFormatGeoreferencing = true
 true if ISO3200 extension format georeferencing should be used.
 
bool useOgcBestPracticeFormatGeoreferencing = false
 true if OGC "best practice" format georeferencing should be used.
 
bool writeGeoPdf = false
 true if geospatial PDF files should be created, instead of normal PDF files.
 

Detailed Description

Contains settings relating to exporting layouts to PDF.

Definition at line 277 of file qgslayoutexporter.h.

Constructor & Destructor Documentation

◆ PdfExportSettings()

QgsLayoutExporter::PdfExportSettings::PdfExportSettings ( )
inline

Definition at line 279 of file qgslayoutexporter.h.

Member Data Documentation

◆ appendGeoreference

bool QgsLayoutExporter::PdfExportSettings::appendGeoreference = true

Indicates whether PDF export should append georeference data.

Since
QGIS 3.10

Definition at line 307 of file qgslayoutexporter.h.

◆ dpi

double QgsLayoutExporter::PdfExportSettings::dpi = -1

Resolution to export layout at. If dpi <= 0 the default layout dpi will be used.

Definition at line 284 of file qgslayoutexporter.h.

◆ exportLayersAsSeperateFiles

bool QgsLayoutExporter::PdfExportSettings::exportLayersAsSeperateFiles = false

true if individual layers from the layout should be rendered to separate PDF files.

This option allows for separation of logic layout layers to individual PDF files. For instance, if this option is true, then a separate PDF file will be created per layer per map item in the layout. Additionally, separate PDF files may be created for other complex layout items, resulting in a set of PDF files which contain logical atomic components of the layout.

This option is designed to allow the PDF files to be composited back together in an external application (e.g. Adobe Illustrator) as a non-QGIS, post-production step.

Since
QGIS 3.14

Definition at line 364 of file qgslayoutexporter.h.

◆ exportMetadata

bool QgsLayoutExporter::PdfExportSettings::exportMetadata = true

Indicates whether PDF export should include metadata generated from the layout's project's metadata.

Since
QGIS 3.2

Definition at line 315 of file qgslayoutexporter.h.

◆ exportThemes

QStringList QgsLayoutExporter::PdfExportSettings::exportThemes

Optional list of map themes to export as Geospatial PDF layer groups.

If set, map item's which are not assigned a specific map theme will iterate through all listed themes and a Geospatial PDF layer group will be created for each.

If PdfExportSettings::writeGeoPdf is false than this option has no effect.

Definition at line 402 of file qgslayoutexporter.h.

◆ flags

QgsLayoutRenderContext::Flags QgsLayoutExporter::PdfExportSettings::flags = QgsLayoutRenderContext::Flags()

Layout context flags, which control how the export will be created.

Definition at line 320 of file qgslayoutexporter.h.

◆ forceVectorOutput

bool QgsLayoutExporter::PdfExportSettings::forceVectorOutput = false

Set to true to force vector object exports, even when the resultant appearance will differ from the layout.

If false, some items may be rasterized in order to maintain their correct appearance in the output.

This option is mutually exclusive with rasterizeWholeImage.

Definition at line 300 of file qgslayoutexporter.h.

◆ includeGeoPdfFeatures

bool QgsLayoutExporter::PdfExportSettings::includeGeoPdfFeatures = true

true if feature vector information (such as attributes) should be exported during Geospatial PDF exports.

If PdfExportSettings::writeGeoPdf is false than this option has no effect.

Definition at line 392 of file qgslayoutexporter.h.

◆ predefinedMapScales

QVector<qreal> QgsLayoutExporter::PdfExportSettings::predefinedMapScales

A list of predefined scales to use with the layout.

This is used for maps which are set to the predefined atlas scaling mode.

Since
QGIS 3.10

Definition at line 409 of file qgslayoutexporter.h.

◆ rasterizeWholeImage

bool QgsLayoutExporter::PdfExportSettings::rasterizeWholeImage = false

Set to true to force whole layout to be rasterized while exporting.

This option is mutually exclusive with forceVectorOutput.

Definition at line 291 of file qgslayoutexporter.h.

◆ simplifyGeometries

bool QgsLayoutExporter::PdfExportSettings::simplifyGeometries = true

Indicates whether vector geometries should be simplified to avoid redundant extraneous detail, such as vertices which are not visible at the specified dpi of the output.

Since
QGIS 3.10

Definition at line 336 of file qgslayoutexporter.h.

◆ textRenderFormat

Qgis::TextRenderFormat QgsLayoutExporter::PdfExportSettings::textRenderFormat = Qgis::TextRenderFormat::AlwaysOutlines

Text rendering format, which controls how text should be rendered in the export (e.g.

as paths or real text objects).

Since
QGIS 3.4.3

Definition at line 328 of file qgslayoutexporter.h.

◆ useIso32000ExtensionFormatGeoreferencing

bool QgsLayoutExporter::PdfExportSettings::useIso32000ExtensionFormatGeoreferencing = true

true if ISO3200 extension format georeferencing should be used.

This is a recommended setting which results in Geospatial PDF files compatible with the built-in Acrobat geospatial tools.

If PdfExportSettings::writeGeoPdf is false than this option has no effect.

Definition at line 374 of file qgslayoutexporter.h.

◆ useOgcBestPracticeFormatGeoreferencing

bool QgsLayoutExporter::PdfExportSettings::useOgcBestPracticeFormatGeoreferencing = false

true if OGC "best practice" format georeferencing should be used.

Warning
This results in geospatial PDF files compatible with a unnamed suite of tools starting with Terra and ending with Go, but can break compatibility with the built-in Acrobat geospatial tools (yes, Geospatial PDF format is a mess!).

If PdfExportSettings::writeGeoPdf is false than this option has no effect.

Definition at line 385 of file qgslayoutexporter.h.

◆ writeGeoPdf

bool QgsLayoutExporter::PdfExportSettings::writeGeoPdf = false

true if geospatial PDF files should be created, instead of normal PDF files.

Whilst geospatial PDF files can include some desirable properties like the ability to interactively query map features, they also can result in lower-quality output files, or forced rasterization of layers.

Note
Requires builds based on GDAL 3.0 or greater.
Since
QGIS 3.10

Definition at line 349 of file qgslayoutexporter.h.


The documentation for this struct was generated from the following file: