[TxMt] Indentation of switch/case blocks

Allan Odgaard throw-away-1 at macromates.com
Wed Apr 19 01:15:32 UTC 2006


On 18/4/2006, at 23:13, Trevor Harmon wrote:

> [ switch/case ] I believe this is a pretty standard formatting  
> convention.

Yes, along with putting brackets around the code, keeping the break  
at same indent as the case, putting the break inside the brackets,  
etc. :)

> [...] I was hoping it could be smart about indenting switch/case  
> blocks, too. Is that possible? Perhaps there is something I could  
> add to the language definition?

While the indenting rules can be controlled [1], it does not have  
enough flexibility to work with switch/case statements.


[1] http://macromates.com/textmate/manual/appendix#indentation_rules




More information about the textmate mailing list