9front - general discussion about 9front
 help / color / mirror / Atom feed
* [~orib/Nail PATCH] Add thread links to bottom of message
@ 2020-11-22  0:30 Daniel Moch
  2020-11-23  1:06 ` [9front] " ori
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Moch @ 2020-11-22  0:30 UTC (permalink / raw)
  To: 9front

This usability patch places thread links at the bottom of displayed
messages in addition to the beginning to allow for easier thread
navigation.

diff -urN a/mesg.c b/mesg.c
--- a/mesg.c	Sat Nov 21 14:21:15 2020
+++ b/mesg.c	Sat Nov 21 19:19:21 2020
@@ -262,6 +262,15 @@
 	}
 
 	home = getenv("home");
+	if(m->parent != nil || m->nchild != 0) {
+		Bprint(wfd, "\n");
+		Bprint(wfd, "===> Thread:");
+		if(m->parent && !(m->parent->state & Sdummy))
+			Bprint(wfd, " ↑ %s", m->parent->name);
+		for(i = 0; i < m->nchild; i++)
+			Bprint(wfd, " ↓ %s", m->child[i]->name);
+		Bprint(wfd, "\n");
+	}
 	if(m->nparts != 0)
 		Bprint(wfd, "\n");
 	for(i = 0; i < m->nparts; i++){

-- 
Daniel Moch
https://djmo.ch



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-11-23  9:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-22  0:30 [~orib/Nail PATCH] Add thread links to bottom of message Daniel Moch
2020-11-23  1:06 ` [9front] " ori
2020-11-23  9:25   ` Daniel Moch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).