From: Jean-Marc Lasgouttes Date: Wed, 3 May 2023 10:22:52 +0000 (+0200) Subject: Never not show caret when window does not have focus X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=21dcb4782f19685e6fcab93dfbbf3809fc9b249e;p=features.git Never not show caret when window does not have focus A non blinking cursor could appear when hovering on inset button. Fixes bug #12762. --- diff --git a/src/frontends/qt/GuiWorkArea.cpp b/src/frontends/qt/GuiWorkArea.cpp index 1a3a9c0178..d634f83894 100644 --- a/src/frontends/qt/GuiWorkArea.cpp +++ b/src/frontends/qt/GuiWorkArea.cpp @@ -474,8 +474,9 @@ void GuiWorkArea::Private::resizeBufferView() void GuiWorkArea::Private::resetCaret() { - // Don't start blinking if the cursor isn't on screen. - if (!buffer_view_->caretInView()) + // Don't start blinking if the cursor isn't on screen or the window + // does not have focus + if (!buffer_view_->caretInView() || !p->hasFocus()) return; // completion indicator