[ESS] Customizing syntax highlighting

Steve Lianoglou mailinglist.honeypot at gmail.com
Fri Jul 23 19:10:16 CEST 2010


On Fri, Jul 23, 2010 at 12:55 PM, S. McKay Curtis
<smcurtis at stat.washington.edu> wrote:
> Steve,
> Fabulous!  Thanks for passing along the tip.  The fact that the first
> argument name after a line break never highlighted with my old .emacs code
> has been a minor irritant for a few months now.
> Note, I also had to change the "1" following the regexp to a "2" as in
> ("\\([(,]\\|[\n[:blank:]]*\\)\\([.A-Za-z][._A-Za-z0-9]*\\)[\n[:blank:]]*=[^=]"
> 2 font-lock-reference-face)

Yeah, sorry for not explicitly pointing that out -- it was in my
original email, but the funny wrapping may not have made it obvious.

There's a down side to this "fix" tho, which is that it will highlight
the LHS of a statement if you use "=" for assignment, eg:

x = 1:10
y = 11:20
z = x + y

The x,y,z on the LHS of those statements all get highlighted. It's not
a big deal for me since I always use "<-" for assignment in my code,
but it my annoy others who stumble onto this thread later and try this
out.

Cheers,
-steve

-- 
Steve Lianoglou
Graduate Student: Computational Systems Biology
 | Memorial Sloan-Kettering Cancer Center
 | Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact



More information about the ESS-help mailing list