about summary refs log tree commit diff stats
path: root/src/ui/console.c
diff options
context:
space:
mode:
authorMichael Vetter <jubalh@iodoru.org>2020-05-21 16:04:26 +0200
committerMichael Vetter <jubalh@iodoru.org>2020-05-21 16:15:14 +0200
commitcb78ee46656972a5481ad0241fb50dc0e0d02413 (patch)
tree8d4b45ec8345324320bfaf13ee2208b9035041c6 /src/ui/console.c
parente41ae21bea63484645c0ef5f98e870bd80bc1c8c (diff)
downloadprofani-tty-cb78ee46656972a5481ad0241fb50dc0e0d02413.tar.gz
Make option to allow hiding windows with no messages in statusbar
`statusbar.show.read` can be set to false in the config.
`/statusbar show|hide read`.

Implement https://github.com/profanity-im/profanity/issues/1285
Diffstat (limited to 'src/ui/console.c')
-rw-r--r--src/ui/console.c28
1 files changed, 17 insertions, 11 deletions
diff --git a/src/ui/console.c b/src/ui/console.c
index ce963c8c..4a1c58d4 100644
--- a/src/ui/console.c
+++ b/src/ui/console.c
@@ -1795,39 +1795,45 @@ void
 cons_statusbar_setting(void)
 {
     if (prefs_get_boolean(PREF_STATUSBAR_SHOW_NAME)) {
-        cons_show("Show tab names (/statusbar)         : ON");
+        cons_show("Show tab names (/statusbar)                 : ON");
     } else {
-        cons_show("Show tab names (/statusbar)         : OFF");
+        cons_show("Show tab names (/statusbar)                 : OFF");
     }
     if (prefs_get_boolean(PREF_STATUSBAR_SHOW_NUMBER)) {
-        cons_show("Show tab numbers (/statusbar)       : ON");
+        cons_show("Show tab numbers (/statusbar)               : ON");
     } else {
-        cons_show("Show tab numbers (/statusbar)       : OFF");
+        cons_show("Show tab numbers (/statusbar)               : OFF");
     }
 
-    cons_show("Max tabs (/statusbar)               : %d", prefs_get_statusbartabs());
+    if (prefs_get_boolean(PREF_STATUSBAR_SHOW_NUMBER)) {
+        cons_show("Show tab with no actions (/statusbar)       : ON");
+    } else {
+        cons_show("Show tab with no actions (/statusbar)       : OFF");
+    }
+
+    cons_show("Max tabs (/statusbar)                       : %d", prefs_get_statusbartabs());
 
     gint pref_len = prefs_get_statusbartablen();
     if (pref_len == 0) {
-        cons_show("Max tab length (/statusbar)         : OFF");
+        cons_show("Max tab length (/statusbar)                 : OFF");
     } else {
-        cons_show("Max tab length (/statusbar)         : %d", pref_len);
+        cons_show("Max tab length (/statusbar)                 : %d", pref_len);
     }
 
     char *pref_self = prefs_get_string(PREF_STATUSBAR_SELF);
     if (g_strcmp0(pref_self, "off") == 0) {
-        cons_show("Self statusbar display (/statusbar) : OFF");
+        cons_show("Self statusbar display (/statusbar)         : OFF");
     } else {
-        cons_show("Self statusbar display (/statusbar) : %s", pref_self);
+        cons_show("Self statusbar display (/statusbar)         : %s", pref_self);
     }
     prefs_free_string(pref_self);
 
     char *pref_chat = prefs_get_string(PREF_STATUSBAR_CHAT);
-    cons_show("Chat tab display (/statusbar)       : %s", pref_chat);
+    cons_show("Chat tab display (/statusbar)               : %s", pref_chat);
     prefs_free_string(pref_chat);
 
     char *pref_room = prefs_get_string(PREF_STATUSBAR_ROOM);
-    cons_show("Room tab display (/statusbar)       : %s", pref_room);
+    cons_show("Room tab display (/statusbar)               : %s", pref_room);
     prefs_free_string(pref_room);
 }