Corona Editor - extra autocomplete

Hi guys,

I’ve been slowly adding a few new features to my own fork of Corona Editor.

I’ve focussed on adding the following to the already excellent autocomplete: 

  1. Require autocomplete  - Corona Editor can now suggest modules when autocompleting require statements. For instance if I start typing [background=‘grey’]require "s [/background]Corona Editor suggests “util.serpent” (along with others)
  2. String filename autocomplete - inside quotation marks Corona Editor can also suggest file paths for assets. For instance if I type [background=‘grey’]display.newImage(".pn[/background], Corona Editor suggests “img/skull.png”. 

Firstly, I have only been developing these features to work for myself. The require autocomplete is well tested and robust. String filename autocompelte is a new addition and currently doesn’t handle ‘/’ as well as I would like, but so far has lived up to expectations.

If you would like to try these features for yourself, grab the source from https://github.com/personalnadir/CoronaSDK-SublimeText

Though it very much comes with a ‘mileage may vary’ health warning! 

Oh, it’s also worth saying that this version has two new options:

  • “corona_sdk_follow_symlinks”: defaults to false. Controls whether when searching for files the editor follows symlinks in your project directory. I tend to use symlinks when including common assets in my projects. If that makes no sense to you, then ignore it.
  • corona_sdk_autocomplete_extensions":[".png",".jpeg",".jpg",".wav",".mp3"]: controls the file types that Corona Editor will include in the string filename autocomplete. Add extra extensions if you use Ogg Vorbis, AAC or database files. 

Oh, it’s also worth saying that this version has two new options:

  • “corona_sdk_follow_symlinks”: defaults to false. Controls whether when searching for files the editor follows symlinks in your project directory. I tend to use symlinks when including common assets in my projects. If that makes no sense to you, then ignore it.
  • corona_sdk_autocomplete_extensions":[".png",".jpeg",".jpg",".wav",".mp3"]: controls the file types that Corona Editor will include in the string filename autocomplete. Add extra extensions if you use Ogg Vorbis, AAC or database files.