diff options
| author | Kevin Smith <git@kismith.co.uk> | 2011-10-11 11:06:18 (GMT) |
|---|---|---|
| committer | Kevin Smith <git@kismith.co.uk> | 2011-10-11 11:06:18 (GMT) |
| commit | 09210ff317de63a8011130edceba3a508a6009d8 (patch) | |
| tree | 05d6cb3a896ab34599dd32b9079f0c8218b1d644 | |
| parent | a63f8175dc065289b4a8867a8e9dac01b883f9f0 (diff) | |
| download | swift-contrib-09210ff317de63a8011130edceba3a508a6009d8.zip swift-contrib-09210ff317de63a8011130edceba3a508a6009d8.tar.bz2 | |
Another label that needs forcing to plain text
| -rw-r--r-- | Swift/QtUI/QtAdHocCommandWindow.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Swift/QtUI/QtAdHocCommandWindow.cpp b/Swift/QtUI/QtAdHocCommandWindow.cpp index a3bb077..221d1f5 100644 --- a/Swift/QtUI/QtAdHocCommandWindow.cpp +++ b/Swift/QtUI/QtAdHocCommandWindow.cpp @@ -1,62 +1,63 @@ /* * Copyright (c) 2010-2011 Kevin Smith * Licensed under the GNU General Public License v3. * See Documentation/Licenses/GPLv3.txt for more information. */ #include <Swift/QtUI/QtAdHocCommandWindow.h> #include <boost/bind.hpp> #include <QBoxLayout> #include <Swift/QtUI/QtFormWidget.h> #include <Swiften/Elements/Command.h> namespace Swift { QtAdHocCommandWindow::QtAdHocCommandWindow(boost::shared_ptr<OutgoingAdHocCommandSession> command) : command_(command) { formWidget_ = NULL; setAttribute(Qt::WA_DeleteOnClose); command->onNextStageReceived.connect(boost::bind(&QtAdHocCommandWindow::handleNextStageReceived, this, _1)); command->onError.connect(boost::bind(&QtAdHocCommandWindow::handleError, this, _1)); command->start(); QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom, this); layout->setContentsMargins(0,0,0,0); layout->setSpacing(2); label_ = new QLabel(this); + label_->setTextFormat(Qt::PlainText); layout->addWidget(label_); QWidget* formContainer = new QWidget(this); layout->addWidget(formContainer); formLayout_ = new QBoxLayout(QBoxLayout::TopToBottom, formContainer); QWidget* buttonsWidget = new QWidget(this); layout->addWidget(buttonsWidget); QBoxLayout* buttonsLayout = new QBoxLayout(QBoxLayout::LeftToRight, buttonsWidget); cancelButton_ = new QPushButton(tr("Cancel"), buttonsWidget); buttonsLayout->addWidget(cancelButton_); connect(cancelButton_, SIGNAL(clicked()), this, SLOT(handleCancelClicked())); backButton_ = new QPushButton(tr("Back"), buttonsWidget); buttonsLayout->addWidget(backButton_); connect(backButton_, SIGNAL(clicked()), this, SLOT(handlePrevClicked())); nextButton_ = new QPushButton(tr("Next"), buttonsWidget); buttonsLayout->addWidget(nextButton_); connect(nextButton_, SIGNAL(clicked()), this, SLOT(handleNextClicked())); completeButton_ = new QPushButton(tr("Complete"), buttonsWidget); buttonsLayout->addWidget(completeButton_); connect(completeButton_, SIGNAL(clicked()), this, SLOT(handleCompleteClicked())); nextButton_->setEnabled(false); backButton_->setEnabled(false); completeButton_->setEnabled(false); actions_[Command::Next] = nextButton_; actions_[Command::Prev] = backButton_; actions_[Command::Complete] = completeButton_; actions_[Command::Cancel] = cancelButton_; show(); } QtAdHocCommandWindow::~QtAdHocCommandWindow() { } void QtAdHocCommandWindow::handleCancelClicked() { |
Swift