From f4c2c942ee9ee54812ae66cfd0abad81d1a5f0c5 Mon Sep 17 00:00:00 2001 From: Aaron Janse Date: Mon, 20 Apr 2020 16:59:08 -0700 Subject: [PATCH] fix bold --- render/cursor.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/render/cursor.go b/render/cursor.go index 9cd89b9..120953c 100644 --- a/render/cursor.go +++ b/render/cursor.go @@ -64,6 +64,10 @@ func deltaMarkup(fromCur, toCur Cursor) string { /* remove effects */ + if from.Bold && !to.Bold { + out += "\033[22m" + } + if from.Faint && !to.Faint { out += "\033[22m" } @@ -78,6 +82,10 @@ func deltaMarkup(fromCur, toCur Cursor) string { /* add effects */ + if !from.Bold && to.Bold { + out += "\033[1m" + } + if !from.Faint && to.Faint { out += "\033[2m" }