diff options
author | nyamatongwe <unknown> | 2003-02-17 11:18:11 +0000 |
---|---|---|
committer | nyamatongwe <unknown> | 2003-02-17 11:18:11 +0000 |
commit | bb028fe06a4e642aa20f72136c2deaf312ba61b9 (patch) | |
tree | 045f6c279f221341f136acd2d2cdd2e8db3a65f8 /src/LexPascal.cxx | |
parent | d9b3f2fe99e4bb7fb6649eee27382f25f20a4146 (diff) | |
download | scintilla-mirror-bb028fe06a4e642aa20f72136c2deaf312ba61b9.tar.gz |
Upgraded keyword list descriptions from Brian Quinlan.
Diffstat (limited to 'src/LexPascal.cxx')
-rw-r--r-- | src/LexPascal.cxx | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/LexPascal.cxx b/src/LexPascal.cxx index 37e5e995f..c3bea6773 100644 --- a/src/LexPascal.cxx +++ b/src/LexPascal.cxx @@ -34,7 +34,7 @@ static void getRange(unsigned int start, } static bool IsStreamCommentStyle(int style) { - return style == SCE_C_COMMENT || + return style == SCE_C_COMMENT || style == SCE_C_COMMENTDOC || style == SCE_C_COMMENTDOCKEYWORD || style == SCE_C_COMMENTDOCKEYWORDERROR; @@ -50,7 +50,7 @@ static int classifyWordPascal(unsigned int start, unsigned int end, /*WordList & WordList& keywords = *keywordlists[0]; WordList& classwords = *keywordlists[1]; - + char s[100]; getRange(start, end, styler, s, sizeof(s)); @@ -119,7 +119,7 @@ static void ColourisePascalDoc(unsigned int startPos, int length, int initStyle, styler.StartSegment(startPos); for (unsigned int i = startPos; i < lengthDoc; i++) { char ch = chNext; - + chNext = styler.SafeGetCharAt(i + 1); if ((ch == '\r' && chNext != '\n') || (ch == '\n')) { @@ -329,7 +329,7 @@ static void FoldPascalDoc(unsigned int startPos, int length, int initStyle, Word levelPrev = levelCurrent; visibleChars = 0; } - + if (!isspacechar(ch)) visibleChars++; } @@ -339,4 +339,10 @@ static void FoldPascalDoc(unsigned int startPos, int length, int initStyle, Word styler.SetLevel(lineCurrent, levelPrev | flagsNext); } -LexerModule lmPascal(SCLEX_PASCAL, ColourisePascalDoc, "pascal", FoldPascalDoc); +static const char * const pascalWordListDesc[] = { + "Keywords", + "Classwords", + 0 +}; + +LexerModule lmPascal(SCLEX_PASCAL, ColourisePascalDoc, "pascal", FoldPascalDoc, pascalWordListDesc); |