about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2015-11-22 00:54:40 +0000
committerJames Booth <boothj5@gmail.com>2015-11-22 00:54:40 +0000
commit3d1299eb1e9f323bb49af0c8f553cdb00752e7e2 (patch)
tree7401c6e6b900a3acddbed23a058dfe6736f8a456
parentb4482b9fe1cb121500b85e2716c561d55215afaa (diff)
downloadprofani-tty-3d1299eb1e9f323bb49af0c8f553cdb00752e7e2.tar.gz
Renamed subwin functions
-rw-r--r--src/ui/occupantswin.c12
-rw-r--r--src/ui/rosterwin.c34
-rw-r--r--src/ui/window.c4
-rw-r--r--src/ui/window.h4
4 files changed, 27 insertions, 27 deletions
diff --git a/src/ui/occupantswin.c b/src/ui/occupantswin.c
index 71474a80..3c1d9dd5 100644
--- a/src/ui/occupantswin.c
+++ b/src/ui/occupantswin.c
@@ -48,13 +48,13 @@ _occuptantswin_occupant(ProfLayoutSplit *layout, Occupant *occupant, gboolean sh
 
     GString *msg = g_string_new("   ");
     g_string_append(msg, occupant->nick);
-    win_print_nowrap(layout->subwin, msg->str, TRUE);
+    win_sub_print_nowrap(layout->subwin, msg->str, TRUE);
     g_string_free(msg, TRUE);
 
     if (showjid && occupant->jid) {
         GString *msg = g_string_new("     ");
         g_string_append(msg, occupant->jid);
-        win_print_nowrap(layout->subwin, msg->str, TRUE);
+        win_sub_print_nowrap(layout->subwin, msg->str, TRUE);
         g_string_free(msg, TRUE);
     }
 
@@ -75,7 +75,7 @@ occupantswin_occupants(const char *const roomjid)
 
             if (prefs_get_boolean(PREF_MUC_PRIVILEGES)) {
                 wattron(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
-                win_print_nowrap(layout->subwin, " -Moderators", TRUE);
+                win_sub_print_nowrap(layout->subwin, " -Moderators", TRUE);
                 wattroff(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
                 GList *roster_curr = occupants;
                 while (roster_curr) {
@@ -87,7 +87,7 @@ occupantswin_occupants(const char *const roomjid)
                 }
 
                 wattron(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
-                win_print_nowrap(layout->subwin, " -Participants", TRUE);
+                win_sub_print_nowrap(layout->subwin, " -Participants", TRUE);
                 wattroff(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
                 roster_curr = occupants;
                 while (roster_curr) {
@@ -99,7 +99,7 @@ occupantswin_occupants(const char *const roomjid)
                 }
 
                 wattron(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
-                win_print_nowrap(layout->subwin, " -Visitors", TRUE);
+                win_sub_print_nowrap(layout->subwin, " -Visitors", TRUE);
                 wattroff(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
                 roster_curr = occupants;
                 while (roster_curr) {
@@ -111,7 +111,7 @@ occupantswin_occupants(const char *const roomjid)
                 }
             } else {
                 wattron(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
-                win_print_nowrap(layout->subwin, " -Occupants\n", TRUE);
+                win_sub_print_nowrap(layout->subwin, " -Occupants\n", TRUE);
                 wattroff(layout->subwin, theme_attrs(THEME_OCCUPANTS_HEADER));
                 GList *roster_curr = occupants;
                 while (roster_curr) {
diff --git a/src/ui/rosterwin.c b/src/ui/rosterwin.c
index bc04511c..79293fc6 100644
--- a/src/ui/rosterwin.c
+++ b/src/ui/rosterwin.c
@@ -68,7 +68,7 @@ _rosterwin_presence(ProfLayoutSplit *layout, theme_item_t colour, const char *pr
             if (presence_indent == -1) {
                 GString *msg = g_string_new("");
                 g_string_append_printf(msg, ": \"%s\"", status);
-                win_print_nowrap(layout->subwin, msg->str, FALSE);
+                win_sub_print_nowrap(layout->subwin, msg->str, FALSE);
                 g_string_free(msg, TRUE);
                 wattroff(layout->subwin, theme_attrs(colour));
             } else {
@@ -78,8 +78,8 @@ _rosterwin_presence(ProfLayoutSplit *layout, theme_item_t colour, const char *pr
                     current_indent--;
                 }
                 g_string_append_printf(msg, "\"%s\"", status);
-                win_newline_lazy(layout->subwin);
-                win_print_nowrap(layout->subwin, msg->str, FALSE);
+                win_sub_newline_lazy(layout->subwin);
+                win_sub_print_nowrap(layout->subwin, msg->str, FALSE);
                 g_string_free(msg, TRUE);
                 wattroff(layout->subwin, theme_attrs(colour));
             }
@@ -98,7 +98,7 @@ _rosterwin_presence(ProfLayoutSplit *layout, theme_item_t colour, const char *pr
             } else if (status && prefs_get_boolean(PREF_ROSTER_STATUS)) {
                 g_string_append_printf(msg, ": \"%s\"", status);
             }
-            win_print_nowrap(layout->subwin, msg->str, FALSE);
+            win_sub_print_nowrap(layout->subwin, msg->str, FALSE);
             g_string_free(msg, TRUE);
             wattroff(layout->subwin, theme_attrs(colour));
         } else {
@@ -115,8 +115,8 @@ _rosterwin_presence(ProfLayoutSplit *layout, theme_item_t colour, const char *pr
             } else if (status && prefs_get_boolean(PREF_ROSTER_STATUS)) {
                 g_string_append_printf(msg, "\"%s\"", status);
             }
-            win_newline_lazy(layout->subwin);
-            win_print_nowrap(layout->subwin, msg->str, FALSE);
+            win_sub_newline_lazy(layout->subwin);
+            win_sub_print_nowrap(layout->subwin, msg->str, FALSE);
             g_string_free(msg, TRUE);
             wattroff(layout->subwin, theme_attrs(colour));
         }
@@ -150,8 +150,8 @@ _rosterwin_resources(ProfLayoutSplit *layout, PContact contact, int current_inde
             if (prefs_get_boolean(PREF_ROSTER_PRIORITY)) {
                 g_string_append_printf(msg, " %d", resource->priority);
             }
-            win_newline_lazy(layout->subwin);
-            win_print_nowrap(layout->subwin, msg->str, FALSE);
+            win_sub_newline_lazy(layout->subwin);
+            win_sub_print_nowrap(layout->subwin, msg->str, FALSE);
             g_string_free(msg, TRUE);
             wattroff(layout->subwin, theme_attrs(resource_presence_colour));
 
@@ -196,8 +196,8 @@ _rosterwin_contact(ProfLayoutSplit *layout, PContact contact)
         g_string_append_printf(msg, "%c", ch);
     }
     g_string_append(msg, name);
-    win_newline_lazy(layout->subwin);
-    win_print_nowrap(layout->subwin, msg->str, FALSE);
+    win_sub_newline_lazy(layout->subwin);
+    win_sub_print_nowrap(layout->subwin, msg->str, FALSE);
     g_string_free(msg, TRUE);
     wattroff(layout->subwin, theme_attrs(presence_colour));
 
@@ -216,7 +216,7 @@ _rosterwin_contacts_by_presence(ProfLayoutSplit *layout, const char *const prese
     // if this group has contacts, or if we want to show empty groups
     if (contacts || prefs_get_boolean(PREF_ROSTER_EMPTY)) {
         if (newline) {
-            win_newline_lazy(layout->subwin);
+            win_sub_newline_lazy(layout->subwin);
         }
         wattron(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
         GString *title_str = g_string_new(" ");
@@ -228,7 +228,7 @@ _rosterwin_contacts_by_presence(ProfLayoutSplit *layout, const char *const prese
         if (prefs_get_boolean(PREF_ROSTER_COUNT)) {
             g_string_append_printf(title_str, " (%d)", g_slist_length(contacts));
         }
-        win_print_nowrap(layout->subwin, title_str->str, FALSE);
+        win_sub_print_nowrap(layout->subwin, title_str->str, FALSE);
         g_string_free(title_str, TRUE);
         wattroff(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
     }
@@ -260,7 +260,7 @@ _rosterwin_contacts_by_group(ProfLayoutSplit *layout, char *group, gboolean newl
 
     if (contacts || prefs_get_boolean(PREF_ROSTER_EMPTY)) {
         if (newline) {
-            win_newline_lazy(layout->subwin);
+            win_sub_newline_lazy(layout->subwin);
         }
         wattron(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
         GString *title = g_string_new(" ");
@@ -272,7 +272,7 @@ _rosterwin_contacts_by_group(ProfLayoutSplit *layout, char *group, gboolean newl
         if (prefs_get_boolean(PREF_ROSTER_COUNT)) {
             g_string_append_printf(title, " (%d)", g_slist_length(contacts));
         }
-        win_print_nowrap(layout->subwin, title->str, FALSE);
+        win_sub_print_nowrap(layout->subwin, title->str, FALSE);
         g_string_free(title, TRUE);
         wattroff(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
 
@@ -302,7 +302,7 @@ _rosterwin_contacts_by_no_group(ProfLayoutSplit *layout, gboolean newline)
 
     if (contacts || prefs_get_boolean(PREF_ROSTER_EMPTY)) {
         if (newline) {
-            win_newline_lazy(layout->subwin);
+            win_sub_newline_lazy(layout->subwin);
         }
         wattron(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
         GString *title = g_string_new(" ");
@@ -315,7 +315,7 @@ _rosterwin_contacts_by_no_group(ProfLayoutSplit *layout, gboolean newline)
         if (prefs_get_boolean(PREF_ROSTER_COUNT)) {
             g_string_append_printf(title, " (%d)", g_slist_length(contacts));
         }
-        win_print_nowrap(layout->subwin, title->str, FALSE);
+        win_sub_print_nowrap(layout->subwin, title->str, FALSE);
         g_string_free(title, TRUE);
         wattroff(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
 
@@ -387,7 +387,7 @@ rosterwin_roster(void)
         if (prefs_get_boolean(PREF_ROSTER_COUNT)) {
             g_string_append_printf(title, " (%d)", g_slist_length(contacts));
         }
-        win_print_nowrap(layout->subwin, title->str, FALSE);
+        win_sub_print_nowrap(layout->subwin, title->str, FALSE);
         g_string_free(title, TRUE);
         wattroff(layout->subwin, theme_attrs(THEME_ROSTER_HEADER));
 
diff --git a/src/ui/window.c b/src/ui/window.c
index c40e3547..d6a87fc6 100644
--- a/src/ui/window.c
+++ b/src/ui/window.c
@@ -1266,7 +1266,7 @@ win_unread(ProfWin *window)
 }
 
 void
-win_print_nowrap(WINDOW *win, char *msg, gboolean newline)
+win_sub_print_nowrap(WINDOW *win, char *msg, gboolean newline)
 {
     int maxx = getmaxx(win);
     int curx = getcurx(win);
@@ -1280,7 +1280,7 @@ win_print_nowrap(WINDOW *win, char *msg, gboolean newline)
 }
 
 void
-win_newline_lazy(WINDOW *win)
+win_sub_newline_lazy(WINDOW *win)
 {
     int curx = getcurx(win);
     if (curx > 0) {
diff --git a/src/ui/window.h b/src/ui/window.h
index 0a01b37f..a8424369 100644
--- a/src/ui/window.h
+++ b/src/ui/window.h
@@ -67,8 +67,8 @@ void win_newline(ProfWin *window);
 void win_redraw(ProfWin *window);
 int win_roster_cols(void);
 int win_occpuants_cols(void);
-void win_print_nowrap(WINDOW *win, char *msg, gboolean newline);
-void win_newline_lazy(WINDOW *win);
+void win_sub_print_nowrap(WINDOW *win, char *msg, gboolean newline);
+void win_sub_newline_lazy(WINDOW *win);
 void win_mark_received(ProfWin *window, const char *const id);
 
 gboolean win_has_active_subwin(ProfWin *window);