Fix regression: ANSI color in preview window not cleared

This commit is contained in:
Junegunn Choi 2017-07-21 16:43:00 +09:00
parent 18a1aeaa91
commit 06301c7847
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

View File

@ -882,8 +882,8 @@ func (w *LightWindow) CFill(fg Color, bg Color, attr Attr, text string) FillRetu
bg = w.bg bg = w.bg
} }
if w.csiColor(fg, bg, attr) { if w.csiColor(fg, bg, attr) {
return w.fill(text, func() { w.csiColor(fg, bg, attr) })
defer w.csi("m") defer w.csi("m")
return w.fill(text, func() { w.csiColor(fg, bg, attr) })
} }
return w.fill(text, w.setBg) return w.fill(text, w.setBg)
} }