#ifndef COMET_DRAW_H #define COMET_DRAW_H #include #include #include #include "window.h" #include "button.h" typedef struct Drawable Drawable; struct Drawable { int height; int left_pad; int right_pad; int top_pad; double alpha; int line_w; GList *layouts; PangoFontDescription *desc; }; typedef struct { Button *btn; int x, y; int width, height; int text_w, text_h; PangoLayout *pl; } Layout; Drawable *draw_create(const char *font, int height, int left_pad, int right_pad, int top_pad, double alpha, int line_w); void draw_compute_layout(Drawable *draw, Window *win, GList *btns); void draw_paint(Drawable *draw, Window *win); void draw_destroy(Drawable *draw); #endif // vim: ts=4 sw=4 et