summaryrefslogtreecommitdiff
path: root/nvim/.config/nvim/colors/monochrome.vim
diff options
context:
space:
mode:
Diffstat (limited to 'nvim/.config/nvim/colors/monochrome.vim')
-rw-r--r--nvim/.config/nvim/colors/monochrome.vim254
1 files changed, 254 insertions, 0 deletions
diff --git a/nvim/.config/nvim/colors/monochrome.vim b/nvim/.config/nvim/colors/monochrome.vim
new file mode 100644
index 0000000..5c4bf00
--- /dev/null
+++ b/nvim/.config/nvim/colors/monochrome.vim
@@ -0,0 +1,254 @@
1" Vim color scheme
2"
3" Name: monochrome.vim
4" Maintainer: Xavier Noria <fxn@hashref.com>
5" License: MIT
6
7set background=dark
8
9hi clear
10if exists('syntax_on')
11 syntax reset
12endif
13
14let g:colors_name = 'monochrome'
15
16let s:white = ['White', 15]
17let s:black = ['#0e1111', 16]
18let s:bgray = ['#181818', 233]
19let s:lgray = ['LightGray', 255]
20let s:cgray = ['#737373', 243]
21let s:dgray = ['DarkGray', 248]
22let s:sblue = ['#778899', 67]
23let s:yellow = ['Yellow', 226]
24let s:red = ['#b6403a', 160]
25let s:green = ['#478226', 28]
26
27let s:default_fg = s:lgray
28let s:default_bg = s:black
29
30let s:italic = 'italic'
31let s:bold = 'bold'
32let s:underline = 'underline'
33let s:none = 'NONE'
34
35let s:default_lst = []
36let s:default_str = ''
37
38if !exists("g:monochrome_italic_comments")
39 let g:monochrome_italic_comments = 0
40endif
41let s:comment_attr = g:monochrome_italic_comments ? s:italic : s:none
42
43function! s:hi(...)
44 let group = a:1
45 let fg = get(a:, 2, s:default_fg)
46 let bg = get(a:, 3, s:default_bg)
47 let attr = get(a:, 4, s:default_str)
48
49 let cmd = ['hi', group]
50
51 if fg != s:default_lst
52 call add(cmd, 'guifg='.fg[0])
53 call add(cmd, 'ctermfg='.fg[1])
54 endif
55
56 if bg != s:default_lst && bg != s:default_bg
57 call add(cmd, 'guibg='.bg[0])
58 call add(cmd, 'ctermbg='.bg[1])
59 endif
60
61 if attr != s:default_str
62 call add(cmd, 'gui='.attr)
63 call add(cmd, 'cterm='.attr)
64 endif
65
66 exec join(cmd, ' ')
67endfunction
68
69
70"
71" --- Vim interface ------------------------------------------------------------
72"
73
74call s:hi('Normal')
75call s:hi('Cursor', s:black, s:lgray)
76call s:hi('CursorLine', s:default_lst, s:bgray, s:none)
77call s:hi('CursorLineNr', s:white, s:default_bg, s:bold)
78call s:hi('ColorColumn', s:default_fg, s:bgray)
79call s:hi('Search', s:white, s:sblue)
80call s:hi('Visual', s:white, s:sblue)
81call s:hi('ErrorMsg', s:white, s:red)
82
83" Tildes at the bottom of a buffer, etc.
84call s:hi('NonText', s:dgray)
85
86" Folding.
87call s:hi('FoldColumn', s:dgray)
88call s:hi('Folded')
89
90" Line numbers gutter.
91call s:hi('LineNr', s:dgray)
92
93" Small arrow used for tabs.
94call s:hi('SpecialKey', s:sblue, s:default_bg, s:bold)
95
96" File browsers.
97call s:hi('Directory', s:white, s:default_bg, s:bold)
98
99" Help.
100call s:hi('helpSpecial')
101call s:hi('helpHyperTextJump', s:sblue, s:default_bg, s:underline)
102call s:hi('helpNote')
103
104" Popup menu.
105call s:hi('Pmenu', s:white, s:sblue)
106call s:hi('PmenuSel', s:sblue, s:white)
107
108" Notes.
109call s:hi('Todo', s:black, s:yellow, s:bold)
110
111" Signs.
112call s:hi('SignColumn')
113
114"
115" --- Programming languages ----------------------------------------------------
116"
117
118call s:hi('Statement', s:white, s:default_bg, s:bold)
119call s:hi('PreProc', s:white, s:default_bg, s:bold)
120call s:hi('String', s:sblue)
121call s:hi('Comment', s:cgray, s:default_bg, s:comment_attr)
122call s:hi('Constant')
123call s:hi('Type', s:white, s:default_bg, s:bold)
124call s:hi('Function', s:white)
125call s:hi('Identifier')
126call s:hi('Special')
127call s:hi('MatchParen', s:lgray, s:black, s:underline)
128
129
130"
131" --- VimL ---------------------------------------------------------------------
132"
133
134call s:hi('vimOption')
135call s:hi('vimGroup')
136call s:hi('vimHiClear')
137call s:hi('vimHiGroup')
138call s:hi('vimHiAttrib')
139call s:hi('vimHiGui')
140call s:hi('vimHiGuiFgBg')
141call s:hi('vimHiCTerm')
142call s:hi('vimHiCTermFgBg')
143call s:hi('vimSynType')
144hi link vimCommentTitle Comment
145
146
147"
148" --- Ruby ---------------------------------------------------------------------
149"
150
151call s:hi('rubyConstant')
152call s:hi('rubySharpBang', s:cgray)
153call s:hi('rubySymbol', s:sblue)
154call s:hi('rubyStringDelimiter', s:sblue)
155call s:hi('rubyStringEscape', s:sblue)
156call s:hi('rubyRegexpEscape', s:sblue)
157call s:hi('rubyRegexpAnchor', s:sblue)
158call s:hi('rubyRegexpSpecial', s:sblue)
159
160
161"
162" --- Elixir -------------------------------------------------------------------
163"
164
165call s:hi('elixirAlias', s:default_fg, s:default_bg, s:none)
166call s:hi('elixirDelimiter', s:sblue)
167call s:hi('elixirSelf', s:default_fg, s:default_bg, s:none)
168
169" For ||, ->, etc.
170call s:hi('elixirOperator')
171
172" Module attributes like @doc or @type.
173hi link elixirVariable Statement
174
175" While rendered as comments in other languages, docstrings are strings,
176" experimental.
177hi link elixirDocString String
178hi link elixirDocTest String
179hi link elixirStringDelimiter String
180
181
182"
183" --- Perl ---------------------------------------------------------------------
184"
185
186call s:hi('perlSharpBang', s:cgray)
187call s:hi('perlStringStartEnd', s:sblue)
188call s:hi('perlStringEscape', s:sblue)
189call s:hi('perlMatchStartEnd', s:sblue)
190
191
192"
193" --- Python -------------------------------------------------------------------
194"
195
196call s:hi('pythonEscape', s:sblue)
197
198
199"
200" --- JavaScript ---------------------------------------------------------------
201"
202
203call s:hi('javaScriptFunction', s:white, s:default_bg, s:bold)
204
205
206"
207" --- Diffs --------------------------------------------------------------------
208"
209
210call s:hi('diffFile', s:cgray)
211call s:hi('diffNewFile', s:cgray)
212call s:hi('diffIndexLine', s:cgray)
213call s:hi('diffLine', s:cgray)
214call s:hi('diffSubname', s:cgray)
215call s:hi('diffAdded', s:white, s:green)
216call s:hi('diffRemoved', s:white, s:red)
217
218
219"
220" --- Markdown -----------------------------------------------------------------
221"
222
223call s:hi('Title', s:white, s:default_bg, s:bold)
224call s:hi('markdownHeadingDelimiter', s:white, s:default_bg, s:bold)
225call s:hi('markdownHeadingRule', s:white, s:default_bg, s:bold)
226call s:hi('markdownLinkText', s:sblue, s:default_bg, s:underline)
227
228
229"
230" --- vim-fugitive -------------------------------------------------------------
231"
232
233call s:hi('gitcommitComment', s:default_fg, s:default_bg, s:none)
234call s:hi('gitcommitOnBranch', s:default_fg, s:default_bg, s:none)
235call s:hi('gitcommitBranch', s:sblue, s:default_bg, s:none)
236call s:hi('gitcommitHeader', s:white, s:default_bg, s:bold)
237call s:hi('gitcommitSelected', s:default_fg, s:default_bg, s:none)
238call s:hi('gitcommitDiscarded', s:default_fg, s:default_bg, s:none)
239call s:hi('gitcommitSelectedType', s:default_fg, s:default_bg, s:none)
240call s:hi('gitcommitDiscardedType', s:default_fg, s:default_bg, s:none)
241
242
243"
244" --- NeoMake ------------------------------------------------------------------
245"
246
247call s:hi('NeomakeMessageSign')
248call s:hi('NeomakeWarningSign', s:sblue)
249call s:hi('NeomakeErrorSign', s:yellow)
250call s:hi('NeomakeInfoSign')
251call s:hi('NeomakeError', s:yellow)
252call s:hi('NeomakeInfo', s:default_fg, s:default_bg, s:bold)
253call s:hi('NeomakeMessage')
254call s:hi('NeomakeWarning', s:yellow)