Related Plugins and Tags

QGIS Planet

3rd Crowdfunding on Point Clouds, Elevation Profiles and 3D Map View Enhancements

Lutra Consulting, North Road and Hobu are collaborating in a new crowd-funding campaign to extend these capabilities in future QGIS releases!

Highlights of the planned improvements include:

  • Point Clouds
    Creating point cloud processing tools for transformation, management and analysis of point clouds. Ensuring that extremely large (terabyte size) datasets can be handled well for both display and analysis.
  • Elevation Profiles
    Support embedding customisable elevation profiles into print layouts and atlases, and allow exporting elevation profiles to CSV and DXF.
  • 3D Maps
    Faster 3D maps for large scenes, an improved 3D measurement tool and further improvements to 3D scene navigation.

Your financial support is vital to make these improvements possible! Visit the crowd funding page for additional information on what is included in the effort and how you can financially contribute.

Crowd funding alert: Point Clouds, Elevation Profiles and 3D Map view improvements!

Together with our partners at Lutra Consulting and Hobu, we have once again have collated your feature requests for even MORE point cloud and QGIS elevation improvements and are ready to start working on them!

Here’s a taster of what to expect if our latest crowd funding campaign is successful:

  • Point cloud data management, transformation and analysis via incorporation of PDAL within the QGIS “Processing” toolbox
  • Optimised handling of large datasets to speed up your 3D maps, including dynamic data loading for complex 3D scenes
  • Combine multiple LAS/LAZ point cloud files into a single “virtual” point cloud for easy data management and display
  • Elevation profile tool embedded into print layouts, totally customizable, more efficient and with the ability to export profile data to CSV and DXF
  • General improvements to QGIS 3D map views, including an enhanced 3D measuring tool, additional camera controls and improving the configuration dialog options and functionality.

To find out more, check out the ‘Detailed proposal and deliverables’ section on the main crowd funding page. You may want to get some popcorn ready, it really is exciting!

We need your help to make this work possible. If you’d like to see these enhancements, pledge to the crowdfunding campaign before October 24, 2022.

QGIS Annual General Meeting – 2022

Dear QGIS Community,

We recently held our 2022 QGIS Annual General Meeting. The minutes of this meeting are available for all to view.

I would like to welcome our new QGIS PSC member: Régis Haubourg. Régis has been a geomatics enthusiast for years and started deploying and funding QGIS development in 2008 as a GIS and database administrator for a water basin agency.

From 2016 to 2021, he worked for Oslandia mainly on QGIS, learned “the developer’s” side of things and could professionally collaborate with other great contributors to the project. Régis has been promoting the QGIS in the french User group, organizing 4 QGIS french user days, and being the local chapter chair for 2 years. Since 2022, he has worked for a scientific institute promoting greener construction and retrofitting methods to fight against climate change. Welcome! We’re very excited to start working with you!

I’d like to take a moment to deeply thank Paolo Cavallini for all his work in QGIS and in the QGIS PSC.

Paolo got involved in QGIS very long ago, first as a user, then more and more deeply in various activities, initiating and supporting various plugins and core functions (e.g. GDAL Tools, DB Manager), opening and managing bugs, taking care of GRASS modules, handling the trademark registration, etc. Paolo also acted as Finance and Marketing Advisor for several years before taking over the plugin approval process.

Between 2018 and 2020 Paolo served as PSC chair helping QGIS rapidly evolve into a more and more professional project. In 2020 Paolo was reelected as a member of the QGIS PSC where he has been helping in different roles.

Looking up the source code in GIT, I see that your first commit back in May 2011 was the translation of the words: Avvio, Scegli and Arrivo (Begin, Choose, Stop). I really hope that your next commit will be the translation of “Ri-Avvio” since I’m sure you still have a lot to give to QGIS as a community member!

Grazie di cuore!

I will continue to serve on the PSC as chair, and Anita Graser will take over the role of Vice-Chair. The board is completed by our longstanding treasurer Andreas Neumann.

I am also pleased to say that the project governance is in good hands with Jürgen Fischer and Alessandro Pasotti kindly making themselves available to serve on the PSC for another two years.

It is also great to know that our project founder, Gary Sherman, and long-term PSC member Tim Sutton continue to serve on the PSC as honorary PSC members. They both set the standard for our great project culture, and it is great to have his continued presence.

QGIS has been growing from strength to strength, backed by a really amazing community of kind and collaborative users, developers, contributors and funders. I look forward to seeing how it continues to grow and flourish.

Rock on QGIS!

Cheers

Marco Bernasocchi (QGIS.ORG Chair)

Visualizing IOT time series with QGIS & MobilityDB

Today’s post presents an experiment in modelling a common scenario in many IOT setups: time series of measurements at stationary sensors. The key idea I want to explore is to use MobilityDB’s temporal data types, in particular the tfloat_inst and tfloat_seq for instances and sequences of temporal float values, respectively.

For info on how to set up MobilityDB, please check my previous post.

Setting up our DB tables

As a toy example, let’s create two IOT devices (in table iot_devices) with three measurements each (in table iot_measurements) and join them to create the tfloat_seq (in table iot_joined):

CREATE TABLE iot_devices (
    id integer,
    geom geometry(Point, 4326)
);

INSERT INTO iot_devices (id, geom) VALUES
(1, ST_SetSRID(ST_MakePoint(1,1), 4326)),
(2, ST_SetSRID(ST_MakePoint(2,3), 4326));

CREATE TABLE iot_measurements (
    device_id integer,
    t timestamp,
    measurement float
);

INSERT INTO iot_measurements (device_id, t, measurement) VALUES
(1, '2022-10-01 12:00:00', 5.0),
(1, '2022-10-01 12:01:00', 6.0),
(1, '2022-10-01 12:02:00', 10.0),
(2, '2022-10-01 12:00:00', 9.0),
(2, '2022-10-01 12:01:00', 6.0),
(2, '2022-10-01 12:02:00', 1.5);

CREATE TABLE iot_joined AS
SELECT 
    dev.id, 
    dev.geom, 
    tfloat_seq(array_agg(
        tfloat_inst(m.measurement, m.t) ORDER BY t
    )) measurements
FROM iot_devices dev 
JOIN iot_measurements m
  ON dev.id = m.device_id
GROUP BY dev.id, dev.geom;

We can load the resulting layer in QGIS but QGIS won’t be happy about the measurements column because it does not recognize its data type:

Query layer with valueAtTimestamp

Instead, what we can do is create a query layer that fetches the measurement value at a specific timestamp:

SELECT id, geom, 
    valueAtTimestamp(measurements, '2022-10-01 12:02:00') 
FROM iot_joined

Which gives us a layer that QGIS is happy with:

Time for TemporalController

Now the tricky question is: how can we wire our query layer to the Temporal Controller so that we can control the timestamp and animate the layer?

I don’t have a GUI solution yet but here’s a way to do it with PyQGIS: whenever the Temporal Controller signal updateTemporalRange is emitted, our update_query_layer function gets the current time frame start time and replaces the datetime in the query layer’s data source with the current time:

l = iface.activeLayer()
tc = iface.mapCanvas().temporalController()

def update_query_layer():
    tct = tc.dateTimeRangeForFrameNumber(tc.currentFrameNumber()).begin().toPyDateTime()
    s = l.source()
    new = re.sub(r"(\d{4})-(\d{2})-(\d{2}) (\d{2}):(\d{2}):(\d{2})", str(tct), s)
    l.setDataSource(new, l.sourceName(), l.dataProvider().name())

tc.updateTemporalRange.connect(update_query_layer)

Future experiments will have to show how this approach performs on lager datasets but it’s exciting to see how MobilityDB’s temporal types may be visualized in QGIS without having to create tables/views that join a geometry to each and every individual measurement.

Detecting close encounters using MobilityDB 1.0

It’s been a while since we last talked about MobilityDB in 2019 and 2020. Since then, the project has come a long way. It joined OSGeo as a community project and formed a first PSC, including the project founders Mahmoud Sakr and Esteban Zimányi as well as Vicky Vergara (of pgRouting fame) and yours truly.

This post is a quick teaser tutorial from zero to computing closest points of approach (CPAs) between trajectories using MobilityDB.

Setting up MobilityDB with Docker

The easiest way to get started with MobilityDB is to use the ready-made Docker container provided by the project. I’m using Docker and WSL (Windows Subsystem Linux on Windows 10) here. Installing WLS/Docker is out of scope of this post. Please refer to the official documentation for your operating system.

Once Docker is ready, we can pull the official container and fire it up:

docker pull mobilitydb/mobilitydb
docker volume create mobilitydb_data
docker run --name "mobilitydb" -d -p 25432:5432 -v mobilitydb_data:/var/lib/postgresql mobilitydb/mobilitydb
psql -h localhost -p 25432 -d mobilitydb -U docker

Currently, the container provides PostGIS 3.2 and MobilityDB 1.0:

Loading movement data into MobilityDB

Once the container is running, we can already connect to it from QGIS. This is my preferred way to load data into MobilityDB because we can simply drag-and-drop any timestamped point layer into the database:

For this post, I’m using an AIS data sample in the region of Gothenburg, Sweden.

After loading this data into a new table called ais, it is necessary to remove duplicate and convert timestamps:

CREATE TABLE AISInputFiltered AS
SELECT DISTINCT ON("MMSI","Timestamp") *
FROM ais;

ALTER TABLE AISInputFiltered ADD COLUMN t timestamp;
UPDATE AISInputFiltered SET t = "Timestamp"::timestamp;

Afterwards, we can create the MobilityDB trajectories:

CREATE TABLE Ships AS
SELECT "MMSI" mmsi,
tgeompoint_seq(array_agg(tgeompoint_inst(Geom, t) ORDER BY t)) AS Trip,
tfloat_seq(array_agg(tfloat_inst("SOG", t) ORDER BY t) FILTER (WHERE "SOG" IS NOT NULL) ) AS SOG,
tfloat_seq(array_agg(tfloat_inst("COG", t) ORDER BY t) FILTER (WHERE "COG" IS NOT NULL) ) AS COG
FROM AISInputFiltered
GROUP BY "MMSI";

ALTER TABLE Ships ADD COLUMN Traj geometry;
UPDATE Ships SET Traj = trajectory(Trip);

Once this is done, we can load the resulting Ships layer and the trajectories will be loaded as lines:

Computing closest points of approach

To compute the closest point of approach between two moving objects, MobilityDB provides a shortestLine function. To be correct, this function computes the line connecting the nearest approach point between the two tgeompoint_seq. In addition, we can use the time-weighted average function twavg to compute representative average movement speeds and eliminate stationary or very slowly moving objects:

SELECT S1.MMSI mmsi1, S2.MMSI mmsi2, 
       shortestLine(S1.trip, S2.trip) Approach,
       ST_Length(shortestLine(S1.trip, S2.trip)) distance
FROM Ships S1, Ships S2
WHERE S1.MMSI > S2.MMSI AND
twavg(S1.SOG) > 1 AND twavg(S2.SOG) > 1 AND
dwithin(S1.trip, S2.trip, 0.003)

In the QGIS Browser panel, we can right-click the MobilityDB connection to bring up an SQL input using Execute SQL:

The resulting query layer shows where moving objects get close to each other:

To better see what’s going on, we’ll look at individual CPAs:

Having a closer look with the Temporal Controller

Since our filtered AIS layer has proper timestamps, we can animate it using the Temporal Controller. This enables us to replay the movement and see what was going on in a certain time frame.

I let the animation run and stopped it once I spotted a close encounter. Looking at the AIS points and the shortest line, we can see that MobilityDB computed the CPAs along the trajectories:

A more targeted way to investigate a specific CPA is to use the Temporal Controllers’ fixed temporal range mode to jump to a specific time frame. This is helpful if we already know the time frame we are interested in. For the CPA use case, this means that we can look up the timestamp of a nearby AIS position and set up the Temporal Controller accordingly:

More

I hope you enjoyed this quick dive into MobilityDB. For more details, including talks by the project founders, check out the project website.


This post is part of a series. Read more about movement data in GIS.

Plugin Update September 2022

The QGIS plugin repository currently lists 1710 plugins and the list keeps on growing. September has been busy with 16 new plugins. It can be challenging to stay up to date.

Our monthly plugin update is meant to provide you a quick overview of the newest plugins. If any of the names or short descriptions piques your interest, you can find the direct link to the plugin page in the table below the screenshot.

Site Schedule Optimization
Finds an optimal multi-day schedule for traveling to a set of locations.
Sentinel-5p data explorer
Sentinel-5p data explorer manage NC files from satellite “Sentinel-5p”.
CityTimer
Evaluate the distance from the 15min city of a context
Drone Path
This plugin prepares a drone flight path based on input polygon and drone camera parameters. This plugin gives a Fly Litchi compatible csv file with way points for the drone path.
Previsioni
This plugin connect to Previsioni API.
BecaGIS
BecaGIS GeoProcessing, Field Calculation Tools and Expressions
SenseRemote Detection
AI detection algorithms for remote sensing images.
Geotuileur
Plugin associated with the IGN France service of the same name: Geotuileur.
Groundwater Buffer Raster
Expands and interpolates edge values of Water Surface Elevation (WSE) rasters to produce groundwater (GW) buffer rasters
KoALA_Nx
KoALA-Nx supports optimal network analysis in various network environments. Users can apply the tool in all network environments, such as roads, railroads, and pedestrians. KoALA-Nx provides two functions: distance-based network analysis and time-based network analysis
Data Range Filter Legend Widget
Filter layer elements from the legend, using sliders that cover the range of each numeric field.
CO2_Sequestration
This plugin predicts the tree CO2 Sequestration by simply knowing the tree Diameter at Breast Height (DBH) and height of the tree.
PEC_Avalia
Realiza a avaliação da acurácia posicional em produtos e dados cartográficos, a partir de normas e padrões brasileiros
SecQuery
Render geodesic buffers with 4-32 sectors and query the point data in them.
Nearest with greater value
Get name (or ID) of and distance to the nearest feature with greater value in a certain field of a point layer. Returns point layer with added attributes and a line layer with connecting lines.
ODKConnector
Plugin to connect to the ODK (Open Data Kit) for data retrieval.

2.3.5 - Diversified Dugong

Changes

What's Changed

  • Update ios appstore certificates

Full Changelog: v2.3.4...v2.3.5

Crowdfunding: Point cloud processing in QGIS and 3D data enhancements

We are pleased to announce a new crowdfunding campaign to introduce point cloud processing to QGIS! Similar to the previous crowdfunding campaigns, we have teamed up with North Road and Hobu.

Point cloud data and raster shading in QGIS

Point cloud data and raster shading in QGIS.

In the last couple of years, we added point cloud data to QGIS, developed profile tool, improved 3D map navigation and many more features related to 3D data.

The new processing tools will allow you to create terrain/contours from your point cloud data, handle and manage large datasets and several other processing algorithms. In addition, we intend to allow you to embed profiles in your print layouts, export to other formats (e.g. DXF, CSV) and more improvements to the elevation profile tool. For more details see the crowdfunding page.

To pledge to this crowdfunding campaign, simply fill in the form. We will start the work as soon as the target fund is raised.

2.3.3 - Diversified Dugong

Changes

Usability Improvements

  • Implement basic iOS local files / project support (#3325)
  • Give a hint that the projects list is empty or being refreshed (#3293)

🐛 Bug Fixes

  • Fetch public projects with a separate request to speed up users' cloud project list on login (#3303)
  • Important fix to authentication manager to restore handling of 2 factor authentication (et cie) configuration (#3313)
  • Fix crash when the layer is invalid (#3304)
  • Fix dashboard buttons glitch on iOS (#3321)

Full Changelog: v2.3.2...v2.3.3

2.3.4 - Diversified Dugong

Changes

🐛 Bug Fixes

  • Fix regression on some older devices whereas the side dashboard and the search bar buttons were mislocated outside of the screen

Securely accessing ArcGIS Online (AGOL) and enterprise ArcGIS Portal sites through QGIS (2022 update!)

We’re often contacted for advice regarding our recommendations for securely accessing content on ArcGIS Online (AGOL) or enterprise ArcGIS Portal deployments from within QGIS. While we ran through our recommended setup in an older post, we thought it was time for a 2022 update for our recommendations. In this version we’ve updated some of the descriptions and screenshots for newer QGIS releases, and have added explicit instructions on accessing ArcGIS Online content too.

This post details step-by-step instructions in setting up both AGOL/ArcGIS Portal and QGIS to enable this integration. First, we’ll need to create an application on the server in order to enable QGIS users to securely authenticate with the server. The process for this varies between AGOL and ArcGIS Portal, so we’ve separated the guidelines into two sections below:

ArcGIS Portal

Creating an application

Logon to the Portal, and from the “Content” tab, click the “Add Item” option. Select “An application” from the drop down list of options:

Set the type of the application as “Desktop

You can fill out the rest of this dialog as you see fit. Suggested values are:

  • Purpose: Ready to Use
  • Platform: Qt
  • URL: https://qgis.org
  • Tags: QGIS, Desktop, etc

Now – here comes a trick. Portal will force you to attach a file for the application. It doesn’t matter what you attach here, so long as it’s a zip file. While you could attach a zipped copy of the QGIS installer, that’s rather wasteful of server space! We’d generally just opt for a zip file containing a text file with a download link in it.

Click Add Item when you’re all done filling out the form, and the new application should be created on the Portal.

Registering the Application

The next step is to register the application on Portal, so that you can obtain the keys required for the OAuth2 logon using it. From the newly created item’s page, click on the “Settings” tab:

Scroll right to the bottom of this page, and you should see a “Register” button. Press this. Set the “App type” to “Native“.

Add two redirect URIs to the list (don’t forget to click “Add” after entering each!):

  1. The Portal’s public address, e.g. https://mydomain.com/portal
  2. http://127.0.0.1:7070

Finally, press the “Register” button in the dialog. If all goes well then the App Registration section in the item settings should now be populated with details. From here, copy the “App ID” and “Secret” strings, we’ll need these later:

Determine Request URLs

One last configuration setting we’ll need to determine before we fire up QGIS is the Portal’s OAuth Request and Token URLs. These are usually found by appending /sharing/rest/oauth2/authorize and /sharing/rest/oauth2/token to the end of your Portal’s URL.

For instance, if your public Portal URL is http://mydomain.com/portal, then the URLs will be:

Request URL: http://mydomain.com/portal/sharing/rest/oauth2/authorize
Token URL: http://mydomain.com/portal/sharing/rest/oauth2/token

You should be able to open both URLs directly in a browser. The Request URL will likely give a “redirect URL not specified” error, and the Token URL will give a “client_id not specified” error. That’s ok — it’s enough to verify that the URLs are correct.

When this is all done we can skip ahead to the client-side configuration below.

ArcGIS Online (AGOL)

Registering an application on AGOL must be done by an account administrator. So first, we’ll logon to AGOL using an appropriate account, and then head over to the “Content” tab. We’ll then hit the “New Item” button to start creating our application:

From the available item types select the “Application” option:

We’ll then select the “Mobile” application type, and enter “https://qgis.org” as the application URL (it actually doesn’t matter what we enter here!):

Lastly, we can enter a title for the application and complete all the metadata options as desired, then hit the “Save” button to create the application. AGOL should then take us over to the applications content page (if not, just open that page manually). From the application summary page, click across to the “Settings” tab:

Scroll right down to the “Credentials” section at the bottom of this page and click the “Register application” button:

Enter the following “Redirect URLs”, by copying each value and then hitting “Add”

  • localhost
  • http://127.0.0.1:7070
  • https://127.0.0.1:7070

Set the “Application environment” to Browser and then click “Register” button to continue:

You’ll be taken back to the application Settings page, but should now see an Client ID value and option to show the Client Secret. Copy the “Client ID” and “Client Secret” (there’s a “copy to clipboard” button for this) as we’ll need these later:

We’re all done on the AGOL side now, so it’s time to fire up QGIS!

Creating an QGIS OAuth2 Authentication Configuration

From your QGIS application, select Options from the Settings menu. Select the Authentication tab. We need to create a new authentication configuration, so press the green + button on the right hand side of the dialog. You’ll get a new dialog prompting you for Authentication details.

You may be asked to create a “Master Password” when you first create an authentication setup. If so, create a secure password there before continuing.

There’s a few tricks to this setup. Firstly, it’s important to ensure that you use the exact same settings on all your client machines. This includes the authentication ID field, which defaults to an auto-generated random string. (While it’s possible to automatically deploy the configuration as part of a startup or QGIS setup script, we won’t be covering that here!).

So, from the top of the dialog, we’ll fill in the “Name” field with a descriptive name of the Portal site. You then need to “unlock” the “Id” field by clicking the little padlock icon, and then you’ll be able to enter a standard ID to identify the Portal. The Id field is very strict, and will only accept a 7 letter string! Since you’ll need to create a different authentication setup for each individual ArcGIS Portal site you access, make sure you choose your ID string accordingly. (If you’re an AGOL user, then you’ll only need to create one authentication setup which will work for any AGOL account you want to access).

Drop down the Authentication Type combo box, and select “OAuth2 Authentication” from the list of options. There’s lots of settings we need to fill in here, but here’s what you’ll need:

  • Grant flow: set to “Authorization Code”
  • Request URL: 
    • For ArcGIS Portal services: enter the Request URL we determined in the previous step, e.g. http://mydomain.com/portal/sharing/rest/oauth2/authorize
    • For AGOL services: enter https://www.arcgis.com/sharing/rest/oauth2/authorize
  • Token URL:
    • For ArcGIS Portal services: enter the Token URL from the previous step, e.g. http://mydomain.com/portal/sharing/rest/oauth2/token
    • For AGOL services: enter https://www.arcgis.com/sharing/rest/oauth2/token
  • Refresh Token URL: leave empty
  • Redirect URL: leave as the default http://127.0.0.1:7070 value
  • Client ID: enter the App ID (or Client ID) from the App Registration information (see earlier steps)
  • Client Secret: enter the App Secret (or Client Secret) from the App Registration information (see earlier steps)
  • Scope: leave empty
  • API Key: leave empty
  • For AGOL services only: you’ll also need to set the “Token header” option under the “Advanced” heading. This needs to be “X-Esri-Authorization” (without the quotes!)

That’s it — leave all the rest of the settings at their default values, and click Save.

You can close down the Options dialog now.

Adding the Connection Details

Lastly, we’ll need to setup the server connection as an “ArcGIS Rest Server Connection” in QGIS. This is done through the QGIS “Data Source Manager” dialog, accessed through the Layer menu. Click the “ArcGIS REST Server” tab to start with, and then press “New” in the Server Connections group at the top of this dialog.

Enter a descriptive name for the connection, and then enter the connection URLs. These will vary depending on whether you’re connecting to AGOL or an ArcGIS Portal server:

ArcGIS Online Connection

  • URL: This will be something similar to “https://services###.arcgis.com/########/arcgis/rest/services/”, but will vary organisation by organisation. You can determine your organisation’s URL by visiting the overview page for any dataset published on your AGOL account, and looking under the “Details” sidebar. Copy the address from the “Source: Feature Service” link and it will contain the correct URL parameters for your organisation. (Just make sure you truncate the link to end after the “arcgis/rest/services” part, you don’t require the full service endpoint URL)
  • Community endpoint URL: https://www.arcgis.com/sharing/rest/community
  • Content endpoint URL: https://www.arcgis.com/sharing/rest/content

ArcGIS Portal Connection

  • URL:  the REST endpoint associated with your Portal, e.g. “https://mydomain.com/arcgis/rest/services”
  • Community endpoint URL (optional): This will vary depending on the server setup, but will generally take the form “https://mydomain.com/portal/sharing/rest/community”
  • Content endpoint URL (optional): This will vary depending on the server setup, but will generally take the form “https://mydomain.com/portal/sharing/rest/content”

Lastly, select the new OAuth2 configuration you just created under the “Authentication” group:

Click OK, and you’re done! When you try to connect to the newly added connection, you’ll automatically be taken to the AGOL or ArcGIS Portal’s logon screen in order to authenticate with the service. After entering your details, you’ll then be connected securely to the server and will have access to all items which are shared with your user account!

We’ve regularly use this setup for our enterprise clients, and have found it to work flawlessly in recent QGIS versions. If you’ve found this useful and are interested in other “best-practice” recommendations for mixed Open-Source and ESRI workplaces, don’t hesitate to contact us to discuss your requirements… at North Road we specialise in ensuring flawless integration between ESRI based systems and the Open Source geospatial software stack.

2.3.0 - Diversified Dugong

Changes

🚀 Features

  • QR code reader functionality (#3104, #3142)
  • Position tracking on point layers (#3247)
  • Layer properties action to show list of features visible on the current map extent (#3213)
  • Symbol-level show features list action (#3261)
  • Remember individual layers visibility and styling (opacity, labels visibility) across QField sessions (#3237)
  • Setting to adjust screen dimmer timeout (#3265)
  • QField Android & iOS now draws under the device’s top status bar (#3188)

Usability Improvements

  • Layer properties popup reorganizing (#3249)
  • Topology editing toggle now visible when a point layer is active (#3273)
  • The measuring tool now respects projects' distance and area units type (#3276)
  • Further improvements to the stakeout/precise view panel (#3244)
  • A pair of copy / paste actions for text attributes when the form is in editing mode (#3142)
  • Significant iOS-specific improvements
  • Windows specific improvements

🐛 Bug Fixes

  • Fix crash when entering geometry editing mode of a point layer (#3273)
  • Fix hidden legend symbols identified when tapping on the map (#3262)
  • Tons of stability improvements

2.3.1 - Diversified Dugong

Changes

🐛 Bug Fixes

  • Fix a very unpleasant crash on Windows and iOS

2.3.2 - Diversified Dugong

Changes

🐛 Bug Fixes

  • Group cloud projects by owner (#3292)
  • Fix delta generation on NULL and 0 (#3280)
  • Fix WMS and WMTS reprojection issues (#3294)
  • Allow all types of image to by selected on Android's gallery (#3287)

Mixed Format Labels in QGIS — coming soon!

For the QGIS 3.28 release North Road had the exciting opportunity to add some much desired new functionality to QGIS: the ability to mix font formatting and styles within a single map label! This enhancement was funded by the Swiss QGIS User Group, and offers a whole range of new cartographic possibilities for all QGIS users. Read on for more details on how this can impact your mapping…

QGIS has long supported the ability to combine different values inside a label for a feature, via the use of custom QGIS expressions. For example, the map below labels features from a rail station layer with the expression

"NAME" || '\n' || "PATRONAGE"

This expression concatenates the field values inside the “NAME” field with their “PATRONAGE” values, using a new line character to separate the two values. The end result looks something like this:

While custom expressions are extremely flexible and offer an almost unlimited range of possibilities to tweak label content, the limitation has been that all of this label text will always be displayed using a single font, font size, and font style. For example, there was no capacity to show the station names in a larger, bold font, and the patronage values in a smaller size.

That’s all changing thanks to the funding from the QGIS Swiss User Group! Now, in QGIS 3.28, users can combine label text with HTML formatting tags in order to customise exactly how each individual word or character in the label is drawn. Let’s revisit the map shown above and flex these new cartographic muscles…

The first thing we need to do is enable the HTML formatting tags for our labels by checking the “Allow HTML formatting” option in the text properties:

With this option enabled, we can now use a range of HTML and CSS tags to format individual parts of our label. For instance, “<b>bold text</b>” will show the text between the <b> and </b> tags in a bold font. By revising our previous labelling expression we can now get the station names to render in a bold font. Here’s the revised expression:

'<b>' || "NAME" || '</b><p>' || "PATRONAGE"

There’s one other important change we’ve made in the above expression. When using HTML formatting for labels, we need to replace the ‘\n’ newline character with the HTML new paragraph tag “<p>”. Otherwise, our expression is very similar to the previous one, with the exception that we’re wrapping the “NAME” field in <b>…</b> tags.

Here’s how it looks:

That’s already a dramatic improvement in the readability of the map! Let’s try refining it further by dropping down the font size of the patronage values. We can do that by inserting some CSS into the label string, specifically the “font-size” property. Here’s our new expression:

'<b>' || "NAME" || '</b><p><span style="font-size: 10pt">' || "PATRONAGE" || '</span>'

It’s so beautiful now! (Go on, scroll back up to our original map, we dare you to compare!).

So which HTML/CSS formatting options are supported? For QGIS 3.28, these options are:

  • Font family, via the CSS font-family tag. E.g. <span style=”font-family: Comic Sans MS”>…</span>
  • Font size, via the CSS font-size tag. E.g. <span style=”font-size: 30pt”>…</span>
  • Font weights, via the HTML <b> tag or CSS font-weight tag
  • Italic, via the HTML <i> tag or CSS “font-style: italic”
  • Font color, via the CSS “color: #rrggbb” tag
  • Underline, via the HTML <u> tag or CSS “text-decoration: underline” tag
  • Strikethrough, via the HTML <s> tag or CSS “text-decoration: line-through” tag
  • Overline, via the CSS “text-decoration: overline” tag

Oh, one last thing we nearly forgot to mention: all these wonderful styling options also apply perfectly to curved label text!

Our thanks go out to the members of the Swiss QGIS User Group for funding this feature! It’s an exciting addition to QGIS and can offer new ways to dramatically improve your mapping creations.

Got any QGIS needs you’d like to discuss? Or want to see additional formatting options added in a future QGIS release? Just contact our friendly team to discuss your needs — we’d love to assist!

QGIS out in the fields…

Wednesday the 28th of September, we’re organizing a thematic day on the field use of QGIS. It’s being hosted by VRBZO (the Fire Department in the Eindhoven region). Theme is the use of QIS in the filed, (mostly) using QField or MerginMaps. Want to join us (language will be mostly Dutch)? Tickets (free for members) […]

24th Contributors QGIS Meeting in Firenze 2022

The international community of QGIS contributors got together in person from 18 to 22 August in parallel to OpenStreetMap State of The Map event and right before the FOSS4G. So there was a lot of open source geo power concentrated in the beautiful city of Florence in those days. It was my first participation and all I knew was that it’s supposed to be an unconference. This means, there is no strict schedule but space and opportunity for everyone to present their work or team up to discuss and hack on specific tasks to bring the QGIS project to the next level.

Introduction and first discussions

We were a group of six OPENGIS.ch members arriving mostly on Thursday, spending the day shopping and moving into our city apartment. In the evening we went to a Bisteccheria to eat the famous Fiorentina steak. It was big and delicious as was the food in general. Though, I am eating vegetarian since to compensate. On Friday we went to the Campus to meet the other contributors. After a warm welcome by the organizer, Rossella and our CEO and QGIS chair Marco Bernasocchi we did an introduction round where everyone mentioned their first QGIS version ever used. At this point, I became aware of the knowledge and experience I was sharing the room with. Besides this, I noticed that there was another company attending with several members, namely Tim Sutton’s Kartoza, which is also contributing a lot to QGIS. The first discussion was about QGIS funding model, vision, communication and on the new website in planning. This discussion then moved into some smaller groups including most of the long term contributors. I was looking around, physically and virtually, and tried to process all the new inputs and to better understand the whole QGIS world. Besides, I noticed my colleague Ivan having problems with compiling QGIS after upgrading to Ubuntu 22.04 which then motivated my other colleague Clemens to implement a docker container to do the compilation. Nevertheless, I postponed my Ubuntu upgrade. That evening we went out all together to have a beer or two and play some pool sessions and table football. Finally, the OPENGIS.ch crew navigated back home pairing a high-precision GNSS sensor with a mobile device running OpenStreetMap in QField. We arrived back home safely and super precise.

First tasks and coffee breaks

There was catering in the main hall covering breakfast, lunch and coffee breaks. It never took long after grabbing a cup of coffee to find yourself in a conversation with either fellow contributors or OpenStreetMap folks. I chatted with a mapper from Japan about mobile apps, an engineer from Colombia about travelling and a freelancer from the Netherlands about GDAL, to name 3 coffees out of many.

QGIS plugins website

After some coffee, Matthias Kuhn, our CTO and high-ranking QGIS contributor, asked me whether I could improve some ugly parts of QGIS plugins website. So I had my first task which I started working on immediately. The task was to make the site more useful on mobile devices which would be achieved by collapsing some unimportant information and even removing other parts. I noticed some quirks in the development workflow, so I also added some pre-commit hooks to the dev setup. Dimas Ciputra from Kartoza helped me finalize the improvements and merge them into master branch on github.

QGIS website downloads section

Regis Haubourg asked to help simplify the QGIS Downloads for Windows section on the main QGIS website. We played around in the browser dev tools until we thought the section looked about right. I then checked out the github repo and started implementing the changes. I need to say the tech stack is not quite easy to develop with currently, but there is a complete rework in planning. Anyway, following the pull request on github a lively discussion started which is ongoing by the time of writing. And this is a good thing and shows how much thought goes into this project.

Presentations

There were many interesting and sometimes spontaneous presentations which always involved lively discussions. Amy Burness from Kartoza presented new styling capabilities for QGIS, Tobias Schmetzer from the Bavarian Center for Applied Energy Research presented the geo data processing and pointed out issues he encountered using QGIS on this and Etienne Trimaille from 3liz talked about qgis-plugins-ci, just to name a few.

Amazing community

On Saturday evening a bus showed up at the campus and took us on a trip up to the hills. After quite a long ride we arrived at a restaurant high up with mind-blowing view of the city. I forgot how many rounds of Tuscan food were served, but it was delicious throughout. An amazing evening with fruitful conversations and many laughs.

The weather was nice and hot, the beers cold, the Tuscan food delicious and the contributors were not only popular Github avatars but really nice people. Thank you QGIS.

Plugin Update August 2022

The QGIS plugin repository currently lists 1694 plugins and the list keeps on growing, even during the holiday season. It can be challenging to stay up to date.

Our new monthly plugin update is meant to provide you a quick overview of the newest plugins. If any of the names or short descriptions piques your interest, you can find the direct link to the plugin page in the table below the screenshot.

STL Generator
This plugin lets you generate an STL from a DEM and allows the exclusion of nodata regions.
Maxent Model
Maxent mapping adapter for QGIS. Adaptador de cartografía Maxent para QGIS
SRApp
Synchronizacja z bazą danych aplikacji Metryka
QGIS Redistricting
Tool for drawing districting plans from geographic units
XPlan-Reader
Import XPlan-GML
GEO_search
Layer Geo Search
Check, Define & Convert CRS
Check, define and convert CRS
Dynamic Provider Filter Plugin
QGIS plugin to dynamically set provider filters using QGIS variable replacement.
TopoTijdreis
This plugin loads all historic maps from 1815-2020 from topotijdreis.nl into QGIS
Tanaka Contours
Generates Tanaka-contours from a DEM

FOSS4G 2022 Florence

FOSS4G is the annual global event of free and open source geographic technologies and open geospatial data hosted by OSGeo. In 2022 it took place in Firenze with over 1300 participants, 402 talks and 44 workshops.

Forget label buffers! Better maps with selective label masks in QGIS

Cartographers use all kind of tricks to make their maps look deceptively simple. Yet, anyone who has ever tried to reproduce a cartographer’s design using only automatic GIS styling and labeling knows that the devil is in the details.

This post was motivated by Mika Hall’s retro map style.

There are a lot of things going on in this design but I want to draw your attention to the labels – and particularly their background:

Detail of Mike’s map (c) Mike Hall. You can see that the rail lines stop right before they would touch the A in Valencia (or any other letters in the surrounding labels).

This kind of effect cannot be achieved by good old label buffers because no matter which color we choose for the buffer, there will always be cases when the chosen color is not ideal, for example, when some labels are on land and some over water:

Ordinary label buffers are not always ideal.

Label masks to the rescue!

Selective label masks enable more advanced designs.

Here’s how it’s done:

Selective masking has actually been around since QGIS 3.12. There are two things we need to take care of when setting up label masks:

1. First we need to enable masks in the label settings for all labels we want to mask (for example the city labels). The mask tab is conveniently located right next to the label buffer tab:

2. Then we can go to the layers we want to apply the masks to (for example the railroads layer). Here we can configure which symbol layers should be affected by which mask:

Note: The order of steps is important here since the “Mask sources” list will be empty as long as we don’t have any label masks enabled and there is currently no help text explaining this fact.

I’m also using label masks to keep the inside of the large city markers (the ones with a star inside a circle) clear of visual clutter. In short, I’m putting a circle-shaped character, such as ◍, over the city location:

In the text tab, we can specify our one-character label and – later on – set the label opacity to zero.
To ensure that the label stays in place, pick the center placement in “Offset from Point” mode.

Once we are happy with the size and placement of this label, we can then reduce the label’s opacity to 0, enable masks, and configure the railroads layer to use this mask.

As a general rule of thumb, it makes sense to apply the masks to dark background features such as the railways, rivers, and lake outlines in our map design:

Resulting map with label masks applied to multiple labels including city and marine area labels masking out railway lines and ferry connections as well as rivers and lake outlines.

If you have never used label masks before, I strongly encourage you to give them a try next time you work on a map for public consumption because they provide this little extra touch that is often missing from GIS maps.

Happy QGISing! Make maps not war.

  • <<
  • Page 16 of 141 ( 2808 posts )
  • >>

Back to Top

Sustaining Members