zenburn.vim 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351
  1. " Vim color file
  2. " Maintainer: Jani Nurminen <slinky@iki.fi>
  3. " Last Change: $Id: zenburn.vim,v 2.13 2009/10/24 10:16:01 slinky Exp $
  4. " URL: http://slinky.imukuppi.org/zenburnpage/
  5. " License: GPL
  6. "
  7. " Nothing too fancy, just some alien fruit salad to keep you in the zone.
  8. " This syntax file was designed to be used with dark environments and
  9. " low light situations. Of course, if it works during a daybright office, go
  10. " ahead :)
  11. "
  12. " Owes heavily to other Vim color files! With special mentions
  13. " to "BlackDust", "Camo" and "Desert".
  14. "
  15. " To install, copy to ~/.vim/colors directory.
  16. "
  17. " Alternatively, you can use Vimball installation:
  18. " vim zenburn.vba
  19. " :so %
  20. " :q
  21. "
  22. " For details, see :help vimball
  23. "
  24. " After installation, use it with :colorscheme zenburn.
  25. " See also :help syntax
  26. "
  27. " Credits:
  28. " - Jani Nurminen - original Zenburn
  29. " - Steve Hall & Cream posse - higher-contrast Visual selection
  30. " - Kurt Maier - 256 color console coloring, low and high contrast toggle,
  31. " bug fixing
  32. " - Charlie - spotted too bright StatusLine in non-high contrast mode
  33. " - Pablo Castellazzi - CursorLine fix for 256 color mode
  34. " - Tim Smith - force dark background
  35. " - John Gabriele - spotted bad Ignore-group handling
  36. " - Zac Thompson - spotted invisible NonText in low contrast mode
  37. " - Christophe-Marie Duquesne - suggested making a Vimball
  38. "
  39. " CONFIGURABLE PARAMETERS:
  40. "
  41. " You can use the default (don't set any parameters), or you can
  42. " set some parameters to tweak the Zenburn colours.
  43. "
  44. " To use them, put them into your .vimrc file before loading the color scheme,
  45. " example:
  46. " let g:zenburn_high_Contrast=1
  47. " colors zenburn
  48. "
  49. " * You can now set a darker background for bright environments. To activate, use:
  50. " contrast Zenburn, use:
  51. "
  52. " let g:zenburn_high_Contrast = 1
  53. "
  54. " * For example, Vim help files uses the Ignore-group for the pipes in tags
  55. " like "|somelink.txt|". By default, the pipes are not visible, as they
  56. " map to Ignore group. If you wish to enable coloring of the Ignore group,
  57. " set the following parameter to 1. Warning, it might make some syntax files
  58. " look strange.
  59. "
  60. " let g:zenburn_color_also_Ignore = 1
  61. "
  62. " * To get more contrast to the Visual selection, use
  63. "
  64. " let g:zenburn_alternate_Visual = 1
  65. "
  66. " * To use alternate colouring for Error message, use
  67. "
  68. " let g:zenburn_alternate_Error = 1
  69. "
  70. " * The new default for Include is a duller orange. To use the original
  71. " colouring for Include, use
  72. "
  73. " let g:zenburn_alternate_Include = 1
  74. "
  75. " * Work-around to a Vim bug, it seems to misinterpret ctermfg and 234 and 237
  76. " as light values, and sets background to light for some people. If you have
  77. " this problem, use:
  78. "
  79. " let g:zenburn_force_dark_Background = 1
  80. "
  81. " NOTE:
  82. "
  83. " * To turn the parameter(s) back to defaults, use UNLET:
  84. "
  85. " unlet g:zenburn_alternate_Include
  86. "
  87. " Setting to 0 won't work!
  88. "
  89. " That's it, enjoy!
  90. "
  91. " TODO
  92. " - Visual alternate color is broken? Try GVim >= 7.0.66 if you have trouble
  93. " - IME colouring (CursorIM)
  94. set background=dark
  95. hi clear
  96. if exists("syntax_on")
  97. syntax reset
  98. endif
  99. let g:colors_name="zenburn"
  100. hi Boolean guifg=#dca3a3
  101. hi Character guifg=#dca3a3 gui=bold
  102. hi Comment guifg=#7f9f7f gui=italic
  103. hi Conditional guifg=#f0dfaf gui=bold
  104. hi Constant guifg=#dca3a3 gui=bold
  105. hi Cursor guifg=#000d18 guibg=#8faf9f gui=bold
  106. hi Debug guifg=#bca3a3 gui=bold
  107. hi Define guifg=#ffcfaf gui=bold
  108. hi Delimiter guifg=#8f8f8f
  109. hi DiffAdd guifg=#709080 guibg=#313c36 gui=bold
  110. hi DiffChange guibg=#333333
  111. hi DiffDelete guifg=#333333 guibg=#464646
  112. hi DiffText guifg=#ecbcbc guibg=#41363c gui=bold
  113. hi Directory guifg=#dcdccc gui=bold
  114. hi ErrorMsg guifg=#80d4aa guibg=#2f2f2f gui=bold
  115. hi Exception guifg=#c3bf9f gui=bold
  116. hi Float guifg=#c0bed1
  117. hi FoldColumn guifg=#93b3a3 guibg=#3f4040
  118. hi Folded guifg=#93b3a3 guibg=#3f4040
  119. hi Function guifg=#efef8f
  120. hi Identifier guifg=#efdcbc
  121. hi IncSearch guibg=#f8f893 guifg=#385f38
  122. hi Keyword guifg=#f0dfaf gui=bold
  123. hi Label guifg=#dfcfaf gui=underline
  124. hi LineNr guifg=#9fafaf guibg=#262626
  125. hi Macro guifg=#ffcfaf gui=bold
  126. hi ModeMsg guifg=#ffcfaf gui=none
  127. hi MoreMsg guifg=#ffffff gui=bold
  128. hi Number guifg=#8cd0d3
  129. hi Operator guifg=#f0efd0
  130. hi PreCondit guifg=#dfaf8f gui=bold
  131. hi PreProc guifg=#ffcfaf gui=bold
  132. hi Question guifg=#ffffff gui=bold
  133. hi Repeat guifg=#ffd7a7 gui=bold
  134. hi Search guifg=#ffffe0 guibg=#284f28
  135. hi SpecialChar guifg=#dca3a3 gui=bold
  136. hi SpecialComment guifg=#82a282 gui=bold
  137. hi Special guifg=#cfbfaf
  138. hi SpecialKey guifg=#9ece9e
  139. hi Statement guifg=#e3ceab gui=none
  140. hi StatusLine guifg=#313633 guibg=#ccdc90
  141. hi StatusLineNC guifg=#2e3330 guibg=#88b090
  142. hi StorageClass guifg=#c3bf9f gui=bold
  143. hi String guifg=#cc9393
  144. hi Structure guifg=#efefaf gui=bold
  145. hi Tag guifg=#e89393 gui=bold
  146. hi Title guifg=#efefef gui=bold
  147. hi Todo guifg=#dfdfdf guibg=bg gui=bold
  148. hi Typedef guifg=#dfe4cf gui=bold
  149. hi Type guifg=#dfdfbf gui=bold
  150. hi Underlined guifg=#dcdccc gui=underline
  151. hi VertSplit guifg=#2e3330 guibg=#688060
  152. hi VisualNOS guifg=#333333 guibg=#f18c96 gui=bold,underline
  153. hi WarningMsg guifg=#ffffff guibg=#333333 gui=bold
  154. hi WildMenu guibg=#2c302d guifg=#cbecd0 gui=underline
  155. hi SpellBad guisp=#bc6c4c guifg=#dc8c6c
  156. hi SpellCap guisp=#6c6c9c guifg=#8c8cbc
  157. hi SpellRare guisp=#bc6c9c guifg=#bc8cbc
  158. hi SpellLocal guisp=#7cac7c guifg=#9ccc9c
  159. " Entering Kurt zone
  160. if &t_Co > 255
  161. hi Boolean ctermfg=181
  162. hi Character ctermfg=181 cterm=bold
  163. hi Comment ctermfg=108
  164. hi Conditional ctermfg=223 cterm=bold
  165. hi Constant ctermfg=181 cterm=bold
  166. hi Cursor ctermfg=233 ctermbg=109 cterm=bold
  167. hi Debug ctermfg=181 cterm=bold
  168. hi Define ctermfg=223 cterm=bold
  169. hi Delimiter ctermfg=245
  170. hi DiffAdd ctermfg=66 ctermbg=237 cterm=bold
  171. hi DiffChange ctermbg=236
  172. hi DiffDelete ctermfg=236 ctermbg=238
  173. hi DiffText ctermfg=217 ctermbg=237 cterm=bold
  174. hi Directory ctermfg=188 cterm=bold
  175. hi ErrorMsg ctermfg=115 ctermbg=236 cterm=bold
  176. hi Exception ctermfg=249 cterm=bold
  177. hi Float ctermfg=251
  178. hi FoldColumn ctermfg=109 ctermbg=238
  179. hi Folded ctermfg=109 ctermbg=238
  180. hi Function ctermfg=228
  181. hi Identifier ctermfg=223
  182. hi IncSearch ctermbg=228 ctermfg=238
  183. hi Keyword ctermfg=223 cterm=bold
  184. hi Label ctermfg=187 cterm=underline
  185. hi LineNr ctermfg=248 ctermbg=235
  186. hi Macro ctermfg=223 cterm=bold
  187. hi ModeMsg ctermfg=223 cterm=none
  188. hi MoreMsg ctermfg=15 cterm=bold
  189. hi Number ctermfg=116
  190. hi Operator ctermfg=230
  191. hi PreCondit ctermfg=180 cterm=bold
  192. hi PreProc ctermfg=223 cterm=bold
  193. hi Question ctermfg=15 cterm=bold
  194. hi Repeat ctermfg=223 cterm=bold
  195. hi Search ctermfg=230 ctermbg=236
  196. hi SpecialChar ctermfg=181 cterm=bold
  197. hi SpecialComment ctermfg=108 cterm=bold
  198. hi Special ctermfg=181
  199. hi SpecialKey ctermfg=151
  200. hi Statement ctermfg=187 ctermbg=234 cterm=none
  201. hi StatusLine ctermfg=236 ctermbg=186
  202. hi StatusLineNC ctermfg=235 ctermbg=108
  203. hi StorageClass ctermfg=249 cterm=bold
  204. hi String ctermfg=174
  205. hi Structure ctermfg=229 cterm=bold
  206. hi Tag ctermfg=181 cterm=bold
  207. hi Title ctermfg=7 ctermbg=234 cterm=bold
  208. hi Todo ctermfg=108 ctermbg=234 cterm=bold
  209. hi Typedef ctermfg=253 cterm=bold
  210. hi Type ctermfg=187 cterm=bold
  211. hi Underlined ctermfg=188 ctermbg=234 cterm=bold
  212. hi VertSplit ctermfg=236 ctermbg=65
  213. hi VisualNOS ctermfg=236 ctermbg=210 cterm=bold
  214. hi WarningMsg ctermfg=15 ctermbg=236 cterm=bold
  215. hi WildMenu ctermbg=236 ctermfg=194 cterm=bold
  216. hi CursorLine ctermbg=236 cterm=none
  217. " spellchecking, always "bright" background
  218. hi SpellLocal ctermfg=14 ctermbg=237
  219. hi SpellBad ctermfg=9 ctermbg=237
  220. hi SpellCap ctermfg=12 ctermbg=237
  221. hi SpellRare ctermfg=13 ctermbg=237
  222. " pmenu
  223. hi PMenu ctermfg=248 ctermbg=0
  224. hi PMenuSel ctermfg=223 ctermbg=235
  225. if exists("g:zenburn_high_Contrast")
  226. hi Normal ctermfg=188 ctermbg=234
  227. hi NonText ctermfg=238
  228. if exists("g:zenburn_color_also_Ignore")
  229. hi Ignore ctermfg=238
  230. endif
  231. else
  232. hi Normal ctermfg=188 ctermbg=237
  233. hi Cursor ctermbg=109
  234. hi diffadd ctermbg=237
  235. hi diffdelete ctermbg=238
  236. hi difftext ctermbg=237
  237. hi errormsg ctermbg=237
  238. hi foldcolumn ctermbg=238
  239. hi folded ctermbg=238
  240. hi incsearch ctermbg=228
  241. hi linenr ctermbg=238
  242. hi search ctermbg=238
  243. hi statement ctermbg=237
  244. hi statusline ctermbg=144
  245. hi statuslinenc ctermbg=108
  246. hi title ctermbg=237
  247. hi todo ctermbg=237
  248. hi underlined ctermbg=237
  249. hi vertsplit ctermbg=65
  250. hi visualnos ctermbg=210
  251. hi warningmsg ctermbg=236
  252. hi wildmenu ctermbg=236
  253. hi NonText ctermfg=240
  254. if exists("g:zenburn_color_also_Ignore")
  255. hi Ignore ctermfg=240
  256. endif
  257. endif
  258. if exists("g:zenburn_alternate_Error")
  259. " use more jumpy Error
  260. hi Error ctermfg=210 ctermbg=52 gui=bold
  261. else
  262. " default is something more zenburn-compatible
  263. hi Error ctermfg=228 ctermbg=95 gui=bold
  264. endif
  265. endif
  266. if exists("g:zenburn_force_dark_Background")
  267. " Force dark background, because of a bug in VIM: VIM sets background
  268. " automatically during "hi Normal ctermfg=X"; it misinterprets the high
  269. " value (234 or 237 above) as a light color, and wrongly sets background to
  270. " light. See ":help highlight" for details.
  271. set background=dark
  272. endif
  273. if exists("g:zenburn_high_Contrast")
  274. " use new darker background
  275. hi Normal guifg=#dcdccc guibg=#1f1f1f
  276. hi CursorLine guibg=#121212 gui=bold
  277. hi Pmenu guibg=#242424 guifg=#ccccbc
  278. hi PMenuSel guibg=#353a37 guifg=#ccdc90 gui=bold
  279. hi PmenuSbar guibg=#2e3330 guifg=#000000
  280. hi PMenuThumb guibg=#a0afa0 guifg=#040404
  281. hi MatchParen guifg=#f0f0c0 guibg=#383838 gui=bold
  282. hi SignColumn guifg=#9fafaf guibg=#181818 gui=bold
  283. hi TabLineFill guifg=#cfcfaf guibg=#181818 gui=bold
  284. hi TabLineSel guifg=#efefef guibg=#1c1c1b gui=bold
  285. hi TabLine guifg=#b6bf98 guibg=#181818 gui=bold
  286. hi CursorColumn guifg=#dcdccc guibg=#2b2b2b
  287. hi NonText guifg=#404040 gui=bold
  288. else
  289. " Original, lighter background
  290. hi Normal guifg=#dcdccc guibg=#3f3f3f
  291. hi CursorLine guibg=#434443
  292. hi Pmenu guibg=#2c2e2e guifg=#9f9f9f
  293. hi PMenuSel guibg=#242424 guifg=#d0d0a0 gui=bold
  294. hi PmenuSbar guibg=#2e3330 guifg=#000000
  295. hi PMenuThumb guibg=#a0afa0 guifg=#040404
  296. hi MatchParen guifg=#b2b2a0 guibg=#2e2e2e gui=bold
  297. hi SignColumn guifg=#9fafaf guibg=#343434 gui=bold
  298. hi TabLineFill guifg=#cfcfaf guibg=#353535 gui=bold
  299. hi TabLineSel guifg=#efefef guibg=#3a3a39 gui=bold
  300. hi TabLine guifg=#b6bf98 guibg=#353535 gui=bold
  301. hi CursorColumn guifg=#dcdccc guibg=#4f4f4f
  302. hi NonText guifg=#5b605e gui=bold
  303. endif
  304. if exists("g:zenburn_alternate_Visual")
  305. " Visual with more contrast, thanks to Steve Hall & Cream posse
  306. " gui=none fixes weird highlight problem in at least GVim 7.0.66, thanks to Kurt Maier
  307. hi Visual guifg=#000000 guibg=#71d3b4 gui=none
  308. hi VisualNOS guifg=#000000 guibg=#71d3b4 gui=none
  309. else
  310. " use default visual
  311. hi Visual guifg=#233323 guibg=#71d3b4 gui=none
  312. hi VisualNOS guifg=#233323 guibg=#71d3b4 gui=none
  313. endif
  314. if exists("g:zenburn_alternate_Error")
  315. " use more jumpy Error
  316. hi Error guifg=#e37170 guibg=#664040 gui=bold
  317. else
  318. " default is something more zenburn-compatible
  319. hi Error guifg=#e37170 guibg=#3d3535 gui=none
  320. endif
  321. if exists("g:zenburn_alternate_Include")
  322. " original setting
  323. hi Include guifg=#ffcfaf gui=bold
  324. else
  325. " new, less contrasted one
  326. hi Include guifg=#dfaf8f gui=bold
  327. endif
  328. if exists("g:zenburn_color_also_Ignore")
  329. " color the Ignore groups
  330. " note: if you get strange coloring for your files, turn this off (unlet)
  331. hi Ignore guifg=#545a4f
  332. endif
  333. " TODO check for more obscure syntax groups that they're ok