Remove the topic label from channel headers

This commit is contained in:
Johannes Findeisen 2026-11-29 07:12:19 +01:00
commit 67b3b2fb87
2 changed files with 2 additions and 4 deletions

View file

@ -111,7 +111,7 @@ Build yours by copying `irc9rc-example` to `irc9rc` next to the binary (or to
```
[irc9] irc.example / #general
/----------------------\----------------------------------------
|*irc.example | Topic: General discussion
|*irc.example | General discussion
| |----------------------------------------
| |-#general |
| |-#help(3) |

4
irc9.c
View file

@ -2569,9 +2569,7 @@ static int layout_topic(int draw)
if (!curwin || curwin->type != W_CHANNEL || mainh < 1 || width < 1)
return 0;
char topic[MAXLINE + sizeof "Topic: "];
snprintf(topic, sizeof topic, "Topic: %s",
curwin->topic[0] ? curwin->topic : "(no topic)");
const char *topic = curwin->topic[0] ? curwin->topic : "(no topic)";
char *rows[MAXWRAPROWS];
int count = 0;
push_wrapped(rows, &count, MAXWRAPROWS, topic, width);