diff options
author | Thomas White <taw@bitwiz.org.uk> | 2015-01-03 18:50:15 +0000 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2015-01-03 18:50:15 +0000 |
commit | 94d1b5ea051bd4a6cb41ed0b2bc9b90f461c6e71 (patch) | |
tree | eccf4aca724461772a33dc6c963932b295bf733b /src/shape.c | |
parent | a68d64edca4f67df49b9499272319cad93d38bbe (diff) |
Thumbnails!
Diffstat (limited to 'src/shape.c')
-rw-r--r-- | src/shape.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/shape.c b/src/shape.c index ab5199b..d51186c 100644 --- a/src/shape.c +++ b/src/shape.c @@ -131,8 +131,8 @@ static int add_wrap_boxes(struct wrap_line *line, const char *text, } -void add_surface_box(struct wrap_line *line, cairo_surface_t *surf, - double w, double h) +void add_callback_box(struct wrap_line *line, double w, double h, + SCCallbackDrawFunc func, void *bvp, void *vp) { struct wrap_box *box; @@ -143,14 +143,16 @@ void add_surface_box(struct wrap_line *line, cairo_surface_t *surf, } box = &line->boxes[line->n_boxes]; - box->type = WRAP_BOX_SURFACE; + box->type = WRAP_BOX_CALLBACK; box->scblock = NULL; box->offs_char = 0; box->space = WRAP_SPACE_NONE; box->width = pango_units_from_double(w); box->ascent = pango_units_from_double(h); box->height = pango_units_from_double(h); - box->surf = surf; + box->draw_func = func; + box->bvp = bvp; + box->vp = vp; box->editable = 0; line->n_boxes++; } |