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.65k stars 3.01k forks source link

Render Layers as a Group not working with Themes in Layout #50391

Open baswein opened 2 years ago

baswein commented 2 years ago

What is the bug or the crash?

If you create a group and select the Render Layers as a Group option and then add that group to a Theme it renders fine in both the map view and the layout view. However if in the Layout you select Follow map theme and choose the theme with the Group the layers in the group will not be rendered.

Demo Data:
Mask Below Theme.zip

Steps to reproduce the issue

  1. Create a new map and add a layer.
  2. Add the layer to a group.
  3. In the Group Styling set to Render Layer as a Group
  4. Create a Theme with the group and layer on.
  5. See that the layer is visible
  6. Create a layout and add a map.
  7. See that the layer is visible
  8. Set the Layout Map to Follow Map Theme with the theme set to (none)
  9. See the layer is visible
  10. Set the Theme to the theme you created
  11. See that the layer disappears

Versions

QGIS version | 3.27.0-Master | QGIS code revision | c6eca784ad -- | -- | -- | -- Qt version | 5.15.3 Python version | 3.9.5 Compiled against GDAL/OGR | 3.6.0dev-dc0012850f | Running against GDAL/OGR | 3.6.0dev-f7c95ff1cf PROJ version | 9.1.0 EPSG Registry database version | v10.074 (2022-08-01) GEOS version | 3.10.3-CAPI-1.16.1 SQLite version | 3.38.1 PDAL version | 2.4.3 PostgreSQL client version | unknown SpatiaLite version | 5.0.1 QWT version | 6.1.6 QScintilla2 version | 2.13.1 OS version | Windows 10 Version 2009   |   |   |   This copy of QGIS writes debugging output.   |   |   |   Active Python plugins db_manager | 0.1.20 grassprovider | 2.12.99 MetaSearch | 0.3.6 otbprovider | 2.12.99 processing | 2.12.99 sagaprovider | 2.12.99 QGIS version 3.27.0-Master QGIS code revision [c6eca784ad](https://github.com/qgis/QGIS/commit/c6eca784ad) Qt version 5.15.3 Python version 3.9.5 Compiled against GDAL/OGR 3.6.0dev-dc0012850f Running against GDAL/OGR 3.6.0dev-f7c95ff1cf PROJ version 9.1.0 EPSG Registry database version v10.074 (2022-08-01) GEOS version 3.10.3-CAPI-1.16.1 SQLite version 3.38.1 PDAL version 2.4.3 PostgreSQL client version unknown SpatiaLite version 5.0.1 QWT version 6.1.6 QScintilla2 version 2.13.1 OS version Windows 10 Version 2009 This copy of QGIS writes debugging output. Active Python plugins db_manager 0.1.20 grassprovider 2.12.99 MetaSearch 0.3.6 otbprovider 2.12.99 processing 2.12.99 sagaprovider 2.12.99 ### Supported QGIS version - [X] I'm running a supported QGIS version according to the roadmap. ### New profile - [X] I tried with a new QGIS profile ### Additional context _No response_
DelazJ commented 1 year ago

Confirmed. Quite annoying. A workaround until #51358 is fixed is to just uncheck the "render layers as a group" box and update the layout: the symbology still applies with the map theme and group constraint.