5

I created a legend with refinement in QGIS print composer. As you can see (picture 1) in the item properties for the legend the items are hierarchical indented.

picture 1 picture 1

But in my map the indentation is not taken from QGIS (see picture 2).

picture 2 picture 2

How can I manage this indentation in the legend?

2
  • How did you get the classified symbol and label to indent in the layer panel (in picture 1)? Commented Dec 30, 2016 at 13:21
  • This could be done within the layer properties (style). I first did a rule based classification using the year and then I refined this classification for 2016 with an additional collumn called project. When I create the legend in the print composer it looks like in picture 1 within the item properties. But it does not take it for the map... Commented Dec 30, 2016 at 13:27

2 Answers 2

5

The answer to "why" is that nobody has implemented a print composer legend that reflects nested rules of a rule-based layer style.

I couldn't find a feature request for this on the QGIS bug tracker with a quick search. For more info on how feature requests are handled, see How to effectively get things changed in QGIS?

4

One option to get that indentation look would be to add three or more legends to the composer. First legend remove all classes after "2015". Add second legend, remove all classes from 2013-2015 and below Saxifraga Project. Then nudge this second legend over to the right to represent the indentation effect. Finally, add in the third legend, remove all classes from Saxifraga Project up and align this legend with the left edge of the first legend. A bit of a hack but this should mock how it shows in the layer panel.

3
  • yes, that could be one way (I already thought about this), but I am wondering why the formatting form item properties is not represented the same way as in my map legend? Shouldn't they do this? Commented Dec 30, 2016 at 13:44
  • I'm not sure about that aspect, maybe someone else can provide those details. Commented Dec 30, 2016 at 14:15
  • This issue was solved at 3.22. gis.stackexchange.com/questions/279707/… Commented Apr 30, 2024 at 3:20

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.