aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/LexPython.cxx
diff options
context:
space:
mode:
authornyamatongwe <unknown>2000-09-06 01:01:01 +0000
committernyamatongwe <unknown>2000-09-06 01:01:01 +0000
commitce2f36ca12b7628e4bf738c0c3a2d6a5ac1d928d (patch)
tree9125f6b449b989f4b347c369a53ee057e1eb1e0e /src/LexPython.cxx
parent54ed137dd177c32f4c57e950cd62d92c0a154875 (diff)
downloadscintilla-mirror-ce2f36ca12b7628e4bf738c0c3a2d6a5ac1d928d.tar.gz
Dots inside identirifers are now in the operator lexical class.
Added markus Gritsch to credits list.
Diffstat (limited to 'src/LexPython.cxx')
-rw-r--r--src/LexPython.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/LexPython.cxx b/src/LexPython.cxx
index df8b7085b..492d21c7d 100644
--- a/src/LexPython.cxx
+++ b/src/LexPython.cxx
@@ -33,6 +33,13 @@ static void ClassifyWordPy(unsigned int start, unsigned int end, WordList &keywo
chAttr = SCE_P_NUMBER;
else if (keywords.InList(s))
chAttr = SCE_P_WORD;
+ // make sure that dot-qualifiers inside the word are lexed correct
+ else for (unsigned int i = 0; i < end - start + 1; i++) {
+ if (styler[start + i] == '.') {
+ styler.ColourTo(start + i - 1, chAttr);
+ styler.ColourTo(start + i, SCE_P_OPERATOR);
+ }
+ }
styler.ColourTo(end, chAttr);
strcpy(prevWord, s);
}