How to use this forum. Please read!

This forum should be used for all code folding problems, questions or suggestions. You can also use this forum to request folding support for a new language.
Post Reply
jussij
Site Admin
Posts: 2650
Joined: Fri Aug 13, 2004 5:10 pm

How to use this forum. Please read!

Post by jussij »

This forum should be used to ask questions, highlight problems or offer suggestions regarding the code folding feature.

While the Zeus code folding has been designed to be language neutral, unlike other Zeus features it is not user configurable :(

But this forum can be used to request changes to the current folding or ask for folding support for other languages :)

For a request to be considered it must contain a minimum set of information regarding the language, including:
  1. The file extensions used by the language
  2. The line comment characters
  3. The block comment characters
  4. Matching pairs of begin/end fold keywords
  5. A short piece of sample code demonstrates how these comments and matching pairs of keywords are used
Once the folding has been added a new xfolder.dll will be published as a download link, making the folding available to all Zeus users. The new folding dll is usually available within 48 hours of the posting of the request.

As an example of the imformation that is required this would be the description of the folding for the c/c++ language:

Code: Select all

    Extensions: .c .cpp .cxx .h .hxx
 Line Comment: //
Block Comment: /*  */
        Begin: {    
          End: }
  Sample Code:
      int test(int value)
      {
        if (value = 1)
        {
           // as this sample code is used to test the folding
        }
        else
        {
           // the code does not need to compile but must be accurate!
        }
      }
and here is an example for the Lua language:

Code: Select all

    Extension: .lua
 Line Comment: --
Block Comment: none
        Begin: if
          End: end
        Begin: for
          End: end
        Begin: function
          End: end
  Sample Code:
      function example()
      
        if marked == 1 then
          top   = get_marked_top()
        end -- if
      
        for line in file_handle:lines() do
          -- write the line to the new file
          print(line)
        end
      end

key_macro() -- run the macro
jussij
Site Admin
Posts: 2650
Joined: Fri Aug 13, 2004 5:10 pm

Re: How to use this forum. Please read!

Post by jussij »

It is also possible to add a language to an existing folder by editing the following file:

Code: Select all

C:\Users\<User ID>\AppData\Local\Programs\Zeus (x64)\xFolder.ini
For example, to add folding for a Pascal like language, all that is needed is adding the file extension to the Pascal entry found in that file:

Code: Select all

Pascal=p;pas
Post Reply