Project

General

Profile

TH3-Code Collapse » History » Version 1

Version 1/5 - Next » - Current version
Wil van Antwerpen, 05/18/2019 10:15 PM


Code Collapse

The Hammer 3.0 is based on the scintilla control and as such it wasn't too hard to add code collapse specifically for the DataFlex language.
This is one of those features that you don't miss until you actually have it.

Currently the following scope keywords automatically support the collapse feature:

  • begin / end code blocks
  • object / end_object
  • class / end_class
  • procedure / end_procedure
  • function / end_function
  • while / loop
  • case begin / case end
  • type / end_type
  • struct / end_struct
  • section metatags (see below)

section metatags

If you want to be able to collapse a whole bunch of code so that you can quickly hide specific parts of code then use the section metatag collapse feature.

It works as follows:

  { #CodeSection YourSection }
.... your code
  { #CodeSection YourSection }

This then looks as follows:

compiler listfiles

This one is pretty useful and not one you would think of immediately.

If you have a .prn/.prp file then you actually have code collapse in there as well (was broken, just fixed 2019-05-17)

It can really be a drag having to plough through all that code. Being able to use code collapse in here does help quite a bit.