diff options
Diffstat (limited to 'quanta/dialogs/settings')
-rw-r--r-- | quanta/dialogs/settings/abbreviation.cpp | 90 | ||||
-rw-r--r-- | quanta/dialogs/settings/abbreviation.h | 12 | ||||
-rw-r--r-- | quanta/dialogs/settings/filemasks.cpp | 12 | ||||
-rw-r--r-- | quanta/dialogs/settings/filemasks.h | 2 | ||||
-rw-r--r-- | quanta/dialogs/settings/parseroptions.cpp | 14 | ||||
-rw-r--r-- | quanta/dialogs/settings/parseroptions.h | 2 | ||||
-rw-r--r-- | quanta/dialogs/settings/previewoptions.cpp | 30 | ||||
-rw-r--r-- | quanta/dialogs/settings/previewoptions.h | 18 |
8 files changed, 90 insertions, 90 deletions
diff --git a/quanta/dialogs/settings/abbreviation.cpp b/quanta/dialogs/settings/abbreviation.cpp index 56f81c0e..79dc4bc1 100644 --- a/quanta/dialogs/settings/abbreviation.cpp +++ b/quanta/dialogs/settings/abbreviation.cpp @@ -13,13 +13,13 @@ ***************************************************************************/ //qt includes -#include <qdom.h> -#include <qfile.h> -#include <qfileinfo.h> -#include <qlineedit.h> -#include <qtextedit.h> -#include <qtextstream.h> -#include <qtimer.h> +#include <tqdom.h> +#include <tqfile.h> +#include <tqfileinfo.h> +#include <tqlineedit.h> +#include <tqtextedit.h> +#include <tqtextstream.h> +#include <tqtimer.h> //kde includes #include <kcombobox.h> @@ -41,13 +41,13 @@ #include "dtds.h" -AbbreviationDlg::AbbreviationDlg(QWidget *parent, const char *name): +AbbreviationDlg::AbbreviationDlg(TQWidget *parent, const char *name): AbbreviationDlgS(parent, name) { m_oldItem = 0L; m_currentAbbrev = 0L; - QMapConstIterator<QString, Abbreviation> it; + TQMapConstIterator<TQString, Abbreviation> it; for (it = qConfig.abbreviations.constBegin(); it != qConfig.abbreviations.constEnd(); ++it) { groupCombo->insertItem(it.key()); @@ -59,10 +59,10 @@ AbbreviationDlg::~AbbreviationDlg() { } -void AbbreviationDlg::slotGroupChanged(const QString& newGroupName) +void AbbreviationDlg::slotGroupChanged(const TQString& newGroupName) { //save the current template - QListViewItem *item = templatesList->currentItem(); + TQListViewItem *item = templatesList->currentItem(); if (item && m_currentAbbrev) m_currentAbbrev->abbreviations.insert(item->text(0) + " " + item->text(1), codeEdit->text()); dtepList->clear(); @@ -70,9 +70,9 @@ void AbbreviationDlg::slotGroupChanged(const QString& newGroupName) codeEdit->clear(); m_oldItem = 0L; m_currentAbbrev = &qConfig.abbreviations[newGroupName]; - QString templateStr; - QString templateName; - QMap<QString, QString>::ConstIterator it; + TQString templateStr; + TQString templateName; + TQMap<TQString, TQString>::ConstIterator it; for ( it = m_currentAbbrev->abbreviations.constBegin(); it != m_currentAbbrev->abbreviations.constEnd(); ++it ) { templateStr = it.key(); @@ -80,7 +80,7 @@ void AbbreviationDlg::slotGroupChanged(const QString& newGroupName) templateStr = templateStr.left(templateStr.find(' ')); new KListViewItem(templatesList, templateStr, templateName); } - for ( QStringList::ConstIterator dtepit = m_currentAbbrev->dteps.constBegin(); dtepit != m_currentAbbrev->dteps.constEnd(); ++dtepit ) + for ( TQStringList::ConstIterator dtepit = m_currentAbbrev->dteps.constBegin(); dtepit != m_currentAbbrev->dteps.constEnd(); ++dtepit ) { dtepList->insertItem(DTDs::ref()->getDTDNickNameFromName(*dtepit)); } @@ -92,13 +92,13 @@ void AbbreviationDlg::slotGroupChanged(const QString& newGroupName) void AbbreviationDlg::slotNewGroup() { bool ok; - QString groupName = KInputDialog::getText(i18n("New Abbreviation Group"), i18n("Group name:"), "", &ok, this); + TQString groupName = KInputDialog::getText(i18n("New Abbreviation Group"), i18n("Group name:"), "", &ok, this); if (ok && !groupName.isEmpty()) { if (qConfig.abbreviations.contains(groupName)) { KMessageBox::error(this, i18n("<qt>There is already an abbreviation group called <b>%1</b>. Choose an unique name for the new group.</qt>").arg(groupName), i18n("Group already exists")); - QTimer::singleShot(0, this, SLOT(slotNewGroup())); + TQTimer::singleShot(0, this, TQT_SLOT(slotNewGroup())); } else { groupCombo->insertItem(groupName); @@ -110,17 +110,17 @@ void AbbreviationDlg::slotNewGroup() void AbbreviationDlg::slotAddDTEP() { - QStringList lst = DTDs::ref()->nickNameList(false); + TQStringList lst = DTDs::ref()->nickNameList(false); for (uint i = 0; i < dtepList->count(); i++) lst.remove(dtepList->text(i)); bool ok = false; - QStringList res = KInputDialog::getItemList( + TQStringList res = KInputDialog::getItemList( i18n( "Add DTEP" ), i18n( "Select a DTEP:" ), lst, 0, true, &ok, this ); if (ok) { dtepList->insertStringList(res); - for (QStringList::ConstIterator it = res.constBegin(); it != res.constEnd(); ++it) + for (TQStringList::ConstIterator it = res.constBegin(); it != res.constEnd(); ++it) { m_currentAbbrev->dteps.append(DTDs::ref()->getDTDNameFromNickName(*it)); } @@ -146,18 +146,18 @@ void AbbreviationDlg::slotRemoveDTEP() } } -void AbbreviationDlg::slotTemplateSelectionChanged(QListViewItem* item) +void AbbreviationDlg::slotTemplateSelectionChanged(TQListViewItem* item) { if (!item) return; - //QListViewItem *m_oldItem = templatesList->currentItem(); + //TQListViewItem *m_oldItem = templatesList->currentItem(); if (m_oldItem) { - QString key = m_oldItem->text(0)+" " +m_oldItem->text(1); + TQString key = m_oldItem->text(0)+" " +m_oldItem->text(1); m_currentAbbrev->abbreviations.insert(key, codeEdit->text()); } - QString code = m_currentAbbrev->abbreviations[item->text(0)+" " +item->text(1)]; + TQString code = m_currentAbbrev->abbreviations[item->text(0)+" " +item->text(1)]; codeEdit->setText(code); m_oldItem = item; } @@ -170,11 +170,11 @@ void AbbreviationDlg::slotAddTemplate() w.templateEdit->setFocus(); if (dlg.exec()) { - QString templateName = w.templateEdit->text(); - QString description = w.descriptionEdit->text(); + TQString templateName = w.templateEdit->text(); + TQString description = w.descriptionEdit->text(); if (!templateName.isEmpty()) { - QListViewItem *item = new KListViewItem(templatesList, templateName, description); + TQListViewItem *item = new KListViewItem(templatesList, templateName, description); templatesList->setCurrentItem(item); templatesList->setSelected(item, true); templatesList->ensureItemVisible(item); @@ -185,9 +185,9 @@ void AbbreviationDlg::slotAddTemplate() void AbbreviationDlg::slotRemoveTemplate() { - QListViewItem *item = templatesList->currentItem(); + TQListViewItem *item = templatesList->currentItem(); if (item && - KMessageBox::warningContinueCancel(this, i18n("<qt>Do you really want to remove the <b>%1</b> template?</qt>").arg(item->text(1)),QString::null,KStdGuiItem::del()) == KMessageBox::Continue) + KMessageBox::warningContinueCancel(this, i18n("<qt>Do you really want to remove the <b>%1</b> template?</qt>").arg(item->text(1)),TQString::null,KStdGuiItem::del()) == KMessageBox::Continue) { m_currentAbbrev->abbreviations.remove(item->text(0)+" "+item->text(1)); delete item; @@ -198,7 +198,7 @@ void AbbreviationDlg::slotRemoveTemplate() void AbbreviationDlg::slotEditTemplate() { - QListViewItem *item = templatesList->currentItem(); + TQListViewItem *item = templatesList->currentItem(); if (!item) return; KDialogBase dlg(this, 0, true, i18n("Edit Code Template"), KDialogBase::Ok | KDialogBase::Cancel); @@ -218,33 +218,33 @@ void AbbreviationDlg::slotEditTemplate() void AbbreviationDlg::saveTemplates() { - QListViewItem *item = templatesList->currentItem(); + TQListViewItem *item = templatesList->currentItem(); if (item && m_currentAbbrev) m_currentAbbrev->abbreviations.insert(item->text(0) + " " + item->text(1), codeEdit->text()); - QString abbrevFile = KGlobal::dirs()->saveLocation("data") + resourceDir + "abbreviations.xml"; - QString s = "<!DOCTYPE Templates>\n<Templates>\n</Templates>\n"; - QString s2; - QDomDocument doc; + TQString abbrevFile = KGlobal::dirs()->saveLocation("data") + resourceDir + "abbreviations.xml"; + TQString s = "<!DOCTYPE Templates>\n<Templates>\n</Templates>\n"; + TQString s2; + TQDomDocument doc; doc.setContent(s); - QDomNode firstNode = doc.firstChild(); + TQDomNode firstNode = doc.firstChild(); Abbreviation abbrev; - QMap<QString, Abbreviation>::ConstIterator abbrevIt; + TQMap<TQString, Abbreviation>::ConstIterator abbrevIt; for (abbrevIt = qConfig.abbreviations.constBegin(); abbrevIt != qConfig.abbreviations.constEnd(); ++abbrevIt) { - QDomElement groupEl = doc.createElement("Group"); + TQDomElement groupEl = doc.createElement("Group"); groupEl.setAttribute("name", abbrevIt.key()); abbrev = abbrevIt.data(); - for (QStringList::ConstIterator dtepIt = abbrev.dteps.constBegin(); dtepIt != abbrev.dteps.constEnd(); ++dtepIt) + for (TQStringList::ConstIterator dtepIt = abbrev.dteps.constBegin(); dtepIt != abbrev.dteps.constEnd(); ++dtepIt) { - QDomElement el = doc.createElement("DTEP"); + TQDomElement el = doc.createElement("DTEP"); el.setAttribute("name", *dtepIt); groupEl.appendChild(el); } int pos; - QMap<QString,QString>::ConstIterator it; + TQMap<TQString,TQString>::ConstIterator it; for (it = abbrev.abbreviations.constBegin(); it != abbrev.abbreviations.constEnd(); ++it) { - QDomElement el = doc.createElement("Template"); + TQDomElement el = doc.createElement("Template"); el.setAttribute("code", it.data()); s = it.key(); s2 = ""; @@ -261,11 +261,11 @@ void AbbreviationDlg::saveTemplates() firstNode.appendChild(groupEl); } - QFile f(abbrevFile); + TQFile f(abbrevFile); if (f.open(IO_WriteOnly | IO_Truncate)) { - QTextStream str(&f); - str.setEncoding(QTextStream::UnicodeUTF8); + TQTextStream str(&f); + str.setEncoding(TQTextStream::UnicodeUTF8); str << doc.toString(); f.close(); } else diff --git a/quanta/dialogs/settings/abbreviation.h b/quanta/dialogs/settings/abbreviation.h index 0e2a34c6..24db8e3b 100644 --- a/quanta/dialogs/settings/abbreviation.h +++ b/quanta/dialogs/settings/abbreviation.h @@ -15,8 +15,8 @@ #ifndef ABBREVIATION_H #define ABBREVIATION_H -#include <qmap.h> -#include <qstringlist.h> +#include <tqmap.h> +#include <tqstringlist.h> #include <abbreviations.h> @@ -28,25 +28,25 @@ class AbbreviationDlg : public AbbreviationDlgS { Q_OBJECT public: - AbbreviationDlg(QWidget *parent, const char *name = 0); + AbbreviationDlg(TQWidget *parent, const char *name = 0); ~AbbreviationDlg(); void saveTemplates(); public slots: - void slotGroupChanged(const QString& newGroupName); + void slotGroupChanged(const TQString& newGroupName); private slots: void slotNewGroup(); void slotAddDTEP(); void slotRemoveDTEP(); - void slotTemplateSelectionChanged(QListViewItem*); + void slotTemplateSelectionChanged(TQListViewItem*); void slotAddTemplate(); void slotRemoveTemplate(); void slotEditTemplate(); private: - QListViewItem *m_oldItem; + TQListViewItem *m_oldItem; Abbreviation *m_currentAbbrev; }; diff --git a/quanta/dialogs/settings/filemasks.cpp b/quanta/dialogs/settings/filemasks.cpp index 14e824c1..fee135f8 100644 --- a/quanta/dialogs/settings/filemasks.cpp +++ b/quanta/dialogs/settings/filemasks.cpp @@ -17,16 +17,16 @@ #include "filemasks.h" #include "filemasks.moc" // qt includes -#include <qlineedit.h> -#include <qpushbutton.h> +#include <tqlineedit.h> +#include <tqpushbutton.h> //kde includes #include <kmimetype.h> -FileMasks::FileMasks(QWidget *parent, const char *name) +FileMasks::FileMasks(TQWidget *parent, const char *name) :FileMasksS(parent,name) { - connect(buttonDefault, SIGNAL(clicked()), this, SLOT(setToDefault())); + connect(buttonDefault, TQT_SIGNAL(clicked()), this, TQT_SLOT(setToDefault())); } FileMasks::~FileMasks(){ @@ -36,10 +36,10 @@ void FileMasks::setToDefault() { KMimeType::List list = KMimeType::allMimeTypes(); KMimeType::List::iterator it; - QString markup, script, image, text; + TQString markup, script, image, text; markup = "text/css; text/html; text/sgml; text/xml; "; script = "text/x-perl; text/x-python; text/x-php; text/x-java; text/x-asp; "; - QString name; + TQString name; for ( it = list.begin(); it != list.end(); ++it ) { name = (*it)->name(); diff --git a/quanta/dialogs/settings/filemasks.h b/quanta/dialogs/settings/filemasks.h index 2d13c1f5..965eb190 100644 --- a/quanta/dialogs/settings/filemasks.h +++ b/quanta/dialogs/settings/filemasks.h @@ -25,7 +25,7 @@ class FileMasks : public FileMasksS { Q_OBJECT public: - FileMasks(QWidget *parent=0, const char *name=0); + FileMasks(TQWidget *parent=0, const char *name=0); ~FileMasks(); public slots: diff --git a/quanta/dialogs/settings/parseroptions.cpp b/quanta/dialogs/settings/parseroptions.cpp index 0ad00d73..24e3c6a6 100644 --- a/quanta/dialogs/settings/parseroptions.cpp +++ b/quanta/dialogs/settings/parseroptions.cpp @@ -15,8 +15,8 @@ #include "parseroptions.h" #include "parseroptions.moc" -#include <qcombobox.h> -#include <qspinbox.h> +#include <tqcombobox.h> +#include <tqspinbox.h> #include <klocale.h> #include <kconfig.h> @@ -25,16 +25,16 @@ * Constructs a ParserOptions which is a child of 'parent', with the * name 'name' and widget flags set to 'f' */ -ParserOptions::ParserOptions( KConfig *a_config, QWidget* parent, const char* name ) +ParserOptions::ParserOptions( KConfig *a_config, TQWidget* parent, const char* name ) : ParserOptionsUI( parent, name ) { config = a_config; config->setGroup("Parser options"); - QString handleLBM = config->readEntry("LBM", i18n("Find Tag & Open Tree")); - QString handleMBM = config->readEntry("MBM", i18n("Nothing")); - QString handleRBM = config->readEntry("RBM", i18n("Popup Menu")); - QString handleDoubleClick = config->readEntry("Double click", i18n("Select Tag Area")); + TQString handleLBM = config->readEntry("LBM", i18n("Find Tag & Open Tree")); + TQString handleMBM = config->readEntry("MBM", i18n("Nothing")); + TQString handleRBM = config->readEntry("RBM", i18n("Popup Menu")); + TQString handleDoubleClick = config->readEntry("Double click", i18n("Select Tag Area")); if ( !name ) diff --git a/quanta/dialogs/settings/parseroptions.h b/quanta/dialogs/settings/parseroptions.h index a4bdd0f5..a4c5f6f3 100644 --- a/quanta/dialogs/settings/parseroptions.h +++ b/quanta/dialogs/settings/parseroptions.h @@ -25,7 +25,7 @@ class ParserOptions : public ParserOptionsUI Q_OBJECT public: - ParserOptions( KConfig *config, QWidget* parent = 0, const char* name = 0); + ParserOptions( KConfig *config, TQWidget* parent = 0, const char* name = 0); ~ParserOptions(); void updateConfig(); diff --git a/quanta/dialogs/settings/previewoptions.cpp b/quanta/dialogs/settings/previewoptions.cpp index c445c52d..2df03ea9 100644 --- a/quanta/dialogs/settings/previewoptions.cpp +++ b/quanta/dialogs/settings/previewoptions.cpp @@ -17,13 +17,13 @@ #include "previewoptions.h" #include "previewoptions.moc" // qt includes -#include <qradiobutton.h> -#include <qcheckbox.h> +#include <tqradiobutton.h> +#include <tqcheckbox.h> // kde includes #include <klocale.h> #include <kmessagebox.h> -PreviewOptions::PreviewOptions(QWidget *parent, const char *name) +PreviewOptions::PreviewOptions(TQWidget *parent, const char *name) : PreviewOptionsS(parent,name) { } @@ -31,50 +31,50 @@ PreviewOptions::PreviewOptions(QWidget *parent, const char *name) PreviewOptions::~PreviewOptions(){ } -void PreviewOptions::setWindowLayout(const QString& layout ) +void PreviewOptions::setWindowLayout(const TQString& layout ) { if ( layout == "Default") resetLayout->setChecked(true); else resetLayout->setChecked(false); } -void PreviewOptions::setPosition(const QString& position ) +void PreviewOptions::setPosition(const TQString& position ) { radioEditor->setChecked(true); if ( position == "Toolview" ) radioToolview->setChecked(true); } -QString PreviewOptions::position() +TQString PreviewOptions::position() { - QString position = "Editor"; + TQString position = "Editor"; if ( radioToolview->isChecked() ) position = "Toolview"; return position; } -void PreviewOptions::setDocPosition(const QString &position) +void PreviewOptions::setDocPosition(const TQString &position) { radioNewDocTab->setChecked(true); if (position == "Toolview") radioSeparateDocView->setChecked(true); } -QString PreviewOptions::docPosition() +TQString PreviewOptions::docPosition() { - QString position = "Tab"; + TQString position = "Tab"; if (radioSeparateDocView->isChecked()) position = "Toolview"; return position; } -QString PreviewOptions::layout() +TQString PreviewOptions::layout() { - QString layout = "Custom"; + TQString layout = "Custom"; if ( resetLayout->isChecked() ) layout = "Default"; return layout; } -QString PreviewOptions::closeButtons() +TQString PreviewOptions::closeButtons() { - QString closeButtonState = "ShowAlways"; + TQString closeButtonState = "ShowAlways"; if (radioDelayedCloseButtons->isChecked()) closeButtonState = "ShowDelayed"; if (radioNoCloseButtons->isChecked()) @@ -82,7 +82,7 @@ QString PreviewOptions::closeButtons() return closeButtonState; } -void PreviewOptions::setCloseButtons(const QString &state) +void PreviewOptions::setCloseButtons(const TQString &state) { if (state == "ShowAlways") radioShowCloseButtons->setChecked(true); if (state == "ShowDelayed") radioDelayedCloseButtons->setChecked(true); diff --git a/quanta/dialogs/settings/previewoptions.h b/quanta/dialogs/settings/previewoptions.h index cb1f6719..3cc5b820 100644 --- a/quanta/dialogs/settings/previewoptions.h +++ b/quanta/dialogs/settings/previewoptions.h @@ -25,21 +25,21 @@ class KConfig; class PreviewOptions : public PreviewOptionsS { Q_OBJECT public: - PreviewOptions(QWidget *parent=0, const char *name=0); + PreviewOptions(TQWidget *parent=0, const char *name=0); ~PreviewOptions(); - QString position(); - QString layout(); - QString closeButtons(); - QString docPosition(); + TQString position(); + TQString layout(); + TQString closeButtons(); + TQString docPosition(); uint toolviewTabs(); bool hiddenFiles(); bool saveTrees(); - void setPosition(const QString&); - void setWindowLayout(const QString&); - void setCloseButtons(const QString&); + void setPosition(const TQString&); + void setWindowLayout(const TQString&); + void setCloseButtons(const TQString&); void setToolviewTabs(uint); - void setDocPosition(const QString&); + void setDocPosition(const TQString&); void setHiddenFiles(bool show); void setSaveTrees(bool show); |