Syntax

Literal Values

Refer to the following syntaxes for using layer names, text, numbers, color values and variables in the formula input field.

Layer name

Use backticks around the layer name.

Layer name
Text

Use double quotation marks around the text.

Text
Text with multiple lines

Add a \n to add a line break between characters or words.

Text with multiple lines
Number

Use Arabic numbers only; other symbols are not allowed.

Number
Color

Colors must be expressed in the #FFFFFF format (Hex color code).

Color
Variable

Use variable names that do not have any symbols in the name.

Variable

Arithmetic operations

The four basic arithmetic operations (+, -, *, /) and remainder calculations are supported.

Remainder calculations (%)

Remainder calculations are done to derive the remainder of a division operation by using the % operative. For example, 5%2 would result in 1 as the remainder in that operation is 1.

Text functions

While arithmetic operations apply to numbers only in most cases, addition can be done with texts. When a text is "added" to another text, the end result is a new text with the two texts combined together. For example, adding "2" to "1" would result in the new text "12".

Text + Text
"helloworld""12"
Text + Number
"hello1234"