summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCatalin Badea <catalin.badea392@gmail.com>2012-04-13 19:49:39 (GMT)
committerKevin Smith <git@kismith.co.uk>2012-04-14 15:44:35 (GMT)
commitd4517116fc71d1b2d5967004757630293613e928 (patch)
treecfb8d66bb781548c5b60d037ef8372f2e82b921b /Swift/QtUI/QtChatWindow.h
parent2dcdee8e9f657c7f5c5d5c507373fd328beaa568 (diff)
downloadswift-contrib-d4517116fc71d1b2d5967004757630293613e928.zip
swift-contrib-d4517116fc71d1b2d5967004757630293613e928.tar.bz2
Improve tab completion
Remember last tab completion suggestion and use it for cycling through all completion candidates. Resolves: #1070 License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Diffstat (limited to 'Swift/QtUI/QtChatWindow.h')
-rw-r--r--Swift/QtUI/QtChatWindow.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/Swift/QtUI/QtChatWindow.h b/Swift/QtUI/QtChatWindow.h
index 18eb092..9db1884 100644
--- a/Swift/QtUI/QtChatWindow.h
+++ b/Swift/QtUI/QtChatWindow.h
@@ -16,6 +16,7 @@
#include <map>
#include <QPointer>
+#include <QTextCursor>
class QTextEdit;
class QLineEdit;
@@ -118,6 +119,7 @@ namespace Swift {
private slots:
void returnPressed();
void handleInputChanged();
+ void handleCursorPositionChanged();
void handleKeyPressEvent(QKeyEvent* event);
void handleSplitterMoved(int pos, int index);
void handleAlertButtonClicked();
@@ -150,6 +152,7 @@ namespace Swift {
LastLineTracker lastLineTracker_;
QString contact_;
QString lastSentMessage_;
+ QTextCursor tabCompleteCursor_;
QtChatView* messageLog_;
QtChatTheme* theme_;
QtTextEdit* input_;
@@ -168,6 +171,7 @@ namespace Swift {
PreviousMessageKind previousMessageKind_;
QString previousSenderName_;
bool inputClearing_;
+ bool tabCompletion_;
UIEventStream* eventStream_;
bool inputEnabled_;
QSplitter *logRosterSplitter_;