Is there a command line way to run gvim with a #ccffff color background?

56 views
Skip to first unread message

Steve Litt

unread,
Feb 9, 2025, 8:28:55 PMFeb 9
to vim...@googlegroups.com
Is there a command line way to run gvim with a #ccffff color background?

Thanks

SteveT

Steve Litt
http://444domains.com

chai...@fourbarlinkage.net

unread,
Feb 9, 2025, 8:39:42 PMFeb 9
to vim...@googlegroups.com
On Sunday, Feb 09, 2025 at 03:28 PM
:highlight Normal guibg=#ccffff

Tony Mechelynck

unread,
Feb 10, 2025, 1:50:30 AMFeb 10
to vim...@googlegroups.com
To run it always with that background, add the above line to your vimrc.

To do it once, run either
gvim --cmd "hi Normal guibg=#ccffff"
or
gvim -c "hi Normal guibg=#ccffff"

see
:help hl-Normal
:help highlight-guibg
:help --cmd
:help -c

Best regards,
Tony.

Steve Litt

unread,
Feb 10, 2025, 3:31:44 AMFeb 10
to vim...@googlegroups.com
Tony Mechelynck said on Mon, 10 Feb 2025 02:50:04 +0100

>On Sun, Feb 9, 2025 at 9:39 PM <chai...@fourbarlinkage.net> wrote:
>>
>> On Sunday, Feb 09, 2025 at 03:28 PM
>> Steve Litt <sl...@troubleshooters.com> wrote:
>>
>> > Is there a command line way to run gvim with a #ccffff color
>> > background?
>> >
>> > Thanks
>> >
>> > SteveT
>> >
>> > Steve Litt
>> > http://444domains.com
>> >
>>
>>
>> :highlight Normal guibg=#ccffff
>
>To run it always with that background, add the above line to your
>vimrc.
>
>To do it once, run either
> gvim --cmd "hi Normal guibg=#ccffff"
>or
> gvim -c "hi Normal guibg=#ccffff"


Thanks Tony and Chainsaw. This is what I needed, and I put it in my
menu.

Chainsaw

unread,
Feb 10, 2025, 1:47:51 PMFeb 10
to vim...@googlegroups.com
On Sunday, Feb 09, 2025 at 10:31 PM
Steve Litt <sl...@troubleshooters.com> wrote:

> Tony Mechelynck said on Mon, 10 Feb 2025 02:50:04 +0100
>
> >On Sun, Feb 9, 2025 at 9:39 PM <chai...@fourbarlinkage.net> wrote:
> >>
> >> On Sunday, Feb 09, 2025 at 03:28 PM
> >> Steve Litt <sl...@troubleshooters.com> wrote:
> >>
> >> > Is there a command line way to run gvim with a #ccffff color
> >> > background?
> >> >
> >> > Thanks
> >> >
> >> > SteveT
> >> >
> >> > Steve Litt
> >> > http://444domains.com
> >> >
> >>
> >>
> >> :highlight Normal guibg=#ccffff
> >
> >To run it always with that background, add the above line to your
> >vimrc.
> >
> >To do it once, run either
> > gvim --cmd "hi Normal guibg=#ccffff"
> >or
> > gvim -c "hi Normal guibg=#ccffff"
>
>
> Thanks Tony and Chainsaw. This is what I needed, and I put it in my
> menu.
>
> SteveT
>
> Steve Litt
>
> http://444domains.com
>

Here is another way triggered after loading a/any color scheme.

Say you want this to happen when you change to dracula colorcsheme:

augroup ColorschemeTweak
autocmd!
autocmd ColorScheme dracula highlight Normal guibg=#ccffff
augroup END

Or for any colorscheme:

augroup ColorschemeTweak
autocmd!
autocmd ColorScheme * highlight Normal guibg=#ccffff
augroup END

Oleg Zadorozhnyi

unread,
Feb 13, 2025, 5:09:28 AMFeb 13
to vim...@googlegroups.com
how to unsubscribe?

пн, 10 февр. 2025 г. в 15:47, Chainsaw <chai...@fourbarlinkage.net>:
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/20250210084729.000014a4%40fourbarlinkage.net.
Reply all
Reply to author
Forward
0 new messages