[polari] chatView: Do not draw on border



commit 5ee4a5243d2f06de0e0128cbab227bedd81ef93b
Author: Florian Müllner <fmuellner gnome org>
Date:   Thu Sep 11 14:18:04 2014 +0100

    chatView: Do not draw on border
    
    It's not scrolled with the rest of the text view, resulting in
    the indicator line leaving some artifacts around; just limit
    drawing to the content area to avoid the problem.

 src/chatView.js |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/chatView.js b/src/chatView.js
index 66e26af..7f66fe2 100644
--- a/src/chatView.js
+++ b/src/chatView.js
@@ -62,9 +62,11 @@ const TextView = new Lang.Class({
         let location = this.get_iter_location(iter);
         let [, y] = this.buffer_to_window_coords(Gtk.TextWindowType.TEXT,
                                                  location.x, location.y);
+        let border = this.border_width;
 
         Gdk.cairo_set_source_rgba(cr, this._dimColor);
-        cr.rectangle(0, y + INDICATOR_OFFSET, this.get_allocated_width(), 1);
+        cr.rectangle(border, y + INDICATOR_OFFSET,
+                     this.get_allocated_width() - 2 * border, 1);
         cr.fill();
         cr.$dispose();
     },


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