]> git.sur5r.net Git - i3/i3status/commitdiff
colorful ipv6 status message
authorLars Kumbier <larsscheithauer@googlemail.com>
Tue, 10 Jul 2012 13:26:08 +0000 (15:26 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Tue, 10 Jul 2012 18:37:54 +0000 (20:37 +0200)
src/print_ipv6_addr.c

index b7f668a4a6ba8353405f4a3268b17472ddbbfb17..abf45081b3ea6b1daaa67c9fde714f57e1cb4032 100644 (file)
@@ -119,7 +119,9 @@ void print_ipv6_info(yajl_gen json_gen, char *buffer, const char *format_up, con
         char *outwalk = buffer;
 
         if (addr_string == NULL) {
+                START_COLOR("color_bad");
                 OUTPUT_FULL_TEXT(format_down);
+                END_COLOR;
                 return;
         }
 
@@ -134,6 +136,7 @@ void print_ipv6_info(yajl_gen json_gen, char *buffer, const char *format_up, con
                         walk += strlen("ip");
                 }
         }
-
+        START_COLOR("color_good");
         OUTPUT_FULL_TEXT(buffer);
+        END_COLOR;
 }