int h = ascent + descent;
int x = 0;
int y = 0;
- bv.fullCursor().getPos(x, y);
+ bv.cursor().getPos(x, y);
y -= ascent + bv.top_y();
//lyxerr << "LyXScreen::showCursor x: " << x << " y: " << y << endl;
int newtop = top_y;
int x, y, asc, desc;
- bv->fullCursor().getPos(x, y);
- bv->fullCursor().getDim(asc, desc);
-
+ bv->cursor().getPos(x, y);
+ bv->cursor().getDim(asc, desc);
+ lyxerr[Debug::DEBUG] << "LyXScreen::fitCursor: x: " << x
+ << " y: " << y
+ << " top_y: " << top_y
+ << endl;
+
bool const big_row = h / 4 < asc + desc && asc + desc < h;
if (y + desc - top_y >= h) {
// maybe we have to clear the screen at the bottom
int const y2 = workarea().workHeight();
- if (y < y2 && !bv.text()->isInInset()) {
+ if (y < y2 && bv.text()->isMainText()) {
workarea().getPainter().fillRectangle(0, y,
workarea().workWidth(), y2 - y,
LColor::bottomarea);
}
- lyxerr << "Redraw screen" << endl;
+ lyxerr[Debug::DEBUG] << "Redraw screen" << endl;
expose(0, 0, workarea().workWidth(), workarea().workHeight());
workarea().getPainter().end();
+
+ showCursor(bv);
}