#include "rowpainter.h"
#include "gettext.h"
-#include "support/filetools.h" // LibFileSearch
#include "support/forkedcontr.h"
#include <boost/utility.hpp>
#include <boost/bind.hpp>
#include <boost/current_function.hpp>
-using lyx::support::libFileSearch;
using lyx::support::ForkedcallsController;
using std::endl;
}
-void WorkArea::redraw(bool singlePar)
+void WorkArea::redraw()
{
if (!buffer_view_ || !buffer_view_->buffer()) {
greyed_out_ = true;
return;
}
- buffer_view_->updateMetrics(singlePar && hasFocus());
+ // No need to do anything if this is the current view. The BufferView
+ // metrics are already up to date.
+ if (&lyx_view_ != theApp()->currentView())
+ // FIXME: it would be nice to optimize for the off-screen case.
+ buffer_view_->updateMetrics(false);
updateScrollbar();
lyx_view_.updateToolbars();
}
- // Slight hack: this is only called currently when we
- // clicked somewhere, so we force through the display
- // of the new status here.
- lyx_view_.clearMessage();
-
- // Show the cursor immediately after any operation.
- hideCursor();
- toggleCursor();
+
+ // GUI tweaks except with mouse motion with no button pressed.
+ if (!(cmd0.action == LFUN_MOUSE_MOTION
+ && cmd0.button() == mouse_button::none)) {
+ // Slight hack: this is only called currently when we
+ // clicked somewhere, so we force through the display
+ // of the new status here.
+ lyx_view_.clearMessage();
+
+ // Show the cursor immediately after any operation.
+ hideCursor();
+ toggleCursor();
+ }
if (needRedraw)
redraw();
lyx_view_.message(_("Formatting document..."));
buffer_view_->workAreaResize(width(), height());
lyx_view_.updateLayoutChoice();
- redraw();
lyx_view_.busy(false);
lyx_view_.clearMessage();
}