The Printing tool allows users to create high quality PDF maps, suitable for hard copy printing.
The user selects a paper size, orientation, quality (DPI) and map scale. Once the map scale has been selected a blue rectangle will appear on the map. The rectangle shows what will be included in the PDF map and its position can be adjusted by panning the map.
After clicking PRINT, a PDF map will be prepared and sent to the user’s browser. An example map is shown below.
The Printing tool has the following settings.
If you require attribution text to appear on printed maps, you can include it here. When the output PDF is created, a label object within the print composer with Item ID set to Attribution (if present) will have its content overwritten with this value.
Is a comma-separated list of scale denominators which are presented to the user in the Printing panel. Be aware that high-resolution printing at large paper sizes and small scale denominators may take some time to complete.
Within this section you can define the print templates supported within your QGIS project.
The ADD TEMPLATE button can be used to add template configurations and the - button to the right of the template name can be used to remove template configurations.
- Template name should match the name of the referenced print layout in the QGIS project which can be seen under Project > Layout Manager... in QGIS
- Paper size and Orientation should match those set in the QGIS print layout
- Viewport width and Viewport height should be set based on the paper dimensions of the map viewport, described below
Viewport width and Viewport height are needed to allow Mappin to correctly draw the blue map content indicator rectangle described above.
These values can be copied from the QGIS project file by:
- Opening the QGIS project file
- Selecting the appropriate print layout
- Project > Layouts > Your layout
- Selecting the map viewport
- Locating its height and width
- Items > Item Properties > Position and Size
- Noting down these measurements in mm
Print resolutions (DPI)¶
A comma-separated list of print resolutions which will be presented as options to users.
Please note that layer vector data will be rendered as vector graphics within the PDF and the print resolution only applies to raster-based printed elements.
When printing tile-based raster layers (e.g. WMTS) at higher DPI settings, Mappin fetch tiles from a more ‘zoomed-in’ zoom level and downsample them to meet the DPI setting. If the tile-based raster layer features labels, these may appear very small in the printed PDF. For the best results, use vector-based background maps.
creating complicated high resolution PDFs can consume a significant amount of resources. Consider this when specifying which resolutions you will allow your users to request. 300 DPI should be adequate for hard copy printing and 96 will be sufficient for most non-hard copy use cases.
Map Title and Description¶
When enabled, these options present the users with the Map Title and Map Description fields in the print dialog seen in the first image. These user-defined fields will then replace the content of label objects within the print composer with Item IDs set to MAPPIN_TITLE and MAPPIN_DESCRIPTION.