diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2014-09-18 14:06:30 +0200 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2014-09-19 18:36:19 +0200 |
| commit | 2630e50e1c33a4383f16a9bda82a7822500a7dfc (patch) | |
| tree | 96f1746d1c9efed77336b245a0e9618d91354b81 /syntax.h | |
| parent | f01457b003d3b0d996f1f2e97112015b8df26fdb (diff) | |
| download | vis-2630e50e1c33a4383f16a9bda82a7822500a7dfc.tar.gz vis-2630e50e1c33a4383f16a9bda82a7822500a7dfc.tar.xz | |
Improve syntax highlighting
Diffstat (limited to 'syntax.h')
| -rw-r--r-- | syntax.h | 12 |
1 files changed, 5 insertions, 7 deletions
@@ -3,8 +3,6 @@ #include <regex.h> -#define SYNTAX_RULES 10 /* maximal number of syntax rules per file type */ - typedef struct { short fg, bg; /* fore and background color */ int attr; /* curses attributes */ @@ -18,11 +16,11 @@ typedef struct { } SyntaxRule; typedef struct Syntax Syntax; -struct Syntax { /* a syntax definition */ - char *name; /* syntax name */ - char *file; /* apply to files matching this regex */ - regex_t file_regex; /* compiled file name regex */ - SyntaxRule rules[SYNTAX_RULES]; /* all rules for this file type */ +struct Syntax { /* a syntax definition */ + char *name; /* syntax name */ + char *file; /* apply to files matching this regex */ + regex_t file_regex; /* compiled file name regex */ + SyntaxRule rules[12]; /* all rules for this file type */ }; #endif |
