diff options
author | nils <nils@34ebc366-c3a9-4b3c-9f84-69acf7962910> | 2011-01-02 00:45:42 +0000 |
---|---|---|
committer | nils <nils@34ebc366-c3a9-4b3c-9f84-69acf7962910> | 2011-01-02 00:45:42 +0000 |
commit | 194529a705a2adef9b82c6df7fb5d41b3b3802de (patch) | |
tree | 697f496b4e77de0886cfdfc9528f81f23a79dc1b /editorpage.cpp | |
parent | added tabs to editor, but VERY buggy till now (diff) | |
download | gpg4usb-194529a705a2adef9b82c6df7fb5d41b3b3802de.tar.gz gpg4usb-194529a705a2adef9b82c6df7fb5d41b3b3802de.zip |
added editorpage files
git-svn-id: http://cpunk.de/svn/src/gpg4usb/trunk@419 34ebc366-c3a9-4b3c-9f84-69acf7962910
Diffstat (limited to 'editorpage.cpp')
-rw-r--r-- | editorpage.cpp | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/editorpage.cpp b/editorpage.cpp new file mode 100644 index 0000000..0a11ee4 --- /dev/null +++ b/editorpage.cpp @@ -0,0 +1,60 @@ +/* + * textpage.cpp + * + * Copyright 2008 gpg4usb-team <[email protected]> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, + * MA 02110-1301, USA. + */ + +#include <QtGui> + +#include "editorpage.h" + + +EditorPage::EditorPage(const QString &filePath, QWidget *parent) : QWidget(parent), + fullFilePath(filePath) +{ + textPage = new QPlainTextEdit(); + + mainLayout = new QHBoxLayout(); + mainLayout->setSpacing(0); + mainLayout->addWidget(textPage); + + setLayout(mainLayout); + setAttribute(Qt::WA_DeleteOnClose); +} + + +const QString& EditorPage::getFilePath() const +{ + return fullFilePath; +} + + +QPlainTextEdit* EditorPage::getTextPage() +{ + return textPage; +} + + +void EditorPage::setFilePath(const QString &filePath) +{ + fullFilePath = filePath; +} + + + + |