Skip to content
Snippets Groups Projects
Unverified Commit 972fb1a2 authored by Junegunn Choi's avatar Junegunn Choi
Browse files

Suppress ANSI colors in preview window if --no-color is set

parent 3a6af275
No related branches found
No related tags found
No related merge requests found
......@@ -958,7 +958,7 @@ func (t *Terminal) printPreview() {
trimmed, _ = t.trimRight(trimmed, maxWidth-t.pwindow.X())
}
str, _ = t.processTabs(trimmed, 0)
if ansi != nil && ansi.colored() {
if t.theme != nil && ansi != nil && ansi.colored() {
fillRet = t.pwindow.CFill(ansi.fg, ansi.bg, ansi.attr, str)
} else {
fillRet = t.pwindow.Fill(str)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment