summaryrefslogtreecommitdiff
path: root/lib/internal.h
diff options
context:
space:
mode:
authorJari Vetoniemi <mailroxas@gmail.com>2014-10-25 20:02:34 +0300
committerJari Vetoniemi <mailroxas@gmail.com>2014-10-25 20:02:34 +0300
commitd3db039136ad66d2c83c1c0fbf0964bfbb5afb16 (patch)
tree93af6d73ad168e0169183a9c4f625acd5492e08c /lib/internal.h
parent2820734ec01ad6d2e1a0611fa480c3dd533588c7 (diff)
downloadbemenu-d3db039136ad66d2c83c1c0fbf0964bfbb5afb16.tar.gz
bemenu-d3db039136ad66d2c83c1c0fbf0964bfbb5afb16.tar.bz2
bemenu-d3db039136ad66d2c83c1c0fbf0964bfbb5afb16.zip
Single line mode, color customization, etc..
Diffstat (limited to 'lib/internal.h')
-rw-r--r--lib/internal.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/lib/internal.h b/lib/internal.h
index 6613cef..b9b4a5e 100644
--- a/lib/internal.h
+++ b/lib/internal.h
@@ -134,6 +134,38 @@ struct bm_item {
};
/**
+ * Internal bm_hex_color struct that is not exposed to public.
+ * Represent a color for element.
+ */
+struct bm_hex_color {
+ /**
+ * Provided hex for the color.
+ */
+ char *hex;
+
+ /**
+ * RGB values.
+ */
+ uint8_t r, g, b;
+};
+
+/**
+ * Internal bm_font struct that is not exposed to public.
+ * Represent a font for text.
+ */
+struct bm_font {
+ /**
+ * Name of the font.
+ */
+ char *name;
+
+ /**
+ * Size of font.
+ */
+ uint32_t size;
+};
+
+/**
* Internal bm_menu struct that is not exposed to public.
*/
struct bm_menu {
@@ -169,6 +201,16 @@ struct bm_menu {
char *title;
/**
+ * Font.
+ */
+ struct bm_font font;
+
+ /**
+ * Colors.
+ */
+ struct bm_hex_color colors[BM_COLOR_LAST];
+
+ /**
* Text used to filter matches.
*/
char *filter;
@@ -200,6 +242,12 @@ struct bm_menu {
uint32_t index;
/**
+ * Max number of vertical lines to be shown.
+ * Some renderers such as ncurses may ignore this when it does not make sense.
+ */
+ uint32_t lines;
+
+ /**
* Current filtering method in menu instance.
*/
enum bm_filter_mode filter_mode;