![]() Registered Member ![]()
|
Do Kate plugins have to be compiled, or can it also take Javascript?
I can do what I need to do with just a couple of lines of Javascript without the overhead of header files, a makefile, etc. etc. etc. The only reason I trying to make a plugin is so that I can assign a menu entry and a keyboard shortcut to my script so I don't have to keep going into the command interface and executing it each time. I've looked into external tools, but I don't see a way to make them pipe their output back into the document. So, to recap, I'd be happy with an answer to any one of these three questions: 1. Can a Javascript be a Kate plugin? 2. Can a keyboard short cut and a menu item be assigned to a Javascript? 3. Can external tools insert their output at the current cursor position? Thanks. |
![]() Registered Member ![]()
|
Yes, meanwhile Kate can be scripted in JavaScript and you can add it to menus and assign shortcuts. js source code: https://projects.kde.org/projects/kde/a ... cript/data Example: https://projects.kde.org/projects/kde/a ... s/utils.js Documentation: usually available in the kate handbook on http://docs.kde.org For KDE < 4.10 you can also find an example here: http://kate-editor.org/2010/07/09/kate- ... d-actions/ |
Registered users: Bing [Bot], Evergrowing, Google [Bot]