+#include <QListWidget>
+
+#ifndef QT_NO_DEBUG_OUTPUT
+/// Gives human-readable event type information.
+QDebug operator<<(QDebug str, const QEvent * ev) {
+ static int eventEnumIndex = QEvent::staticMetaObject.indexOfEnumerator("Type");
+ str << "QEvent";
+ if (ev) {
+ QString name = QEvent::staticMetaObject.enumerator(eventEnumIndex).valueToKey(ev->type());
+ if (!name.isEmpty()) str << name; else str << ev->type();
+ } else {
+ str << (void*)ev;
+ }
+ return str.maybeSpace();
+}
+#endif
+
+AutoComplete::AutoComplete(SearchWidget *buddy, QLineEdit *lineEdit):
+ QObject(lineEdit), buddy(buddy), lineEdit(lineEdit), enabled(true), suggester(0), itemHovering(false) {