"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Mark Jamsek <mark@jamsek.com>
Subject:
tog: extend log view headline highlight
To:
Game of Trees <gameoftrees@openbsd.org>
Date:
Sat, 3 Sep 2022 23:46:14 +1000

Download raw body.

Thread
This is the same idea as the previous diff applied to the log view
headline: extend the highlight colour to the full width of the line.

Admittedly subjective again, but I think it looks better in splitscreen
when the log view is focussed.

diff /home/mark/src/got
commit - 58381f7013ee220415b44aaf36c549b2f1cd2937
path + /home/mark/src/got
blob - d3fe18a13136b64b9e9ba153ae5a2deda0482b9c
file + tog/tog.c
--- tog/tog.c
+++ tog/tog.c
@@ -2326,13 +2326,13 @@ draw_commits(struct tog_view *view)
 		wattr_on(view->window,
 		    COLOR_PAIR(tc->colorpair), NULL);
 	waddwstr(view->window, wline);
-	if (tc)
-		wattr_off(view->window,
-		    COLOR_PAIR(tc->colorpair), NULL);
 	while (width < view->ncols) {
 		waddch(view->window, ' ');
 		width++;
 	}
+	if (tc)
+		wattr_off(view->window,
+		    COLOR_PAIR(tc->colorpair), NULL);
 	if (view_needs_focus_indication(view))
 		wstandend(view->window);
 	free(wline);

-- 
Mark Jamsek <fnc.bsdbox.org>
GPG: F2FF 13DE 6A06 C471 CA80  E6E2 2930 DC66 86EE CF68