Searched for this, didn't find it. I can make a user defined lang that has folders for SQL (like BEGIN and END) and get it working. What I'd like to know is how I can add this to the language definition for SQL. Or at least copy the existing SQL definition to a user def language and then add the folder definitions. I made a language, added the folder defs (got it working), called it 'myLang' then I searched in the Notepad++ folder for any text called 'myLang' and didn't find it. Same with my user folder. And %APPDATA% for Notepad++.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
OK I looked in stylers.xml and there are no Keywords tags. So that's a dead end. I tried adding the <Keywords name="Folder+"> (and -) tags to langs.model.xml (where there are Keywords tags) and that didn't work. I've tried renaming the "My Lexer Template" to "SqlFolding" but it won't show up in the languages menu. I even went so far as to rename all instances of "My Lexer" to "My Lexer 01" in all of the config files and still it shows up as "My Lexer" in the Language menu. Is this whole thing sort-of data driven but not really? I'm changing data in lots of places but I never see it in Notepad menus/behavior. Grr.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Searched for this, didn't find it. I can make a user defined lang that has folders for SQL (like BEGIN and END) and get it working. What I'd like to know is how I can add this to the language definition for SQL. Or at least copy the existing SQL definition to a user def language and then add the folder definitions. I made a language, added the folder defs (got it working), called it 'myLang' then I searched in the Notepad++ folder for any text called 'myLang' and didn't find it. Same with my user folder. And %APPDATA% for Notepad++.
OK I looked in stylers.xml and there are no Keywords tags. So that's a dead end. I tried adding the <Keywords name="Folder+"> (and -) tags to langs.model.xml (where there are Keywords tags) and that didn't work. I've tried renaming the "My Lexer Template" to "SqlFolding" but it won't show up in the languages menu. I even went so far as to rename all instances of "My Lexer" to "My Lexer 01" in all of the config files and still it shows up as "My Lexer" in the Language menu. Is this whole thing sort-of data driven but not really? I'm changing data in lots of places but I never see it in Notepad menus/behavior. Grr.
Search for "folding".
Take a look at this message:
"Predefined languages - hardcoded?"
http://sourceforge.net/forum/forum.php?thread_id=1911720&forum_id=331754
There must be something somewhere about built-in like handling of user created languages (not via the User Define Dialog).
It is in the Plug-In forum:
"New External Lexer Support Template/Tutorial"
http://sourceforge.net/forum/forum.php?thread_id=1907325&forum_id=482781
OK, got that installed which took 15 mins. Now... nothing. I don't see any discussion of folding in that thread. Does the Gmod lexer support folding?
Add any of these Keywords entries to the Languages group/tag:
<Keywords name="Delimiters">[00]00</Keywords>
<Keywords name="Folder+">Begin FolderOpenKeywords</Keywords>
<Keywords name="Folder-">End FolderCloseKeywords</Keywords>
<Keywords name="Operators"># ( ) { } < = ></Keywords>
<Keywords name="Comment">1 2 0[</Keywords>
... or something likt it.
Just look in the stylers.xml for the default languages to get a clue.