diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2011-04-04 23:35:45 +0200 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2011-04-04 23:35:45 +0200 |
commit | 7cf6ccee8c6b59d8aac17ab6e4673bcb69f5e8d2 (patch) | |
tree | b329db03bae14fca178add9909b78b050345c140 /xps/xps_tile.c | |
parent | efc46353676c27b24f2933dce78305796951a01e (diff) | |
download | mupdf-7cf6ccee8c6b59d8aac17ab6e4673bcb69f5e8d2.tar.xz |
Le Roi est mort, vive le Roi!
The run-together words are dead! Long live the underscores!
The postscript inspired naming convention of using all run-together
words has served us well, but it is now time for more readable code.
In this commit I have also added the sed script, rename.sed, that I used
to convert the source. Use it on your patches and application code.
Diffstat (limited to 'xps/xps_tile.c')
-rw-r--r-- | xps/xps_tile.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/xps/xps_tile.c b/xps/xps_tile.c index 22444ef2..eb972fad 100644 --- a/xps/xps_tile.c +++ b/xps/xps_tile.c @@ -22,16 +22,16 @@ struct closure static void xps_paint_tiling_brush_clipped(xps_context *ctx, fz_matrix ctm, fz_rect viewbox, struct closure *c) { - fz_path *path = fz_newpath(); + fz_path *path = fz_new_path(); fz_moveto(path, viewbox.x0, viewbox.y0); fz_lineto(path, viewbox.x0, viewbox.y1); fz_lineto(path, viewbox.x1, viewbox.y1); fz_lineto(path, viewbox.x1, viewbox.y0); fz_closepath(path); - ctx->dev->clippath(ctx->dev->user, path, 0, ctm); - fz_freepath(path); + ctx->dev->clip_path(ctx->dev->user, path, 0, ctm); + fz_free_path(path); c->func(ctx, ctm, viewbox, c->base_uri, c->dict, c->root, c->user); - ctx->dev->popclip(ctx->dev->user); + ctx->dev->pop_clip(ctx->dev->user); } static void @@ -119,11 +119,11 @@ xps_parse_tiling_brush(xps_context *ctx, fz_matrix ctm, fz_rect area, xps_parse_matrix_transform(ctx, transform_tag, &transform); ctm = fz_concat(transform, ctm); - viewbox = fz_unitrect; + viewbox = fz_unit_rect; if (viewbox_att) xps_parse_rectangle(ctx, viewbox_att, &viewbox); - viewport = fz_unitrect; + viewport = fz_unit_rect; if (viewport_att) xps_parse_rectangle(ctx, viewport_att, &viewport); @@ -168,8 +168,8 @@ xps_parse_tiling_brush(xps_context *ctx, fz_matrix ctm, fz_rect area, if (tile_mode != TILE_NONE) { int x0, y0, x1, y1; - fz_matrix invctm = fz_invertmatrix(ctm); - area = fz_transformrect(invctm, area); + fz_matrix invctm = fz_invert_matrix(ctm); + area = fz_transform_rect(invctm, area); x0 = floorf(area.x0 / xstep); y0 = floorf(area.y0 / ystep); x1 = ceilf(area.x1 / xstep); @@ -182,11 +182,11 @@ xps_parse_tiling_brush(xps_context *ctx, fz_matrix ctm, fz_rect area, bigview.x1 = bigview.x0 + xstep; bigview.y1 = bigview.y0 + ystep; if (n > 1) - ctx->dev->begintile(ctx->dev->user, area, bigview, xstep, ystep, ctm); + ctx->dev->begin_tile(ctx->dev->user, area, bigview, xstep, ystep, ctm); if (n > 0) xps_paint_tiling_brush(ctx, ctm, viewbox, tile_mode, &c); if (n > 1) - ctx->dev->endtile(ctx->dev->user); + ctx->dev->end_tile(ctx->dev->user); } #else { @@ -316,7 +316,7 @@ xps_parse_canvas(xps_context *ctx, fz_matrix ctm, fz_rect area, char *base_uri, xps_end_opacity(ctx, opacity_mask_uri, dict, opacity_att, opacity_mask_tag); if (clip_att || clip_tag) - ctx->dev->popclip(ctx->dev->user); + ctx->dev->pop_clip(ctx->dev->user); if (new_dict) xps_free_resource_dictionary(ctx, new_dict); @@ -345,7 +345,7 @@ xps_parse_fixed_page(xps_context *ctx, fz_matrix ctm, xps_page *page) if (!page->root) return; - area = fz_transformrect(fz_scale(page->width, page->height), fz_unitrect); + area = fz_transform_rect(fz_scale(page->width, page->height), fz_unit_rect); for (node = xml_down(page->root); node; node = xml_next(node)) { |