On Fri, Mar 13, 2009 at 22:16, Martin Friebe <laza...@mfriebe.de> wrote: > There is a general plan/idea to add some configuration (have to see how > much) to define what you want to have foldable and what not. It wasn't > seen as urgent yet (at least not by me...) > > Most (if not all) of the places that allow folding now, do so in Delphi > as well. this is part of why they have been added, to make it easier for > (ex-) Delphi users.
Actually, at least in Delphi 2007 code folding works only down to classes and procedures, not below. Still, I think it is a good feature. > IMHO most of the new ones are reasonable? > - Except maybe for: "Program" / "Unit" and "Implementation" / > "interface"; but they don't occur very often in a normal unit. > - Maybe discussable are "var" "Canost" "type" blocks? Think is they can > be very useful for bigger "var" sections (but I agree they can be > irritating with just on line in it) > - Folding at class / private / public => IMHO should be ok? > - Folding at "procedure" in addition to the begin => arguable, if it > should be instead of the begin? I'd say that such deep nesting should have very detailed configuration. I suggest to replace current numeric setting with a grid of checkboxes controlling code folding and divider drawing separately at logical levels: Level | Folding | Divider Unit/Program | Off | Off Section (interface/implementation/...) | On | Off Class/Object/Record Type Definition | On | On Class Visibility Specifier (public/private/...) | Off | Off Other Type Definition | On | Off Uses statement | On | Off Global var/property/const | On | On Procedure/Function/Method implementation | On | On Nested Procedure/Function | On | Off Local var/const | Off | Off Begin/end blocks | Off | Off Additionally, maybe for begin/end blocks a separate setting to turn folding on for blocks longer that N lines. The settings I above are my preferences, and I hope also reasonable defaults. -- Alexander S. Klenin _______________________________________________ Lazarus mailing list Lazarus@lazarus.freepascal.org http://www.lazarus.freepascal.org/mailman/listinfo/lazarus