I wondering, is there a way to use some default values for expressions, if selected attribute is not found?
Let's say i have a StringExpression for TextSymbol text like [_text_], so if i apply this style to feature with attribute table without _text_ attribute, feature will render with text "_text_", but i need, for example set some default text, or even leave it empty.
Same with NumericExpressions, let's say i have some InstanceSymbol with scale property, which may depend on attribute, for example: [_height_] / 50. And i want it to be just 1 (for whole expression, or 50 for missing attribute _height_, if its possible, so whole expressions becomes 1), if there is no _height_ attribute.
Just to clarify: programmatically, i should set this script in StyleSheet (setScript method)?
Can it hit rendering performance? In other words, i can render a lot of feature nodes / feature model layers, can i set this script with basic js functions to every StyleSheet, even if styles within this StyleSheet don't use js functions as expression or it's better to do some preparation?