]> git.lyx.org Git - features.git/commitdiff
Round values properly when drawing right margin selection
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 4 Nov 2016 14:57:59 +0000 (15:57 +0100)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 4 Nov 2016 14:58:54 +0000 (15:58 +0100)
This fixes a compiler warning reported by Uwe.

src/RowPainter.cpp

index 7f8456f2f6992e4d77c670f8952eb4f8637b66e4..fabfcddf2a38acf268289caaba2aaf94443e79a0 100644 (file)
@@ -652,7 +652,8 @@ void RowPainter::paintSelection() const
        }
 
        if (rtl ? row_.begin_margin_sel : row_.end_margin_sel)
-               pi_.pain.fillRectangle(x, y1, int(xo_) + text_metrics_.width() - x, y2 - y1,
+               pi_.pain.fillRectangle(int(x), y1,
+                                      int(xo_ + text_metrics_.width()) - int(x), y2 - y1,
                                       Color_selection);
 
 }