I know about live templates and use them, but I don't see how I can use them to do auto-complete for LUA "classes", which is something that sublime2 does http://sublimetext.info/docs/en/extensibility/completions.html
If indeed live templates would allow this, is there a format that can be generated and read without restarting?
Many many thanks.
I see, so the question is to how introduce target text into template. The IDE already provides a notion of 'surround templates', i.e. templates which use text selected at editor. You can combine that with the powerful macros sub-system. The general idea is to write a macros which selects target text and calls target custom surround template and bind it to shortcut.
I've created a small screencast which illustrates the whole process - https://dl.dropbox.com/u/1648086/video/macro-template.m4v
Thank you so much for your help, I just have a final question, is there a way to load these from a generated file? The reason for this is that I have hundreds of completions in sublime that I create from the code source when I run a build script.
Sure, all 'surround' templates are stored at $IDEA_CONFIG_HOME/templates/surround.xml file. So, you can do the following:
This got me almost there, the only thing I can't seem to do is have IntelliJ pick up these changes without restarting it. Is there a way to read the xml everytime it builds?