New feature in QGIS 3.12 does not seem to work.

And it looks different from shown in changelog https://qgis.org/en/site/forusers/visualchangelog312/#feature-selective-masking


This is how it actually looks like example2

There is "Symbol layers to mask" part missing, with "This mask shape should be then selected as mask source in the Masks properties of a layer in order to enable masking" instead.

So I went to Mask properties, check boxes in Masked symbol layers and in Mask sources. example3

And nothing happened. The label looks exactly the same. So, I oppened up Mask properties again, and found that all check-boxes were unchecked.

What am I doing wrong?

  • 1
    You are probably right. This feature is either not fully available or setting it to use is missing. User documentation of QGIS also does not hint either about selective masking or "Masks" tab below the "Labels" tab. I have checked it on Windows10 64 bit. Which OS are you using? Normally (but not always) open source software developers work on Linux. Maybe the Linux version of QGIS 3.12 has it as described in Changelog. – datakeen Mar 20 at 10:15
  • Windows 10 64 bit. I didn't think that this could be an operating system problem. Thanks. – Bartosz Czarnecki Mar 20 at 13:37
  • I'm finding the same result. It doesn't appear the same as in the changelog and it doesn't seem to work. I'm also using Windows 10, 64 bit. This would be an awesome feature if it worked. – Geezer Apr 13 at 12:12
  • I have the same problem, label masking is not working. Layer "Masks" / "Edit mask settings" is not being saved. Win10 QGIS 3.12.2 – a qgis user Apr 30 at 14:51

I use 3.12.1 (not sure about 3.12.0, if it didn't work in it you should upgrade) and it work but it's not very intuitive.

At first you have to set your label and check the "enable mask" in the "Mask" tab of the label tab (not the mask tab of the layer styling tab)

enter image description here

After that you could go to the layer styling of the layer you want to mask (it could be the same as your label layer if you want to mask the feature being labelled or any other layer) and choose the mask tab, you should see at the top the different symbol layer of the active layer (note that if you want to mask a polygon border you need to have two layer, one for border and one for fill) here you check what part of the symbology you want to mask. At the bottom you have the mask source ie. the label to use as mask.

enter image description here

| improve this answer | |

I had the same issue as everybody else with QGIS 3.12.3 on a Mac, but managed to get it working using the workaround suggested by 'a qgis user' below.

To elaborate on the explanation: following the steps posted by the original poster, if you hit 'OK' to save your mask specification and then reopen the Masks tab of the same layer, you will find that the masking information that you just entered has not in fact been saved.

So label masking definitely also works on Windows, it's only the default way to specify the 'mask source', namely using the symbol layer's 'layer properties' dialog, that seems to be broken.

The workaround that also worked for me was to specify the mask not through the layer properties dialog, but using the 'Layer Styling' panel that can be integrated into the main QGIS frontend. Enable it under View > Panels > Layer Styling, then select the Masks tab within the panel, enter your masking spec, hit 'Apply' and voila, everything works!

| improve this answer | |

I have just discovered that it doesn't work configuring it through the layer property window, but it works right doing it through the layer style panel!!

| improve this answer | |

I've found that buffering works in a similar way, and doesn't have the issues associated with masking.

| improve this answer | |

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.