]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt4/GuiCompleter.cpp
Use QFontMetrics information for underlines (and friends) width and position
[lyx.git] / src / frontends / qt4 / GuiCompleter.cpp
index fb02cf0230a9047dfe3eeecf9c6cef142eb8aa18..7c3c2ff2c81ad83612ff32b21d6870a960df5854 100644 (file)
@@ -22,6 +22,7 @@
 #include "LyX.h"
 #include "LyXRC.h"
 #include "Paragraph.h"
+#include "qt_helpers.h"
 #include "version.h"
 
 #include "support/lassert.h"
@@ -136,6 +137,8 @@ public:
                // get icon from cache
                QPixmap scaled;
                QString const name = ":" + toqstr(list_->icon(index.row()));
+               if (name == ":")
+                       return scaled;
                if (!QPixmapCache::find("completion" + name, scaled)) {
                        // load icon from disk
                        QPixmap p = QPixmap(name);