From bbbd0d6597bffcb96bcee48b744aeb7d57890620 Mon Sep 17 00:00:00 2001 From: Vincent van Ravesteijn Date: Fri, 3 Dec 2010 15:40:23 +0000 Subject: [PATCH] *rowpainter.cpp: Squeeze some warnings and reduce linelength. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36683 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/rowpainter.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/rowpainter.cpp b/src/rowpainter.cpp index 6126f36025..2d512ce48f 100644 --- a/src/rowpainter.cpp +++ b/src/rowpainter.cpp @@ -951,21 +951,21 @@ void RowPainter::paintSelection() // draw the margins if (row_.begin_margin_sel) { if (text_.isRTL(beg.paragraph())) { - pi_.pain.fillRectangle(xo_ + x1, y1, text_metrics_.width() - rm - x1, y2 - y1, - Color_selection); + pi_.pain.fillRectangle(int(xo_ + x1), y1, + text_metrics_.width() - rm - x1, y2 - y1, Color_selection); } else { - pi_.pain.fillRectangle(xo_ + lm, y1, x1 - lm, y2 - y1, + pi_.pain.fillRectangle(int(xo_ + lm), y1, x1 - lm, y2 - y1, Color_selection); } } if (row_.end_margin_sel) { if (text_.isRTL(beg.paragraph())) { - pi_.pain.fillRectangle(xo_ + lm, y1, x2 - lm, y2 - y1, + pi_.pain.fillRectangle(int(xo_ + lm), y1, x2 - lm, y2 - y1, Color_selection); } else { - pi_.pain.fillRectangle(xo_ + x2, y1, text_metrics_.width() - rm - x2, y2 - y1, - Color_selection); + pi_.pain.fillRectangle(int(xo_ + x2), y1, text_metrics_.width() - rm - x2, + y2 - y1, Color_selection); } } @@ -1009,8 +1009,8 @@ void RowPainter::paintSelection() if (!(cur < end) || draw_now) { x2 = text_metrics_.cursorX(cur.top(), cur.boundary()); - pi_.pain.fillRectangle(xo_ + min(x1,x2), y1, abs(x2 - x1), y2 - y1, - Color_selection); + pi_.pain.fillRectangle(int(xo_ + min(x1, x2)), y1, abs(x2 - x1), + y2 - y1, Color_selection); // reset x1, so it is set again next round (which will be on the // right side of a boundary or at the selection end)