I have approached other third party viewers in the past about this but they always seem cagey about giving us scripters anything new and interesting to work with. So figured that maybe you might be interested in actually implementing this as you seem to like including things in your viewer to enhance the user experience.
At present when scripting in LSL, if you create an interesting snippet of code or regularly use the same snippets of code then you are generally limited to how you store those snippets for future use. For me, they are stored in multiple scripts, separated into categories in my inventory that I have to go searching for each and every time I want to copy and paste a sections of code into my current project. This is not a bad solution by any means but can be a bit cumbersome if you have multiple snippets to retrieve from multiple different scripts. So, my idea is this...
The ability to save code snippets to your own custom function / snippet library that is stored on your computer / cloud server / where ever you desire.
It works like this.
Firstly click the edit menu and set your library location. This could be, for example Cloud Drive / LSL / MathLibrary.
Once the library location has been selected the viewer could set up a simple key pair value file that links the name of the snippet to the snippet code itself. (Maybe...you are more the expert on this than me).
Then to save the snippet you would....
1. Highlight section of code.
2. Right click section of code.
3. Select "Save Function / Snippet" from the menu.
4. Give your snippet a name and click save.
5. This is then stored locally in the library file created earlier. Snippet name would appear in a drop down box at the bottom of the viewer next to the drop down box for built in LSL function.
To load a snippet you would....
1. Place cursor where you want the snippet inserted.
2. Select snippet name from drop down list.
3. Snippet is inserted at cursor position.
Why do I think this is a good idea?.
1. It would help users quickly organise and access their code snippets.
2. The use of "set library location" could allow users to switch between different libraries depending on their needs.
3. It would allow users to access their LSL libraries between SL and Open Sim without the need of copy pasting multiple code snippets from one world to the other.
4. Users could in fact share their library files for other scripters to use maybe leading to quite large useful open source libraries.
5. It would add depth to the notion of scripting purely in the viewer and keep the immersion aspect of being in Second Life.
Yes I am aware that Firestorm has it's include function. But honestly, that seems janky and doesn't feel all that immersive or well thought out.
Yes there are external programs that you can use such as external editors but adding something native to the viewer would simplify the process and give some power back to the built in script editor.
Scripters literally get no love when it comes to viewer development. The focus always seems to be on the shoppers, bloggers and photographers and quite honestly it's getting tiring. I feel like there is so much potential that LL / TPV developers could tap into for the built in script editor and yet no one ever does anything to improve it.
For example, opening multiple scripts in the one window in tabs with a save all option. Thus letting you work on multiple scripts without needing 6 script windows open in front of you. Or outputting llOwnerSay messages to the lower text area (apologies I forget what its called) where it tells you that the script has been saved. Could even enable a "histories" version of the library idea that when enabled saves a copy of the scripts current saved state externally allowing you to revert to earlier versions.
Lastly. Thank you for taking the time reading this
.
Concept image is here :
https://pasteboard.co/JPn0dZx.png