pansz wrote:
> Hi,
> 
> Vim 7.2.93 in Konsole.
> 
> I'd tested that when I set hi Normal ctermbg=NONE in a script, the 
> following ctermbg=bg statements after that line will issue error E420e.
> 
> Is this a bug or a feature?

I believe it is by design. Vim permits the use of "bg" as a color name 
if and only if the background color is known: i.e., if you've set it 
explicitly to a color value.

<<< From help >>>
When Vim knows the normal foreground and background colors, "fg" and 
"bg" can be used as color names.  This only works after setting the 
colors for the Normal group and for the MS-DOS console.
<<< End help >>>

When NONE is used, Vim doesn't know the normal background color because 
it doesn't set it. I agree, though, that it would be nice if Vim would 
allow you to say, "Make this group's background match that of the Normal 
group: if the Normal group uses the terminal's default, fine; otherwise, 
use the specific color used by the Normal group." Actually, though, I 
think this would be more useful for setting foreground color equal to 
background color, but I don't think all terminal's give Vim a way to do 
this...

Brett Stahlman



> 
> Basically, hi Normal ctermbg=NONE will use a "transparent" background, 
> i.e. the same background as the terminal emulator regardless of what it 
> is. the ctermbg=bg indicates the highlight group uses the same value as 
> the Normal group, which can be handy in many cases. It is strange why 
> ctermbg=bg is a error when the Normal group has ctermbg=NONE.
> 
> Any hints?
> 
> 
> > 
> 

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to