From 3deadb918f1ac034e4edf03e1ba88468ee76bd62 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Thu, 7 Nov 2013 16:42:54 +0100 Subject: util: add circle to special chars we can draw --- src/shared/macro.h | 2 -- src/shared/util.c | 2 ++ src/shared/util.h | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/shared/macro.h b/src/shared/macro.h index d3f4245d5d..9e94495dd6 100644 --- a/src/shared/macro.h +++ b/src/shared/macro.h @@ -278,11 +278,9 @@ do { \ */ #define F_TYPE_EQUAL(a, b) (a == (typeof(a)) b) - /* Returns the number of chars needed to format variables of the * specified type as a decimal string. Adds in extra space for a * negative '-' prefix. */ - #define DECIMAL_STR_MAX(type) \ (1+(sizeof(type) <= 1 ? 3 : \ sizeof(type) <= 2 ? 5 : \ diff --git a/src/shared/util.c b/src/shared/util.c index d753781c7a..7d41a7ae8d 100644 --- a/src/shared/util.c +++ b/src/shared/util.c @@ -5466,6 +5466,7 @@ const char *draw_special_char(DrawSpecialChar ch) { [DRAW_TREE_RIGHT] = "\342\224\224\342\224\200", /* └─ */ [DRAW_TREE_SPACE] = " ", /* */ [DRAW_TRIANGULAR_BULLET] = "\342\200\243 ", /* ‣ */ + [DRAW_BLACK_CIRCLE] = "\342\227\217 ", /* ● */ }, /* ASCII fallback */ { [DRAW_TREE_VERT] = "| ", @@ -5473,6 +5474,7 @@ const char *draw_special_char(DrawSpecialChar ch) { [DRAW_TREE_RIGHT] = "`-", [DRAW_TREE_SPACE] = " ", [DRAW_TRIANGULAR_BULLET] = "> ", + [DRAW_BLACK_CIRCLE] = "* ", } }; diff --git a/src/shared/util.h b/src/shared/util.h index 8b4c15512a..d46ff27f1c 100644 --- a/src/shared/util.h +++ b/src/shared/util.h @@ -622,6 +622,7 @@ typedef enum DrawSpecialChar { DRAW_TREE_RIGHT, DRAW_TREE_SPACE, DRAW_TRIANGULAR_BULLET, + DRAW_BLACK_CIRCLE, _DRAW_SPECIAL_CHAR_MAX } DrawSpecialChar; const char *draw_special_char(DrawSpecialChar ch); -- cgit v1.2.3-54-g00ecf