7
|
1 " Vim syntax support file
|
|
2 " Maintainer: Bram Moolenaar <Bram@vim.org>
|
19404
|
3 " Last Change: 2020 Feb 13
|
7
|
4
|
|
5 " This file sets up the default methods for highlighting.
|
|
6 " It is loaded from "synload.vim" and from Vim for ":syntax reset".
|
|
7 " Also used from init_highlight().
|
|
8
|
|
9 if !exists("syntax_cmd") || syntax_cmd == "on"
|
|
10 " ":syntax on" works like in Vim 5.7: set colors but keep links
|
|
11 command -nargs=* SynColor hi <args>
|
|
12 command -nargs=* SynLink hi link <args>
|
|
13 else
|
|
14 if syntax_cmd == "enable"
|
|
15 " ":syntax enable" keeps any existing colors
|
|
16 command -nargs=* SynColor hi def <args>
|
|
17 command -nargs=* SynLink hi def link <args>
|
|
18 elseif syntax_cmd == "reset"
|
|
19 " ":syntax reset" resets all colors to the default
|
|
20 command -nargs=* SynColor hi <args>
|
|
21 command -nargs=* SynLink hi! link <args>
|
|
22 else
|
|
23 " User defined syncolor file has already set the colors.
|
|
24 finish
|
|
25 endif
|
|
26 endif
|
|
27
|
|
28 " Many terminals can only use six different colors (plus black and white).
|
|
29 " Therefore the number of colors used is kept low. It doesn't look nice with
|
|
30 " too many colors anyway.
|
|
31 " Careful with "cterm=bold", it changes the color to bright for some terminals.
|
|
32 " There are two sets of defaults: for a dark and a light background.
|
|
33 if &background == "dark"
|
|
34 SynColor Comment term=bold cterm=NONE ctermfg=Cyan ctermbg=NONE gui=NONE guifg=#80a0ff guibg=NONE
|
|
35 SynColor Constant term=underline cterm=NONE ctermfg=Magenta ctermbg=NONE gui=NONE guifg=#ffa0a0 guibg=NONE
|
|
36 SynColor Special term=bold cterm=NONE ctermfg=LightRed ctermbg=NONE gui=NONE guifg=Orange guibg=NONE
|
|
37 SynColor Identifier term=underline cterm=bold ctermfg=Cyan ctermbg=NONE gui=NONE guifg=#40ffff guibg=NONE
|
|
38 SynColor Statement term=bold cterm=NONE ctermfg=Yellow ctermbg=NONE gui=bold guifg=#ffff60 guibg=NONE
|
|
39 SynColor PreProc term=underline cterm=NONE ctermfg=LightBlue ctermbg=NONE gui=NONE guifg=#ff80ff guibg=NONE
|
|
40 SynColor Type term=underline cterm=NONE ctermfg=LightGreen ctermbg=NONE gui=bold guifg=#60ff60 guibg=NONE
|
|
41 SynColor Underlined term=underline cterm=underline ctermfg=LightBlue gui=underline guifg=#80a0ff
|
|
42 SynColor Ignore term=NONE cterm=NONE ctermfg=black ctermbg=NONE gui=NONE guifg=bg guibg=NONE
|
|
43 else
|
|
44 SynColor Comment term=bold cterm=NONE ctermfg=DarkBlue ctermbg=NONE gui=NONE guifg=Blue guibg=NONE
|
|
45 SynColor Constant term=underline cterm=NONE ctermfg=DarkRed ctermbg=NONE gui=NONE guifg=Magenta guibg=NONE
|
19404
|
46 " #6a5acd is SlateBlue
|
|
47 SynColor Special term=bold cterm=NONE ctermfg=DarkMagenta ctermbg=NONE gui=NONE guifg=#6a5acd guibg=NONE
|
7
|
48 SynColor Identifier term=underline cterm=NONE ctermfg=DarkCyan ctermbg=NONE gui=NONE guifg=DarkCyan guibg=NONE
|
|
49 SynColor Statement term=bold cterm=NONE ctermfg=Brown ctermbg=NONE gui=bold guifg=Brown guibg=NONE
|
19404
|
50 " #6a0dad is Purple
|
|
51 SynColor PreProc term=underline cterm=NONE ctermfg=DarkMagenta ctermbg=NONE gui=NONE guifg=#6a0dad guibg=NONE
|
7
|
52 SynColor Type term=underline cterm=NONE ctermfg=DarkGreen ctermbg=NONE gui=bold guifg=SeaGreen guibg=NONE
|
|
53 SynColor Underlined term=underline cterm=underline ctermfg=DarkMagenta gui=underline guifg=SlateBlue
|
|
54 SynColor Ignore term=NONE cterm=NONE ctermfg=white ctermbg=NONE gui=NONE guifg=bg guibg=NONE
|
|
55 endif
|
|
56 SynColor Error term=reverse cterm=NONE ctermfg=White ctermbg=Red gui=NONE guifg=White guibg=Red
|
|
57 SynColor Todo term=standout cterm=NONE ctermfg=Black ctermbg=Yellow gui=NONE guifg=Blue guibg=Yellow
|
|
58
|
|
59 " Common groups that link to default highlighting.
|
|
60 " You can specify other highlighting easily.
|
|
61 SynLink String Constant
|
|
62 SynLink Character Constant
|
|
63 SynLink Number Constant
|
|
64 SynLink Boolean Constant
|
|
65 SynLink Float Number
|
|
66 SynLink Function Identifier
|
|
67 SynLink Conditional Statement
|
|
68 SynLink Repeat Statement
|
|
69 SynLink Label Statement
|
|
70 SynLink Operator Statement
|
|
71 SynLink Keyword Statement
|
|
72 SynLink Exception Statement
|
|
73 SynLink Include PreProc
|
|
74 SynLink Define PreProc
|
|
75 SynLink Macro PreProc
|
|
76 SynLink PreCondit PreProc
|
|
77 SynLink StorageClass Type
|
|
78 SynLink Structure Type
|
|
79 SynLink Typedef Type
|
|
80 SynLink Tag Special
|
|
81 SynLink SpecialChar Special
|
|
82 SynLink Delimiter Special
|
|
83 SynLink SpecialComment Special
|
|
84 SynLink Debug Special
|
|
85
|
|
86 delcommand SynColor
|
|
87 delcommand SynLink
|