diff options
author | Konstantinos Sideris <sideris.konstantin@gmail.com> | 2017-08-20 13:47:22 +0300 |
---|---|---|
committer | Konstantinos Sideris <sideris.konstantin@gmail.com> | 2017-08-20 13:47:22 +0300 |
commit | 2644e4accaf7487ad51b205040163e42b76de3a4 (patch) | |
tree | 523db09ee380e05838bfb2a5eee60ca88aad6e52 /src/TextInputWidget.cc | |
parent | 57ac64fb2b1e8e4b5346d2df49ede3265d58aefe (diff) |
Small style change
Diffstat (limited to 'src/TextInputWidget.cc')
-rw-r--r-- | src/TextInputWidget.cc | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/TextInputWidget.cc b/src/TextInputWidget.cc index 9b70cd9b..328c99e2 100644 --- a/src/TextInputWidget.cc +++ b/src/TextInputWidget.cc @@ -24,12 +24,13 @@ #include "TextInputWidget.h" FilteredTextEdit::FilteredTextEdit(QWidget *parent) - : QTextEdit(parent) + : QTextEdit(parent) { setAcceptRichText(false); } -void FilteredTextEdit::keyPressEvent(QKeyEvent *event) +void +FilteredTextEdit::keyPressEvent(QKeyEvent *event) { if (event->key() == Qt::Key_Return || event->key() == Qt::Key_Enter) emit enterPressed(); @@ -38,7 +39,7 @@ void FilteredTextEdit::keyPressEvent(QKeyEvent *event) } TextInputWidget::TextInputWidget(QWidget *parent) - : QWidget(parent) + : QWidget(parent) { setFont(QFont("Emoji One")); @@ -95,7 +96,8 @@ TextInputWidget::TextInputWidget(QWidget *parent) connect(emoji_button_, SIGNAL(emojiSelected(const QString &)), this, SLOT(addSelectedEmoji(const QString &))); } -void TextInputWidget::addSelectedEmoji(const QString &emoji) +void +TextInputWidget::addSelectedEmoji(const QString &emoji) { QTextCursor cursor = input_->textCursor(); @@ -118,7 +120,8 @@ void TextInputWidget::addSelectedEmoji(const QString &emoji) input_->show(); } -void TextInputWidget::onSendButtonClicked() +void +TextInputWidget::onSendButtonClicked() { auto msg_text = input_->document()->toPlainText().trimmed(); @@ -130,7 +133,8 @@ void TextInputWidget::onSendButtonClicked() input_->clear(); } -void TextInputWidget::paintEvent(QPaintEvent *event) +void +TextInputWidget::paintEvent(QPaintEvent *event) { Q_UNUSED(event); |