]> git.r.bdr.sh - rbdr/dotfiles/blob - vim/colors/vividchalk.vim
Turn off the blur
[rbdr/dotfiles] / vim / colors / vividchalk.vim
1 " Vim color scheme
2 " Name: vividchalk.vim
3 " Author: Tim Pope <vimNOSPAM@tpope.info>
4 " Version: 2.0
5 " GetLatestVimScripts: 1891 1 :AutoInstall: vividchalk.vim
6
7 " Based on the Vibrank Ink theme for TextMate
8 " Distributable under the same terms as Vim itself (see :help license)
9
10 if has("gui_running")
11 set background=dark
12 endif
13 hi clear
14 if exists("syntax_on")
15 syntax reset
16 endif
17
18 let colors_name = "vividchalk"
19
20 " First two functions adapted from inkpot.vim
21
22 " map a urxvt cube number to an xterm-256 cube number
23 fun! s:M(a)
24 return strpart("0245", a:a, 1) + 0
25 endfun
26
27 " map a urxvt colour to an xterm-256 colour
28 fun! s:X(a)
29 if &t_Co == 88
30 return a:a
31 else
32 if a:a == 8
33 return 237
34 elseif a:a < 16
35 return a:a
36 elseif a:a > 79
37 return 232 + (3 * (a:a - 80))
38 else
39 let l:b = a:a - 16
40 let l:x = l:b % 4
41 let l:y = (l:b / 4) % 4
42 let l:z = (l:b / 16)
43 return 16 + s:M(l:x) + (6 * s:M(l:y)) + (36 * s:M(l:z))
44 endif
45 endif
46 endfun
47
48 function! E2T(a)
49 return s:X(a:a)
50 endfunction
51
52 function! s:choose(mediocre,good)
53 if &t_Co != 88 && &t_Co != 256
54 return a:mediocre
55 else
56 return s:X(a:good)
57 endif
58 endfunction
59
60 function! s:hifg(group,guifg,first,second,...)
61 if a:0 && &t_Co == 256
62 let ctermfg = a:1
63 else
64 let ctermfg = s:choose(a:first,a:second)
65 endif
66 exe "highlight ".a:group." guifg=".a:guifg." ctermfg=".ctermfg
67 endfunction
68
69 function! s:hibg(group,guibg,first,second)
70 let ctermbg = s:choose(a:first,a:second)
71 exe "highlight ".a:group." guibg=".a:guibg." ctermbg=".ctermbg
72 endfunction
73
74 hi link railsMethod PreProc
75 hi link rubyDefine Keyword
76 hi link rubySymbol Constant
77 hi link rubyAccess rubyMethod
78 hi link rubyAttribute rubyMethod
79 hi link rubyEval rubyMethod
80 hi link rubyException rubyMethod
81 hi link rubyInclude rubyMethod
82 hi link rubyStringDelimiter rubyString
83 hi link rubyRegexp Regexp
84 hi link rubyRegexpDelimiter rubyRegexp
85 "hi link rubyConstant Variable
86 "hi link rubyGlobalVariable Variable
87 "hi link rubyClassVariable Variable
88 "hi link rubyInstanceVariable Variable
89 hi link javascriptRegexpString Regexp
90 hi link javascriptNumber Number
91 hi link javascriptNull Constant
92 highlight link diffAdded String
93 highlight link diffRemoved Statement
94 highlight link diffLine PreProc
95 highlight link diffSubname Comment
96
97 call s:hifg("Normal","#EEEEEE","White",87)
98 if &background == "light" || has("gui_running")
99 hi Normal guibg=Black ctermbg=Black
100 else
101 hi Normal guibg=Black ctermbg=NONE
102 endif
103 highlight StatusLine guifg=Black guibg=#aabbee gui=bold ctermfg=Black ctermbg=White cterm=bold
104 highlight StatusLineNC guifg=#444444 guibg=#aaaaaa gui=none ctermfg=Black ctermbg=Grey cterm=none
105 "if &t_Co == 256
106 "highlight StatusLine ctermbg=117
107 "else
108 "highlight StatusLine ctermbg=43
109 "endif
110
111 highlight Ignore ctermfg=Black
112 highlight WildMenu guifg=Black guibg=#ffff00 gui=bold ctermfg=Black ctermbg=Yellow cterm=bold
113 highlight Cursor guifg=Black guibg=White ctermfg=Black ctermbg=White
114 highlight CursorLine guibg=#333333 guifg=NONE
115 highlight CursorColumn guibg=#333333 guifg=NONE
116 highlight NonText guifg=#404040 ctermfg=8
117 highlight SpecialKey guifg=#404040 ctermfg=8
118 highlight Directory none
119 high link Directory Identifier
120 highlight ErrorMsg guibg=Red ctermbg=DarkRed guifg=NONE ctermfg=NONE
121 highlight Search guifg=NONE ctermfg=NONE gui=none cterm=none
122 call s:hibg("Search" ,"#555555","DarkBlue",81)
123 highlight IncSearch guifg=White guibg=Black ctermfg=White ctermbg=Black
124 highlight MoreMsg guifg=#00AA00 ctermfg=Green
125 highlight LineNr guifg=#DDEEFF ctermfg=White
126 call s:hibg("LineNr" ,"#222222","DarkBlue",80)
127 highlight Question none
128 high link Question MoreMsg
129 highlight Title guifg=Magenta ctermfg=Magenta
130 highlight VisualNOS gui=none cterm=none
131 call s:hibg("Visual" ,"#555577","LightBlue",83)
132 call s:hibg("VisualNOS" ,"#444444","DarkBlue",81)
133 call s:hibg("MatchParen","#1100AA","DarkBlue",18)
134 highlight WarningMsg guifg=Red ctermfg=Red
135 highlight Error ctermbg=DarkRed
136 highlight SpellBad ctermbg=DarkRed
137 " FIXME: Comments
138 highlight SpellRare ctermbg=DarkMagenta
139 highlight SpellCap ctermbg=DarkBlue
140 highlight SpellLocal ctermbg=DarkCyan
141
142 call s:hibg("Folded" ,"#110077","DarkBlue",17)
143 call s:hifg("Folded" ,"#aaddee","LightCyan",63)
144 highlight FoldColumn none
145 high link FoldColumn Folded
146 highlight DiffAdd ctermbg=4 guibg=DarkBlue
147 highlight DiffChange ctermbg=5 guibg=DarkMagenta
148 highlight DiffDelete ctermfg=12 ctermbg=6 gui=bold guifg=Blue guibg=DarkCyan
149 highlight DiffText ctermbg=DarkRed
150 highlight DiffText cterm=bold ctermbg=9 gui=bold guibg=Red
151
152 highlight Pmenu guifg=White ctermfg=White gui=bold cterm=bold
153 highlight PmenuSel guifg=White ctermfg=White gui=bold cterm=bold
154 call s:hibg("Pmenu" ,"#000099","Blue",18)
155 call s:hibg("PmenuSel" ,"#5555ff","DarkCyan",39)
156 highlight PmenuSbar guibg=Grey ctermbg=Grey
157 highlight PmenuThumb guibg=White ctermbg=White
158 highlight TabLine gui=underline cterm=underline
159 call s:hifg("TabLine" ,"#bbbbbb","LightGrey",85)
160 call s:hibg("TabLine" ,"#333333","DarkGrey",80)
161 highlight TabLineSel guifg=White guibg=Black ctermfg=White ctermbg=Black
162 highlight TabLineFill gui=underline cterm=underline
163 call s:hifg("TabLineFill","#bbbbbb","LightGrey",85)
164 call s:hibg("TabLineFill","#808080","Grey",83)
165
166 hi Type gui=none
167 hi Statement gui=none
168 if !has("gui_mac")
169 " Mac GUI degrades italics to ugly underlining.
170 hi Comment gui=italic
171 hi railsUserClass gui=italic
172 hi railsUserMethod gui=italic
173 endif
174 hi Identifier cterm=none
175 " Commented numbers at the end are *old* 256 color values
176 "highlight PreProc guifg=#EDF8F9
177 call s:hifg("Comment" ,"#9933CC","DarkMagenta",34) " 92
178 " 26 instead?
179 call s:hifg("Constant" ,"#339999","DarkCyan",21) " 30
180 call s:hifg("rubyNumber" ,"#CCFF33","Yellow",60) " 190
181 call s:hifg("String" ,"#66FF00","LightGreen",44,82) " 82
182 call s:hifg("Identifier" ,"#FFCC00","Yellow",72) " 220
183 call s:hifg("Statement" ,"#FF6600","Brown",68) " 202
184 call s:hifg("PreProc" ,"#AAFFFF","LightCyan",47) " 213
185 call s:hifg("railsUserMethod","#AACCFF","LightCyan",27)
186 call s:hifg("Type" ,"#AAAA77","Grey",57) " 101
187 call s:hifg("railsUserClass" ,"#AAAAAA","Grey",7) " 101
188 call s:hifg("Special" ,"#33AA00","DarkGreen",24) " 7
189 call s:hifg("Regexp" ,"#44B4CC","DarkCyan",21) " 74
190 call s:hifg("rubyMethod" ,"#DDE93D","Yellow",77) " 191
191 "highlight railsMethod guifg=#EE1122 ctermfg=1