Questions tagged [qgis-print-layouts]

Print layout provides growing layout and printing capabilities in QGIS 3.

Filter by
Sorted by
Tagged with
3
votes
2answers
25 views

Setting new size for printLayout using PyQGIS

I am trying to create an A0 layout from PyQGIS. I tried the following code but it doesn't work. from qgis.core import * manager = QgsProject.instance().layoutManager() layouts_list = manager....
1
vote
0answers
35 views

QGIS Repeat Page Layout

I'd like to reuse a page layout across multiple pages - specifically the page border, the title, etc. Is there an easy way to do this? Right now I'm making new pages and copy/pasting everything. ...
2
votes
1answer
61 views

Layout expression for getting all features of layer within the current map view in QGIS 3?

In a map layout template, I want to insert an expression which gets all feature's names of a certain layer, which are contained in the current layout's view/extent. Is there a way to get an aggregate ...
1
vote
1answer
52 views

Creating LAT / LONG grid labels with Northing/Southing and Easting/Westing suffix in QGIS?

I´m using QGIS 3.6. I have my map as you can see below: I would like to have the labels in LAT / LONG coordinates like (40E ; -10S). Can you please tell me how can I do this? I saw: https://...
2
votes
1answer
45 views

QGIS 3 export report in Python

In QGIS we have new layout type: Report. I didn't find tutoral to export this in PDF in Python. Where can I find Python code examples?
1
vote
0answers
40 views

QGIS 3 suddenly slow

I created a project in QGIS 2 and put in an Atlas. I then realised that QGIS 2 only allows 500 objects in the Atlas preview, which is no good to me (I've got about 2000+) so copied the project, opened ...
0
votes
0answers
27 views

In QGIS Layout Manager, padding inside html table not working?

For a HTML field in the QGIS Layout Manager I have in the "Source" field a table like: <table> <tr> <td>1</td> <td>2</td> </tr> <tr> &...
1
vote
2answers
61 views

How to select a specific print layout (by name) in QGIS 3?

I'm a real beginner in Python. I'm using a Python script to produce maps automatically. This script is working but it is failing in the last part: saving the current map with a specific print layout. ...
0
votes
0answers
15 views

QGIS 3.4, Why doesn't MapBox look the same ion Map canvas as in Layout? [duplicate]

When I export, the basemap looks completely different. And then Exported as .jpeg: Have asked MapBox and they don't know.
1
vote
0answers
19 views

QGIS adding additional (excess) map detail

I'm having a problem with QGIS (3.2.3-Bonn) which I hope the collective wisdom here can help with. I'm currently trying to make a base map with GPS data on top. So far so good. I found a decent ...
1
vote
0answers
33 views

Deleting text from Map Items in QGIS print composer?

I have been using QGIS for some time, and what I am experiencing is not something that I have had issues with before. It appears to be a gitch. I created a map in QGIS 3.6.2. Then, I exported it as ...
1
vote
2answers
103 views

QGIS+PostGIS set atlas extents to include atlas feature and point

I have a QGIS print layout with an atlas layer for which I would like the map extents to show the current atlas feature and a nearby point. The layer provider is postgis. It seems the only way to do ...
2
votes
1answer
91 views

Loading print layout using an existing template (.qpt) with PyQgis3

I'm trying to load a print layout (.qpt) which I saved earlier via PyQgis. I found this earlier entry, but it's for QGIS 2.x and thus doesn't work for QGIS3: Programmatically load composer from ...
1
vote
1answer
46 views

Feature Count for Categorized Layers with the Atlas function of Print Layout in QGIS 3

In QGIS, is it possible to count the features of each class in a categorized layer where the features being counted are limited to those that are inside the current atlas feature? I have tried ...
1
vote
0answers
25 views

Where is Composition ‣ Paper and Quality panel of QGIS? [duplicate]

A right-click on panel doesn't bring this up and not listed in View/Toolbars or View/Panels ... have a very specific page size so really need to change from default A4.
1
vote
1answer
40 views

Is it possible to print a map in PyQgis3 of a database table without rendering the layer in the project gui?

There is a way to print a map using pyqgis3 without rendering the vector layer in the project interface? (by giving just the connection to the table, the map extent and the style )
1
vote
1answer
73 views

How do I add a QgsLayoutItemMapGrid to a QgsLayoutItemMap with PyQGIS 3.x?

I'm trying to add a grid to a map but I don't get any results. My code: def add_map_layout_item(self, list_maplayers, qgs_rectangle, ...
4
votes
1answer
90 views

Layout export from stand-alone PyQGIS script shows empty map

I have a problem with exporting of a QGIS layout by the pyQGIS. I have prepared the qgz project and also the qpt layout. When I try to export the layout to PDF by QgsLayoutExporter.exportToPdf by ...
1
vote
1answer
94 views

How to show layout of layout manager from Python console or Python script QGIS 3

How can I show/open layout '2019_A' of Layout Manager from Python console? How show window layout specific? I checked in menu Interface Customization, mActionShowLayoutManager and I do not know how ...
0
votes
0answers
18 views

Snapping to added guides in QGIS Layout does not actually align objects

I added some horizontal guides to QGIS layout with the idea of aligning my main map frame to the legend. I also activated the "Snap to Guides" option under View>Snap to Guides. When I snap the map ...
0
votes
1answer
78 views

Adjusting QGIS 3.6 Print Composer default output resolution? [duplicate]

When exporting a print layout to image or PDF in QGIS 3.6, the default resolution is 300dpi. I'd like to change that default. There's an analogue question here: Adjusting QGIS Print Composer output ...
1
vote
1answer
70 views

Editing a map created with PyQgis3 in Qgis Print Layout

I create a new print layout using PyQgis and then I open it in the layout designer. Everything seems ok till I try to refresh the page or update the map extent, then map disappears. project = ...
2
votes
0answers
76 views

QGIS print layout (large size printed image)

I have been asked to create large size images to be the printed with a good quality to look at. The images could be with dimensions of 1 meter in height or width, but even larger. I must create these ...
2
votes
1answer
56 views

How to duplicate Layout PyQt5 QGIS 3?

I want script in python3 with QGIS 3? For example: This code create a layout 2019_A4 and add Layout Manager. I need a code make same in QGIS3 using QgsLayoutManager with Methods duplicateLayout ...
1
vote
1answer
74 views

Scale of shape in a Print Layout

I am making an atlas with a fixed scale, and want to include circles with a fixed radius (in scaled kilometers) about the center point in the atlas (see image below). I was able to do this by ...
0
votes
1answer
46 views

Automatically creating html for QGIS atlas feature, listing all attributes?

I want to create a text box containing HTML, to list all attributes belonging to the current atlas feature. I think I can do this by hand, writing html which references each and every field. For a ...
0
votes
0answers
60 views

Filtering attribute table in QGIS Atlas?

I have encountered a problem with filtering "show only features visible within a map" in QGIS Atlas ?composer. I need to have an attribute table with all mileage posts visible within one map. ...
2
votes
3answers
188 views

Re-docking/pining panel in layout window in QGIS?

Using QGIS v3.4.4 and accidentally closed the "Item Properties" and "Items" panels in the layout window. Cannot now get them to re-dock/pin back into place. They will only float. Have googled ...
2
votes
0answers
25 views

Calling a Python function for each page in an atlas

I have made a script to do some calculations for each page of a QGIS atlas (QGIS Atlas with insert map) The script is adjusting the bounding box of a map on the layout page. To make it run for each ...
1
vote
2answers
87 views

QGIS Atlas with insert map

I am making a document with descriptions of how to get to some points of interest. For each point I am making a document that contains two maps, one showing the general overview and the larger roads (...
1
vote
0answers
31 views

Rotate bottom coordinates to be upside-down in print layout (QGIS)

Is it possible in QGIS (3.6) to somehow make all coordinates on the 4 sides of a map in a print layout point towards the map? I found the option for the 2 vertical sides. If the map is rotated by 90° ...
0
votes
1answer
130 views

How do I make a map's background transparent in a layout?

I am trying to add an overview map to my layout. The main map is projected while the overview map is a 'globe' (image below). I want to make the white part of the overview map transparent. I have ...
1
vote
0answers
25 views

Inserting title block when making print templates

I am creating a print template for some figures for a report. These figures will need a title block with all my company's details. Typically when I use it in surfer it is just a bunch of lines ...
1
vote
2answers
123 views

Display credit in map composer? [duplicate]

I am trying to publish maps from QGIS Map Composer. I would like to automatically add the credits of the background layers displayed in the composition (like OSM, Bing, ...) I am aware of such a ...
2
votes
1answer
73 views

British National Grid Sheet Reference Letters in Print Layout

I have managed to get a custom grid on the print layout to convert northing and eastings (XY) to ESPG:27700 grid references i.e NS00 through to NS99. The problem I am coming across is when when NS99 ...
3
votes
1answer
53 views

Exclude image from rendering in layout if file not found

I'm using QGIS 3.4. print layout to create an atlas with photos of features. I have a folder with photos and each photo is named with an ID of related feature. Example: If ID of feature is 543, ...
2
votes
2answers
189 views

QGIS 3.4. - page numbers in print layout

I'm using QGIS print layout to create an atlas with around 180 features. I'm trying to find a way to add page number in print layout. I tried adding text label with [% @atlas_featurenumber %] to show ...
1
vote
1answer
136 views

Auto update QGIS Legend

I have a project with many layers. Some layers are objects of interest while other layers are custom layers. Simplified example: Streets (polygon) Buildings (polygon) Street names (point) I created ...
2
votes
1answer
187 views

PyQGIS - Print Layout Legend. setLegendFilterByMapEnabled()

I'm creating a legend in my print composer and only want "visible", or active, layers shown in the legend. This means I want only layers with the box checked in my layers panel. Here is how I create ...
1
vote
1answer
195 views

PyQGIS - Print Layout Label text size

I'm adding a label to a Print Layout using python. I do so with the following code: label = QgsLayoutItemLabel(layout) label.setText("This is my map label") label.adjustSizeToText() layout....
1
vote
1answer
63 views

Drawing point and path graphic shapes in print layout of QGIS?

At QGIS 3.4.4, I would like to freehand draw points and paths (i.e. zigzag lines) graphic shapes on my print layout. However, I only see the option to draw rectangles, ellipses, and triangles, as ...
1
vote
1answer
523 views

QGIS 3.4 - Print composer export to image error

In QGIS 3.4.4.1 when exporting Print composer layout to image (.png, .jpeg) I get the following error message: "Cannot write to C:\xxxxx.png. This file may be open in another application". This file ...
1
vote
2answers
323 views

QGIS Print Layout: how to create a drop-shadow for items

USing QGIS 3.4.4, I've added a map to a print layout, given it a black frame, and it looks fine. Now how do I add a drop-shadow effect to the map frame in the layout? I haven't found anything in the ...
2
votes
1answer
117 views

QGIS 3 Scale Bar Should Print at 1" But Does Not

In QGIS 3.4, I am using the Print Layout to print some UTM lines with scale bars. My goal is to make a PDF of a map that is at 1:63360 or 1 inch to the mile. When I print the PDF, the mile Scale Bar ...
0
votes
0answers
25 views

How to increase the header height for an Layout Attribute Table in QGIS 3?

I need to increase the header height because the header text has 2 lines. The only way I could find to increase it was use cell margins. But that affects all rows. How to increase the height of the ...
3
votes
1answer
116 views

Automatically generate file name from text boxes in layout in QGIS

Suppose I have a layout template in QGIS, with a lot of text boxes like the title of the map, title of the project, a project code, ... When I export a map in pdf, is it possible to have it named ...
2
votes
3answers
143 views

Nesting project file name into layout in QGIS

Is there any way to automatically take information from the project file name into several boxes on a layout in QGIS? For example, if I had a file name of "185.005R1 - Geology Map.qgz" how could I ...
0
votes
0answers
48 views

QGIS print composer does not export high res details from Spatialite layer

I downloaded OSM.pbf data from Geofabrik, and I followed https://anitagraser.com/2014/05/31/a-guide-to-googlemaps-like-maps-with-osm-in-qgis/ this example to import pbf file to SpatiaLite layer for ...
0
votes
1answer
88 views

QGIS use layout name in styling expression

I have a .qgs file with a number of fairly complex styling rules showing the local Nordic ski trails. It has a single layout for printing on an 11x17 page. Until now the same PDF has been used for ...
2
votes
2answers
328 views

PyQGIS - remove layer from legend

I'm creating a simple print layout with Python. I've created a legend but I want to remove a few items from it. Here is my code to create a blank Print Layout called "LayoutWithLegend" and add a ...