[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Small improvements to ruby-mode

From: Bozhidar Batsov
Subject: Re: Small improvements to ruby-mode
Date: Wed, 10 Jul 2013 09:09:08 +0300

On 9 July 2013 20:09, Dmitry Gutov <address@hidden> wrote:
On 09.07.2013 18:36, Bozhidar Batsov wrote:
I've noticed two more font look issues (I guess I'm becoming annoying :-) ):

Not really. The novelty of seeing a Ruby user in emacs-devel still hasn't worn off. :)

You might want to start filing new reports as bugs, though.

Normally I'd have been doing that from the start, but I'm not extremely fond of Emacs's "issue tracker". Despite my feelings for it I will start using it, though.

- ?c, ?x, ?\n, ?\C-\M-d, etc should be font-locked as strings I guess,
since from Ruby 1.9 the character literal syntax actually yields strings.

It will be the right thing to do, but handling the backslashes and key chords looks kind of complicated.

Yep, the highlighting regexp won't be exactly pretty :-) 

- there should be support for the new %I/%i literals from Ruby 2.0 - I
guess we should font-lock them as symbols

I guess we should, but it's kind of complicated. The point of using percent literals is that you can put any stuff, at all, inside, and the only suitable Emacs syntax classes for that are strings and comments.

We should be able to overwrite that highlighting in ruby-font-lock-keywords, but I don't see a good way to do that, yet. This facility works with regexp-based search, and we need to effectively say "highlight from here and till the end of the string literal". 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]