cideM / yui

A minimal Vim/Neovim color scheme inspired by Dieter Rams
MIT License
135 stars 7 forks source link

Add ability to use colorscheme in lightline #22

Closed mambusskruj closed 2 years ago

mambusskruj commented 2 years ago

Hi!

Lightline is a popular light and configurable statusline/tabline plugin for Vim. – https://github.com/itchyny/lightline.vim

Lightline provides ability to configure colors for theme developers. Here's example for popular vim theme called gruvbox: https://github.com/morhetz/gruvbox/blob/master/autoload/lightline/colorscheme/gruvbox.vim

Would you mind to add colors for lightline in yui?

mambusskruj commented 2 years ago

I really enjoy your theme, btw!

cideM commented 2 years ago

Glad you like it 👍🏻 thank you. Sounds like a reasonable request I'll try to take care of it ASAP

cideM commented 2 years ago

I started working on this and I'll have a branch ready for you to try tomorrow, sorry for the delay

There's a lightline branch which you can test with

let g:yui_lightline = v:true
let g:lightline = {}
let g:lightline.colorscheme = 'yui'
call lightline#init()
call lightline#colorscheme()
call lightline#update()
mambusskruj commented 2 years ago

Hey! Hmm, I get error:

lightline.vim: Could not load colorscheme yui.

I see lightline block in colors/yui.vim


UPD: Ah, I get it now!

mambusskruj commented 2 years ago

Looks good!

Personally I'm not sure about bold text. For reference, lightline's solarized theme doesn't use any bold text, and it looks sharper to me. https://github.com/itchyny/lightline.vim#solarized-backgroundlight image

But it's all of your taste ofc. :) So for me it already looks very nice!

cideM commented 2 years ago

I agree that the solarized theme without bold text looks better. I'll take another look and tweak some colors and remove the bold, just need to make sure that contrast is good enough

cideM commented 2 years ago

@mambusskruj I pushed another commit to the branch which removes the bold

mambusskruj commented 2 years ago

Love it! Thank you, it looks very clean and pretty.

cideM commented 2 years ago

@mambusskruj I updated the documentation and made sure that the colorscheme uses the documented option. Would it be possible for you to check this again? I verified that the colorscheme works with and without lightline and that people can still use other lightline color schemes even when yui_lightline = v:true

I'll merge this soon then.

g:yui_lightline

let g:yui_lightline = v:true
colorscheme yui
let g:lightline = {
  \ 'colorscheme': 'yui'
  \ }
mambusskruj commented 2 years ago

Would it be possible for you to check this again?

Checked it. Yes, it works as you described it!