diff options
Diffstat (limited to 'syntax.h')
| -rw-r--r-- | syntax.h | 10 |
1 files changed, 3 insertions, 7 deletions
@@ -4,20 +4,15 @@ #include <regex.h> typedef struct { - short fg, bg; /* fore and background color */ - int attr; /* curses attributes */ -} Color; - -typedef struct { char *rule; /* regex to search for */ - Color *color; /* settings to apply in case of a match */ + int style; /* settings to apply in case of a match */ bool multiline; /* whether . should match new lines */ regex_t regex; /* compiled form of the above rule */ } SyntaxRule; typedef struct { char *symbol; - Color *color; + int style; } SyntaxSymbol; enum { @@ -35,6 +30,7 @@ struct Syntax { /* a syntax definition */ char *file; /* apply to files matching this regex */ regex_t file_regex; /* compiled file name regex */ const char **settings;/* settings associated with this file type */ + const char **styles; /* settings associated with this file type */ SyntaxSymbol symbols[SYNTAX_SYMBOL_LAST]; /* symbols for white space handling */ SyntaxRule rules[24]; /* all rules for this file type */ }; |
