mhartington / oceanic-next

Oceanic Next theme for neovim
Other
1.13k stars 141 forks source link

Different colors than in screenshots #37

Closed shelldandy closed 7 years ago

shelldandy commented 7 years ago

Hi @mhartington i was wondering if you ran into similar issues, im using iterm 2 with tmux and also installed the oceanic next color scheme on my terminal so by default it looks like this:

captura de pantalla 2016-11-27 a la s 11 39 36

However after setting everything in my .vimrc file for some reason I get a dull grey background instead of the nice blue one:

captura de pantalla 2016-11-27 a la s 11 39 53

Am I missing something? I'm using Vim 7.4.898 for reference. Thanks

mhartington commented 7 years ago

Can provide a minimal vimrc file to test against?

shelldandy commented 7 years ago

How minimal?

I copied what's on the readme:

 " Theme
syntax enable
" for vim 7
set t_Co=256

" for vim 8
if (has("termguicolors"))
 set termguicolors
endif

colorscheme OceanicNext

Also installed vim 8 to test but no luck either 😕

mhartington commented 7 years ago

Using this minimal gist, I have not been able to replicate.

screen shot 2016-11-28 at 9 34 19 am

Using vim 8

VIM - Vi IMproved 8.0 (2016 Sep 12, compiled Nov 20 2016 19:04:13)
MacOS X (unix) version
Included patches: 1-94
shelldandy commented 7 years ago

Can it be because I'm using Vundle instead of Plug?

It almost looks like the previous oceanic next theme (the one im getting)

My current vimrc is this but i don't think I'm using any plugin that could mess with the colors

https://github.com/mike3run/dotfiles/blob/master/.vimrc

sittim commented 7 years ago

In my case for VIM8 and NeoVim colorscheme OceanicNext did not work, the following worked

let g:colors_name="OceanicNext"
let g:airline_theme='oceanicnext'

I do wonder why?

mhartington commented 7 years ago

That part should be fixed, in the last commit

https://github.com/mhartington/oceanic-next/commit/1b5d0b2e1569d1e2cde8ecc923ade90305228384#diff-e8a060cc160b2d21d9797efdd57a8fb7L10

shelldandy commented 7 years ago

captura de pantalla 2016-11-28 a la s 10 55 17

Still not working well at least now the background is not gray... but now i don't have any colors :/

sittim commented 7 years ago

Just updated it, now In VIM8, now it does not work at all, in NeoVim, you have to re-source the rc file after opening for it to work.

mhartington commented 7 years ago

@mike3run you should not need the let g:colors_name bit, that is already fixed. That is not the issue. Not sure on the vundle part, try vim-plug, as it is much easier and more modern.

@sittim please provide a minimal vimrc to test against.

Need to do work today, so I'll have to look tonight or in the next day, but PRs are always welcomed if you can fix it.

shelldandy commented 7 years ago

@mhartington i managed to somewhat fix it, so its funky inside tmux i already managed to enable everything however i see some blue backgrounds in every line of text

Is there a setting to take care of this?

captura de pantalla 2016-11-28 a la s 11 13 31

mhartington commented 7 years ago

That is not fixing things.... That is still broken

sittim commented 7 years ago

@mike3run, are you saying that it looks good outside of tmux and looks bad inside of tmux? If that is the case, take a look at:

https://github.com/icymind/NeoSolarized#truecolor-test

run the test in tmux, and follow the section Tmux to make it work inside the tmux...

sittim commented 7 years ago

Min .vimrc

call plug#begin('~/.vim/plugged')
Plug 'mhartington/oceanic-next'
call plug#end()

filetype plugin indent on " required

set termguicolors
set shell=bash

set t_8f=[38;2;%lu;%lu;%lum
set t_8b=[48;2;%lu;%lu;%lum

" ----- OceanicNext
"let g:colors_name="OceanicNext"
colorscheme OceanicNext
set background=dark
mhartington commented 7 years ago

@sittim these two lines break everything for me

set t_8f=�[38;2;%lu;%lu;%lum
set t_8b=�[48;2;%lu;%lu;%lum

what OS/terminal are you using?

@mike3run can you share your dot files. I'm not able to replicate. If you're trying to use a termguicolors, you'll need to enable them in tmux too.

set -g default-terminal "xterm-256color-italic"
set-option -ga terminal-overrides ',xterm-256color-italic:Tc'

http://homeonrails.com/2016/05/truecolor-in-gnome-terminal-tmux-and-neovim/

sittim commented 7 years ago

@mhartington, it works the same way in gnome terminal and in st, actually you do not need these two lines unless you use tmux, so just comment them out. I am using Ubuntu 16.04, which uses gnome terminal v 3.18.3

shelldandy commented 7 years ago

okay i've installed neovim and it kind of works inside on tmux

captura de pantalla 2016-11-28 a la s 19 22 20

This is with set background=dark with this the background and colors look okay-ish (still not exactly like the screenshots on JS for example)

captura de pantalla 2016-11-28 a la s 19 25 01

If I remove that attribute i get italic comments but the colors become poopy:

captura de pantalla 2016-11-28 a la s 19 21 46

mhartington commented 7 years ago

ok, so I've updated the readme, as I just removed italics for a bit.

@mike3run the set background=dark should not be there, since it's already taken care of by the theme. As the readme states:

" For Neovim 0.1.3 and 0.1.4
let $NVIM_TUI_ENABLE_TRUE_COLOR=1

" Or if you have Neovim >= 0.1.5
if (has("termguicolors"))
 set termguicolors
endif

" Theme
syntax enable
colorscheme OceanicNext

There is no need to call it.

sittim commented 7 years ago

Awesome, not setting the background works for me for both VIM8 and NeoVim, but I will wait for the ability turn off italics.

mhartington commented 7 years ago

@sittim italics have been removed since yesterday. Please pull the latest commits

olalonde commented 7 years ago

I had the same issues as @mike3run but ended fixing most of it by enabling true color support in tmux. Still have a color that is a bit off in tmux strangely and opened a new issue: https://github.com/mhartington/oceanic-next/issues/40