diff options
| author | nyamatongwe <devnull@localhost> | 2010-10-20 14:55:46 +1100 |
|---|---|---|
| committer | nyamatongwe <devnull@localhost> | 2010-10-20 14:55:46 +1100 |
| commit | ce06ba97ce7bc80f9be8a646be20b784259c4a1d (patch) | |
| tree | 6ee572350dc0aa75d7532a336b852741a7828be4 /lexers/LexRuby.cxx | |
| parent | bddac88e201ea86920ef0dc41e13423aad5dbb80 (diff) | |
| download | scintilla-mirror-ce06ba97ce7bc80f9be8a646be20b784259c4a1d.tar.gz | |
Handle % quoting better.
From bug #2093767.
Diffstat (limited to 'lexers/LexRuby.cxx')
| -rw-r--r-- | lexers/LexRuby.cxx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lexers/LexRuby.cxx b/lexers/LexRuby.cxx index a77ff13ee..402b8da32 100644 --- a/lexers/LexRuby.cxx +++ b/lexers/LexRuby.cxx @@ -978,6 +978,15 @@ static void ColouriseRbDoc(unsigned int startPos, int length, int initStyle, } else if (preferRE && !isSafeWordcharOrHigh(chNext)) { // Ruby doesn't allow high bit chars here, // but the editor host might + Quote.New(); + state = SCE_RB_STRING_QQ; + Quote.Open(chNext); + advance_char(i, ch, chNext, chNext2); // pass by ref + have_string = true; + } else if (!isSafeWordcharOrHigh(chNext) && !iswhitespace(chNext) && !isEOLChar(chNext)) { + // Ruby doesn't allow high bit chars here, + // but the editor host might + Quote.New(); state = SCE_RB_STRING_QQ; Quote.Open(chNext); advance_char(i, ch, chNext, chNext2); // pass by ref |
