Use default bg color when fg is set to -1 with reverse attribute

pull/2246/head
Junegunn Choi 4 years ago
parent c144c95cda
commit 15d351b0f0
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

@ -554,6 +554,9 @@ func initTheme(theme *ColorTheme, baseTheme *ColorTheme, forceBlack bool) {
func initPalette(theme *ColorTheme) {
pair := func(fg, bg ColorAttr) ColorPair {
if fg.Color == colDefault && (fg.Attr&Reverse) > 0 {
bg.Color = colDefault
}
return ColorPair{fg.Color, bg.Color, fg.Attr}
}
blank := theme.Fg

Loading…
Cancel
Save