Closed megamaddu closed 8 years ago
I see you're using multiple JavaScript syntax highlighting plugins in your .vimrc, only using one should make JavaScript highlighting look better (I'm currently using othree/yajs.vim).
I don't work with PureScript, but it appears that you're using raichoo/purescript-vim for syntax highlighting. This plugin doesn't appear to add a lot of syntax highlighting groups, at least not with the sample code I tried, so the highlighting provided by that plugin won't be as rich as it appears in Atom. That said, I just pushed b16ba4c99c672aaa64931bc210e0eeb3cf1bb593 which adds a few more previously-empty syntax groups, that may improve things.
Awesome, I'll give the update and your JS suggestions a try. Thanks!
You're welcome!
Your update fixed everything : ]
One other note (and maybe this would be better as a separate issue in the airline repo) is the airline background is the same color as the main background, so it's really difficult to see that two files are open here:
Glad to hear it, and thanks for using the theme and for reporting the issue!
It looks like Airline isn't displaying at all for the top split in your screenshot, unless I'm missing something? I see what looks like a normal Vim statusline instead?
Right, the status line only shows for the selected pane. Is that normal? If I move to the upper pane it'll show the green "normal" and the file name, which is a little better but still a bit hard to see. Maybe it's just an airline setting. I haven't looked at that in a while.
Because your screenshot is cut off, I can't tell if you have the right side of Airline disabled or not, but I don't see it on the bottom (and see what looks like the start of "javascript" on the top.) The Airline theme only shows the filename on the left for inactive panes and grays out the colors on the right, so if you have the right side disabled you wouldn't see any of that.
Ah, here's another example. It's not a busy file, so it's easier to see there's a divider, but even then it's much harder to tell there's a split when the bottom file is selected.
Top selected:
Bottom selected:
It's not a big deal though.
Ah, okay. This is mostly a matter of personal preference. Here's a slightly-edited version of the theme that might be closer to what you're looking for:
" [onedark.vim](https://github.com/joshdick/airline-onedark.vim/)
" This is a [vim-airline](https://github.com/bling/vim-airline) theme for use with
" the [onedark.vim](https://github.com/joshdick/onedark.vim) colorscheme.
" It is based on vim-airline's ["tomorrow" theme](https://github.com/bling/vim-airline/blob/master/autoload/airline/themes/tomorrow.vim).
let g:airline#themes#onedark#palette = {}
function! airline#themes#onedark#refresh()
let g:airline#themes#onedark#palette.accents = {
\ 'red': airline#themes#get_highlight('Constant'),
\ }
let s:N1 = airline#themes#get_highlight2(['Normal', 'bg'], ['String', 'fg'])
let s:N2 = airline#themes#get_highlight('CursorLine')
let s:N3 = s:N2
let g:airline#themes#onedark#palette.normal = airline#themes#generate_color_map(s:N1, s:N2, s:N3)
let group = airline#themes#get_highlight('vimCommand')
let g:airline#themes#onedark#palette.normal_modified = {
\ 'airline_c': [ group[0], '', group[2], '', '' ]
\ }
let s:I1 = airline#themes#get_highlight('Cursor')
let s:I2 = s:N2
let s:I3 = airline#themes#get_highlight2(['Cursor', 'bg'], ['CusrorLine', 'bg'])
let g:airline#themes#onedark#palette.insert = airline#themes#generate_color_map(s:I1, s:I2, s:I3)
let g:airline#themes#onedark#palette.insert_modified = g:airline#themes#onedark#palette.normal_modified
let s:R1 = airline#themes#get_highlight('Error')
let s:R2 = s:N2
let s:R3 = airline#themes#get_highlight2(['Error', 'fg'], ['CursorLine', 'bg'])
let g:airline#themes#onedark#palette.replace = airline#themes#generate_color_map(s:R1, s:R2, s:R3)
let g:airline#themes#onedark#palette.replace_modified = g:airline#themes#onedark#palette.normal_modified
let s:V1 = airline#themes#get_highlight2(['Normal', 'bg'], ['Statement', 'fg'])
let s:V2 = s:N2
let s:V3 = airline#themes#get_highlight2(['Statement', 'fg'], ['CursorLine', 'bg'])
let g:airline#themes#onedark#palette.visual = airline#themes#generate_color_map(s:V1, s:V2, s:V3)
let g:airline#themes#onedark#palette.visual_modified = g:airline#themes#onedark#palette.normal_modified
let s:IA1 = airline#themes#get_highlight2(['Normal', 'bg'], ['Normal', 'fg'])
let s:IA2 = s:N2
let s:IA3 = airline#themes#get_highlight2(['Normal', 'fg'], ['CursorLine', 'bg'])
let g:airline#themes#onedark#palette.inactive = airline#themes#generate_color_map(s:IA1, s:IA2, s:IA3)
let g:airline#themes#onedark#palette.inactive_modified = {
\ 'airline_c': [ group[0], '', group[2], '', '' ]
\ }
endfunction
call airline#themes#onedark#refresh()
Ah yes, thanks!
You're welcome!
I've been using solarized-dark for a while, but I really like the colors in this theme. One problem I have though is that some languages have much less color (especially for symbols) using
onedark
instead ofsolarized
. I'll just post some screenshots. The two main ones for me are the arrows (->) and symbols (<<<, ., etc) in PureScript and the symbols in JavaScript (const, =, &&, etc).(FWIW, I find Atom's PureScript highlighting to be a bit odd (good for types, bad for code and imports) and way too colorful for JavaScript)
Solarized, PureScript:
Onedark, PureScript:
Solarized, JavaScript:
Onedark, JavaScript:
Atom, PureScript:
Atom, JavaScript:
And thanks for working on this theme, it's the best I've tried so far!