#include "support/debug.h"
#include "support/lassert.h"
-#include "support/RefChanger.h"
+#include "support/Changer.h"
#include <stdlib.h>
#include <cmath>
first = row.endpos();
++row_index;
- pm.dim().wid = max(pm.dim().wid, row.width());
+ pm.dim().wid = max(pm.dim().wid, row.width() + row.right_margin);
pm.dim().des += row.height();
} while (first < par.size() || need_new_row);
return;
size_t const nrows = pm.rows().size();
// Remember left and right margin for drawing math numbers
- Changer changeleft = make_change(pi.leftx, x + leftMargin(pit));
- Changer changeright = make_change(pi.rightx, x + width() - rightMargin(pit));
+ Changer changeleft = changeVar(pi.leftx, x + leftMargin(pit));
+ Changer changeright = changeVar(pi.rightx, x + width() - rightMargin(pit));
// Use fast lane in nodraw stage.
if (pi.pain.isNull()) {
LYXERR(Debug::PAINTING, "Clear rect@("
<< max(row_x, 0) << ", " << y - row.ascent() << ")="
<< width() << " x " << row.height());
- // FIXME: this is a hack. We clear an amount equal to
- // cursor width. This will not work if the caret has a
- // ridiculous width like 6. (see ticket #10797)
- // This is the same formula as in GuiWorkArea.
- int const caret_width = lyxrc.cursor_width
- ? lyxrc.cursor_width
- : 1 + int((lyxrc.currentZoom + 50) / 200.0);
- pi.pain.fillRectangle(max(row_x, 0), y - row.ascent(),
- width() + caret_width,
- row.height(), pi.background_color);
+ pi.pain.fillRectangle(row_x, y - row.ascent(),
+ width(), row.height(), pi.background_color);
}
// Instrumentation for testing row cache (see also