]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt/GuiCompleter.cpp
Properly scale some icons for HiDPI (#12695)
[lyx.git] / src / frontends / qt / GuiCompleter.cpp
index 281ff355bb176db8e5e97d0478a70c4fbd0208d3..661178575b1f860e2a71ce82bedd42dd5470456f 100644 (file)
@@ -455,8 +455,8 @@ void GuiCompleter::asyncUpdatePopup()
        // has a bad memory about it and we have to tell him again and again.
        QTreeView * listView = static_cast<QTreeView *>(popup());
        listView->header()->setStretchLastSection(false);
-       setSectionResizeMode(listView->header(), 0, QHeaderView::Stretch);
-       setSectionResizeMode(listView->header(), 1, QHeaderView::Fixed);
+       listView->header()->setSectionResizeMode(0, QHeaderView::Stretch);
+       listView->header()->setSectionResizeMode(1, QHeaderView::Fixed);
        listView->header()->resizeSection(1, 22);
 
        // show/update popup
@@ -710,7 +710,7 @@ void GuiCompleter::tab()
        docstring longestCompletion = longestUniqueCompletion();
        prefix = cur.inset().completionPrefix(cur);
        docstring postfix = longestCompletion.substr(min(longestCompletion.size(), prefix.size()));
-       cur.inset().insertCompletion(cur, postfix, false);
+       cur.inset().insertCompletion(cur, postfix, uniqueCompletionAvailable());
        old_cursor_ = bv.cursor();
        updatePrefix(cur);