summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Hacohen <tom@stosb.com>2012-07-03 06:15:01 +0000
committerTom Hacohen <tom@stosb.com>2012-07-03 06:15:01 +0000
commitea4f042b2985803da1e4b7871946549bf4b902ea (patch)
tree94daa8182e8800bf935fb69019d13295365c45cf
parent62e266dbd4287737199987c0034a5bb708c24a6a (diff)
Edi: Fixed colour of statement keywords.
SVN revision: 73190
-rw-r--r--src/bin/edi_main.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/bin/edi_main.c b/src/bin/edi_main.c
index b31b7c3..954cf02 100644
--- a/src/bin/edi_main.c
+++ b/src/bin/edi_main.c
@@ -46,6 +46,7 @@ typedef enum {
46 /* SYNTAX */ 46 /* SYNTAX */
47 EDI_COLOR_FOREGROUND_PUNCTUATION, 47 EDI_COLOR_FOREGROUND_PUNCTUATION,
48 EDI_COLOR_FOREGROUND_KEYWORD, 48 EDI_COLOR_FOREGROUND_KEYWORD,
49 EDI_COLOR_FOREGROUND_KEYWORD_STMT,
49 EDI_COLOR_FOREGROUND_REF, 50 EDI_COLOR_FOREGROUND_REF,
50 EDI_COLOR_FOREGROUND_COMMENT, 51 EDI_COLOR_FOREGROUND_COMMENT,
51 EDI_COLOR_FOREGROUND_LITERAL, 52 EDI_COLOR_FOREGROUND_LITERAL,
@@ -70,6 +71,7 @@ static const int colors[][4] =
70 /* SYNTAX */ 71 /* SYNTAX */
71 { 0x4E, 0x9A, 0x06, 255 }, /* punctuation */ 72 { 0x4E, 0x9A, 0x06, 255 }, /* punctuation */
72 { 0x4E, 0x9A, 0x06, 255 }, /* keyword */ 73 { 0x4E, 0x9A, 0x06, 255 }, /* keyword */
74 { 0xC4, 0xA0, 0x00, 255 }, /* keyword statement */
73 { 0x80, 0x80, 0x80, 255 }, /* ref */ 75 { 0x80, 0x80, 0x80, 255 }, /* ref */
74 { 0x34, 0x65, 0xA4, 255 }, /* comment */ 76 { 0x34, 0x65, 0xA4, 255 }, /* comment */
75 { 0xCC, 0x00, 0x00, 255 }, /* literal */ 77 { 0xCC, 0x00, 0x00, 255 }, /* literal */
@@ -219,6 +221,20 @@ _clang_load_highlighting(Edi_File *ef)
219 case CXCursor_PreprocessingDirective: 221 case CXCursor_PreprocessingDirective:
220 color = EDI_COLOR_FOREGROUND_PREPROCESSING_DIRECTIVE; 222 color = EDI_COLOR_FOREGROUND_PREPROCESSING_DIRECTIVE;
221 break; 223 break;
224 case CXCursor_CaseStmt:
225 case CXCursor_DefaultStmt:
226 case CXCursor_IfStmt:
227 case CXCursor_SwitchStmt:
228 case CXCursor_WhileStmt:
229 case CXCursor_DoStmt:
230 case CXCursor_ForStmt:
231 case CXCursor_GotoStmt:
232 case CXCursor_IndirectGotoStmt:
233 case CXCursor_ContinueStmt:
234 case CXCursor_BreakStmt:
235 case CXCursor_ReturnStmt:
236 color = EDI_COLOR_FOREGROUND_KEYWORD_STMT;
237 break;
222 default: 238 default:
223 color = EDI_COLOR_FOREGROUND_KEYWORD; 239 color = EDI_COLOR_FOREGROUND_KEYWORD;
224 break; 240 break;