]> git.lyx.org Git - features.git/commit
Do not display caret when we're not ready
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 28 Feb 2020 14:21:40 +0000 (15:21 +0100)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 13 Mar 2020 15:02:36 +0000 (16:02 +0100)
commit9bc255dc89b58bfdb2d9692136b2f2715eab256b
tree3f96dcd23ac3230be877aca2286f763f9083396f
parent86693b5c3c8726bfce3b7b488300179fee4cab4f
Do not display caret when we're not ready

Using a dialog may trigger a redraw at times where the metrics caches
have not been updated yet. To fix this, do as in paintEvent() and
abort caret blinking if there is an open undo group.

Move the decision to skip the caret painting to showCaret(), closer to
where real work happens. hideCaret () is now an alias for
showCaret(false), which allows some code refactoring.

See also commit c7496a11b2.

Fixes bug #11763 (although it does not trigger on master).
src/frontends/qt/GuiWorkArea.cpp
src/frontends/qt/GuiWorkArea_Private.h