summaryrefslogtreecommitdiffstats
path: root/kttsd/filters/talkerchooser
diff options
context:
space:
mode:
Diffstat (limited to 'kttsd/filters/talkerchooser')
-rw-r--r--kttsd/filters/talkerchooser/talkerchooserconf.cpp84
-rw-r--r--kttsd/filters/talkerchooser/talkerchooserconf.h10
-rw-r--r--kttsd/filters/talkerchooser/talkerchooserproc.cpp16
-rw-r--r--kttsd/filters/talkerchooser/talkerchooserproc.h10
4 files changed, 60 insertions, 60 deletions
diff --git a/kttsd/filters/talkerchooser/talkerchooserconf.cpp b/kttsd/filters/talkerchooser/talkerchooserconf.cpp
index 0dbf53f..cc811a3 100644
--- a/kttsd/filters/talkerchooser/talkerchooserconf.cpp
+++ b/kttsd/filters/talkerchooser/talkerchooserconf.cpp
@@ -22,9 +22,9 @@
******************************************************************************/
// Qt includes.
-#include <qstring.h>
-#include <qhbox.h>
-#include <qlayout.h>
+#include <tqstring.h>
+#include <tqhbox.h>
+#include <tqlayout.h>
// KDE includes.
#include <klocale.h>
@@ -49,13 +49,13 @@
/**
* Constructor
*/
-TalkerChooserConf::TalkerChooserConf( QWidget *parent, const char *name, const QStringList& /*args*/) :
+TalkerChooserConf::TalkerChooserConf( TQWidget *parent, const char *name, const TQStringList& /*args*/) :
KttsFilterConf(parent, name)
{
// kdDebug() << "TalkerChooserConf::TalkerChooserConf: Running" << endl;
// Create configuration widget.
- QVBoxLayout *layout = new QVBoxLayout(this, KDialog::marginHint(),
+ TQVBoxLayout *layout = new TQVBoxLayout(this, KDialog::marginHint(),
KDialog::spacingHint(), "TalkerChooserConfigWidgetLayout");
layout->setAlignment (Qt::AlignTop);
m_widget = new TalkerChooserConfWidget(this, "TalkerChooserConfigWidget");
@@ -65,23 +65,23 @@ TalkerChooserConf::TalkerChooserConf( QWidget *parent, const char *name, const Q
m_reEditorInstalled = !KTrader::self()->query("KRegExpEditor/KRegExpEditor").isEmpty();
m_widget->reEditorButton->setEnabled(m_reEditorInstalled);
- connect(m_widget->nameLineEdit, SIGNAL(textChanged(const QString&)),
- this, SLOT(configChanged()));
- connect(m_widget->reLineEdit, SIGNAL(textChanged(const QString&)),
- this, SLOT(configChanged()));
- connect(m_widget->reEditorButton, SIGNAL(clicked()),
- this, SLOT(slotReEditorButton_clicked()));
- connect(m_widget->appIdLineEdit, SIGNAL(textChanged(const QString&)),
- this, SLOT(configChanged()));
- connect(m_widget->talkerButton, SIGNAL(clicked()),
- this, SLOT(slotTalkerButton_clicked()));
+ connect(m_widget->nameLineEdit, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(configChanged()));
+ connect(m_widget->reLineEdit, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(configChanged()));
+ connect(m_widget->reEditorButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotReEditorButton_clicked()));
+ connect(m_widget->appIdLineEdit, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(configChanged()));
+ connect(m_widget->talkerButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotTalkerButton_clicked()));
- connect(m_widget->loadButton, SIGNAL(clicked()),
- this, SLOT(slotLoadButton_clicked()));
- connect(m_widget->saveButton, SIGNAL(clicked()),
- this, SLOT(slotSaveButton_clicked()));
- connect(m_widget->clearButton, SIGNAL(clicked()),
- this, SLOT(slotClearButton_clicked()));
+ connect(m_widget->loadButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotLoadButton_clicked()));
+ connect(m_widget->saveButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotSaveButton_clicked()));
+ connect(m_widget->clearButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotClearButton_clicked()));
// Set up defaults.
defaults();
@@ -107,7 +107,7 @@ TalkerChooserConf::~TalkerChooserConf(){
* @param configGroup Call config->setGroup with this argument before
* loading your configuration.
*/
-void TalkerChooserConf::load(KConfig* config, const QString& configGroup){
+void TalkerChooserConf::load(KConfig* config, const TQString& configGroup){
// kdDebug() << "TalkerChooserConf::load: Running" << endl;
config->setGroup( configGroup );
m_widget->nameLineEdit->setText( config->readEntry( "UserFilterName", m_widget->nameLineEdit->text() ) );
@@ -118,7 +118,7 @@ void TalkerChooserConf::load(KConfig* config, const QString& configGroup){
m_talkerCode = TalkerCode(config->readEntry("TalkerCode"), false);
// Legacy settings.
- QString s = config->readEntry( "LanguageCode" );
+ TQString s = config->readEntry( "LanguageCode" );
if (!s.isEmpty()) m_talkerCode.setFullLanguageCode(s);
s = config->readEntry( "SynthInName" );
if (!s.isEmpty()) m_talkerCode.setPlugInName(s);
@@ -142,7 +142,7 @@ void TalkerChooserConf::load(KConfig* config, const QString& configGroup){
* @param configGroup Call config->setGroup with this argument before
* saving your configuration.
*/
-void TalkerChooserConf::save(KConfig* config, const QString& configGroup){
+void TalkerChooserConf::save(KConfig* config, const TQString& configGroup){
// kdDebug() << "TalkerChooserConf::save: Running" << endl;
config->setGroup( configGroup );
config->writeEntry( "UserFilterName", m_widget->nameLineEdit->text() );
@@ -167,7 +167,7 @@ void TalkerChooserConf::defaults(){
// Default App ID is blank.
m_widget->appIdLineEdit->setText( "" );
// Default to using default Talker.
- m_talkerCode = TalkerCode( QString::null, false );
+ m_talkerCode = TalkerCode( TQString::null, false );
m_widget->talkerLineEdit->setText( m_talkerCode.getTranslatedDescription() );
}
@@ -186,13 +186,13 @@ bool TalkerChooserConf::supportsMultiInstance() { return true; }
* return an empty string.
* @return Filter instance name.
*/
-QString TalkerChooserConf::userPlugInName()
+TQString TalkerChooserConf::userPlugInName()
{
- if (m_widget->talkerLineEdit->text().isEmpty()) return QString::null;
+ if (m_widget->talkerLineEdit->text().isEmpty()) return TQString::null;
if (m_widget->appIdLineEdit->text().isEmpty() &&
- m_widget->reLineEdit->text().isEmpty()) return QString::null;
- QString instName = m_widget->nameLineEdit->text();
- if (instName.isEmpty()) return QString::null;
+ m_widget->reLineEdit->text().isEmpty()) return TQString::null;
+ TQString instName = m_widget->nameLineEdit->text();
+ if (instName.isEmpty()) return TQString::null;
return instName;
}
@@ -200,8 +200,8 @@ void TalkerChooserConf::slotReEditorButton_clicked()
{
// Show Regular Expression Editor dialog if it is installed.
if ( !m_reEditorInstalled ) return;
- QDialog *editorDialog =
- KParts::ComponentFactory::createInstanceFromQuery<QDialog>( "KRegExpEditor/KRegExpEditor" );
+ TQDialog *editorDialog =
+ KParts::ComponentFactory::createInstanceFromQuery<TQDialog>( "KRegExpEditor/KRegExpEditor" );
if ( editorDialog )
{
// kdeutils was installed, so the dialog was found. Fetch the editor interface.
@@ -210,9 +210,9 @@ void TalkerChooserConf::slotReEditorButton_clicked()
Q_ASSERT( reEditor ); // This should not fail!// now use the editor.
reEditor->setRegExp( m_widget->reLineEdit->text() );
int dlgResult = editorDialog->exec();
- if ( dlgResult == QDialog::Accepted )
+ if ( dlgResult == TQDialog::Accepted )
{
- QString re = reEditor->regExp();
+ TQString re = reEditor->regExp();
m_widget->reLineEdit->setText( re );
}
delete editorDialog;
@@ -221,7 +221,7 @@ void TalkerChooserConf::slotReEditorButton_clicked()
void TalkerChooserConf::slotTalkerButton_clicked()
{
- QString talkerCode = m_talkerCode.getTalkerCode();
+ TQString talkerCode = m_talkerCode.getTalkerCode();
SelectTalkerDlg dlg( m_widget, "selecttalkerdialog", i18n("Select Talker"), talkerCode, true );
int dlgResult = dlg.exec();
if ( dlgResult != KDialogBase::Accepted ) return;
@@ -232,8 +232,8 @@ void TalkerChooserConf::slotTalkerButton_clicked()
void TalkerChooserConf::slotLoadButton_clicked()
{
- QString dataDir = KGlobal::dirs()->findAllResources("data", "kttsd/talkerchooser/").last();
- QString filename = KFileDialog::getOpenFileName(
+ TQString dataDir = KGlobal::dirs()->findAllResources("data", "kttsd/talkerchooser/").last();
+ TQString filename = KFileDialog::getOpenFileName(
dataDir,
"*rc|Talker Chooser Config (*rc)",
m_widget,
@@ -247,7 +247,7 @@ void TalkerChooserConf::slotLoadButton_clicked()
void TalkerChooserConf::slotSaveButton_clicked()
{
- QString filename = KFileDialog::getSaveFileName(
+ TQString filename = KFileDialog::getSaveFileName(
KGlobal::dirs()->saveLocation( "data" ,"kttsd/talkerchooser/", false ),
"*rc|Talker Chooser Config (*rc)",
m_widget,
@@ -260,10 +260,10 @@ void TalkerChooserConf::slotSaveButton_clicked()
void TalkerChooserConf::slotClearButton_clicked()
{
- m_widget->nameLineEdit->setText( QString::null );
- m_widget->reLineEdit->setText( QString::null );
- m_widget->appIdLineEdit->setText( QString::null );
- m_talkerCode = TalkerCode( QString::null, false );
+ m_widget->nameLineEdit->setText( TQString::null );
+ m_widget->reLineEdit->setText( TQString::null );
+ m_widget->appIdLineEdit->setText( TQString::null );
+ m_talkerCode = TalkerCode( TQString::null, false );
m_widget->talkerLineEdit->setText( m_talkerCode.getTranslatedDescription() );
configChanged();
}
diff --git a/kttsd/filters/talkerchooser/talkerchooserconf.h b/kttsd/filters/talkerchooser/talkerchooserconf.h
index d6b3959..38a6c49 100644
--- a/kttsd/filters/talkerchooser/talkerchooserconf.h
+++ b/kttsd/filters/talkerchooser/talkerchooserconf.h
@@ -25,7 +25,7 @@
#define _TALKERCHOOSERCONF_H_
// Qt includes.
-#include <qwidget.h>
+#include <tqwidget.h>
// KDE includes.
#include <kconfig.h>
@@ -50,7 +50,7 @@ class TalkerChooserConf : public KttsFilterConf
/**
* Constructor
*/
- TalkerChooserConf( QWidget *parent, const char *name, const QStringList &args = QStringList() );
+ TalkerChooserConf( TQWidget *parent, const char *name, const TQStringList &args = TQStringList() );
/**
* Destructor
@@ -75,7 +75,7 @@ class TalkerChooserConf : public KttsFilterConf
* any instance-specific parameters to load, but it may still wish
* to load parameters that apply to all instances of the plugin.
*/
- virtual void load(KConfig *config, const QString &configGroup);
+ virtual void load(KConfig *config, const TQString &configGroup);
/**
* This function gets called when the user wants to save the settings in
@@ -87,7 +87,7 @@ class TalkerChooserConf : public KttsFilterConf
* @param configGroup Call config->setGroup with this argument before
* saving your configuration.
*/
- virtual void save(KConfig *config, const QString &configGroup);
+ virtual void save(KConfig *config, const TQString &configGroup);
/**
* This function is called to set the settings in the module to sensible
@@ -113,7 +113,7 @@ class TalkerChooserConf : public KttsFilterConf
* return an empty string.
* @return Filter instance name.
*/
- virtual QString userPlugInName();
+ virtual TQString userPlugInName();
private slots:
void slotReEditorButton_clicked();
diff --git a/kttsd/filters/talkerchooser/talkerchooserproc.cpp b/kttsd/filters/talkerchooser/talkerchooserproc.cpp
index 628b68a..5758df2 100644
--- a/kttsd/filters/talkerchooser/talkerchooserproc.cpp
+++ b/kttsd/filters/talkerchooser/talkerchooserproc.cpp
@@ -22,7 +22,7 @@
******************************************************************************/
// Qt includes.
-#include <qregexp.h>
+#include <tqregexp.h>
// KDE includes.
#include <kdebug.h>
@@ -38,7 +38,7 @@
/**
* Constructor.
*/
-TalkerChooserProc::TalkerChooserProc( QObject *parent, const char *name, const QStringList& /*args*/ ) :
+TalkerChooserProc::TalkerChooserProc( TQObject *parent, const char *name, const TQStringList& /*args*/ ) :
KttsFilterProc(parent, name)
{
// kdDebug() << "TalkerChooserProc::TalkerChooserProc: Running" << endl;
@@ -61,14 +61,14 @@ TalkerChooserProc::~TalkerChooserProc()
* Note: The parameters are for reading from kttsdrc file. Plugins may wish to maintain
* separate configuration files of their own.
*/
-bool TalkerChooserProc::init(KConfig* config, const QString& configGroup){
+bool TalkerChooserProc::init(KConfig* config, const TQString& configGroup){
// kdDebug() << "PlugInProc::init: Running" << endl;
config->setGroup( configGroup );
m_re = config->readEntry( "MatchRegExp" );
m_appIdList = config->readListEntry( "AppIDs" );
m_chosenTalkerCode = TalkerCode(config->readEntry("TalkerCode"), false);
// Legacy settings.
- QString s = config->readEntry( "LanguageCode" );
+ TQString s = config->readEntry( "LanguageCode" );
if (!s.isEmpty()) m_chosenTalkerCode.setFullLanguageCode(s);
s = config->readEntry( "SynthInName" );
if (!s.isEmpty()) m_chosenTalkerCode.setPlugInName(s);
@@ -102,12 +102,12 @@ bool TalkerChooserProc::init(KConfig* config, const QString& configGroup){
* @param appId The DCOP appId of the application that queued the text.
* Also useful for hints about how to do the filtering.
*/
-/*virtual*/ QString TalkerChooserProc::convert(const QString& inputText, TalkerCode* talkerCode,
- const QCString& appId)
+/*virtual*/ TQString TalkerChooserProc::convert(const TQString& inputText, TalkerCode* talkerCode,
+ const TQCString& appId)
{
if ( !m_re.isEmpty() )
{
- int pos = inputText.find( QRegExp(m_re) );
+ int pos = inputText.find( TQRegExp(m_re) );
if ( pos < 0 ) return inputText;
}
// If appId doesn't match, return input unmolested.
@@ -116,7 +116,7 @@ bool TalkerChooserProc::init(KConfig* config, const QString& configGroup){
// kdDebug() << "TalkerChooserProc::convert: converting " << inputText << " if appId "
// << appId << " matches " << m_appIdList << endl;
bool found = false;
- QString appIdStr = appId;
+ TQString appIdStr = appId;
for ( uint ndx=0; ndx < m_appIdList.count(); ++ndx )
{
if ( appIdStr.contains(m_appIdList[ndx]) )
diff --git a/kttsd/filters/talkerchooser/talkerchooserproc.h b/kttsd/filters/talkerchooser/talkerchooserproc.h
index 07cde68..8c9ab01 100644
--- a/kttsd/filters/talkerchooser/talkerchooserproc.h
+++ b/kttsd/filters/talkerchooser/talkerchooserproc.h
@@ -36,7 +36,7 @@ public:
/**
* Constructor.
*/
- TalkerChooserProc( QObject *parent, const char *name, const QStringList &args = QStringList() );
+ TalkerChooserProc( TQObject *parent, const char *name, const TQStringList &args = TQStringList() );
/**
* Destructor.
@@ -52,7 +52,7 @@ public:
* Note: The parameters are for reading from kttsdrc file. Plugins may wish to maintain
* separate configuration files of their own.
*/
- virtual bool init(KConfig *config, const QString &configGroup);
+ virtual bool init(KConfig *config, const TQString &configGroup);
/**
* Returns True if the plugin supports asynchronous processing,
@@ -75,12 +75,12 @@ public:
* @param appId The DCOP appId of the application that queued the text.
* Also useful for hints about how to do the filtering.
*/
- virtual QString convert(const QString& inputText, TalkerCode* talkerCode, const QCString& appId);
+ virtual TQString convert(const TQString& inputText, TalkerCode* talkerCode, const TQCString& appId);
private:
- QString m_re;
- QStringList m_appIdList;
+ TQString m_re;
+ TQStringList m_appIdList;
TalkerCode m_chosenTalkerCode;
};