blob: 3e7c1b36659bd3b93b432d079c0364844d39ab08 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
struct dimensions {
int row_count; /* rows */
int column_count; /* columns */
double paper_width; /* paper width */
double paper_height; /* paper height */
double month_width; /* month width */
double month_height; /* month height */
double month_top_corner_x;
double month_top_corner_y;
double day_width; /* day box width */
double day_height; /* day box height */
double margin; /* margin */
};
int fill_bg(cairo_t *c);
int draw_text(cairo_t *c, double x, double y, char *text);
int calculate_dimensions(double pw, double ph, struct dimensions *d);
int print_dimensions(struct dimensions *d);
//int draw_month_grid (cairo_t *c, struct dimensions *d);
int draw_month (cairo_t *c, cairo_t *cd, cairo_surface_t *s, struct dimensions *d, int days_in_month, int start_day);
int day_of_week (int d, int m, int y);
|