mirror of
https://github.com/zyedidia/micro.git
synced 2026-02-07 15:40:24 +09:00
* Adds new syntax groups and docs * Large refactor of syntax highlighting files * Changed keybindings for changing tabs. * Improved the documentation. * Added F3 for find to default bindings. * Massive overhaul of the syntax files * Phase 1 color-scheme updates. * The new colorschemes. * Colorscheme and syntax updates. * Tiny fix to the cmc theme. * Another phase of colorschemes and testing gitconfig. * Fixed haskell error * Fortran fix * Delete test.txt Heh, sorry about forgetting to do this again.
46 lines
1.7 KiB
Plaintext
46 lines
1.7 KiB
Plaintext
## Here is an example for C.
|
|
##
|
|
syntax "c" "\.(c|C)$" "\.(h|H)$" "\.ii?$" "\.(def)$"
|
|
color identifier "\b[A-Z_][0-9A-Z_]+\b"
|
|
color type "\b(float|double|char|int|short|long|sizeof|enum|void|static|const|struct|union|typedef|extern|(un)?signed|inline)\b"
|
|
color type "\b((s?size)|((u_?)?int(8|16|32|64|ptr)))_t\b"
|
|
color type.extended "\b(bool)\b"
|
|
color statement "\b(typename|mutable|volatile|register|explicit)\b"
|
|
color statement "\b(for|if|while|do|else|case|default|switch)\b"
|
|
color statement "\b(try|throw|catch|operator|new|delete)\b"
|
|
color special "\b(goto|continue|break|return)\b"
|
|
color preproc "^[[:space:]]*#[[:space:]]*(define|pragma|include|(un|ifn?)def|endif|el(if|se)|if|warning|error)"
|
|
color constant "'([^'\\]|(\\["'abfnrtv\\]))'" "'\\(([0-3]?[0-7]{1,2}))'" "'\\x[0-9A-Fa-f]{1,2}'"
|
|
|
|
##
|
|
## GCC builtins
|
|
color statement "__attribute__[[:space:]]*\(\([^)]*\)\)" "__(aligned|asm|builtin|hidden|inline|packed|restrict|section|typeof|weak)__"
|
|
|
|
#Operator Color
|
|
color symbol.operator "[.:;,+*|=!\%]" "<" ">" "/" "-" "&"
|
|
|
|
#Parenthetical Color
|
|
color symbol.brackets "[(){}]" "\[" "\]"
|
|
|
|
#Includes
|
|
color constant.string "<.+?>"
|
|
#Integers
|
|
color constant.number "\b[0-9]+\b" "\b0x[0-9A-Fa-f]+\b"
|
|
color constant.number "NULL"
|
|
|
|
##
|
|
## String highlighting. You will in general want your brightblacks and
|
|
## strings to come last, because syntax highlighting rules will be
|
|
## applied in the order they are read in.
|
|
color constant.string ""(\\.|[^"])*""
|
|
##
|
|
## This string is VERY resource intensive!
|
|
#color cyan start=""(\\.|[^"])*\\[[:space:]]*$" end="^(\\.|[^"])*""
|
|
|
|
## Comment highlighting
|
|
color comment "//.*"
|
|
color comment start="/\*" end="\*/"
|
|
|
|
## Trailing whitespace
|
|
color indent-char.whitespace "[[:space:]]+$"
|