summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrandon Wright <bearoso@gmail.com>2010-09-29 10:57:25 -0400
committerThomas Thurman <tthurman@gnome.org>2010-09-29 10:57:25 -0400
commitcc70022b6f0007e3edd3073a56a20ca281e998f5 (patch)
treee26bba5346e635a5692ae7a7251be8a175111916
parent9e88e554a1aa3c207c6361d55dcdc6b13acfefa2 (diff)
downloadmetacity-cc70022b6f0007e3edd3073a56a20ca281e998f5.tar.gz
metacity-cc70022b6f0007e3edd3073a56a20ca281e998f5.tar.bz2
Patch to fix theme breakage in 2.30.2; see bug 630426
-rw-r--r--src/ui/theme.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/src/ui/theme.c b/src/ui/theme.c
index 4184b1f..b19cfbf 100644
--- a/src/ui/theme.c
+++ b/src/ui/theme.c
@@ -3474,17 +3474,33 @@ meta_draw_op_draw_with_env (const MetaDrawOp *op,
if (y1 == y2)
{
+ if (x2 < x1)
+ {
+ x1 ^= x2;
+ x2 ^= x1;
+ x1 ^= x2;
+ }
cairo_move_to (cr, x1, y1 + offset);
cairo_line_to (cr, x2 + line_extend, y2 + offset);
}
else
{
+ if (y2 < y1)
+ {
+ y1 ^= y2;
+ y2 ^= y1;
+ y1 ^= y2;
+ }
cairo_move_to (cr, x1 + offset, y1);
cairo_line_to (cr, x2 + offset, y2 + line_extend);
}
}
else
{
+ if (op->data.line.width <= 0)
+ {
+ cairo_set_line_cap (cr, CAIRO_LINE_CAP_SQUARE);
+ }
cairo_move_to (cr, x1 + .5, y1 + .5);
cairo_line_to (cr, x2 + .5, y2 + .5);
}
@@ -3585,7 +3601,7 @@ meta_draw_op_draw_with_env (const MetaDrawOp *op,
meta_color_spec_render (op->data.tint.color_spec, widget, &color);
gdk_cairo_set_source_color (cr, &color);
- cairo_rectangle (cr, rx + .5, ry + .5, rwidth, rheight);
+ cairo_rectangle (cr, rx, ry, rwidth, rheight);
cairo_fill (cr);
}
else