When defining the behavior, we will be asked to input values frequently. Some input fields support expression, which means you can use a sentence to represent the value in design phase, and it will be replaced with the real value in simulation.
An expression can contain constants, properties (element property or global property) parenthesis and operators. The figure below shows an example of expression:
Although the expression is in code form, usually you don't have to input them letter by letter, ForeUI provides some tools to help you create the expression quickly.
All input fields that support expression will has a button nearby. This button can bring out the property chooser, which will help you to insert property into the field. The property chooser looks like this:
There are two tabs in the property chooser window which allow you to browse element property or global property.
Insert Element Property
To browse the element property, you need to specify an element first. Make sure the "Element Property" tab is selected and click the "Choose..." button in property chooser window to pick the element, the element chooser will pop up:
You can also input the element id in the element field:
Then you can choose the property in the drop-down list.
Insert Global Property
To insert global property, just click the "Global Property" tab in the property chooser window and select the property in the drop-down list:
Finish the Expression
You can insert multiple properties into the input field, then use operators, parenthesis, and constants to finish the expression.