[R-SIG-Mac] BBEdit Language Module Enhancements

Jonathan Marc Bearak jonathan.bearak at gmail.com
Fri Oct 30 21:12:12 CET 2009


Thanks for noticing the missing 0.

I wonder why the function pattern works in BBEdit but not in  
TextWrangler, but since your revision seems to work in both, I swapped  
it in.


On Oct 30, 2009, at 4:02 PM, Berend Hasselman wrote:

> On 30/10/2009, at 20:10, Jonathan Marc Bearak wrote:
>> Hi,
>> I made a couple of enhancements to the BBEdit Language Module found  
>> in this thread:
>> 	https://stat.ethz.ch/pipermail/r-sig-mac/2005-December/002520.html
>> I have uploaded the language module here:
>> 	http://homepages.nyu.edu/~jmb736/code/R_language_module_for_BBEdit/R.plist
>> This language module, as revised, will detect R functions, so you  
>> can browse functions in the symbols menu.
>> I have not yet figured out how to match the function body.  As  
>> such, when the cursor is placed, not in the function name, but in  
>> the function body, the symbols menu will display "(no symbols  
>> selected)".  I am not sure when I will next have time to look at  
>> this, but in any case, simply being able to browse function names  
>> is the really important thing (for me, anyway) so I do not have to  
>> scroll down a file or use the find dialog just to find a function.
> I tried your R.plist in TextWrangler 3 and it failed to recognise  
> functions.
> I changed the function pattern to this
> 		<key>Function Pattern</key>
> 		<string>(?P&lt;function_name&gt;[a-z0-9_A-Z.]+)\s*&lt;- 
> \s*function</string>
> and then TextWrangler does recognise R functions with function names  
> appearing in the symbols popup menu.
> The string for <key>Identifier and Keyword Characters</key> should  
> also contain a 0 (zero digit).
> Berend

More information about the R-SIG-Mac mailing list