]> git.r.bdr.sh - rbdr/dotfiles/blame_incremental - vim/colors/solarized.vim
Remove easymotion plugin
[rbdr/dotfiles] / vim / colors / solarized.vim
... / ...
CommitLineData
1" Name: Solarized vim colorscheme
2" Author: Ethan Schoonover <es@ethanschoonover.com>
3" URL: http://ethanschoonover.com/solarized
4" (see this url for latest release & screenshots)
5" License: OSI approved MIT license (see end of this file)
6" Created: In the middle of the night
7" Modified: 2011 May 05
8"
9" Usage "{{{
10"
11" ---------------------------------------------------------------------
12" ABOUT:
13" ---------------------------------------------------------------------
14" Solarized is a carefully designed selective contrast colorscheme with dual
15" light and dark modes that runs in both GUI, 256 and 16 color modes.
16"
17" See the homepage above for screenshots and details.
18"
19" ---------------------------------------------------------------------
20" OPTIONS:
21" ---------------------------------------------------------------------
22" See the "solarized.txt" help file included with this colorscheme (in the
23" "doc" subdirectory) for information on options, usage, the Toggle Background
24" function and more. If you have already installed Solarized, this is available
25" from the Solarized menu and command line as ":help solarized"
26"
27" ---------------------------------------------------------------------
28" INSTALLATION:
29" ---------------------------------------------------------------------
30" Two options for installation: manual or pathogen
31"
32" MANUAL INSTALLATION OPTION:
33" ---------------------------------------------------------------------
34"
35" 1. Download the solarized distribution (available on the homepage above)
36" and unarchive the file.
37" 2. Move `solarized.vim` to your `.vim/colors` directory.
38" 3. Move each of the files in each subdirectories to the corresponding .vim
39" subdirectory (e.g. autoload/togglebg.vim goes into your .vim/autoload
40" directory as .vim/autoload/togglebg.vim).
41"
42" RECOMMENDED PATHOGEN INSTALLATION OPTION:
43" ---------------------------------------------------------------------
44"
45" 1. Download and install Tim Pope's Pathogen from:
46" https://github.com/tpope/vim-pathogen
47"
48" 2. Next, move or clone the `vim-colors-solarized` directory so that it is
49" a subdirectory of the `.vim/bundle` directory.
50"
51" a. **clone with git:**
52"
53" $ cd ~/.vim/bundle
54" $ git clone git://github.com/altercation/vim-colors-solarized.git
55"
56" b. **or move manually into the pathogen bundle directory:**
57" In the parent directory of vim-colors-solarized:
58"
59" $ mv vim-colors-solarized ~/.vim/bundle/
60"
61" MODIFY VIMRC:
62"
63" After either Option 1 or Option 2 above, put the following two lines in your
64" .vimrc:
65"
66" syntax enable
67" set background=dark
68" colorscheme solarized
69"
70" or, for the light background mode of Solarized:
71"
72" syntax enable
73" set background=light
74" colorscheme solarized
75"
76" I like to have a different background in GUI and terminal modes, so I can use
77" the following if-then. However, I find vim's background autodetection to be
78" pretty good and, at least with MacVim, I can leave this background value
79" assignment out entirely and get the same results.
80"
81" if has('gui_running')
82" set background=light
83" else
84" set background=dark
85" endif
86"
87" See the Solarized homepage at http://ethanschoonover.com/solarized for
88" screenshots which will help you select either the light or dark background.
89"
90" ---------------------------------------------------------------------
91" COLOR VALUES
92" ---------------------------------------------------------------------
93" Download palettes and files from: http://ethanschoonover.com/solarized
94"
95" L\*a\*b values are canonical (White D65, Reference D50), other values are
96" matched in sRGB space.
97"
98" SOLARIZED HEX 16/8 TERMCOL XTERM/HEX L*A*B sRGB HSB
99" --------- ------- ---- ------- ----------- ---------- ----------- -----------
100" base03 #002b36 8/4 brblack 234 #1c1c1c 15 -12 -12 0 43 54 193 100 21
101" base02 #073642 0/4 black 235 #262626 20 -12 -12 7 54 66 192 90 26
102" base01 #586e75 10/7 brgreen 240 #4e4e4e 45 -07 -07 88 110 117 194 25 46
103" base00 #657b83 11/7 bryellow 241 #585858 50 -07 -07 101 123 131 195 23 51
104" base0 #839496 12/6 brblue 244 #808080 60 -06 -03 131 148 150 186 13 59
105" base1 #93a1a1 14/4 brcyan 245 #8a8a8a 65 -05 -02 147 161 161 180 9 63
106" base2 #eee8d5 7/7 white 254 #d7d7af 92 -00 10 238 232 213 44 11 93
107" base3 #fdf6e3 15/7 brwhite 230 #ffffd7 97 00 10 253 246 227 44 10 99
108" yellow #b58900 3/3 yellow 136 #af8700 60 10 65 181 137 0 45 100 71
109" orange #cb4b16 9/3 brred 166 #d75f00 50 50 55 203 75 22 18 89 80
110" red #dc322f 1/1 red 160 #d70000 50 65 45 220 50 47 1 79 86
111" magenta #d33682 5/5 magenta 125 #af005f 50 65 -05 211 54 130 331 74 83
112" violet #6c71c4 13/5 brmagenta 61 #5f5faf 50 15 -45 108 113 196 237 45 77
113" blue #268bd2 4/4 blue 33 #0087ff 55 -10 -45 38 139 210 205 82 82
114" cyan #2aa198 6/6 cyan 37 #00afaf 60 -35 -05 42 161 152 175 74 63
115" green #859900 2/2 green 64 #5f8700 60 -20 65 133 153 0 68 100 60
116"
117" ---------------------------------------------------------------------
118" COLORSCHEME HACKING
119" ---------------------------------------------------------------------
120"
121" Useful commands for testing colorschemes:
122" :source $VIMRUNTIME/syntax/hitest.vim
123" :help highlight-groups
124" :help cterm-colors
125" :help group-name
126"
127" Useful links for developing colorschemes:
128" http://www.vim.org/scripts/script.php?script_id=2937
129" http://vimcasts.org/episodes/creating-colorschemes-for-vim/
130" http://www.frexx.de/xterm-256-notes/"
131"
132" }}}
133" Environment Specific Overrides "{{{
134" Allow or disallow certain features based on current terminal emulator or
135" environment.
136
137" Terminals that support italics
138let s:terms_italic=[
139 \"rxvt",
140 \"gnome-terminal"
141 \]
142" For reference only, terminals are known to be incomptible.
143" Terminals that are in neither list need to be tested.
144let s:terms_noitalic=[
145 \"iTerm.app",
146 \"Apple_Terminal"
147 \]
148if has("gui_running")
149 let s:terminal_italic=1 " TODO: could refactor to not require this at all
150else
151 let s:terminal_italic=0 " terminals will be guilty until proven compatible
152 for term in s:terms_italic
153 if $TERM_PROGRAM =~ term
154 let s:terminal_italic=1
155 endif
156 endfor
157endif
158
159" }}}
160" Default option values"{{{
161" ---------------------------------------------------------------------
162" s:options_list is used to autogenerate a list of all non-default options
163" using "call SolarizedOptions()" or with the "Generate .vimrc commands"
164" Solarized menu option. See the "Menus" section below for the function itself.
165let s:options_list=[
166 \'" this block of commands has been autogenerated by solarized.vim and',
167 \'" includes the current, non-default Solarized option values.',
168 \'" To use, place these commands in your .vimrc file (replacing any',
169 \'" existing colorscheme commands). See also ":help solarized"',
170 \'',
171 \'" ------------------------------------------------------------------',
172 \'" Solarized Colorscheme Config',
173 \'" ------------------------------------------------------------------',
174 \]
175let s:colorscheme_list=[
176 \'syntax enable',
177 \'set background='.&background,
178 \'colorscheme solarized',
179 \]
180let s:defaults_list=[
181 \'" ------------------------------------------------------------------',
182 \'',
183 \'" The following items are available options, but do not need to be',
184 \'" included in your .vimrc as they are currently set to their defaults.',
185 \''
186 \]
187let s:lazycat_list=[
188 \'" lazy method of appending this onto your .vimrc ":w! >> ~/.vimrc"',
189 \'" ------------------------------------------------------------------',
190 \]
191
192function! s:SetOption(name,default)
193 if type(a:default) == type(0)
194 let l:wrap=''
195 let l:ewrap=''
196 else
197 let l:wrap='"'
198 let l:ewrap='\"'
199 endif
200 if !exists("g:solarized_".a:name) || g:solarized_{a:name}==a:default
201 exe 'let g:solarized_'.a:name.'='.l:wrap.a:default.l:wrap.'"'
202 exe 'call add(s:defaults_list, "\" let g:solarized_'.a:name.'='.l:ewrap.g:solarized_{a:name}.l:ewrap.'")'
203 else
204 exe 'call add(s:options_list, "let g:solarized_'.a:name.'='.l:ewrap.g:solarized_{a:name}.l:ewrap.' \"default value is '.a:default.'")'
205 endif
206endfunction
207
208if ($TERM_PROGRAM ==? "apple_terminal" && &t_Co < 256)
209 let s:solarized_termtrans_default = 1
210else
211 let s:solarized_termtrans_default = 0
212endif
213call s:SetOption("termtrans",s:solarized_termtrans_default)
214call s:SetOption("degrade",0)
215call s:SetOption("bold",1)
216call s:SetOption("underline",1)
217call s:SetOption("italic",1) " note that we need to override this later if the terminal doesn't support
218call s:SetOption("termcolors",16)
219call s:SetOption("contrast","normal")
220call s:SetOption("visibility","normal")
221call s:SetOption("diffmode","normal")
222call s:SetOption("hitrail",0)
223call s:SetOption("menu",1)
224
225"}}}
226" Colorscheme initialization "{{{
227" ---------------------------------------------------------------------
228hi clear
229if exists("syntax_on")
230 syntax reset
231endif
232let colors_name = "solarized"
233
234"}}}
235" GUI & CSApprox hexadecimal palettes"{{{
236" ---------------------------------------------------------------------
237"
238" Set both gui and terminal color values in separate conditional statements
239" Due to possibility that CSApprox is running (though I suppose we could just
240" leave the hex values out entirely in that case and include only cterm colors)
241" We also check to see if user has set solarized (force use of the
242" neutral gray monotone palette component)
243if (has("gui_running") && g:solarized_degrade == 0)
244 let s:vmode = "gui"
245 let s:base03 = "#002b36"
246 let s:base02 = "#073642"
247 let s:base01 = "#586e75"
248 let s:base00 = "#657b83"
249 let s:base0 = "#839496"
250 let s:base1 = "#93a1a1"
251 let s:base2 = "#eee8d5"
252 let s:base3 = "#fdf6e3"
253 let s:yellow = "#b58900"
254 let s:orange = "#cb4b16"
255 let s:red = "#dc322f"
256 let s:magenta = "#d33682"
257 let s:violet = "#6c71c4"
258 let s:blue = "#268bd2"
259 let s:cyan = "#2aa198"
260 "let s:green = "#859900" "original
261 let s:green = "#719e07" "experimental
262elseif (has("gui_running") && g:solarized_degrade == 1)
263 " These colors are identical to the 256 color mode. They may be viewed
264 " while in gui mode via "let g:solarized_degrade=1", though this is not
265 " recommened and is for testing only.
266 let s:vmode = "gui"
267 let s:base03 = "#1c1c1c"
268 let s:base02 = "#262626"
269 let s:base01 = "#4e4e4e"
270 let s:base00 = "#585858"
271 let s:base0 = "#808080"
272 let s:base1 = "#8a8a8a"
273 let s:base2 = "#d7d7af"
274 let s:base3 = "#ffffd7"
275 let s:yellow = "#af8700"
276 let s:orange = "#d75f00"
277 let s:red = "#af0000"
278 let s:magenta = "#af005f"
279 let s:violet = "#5f5faf"
280 let s:blue = "#0087ff"
281 let s:cyan = "#00afaf"
282 let s:green = "#5f8700"
283elseif g:solarized_termcolors != 256 && &t_Co >= 16
284 let s:vmode = "cterm"
285 let s:base03 = "8"
286 let s:base02 = "0"
287 let s:base01 = "10"
288 let s:base00 = "11"
289 let s:base0 = "12"
290 let s:base1 = "14"
291 let s:base2 = "7"
292 let s:base3 = "15"
293 let s:yellow = "3"
294 let s:orange = "9"
295 let s:red = "1"
296 let s:magenta = "5"
297 let s:violet = "13"
298 let s:blue = "4"
299 let s:cyan = "6"
300 let s:green = "2"
301elseif g:solarized_termcolors == 256
302 let s:vmode = "cterm"
303 let s:base03 = "234"
304 let s:base02 = "235"
305 let s:base01 = "239"
306 let s:base00 = "240"
307 let s:base0 = "244"
308 let s:base1 = "245"
309 let s:base2 = "187"
310 let s:base3 = "230"
311 let s:yellow = "136"
312 let s:orange = "166"
313 let s:red = "124"
314 let s:magenta = "125"
315 let s:violet = "61"
316 let s:blue = "33"
317 let s:cyan = "37"
318 let s:green = "64"
319else
320 let s:vmode = "cterm"
321 let s:bright = "* term=bold cterm=bold"
322" let s:base03 = "0".s:bright
323" let s:base02 = "0"
324" let s:base01 = "2".s:bright
325" let s:base00 = "3".s:bright
326" let s:base0 = "4".s:bright
327" let s:base1 = "6".s:bright
328" let s:base2 = "7"
329" let s:base3 = "7".s:bright
330" let s:yellow = "3"
331" let s:orange = "1".s:bright
332" let s:red = "1"
333" let s:magenta = "5"
334" let s:violet = "5".s:bright
335" let s:blue = "4"
336" let s:cyan = "6"
337" let s:green = "2"
338 let s:base03 = "DarkGray" " 0*
339 let s:base02 = "Black" " 0
340 let s:base01 = "LightGreen" " 2*
341 let s:base00 = "LightYellow" " 3*
342 let s:base0 = "LightBlue" " 4*
343 let s:base1 = "LightCyan" " 6*
344 let s:base2 = "LightGray" " 7
345 let s:base3 = "White" " 7*
346 let s:yellow = "DarkYellow" " 3
347 let s:orange = "LightRed" " 1*
348 let s:red = "DarkRed" " 1
349 let s:magenta = "DarkMagenta" " 5
350 let s:violet = "LightMagenta" " 5*
351 let s:blue = "DarkBlue" " 4
352 let s:cyan = "DarkCyan" " 6
353 let s:green = "DarkGreen" " 2
354
355endif
356"}}}
357" Formatting options and null values for passthrough effect "{{{
358" ---------------------------------------------------------------------
359 let s:none = "NONE"
360 let s:none = "NONE"
361 let s:t_none = "NONE"
362 let s:n = "NONE"
363 let s:c = ",undercurl"
364 let s:r = ",reverse"
365 let s:s = ",standout"
366 let s:ou = ""
367 let s:ob = ""
368"}}}
369" Background value based on termtrans setting "{{{
370" ---------------------------------------------------------------------
371if (has("gui_running") || g:solarized_termtrans == 0)
372 let s:back = s:base03
373else
374 let s:back = "NONE"
375endif
376"}}}
377" Alternate light scheme "{{{
378" ---------------------------------------------------------------------
379if &background == "light"
380 let s:temp03 = s:base03
381 let s:temp02 = s:base02
382 let s:temp01 = s:base01
383 let s:temp00 = s:base00
384 let s:base03 = s:base3
385 let s:base02 = s:base2
386 let s:base01 = s:base1
387 let s:base00 = s:base0
388 let s:base0 = s:temp00
389 let s:base1 = s:temp01
390 let s:base2 = s:temp02
391 let s:base3 = s:temp03
392 if (s:back != "NONE")
393 let s:back = s:base03
394 endif
395endif
396"}}}
397" Optional contrast schemes "{{{
398" ---------------------------------------------------------------------
399if g:solarized_contrast == "high"
400 let s:base01 = s:base00
401 let s:base00 = s:base0
402 let s:base0 = s:base1
403 let s:base1 = s:base2
404 let s:base2 = s:base3
405 let s:back = s:back
406endif
407if g:solarized_contrast == "low"
408 let s:back = s:base02
409 let s:ou = ",underline"
410endif
411"}}}
412" Overrides dependent on user specified values and environment "{{{
413" ---------------------------------------------------------------------
414if (g:solarized_bold == 0 || &t_Co == 8 )
415 let s:b = ""
416 let s:bb = ",bold"
417else
418 let s:b = ",bold"
419 let s:bb = ""
420endif
421
422if g:solarized_underline == 0
423 let s:u = ""
424else
425 let s:u = ",underline"
426endif
427
428if g:solarized_italic == 0 || s:terminal_italic == 0
429 let s:i = ""
430else
431 let s:i = ",italic"
432endif
433"}}}
434" Highlighting primitives"{{{
435" ---------------------------------------------------------------------
436
437exe "let s:bg_none = ' ".s:vmode."bg=".s:none ."'"
438exe "let s:bg_back = ' ".s:vmode."bg=".s:back ."'"
439exe "let s:bg_base03 = ' ".s:vmode."bg=".s:base03 ."'"
440exe "let s:bg_base02 = ' ".s:vmode."bg=".s:base02 ."'"
441exe "let s:bg_base01 = ' ".s:vmode."bg=".s:base01 ."'"
442exe "let s:bg_base00 = ' ".s:vmode."bg=".s:base00 ."'"
443exe "let s:bg_base0 = ' ".s:vmode."bg=".s:base0 ."'"
444exe "let s:bg_base1 = ' ".s:vmode."bg=".s:base1 ."'"
445exe "let s:bg_base2 = ' ".s:vmode."bg=".s:base2 ."'"
446exe "let s:bg_base3 = ' ".s:vmode."bg=".s:base3 ."'"
447exe "let s:bg_green = ' ".s:vmode."bg=".s:green ."'"
448exe "let s:bg_yellow = ' ".s:vmode."bg=".s:yellow ."'"
449exe "let s:bg_orange = ' ".s:vmode."bg=".s:orange ."'"
450exe "let s:bg_red = ' ".s:vmode."bg=".s:red ."'"
451exe "let s:bg_magenta = ' ".s:vmode."bg=".s:magenta."'"
452exe "let s:bg_violet = ' ".s:vmode."bg=".s:violet ."'"
453exe "let s:bg_blue = ' ".s:vmode."bg=".s:blue ."'"
454exe "let s:bg_cyan = ' ".s:vmode."bg=".s:cyan ."'"
455
456exe "let s:fg_none = ' ".s:vmode."fg=".s:none ."'"
457exe "let s:fg_back = ' ".s:vmode."fg=".s:back ."'"
458exe "let s:fg_base03 = ' ".s:vmode."fg=".s:base03 ."'"
459exe "let s:fg_base02 = ' ".s:vmode."fg=".s:base02 ."'"
460exe "let s:fg_base01 = ' ".s:vmode."fg=".s:base01 ."'"
461exe "let s:fg_base00 = ' ".s:vmode."fg=".s:base00 ."'"
462exe "let s:fg_base0 = ' ".s:vmode."fg=".s:base0 ."'"
463exe "let s:fg_base1 = ' ".s:vmode."fg=".s:base1 ."'"
464exe "let s:fg_base2 = ' ".s:vmode."fg=".s:base2 ."'"
465exe "let s:fg_base3 = ' ".s:vmode."fg=".s:base3 ."'"
466exe "let s:fg_green = ' ".s:vmode."fg=".s:green ."'"
467exe "let s:fg_yellow = ' ".s:vmode."fg=".s:yellow ."'"
468exe "let s:fg_orange = ' ".s:vmode."fg=".s:orange ."'"
469exe "let s:fg_red = ' ".s:vmode."fg=".s:red ."'"
470exe "let s:fg_magenta = ' ".s:vmode."fg=".s:magenta."'"
471exe "let s:fg_violet = ' ".s:vmode."fg=".s:violet ."'"
472exe "let s:fg_blue = ' ".s:vmode."fg=".s:blue ."'"
473exe "let s:fg_cyan = ' ".s:vmode."fg=".s:cyan ."'"
474
475exe "let s:fmt_none = ' ".s:vmode."=NONE". " term=NONE". "'"
476exe "let s:fmt_bold = ' ".s:vmode."=NONE".s:b. " term=NONE".s:b."'"
477exe "let s:fmt_bldi = ' ".s:vmode."=NONE".s:b. " term=NONE".s:b."'"
478exe "let s:fmt_undr = ' ".s:vmode."=NONE".s:u. " term=NONE".s:u."'"
479exe "let s:fmt_undb = ' ".s:vmode."=NONE".s:u.s:b. " term=NONE".s:u.s:b."'"
480exe "let s:fmt_undi = ' ".s:vmode."=NONE".s:u. " term=NONE".s:u."'"
481exe "let s:fmt_uopt = ' ".s:vmode."=NONE".s:ou. " term=NONE".s:ou."'"
482exe "let s:fmt_curl = ' ".s:vmode."=NONE".s:c. " term=NONE".s:c."'"
483exe "let s:fmt_ital = ' ".s:vmode."=NONE".s:i. " term=NONE".s:i."'"
484exe "let s:fmt_stnd = ' ".s:vmode."=NONE".s:s. " term=NONE".s:s."'"
485exe "let s:fmt_revr = ' ".s:vmode."=NONE".s:r. " term=NONE".s:r."'"
486exe "let s:fmt_revb = ' ".s:vmode."=NONE".s:r.s:b. " term=NONE".s:r.s:b."'"
487" revbb (reverse bold for bright colors) is only set to actual bold in low
488" color terminals (t_co=8, such as OS X Terminal.app) and should only be used
489" with colors 8-15.
490exe "let s:fmt_revbb = ' ".s:vmode."=NONE".s:r.s:bb. " term=NONE".s:r.s:bb."'"
491exe "let s:fmt_revbbu = ' ".s:vmode."=NONE".s:r.s:bb.s:u." term=NONE".s:r.s:bb.s:u."'"
492
493if has("gui_running")
494 exe "let s:sp_none = ' guisp=".s:none ."'"
495 exe "let s:sp_back = ' guisp=".s:back ."'"
496 exe "let s:sp_base03 = ' guisp=".s:base03 ."'"
497 exe "let s:sp_base02 = ' guisp=".s:base02 ."'"
498 exe "let s:sp_base01 = ' guisp=".s:base01 ."'"
499 exe "let s:sp_base00 = ' guisp=".s:base00 ."'"
500 exe "let s:sp_base0 = ' guisp=".s:base0 ."'"
501 exe "let s:sp_base1 = ' guisp=".s:base1 ."'"
502 exe "let s:sp_base2 = ' guisp=".s:base2 ."'"
503 exe "let s:sp_base3 = ' guisp=".s:base3 ."'"
504 exe "let s:sp_green = ' guisp=".s:green ."'"
505 exe "let s:sp_yellow = ' guisp=".s:yellow ."'"
506 exe "let s:sp_orange = ' guisp=".s:orange ."'"
507 exe "let s:sp_red = ' guisp=".s:red ."'"
508 exe "let s:sp_magenta = ' guisp=".s:magenta."'"
509 exe "let s:sp_violet = ' guisp=".s:violet ."'"
510 exe "let s:sp_blue = ' guisp=".s:blue ."'"
511 exe "let s:sp_cyan = ' guisp=".s:cyan ."'"
512else
513 let s:sp_none = ""
514 let s:sp_back = ""
515 let s:sp_base03 = ""
516 let s:sp_base02 = ""
517 let s:sp_base01 = ""
518 let s:sp_base00 = ""
519 let s:sp_base0 = ""
520 let s:sp_base1 = ""
521 let s:sp_base2 = ""
522 let s:sp_base3 = ""
523 let s:sp_green = ""
524 let s:sp_yellow = ""
525 let s:sp_orange = ""
526 let s:sp_red = ""
527 let s:sp_magenta = ""
528 let s:sp_violet = ""
529 let s:sp_blue = ""
530 let s:sp_cyan = ""
531endif
532
533"}}}
534" Basic highlighting"{{{
535" ---------------------------------------------------------------------
536" note that link syntax to avoid duplicate configuration doesn't work with the
537" exe compiled formats
538
539exe "hi! Normal" .s:fmt_none .s:fg_base0 .s:bg_back
540
541exe "hi! Comment" .s:fmt_ital .s:fg_base01 .s:bg_none
542" *Comment any comment
543
544exe "hi! Constant" .s:fmt_none .s:fg_cyan .s:bg_none
545" *Constant any constant
546" String a string constant: "this is a string"
547" Character a character constant: 'c', '\n'
548" Number a number constant: 234, 0xff
549" Boolean a boolean constant: TRUE, false
550" Float a floating point constant: 2.3e10
551
552exe "hi! Identifier" .s:fmt_none .s:fg_blue .s:bg_none
553" *Identifier any variable name
554" Function function name (also: methods for classes)
555"
556exe "hi! Statement" .s:fmt_none .s:fg_green .s:bg_none
557" *Statement any statement
558" Conditional if, then, else, endif, switch, etc.
559" Repeat for, do, while, etc.
560" Label case, default, etc.
561" Operator "sizeof", "+", "*", etc.
562" Keyword any other keyword
563" Exception try, catch, throw
564
565exe "hi! PreProc" .s:fmt_none .s:fg_orange .s:bg_none
566" *PreProc generic Preprocessor
567" Include preprocessor #include
568" Define preprocessor #define
569" Macro same as Define
570" PreCondit preprocessor #if, #else, #endif, etc.
571
572exe "hi! Type" .s:fmt_none .s:fg_yellow .s:bg_none
573" *Type int, long, char, etc.
574" StorageClass static, register, volatile, etc.
575" Structure struct, union, enum, etc.
576" Typedef A typedef
577
578exe "hi! Special" .s:fmt_none .s:fg_red .s:bg_none
579" *Special any special symbol
580" SpecialChar special character in a constant
581" Tag you can use CTRL-] on this
582" Delimiter character that needs attention
583" SpecialComment special things inside a comment
584" Debug debugging statements
585
586exe "hi! Underlined" .s:fmt_none .s:fg_violet .s:bg_none
587" *Underlined text that stands out, HTML links
588
589exe "hi! Ignore" .s:fmt_none .s:fg_none .s:bg_none
590" *Ignore left blank, hidden |hl-Ignore|
591
592exe "hi! Error" .s:fmt_bold .s:fg_red .s:bg_none
593" *Error any erroneous construct
594
595exe "hi! Todo" .s:fmt_bold .s:fg_magenta.s:bg_none
596" *Todo anything that needs extra attention; mostly the
597" keywords TODO FIXME and XXX
598"
599"}}}
600" Extended highlighting "{{{
601" ---------------------------------------------------------------------
602if (g:solarized_visibility=="high")
603 exe "hi! SpecialKey" .s:fmt_revr .s:fg_red .s:bg_none
604 exe "hi! NonText" .s:fmt_bold .s:fg_red .s:bg_none
605elseif (g:solarized_visibility=="low")
606 exe "hi! SpecialKey" .s:fmt_bold .s:fg_base02 .s:bg_none
607 exe "hi! NonText" .s:fmt_bold .s:fg_base02 .s:bg_none
608else
609 exe "hi! SpecialKey" .s:fmt_bold .s:fg_base00 .s:bg_base02
610 exe "hi! NonText" .s:fmt_bold .s:fg_base00 .s:bg_none
611endif
612exe "hi! StatusLine" .s:fmt_none .s:fg_base1 .s:bg_base02 .s:fmt_revbb
613exe "hi! StatusLineNC" .s:fmt_none .s:fg_base00 .s:bg_base02 .s:fmt_revbb
614exe "hi! Visual" .s:fmt_none .s:fg_base01 .s:bg_base03 .s:fmt_revbb
615exe "hi! Directory" .s:fmt_none .s:fg_blue .s:bg_none
616exe "hi! ErrorMsg" .s:fmt_revr .s:fg_red .s:bg_none
617exe "hi! IncSearch" .s:fmt_stnd .s:fg_orange .s:bg_none
618exe "hi! Search" .s:fmt_revr .s:fg_yellow .s:bg_none
619exe "hi! MoreMsg" .s:fmt_none .s:fg_blue .s:bg_none
620exe "hi! ModeMsg" .s:fmt_none .s:fg_blue .s:bg_none
621exe "hi! LineNr" .s:fmt_none .s:fg_base01 .s:bg_base02
622exe "hi! Question" .s:fmt_bold .s:fg_cyan .s:bg_none
623if ( has("gui_running") || &t_Co > 8 )
624 exe "hi! VertSplit" .s:fmt_none .s:fg_base00 .s:bg_base00
625else
626 exe "hi! VertSplit" .s:fmt_revbb .s:fg_base00 .s:bg_base02
627endif
628exe "hi! Title" .s:fmt_bold .s:fg_orange .s:bg_none
629exe "hi! VisualNOS" .s:fmt_stnd .s:fg_none .s:bg_base02 .s:fmt_revbb
630exe "hi! WarningMsg" .s:fmt_bold .s:fg_red .s:bg_none
631exe "hi! WildMenu" .s:fmt_none .s:fg_base2 .s:bg_base02 .s:fmt_revbb
632exe "hi! Folded" .s:fmt_undb .s:fg_base0 .s:bg_base02 .s:sp_base03
633exe "hi! FoldColumn" .s:fmt_none .s:fg_base0 .s:bg_base02
634if (g:solarized_diffmode=="high")
635exe "hi! DiffAdd" .s:fmt_revr .s:fg_green .s:bg_none
636exe "hi! DiffChange" .s:fmt_revr .s:fg_yellow .s:bg_none
637exe "hi! DiffDelete" .s:fmt_revr .s:fg_red .s:bg_none
638exe "hi! DiffText" .s:fmt_revr .s:fg_blue .s:bg_none
639elseif (g:solarized_diffmode=="low")
640exe "hi! DiffAdd" .s:fmt_undr .s:fg_green .s:bg_none .s:sp_green
641exe "hi! DiffChange" .s:fmt_undr .s:fg_yellow .s:bg_none .s:sp_yellow
642exe "hi! DiffDelete" .s:fmt_bold .s:fg_red .s:bg_none
643exe "hi! DiffText" .s:fmt_undr .s:fg_blue .s:bg_none .s:sp_blue
644else " normal
645 if has("gui_running")
646exe "hi! DiffAdd" .s:fmt_bold .s:fg_green .s:bg_base02 .s:sp_green
647exe "hi! DiffChange" .s:fmt_bold .s:fg_yellow .s:bg_base02 .s:sp_yellow
648exe "hi! DiffDelete" .s:fmt_bold .s:fg_red .s:bg_base02
649exe "hi! DiffText" .s:fmt_bold .s:fg_blue .s:bg_base02 .s:sp_blue
650 else
651exe "hi! DiffAdd" .s:fmt_none .s:fg_green .s:bg_base02 .s:sp_green
652exe "hi! DiffChange" .s:fmt_none .s:fg_yellow .s:bg_base02 .s:sp_yellow
653exe "hi! DiffDelete" .s:fmt_none .s:fg_red .s:bg_base02
654exe "hi! DiffText" .s:fmt_none .s:fg_blue .s:bg_base02 .s:sp_blue
655 endif
656endif
657exe "hi! SignColumn" .s:fmt_none .s:fg_base0
658exe "hi! Conceal" .s:fmt_none .s:fg_blue .s:bg_none
659exe "hi! SpellBad" .s:fmt_curl .s:fg_none .s:bg_none .s:sp_red
660exe "hi! SpellCap" .s:fmt_curl .s:fg_none .s:bg_none .s:sp_violet
661exe "hi! SpellRare" .s:fmt_curl .s:fg_none .s:bg_none .s:sp_cyan
662exe "hi! SpellLocal" .s:fmt_curl .s:fg_none .s:bg_none .s:sp_yellow
663exe "hi! Pmenu" .s:fmt_none .s:fg_base0 .s:bg_base02 .s:fmt_revbb
664exe "hi! PmenuSel" .s:fmt_none .s:fg_base01 .s:bg_base2 .s:fmt_revbb
665exe "hi! PmenuSbar" .s:fmt_none .s:fg_base2 .s:bg_base0 .s:fmt_revbb
666exe "hi! PmenuThumb" .s:fmt_none .s:fg_base0 .s:bg_base03 .s:fmt_revbb
667exe "hi! TabLine" .s:fmt_undr .s:fg_base0 .s:bg_base02 .s:sp_base0
668exe "hi! TabLineFill" .s:fmt_undr .s:fg_base0 .s:bg_base02 .s:sp_base0
669exe "hi! TabLineSel" .s:fmt_undr .s:fg_base01 .s:bg_base2 .s:sp_base0 .s:fmt_revbbu
670exe "hi! CursorColumn" .s:fmt_none .s:fg_none .s:bg_base02
671exe "hi! CursorLine" .s:fmt_uopt .s:fg_none .s:bg_base02 .s:sp_base1
672exe "hi! ColorColumn" .s:fmt_none .s:fg_none .s:bg_base02
673exe "hi! Cursor" .s:fmt_none .s:fg_base03 .s:bg_base0
674hi! link lCursor Cursor
675exe "hi! MatchParen" .s:fmt_bold .s:fg_red .s:bg_base01
676
677"}}}
678" vim syntax highlighting "{{{
679" ---------------------------------------------------------------------
680"exe "hi! vimLineComment" . s:fg_base01 .s:bg_none .s:fmt_ital
681"hi! link vimComment Comment
682"hi! link vimLineComment Comment
683hi! link vimVar Identifier
684hi! link vimFunc Function
685hi! link vimUserFunc Function
686hi! link helpSpecial Special
687hi! link vimSet Normal
688hi! link vimSetEqual Normal
689exe "hi! vimCommentString" .s:fmt_none .s:fg_violet .s:bg_none
690exe "hi! vimCommand" .s:fmt_none .s:fg_yellow .s:bg_none
691exe "hi! vimCmdSep" .s:fmt_bold .s:fg_blue .s:bg_none
692exe "hi! helpExample" .s:fmt_none .s:fg_base1 .s:bg_none
693exe "hi! helpOption" .s:fmt_none .s:fg_cyan .s:bg_none
694exe "hi! helpNote" .s:fmt_none .s:fg_magenta.s:bg_none
695exe "hi! helpVim" .s:fmt_none .s:fg_magenta.s:bg_none
696exe "hi! helpHyperTextJump" .s:fmt_undr .s:fg_blue .s:bg_none
697exe "hi! helpHyperTextEntry".s:fmt_none .s:fg_green .s:bg_none
698exe "hi! vimIsCommand" .s:fmt_none .s:fg_base00 .s:bg_none
699exe "hi! vimSynMtchOpt" .s:fmt_none .s:fg_yellow .s:bg_none
700exe "hi! vimSynType" .s:fmt_none .s:fg_cyan .s:bg_none
701exe "hi! vimHiLink" .s:fmt_none .s:fg_blue .s:bg_none
702exe "hi! vimHiGroup" .s:fmt_none .s:fg_blue .s:bg_none
703exe "hi! vimGroup" .s:fmt_undb .s:fg_blue .s:bg_none
704"}}}
705" diff highlighting "{{{
706" ---------------------------------------------------------------------
707hi! link diffAdded Statement
708hi! link diffLine Identifier
709"}}}
710" git & gitcommit highlighting "{{{
711"git
712"exe "hi! gitDateHeader"
713"exe "hi! gitIdentityHeader"
714"exe "hi! gitIdentityKeyword"
715"exe "hi! gitNotesHeader"
716"exe "hi! gitReflogHeader"
717"exe "hi! gitKeyword"
718"exe "hi! gitIdentity"
719"exe "hi! gitEmailDelimiter"
720"exe "hi! gitEmail"
721"exe "hi! gitDate"
722"exe "hi! gitMode"
723"exe "hi! gitHashAbbrev"
724"exe "hi! gitHash"
725"exe "hi! gitReflogMiddle"
726"exe "hi! gitReference"
727"exe "hi! gitStage"
728"exe "hi! gitType"
729"exe "hi! gitDiffAdded"
730"exe "hi! gitDiffRemoved"
731"gitcommit
732"exe "hi! gitcommitSummary"
733exe "hi! gitcommitComment" .s:fmt_ital .s:fg_base01 .s:bg_none
734hi! link gitcommitUntracked gitcommitComment
735hi! link gitcommitDiscarded gitcommitComment
736hi! link gitcommitSelected gitcommitComment
737exe "hi! gitcommitUnmerged" .s:fmt_bold .s:fg_green .s:bg_none
738exe "hi! gitcommitOnBranch" .s:fmt_bold .s:fg_base01 .s:bg_none
739exe "hi! gitcommitBranch" .s:fmt_bold .s:fg_magenta .s:bg_none
740hi! link gitcommitNoBranch gitcommitBranch
741exe "hi! gitcommitDiscardedType".s:fmt_none .s:fg_red .s:bg_none
742exe "hi! gitcommitSelectedType" .s:fmt_none .s:fg_green .s:bg_none
743"exe "hi! gitcommitUnmergedType"
744"exe "hi! gitcommitType"
745"exe "hi! gitcommitNoChanges"
746"exe "hi! gitcommitHeader"
747exe "hi! gitcommitHeader" .s:fmt_none .s:fg_base01 .s:bg_none
748exe "hi! gitcommitUntrackedFile".s:fmt_bold .s:fg_cyan .s:bg_none
749exe "hi! gitcommitDiscardedFile".s:fmt_bold .s:fg_red .s:bg_none
750exe "hi! gitcommitSelectedFile" .s:fmt_bold .s:fg_green .s:bg_none
751exe "hi! gitcommitUnmergedFile" .s:fmt_bold .s:fg_yellow .s:bg_none
752exe "hi! gitcommitFile" .s:fmt_bold .s:fg_base0 .s:bg_none
753hi! link gitcommitDiscardedArrow gitcommitDiscardedFile
754hi! link gitcommitSelectedArrow gitcommitSelectedFile
755hi! link gitcommitUnmergedArrow gitcommitUnmergedFile
756"exe "hi! gitcommitArrow"
757"exe "hi! gitcommitOverflow"
758"exe "hi! gitcommitBlank"
759" }}}
760" html highlighting "{{{
761" ---------------------------------------------------------------------
762exe "hi! htmlTag" .s:fmt_none .s:fg_base01 .s:bg_none
763exe "hi! htmlEndTag" .s:fmt_none .s:fg_base01 .s:bg_none
764exe "hi! htmlTagN" .s:fmt_bold .s:fg_base1 .s:bg_none
765exe "hi! htmlTagName" .s:fmt_bold .s:fg_blue .s:bg_none
766exe "hi! htmlSpecialTagName".s:fmt_ital .s:fg_blue .s:bg_none
767exe "hi! htmlArg" .s:fmt_none .s:fg_base00 .s:bg_none
768exe "hi! javaScript" .s:fmt_none .s:fg_yellow .s:bg_none
769"}}}
770" perl highlighting "{{{
771" ---------------------------------------------------------------------
772exe "hi! perlHereDoc" . s:fg_base1 .s:bg_back .s:fmt_none
773exe "hi! perlVarPlain" . s:fg_yellow .s:bg_back .s:fmt_none
774exe "hi! perlStatementFileDesc". s:fg_cyan.s:bg_back.s:fmt_none
775
776"}}}
777" tex highlighting "{{{
778" ---------------------------------------------------------------------
779exe "hi! texStatement" . s:fg_cyan .s:bg_back .s:fmt_none
780exe "hi! texMathZoneX" . s:fg_yellow .s:bg_back .s:fmt_none
781exe "hi! texMathMatcher" . s:fg_yellow .s:bg_back .s:fmt_none
782exe "hi! texMathMatcher" . s:fg_yellow .s:bg_back .s:fmt_none
783exe "hi! texRefLabel" . s:fg_yellow .s:bg_back .s:fmt_none
784"}}}
785" ruby highlighting "{{{
786" ---------------------------------------------------------------------
787exe "hi! rubyDefine" . s:fg_base1 .s:bg_back .s:fmt_bold
788"rubyInclude
789"rubySharpBang
790"rubyAccess
791"rubyPredefinedVariable
792"rubyBoolean
793"rubyClassVariable
794"rubyBeginEnd
795"rubyRepeatModifier
796"hi! link rubyArrayDelimiter Special " [ , , ]
797"rubyCurlyBlock { , , }
798
799"hi! link rubyClass Keyword
800"hi! link rubyModule Keyword
801"hi! link rubyKeyword Keyword
802"hi! link rubyOperator Operator
803"hi! link rubyIdentifier Identifier
804"hi! link rubyInstanceVariable Identifier
805"hi! link rubyGlobalVariable Identifier
806"hi! link rubyClassVariable Identifier
807"hi! link rubyConstant Type
808"}}}
809" haskell syntax highlighting"{{{
810" ---------------------------------------------------------------------
811" For use with syntax/haskell.vim : Haskell Syntax File
812" http://www.vim.org/scripts/script.php?script_id=3034
813" See also Steffen Siering's github repository:
814" http://github.com/urso/dotrc/blob/master/vim/syntax/haskell.vim
815" ---------------------------------------------------------------------
816"
817" Treat True and False specially, see the plugin referenced above
818let hs_highlight_boolean=1
819" highlight delims, see the plugin referenced above
820let hs_highlight_delimiters=1
821
822exe "hi! cPreCondit". s:fg_orange.s:bg_none .s:fmt_none
823
824exe "hi! VarId" . s:fg_blue .s:bg_none .s:fmt_none
825exe "hi! ConId" . s:fg_yellow .s:bg_none .s:fmt_none
826exe "hi! hsImport" . s:fg_magenta.s:bg_none .s:fmt_none
827exe "hi! hsString" . s:fg_base00 .s:bg_none .s:fmt_none
828
829exe "hi! hsStructure" . s:fg_cyan .s:bg_none .s:fmt_none
830exe "hi! hs_hlFunctionName" . s:fg_blue .s:bg_none
831exe "hi! hsStatement" . s:fg_cyan .s:bg_none .s:fmt_none
832exe "hi! hsImportLabel" . s:fg_cyan .s:bg_none .s:fmt_none
833exe "hi! hs_OpFunctionName" . s:fg_yellow .s:bg_none .s:fmt_none
834exe "hi! hs_DeclareFunction" . s:fg_orange .s:bg_none .s:fmt_none
835exe "hi! hsVarSym" . s:fg_cyan .s:bg_none .s:fmt_none
836exe "hi! hsType" . s:fg_yellow .s:bg_none .s:fmt_none
837exe "hi! hsTypedef" . s:fg_cyan .s:bg_none .s:fmt_none
838exe "hi! hsModuleName" . s:fg_green .s:bg_none .s:fmt_undr
839exe "hi! hsModuleStartLabel" . s:fg_magenta.s:bg_none .s:fmt_none
840hi! link hsImportParams Delimiter
841hi! link hsDelimTypeExport Delimiter
842hi! link hsModuleStartLabel hsStructure
843hi! link hsModuleWhereLabel hsModuleStartLabel
844
845" following is for the haskell-conceal plugin
846" the first two items don't have an impact, but better safe
847exe "hi! hsNiceOperator" . s:fg_cyan .s:bg_none .s:fmt_none
848exe "hi! hsniceoperator" . s:fg_cyan .s:bg_none .s:fmt_none
849
850"}}}
851" pandoc markdown syntax highlighting "{{{
852" ---------------------------------------------------------------------
853
854"PandocHiLink pandocNormalBlock
855exe "hi! pandocTitleBlock" .s:fg_blue .s:bg_none .s:fmt_none
856exe "hi! pandocTitleBlockTitle" .s:fg_blue .s:bg_none .s:fmt_bold
857exe "hi! pandocTitleComment" .s:fg_blue .s:bg_none .s:fmt_bold
858exe "hi! pandocComment" .s:fg_base01 .s:bg_none .s:fmt_ital
859exe "hi! pandocVerbatimBlock" .s:fg_yellow .s:bg_none .s:fmt_none
860hi! link pandocVerbatimBlockDeep pandocVerbatimBlock
861hi! link pandocCodeBlock pandocVerbatimBlock
862hi! link pandocCodeBlockDelim pandocVerbatimBlock
863exe "hi! pandocBlockQuote" .s:fg_blue .s:bg_none .s:fmt_none
864exe "hi! pandocBlockQuoteLeader1" .s:fg_blue .s:bg_none .s:fmt_none
865exe "hi! pandocBlockQuoteLeader2" .s:fg_cyan .s:bg_none .s:fmt_none
866exe "hi! pandocBlockQuoteLeader3" .s:fg_yellow .s:bg_none .s:fmt_none
867exe "hi! pandocBlockQuoteLeader4" .s:fg_red .s:bg_none .s:fmt_none
868exe "hi! pandocBlockQuoteLeader5" .s:fg_base0 .s:bg_none .s:fmt_none
869exe "hi! pandocBlockQuoteLeader6" .s:fg_base01 .s:bg_none .s:fmt_none
870exe "hi! pandocListMarker" .s:fg_magenta.s:bg_none .s:fmt_none
871exe "hi! pandocListReference" .s:fg_magenta.s:bg_none .s:fmt_undr
872
873" Definitions
874" ---------------------------------------------------------------------
875let s:fg_pdef = s:fg_violet
876exe "hi! pandocDefinitionBlock" .s:fg_pdef .s:bg_none .s:fmt_none
877exe "hi! pandocDefinitionTerm" .s:fg_pdef .s:bg_none .s:fmt_stnd
878exe "hi! pandocDefinitionIndctr" .s:fg_pdef .s:bg_none .s:fmt_bold
879exe "hi! pandocEmphasisDefinition" .s:fg_pdef .s:bg_none .s:fmt_ital
880exe "hi! pandocEmphasisNestedDefinition" .s:fg_pdef .s:bg_none .s:fmt_bldi
881exe "hi! pandocStrongEmphasisDefinition" .s:fg_pdef .s:bg_none .s:fmt_bold
882exe "hi! pandocStrongEmphasisNestedDefinition" .s:fg_pdef.s:bg_none.s:fmt_bldi
883exe "hi! pandocStrongEmphasisEmphasisDefinition" .s:fg_pdef.s:bg_none.s:fmt_bldi
884exe "hi! pandocStrikeoutDefinition" .s:fg_pdef .s:bg_none .s:fmt_revr
885exe "hi! pandocVerbatimInlineDefinition" .s:fg_pdef .s:bg_none .s:fmt_none
886exe "hi! pandocSuperscriptDefinition" .s:fg_pdef .s:bg_none .s:fmt_none
887exe "hi! pandocSubscriptDefinition" .s:fg_pdef .s:bg_none .s:fmt_none
888
889" Tables
890" ---------------------------------------------------------------------
891let s:fg_ptable = s:fg_blue
892exe "hi! pandocTable" .s:fg_ptable.s:bg_none .s:fmt_none
893exe "hi! pandocTableStructure" .s:fg_ptable.s:bg_none .s:fmt_none
894hi! link pandocTableStructureTop pandocTableStructre
895hi! link pandocTableStructureEnd pandocTableStructre
896exe "hi! pandocTableZebraLight" .s:fg_ptable.s:bg_base03.s:fmt_none
897exe "hi! pandocTableZebraDark" .s:fg_ptable.s:bg_base02.s:fmt_none
898exe "hi! pandocEmphasisTable" .s:fg_ptable.s:bg_none .s:fmt_ital
899exe "hi! pandocEmphasisNestedTable" .s:fg_ptable.s:bg_none .s:fmt_bldi
900exe "hi! pandocStrongEmphasisTable" .s:fg_ptable.s:bg_none .s:fmt_bold
901exe "hi! pandocStrongEmphasisNestedTable" .s:fg_ptable.s:bg_none .s:fmt_bldi
902exe "hi! pandocStrongEmphasisEmphasisTable" .s:fg_ptable.s:bg_none .s:fmt_bldi
903exe "hi! pandocStrikeoutTable" .s:fg_ptable.s:bg_none .s:fmt_revr
904exe "hi! pandocVerbatimInlineTable" .s:fg_ptable.s:bg_none .s:fmt_none
905exe "hi! pandocSuperscriptTable" .s:fg_ptable.s:bg_none .s:fmt_none
906exe "hi! pandocSubscriptTable" .s:fg_ptable.s:bg_none .s:fmt_none
907
908" Headings
909" ---------------------------------------------------------------------
910let s:fg_phead = s:fg_orange
911exe "hi! pandocHeading" .s:fg_phead .s:bg_none.s:fmt_bold
912exe "hi! pandocHeadingMarker" .s:fg_yellow.s:bg_none.s:fmt_bold
913exe "hi! pandocEmphasisHeading" .s:fg_phead .s:bg_none.s:fmt_bldi
914exe "hi! pandocEmphasisNestedHeading" .s:fg_phead .s:bg_none.s:fmt_bldi
915exe "hi! pandocStrongEmphasisHeading" .s:fg_phead .s:bg_none.s:fmt_bold
916exe "hi! pandocStrongEmphasisNestedHeading" .s:fg_phead .s:bg_none.s:fmt_bldi
917exe "hi! pandocStrongEmphasisEmphasisHeading".s:fg_phead .s:bg_none.s:fmt_bldi
918exe "hi! pandocStrikeoutHeading" .s:fg_phead .s:bg_none.s:fmt_revr
919exe "hi! pandocVerbatimInlineHeading" .s:fg_phead .s:bg_none.s:fmt_bold
920exe "hi! pandocSuperscriptHeading" .s:fg_phead .s:bg_none.s:fmt_bold
921exe "hi! pandocSubscriptHeading" .s:fg_phead .s:bg_none.s:fmt_bold
922
923" Links
924" ---------------------------------------------------------------------
925exe "hi! pandocLinkDelim" .s:fg_base01 .s:bg_none .s:fmt_none
926exe "hi! pandocLinkLabel" .s:fg_blue .s:bg_none .s:fmt_undr
927exe "hi! pandocLinkText" .s:fg_blue .s:bg_none .s:fmt_undb
928exe "hi! pandocLinkURL" .s:fg_base00 .s:bg_none .s:fmt_undr
929exe "hi! pandocLinkTitle" .s:fg_base00 .s:bg_none .s:fmt_undi
930exe "hi! pandocLinkTitleDelim" .s:fg_base01 .s:bg_none .s:fmt_undi .s:sp_base00
931exe "hi! pandocLinkDefinition" .s:fg_cyan .s:bg_none .s:fmt_undr .s:sp_base00
932exe "hi! pandocLinkDefinitionID" .s:fg_blue .s:bg_none .s:fmt_bold
933exe "hi! pandocImageCaption" .s:fg_violet .s:bg_none .s:fmt_undb
934exe "hi! pandocFootnoteLink" .s:fg_green .s:bg_none .s:fmt_undr
935exe "hi! pandocFootnoteDefLink" .s:fg_green .s:bg_none .s:fmt_bold
936exe "hi! pandocFootnoteInline" .s:fg_green .s:bg_none .s:fmt_undb
937exe "hi! pandocFootnote" .s:fg_green .s:bg_none .s:fmt_none
938exe "hi! pandocCitationDelim" .s:fg_magenta.s:bg_none .s:fmt_none
939exe "hi! pandocCitation" .s:fg_magenta.s:bg_none .s:fmt_none
940exe "hi! pandocCitationID" .s:fg_magenta.s:bg_none .s:fmt_undr
941exe "hi! pandocCitationRef" .s:fg_magenta.s:bg_none .s:fmt_none
942
943" Main Styles
944" ---------------------------------------------------------------------
945exe "hi! pandocStyleDelim" .s:fg_base01 .s:bg_none .s:fmt_none
946exe "hi! pandocEmphasis" .s:fg_base0 .s:bg_none .s:fmt_ital
947exe "hi! pandocEmphasisNested" .s:fg_base0 .s:bg_none .s:fmt_bldi
948exe "hi! pandocStrongEmphasis" .s:fg_base0 .s:bg_none .s:fmt_bold
949exe "hi! pandocStrongEmphasisNested" .s:fg_base0 .s:bg_none .s:fmt_bldi
950exe "hi! pandocStrongEmphasisEmphasis" .s:fg_base0 .s:bg_none .s:fmt_bldi
951exe "hi! pandocStrikeout" .s:fg_base01 .s:bg_none .s:fmt_revr
952exe "hi! pandocVerbatimInline" .s:fg_yellow .s:bg_none .s:fmt_none
953exe "hi! pandocSuperscript" .s:fg_violet .s:bg_none .s:fmt_none
954exe "hi! pandocSubscript" .s:fg_violet .s:bg_none .s:fmt_none
955
956exe "hi! pandocRule" .s:fg_blue .s:bg_none .s:fmt_bold
957exe "hi! pandocRuleLine" .s:fg_blue .s:bg_none .s:fmt_bold
958exe "hi! pandocEscapePair" .s:fg_red .s:bg_none .s:fmt_bold
959exe "hi! pandocCitationRef" .s:fg_magenta.s:bg_none .s:fmt_none
960exe "hi! pandocNonBreakingSpace" . s:fg_red .s:bg_none .s:fmt_revr
961hi! link pandocEscapedCharacter pandocEscapePair
962hi! link pandocLineBreak pandocEscapePair
963
964" Embedded Code
965" ---------------------------------------------------------------------
966exe "hi! pandocMetadataDelim" .s:fg_base01 .s:bg_none .s:fmt_none
967exe "hi! pandocMetadata" .s:fg_blue .s:bg_none .s:fmt_none
968exe "hi! pandocMetadataKey" .s:fg_blue .s:bg_none .s:fmt_none
969exe "hi! pandocMetadata" .s:fg_blue .s:bg_none .s:fmt_bold
970hi! link pandocMetadataTitle pandocMetadata
971
972"}}}
973" Utility autocommand "{{{
974" ---------------------------------------------------------------------
975" In cases where Solarized is initialized inside a terminal vim session and
976" then transferred to a gui session via the command `:gui`, the gui vim process
977" does not re-read the colorscheme (or .vimrc for that matter) so any `has_gui`
978" related code that sets gui specific values isn't executed.
979"
980" Currently, Solarized sets only the cterm or gui values for the colorscheme
981" depending on gui or terminal mode. It's possible that, if the following
982" autocommand method is deemed excessively poor form, that approach will be
983" used again and the autocommand below will be dropped.
984"
985" However it seems relatively benign in this case to include the autocommand
986" here. It fires only in cases where vim is transferring from terminal to gui
987" mode (detected with the script scope s:vmode variable). It also allows for
988" other potential terminal customizations that might make gui mode suboptimal.
989"
990autocmd GUIEnter * if (s:vmode != "gui") | exe "colorscheme " . g:colors_name | endif
991"}}}
992" Highlight Trailing Space {{{
993" Experimental: Different highlight when on cursorline
994function! s:SolarizedHiTrail()
995 if g:solarized_hitrail==0
996 hi! clear solarizedTrailingSpace
997 else
998 syn match solarizedTrailingSpace "\s*$"
999 exe "hi! solarizedTrailingSpace " .s:fmt_undr .s:fg_red .s:bg_none .s:sp_red
1000 endif
1001endfunction
1002augroup SolarizedHiTrail
1003 autocmd!
1004 if g:solarized_hitrail==1
1005 autocmd! Syntax * call s:SolarizedHiTrail()
1006 autocmd! ColorScheme * if g:colors_name == "solarized" | call s:SolarizedHiTrail() | else | augroup! s:SolarizedHiTrail | endif
1007 endif
1008augroup END
1009" }}}
1010" Menus "{{{
1011" ---------------------------------------------------------------------
1012" Turn off Solarized menu by including the following assignment in your .vimrc:
1013"
1014" let g:solarized_menu=0
1015
1016function! s:SolarizedOptions()
1017 new "new buffer
1018 setf vim "vim filetype
1019 let failed = append(0, s:defaults_list)
1020 let failed = append(0, s:colorscheme_list)
1021 let failed = append(0, s:options_list)
1022 let failed = append(0, s:lazycat_list)
1023 0 "jump back to the top
1024endfunction
1025if !exists(":SolarizedOptions")
1026 command SolarizedOptions :call s:SolarizedOptions()
1027endif
1028
1029function! SolarizedMenu()
1030 if exists("g:loaded_solarized_menu")
1031 try
1032 silent! aunmenu Solarized
1033 endtry
1034 endif
1035 let g:loaded_solarized_menu = 1
1036
1037 if g:colors_name == "solarized" && g:solarized_menu != 0
1038
1039 amenu &Solarized.&Contrast.&Low\ Contrast :let g:solarized_contrast="low" \| colorscheme solarized<CR>
1040 amenu &Solarized.&Contrast.&Normal\ Contrast :let g:solarized_contrast="normal" \| colorscheme solarized<CR>
1041 amenu &Solarized.&Contrast.&High\ Contrast :let g:solarized_contrast="high" \| colorscheme solarized<CR>
1042 an &Solarized.&Contrast.-sep- <Nop>
1043 amenu &Solarized.&Contrast.&Help:\ Contrast :help 'solarized_contrast'<CR>
1044
1045 amenu &Solarized.&Visibility.&Low\ Visibility :let g:solarized_visibility="low" \| colorscheme solarized<CR>
1046 amenu &Solarized.&Visibility.&Normal\ Visibility :let g:solarized_visibility="normal" \| colorscheme solarized<CR>
1047 amenu &Solarized.&Visibility.&High\ Visibility :let g:solarized_visibility="high" \| colorscheme solarized<CR>
1048 an &Solarized.&Visibility.-sep- <Nop>
1049 amenu &Solarized.&Visibility.&Help:\ Visibility :help 'solarized_visibility'<CR>
1050
1051 amenu &Solarized.&Background.&Toggle\ Background :ToggleBG<CR>
1052 amenu &Solarized.&Background.&Dark\ Background :set background=dark \| colorscheme solarized<CR>
1053 amenu &Solarized.&Background.&Light\ Background :set background=light \| colorscheme solarized<CR>
1054 an &Solarized.&Background.-sep- <Nop>
1055 amenu &Solarized.&Background.&Help:\ ToggleBG :help togglebg<CR>
1056
1057 if g:solarized_bold==0 | let l:boldswitch="On" | else | let l:boldswitch="Off" | endif
1058 exe "amenu &Solarized.&Styling.&Turn\\ Bold\\ ".l:boldswitch." :let g:solarized_bold=(abs(g:solarized_bold-1)) \\| colorscheme solarized<CR>"
1059 if g:solarized_italic==0 | let l:italicswitch="On" | else | let l:italicswitch="Off" | endif
1060 exe "amenu &Solarized.&Styling.&Turn\\ Italic\\ ".l:italicswitch." :let g:solarized_italic=(abs(g:solarized_italic-1)) \\| colorscheme solarized<CR>"
1061 if g:solarized_underline==0 | let l:underlineswitch="On" | else | let l:underlineswitch="Off" | endif
1062 exe "amenu &Solarized.&Styling.&Turn\\ Underline\\ ".l:underlineswitch." :let g:solarized_underline=(abs(g:solarized_underline-1)) \\| colorscheme solarized<CR>"
1063
1064 amenu &Solarized.&Diff\ Mode.&Low\ Diff\ Mode :let g:solarized_diffmode="low" \| colorscheme solarized<CR>
1065 amenu &Solarized.&Diff\ Mode.&Normal\ Diff\ Mode :let g:solarized_diffmode="normal" \| colorscheme solarized<CR>
1066 amenu &Solarized.&Diff\ Mode.&High\ Diff\ Mode :let g:solarized_diffmode="high" \| colorscheme solarized<CR>
1067
1068 if g:solarized_hitrail==0 | let l:hitrailswitch="On" | else | let l:hitrailswitch="Off" | endif
1069 exe "amenu &Solarized.&Experimental.&Turn\\ Highlight\\ Trailing\\ Spaces\\ ".l:hitrailswitch." :let g:solarized_hitrail=(abs(g:solarized_hitrail-1)) \\| colorscheme solarized<CR>"
1070 an &Solarized.&Experimental.-sep- <Nop>
1071 amenu &Solarized.&Experimental.&Help:\ HiTrail :help 'solarized_hitrail'<CR>
1072
1073 an &Solarized.-sep1- <Nop>
1074
1075 amenu &Solarized.&Autogenerate\ options :SolarizedOptions<CR>
1076
1077 an &Solarized.-sep2- <Nop>
1078
1079 amenu &Solarized.&Help.&Solarized\ Help :help solarized<CR>
1080 amenu &Solarized.&Help.&Toggle\ Background\ Help :help togglebg<CR>
1081 amenu &Solarized.&Help.&Removing\ This\ Menu :help solarized-menu<CR>
1082
1083 an 9999.77 &Help.&Solarized\ Colorscheme :help solarized<CR>
1084 an 9999.78 &Help.&Toggle\ Background :help togglebg<CR>
1085 an 9999.79 &Help.-sep3- <Nop>
1086
1087 endif
1088endfunction
1089
1090autocmd ColorScheme * if g:colors_name != "solarized" | silent! aunmenu Solarized | else | call SolarizedMenu() | endif
1091
1092"}}}
1093" License "{{{
1094" ---------------------------------------------------------------------
1095"
1096" Copyright (c) 2011 Ethan Schoonover
1097"
1098" Permission is hereby granted, free of charge, to any person obtaining a copy
1099" of this software and associated documentation files (the "Software"), to deal
1100" in the Software without restriction, including without limitation the rights
1101" to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
1102" copies of the Software, and to permit persons to whom the Software is
1103" furnished to do so, subject to the following conditions:
1104"
1105" The above copyright notice and this permission notice shall be included in
1106" all copies or substantial portions of the Software.
1107"
1108" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
1109" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
1110" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1111" AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1112" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
1113" OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
1114" THE SOFTWARE.
1115"
1116" vim:foldmethod=marker:foldlevel=0
1117"}}}