[Idle-dev] Hide code?
Stephen M. Gava
elguavas@users.sourceforge.net
Mon, 5 Nov 2001 01:20:58 +1100
On Mon, 5 Nov 2001 01:17:am, Bruce Sherwood wrote:
> Does the following have any merit for IDLE?
>
> In the program editor for another language (cT), you can hide individual
> routines in a file (this would be classes or defs in Python). You click
> somewhere in a routine and choose the "Hide" menu option. The head of the
> routine remains visible, but the entire body collapses down to a single
> indented horizontal line. Click on a hidden routine and choose "Show" to
> make the body visible again. There are also menu options to hide or show
> all routines in the file.
>
> The purpose is to facilitate working on a long module most of which is well
> debugged. You show only those routines you're currently working on.
>
> Implementation could be through special comment lines.
>
> I found this very useful when working on cT programs.
This concept is called "folding" and it is available in quite a number of
programmers text editors. In idle we can just open the class browser and
double click on the entries there to quickly jump around in a large module.
The overhead of implementing folding in the idle editor may be prohibitive.
Stephen.
--
Stephen M. Gava <elguavas@users.sourceforge.net>
IDLEfork ( http://idlefork.sourceforge.net ) " just like IDLE, only crunchy "