Old 10-02-2018, 12:42 PM   #41
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Quote:
Originally Posted by rstockm View Post
This looks very promising, autocomplete for the REAPER/LUA API works like a charm. One suggestion, though: in LUA, there is no different color for the API calls, it's all white. For instance reaper.get_action_context() etc.
It would be very clever to have them colored, too?
Quote:
Originally Posted by mespotine View Post
Is there a way to expand it with syntax-highlighting for my own functions? Or for Lokasenna's Gui-Lib?
You can create tmLanguage files (please follow the existing format of having JSON files in src and tmLanguage in root folder) that define what function is what through defining scopes. Have a look at ReaSyntax - EEL.tmLanguage and ReaSyntax - JS.tmLanguage to see how it's done. Remember to use JSON cause it's much easier to edit and converting to tmLanguage can be done quite easily(package that offers commands to do that is called SerializedDataConverter)

If you want a special highlighting, after that you will have to create themes that highlight specific functions in specific scopes defined in tmLanguage files. When you do that, please use common sense when defining scopes. Most coders, me included, don't have that much need for so much different colors. A function is a function is a function, right? Having many colors sounds like fun but it's hard to maintain and readability is achived through smart use of spaces, formating, variable naming and such.

For general stuff I guess EEL tmLanguage file can be reused - but we will again have a problem with syntax being loaded for all Lua files, not just REAPER ones. This is easily solvable - example is already there in ReaScript.py where JS file detection happens

I would be much more grafetull if someone with more Sublime Text chops than me can fix loading of autocompletion files for specific files only


That said, if you want to contribute, simply do it and do a pull request. Please make it clean or I won't accept it. Unfortunately, I don't have much time to fix and test stuff I don't use.

Last edited by Breeder; 10-02-2018 at 02:00 PM.
Breeder is offline   Reply With Quote
Old 02-03-2019, 05:38 PM   #42
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Updated the ReaSyntax to 0.2.2

Changes are:
Code:
##### v0.2.2 (February 04 2018)
 * [Lua, EEL] Updated completions to match REAPER 5.965, SWS 2.10.0, ReaPack 1.2.1 and js_ReaScriptAPI 0.963
Breeder is offline   Reply With Quote
Old 03-12-2019, 06:06 AM   #43
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Updated the ReaSyntax to 0.2.3

Changes are:
Code:
##### v0.2.3 (March 12 2018)
 * [Lua, EEL] Updated completions to match REAPER 5.973, SWS 2.10.0 #1, ReaPack 1.2.2 and js_ReaScriptAPI 0.972
Breeder is offline   Reply With Quote
Old 04-07-2019, 02:48 AM   #44
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Updated the ReaSyntax to 0.2.4

Changes are:
Code:
##### v0.2.4 (April 07 2018)
 * [Lua, EEL] Updated completions to match REAPER 5.974, SWS 2.10.0 #1, ReaPack 1.2.2 and js_ReaScriptAPI 0.980
Breeder is offline   Reply With Quote
Old 04-10-2019, 06:28 AM   #45
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Updated the ReaSyntax to 0.2.5

Changes are:
Code:
##### v0.2.5 (April 10 2018)
 * [JS] Load JS syntax automatically for files with file extenstion ".jsfx"
Breeder is offline   Reply With Quote
Old 05-01-2019, 10:05 AM   #46
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Updated the ReaSyntax to 0.2.6

Changes are:
Code:
##### v0.2.6 (May 01 2019)
 * [Lua, EEL] Updated completions to match REAPER 5.975, SWS 2.10.0 #1, ReaPack 1.2.2 and js_ReaScriptAPI 0.985
Breeder is offline   Reply With Quote
Old 08-18-2019, 10:23 AM   #47
Breeder
Human being with feelings
 
Breeder's Avatar
 
Join Date: Nov 2010
Location: Croatia
Posts: 2,125
Default

Updated the ReaSyntax to 0.2.7

Changes are:
Code:
##### v0.2.7 (August 18 2019)
 * [Lua, EEL] Updated completions to match REAPER 5.982, SWS 2.10.0 #1, ReaPack 1.2.2 and js_ReaScriptAPI 0.990
Breeder is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 03:59 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.