10

I'm working with a QGIS project with a number of layers. When assembling a printout all visible layers are automatically added to the legend:

1st legend

I would like to exercise some control over the legend elements are remove some of the entries:

2nd legend

However, as the entries correspond to the upper levels in the hierarchy, deleting them will remove the keys:

1 - 20000
20000 - 40000
...


I'm working in Qgis 2.8. I'm not interested in modifying my layer structure but only in changing the legend elements.

1 Answer 1

14

Instead of deleting legend items, you could hide them. From the Legend items options window, right-click the name of the layer and select the Hidden option:

Hide layer names

This would hide the names of layers, leaving the values:

Result

Hope this helps!

5
  • Thank you very much, this solves my problem. Can I also ask if there is a convenient way of removing decimal places that are visible in your legend? I use QGIS to classify some of the variables automatically and on a few occasions I had to edit the legend by hand. I would like to automatically determine the number of decimal places generated and visible in the legend.
    – Konrad
    Commented Oct 28, 2015 at 12:34
  • 1
    @Konrad - Most welcome buddy! For the layers I used, they were made using the Graduated style. There's a Precision option which you can edit to increase/decrease the amount of decimal places. The legend should be automatically updated with the new precision...hopefully :)
    – Joseph
    Commented Oct 28, 2015 at 12:42
  • 1
    this is excellent. Thank you very much for the useful advice.
    – Konrad
    Commented Oct 28, 2015 at 12:44
  • @Konrad - My pleasure, hope you get the legend the way you want it to look :)
    – Joseph
    Commented Oct 28, 2015 at 12:46
  • I have found that the layers I don't want to show on the legend are already marked "Hidden". However there is a 'minus sign button' below the list of layers which does the trick
    – djnz0feh
    Commented Dec 13, 2022 at 10:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.