common/graphic-helpers: Add cairo helpers

This commit is contained in:
Consolatis 2022-08-20 20:11:58 +02:00 committed by Johan Malm
parent 8c8583ef94
commit fb36463c34
4 changed files with 48 additions and 61 deletions

View file

@ -32,3 +32,13 @@ struct multi_rect *multi_rect_create(struct wlr_scene_tree *parent,
float *colors[3], int line_width);
void multi_rect_set_size(struct multi_rect *rect, int width, int height);
/**
* Sets the cairo color.
* Splits a float[4] single color array into its own arguments
*/
void set_cairo_color(cairo_t *cairo, float *color);
/* Draws a border with a specified line width */
void draw_cairo_border(cairo_t *cairo, double width, double height,
double line_width);