Code expansion/completion

Questions on using RSyntaxTextArea should go here.

Moderator: robert

Code expansion/completion

Postby CurareX » Mon Mar 30, 2009 5:16 pm


I'm a Java programmer who have stumbled onto this discovery, so I humbly thank you for this wonderful open-source component! :D Then I noticed that the latest feature includes a code completion feature. As I have an open-source project similar to the lines of the use of RSyntaxTextArea, I would just like to ask a simple question for clarifications, what are the available programming languages that are currently implemented for this code completion feature? A quick look through the documentation of the Code Completion open-source doesn't find the details of these.

Thank you!
Posts: 1
Joined: Mon Mar 30, 2009 5:08 pm

Re: Code expansion/completion

Postby robert » Thu Apr 02, 2009 1:07 pm

Hi CurareX,

The RSTA code completion doesn't support any languages directly; rather, it is a framework through which you can add completion support for any language. As you probably discovered, on the project page there is a Webstart example of code completion for the C standard library - that is implemented by reading all of the data from a simple XML file.

I also have a half-baked example of Java code completion, that offers completion for classes read from a user-specified "classpath", and even parses the current editor's contents for method and field names. This is an attempt at ensuring the feature is robust enough to support "dynamic" completion. One user emailed me an example he created of using the code completion feature for Groovy code completion, and is really quite good.

So in short, it's really more of a "framework" than an implementation for any specific language. I could certainly add language completion "implementations" to the project downloads, such as the C XML file in the demo, and the Java completion when (if) it's done.

Another thing I'm considering is adding support for parsing ctags output. This would allow for good code completion if you were okay with adding a dependency on the Exuberant ctags library (it's GPL, whereas RSTA is LGPL).
User avatar
Posts: 760
Joined: Sat May 10, 2008 5:16 pm

Return to Help

Who is online

Users browsing this forum: No registered users and 4 guests