how to use codefolding feature of notepad++ for normal text documents

When I open an reg file in notepad++ file in notepad++, I see the amazing functionality to minimize and maximize the subkeys of a base key by clicking on that little arrow on the left. Can I get this functionality in normal documents? I want to create different categories for ex: topic 1, topic 2, etc, which I can maximize and minimize.

http://imgur.com/JU8JfwF


Solution 1:

You can define your own syntax highlighting and code folding rules by defining a 'User language'. Click Language -> Define your language... to open the User Defined Language dialog.

This dialog gives options for many levels of customisation. In your case, you could add the word 'Topic' to the 'Folding in code 1 style' open list.

Solution 2:

Basically, View -> User-Defined Dialogue
Create New. I call it Txt, set the extension to .txt
In folder and default pane, set the open and close options.
I use {{ and }} respectively.

Then from the View menu, use the fold, collapse options.

More details in http://sourceforge.net/p/notepad-plus/discussion/331754/thread/c01d98f7