- select the text you want to align (e.g. ctrl+a)
- press ctrl+i
is there a cmd which can justify a script at once?
1 次查看(过去 30 天)
显示 更早的评论
Dear Matlab users,
I would like to knwo whether there is an option that put your script in "good shape".
What I mean is that when you write your script and you add the line starting with "if" there is a tab which is automatically applied. All the text up to the associated "end" will be accordingly "tabbed".
But if you add a comment in between then the wire is broken and the tab is restored to 0.
Or if you remove some lines containing if/end then what was connected to this removed if/end will not be restored to a normal position.
Do you knwo whether there is cmd which allow to justify the whole script at once?
Many thanks
Frederic
0 个评论
采纳的回答
Stephen23
2021-3-26
编辑:Stephen23
2021-3-26
In the MATLAB editor:
2 个评论
Walter Roberson
2021-3-26
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/563266/image.png)
Or select all of the text, and then click on the first of those icons shown in the "Ident" line
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 String 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!