[Gambas-user] Code Origami Mysteries

Bruce Bruen bbruen at ...2308...
Tue Aug 23 08:28:19 CEST 2011


Well, I'm flabbergasted!  :-)

I have just discovered the code folding in the gambas 3 IDE.  (Yes, I 
know I'm slow. It comes with age. :-X )

But two things have got me beat.

1.  Is there a keyboard shortcut to collapse/expand the current folding 
region?

2. (A bit more mysterious!)  I use a standard prototype for all my 
classes so I can remember where to find things (age again -  memory span 
is about 5 milliseconds these days).  It looks like this:

'=================================================================
'====                   EVENT Declarations                    ====
'=================================================================

'=================================================================
'====                 Property Declarations                   ====
'=================================================================

'=================================================================
'====                Local Property Variables                 ====
'=================================================================

'=================================================================
'====                     Local Variables                     ====
'=================================================================

'=================================================================
'====                    Special Methods                      ====
'=================================================================

'=================================================================
'====                     Public Methods                      ====
'=================================================================

'=================================================================
'====                    Private Methods                      ====
'=================================================================

'=================================================================
'====                      Event Handlers                     ====
'=================================================================

'=================================================================
'====                   Property Accessors                    ====
'=================================================================

and here is a picture of a sample class with all regions collapsed
collapsed

Now, that is absolutely fantatistic!!!!!!
But.

Sometimes those header block comments are not shown.  Here's an example, 
caused by including a blank line after the block comment:
cant see some blocks
Notice how the "Property Accessors" block comment is no longer visible.

The mystery to me is:

         What are the rules that the IDE follows when folding code?

cheers
Bruce





More information about the User mailing list