From 3d8dc2f8fcd5408235eb2fee4e7d1ffd9ba67f95 Mon Sep 17 00:00:00 2001 From: Neil Date: Mon, 17 Mar 2014 09:01:12 +1100 Subject: Bug [#1583]. Fix keyword style extending past end of word. From Alpha. --- doc/ScintillaHistory.html | 5 +++++ lexers/LexCoffeeScript.cxx | 7 +++++++ 2 files changed, 12 insertions(+) diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html index 85eee8f1f..35598a358 100644 --- a/doc/ScintillaHistory.html +++ b/doc/ScintillaHistory.html @@ -485,6 +485,11 @@ ';' to separate statements.
  • + Fix Coffeescript lexer for keyword style extending past end of word. + Also fixes styling 0...myArray.length all as a number. + Bug #1583. +
  • +
  • Fix crashes and other bugs in Fortran folder by removing folding of do-label constructs.
  • diff --git a/lexers/LexCoffeeScript.cxx b/lexers/LexCoffeeScript.cxx index 9da531adb..def93599d 100644 --- a/lexers/LexCoffeeScript.cxx +++ b/lexers/LexCoffeeScript.cxx @@ -204,6 +204,13 @@ static void ColouriseCoffeeScriptDoc(unsigned int startPos, int length, int init sc.SetState(SCE_COFFEESCRIPT_DEFAULT); } break; + case SCE_COFFEESCRIPT_WORD: + case SCE_COFFEESCRIPT_WORD2: + case SCE_COFFEESCRIPT_GLOBALCLASS: + if (!setWord.Contains(sc.ch)) { + sc.SetState(SCE_COFFEESCRIPT_DEFAULT); + } + break; case SCE_COFFEESCRIPT_PREPROCESSOR: if (sc.atLineStart && !continuationLine) { sc.SetState(SCE_COFFEESCRIPT_DEFAULT); -- cgit v1.2.3