diff options
Diffstat (limited to 'xps')
-rw-r--r-- | xps/xpsgradient.c | 2 | ||||
-rw-r--r-- | xps/xpspage.c | 2 | ||||
-rw-r--r-- | xps/xpspath.c | 10 | ||||
-rw-r--r-- | xps/xpstile.c | 20 |
4 files changed, 17 insertions, 17 deletions
diff --git a/xps/xpsgradient.c b/xps/xpsgradient.c index 8baf6805..0c06ff15 100644 --- a/xps/xpsgradient.c +++ b/xps/xpsgradient.c @@ -567,7 +567,7 @@ xps_parse_gradient_brush(xps_context_t *ctx, fz_matrix ctm, xps_parse_render_transform(ctx, transform_att, &transform); if (transform_tag) xps_parse_matrix_transform(ctx, transform_tag, &transform); - ctm = fz_concat(ctm, transform); + ctm = fz_concat(transform, ctm); if (!stop_tag) { fz_warn("missing gradient stops tag"); diff --git a/xps/xpspage.c b/xps/xpspage.c index f27b4287..12547784 100644 --- a/xps/xpspage.c +++ b/xps/xpspage.c @@ -57,7 +57,7 @@ xps_parse_canvas(xps_context_t *ctx, fz_matrix ctm, char *base_uri, xps_resource xps_parse_render_transform(ctx, transform_att, &transform); if (transform_tag) xps_parse_matrix_transform(ctx, transform_tag, &transform); - ctm = fz_concat(ctm, transform); + ctm = fz_concat(transform, ctm); if (clip_att || clip_tag) { diff --git a/xps/xpspath.c b/xps/xpspath.c index bc1d3e34..f99db248 100644 --- a/xps/xpspath.c +++ b/xps/xpspath.c @@ -92,7 +92,7 @@ xps_draw_arc_segment(xps_context_t *ctx, fz_matrix mtx, float th0, float th1, in { float t, d; fz_point p; -return; // XXX broken + while (th1 < th0) th1 += M_PI * 2.0; @@ -251,9 +251,9 @@ xps_draw_arc(xps_context_t *ctx, } mtx = fz_identity; - mtx = fz_concat(mtx, fz_translate(cx, cy)); - mtx = fz_concat(mtx, fz_rotate(rotation_angle)); - mtx = fz_concat(mtx, fz_scale(rx, ry)); + mtx = fz_concat(fz_translate(cx, cy), mtx); + mtx = fz_concat(fz_rotate(rotation_angle), mtx); + mtx = fz_concat(fz_scale(rx, ry), mtx); xps_draw_arc_segment(ctx, mtx, th1, th1 + dth, is_clockwise); fz_lineto(ctx->path, point_x, point_y); @@ -946,7 +946,7 @@ xps_parse_path(xps_context_t *ctx, fz_matrix ctm, char *base_uri, xps_resource_t xps_parse_render_transform(ctx, transform_att, &transform); if (transform_tag) xps_parse_matrix_transform(ctx, transform_tag, &transform); - ctm = fz_concat(ctm, transform); + ctm = fz_concat(transform, ctm); if (clip_att || clip_tag) { diff --git a/xps/xpstile.c b/xps/xpstile.c index 2c91afa9..e6bcb8cf 100644 --- a/xps/xpstile.c +++ b/xps/xpstile.c @@ -42,22 +42,22 @@ xps_paint_tiling_brush(xps_context_t *ctx, fz_matrix ctm, fz_rect viewbox, int t if (tile_mode == TILE_FLIP_X || tile_mode == TILE_FLIP_X_Y) { - ttm = fz_concat(ctm, fz_translate(viewbox.x1 * 2, 0)); - ttm = fz_concat(ttm, fz_scale(-1, 1)); + ttm = fz_concat(fz_translate(viewbox.x1 * 2, 0), ctm); + ttm = fz_concat(fz_scale(-1, 1), ttm); xps_paint_tiling_brush_clipped(ctx, ttm, viewbox, c); } if (tile_mode == TILE_FLIP_Y || tile_mode == TILE_FLIP_X_Y) { - ttm = fz_concat(ctm, fz_translate(0, viewbox.y1 * 2)); - ttm = fz_concat(ttm, fz_scale(1, -1)); + ttm = fz_concat(fz_translate(0, viewbox.y1 * 2), ctm); + ttm = fz_concat(fz_scale(1, -1), ttm); xps_paint_tiling_brush_clipped(ctx, ttm, viewbox, c); } if (tile_mode == TILE_FLIP_X_Y) { - ttm = fz_concat(ctm, fz_translate(viewbox.x1 * 2, viewbox.y1 * 2)); - ttm = fz_concat(ttm, fz_scale(-1, -1)); + ttm = fz_concat(fz_translate(viewbox.x1 * 2, viewbox.y1 * 2), ctm); + ttm = fz_concat(fz_scale(-1, -1), ttm); xps_paint_tiling_brush_clipped(ctx, ttm, viewbox, c); } } @@ -152,10 +152,10 @@ xps_parse_tiling_brush(xps_context_t *ctx, fz_matrix ctm, xps_begin_opacity(ctx, ctm, base_uri, dict, opacity_att, NULL); - ctm = fz_concat(ctm, transform); - ctm = fz_concat(ctm, fz_translate(viewport.x0, viewport.y0)); - ctm = fz_concat(ctm, fz_scale(scalex, scaley)); - ctm = fz_concat(ctm, fz_translate(-viewbox.x0, -viewbox.y0)); + ctm = fz_concat(transform, ctm); + ctm = fz_concat(fz_translate(viewport.x0, viewport.y0), ctm); + ctm = fz_concat(fz_scale(scalex, scaley), ctm); + ctm = fz_concat(fz_translate(-viewbox.x0, -viewbox.y0), ctm); if (tile_mode != TILE_NONE) { |