| Author |
Message |
EMebane
Joined: Apr 15, 2019 Posts: 108
|
Posted: Aug 17, 2019 5:56 AM Post subject: Nested Design position |
|
| I created a nested design with one Nested Output. When I reset the design all 4 instances of my nested design snapped back to the same location. I added a Nested Input and Nested Properties element to the Nested Design (without using them for anything) and they stay in the position they were assigned. Is this as intended? The docs say that you need at least a Nested Input or Nested Output, not both. |
|
 |
jarek
Joined: Oct 22, 2007 Posts: 1073
|
Posted: Aug 17, 2019 2:50 PM Post subject: |
|
Yes, either nested input or output is needed to create a nested design. But I don't remember how this is related to the reset option (which was added much later). I guess it is possible having them both adds some extra path to the executed code.
The reset clears all "local" settings (if "Load/save local properties" option is selected) and should be done every time the nested design is modified. |
|
 |
EMebane
Joined: Apr 15, 2019 Posts: 108
|
Posted: Aug 17, 2019 8:55 PM Post subject: |
|
Now I am modifying an existing Nested Design that was already working (Threshold). I am adding Input Text Elements. When values are entered into the Input Text Fields of an instance of the Nested Design and the Design is reloaded, the values of the Input Text Elements revert to their default values.
Under the Nested Design > Advanced Properties > Nested Initialization the setting is Load/Save Local Properties.
What else must be done so that individual settings in Nested Designs are preserved?
I am not using the Properties panel. Does that play a mandatory role in storing values that were set on Elements in an instance of a Nested Design? |
|
 |
jarek
Joined: Oct 22, 2007 Posts: 1073
|
Posted: Aug 17, 2019 9:46 PM Post subject: |
|
The "Load/Save Local Properties" is probably what makes it behave not as you expect. Because when you edit (change it by loading as a main) the nested design, it will automatically reset next time you load it. It should happen only once, until next time it is edited again.
You should have a more expected behavior with a "Global" option. If you do not need several instances of the same nested design in your main design, then a "Global" option is a better choice.
The NestedProperties element is for customizing the properties. Its original purpose was ability to create a nested design as a black box (or library) with only some small number of properties exposed to the world to make is simple to use.
It was a while since all that was implemented, I probably do not remember all the details. |
|
 |
EMebane
Joined: Apr 15, 2019 Posts: 108
|
Posted: Aug 17, 2019 10:33 PM Post subject: |
|
Thanks. I have multiple Thresholds in the same design, each with their own settings I'd like to specify in Text Elements in the Threshold Nested Design.
I left the Load/Save Local Properties at Local so each instance would retain its own properties.
I solved it by setting the Text Input Element's Properties > Remember Last to true. It looks like the problem wasn't related to being within a Nested Design, but rather the Text Element itself wasn't set to remember its own status. |
|
 |
EMebane
Joined: Apr 15, 2019 Posts: 108
|
Posted: Aug 17, 2019 10:43 PM Post subject: |
|
| And it may help others to point out one more thing: I must press Enter after changing a value in a Text Element to force that value to be saved. If I just change the value then save and reload the Design, the Text Element is populated with the prior saved value. Running the design also causes the value in the Text Element to be stored. |
|