aboutsummaryrefslogtreecommitdiffstats
path: root/swaybar/status_line.h
diff options
context:
space:
mode:
Diffstat (limited to 'swaybar/status_line.h')
-rw-r--r--swaybar/status_line.h45
1 files changed, 45 insertions, 0 deletions
diff --git a/swaybar/status_line.h b/swaybar/status_line.h
new file mode 100644
index 00000000..36020aeb
--- /dev/null
+++ b/swaybar/status_line.h
@@ -0,0 +1,45 @@
1#ifndef _SWAYBAR_STATUS_LINE_H
2#define _SWAYBAR_STATUS_LINE_H
3
4#include <stdint.h>
5#include <stdbool.h>
6
7#include "list.h"
8#include "state.h"
9
10typedef enum {UNDEF, TEXT, I3BAR} command_protocol;
11
12struct status_line {
13 list_t *block_line;
14 char *text_line;
15 command_protocol protocol;
16};
17
18struct status_block {
19 char *full_text, *short_text, *align;
20 bool urgent;
21 uint32_t color;
22 int min_width;
23 char *name, *instance;
24 bool separator;
25 int separator_block_width;
26 // Airblader features
27 uint32_t background;
28 uint32_t border;
29 int border_top;
30 int border_bottom;
31 int border_left;
32 int border_right;
33};
34
35/**
36 * Initialize status line struct.
37 */
38struct status_line *init_status_line();
39
40/**
41 * handle status line activity.
42 */
43bool handle_status_line(struct swaybar_state *st);
44
45#endif /* _SWAYBAR_STATUS_LINE_H */