Open markhavemann opened 2 years ago
Yes, this is by design. The reason I do not indent them is because AHK is a bit strange in the fact that there really isn't a reliable way to tell when you have finished a label. With a function there is a clear { and } but labels are sadly not as structured :(
that's so sad, it would make code sooo much more readable.
Any way to make it a feature by something like adding a certain comment (maybe somethin like "return ;=end=label name=") at the end of the return for a label?
Besides that AHK Studio is amazing, thanks for making it!
you can use ;{ and ;} around any code to indent it: `;{
this will be indented
;} this won't`
that's awesome, thank!
For anyone else who finds this in the future:
Make sure "Auto Indent Comment Lines" is turned on in "Options->Auto Indent", otherwise it won't indent from the commented curly braces.
Is it by design that content of labels are not automatically indented?
I love that fuctions and loops and everything with curly brackets is indented, but autoindent will often UNindent my labels for me after I've done it manually. AHK uses so many labels that this is almost a dealbreaker for me since it makes code so much harder to read.