[gtksourceview] view: small drawing fix for line background



commit fd61f6073b6ec44c1d5c4cceda8fedad48bfa0e0
Author: Paolo Borelli <pborelli gnome org>
Date:   Mon Apr 18 10:44:17 2016 +0200

    view: small drawing fix for line background
    
    Should not make any difference since we are using the same color
    for fill and stroke and since the half pixel "outside" gets clipped,
    but this seems more correct in cairo.

 gtksourceview/gtksourceview.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gtksourceview/gtksourceview.c b/gtksourceview/gtksourceview.c
index 6b73c02..0b87993 100644
--- a/gtksourceview/gtksourceview.c
+++ b/gtksourceview/gtksourceview.c
@@ -2173,7 +2173,7 @@ gtk_source_view_paint_line_background (GtkTextView    *text_view,
 
        gdk_cairo_set_source_rgba (cr, (GdkRGBA *)color);
        cairo_set_line_width (cr, 1);
-       cairo_rectangle (cr, x1, y + .5, x2 - x1, height - 1);
+       cairo_rectangle (cr, x1 + .5, y + .5, x2 - x1 - 1, height - 1);
        cairo_stroke_preserve (cr);
        cairo_fill (cr);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]