Hi Sebastian,
> On 3. May 2022, at 11:33, Sebastian Haunss <
sebastia...@uni-bremen.de> wrote:
>
> I have a layer with several features. Some features are of type Primitive: String.
> Is it possible to set a coloring rule so that if one of these string features takes a certain value (e.g. "1") the color of the layer is set to e.g. green (#00ff00)? How would that rule look like?
The coloring rules are simply a list of regular expressions that is applied to the annotation label that is shown above the annotated text.
If you want to match a label that contains a "1" anywhere, you'd use ".*1.*" to match it. If the 1 could appear in different contexts and
you would only want to rule to apply in certain contexts of it appearing, you'd have to write your regular expressions such that it only
matches the "1" in those contexts that matter to you.
The rules are processed from top to bottom. So if you want to color say all annotations containing the "1" green and all others red, you'd say
".*1.*" -> Green
".*" -> Red
Cheers,
-- Richard