#ifndef COMET_LAYOUT_H #define COMET_LAYOUT_H #include #include #include #include "block.h" typedef struct { PangoFontDescription *fontdesc; PangoContext *context; int x_offset; int height; } layout_info_t; typedef struct layout { block_t *block; int x, y; int x_padding, y_padding; int width, height; int text_width, text_height; PangoLayout *pl; int n_children; struct layout *children; } layout_t; void layout_init(layout_t *layout, block_t *block, layout_info_t info); void layout_render(layout_t *layout, cairo_t *cr); void layout_free(layout_t *layout); #endif