How can I trigger Stateflow's "Arrange Automatically" via the API?
Show older comments
You can arrange a Stateflow chart within the editor by using Ctrl+Shift+A to "Arrange Automatically". How can I trigger this functionality when programmatically generating a Stateflow chart? For instance, the analogous feature in Simulink can be accessed from MATLAB via the Simulink.BlockDiagram.arrangeSystem function.
Answers (1)
Kunal Kandhari
on 19 Jan 2023
0 votes
I am not aware of ways to align or distribute blocks programmatically but, starting MATLAB 2018b you can use Simulink.BlockDiagram.arrangeSystem(system) from your MATLAB command window to automatically arrange your model.
1 Comment
Alex Hirzel
on 27 Jan 2023
Categories
Find more on Simulink Functions in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!