[SciPy-user] Automatic Indentation

Steve Schmerler elcorto@gmx....
Mon Mar 26 14:41:12 CDT 2007


Crider, Joseph A wrote:
> I frequently use jEdit (www.jedit.org) for editing code, and it has a
> command on the Edit menu to move indentation of a selected block either
> left or right, which has been very useful for me in similar situations.
> I've encountered similar features on some other editors, but I can't
> recall which ones right off.

Almost every text editor offers some functionallity of this kind. I
favour vim and ther it is CTRL-v for "visual block mode", then mark your
block and > for moving the block 'shiftwidth' characters to the right,
which should be equal to your tab-setting (set shiftwidth=4, set
tabstop=4 in my case).

Anyway if you have to indent very large code chunks, you're probably
writing  "spaghetti code" and should consider packing parts of it in
functions and classes to keep the clarity :)

-- 
cheers,
steve

I love deadlines. I like the whooshing sound they make as they fly by.
-- Douglas Adams



More information about the SciPy-user mailing list