]> git.lyx.org Git - features.git/blobdiff - src/frontends/qt4/GuiWorkArea.cpp
Keyboard based horizontal scrolling for wide insets
[features.git] / src / frontends / qt4 / GuiWorkArea.cpp
index 4e4d3d467e4f3f2b49e13f1cc4ec26edb470999d..b8a52f45ab7f0511ef7afdec09781eb5703c066c 100644 (file)
@@ -628,6 +628,12 @@ void GuiWorkArea::Private::showCursor()
                && !completer_->inlineVisible();
        cursor_visible_ = true;
        cursor_->recomputeWidth();
+
+       //int cur_x = buffer_view_->getPos(cur).x_;
+       // We may have decided to slide the cursor row so that cursor
+       // is visible.
+       p.x_ -= buffer_view_->horizScrollOffset();
+
        showCursor(p.x_, p.y_, h, l_shape, isrtl, completable);
 }