A little disappointed so far

Robin Munn rmunn at pobox.com
Tue May 20 07:55:28 EDT 2003


Guy Middleton <guy at obstruction-no-spam.com> wrote:
> In article <NBmdnesebY8Gb1WjXTWcqg at comcast.com>,
> Terry Reedy <tjreedy at udel.edu> wrote:
>> 
>> "Graham Nicholls" <graham at rockcons.co.uk> wrote in message
>> news:Mv2ya.4193$573.1871 at news-binary.blueyonder.co.uk...
>> > I find it easy in c to press % and jump to the bottom of a loop.
>> How can I
>> > do this for Python files.  The increment was a legal, sensible
>> command, but
>> > not indented enough, so the loop
>> 
>> By collapsing the intervening blocks down to a line or so.  I
>> sometimes use the PythonWin editor which has little +s and -s in the
>> left column that, when clicked on, expand and collapse compound
>> statement blocks.  This make it *much* easier to line up a statement
>> with one above that would otherwise be off the screen.
> 
> Is there an editor on Unix that can do this?  In particular, is there a way to
> get gvim to do it?

Read :help folding -- in particular the foldmethod=indent option. I've
only played with it a little so far, but I think I'm going to start
using it for my Python code; it seems quite useful.

-- 
Robin Munn <rmunn at pobox.com>
http://www.rmunn.com/
PGP key ID: 0x6AFB6838    50FF 2478 CFFB 081A 8338  54F7 845D ACFD 6AFB 6838




More information about the Python-list mailing list