- April 8, 2016 at 7:28 am #20691
I would like to call a pre-existing snippet using the keyboard, but without using the trigger. I have a number of snippets I don’t use often enough to justify a trigger, but I’m a keyboard addict, and I was wondering if it would be possible to add them to the Quick Launch somehow?
It would be fine if a could call them via a macro. I found the ExecutePlugin function, but it appears to only allow snippets defined as a parameter. The snippets I have are too long for that. If it would be possible to identify the snippet, perhaps using the ‘path’, for example “Pascal\NewLine”, that would be enough. I have no problem creating a macro that I can reach via the quick launch or toolbar, or whatever.
Or some other way would be fine as well. That’s just a thought I had.
Thanks for your consideration.
PaulApril 8, 2016 at 12:01 pm #20694
On the next beta version (v15.9.0 beta 3), you will be able to call Snippets by using ExecutePlugin function with the nParam = 1, and strParam = path to the snippet. For example:
editor.ExecutePlugin( "Snippets.dll", eePluginUserMessage, 1, "General\\Date" );
I hope this will help you.
Thank you!April 8, 2016 at 12:38 pm #20695
Looking forward to trying it out.
You must be logged in to reply to this topic.