Calculates layer values referencing other layers.
Let's learn how it works with a simple example:
- Create a text layer named
layer_1
with the value3
. - Create a text layer named
layer_2
with the value10
. - Create a text layer named
={layer_1} + {layer_2}
with any value and run the plugin. - The value should be changed to
13
, the sum oflayer_1
andlayer_2
.
You can also use other arithmetic operations.
Try creating the following:
={layer_1} * 2
={layer_1} - {layer_2}
={layer_1} + (100 * ({layer_2} / 2))
You can also simply reference other field. That's useful, for example, when you need to define a value in a single place of and use it along the document:
={layer_1}
The plugin also support a number of operation with strings:
=CONCAT({layer_1}, {*layer_2}, {layer_3})
=UPPER({layer_1})
=LOWER({layer_1})
By default, layer names in formulas will be searched in the same artboard as the formula layer. But formulas can also include references to layers in other artboards by being referenced with a *
before the name. For example:
={layer_1}
uses the value oflayer_1
layer in the same artboard.={*layer_1}
uses the value of the firstlayer_1
layer that exists in any artboard of the document.
- For the moment the plugin only works with "," as decimal separator.
- We haven't done any performance optimization yet, so it might be slow in complex documents.
- Right now elements need to be included in an artboard.