qgis / QGIS

QGIS is a free, open source, cross platform (lin/win/mac) geographical information system (GIS)
https://qgis.org
GNU General Public License v2.0
10.56k stars 3k forks source link

Font of vector tile layer labels changes after closing and reopening project, first appeared in QGIS 3.34.2 #58592

Open SimonHHaas opened 1 month ago

SimonHHaas commented 1 month ago

What is the bug or the crash?

I've encountered an issue where the label (font) appearance of some vector tile layers changes after saving/closing and reopening the project in QGIS. Upon reopening the project, some labels switch to a different font/become bold. This issue first appeared in QGIS version 3.34.2 and has seemingly persisted to the current version.

How the labels should look like (how they look like immediately after adding the layer to the map canvas): before

How the labels look like after saving, closing and reopening the project: after

Vector tile layer used in this example: URL: https://sgx.geodatenzentrum.de/gdz_basemapde_vektor/tiles/v1/bm_web_de_3857/{z}/{x}/{y}.pbf Style URL: https://sgx.geodatenzentrum.de/gdz_basemapde_vektor/styles/bm_web_gry.json

Tested on Windows 11 with the following QGIS versions:

Creating a new user profile did not resolve this bug.

When opening a project containing an affected vector tile layer in an earlier version of QGIS that doesn't have this bug yet (e.g. 3.34.0), the labels return to their normal appearance. Saving the project file with the “broken” layer with the earlier QGIS version does not fix the label appearance of the layer when viewing the project in an affected, more recent version of QGIS. However, with the original project in which I first discovered this issue, the labels don't return to looking like normal when viewed in an earlier QGIS version. I'm not sure why that is yet.

Steps to reproduce the issue

  1. Open QGIS 3.34.2 or later
  2. Add the following vector tile layer in the browser panel and add it to the map canvas: URL: https://sgx.geodatenzentrum.de/gdz_basemapde_vektor/tiles/v1/bm_web_de_3857/{z}/{x}/{y}.pbf Style URL: https://sgx.geodatenzentrum.de/gdz_basemapde_vektor/styles/bm_web_gry.json
  3. Save and close the project, then reopen it
  4. You should then see that the text on some of the labels has turned bold/switched to a different font

Versions

QGIS version 3.34.2-Prizren QGIS code revision 7d199797fc Qt version 5.15.3 Python version 3.9.5 GDAL/OGR version 3.8.2 PROJ version 9.3.1 EPSG Registry database version v10.098 (2023-11-24) GEOS version 3.12.1-CAPI-1.18.1 SQLite version 3.41.1 PDAL version 2.6.0 PostgreSQL client version 15.2 SpatiaLite version 5.1.0 QWT version 6.1.6 QScintilla2 version 2.13.4 OS version Windows 10 Version 2009

Active Python plugins db_manager 0.1.20 grassprovider 2.12.99 MetaSearch 0.3.6 processing 2.12.99

Supported QGIS version

New profile

Additional context

No response

agiudiceandrea commented 1 month ago

I cannot replicate exactly the reported issue. It seems to me QGS 3.34.0 and QGIS 3.34.10 behave the same on my Windows 10 system regarding the appearance of the map containing the provided vector tile layer before and after saving, closing and reopening. I think a possible difference may be also due to different fonts installed in different user profiles . May you check in the user_profile_folder/fonts/ folder?