Bug report #21101

Legend content issue when using atlas and themes

Added by Alexis Roy-L about 5 years ago. Updated about 5 years ago.

Status:Open
Priority:Normal
Assignee:-
Category:Map Legend
Affected QGIS version:3.4.4 Regression?:No
Operating System:Windows 10 Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:28919

Description

Greetings,

Here is the behavior I noticed:

When using themes and an atlas to generate automatically maps, the current selected sub item in the map will be used rather than the setting of the theme.

IE: If I have a layer with 7 classes and I want one of them to be displayed for 2 themes and all the classes for 1 other theme.

The legend will display the classes that are currently activated in the map regardless of what is displayed by the theme on the canvas.

This mean that I must set my map to match the theme of the canvas in order to display the proper categories in the legend, otherwise only one, none or all the classes for a given layer will be displayed depending on the current map theme and regardless of the canvas theme.

Thanks and have a nice day!

History

#1 Updated by Alexis Roy-L about 5 years ago

This is not an issue with the auto-update activated. But the auto-update displays too much information(basemap, etc.), which makes it more annoying to use.

#2 Updated by Giovanni Manghi about 5 years ago

  • Status changed from Open to Feedback

Please always test with the latest version available, now is 3.4.4. Thanks.

#3 Updated by Alexis Roy-L about 5 years ago

Giovanni Manghi wrote:

Please always test with the latest version available, now is 3.4.4. Thanks.

Bug is still present in 3.4.4

Here is how to replicate it:

1 Make a layer with categories.
2 save themes with some categories disabled
3 Make a file with the name of the theme in a field to act as the atlas
4 in the layout deactivate auto update and add the layer to the atlas, set the legend to filter visible elements
5 use the atlas field to set the canvas map theme and activate the theme option.
6 cycle through the atlas.

You will see that only the map preset will be used to determine which layer categories will be displayed in the legend.

#4 Updated by Giovanni Manghi about 5 years ago

  • Affected QGIS version changed from 3.4.0 to 3.4.4
  • Status changed from Feedback to Open

Also available in: Atom PDF