mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-03 12:35:58 +00:00
Bug 285475 - fix cairo calculation of stroke extents on lines with caps.
This commit is contained in:
parent
349d1fef20
commit
4c1bc91ccf
@ -17,3 +17,5 @@ PATCHES:
|
||||
quartz.diff - update cairo quartz/atsui backend for 0.4.0, reenable.
|
||||
|
||||
xlib.diff - include X11/xlib.h in cairo-xlib.h - needed for Solaris.
|
||||
|
||||
stroke-extent.diff - fix calculation of stroke extents.
|
||||
|
@ -1700,6 +1700,8 @@ _cairo_gstate_stroke_extents (cairo_gstate_t *gstate,
|
||||
cairo_status_t status;
|
||||
cairo_traps_t traps;
|
||||
cairo_box_t extents;
|
||||
|
||||
_cairo_pen_init (&gstate->pen_regular, gstate->line_width / 2.0, gstate);
|
||||
|
||||
_cairo_traps_init (&traps);
|
||||
|
||||
|
21
gfx/cairo/stroke-extent.diff
Normal file
21
gfx/cairo/stroke-extent.diff
Normal file
@ -0,0 +1,21 @@
|
||||
--- cairo-0.4.0/src/cairo_gstate.c 2005-03-04 11:57:53.000000000 -0600
|
||||
+++ cairo/src/cairo_gstate.c 2005-03-30 11:16:57.576419878 -0600
|
||||
@@ -1695,16 +1695,18 @@ _cairo_gstate_show_page (cairo_gstate_t
|
||||
cairo_status_t
|
||||
_cairo_gstate_stroke_extents (cairo_gstate_t *gstate,
|
||||
double *x1, double *y1,
|
||||
double *x2, double *y2)
|
||||
{
|
||||
cairo_status_t status;
|
||||
cairo_traps_t traps;
|
||||
cairo_box_t extents;
|
||||
+
|
||||
+ _cairo_pen_init (&gstate->pen_regular, gstate->line_width / 2.0, gstate);
|
||||
|
||||
_cairo_traps_init (&traps);
|
||||
|
||||
status = _cairo_path_stroke_to_traps (&gstate->path, gstate, &traps);
|
||||
if (status)
|
||||
goto BAIL;
|
||||
|
||||
_cairo_traps_extents (&traps, &extents);
|
Loading…
x
Reference in New Issue
Block a user