aboutsummaryrefslogtreecommitdiffhomepage
path: root/.config/vim/my/colors/ocean.vim
blob: f22074096d5db16833b86516f2027c7b91e097f5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
scriptencoding utf-8


hi clear
let g:colors_name = 'ocean'



let s:dark = {
    \ 'NONE'        : 'NONE',
    \ 'bg'          : '#101020',
    \ 'fg'          : '#b1b1c8',
    \ 'gray1'       : '#a7a7a7',
    \ 'gray2'       : '#353535',
    \ 'gray3'       : '#464646',
    \ 'gray4'       : '#252525',
    \ 'red'         : '#a65f49',
    \ 'red2'        : '#2e1f28',
    \ 'orange'      : '#deab52',
    \ 'yellow'      : '#a68f49',
    \ 'yellow2'     : '#a89562',
    \ 'yellow3'     : '#5c5241',
    \ 'green'       : '#c4e088',
    \ 'blue'        : '#6e6eff',
    \ 'blue2'       : '#70b0ff',
    \ 'diff_add'    : '#202050',
    \ 'diff_change' : '#204020',
    \ 'diff_delete' : '#402020',
    \ 'diff_text'   : '#3e6333',
    \ 'visual'      : '#303060',
    \ 'comment'     : '#8686bf',
    \ 'cursor'      : '#5b5bb6',
    \ }

let s:light = {
    \ 'NONE'        : 'NONE',
    \ 'bg'          : '#f5f5ff',
    \ 'fg'          : '#203050',
    \ 'gray1'       : '#4f4f4f',
    \ 'gray2'       : '#bebebe',
    \ 'gray3'       : '#aeaeae',
    \ 'gray4'       : '#cecece',
    \ 'red'         : '#d77253',
    \ 'red2'        : '#dcc8c2',
    \ 'orange'      : '#e79230',
    \ 'yellow'      : '#cba224',
    \ 'yellow2'     : '#af8e29',
    \ 'yellow3'     : '#c6b683',
    \ 'green'       : '#6f9226',
    \ 'blue'        : '#6e6eff',
    \ 'blue2'       : '#6f8fff',
    \ 'diff_add'    : '#202050',
    \ 'diff_change' : '#204020',
    \ 'diff_delete' : '#402020',
    \ 'diff_text'   : '#c4ff88',
    \ 'visual'      : '#f0f0d0',
    \ 'comment'     : '#a0a0e0',
    \ 'cursor'      : '#5b5bb6',
    \ }


function! s:hi(group_name, guifg, guibg, ...) abort
    let attributes = get(a:000, 0, 'NONE')
    " Even if 'termguicolors' is enabled the attribute "gui" is ignored,
    " instead, "cterm" is used.
    execute printf('hi %s guifg=%s guibg=%s gui=%s cterm=%s',
        \ a:group_name,
        \ s:pallete[a:guifg], s:pallete[a:guibg], attributes, attributes)
endfunction

command! -nargs=*
    \ Hi
    \ call s:hi(<f-args>)



let s:pallete = &background ==# 'dark' ? s:dark : s:light

Hi ColorColumn    NONE    red2
Hi Comment        comment NONE
Hi Constant       red     NONE
Hi Cursor         fg      cursor
Hi DiffAdd        NONE    diff_add
Hi DiffChange     NONE    diff_change
Hi DiffDelete     NONE    diff_delete
Hi DiffText       NONE    diff_text
Hi EndOfBuffer    bg      bg
Hi Error          red     NONE
Hi Identifier     green   NONE
Hi LineNr         gray1   visual
Hi MatchParen     NONE    NONE
Hi MoreMsg        comment NONE
Hi Normal         fg      bg
Hi PMenu          fg      gray2
Hi PMenuSbar      NONE    gray2
Hi PMenuSel       fg      visual
Hi PMenuThumb     NONE    gray4
Hi PreProc        orange  NONE
Hi Search         bg      yellow3 bold
Hi Special        red     NONE
Hi SpecialComment comment NONE    bold
Hi SpecialKey     gray2   NONE
Hi SpellBad       red     NONE    underline
Hi SpellCap       red     NONE    underline
Hi SpellLocal     yellow2 NONE    underline
Hi SpellRare      yellow2 NONE    underline
Hi Statement      blue    NONE
Hi StatusLine     gray1   gray2
Hi StatusLineNC   gray1   gray3
Hi String         yellow  NONE
Hi Title          orange  NONE
Hi Todo           fg      NONE    bold
Hi Type           blue2   NONE
Hi Underlined     NONE    NONE    underline
Hi Visual         NONE    visual
Hi WarningMsg     yellow2 NONE    bold


hi! link Character    String
hi! link CursorColumn CursorLine
hi! link CursorIM     Cursor
hi! link CursorLine   Visual
hi! link CursorLineNr Normal
hi! link Directory    Type
hi! link ErrorMsg     Error
hi! link FoldColumn   LineNr
hi! link Folded       Comment
hi! link IncSearch    Search
hi! link ModeMsg      Comment
hi! link NonText      SpecialKey
hi! link Operator     Identifier
hi! link Question     MoreMsg
hi! link SignColumn   LineNr
hi! link TabLine      StatusLineNC
hi! link TabLineFill  EndOfBuffer
hi! link TabLineSel   StatusLine
hi! link VertSplit    StatusLine
hi! link WildMenu     Title



unlet s:pallete
unlet s:dark
unlet s:light
delfunction s:hi
delcommand Hi