diff options
| author | nyamatongwe <unknown> | 2010-10-20 14:55:46 +1100 | 
|---|---|---|
| committer | nyamatongwe <unknown> | 2010-10-20 14:55:46 +1100 | 
| commit | ecd5e7da1c84b0165203ca29335f74142b50f073 (patch) | |
| tree | deaa0f09ffaab795d23adb7def60cd9446120c2e /lexers/LexRuby.cxx | |
| parent | 85c776304cdd0a3a48f1a5dba42d89cea9665d9a (diff) | |
| download | scintilla-mirror-ecd5e7da1c84b0165203ca29335f74142b50f073.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  | 
