Old 10-13-2019, 10:01 AM   #41
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

Thanks Steve, guess I'll have to try and parse the API docs myself if no one else does it.
Edgemeal is offline   Reply With Quote
Old 10-13-2019, 12:09 PM   #42
_Stevie_
Human being with feelings
 
_Stevie_'s Avatar
 
Join Date: Oct 2017
Location: Black Forest
Posts: 5,054
Default

That would be awesome, thanks for your effort!
__________________
My Reascripts forum thread | My Reascripts on GitHub
If you like or use my scripts, please support the Ukraine: Ukraine Crisis Relief Fund | DirectRelief | Save The Children | Razom
_Stevie_ is online now   Reply With Quote
Old 10-13-2019, 01:30 PM   #43
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

This one is for Lua only also.

FWIW, I replace quotation chars with ' chars. Hopefully there isn't any HTML mixed in the code, .Net class is supposed to fix/clean all that for me but not working as expected so had to use a find/replace workaround.

BTW, this doesn't include Julian's API, I'm keeping them separate.

Re-Post Fixed HTML '  with space char.

Last edited by Edgemeal; 10-14-2019 at 08:03 PM.
Edgemeal is offline   Reply With Quote
Old 10-13-2019, 03:22 PM   #44
Lokasenna
Human being with feelings
 
Lokasenna's Avatar
 
Join Date: Sep 2008
Location: Calgary, AB, Canada
Posts: 6,551
Default

1. The snippets that are up are what ausbaxter gave me ages ago, so no - you aren't using an outdated copy.

2. The problem with including returned parameters straight from the API docs is that you don't end up with valid Lua:
Code:
integer retval, number tracknumber, number itemnumber, number fxnumber = reaper.GetFocusedFX()
When parsing the original, are you able to split by comma to get the separate arguments and then only use characters after the space? I think that would work for all of them.

3. I'm happy to help get the parsing script sorted out and have it live in the repo if you want to open a pull request with what you've got so far. Maybe add a /parsing folder at the repo's root?

4. I've been wondering if this would be better served as an actual extension providing completion snippets rather than just being snippet files. Then it could have options for which extensions (SWS, JS, Ultraschall, my GUI, etc) to include. For example: https://github.com/microsoft/vscode-...letions-sample
__________________
I'm no longer using Reaper or working on scripts for it. Sorry. :(
Default 5.0 Nitpicky Edition / GUI library for Lua scripts / Theory Helper / Radial Menu / Donate
Lokasenna is offline   Reply With Quote
Old 10-13-2019, 03:44 PM   #45
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

1. OK Thanks.
2. Thats true, but I'd have to keep refering to the REAPER API docs if the return params aren't added. :/
3+. Honestly, I don't want to spend another minute on this, have fun!
Edgemeal is offline   Reply With Quote
Old 10-13-2019, 03:52 PM   #46
Lokasenna
Human being with feelings
 
Lokasenna's Avatar
 
Join Date: Sep 2008
Location: Calgary, AB, Canada
Posts: 6,551
Default

Quote:
Originally Posted by Edgemeal View Post
2. Thats true, but I'd have to keep refering to the REAPER API docs if the return params aren't added. :/
I just mean that you need to strip out "integer " from "integer retval" for it to work at all. As-is, if I use that snippet I'd have to manually remove the types every single time.
__________________
I'm no longer using Reaper or working on scripts for it. Sorry. :(
Default 5.0 Nitpicky Edition / GUI library for Lua scripts / Theory Helper / Radial Menu / Donate
Lokasenna is offline   Reply With Quote
Old 10-13-2019, 03:57 PM   #47
Lokasenna
Human being with feelings
 
Lokasenna's Avatar
 
Join Date: Sep 2008
Location: Calgary, AB, Canada
Posts: 6,551
Default

I just found an honest-to-goodness Lua language server for VS Code.

https://marketplace.visualstudio.com...me=sumneko.lua

It's even smart enough to tell me the default parameters for the classes in my GUI and offers method completion without having to manually create any snippets:

__________________
I'm no longer using Reaper or working on scripts for it. Sorry. :(
Default 5.0 Nitpicky Edition / GUI library for Lua scripts / Theory Helper / Radial Menu / Donate
Lokasenna is offline   Reply With Quote
Old 10-13-2019, 11:27 PM   #48
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

Quote:
Originally Posted by Lokasenna View Post
I just mean that you need to strip out "integer " from "integer retval" for it to work at all. As-is, if I use that snippet I'd have to manually remove the types every single time.
Ya, I thought it would be helpful, but it does make coding a lot harder.

Re-parsed the api docs into one snipet file, but still only Lua. Removed all the 'type-names' from all params, and made optional params into one word,..

Code:
retval, optional_key, optional_val = reaper.EnumProjExtState(proj, extname, idx)
You can build the snippet file yourself, see post #54.
Or for my latest posted snippet file see,
https://stash.reaper.fm/v/38109/ReaS...e-snippets.zip

Last edited by Edgemeal; 04-08-2021 at 07:26 AM.
Edgemeal is offline   Reply With Quote
Old 10-14-2019, 04:44 AM   #49
_Stevie_
Human being with feelings
 
_Stevie_'s Avatar
 
Join Date: Oct 2017
Location: Black Forest
Posts: 5,054
Default

Thanks a lot for doing this! Loving it
__________________
My Reascripts forum thread | My Reascripts on GitHub
If you like or use my scripts, please support the Ukraine: Ukraine Crisis Relief Fund | DirectRelief | Save The Children | Razom
_Stevie_ is online now   Reply With Quote
Old 03-31-2020, 09:42 AM   #50
Navelpluisje
Human being with feelings
 
Navelpluisje's Avatar
 
Join Date: Mar 2020
Location: IJsselstein, Netherlands
Posts: 435
Default More color highlighting

I didn't search the forum for tools, what I will do next time, but only the marketplace of vscode. I created my own color highlighting for the reaperTheme and the rtconfig.txt files which are available in the marketplace. (just search for reaper)
You can check it out here: https://marketplace.visualstudio.com...pluisje.reaper.
Attached Images
File Type: jpg screenshot.jpg (55.0 KB, 144 views)

Last edited by Navelpluisje; 03-31-2020 at 10:15 AM.
Navelpluisje is offline   Reply With Quote
Old 04-04-2021, 10:10 PM   #51
daniellumertz
Human being with feelings
 
daniellumertz's Avatar
 
Join Date: Dec 2017
Location: Brazil
Posts: 1,992
Default

Quote:
Originally Posted by Edgemeal View Post
Ya, I thought it would be helpful, but it does make coding a lot harder.

Re-parsed the api docs into one snipet file, but still only Lua. Removed all the 'type-names' from all params, and made optional params into one word,..

Code:
retval, optional_key, optional_val = reaper.EnumProjExtState(proj, extname, idx)
EDIT: Updated snippet file, Oct 16, 2020
ReaScript API (REAPER v6.15rc1/x64)
SWS v2.12.1.0 (BETA Oct-16-2020)
js_ReaScriptAPI v1.217

Download, https://stash.reaper.fm/v/38109/ReaS...e-snippets.zip
Hey Edgemeal I still use this with @gfxray I like that with his extension I get mouse over info but with the snippets I get the autocomplete with the variables there. Are you planning to update this from time to time or you think it will no longer be updated ? Thanks for this

Have you added ImGUI functions or they appear here by magic o.o?

Last edited by daniellumertz; 04-04-2021 at 11:44 PM.
daniellumertz is online now   Reply With Quote
Old 04-05-2021, 07:06 AM   #52
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

Quote:
Originally Posted by daniellumertz View Post
Hey Edgemeal I still use this with @gfxray I like that with his extension I get mouse over info but with the snippets I get the autocomplete with the variables there. Are you planning to update this from time to time or you think it will no longer be updated ? Thanks for this

Have you added ImGUI functions or they appear here by magic o.o?
I still update that snippet file on the Stash occasionally, like when I see something new was added, last was in March to add reaimgui I believe.

I didn't think anyone was using it since there has been more robust solutions posted.

Last edited by Edgemeal; 04-08-2021 at 07:27 AM.
Edgemeal is offline   Reply With Quote
Old 04-05-2021, 09:46 AM   #53
daniellumertz
Human being with feelings
 
daniellumertz's Avatar
 
Join Date: Dec 2017
Location: Brazil
Posts: 1,992
Default

Thanks for this Will download again!
daniellumertz is online now   Reply With Quote
Old 04-06-2021, 08:18 AM   #54
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

Quote:
Originally Posted by daniellumertz View Post
Thanks for this Will download again!
If you're on Windows you can build the snippet file yourself from latest ReaScriptHelp.html file.

VSCode Snippet Builder
v0.13 - Apr 06, 2021
* Allow user to set destination path & save/restore from ini file.

See readme in zip.

Zip on REAPER stash
https://stash.reaper.fm/v/44422/VSCo...er%20v0.13.zip

Last edited by Edgemeal; 05-01-2022 at 03:15 PM.
Edgemeal is offline   Reply With Quote
Old 04-07-2021, 09:10 AM   #55
daniellumertz
Human being with feelings
 
daniellumertz's Avatar
 
Join Date: Dec 2017
Location: Brazil
Posts: 1,992
Default

Oh cool! This is how you are doing then, was able to build here thank thnnks
daniellumertz is online now   Reply With Quote
Old 07-03-2021, 09:05 PM   #56
daniellumertz
Human being with feelings
 
daniellumertz's Avatar
 
Join Date: Dec 2017
Location: Brazil
Posts: 1,992
Default

Hey Edgemeal I wonder if is possible to export the python functions too. I am starting to mess with reaper and python so would be cool to have....
daniellumertz is online now   Reply With Quote
Old 07-04-2021, 05:56 AM   #57
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

Quote:
Originally Posted by daniellumertz View Post
Hey Edgemeal I wonder if is possible to export the python functions too. I am starting to mess with reaper and python so would be cool to have....
I don't want to say no/never, but its unlikely.

There was 1-2 other solutions posted to the forum that IIRC do all the languages, I don't have the links to them though.
Edgemeal is offline   Reply With Quote
Old 05-01-2022, 01:31 PM   #58
Sexan
Human being with feelings
 
Sexan's Avatar
 
Join Date: Jun 2009
Location: Croatia
Posts: 4,597
Default

Quote:
Originally Posted by Edgemeal View Post
If you're on Windows you can build the snippet file yourself from latest ReaScriptHelp.html file.

VSCode Snippet Builder
v0.13 - Apr 06, 2021
* Allow user to set destination path & save/restore from ini file.

See readme in zip.
This generator script is not available anymore?
Sexan is offline   Reply With Quote
Old 05-01-2022, 03:16 PM   #59
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,913
Default

Quote:
Originally Posted by Sexan View Post
This generator script is not available anymore?
Zip on REAPER stash,
https://stash.reaper.fm/v/44422/VSCo...er%20v0.13.zip
Edgemeal is offline   Reply With Quote
Old 05-02-2022, 03:05 AM   #60
Sexan
Human being with feelings
 
Sexan's Avatar
 
Join Date: Jun 2009
Location: Croatia
Posts: 4,597
Default

Thank you very much!
Sexan is offline   Reply With Quote
Old 08-05-2023, 05:10 AM   #61
Icchan
Human being with feelings
 
Icchan's Avatar
 
Join Date: Dec 2011
Location: Finland
Posts: 792
Default

Hi everyone.

Getting into LUA for REAPER and found this thread.

Have these tools been updated in a long time? I saw that stash link for Edgemeals builder goes to completely different thread than expected and as it says

"*** NO LONGER SUPPORTED ***"

I think there could be an up to date alternative somewhere?

Also, Lokasenna's git repository was updated ~5 years ago. what's the status of REAPER for vscode today?

What do I need to get going and not miss any intellisense or snippets etc. that I might want to have when diving into this? Do I need to make all of it myself to get going?

I'm new to LUA, even though I've been programming since ages, so I could use all the inline help and intellisense available

Last edited by Icchan; 08-05-2023 at 06:07 PM. Reason: typos
Icchan is offline   Reply With Quote
Old 08-05-2023, 06:05 AM   #62
vitalker
Human being with feelings
 
vitalker's Avatar
 
Join Date: Dec 2012
Posts: 13,333
Default

Quote:
Originally Posted by Icchan View Post
Hi everyone.

Getting into LUA for REAPER and found this thread.

Have these tools been updated in a long time? I saw that stash link for Edgemeals builder goes to completely different thread than expected and as it says

"*** NO LONGER SUPPORTED ***"

I think there could be an up to date alternative somewhere?

Also, Lokasenna's ghit repository was updated ~5 years ago. Rhat's the status of REAPER for vscode today?

What do I need to get going and not miss any intellisense or snippets etc. that I might want to have when diving into this? Do I need to make all of it myself to get going?

I'm new to LUA, even though I've been programming since ages, so I could use all the inline help and intellisense available
Lokasenna's signature says he is no longer a part of Reaper community. Why just not use native IDE? You can test all your code immediately without a need to use external services.
vitalker is online now   Reply With Quote
Old 08-05-2023, 06:09 AM   #63
Sexan
Human being with feelings
 
Sexan's Avatar
 
Join Date: Jun 2009
Location: Croatia
Posts: 4,597
Default

There is vs code extension
https://marketplace.visualstudio.com...reascript-docs
Sexan is offline   Reply With Quote
Old 08-05-2023, 09:48 PM   #64
PitchSlap
Human being with feelings
 
PitchSlap's Avatar
 
Join Date: Jan 2008
Location: Vancouver, BC
Posts: 3,793
Default

Quote:
Originally Posted by Sexan View Post
Awesome, I was just about to ask!
__________________
FRs: v5 Media Explorer Requests, Global Quantization, Session View
Win10 Pro 64-bit, Reaper 6(x64), AMD 3950x, Aorus X570 Master, 64GB DDR4 3600, PowerColor Red Devil 5700XT, EVO 970 2TB, 10TB HD, Define R6
PitchSlap is offline   Reply With Quote
Old 08-08-2023, 03:12 PM   #65
lalo
Human being with feelings
 
Join Date: Jun 2006
Posts: 187
Default

Quote:
Originally Posted by Sexan View Post
Thanks! I've just installed it on Windows 11 and latest VSCode version but i can't get synthax highlighting...is any configuration needed?
thanks
lalo 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 05:14 PM.


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