aboutsummaryrefslogtreecommitdiffstats
path: root/systray/icon.h
diff options
context:
space:
mode:
authorNikita Langer <nikitalanger@icloud.com>2026-08-22 18:23:18 +0200
committerNikita Langer <nikitalanger@icloud.com>2026-08-22 18:23:18 +0200
commit98f342c73911d1ba4afcdcd36bd5b4fb9cade224 (patch)
tree1dd0db18d76f5af51e161f919179e84142c3cc25 /systray/icon.h
parent960d0661f6ed5ab6fd9c371c53a5f5b137864da1 (diff)
downloaddwl-master.tar.gz
dwl-master.tar.bz2
dwl-master.tar.xz
dwl-master.zip
systrayHEADmaster
Diffstat (limited to 'systray/icon.h')
-rw-r--r--systray/icon.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/systray/icon.h b/systray/icon.h
new file mode 100644
index 0000000..20f281b
--- /dev/null
+++ b/systray/icon.h
@@ -0,0 +1,26 @@
+#ifndef ICON_H
+#define ICON_H
+
+#include <fcft/fcft.h>
+#include <pixman.h>
+
+#include <stddef.h>
+#include <stdint.h>
+
+typedef const struct fcft_glyph FallbackIcon;
+
+typedef struct {
+ pixman_image_t *img;
+ uint32_t *buf_pixman;
+ uint8_t *buf_orig;
+ size_t size_orig;
+ size_t size_pixman;
+} Icon;
+
+Icon *createicon (const uint8_t *buf, int width, int height, int size);
+FallbackIcon *createfallbackicon (const char *appname, int fgcolor,
+ struct fcft_font *font);
+void destroyicon (Icon *icon);
+int resize_image (pixman_image_t *orig, int new_width, int new_height);
+
+#endif /* ICON_H */