From b5a804d1afaef1969de9c32060808fefb81a91e7 Mon Sep 17 00:00:00 2001 From: Felix Buehler Date: Mon, 10 Feb 2020 18:52:04 +0100 Subject: use format_placeholder for battery --- include/i3status.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'include') diff --git a/include/i3status.h b/include/i3status.h index 2e314b1..95e6eba 100644 --- a/include/i3status.h +++ b/include/i3status.h @@ -198,6 +198,20 @@ char *endcolor() __attribute__((pure)); void reset_cursor(void); void maybe_escape_markup(char *text, char **buffer); +char *rtrim(const char *s); +char *ltrim(const char *s); +char *trim(const char *s); + +// copied from i3:libi3/format_placeholders.c +/* src/format_placeholders.c */ +typedef struct { + /* The placeholder to be replaced, e.g., "%title". */ + char *name; + /* The value this placeholder should be replaced with. */ + char *value; +} placeholder_t; +char *format_placeholders(const char *format, placeholder_t *placeholders, int num); + /* src/auto_detect_format.c */ char *auto_detect_format(); -- cgit v1.2.3