To emphasise one particular polygon area, I have used rule-based styles (QGIS) to apply a 50% transparency white fill to every polygon but the one I am interested in. This polygon layer is above all the others in the stack, with the result that all the mapping outside the emphasised polygon is 'faded out'.

However, any and all labels attached to places and roads are not faded out, even though the text layers in question are underneath the 'fade out' polygon layer.

How can I fix this?

  • Eagerly awaiting the answer to this one. Very strange behavior! I'm able to duplicate this with any kind of overlay. In the meantime, there is an option to only label selected features, perhaps you can integrate that into your process? – L_Holcombe Jan 16 '13 at 10:00
  • Far too many features to select unfortunately... – ElendilTheTall Jan 16 '13 at 11:17

Not straight forward, but possible:

You can clip all your data layers with the polygon using Vector->geoprocessing tools, and choose labelling only for that layer. For feature styling, choose a minimalistic design, or put it downmost in the stack.

A small example with OSM bus stops and admin borders:

enter image description here

  • I will try this – ElendilTheTall Jan 16 '13 at 11:21
  • If you want faded labels as well, intersect a second time for the rest of the data. – AndreJ Jan 16 '13 at 15:41

You can not control the render order of labels. Labels are always rendered last and on top of everything else.

In the latest QGIS dev build you can set the label transparency, however labels will still not render on top as labels have collision detection.

If you still want to make the labels transparent you can set it in the label options:

enter image description here

If you only want to show the labels in the area of interest you could have a field in your points layer with the area name and use a label case statement to just show those labels:

CASE WHEN area = 'name' THEN "LabelColumn" END 
  • The problem with this is that the labels inside the fade out will be affected too. – ElendilTheTall Jan 16 '13 at 11:14
  • Ahh I see what you want to do. See my update – Nathan W Jan 16 '13 at 11:36
  • Where do I input the CASE statement? – ElendilTheTall Jan 16 '13 at 12:01
  • In the label expression box. – Nathan W Jan 16 '13 at 12:09
  • Is that in the dev version only? – ElendilTheTall Jan 16 '13 at 12:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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