|
|
|
10-02-2018, 12:42 PM
|
#41
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Quote:
Originally Posted by rstockm
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
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.
|
|
|
02-03-2019, 05:38 PM
|
#42
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
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
|
|
|
03-12-2019, 06:06 AM
|
#43
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
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
|
|
|
04-07-2019, 02:48 AM
|
#44
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
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
|
|
|
04-10-2019, 06:28 AM
|
#45
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
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"
|
|
|
05-01-2019, 10:05 AM
|
#46
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
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
|
|
|
08-18-2019, 10:23 AM
|
#47
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
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
|
|
|
11-02-2019, 11:02 PM
|
#48
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.2.8
Changes are:
Code:
##### v0.2.8 (November 03 2019)
* [Lua, EEL] Updated completions to match REAPER 5.984, SWS 2.10.0 #1, ReaPack 1.2.2 and js_ReaScriptAPI 0.995
|
|
|
12-04-2019, 02:55 AM
|
#49
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.2.9
Changes are:
Code:
##### v0.2.9 (December 04 2019)
* [Lua, EEL] Updated completions to match REAPER 6.0, SWS 2.11.0 #0, ReaPack 1.2.2 and js_ReaScriptAPI 0.995
|
|
|
01-17-2020, 07:39 AM
|
#50
|
Human being with feelings
Join Date: Aug 2019
Location: beijing
Posts: 612
|
couldn't find the LUA syntax (REAPER)
hi breeder,
after installing the ReaSyntax,
I went to the view> Syntax> ReaSyntax> here I only found : - EEL (REAPER)
- JS (REAPER)
- WALTER (REAPER)
this is the video I made.
My sublime text3 version : 3.2.2
I installed package control from : https://packagecontrol.io/installation
instructions I followed : https://github.com/Breeder/ReaSyntax/
after installing package control I tried these 2 method from the link above.
- Using Package Control
Install Package Control
Use Cmd+Shift+P or Ctrl+Shift+P and search for Package Control: Install Package
Wait for Package Control to download latest package list and search for ReaSyntax
- Download manually
Download zipped repository from here
Unzip the files and rename the folder to ReaSyntax
Find your Packages directory using the menu item Preferences -> Browse Packages...
Copy the folder into your Sublime Text Packages directory
I supposed I would see LUA (REAPER) in the Syntax section.
is thrr anything I did wrong ?
or is it normal ?
Last edited by todoublez; 01-17-2020 at 07:52 AM.
|
|
|
05-19-2020, 04:08 AM
|
#51
|
Human being with feelings
Join Date: Jan 2010
Location: Fjugesta, Sweden
Posts: 811
|
Quote:
Originally Posted by todoublez
I supposed I would see LUA (REAPER) in the Syntax section.
is thrr anything I did wrong ?
or is it normal ?
|
I think you shall use LUA.
I loaded a script and LUA was marked and the code completion
worked as it should.
|
|
|
05-19-2020, 04:25 AM
|
#52
|
Human being with feelings
Join Date: Jan 2010
Location: Fjugesta, Sweden
Posts: 811
|
Quote:
Originally Posted by mespotine
Is there a way to expand it with syntax-highlighting for my own functions? Or for Lokasenna's Gui-Lib?
|
+1 for UltrashallAPI and Lokasenna GUI/Scythe
That would be lovely!
Great suggestion Mespotine!
|
|
|
05-19-2020, 04:28 AM
|
#53
|
Human being with feelings
Join Date: Jan 2010
Location: Fjugesta, Sweden
Posts: 811
|
Quote:
Originally Posted by Breeder
Updated the ReaSyntax to 0.2.9
Changes are:
Code:
##### v0.2.9 (December 04 2019)
* [Lua, EEL] Updated completions to match REAPER 6.0, SWS 2.11.0 #0, ReaPack 1.2.2 and js_ReaScriptAPI 0.995
|
I just bought Sublime Text and then I found this!
Great stuff @Breeder!
|
|
|
07-08-2020, 09:12 AM
|
#54
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.0
Changes are:
Code:
##### v0.3.0 (July 08 2020)
* [Lua, EEL] Updated completions to match REAPER 6.12, SWS 2.12.0 #0, ReaPack 1.2.3 and js_ReaScriptAPI 1.215
|
|
|
12-05-2020, 07:08 AM
|
#55
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.1
Changes are:
Code:
##### v0.3.1 (December 05 2020)
* [Lua, EEL] Updated completions to match REAPER 6.18, SWS 2.12.1, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.217
|
|
|
12-06-2020, 11:47 AM
|
#56
|
Human being with feelings
Join Date: Jan 2010
Location: Fjugesta, Sweden
Posts: 811
|
Quote:
Originally Posted by Breeder
Updated the ReaSyntax to 0.3.1
Changes are:
Code:
##### v0.3.1 (December 05 2020)
* [Lua, EEL] Updated completions to match REAPER 6.18, SWS 2.12.1, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.217
|
Nice - thanks for your work!
|
|
|
12-06-2020, 11:59 AM
|
#57
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Quote:
Originally Posted by tompad
Nice - thanks for your work!
|
Thanks man
|
|
|
02-11-2021, 12:49 AM
|
#58
|
Human being with feelings
Join Date: Nov 2015
Location: earth
Posts: 471
|
ReaSyntax JS Editor colors for Lua
So I decided to add JS Editor theme support for Lua script files because colors are important.
You can get the files here:
https://stash.reaper.fm/v/41332/ReaS...itor_Theme.zip
Just my way of showing my gratitude for an awesome ST3 package. Thanks, Breeder!
I'm not sure how the github thing works. But feel free to update it to include this stuff if you want.
Also, for anyone who does a lot of other Lua scripting in ST3, just a fair warning: this may also change the color scheme for Lua when you aren't working on Reaper scripts.
|
|
|
02-11-2021, 03:06 AM
|
#59
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,333
|
Do you know guys last Reaper versions have some cool stuff?
- autosuggest text (function names, variable names) while typing
- add Ctrl+R for replace (after find), Ctrl+Return to insert line after current, Ctrl+J to jump to line number
- support searching backwards via Ctrl+Shift+G or Shift+F3
- double-clicking a user function name jumps to the function definition
- improve search function, up/down changes search modes (substring, word, token)
- reduce flicker in watch lists
- show viewable line range in status line
- add preference for watch window update interval
- remember watch-enabled state
|
|
|
02-11-2021, 06:04 AM
|
#60
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Quote:
Originally Posted by earhax
So I decided to add JS Editor theme support for Lua script files because colors are important.
You can get the files here:
https://stash.reaper.fm/v/41332/ReaS...itor_Theme.zip
Just my way of showing my gratitude for an awesome ST3 package. Thanks, Breeder!
I'm not sure how the github thing works. But feel free to update it to include this stuff if you want.
Also, for anyone who does a lot of other Lua scripting in ST3, just a fair warning: this may also change the color scheme for Lua when you aren't working on Reaper scripts.
|
THAAAAANK YOU!!!
I believe this 'may change other Lua scripts' could be remedied
through that small python script in the package that detects .eel scripts. I guess it could be modified to detect REAPER .lua scripts as well.
I'll put it in the first post for now cause God only knows how many people use Package Manager and we don't want to make such surprises unannounced.
Last edited by Breeder; 03-06-2021 at 10:43 PM.
|
|
|
03-06-2021, 10:39 PM
|
#61
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.2
Changes are:
Code:
##### v0.3.2 (March 07 2021)
* [Lua, EEL] Updated completions to match REAPER 6.25, SWS 2.12.1.3, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.220
|
|
|
03-07-2021, 10:34 AM
|
#62
|
Human being with feelings
Join Date: Dec 2020
Location: Miami, FL USA
Posts: 396
|
Hey Breeder, just wanted to say thank you for writing & maintaining this. Syntax-highlighting support for WALTER, Eel, and JS in VS Code only exists because of you:
vscode-reascript-extension/resources/ReaSyntax COPYRIGHT NOTICE.txt
__________________
Seasoned codemonkey
Dunno a thing about making music (here to learn!)
|
|
|
03-07-2021, 07:51 PM
|
#63
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Quote:
Originally Posted by gxray
|
Nice, thank you! Visual studio is awesome, I kinda miss it from SWS days. The only thing that it missed was multiple cursors. Wonder if they implemented it in newer versions, they got so bloated I just decided to stick with old versions of VS. I might give your extension a try, this is something I always wanted but never got around doing it so I'm glad someone else took a shoot at it. Thanks again my friend!
|
|
|
03-29-2021, 03:55 PM
|
#64
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.3
Changes are:
Code:
##### v0.3.3 (March 30 2021)
* [Lua, EEL] Updated completions to match REAPER 6.26, SWS 2.12.1.3, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.220
|
|
|
04-15-2021, 02:40 PM
|
#65
|
Human being with feelings
Join Date: Dec 2015
Posts: 172
|
Quote:
Originally Posted by Breeder
Updated the ReaSyntax to 0.3.3
Changes are:
Code:
##### v0.3.3 (March 30 2021)
* [Lua, EEL] Updated completions to match REAPER 6.26, SWS 2.12.1.3, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.220
|
Hi! Thank you for this awesome package!
Any chance to have autocompletion for Dear IMGUI functions? It would be just great!
|
|
|
04-15-2021, 05:46 PM
|
#66
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Quote:
Originally Posted by kartalex
Hi! Thank you for this awesome package!
Any chance to have autocompletion for Dear IMGUI functions? It would be just great!
|
I downloaded that extension just yesterday so it will be in the next build xD
|
|
|
04-15-2021, 06:12 PM
|
#67
|
Human being with feelings
Join Date: Dec 2015
Posts: 172
|
Quote:
Originally Posted by Breeder
I downloaded that extension just yesterday so it will be in the next build xD
|
That's cool!
|
|
|
04-15-2021, 06:30 PM
|
#68
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.4
Changes are:
Code:
##### v0.3.4 (April 16 2021)
* [EEL] Added completions support for extension API (REAPER 6.24 introduced new syntax for extension API functions without using extension_api)
* [EEL] Added completions back (due to recent changes in REAPER, auto-build script wasn't exporting EEL completions)
* [Lua, EEL] Added completions support for ReaImGui (current version: 0.2)
* [Lua, EEL] Updated completions to match REAPER 6.27, SWS 2.12.1.3, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.220
|
|
|
04-17-2021, 03:40 PM
|
#69
|
Human being with feelings
Join Date: Dec 2015
Posts: 172
|
Quote:
Originally Posted by Breeder
Updated the ReaSyntax to 0.3.4
Changes are:
Code:
##### v0.3.4 (April 16 2021)
* [Lua, EEL] Added completions support for ReaImGui (current version: 0.2)
* [Lua, EEL] Updated completions to match REAPER 6.27, SWS 2.12.1.3, ReaPack 1.2.3.1 and js_ReaScriptAPI 1.220
|
Thanks a lot!
|
|
|
04-20-2021, 03:26 AM
|
#70
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.5
Changes are:
Code:
##### v0.3.5 (April 20 2021)
* [Lua] Removed three completions that were messing with the Sublime Text's auto-complete (Fixes #6):
* reaper.ImGui_TableFlags_NoHostExtendX()
* reaper.ImGui_TableFlags_NoHostExtendY()
* reaper.ImGui_GetTextLineHeightWithSpacing(ImGui_Context ctx)
|
|
|
05-08-2021, 04:05 AM
|
#71
|
Human being with feelings
Join Date: Jan 2010
Location: Fjugesta, Sweden
Posts: 811
|
Quote:
Originally Posted by Breeder
Updated the ReaSyntax to 0.3.5
Changes are:
Code:
##### v0.3.5 (April 20 2021)
* [Lua] Removed three completions that were messing with the Sublime Text's auto-complete (Fixes #6):
* reaper.ImGui_TableFlags_NoHostExtendX()
* reaper.ImGui_TableFlags_NoHostExtendY()
* reaper.ImGui_GetTextLineHeightWithSpacing(ImGui_Context ctx)
|
Any way to include Reabank support?
Was thinking on editing Reaticulate files....
Adaline made something for VScode,
https://forum.cockos.com/showpost.ph...postcount=1359
, I am not sure if its something usable in Sublime Text....my knowledge
of these things is rather short...
|
|
|
05-23-2021, 05:36 PM
|
#72
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.7
Changes are:
Code:
##### v0.3.7 (May 24 2021)
* [Lua, EEL] Updated completions to match REAPER 6.29, js_ReaScriptAPI 1.220, ReaImGui 0.4, ReaPack 1.2.3.1 and SWS 2.12.1.3
Last edited by Breeder; 05-23-2021 at 05:46 PM.
|
|
|
05-23-2021, 05:41 PM
|
#73
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Quote:
Originally Posted by tompad
Any way to include Reabank support?
Was thinking on editing Reaticulate files....
Adaline made something for VScode,
https://forum.cockos.com/showpost.ph...postcount=1359
, I am not sure if its something usable in Sublime Text....my knowledge
of these things is rather short...
|
Sorry for the late reply, I only saw your question just now. Quick look at the VS extension files looks like it's not easy as copy paste but in theory it should be very doable to make it from the scratch. Since I do not use ReaBanks, I personally doubt I will do it, but you can always contact me if you need coding custom stuff and we can make a deal.
|
|
|
07-06-2021, 01:23 AM
|
#74
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.8
Changes are:
Code:
##### v0.3.8 (July 06 2021)
* [Lua, EEL] Updated completions to match REAPER 6.30, js_ReaScriptAPI 1.220, ReaImGui 0.5.2, ReaPack 1.2.3.1 and SWS 2.12.1.3
|
|
|
09-04-2021, 06:57 AM
|
#75
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
Updated the ReaSyntax to 0.3.9
Changes are:
Code:
##### v0.3.9 (September 04 2021)
* [Lua, EEL] Updated completions to match REAPER 6.36, js_ReaScriptAPI 1.220, ReaImGui 0.5.6, ReaPack 1.2.3.1 and SWS 2.12.1.3
|
|
|
10-27-2021, 02:47 AM
|
#76
|
Human being with feelings
Join Date: Dec 2015
Posts: 324
|
this looks great!
sorry in advance for a probably stupid question:
is there any way of using this reasyntax in Atom? or easily adapting it for Atom? I guess the answer is no, but as i don't know much about this stuff i figured i might be wrong
|
|
|
10-27-2021, 03:14 AM
|
#77
|
Human being with feelings
Join Date: Nov 2010
Posts: 2,436
|
No idea, never heard of Atom
|
|
|
11-04-2021, 03:58 AM
|
#78
|
Human being with feelings
Join Date: Dec 2015
Posts: 324
|
ok. fyi atom is an open source text editor developed by gihub https://atom.io/
|
|
|
11-06-2021, 01:41 PM
|
#79
|
Human being with feelings
Join Date: Dec 2020
Location: Miami, FL USA
Posts: 396
|
Quote:
Originally Posted by benmiller
this looks great!
sorry in advance for a probably stupid question:
is there any way of using this reasyntax in Atom? or easily adapting it for Atom? I guess the answer is no, but as i don't know much about this stuff i figured i might be wrong
|
Yeah, you can use it in Atom from a quick google search I believe.
(Atom has been pretty dead[1] since Microsoft acquired Github, and put all the Atom devs onto VS Code development though, as an FYI)
The Textmate grammar files are what you need, in the repo they are the ones that end with ".tmLanguage"
So for example, here's the Eel one:
https://github.com/Breeder/ReaSyntax...EEL.tmLanguage
I googled "Atom textmate grammar", and from this tutorial, it seems you need the JSON form, not the XML form that is used in Breeder's repo.
The easiest way I know to convert between these formats is to: - Download VS Code
- Install the "Textmate Languages" extension.
- Press "Ctrl/Cmd + Shift + P" in VS Code with the ".tmLanguage" file open for Eel/WALTER that Breeder's repo provides, and run the command "Convert to JSON-tmLanguage"
Now with this JSON form of the Textmate grammar/language file, you can use it with Atom for syntax highlighting.
See the tutorial here on "Creating a legacy Textmate Grammar":
Click to see image guide: https://i.imgur.com/RyVgZxkh.png
-------------
Good reminder for me to donate to Breeder again for maintaining this (and other things) =P
Quote:
[1]: See below
Atom Commit Timeline:
VS Code Commit Timeline:
|
__________________
Seasoned codemonkey
Dunno a thing about making music (here to learn!)
Last edited by gxray; 11-06-2021 at 01:50 PM.
|
|
|
11-08-2021, 10:00 AM
|
#80
|
Human being with feelings
Join Date: Dec 2015
Posts: 324
|
Quote:
Originally Posted by gxray
Yeah, you can use it in Atom from a quick google search I believe.
(Atom has been pretty dead[1] since Microsoft acquired Github, and put all the Atom devs onto VS Code development though, as an FYI)
The Textmate grammar files are what you need, in the repo they are the ones that end with ".tmLanguage"
...
|
cool, thanks for the helpful info! I'll try this when i get the time.
|
|
|
Thread Tools |
|
Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -7. The time now is 06:28 AM.
|