aboutsummaryrefslogtreecommitdiff
path: root/src/draw.h
diff options
context:
space:
mode:
authorfoswret2026-05-08 22:20:02 -0500
committerfoswret2026-05-08 22:20:02 -0500
commit820a647eb2ad5e1b424acd72a4cf7362cfda2e8a (patch)
tree76189a8b9e8bd64f2c439bb02305b7725db0bb97 /src/draw.h
parentf0c9538a77c942ac96aebe52319f3e127be230ee (diff)
Shrink default month-grid size, render month art comfortably
Diffstat (limited to 'src/draw.h')
-rw-r--r--src/draw.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/draw.h b/src/draw.h
index 5955e1e..40ca609 100644
--- a/src/draw.h
+++ b/src/draw.h
@@ -10,6 +10,8 @@ struct dimensions {
double day_width; /* day box width */
double day_height; /* day box height */
double margin; /* margin */
+ double header_width;
+ double header_height;
};
int fill_bg(cairo_t *c);
@@ -21,8 +23,10 @@ struct RGB {
};
struct month_info {
+ int month_position;
int first_day;
int num_of_days;
+ int minimum_rows;
};
struct RGB hex_to_rgb(char *str);
@@ -41,7 +45,7 @@ int draw_month (cairo_t *c, cairo_t *cd, cairo_surface_t *s, struct month_info *
int day_of_week (int d, int m, int y);
-int draw_month_title(cairo_t *c, struct dimensions *d, char *name);
+int draw_month_title(cairo_t *c, struct dimensions *d, char *font_family, int font_size, char *name);
PangoRectangle get_logical_extents (cairo_t *c, char *font_family, int font_size, char *text);
@@ -51,4 +55,4 @@ int draw_image(cairo_t *c, char *path, double x, double y);
int draw_month_art(cairo_t *c, struct dimensions *d, char *path);
-
+int construct_day_box(cairo_t *cd, int month, int day, int week_day);