How to override a syntax scope when there is another X scope present?
There is this scopes defined for the word defined
on the preprocessor scope, form the default C++ Syntax file.
meta.preprocessor.c++
keyword.control.c++
And on my syntax file, want to override the scope keyword.control
when the scope meta.preprocessor
is also defined.
On my settings files, there is this trick for the spellchecking overriding:
"spelling_selector": "source string.quoted - punctuation - meta.preprocessor.include, source comment",
It would only allow the spell checking when the scope punctuation
and meta.preprocessor.include
are not defined.
Now I want to do the same on my theme file:
<dict>
<key>name</key>
<string>Preprocessor</string>
<key>scope</key>
<string>preprocessor, meta.preprocessor - keyword.control</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>unbold</string>
<key>foreground</key>
<string>#804000</string>
</dict>
</dict>
But it is not working.