]> git.lyx.org Git - features.git/blobdiff - src/frontends/qt4/GuiCompleter.cpp
Fix bug #6063: Keylogger lyx::lyxbreaker: Crash in Math.
[features.git] / src / frontends / qt4 / GuiCompleter.cpp
index 884bde6d873143d7705c74874ba2a84d94f81a05..fa8f6f818718b776ca12df2707852f69c3b06260 100644 (file)
@@ -313,6 +313,11 @@ void GuiCompleter::updateVisibility(Cursor & cur, bool start, bool keep, bool cu
        if (!inlineVisible() && possibleInlineState && start
                && cur.inset().automaticInlineCompletion())
                inline_timer_.start(int(lyxrc.completion_inline_delay * 1000));
+       else {
+               // no inline completion, hence a metrics update is needed
+               if (!(cur.disp_.update() & Update::Force))
+                       cur.updateFlags(cur.disp_.update() | Update::SinglePar);
+       }
 
        // update prefix if any completion is possible
        bool modelActive = modelActive_ && model()->rowCount() > 0;