Integrating Language Support into RText

I’ve spent the last week or so doing tedious, but important, stuff – making sure the RSTALangaugeSupport API is robust enough to be used in other applications.  The hard work is starting to pay off: Perl support is almost completely integrated already!

Perl options in RText

Perl options in RText

Here’s RText’s Options dialog, showing all the features related to Perl support that you can currently toggle.  As you can see, you can currently fiddle with both the code completion as well as the on-the-fly syntax checking I recently blogged about.  For the latter, you have to have a Perl install somewhere on your machine.  RText will scan your PATH for a Perl install, and default to using that, but you can change it to another installation if you want.  Still pending is the ability to add modules to the @INC path.

Language support will be fully integrated into all aspects of RText.  For example, compile errors and warnings will show up in the Error Strip component:

Compiler errors in Error Strip

Compiler errors in Error Strip

Also, function descriptions are displayed simply by hovering the mouse over them.  For example, below, my mouse is over the “print” function (sorry screen captures in Windows don’t capture the mouse pointer):

Function descriptions on mouse hover

Function descriptions on mouse hover

Perl is one of the harder languages to integrate, simply because its language support has so many features (runtime compilation, etc.) that others don’t have.  Hopefully other language supports will be integrated into RText shortly.  Stay tuned!

2 Responses to “Integrating Language Support into RText”

  1. [...] Language support added for C, Java, Perl, PHP, HTML and shell scripting (code completion for all, varying degrees of syntax checking for others).  While no Eclipse by any means, even the simplest of code completion support takes RText to another level of usability.  This is one area that will definitely be expanded moving forward.  Note that the focus is not on code project management, but simply on being able to provide code completion to speed up editing code. [...]

  2. [...] first item is already practically done.  I’ve integrated RSTALanguageSupport via a plugin.  I’ve still got a couple more ideas for the latter two items before 1.2 is good to [...]