for loop
古いコメントを表示
Hi everyone,
I want to tidy up lots of for loops I have. I have confused which end in belongs to which 'if' or 'for'. I know there is a very to tidy up, but I can not remember. Would you please help me on that. Thank you!
S.
回答 (1 件)
Jos (10584)
2011 年 3 月 22 日
1 投票
In the Matlab Editor,
- select the text you want to tidy up
- use the menu "Text" -> "Smart Indent" (or the shortcut, which is cmd-I on the Mac, and something similar on PC's)
6 件のコメント
S
2011 年 3 月 22 日
Matt Tearle
2011 年 3 月 22 日
On a PC:
ctrl-A
ctrl-I
My fingers do it without my brain having to tell them to!
Walter Roberson
2011 年 3 月 22 日
But it still bugs me that it has to be control-I and not the tab key!
Matt Tearle
2011 年 3 月 22 日
Never thought of the tab as a mass indent operator. What bugs me is that ctrl-I unfolds everything.
Andrew Newell
2011 年 3 月 23 日
I never thought of tab that way either, but it would be very tidy!
Matt Fig
2011 年 3 月 23 日
It doesn't matter to me what the shortcut key is, I am just glad TMW included one to do the job.
カテゴリ
ヘルプ センター および File Exchange で Loops and Conditional Statements についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!