comparison vendor/vim-packs/srcery-vim/autoload/srcery.vim @ 704:1e0f578f6752

Update vendor and add support for vim packs
author nanaya <me@nanaya.net>
date Sun, 18 Dec 2022 20:06:46 +0900
parents
children 78469331407e
comparison
equal deleted inserted replaced
703:b7cd7465cc26 704:1e0f578f6752
1 " Setup Variables: {{{
2 " Colors {{{
3
4 if !exists('g:srcery_black')
5 let g:srcery_black='#1C1B19'
6 endif
7
8 if !exists('g:srcery_red')
9 let g:srcery_red='#EF2F27'
10 endif
11
12 if !exists('g:srcery_green')
13 let g:srcery_green='#519F50'
14 endif
15
16 if !exists('g:srcery_yellow')
17 let g:srcery_yellow='#FBB829'
18 endif
19
20 if !exists('g:srcery_blue')
21 let g:srcery_blue='#2C78BF'
22 endif
23
24 if !exists('g:srcery_magenta')
25 let g:srcery_magenta='#E02C6D'
26 endif
27
28 if !exists('g:srcery_cyan')
29 let g:srcery_cyan='#0AAEB3'
30 endif
31
32 if !exists('g:srcery_white')
33 let g:srcery_white='#BAA67F'
34 endif
35
36 if !exists('g:srcery_bright_black')
37 let g:srcery_bright_black='#918175'
38 endif
39
40 if !exists('g:srcery_bright_red')
41 let g:srcery_bright_red='#F75341'
42 endif
43
44 if !exists('g:srcery_bright_green')
45 let g:srcery_bright_green='#98BC37'
46 endif
47
48 if !exists('g:srcery_bright_yellow')
49 let g:srcery_bright_yellow='#FED06E'
50 endif
51
52 if !exists('g:srcery_bright_blue')
53 let g:srcery_bright_blue='#68A8E4'
54 endif
55
56 if !exists('g:srcery_bright_magenta')
57 let g:srcery_bright_magenta='#FF5C8F'
58 endif
59
60 if !exists('g:srcery_bright_cyan')
61 let g:srcery_bright_cyan='#2BE4D0'
62 endif
63
64 if !exists('g:srcery_bright_white')
65 let g:srcery_bright_white='#FCE8C3'
66 endif
67
68 if !exists('g:srcery_orange')
69 let g:srcery_orange='#FF5F00'
70 endif
71
72 if !exists('g:srcery_bright_orange')
73 let g:srcery_bright_orange='#FF8700'
74 endif
75
76 if !exists('g:srcery_hard_black')
77 let g:srcery_hard_black='#121212'
78 endif
79
80 if !exists('g:srcery_xgray1')
81 let g:srcery_xgray1='#262626'
82 endif
83
84 if !exists('g:srcery_xgray2')
85 let g:srcery_xgray2='#303030'
86 endif
87
88 if !exists('g:srcery_xgray3')
89 let g:srcery_xgray3='#3A3A3A'
90 endif
91
92 if !exists('g:srcery_xgray4')
93 let g:srcery_xgray4='#444444'
94 endif
95
96 if !exists('g:srcery_xgray5')
97 let g:srcery_xgray5='#4E4E4E'
98 endif
99
100 if !exists('g:srcery_xgray6')
101 let g:srcery_xgray6='#585858'
102 endif
103
104 " }}}
105 " Options {{{
106
107 if !exists('g:srcery_bold')
108 let g:srcery_bold=1
109 endif
110
111 if !exists('g:srcery_italic')
112 if has('gui_running') || $TERM_ITALICS ==? 'true'
113 let g:srcery_italic=1
114 else
115 let g:srcery_italic=0
116 endif
117 endif
118
119 if !exists('g:srcery_bg_passthrough')
120 let g:srcery_bg_passthrough=0
121 endif
122
123 if !exists('g:srcery_undercurl')
124 let g:srcery_undercurl=1
125 endif
126
127 if !exists('g:srcery_underline')
128 let g:srcery_underline=1
129 endif
130
131 if !exists('g:srcery_inverse')
132 let g:srcery_inverse=1
133 endif
134
135 if !exists('g:srcery_inverse_matches')
136 let g:srcery_inverse_matches=0
137 endif
138
139 if !exists('g:srcery_inverse_match_paren')
140 let g:srcery_inverse_match_paren=0
141 endif
142
143 if !exists('g:srcery_dim_lisp_paren')
144 let g:srcery_dim_lisp_paren=0
145 endif
146
147 if !exists('g:srcery_guisp_fallback') || index(['fg', 'bg'], g:srcery_guisp_fallback) == -1
148 let g:srcery_guisp_fallback='NONE'
149 endif
150
151 if !exists('g:srcery_italic_types')
152 let g:srcery_italic_types=0
153 endif
154
155 if !exists('g:srcery_hard_black_terminal_bg')
156 let g:srcery_hard_black_terminal_bg=1
157 endif
158
159 " }}}
160 " }}}
161 " Palette: {{{
162
163 let g:srcery#palette = {}
164 let g:srcery#palette.none = ['NONE', 'NONE']
165
166 " 16 base colors
167 let g:srcery#palette.black = [g:srcery_black, 0]
168 let g:srcery#palette.red = [g:srcery_red, 1]
169 let g:srcery#palette.green = [g:srcery_green, 2]
170 let g:srcery#palette.yellow = [g:srcery_yellow, 3]
171 let g:srcery#palette.blue = [g:srcery_blue, 4]
172 let g:srcery#palette.magenta = [g:srcery_magenta, 5]
173 let g:srcery#palette.cyan = [g:srcery_cyan, 6]
174 let g:srcery#palette.white = [g:srcery_white, 7]
175 let g:srcery#palette.bright_black = [g:srcery_bright_black, 8]
176 let g:srcery#palette.bright_red = [g:srcery_bright_red, 9]
177 let g:srcery#palette.bright_green = [g:srcery_bright_green, 10]
178 let g:srcery#palette.bright_yellow = [g:srcery_bright_yellow, 11]
179 let g:srcery#palette.bright_blue = [g:srcery_bright_blue, 12]
180 let g:srcery#palette.bright_magenta = [g:srcery_bright_magenta, 13]
181 let g:srcery#palette.bright_cyan = [g:srcery_bright_cyan, 14]
182 let g:srcery#palette.bright_white = [g:srcery_bright_white, 15]
183
184 " xterm colors
185 let g:srcery#palette.orange = [g:srcery_orange, 202]
186 let g:srcery#palette.bright_orange = [g:srcery_bright_orange, 208]
187 let g:srcery#palette.hard_black = [g:srcery_hard_black, 233]
188 let g:srcery#palette.xgray1 = [g:srcery_xgray1, 235]
189 let g:srcery#palette.xgray2 = [g:srcery_xgray2, 236]
190 let g:srcery#palette.xgray3 = [g:srcery_xgray3, 237]
191 let g:srcery#palette.xgray4 = [g:srcery_xgray4, 238]
192 let g:srcery#palette.xgray5 = [g:srcery_xgray5, 239]
193 let g:srcery#palette.xgray6 = [g:srcery_xgray6, 240]
194
195 " }}}
196 " Setup Emphasis: {{{
197
198 let g:srcery#palette.bold = 'bold,'
199 if g:srcery_bold == 0
200 let g:srcery#palette.bold = ''
201 endif
202
203 let g:srcery#palette.italic = 'italic,'
204 if g:srcery_italic == 0
205 let g:srcery#palette.italic = ''
206 endif
207
208 let g:srcery#palette.underline = 'underline,'
209 if g:srcery_underline == 0
210 let g:srcery#palette.underline = ''
211 endif
212
213 let g:srcery#palette.undercurl = 'undercurl,'
214 if g:srcery_undercurl == 0
215 let g:srcery#palette.undercurl = ''
216 endif
217
218 let g:srcery#palette.inverse = 'inverse,'
219 if g:srcery_inverse == 0
220 let g:srcery#palette.inverse = ''
221 endif
222
223 " }}}
224
225 " Setup Terminal Colors For Neovim: {{{
226
227 if has('nvim')
228 let g:terminal_color_0 = g:srcery#palette.black[0]
229 let g:terminal_color_8 = g:srcery#palette.bright_black[0]
230
231 let g:terminal_color_1 = g:srcery#palette.red[0]
232 let g:terminal_color_9 = g:srcery#palette.bright_red[0]
233
234 let g:terminal_color_2 = g:srcery#palette.green[0]
235 let g:terminal_color_10 = g:srcery#palette.bright_green[0]
236
237 let g:terminal_color_3 = g:srcery#palette.yellow[0]
238 let g:terminal_color_11 = g:srcery#palette.bright_yellow[0]
239
240 let g:terminal_color_4 = g:srcery#palette.blue[0]
241 let g:terminal_color_12 = g:srcery#palette.bright_blue[0]
242
243 let g:terminal_color_5 = g:srcery#palette.magenta[0]
244 let g:terminal_color_13 = g:srcery#palette.bright_magenta[0]
245
246 let g:terminal_color_6 = g:srcery#palette.cyan[0]
247 let g:terminal_color_14 = g:srcery#palette.bright_cyan[0]
248
249 let g:terminal_color_7 = g:srcery#palette.white[0]
250 let g:terminal_color_15 = g:srcery#palette.bright_white[0]
251 endif
252
253 " }}}
254 " Setup Terminal Colors For Vim with termguicolors: {{{
255
256 if exists('*term_setansicolors')
257 let g:terminal_ansi_colors = repeat([0], 16)
258
259 let g:terminal_ansi_colors[0] = g:srcery#palette.black[0]
260 let g:terminal_ansi_colors[8] = g:srcery#palette.bright_black[0]
261
262 let g:terminal_ansi_colors[1] = g:srcery#palette.red[0]
263 let g:terminal_ansi_colors[9] = g:srcery#palette.bright_red[0]
264
265 let g:terminal_ansi_colors[2] = g:srcery#palette.green[0]
266 let g:terminal_ansi_colors[10] = g:srcery#palette.bright_green[0]
267
268 let g:terminal_ansi_colors[3] = g:srcery#palette.yellow[0]
269 let g:terminal_ansi_colors[11] = g:srcery#palette.bright_yellow[0]
270
271 let g:terminal_ansi_colors[4] = g:srcery#palette.blue[0]
272 let g:terminal_ansi_colors[12] = g:srcery#palette.bright_blue[0]
273
274 let g:terminal_ansi_colors[5] = g:srcery#palette.magenta[0]
275 let g:terminal_ansi_colors[13] = g:srcery#palette.bright_magenta[0]
276
277 let g:terminal_ansi_colors[6] = g:srcery#palette.cyan[0]
278 let g:terminal_ansi_colors[14] = g:srcery#palette.bright_cyan[0]
279
280 let g:terminal_ansi_colors[7] = g:srcery#palette.white[0]
281 let g:terminal_ansi_colors[15] = g:srcery#palette.bright_white[0]
282 endif
283
284 " }}}
285
286 " vim: fdm=marker ts=2 sts=2 sw=2 fdl=0: