The Stack Overflow podcast is back! Listen to an interview with our new CEO.

Questions tagged [geometry-generator]

For questions about the geometry generator symbol layer style in QGIS.

Filter by
Sorted by
Tagged with
3
votes
1answer
39 views

Set geometry generator polygon to have flat end caps

I'm trying to buffer a line using Geometry Generator in QGIS (buffer($geometry,3)) However although I've set the Simple Fill join style to Miter I can't get the ends of the buffer to be flat. I ...
2
votes
1answer
87 views

Shorten leader-line for labels with geometry-generator

QGIS 3.8, Win 10. I have labels that are connected with the points they represent with a leader-line. The line is generated with geometry generator (going from the point-layer to the position where I ...
5
votes
1answer
44 views

Restricting label/line drawing to 45 deg. lines?

I've followed this tutorial to be able to move label positions and draw lines to connect them to the label dots, but I'd like to restrict the line drawing to 45˚ angles. Is there a way to do that? I ...
2
votes
0answers
42 views

Measure collected polygons in Geometry Generator, avoiding extra texts from multipart polygons

I combined a set of polygons on the first instance of Geometry generator using something like this: buffer(buffer(collect( $geometry, concat("MZNA","REGLABEL")), 0.1), -0.1) Buffers are meant to ...
1
vote
0answers
36 views

Use of QGIS/GRASS/SAGA procedures on Geometry Generator

Im new at QGIS, started 2 weeks ago. I'm trying to automatize the display of a map and get rid of some "duplicated" layers and all the extra work. I need to know if SAGA's dissolve can be used in the ...
3
votes
1answer
44 views

Geometry Generator - Straight lines not curved

I have QGIS 3.8.2 installed and started to look at the Geometry Generator. I have a layer of airline tracks and trying to create a curved line linking start and end points. I did a lot of searching ...
1
vote
1answer
66 views

QGIS geometry generator for marker line

I'm drawing marker line with user defined geometry of the marker (see example on the picture). Markers are placed with interval of screen (not map) units. It's possible to do with svg-marker or font ...
1
vote
1answer
19 views

How to add point at the beginning of ta call out line

I am trying to add a point at the start of my callout lines in QGIS but I don't manage. I create an additional geometry generator to my callout line and use this code: make_point(closest_point($...
2
votes
0answers
53 views

Converting lat/long to EPSG:27700 in geometry generator expression

I have incorporated a geometry generator into a style in QGIS 3.4 which creates a callout line from a feature to its relevant spatial position. For reasons out of my control our projects use CRS: ...
1
vote
0answers
49 views

Layer Styling by Geometry Generator in QGIS 3.6

I am trying to create custom styling by using Geometry Generator in QGIS 3.6 but I got an error expression. segments_to_lines ( $geometry) ramp_color('Viridis', scale_linear( length( ...
1
vote
1answer
53 views

Geometry generator in print composer

I am trying to create folding marks in the QGIS-print composer. Basically they are just markers along a line - with the twist, that the spacing is not even. I want to avoid having to create several ...
4
votes
2answers
194 views

How to divide a buffer using geometry generator in QGIS 3.X

Some background and working PostGIS query and Python script available here. How to split circles in 12 sections in PostGIS? I don't want to create a new polygon layer out of points. I really like ...
3
votes
1answer
292 views

QGIS Geometry Generator Line Type

I am trying to create a line style for a multiline geometry. I am hoping to create a linetype which looks like the following The Points are not an issue, its the line/lines entering and exiting at ...
3
votes
2answers
130 views

Which Units Geometry Generator in QGIS works with?

While modifying some geometries in QGIS in my previous question Adjusting flow map styles in QGIS: Varying buffers' sizes I ended up with a huge confusion regarding the dimensions/units that Geometry ...
3
votes
0answers
209 views

pyqgis - geometry generator - line pattern fill

I'm trying to make a line pattern fill in QGis using the geometry generator and a python function. The code is inspired from this answer : Save line geometry as points geometry in QGIS (pyqgis) from ...
4
votes
2answers
271 views

Geometry Generator - Line pattern fill to a buffer of x metres

I have an image below to help illustrate the style I'm trying to apply to my polygon. I have an idea of what I need to type in the geometry generator but can't get it to work. Something along the line ...
2
votes
0answers
60 views

Unexpected behavior of collect() in geometry generator

I'm having unexpected results using geometry generator with the following expression: buffer(collect($geometry),0) …which was an answer given in this topic. I have used this previously with the ...
3
votes
1answer
95 views

Using geometrygenerator and different CRS in QGIS?

In a QGIS3-project (QGIS Version 3.4.3) I'd like to display points from a textfile and constructed lines from this points in an given length and an angle from the textfile with the geometrygenerator. ...
3
votes
3answers
338 views

Draw line to next feature with distance as label (dynamic)

I would like to dynamically draw the shortest line to the next object (Geometry Generator?). Example: I have a network-layer (streets) and a point-layer. I know the distance from every point to the ...
3
votes
1answer
206 views

Geometry Generator - make line to polygon perimiter

I would like to improve the way arrows point to polygons when moving labels. I have some fields with unique numbers associated with each one. When the centroid of a polygon is outside the physical ...
2
votes
0answers
52 views

Achieving the opposite of the shortest_line() function in QGIS?

I currently use the Geometry Generator styling on a point layer to draw the intersection between protection buffers around tree points and another polygon (say a building footprint) using the ...
2
votes
0answers
82 views

How to create pattern fill via geomtry generator in QGIS3?

I would like to style polygon layer using geometry generator to create point patterns but using just generated points geometry. Is it possible? How can I achieve that? I know that I can use just use ...
5
votes
2answers
169 views

Geometry generator line from centroid to edge of irregular polygon

I have a point layer styled with the following geometry generator formula for an irregular polygon. It is the union of (a) a circular buffer with (b) a tree canopy spread buffered by 1m (where that ...
1
vote
1answer
354 views

Geometry Generator Line to Polygon Feature

I had great luck using Carlos' answer here to make lines from features in a point-shapefile layer to their labels, but when I tried the same technique with a shapefile layer of polygons, it won't work....
3
votes
0answers
246 views

QGIS draw line segments with “geometry generator” based on segments angle

I have quite a hard problem to solve here and I don't know if its even possible with the geometry functions in QGIS. I have a line geometry with equidistant vertices, that is, same length segments. ...
3
votes
0answers
108 views

Drawing a line to a point - style in QGIS

I need to create a style in QGIS in which the line is moved away from the second line by 2 units, but their ends merge at one point. I created 3 geometry generators - 3 lines. At the ends of the line: ...
1
vote
0answers
68 views

Geometry-generated lines not showing on QGIS Cloud

I have a points layer (tested as both a delimted text file and as a point shapefile) which is styled as shown below where the lines were created using the Geometry Generator. Please ignore the ...
1
vote
1answer
248 views

Comparing values across attributes of one feature in QGIS

I am using QGIS 2.18 I have a shapefile that contains data of each state of India, and the number of people per state following a particular religion. Each feature has the following attributes: ...
5
votes
1answer
376 views

Rotating polygon in geometry generator based on feature attribute?

That's a bounding box generated with the geometry generator with variables from a table: geom_from_wkt( 'POLYGON(('|| (x( $geometry ) + ("width"-"bleed")*"scale"/2)||' '||(y( $geometry ) + "height"*...
9
votes
2answers
445 views

Create an arc of lines from a line and a value

I'm trying to recreate an Origin-Destination plot like this: I have managed to munge the data into a MSOA to LAD table and can draw a map like this for one of the origin MSOA. Which once you allow ...
0
votes
1answer
493 views

Create callout from label to edge of polygon with Geometry generator with QGIS

With make_line(centroid ($geometry), make_point("x","y")) you can draw a line between the label and the center of an polygon, like this: Is there a way to draw a line just between the border/edge of ...
3
votes
3answers
606 views

Extract coordinates of lower right corners of polygon

Using QGIS 2.18.14, I would like to know the node number at lower-right corner of each polygon, shown as red circle in a image below. My goal is to obtain xy coordinates, by giving such number n to ...
12
votes
2answers
365 views

Displaying generated lines out of map extent using QGIS?

I have drawn an OD flow map using QGIS geometry generator, using the following expression : make_line( centroid( $geometry ), centroid( geometry( get_feature( 'Layer2', 'Attribute1', attribute( ...
7
votes
1answer
371 views

Styling shared boundaries in QGIS?

I have 2 polygon layers, 1 showing roads and another showing parking restrictions on those roads (no parking, residents only, etc). I'm trying to style the layer according to the markings that would ...
2
votes
2answers
693 views

How to rotate a geometry created by the geometry builder in QGIS

This topic goes into making polygons based on point locations; Using QGIS Geometry Generator to get rectangle from point? Is there a way to apply a rotation to the geometry generated? I have a field ...
8
votes
1answer
287 views

Rotate geometry generator marker line depending on map projection QGIS

I'd like to rotate marker line made from geometry generator function: the thing is that, by means of geometry generator I create line via make_line and points are the calculated values (based on ...
1
vote
0answers
311 views

Creating multiple polygons within one geometry generator using QGIS?

Is it possible to create multiple geom_from_wkt() elements like Using QGIS Geometry Generator to get rectangle from point? in a single geometry generator symbol layer?
3
votes
0answers
669 views

Geometry generator & get_feature

I am just trying to follow anita graser's examples in https://anitagraser.com/2017/04/08/a-guide-to-geometry-generator-symbol-layers/ - where the "Creating a line between features in different layers" ...
9
votes
1answer
242 views

Using some 'temporary variables' in QGIS Geometry generator symbol layer type expression?

Making use of the Geometry generator symbol layer type, I draw rectangles of dimensions @nv_bg_w (width) and @nv_bg_h (height) (project variables) to line features, either at coordinates text_x, ...
18
votes
2answers
3k views

Creating leader lines for moved labels

With a lot of help from gis.stackexchange.com I've created leader lines for point symbols. The lines are based on a geometry generator symbology: Shortening line geometry using expression dialog in ...
7
votes
2answers
1k views

Shortening line geometry using expression dialog in QGIS?

I use the "Offset Point Symbol" tool and a geometry generator symbology to create dynamic leader lines. A sample file is available at http://hub.qgis.org/issues/15201 (Add snapping for 'Offset Point ...
8
votes
2answers
1k views

Seeking QGIS geometry generator manual?

I'd like to create some flow maps like the ones shown in Underdark's post: https://anitagraser.com/2016/12/18/details-of-good-flow-maps/ I have a set of location points, say 50, and I'd like to ...
6
votes
4answers
4k views

Using QGIS Geometry Generator to get rectangle from point?

I would like to translate a point (from a point layer) to a rectangle polygon using the new Geometry Generator from QGIS 2.14. I know the length and the height of the resulting rectangle. The point ...