summaryrefslogtreecommitdiffstats
path: root/kdeprint
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:33:34 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:33:34 +0000
commitc663b6440964f6ac48027143ac9e63298991f9d0 (patch)
tree6d8b0c5a5f9db1ee16acf98b1397cea9126b281d /kdeprint
parenta061f7191beebb0e4a3b0c0a7c534ec5f22f2dc7 (diff)
downloadtdebase-c663b6440964f6ac48027143ac9e63298991f9d0.tar.gz
tdebase-c663b6440964f6ac48027143ac9e63298991f9d0.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1157639 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdeprint')
-rw-r--r--kdeprint/descriptions/sortthem.cpp6
-rw-r--r--kdeprint/kdeprint_part/printpart.cpp10
-rw-r--r--kdeprint/kdeprint_part/printpart.h6
-rw-r--r--kdeprint/kdeprintfax/conffax.cpp26
-rw-r--r--kdeprint/kdeprintfax/conffax.h4
-rw-r--r--kdeprint/kdeprintfax/conffilters.cpp66
-rw-r--r--kdeprint/kdeprintfax/conffilters.h6
-rw-r--r--kdeprint/kdeprintfax/confgeneral.cpp34
-rw-r--r--kdeprint/kdeprintfax/confgeneral.h8
-rw-r--r--kdeprint/kdeprintfax/configdlg.cpp6
-rw-r--r--kdeprint/kdeprintfax/configdlg.h4
-rw-r--r--kdeprint/kdeprintfax/confsystem.cpp50
-rw-r--r--kdeprint/kdeprintfax/confsystem.h6
-rw-r--r--kdeprint/kdeprintfax/defcmds.cpp4
-rw-r--r--kdeprint/kdeprintfax/defcmds.h4
-rw-r--r--kdeprint/kdeprintfax/faxab.cpp42
-rw-r--r--kdeprint/kdeprintfax/faxab.h18
-rw-r--r--kdeprint/kdeprintfax/faxctrl.cpp158
-rw-r--r--kdeprint/kdeprintfax/faxctrl.h20
-rw-r--r--kdeprint/kdeprintfax/filterdlg.cpp26
-rw-r--r--kdeprint/kdeprintfax/filterdlg.h4
-rw-r--r--kdeprint/kdeprintfax/kdeprintfax.cpp210
-rw-r--r--kdeprint/kdeprintfax/kdeprintfax.h44
-rw-r--r--kdeprint/kdeprintfax/main.cpp6
-rw-r--r--kdeprint/kjobviewer/kjobviewer.cpp26
-rw-r--r--kdeprint/kjobviewer/kjobviewer.h6
-rw-r--r--kdeprint/kprinter/main.cpp4
-rw-r--r--kdeprint/kprinter/printwrapper.cpp68
-rw-r--r--kdeprint/kprinter/printwrapper.h4
-rw-r--r--kdeprint/printmgr/kcmprintmgr.cpp10
-rw-r--r--kdeprint/printmgr/kcmprintmgr.h4
-rw-r--r--kdeprint/slave/kio_print.cpp148
-rw-r--r--kdeprint/slave/kio_print.h20
33 files changed, 529 insertions, 529 deletions
diff --git a/kdeprint/descriptions/sortthem.cpp b/kdeprint/descriptions/sortthem.cpp
index e9e49c058..9adc284b1 100644
--- a/kdeprint/descriptions/sortthem.cpp
+++ b/kdeprint/descriptions/sortthem.cpp
@@ -1,14 +1,14 @@
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <stdlib.h>
#include <stdio.h>
int main(int argc, char **argv) {
-QStringList have;
+TQStringList have;
char buf[1024];
diff --git a/kdeprint/kdeprint_part/printpart.cpp b/kdeprint/kdeprint_part/printpart.cpp
index 535c0e7e0..c8d6ccb15 100644
--- a/kdeprint/kdeprint_part/printpart.cpp
+++ b/kdeprint/kdeprint_part/printpart.cpp
@@ -28,14 +28,14 @@
#include <kaboutdata.h>
#include <kdebug.h>
#include <kparts/genericfactory.h>
-#include <qwidget.h>
+#include <tqwidget.h>
typedef KParts::GenericFactory<PrintPart> PrintPartFactory;
K_EXPORT_COMPONENT_FACTORY( libkdeprint_part, PrintPartFactory )
-PrintPart::PrintPart(QWidget *parentWidget, const char * /*widgetName*/ ,
- QObject *parent, const char *name,
- const QStringList & /*args*/ )
+PrintPart::PrintPart(TQWidget *parentWidget, const char * /*widgetName*/ ,
+ TQObject *parent, const char *name,
+ const TQStringList & /*args*/ )
: KParts::ReadOnlyPart(parent, name)
{
setInstance(PrintPartFactory::instance());
@@ -43,7 +43,7 @@ PrintPart::PrintPart(QWidget *parentWidget, const char * /*widgetName*/ ,
m_extension = new PrintPartExtension(this);
m_view = new KMMainView(parentWidget, "MainView", actionCollection());
- m_view->setFocusPolicy(QWidget::ClickFocus);
+ m_view->setFocusPolicy(TQWidget::ClickFocus);
m_view->enableToolbar(false);
setWidget(m_view);
diff --git a/kdeprint/kdeprint_part/printpart.h b/kdeprint/kdeprint_part/printpart.h
index afba3c277..c84fed1cc 100644
--- a/kdeprint/kdeprint_part/printpart.h
+++ b/kdeprint/kdeprint_part/printpart.h
@@ -31,9 +31,9 @@ class PrintPart : public KParts::ReadOnlyPart
{
Q_OBJECT
public:
- PrintPart(QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
- const QStringList & );
+ PrintPart(TQWidget *parentWidget, const char *widgetName,
+ TQObject *parent, const char *name,
+ const TQStringList & );
virtual ~PrintPart();
static KAboutData *createAboutData();
diff --git a/kdeprint/kdeprintfax/conffax.cpp b/kdeprint/kdeprintfax/conffax.cpp
index c88184595..2351c9c69 100644
--- a/kdeprint/kdeprintfax/conffax.cpp
+++ b/kdeprint/kdeprintfax/conffax.cpp
@@ -20,11 +20,11 @@
#include "conffax.h"
-#include <qcombobox.h>
-#include <qlineedit.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qprinter.h>
+#include <tqcombobox.h>
+#include <tqlineedit.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqprinter.h>
#include <kglobal.h>
#include <kconfig.h>
@@ -33,24 +33,24 @@
#include <stdlib.h>
-ConfFax::ConfFax(QWidget *parent, const char *name)
-: QWidget(parent, name)
+ConfFax::ConfFax(TQWidget *parent, const char *name)
+: TQWidget(parent, name)
{
- m_resolution = new QComboBox(this);
+ m_resolution = new TQComboBox(this);
m_resolution->setMinimumHeight(25);
- m_pagesize = new QComboBox(this);
+ m_pagesize = new TQComboBox(this);
m_pagesize->setMinimumHeight(25);
m_resolution->insertItem(i18n("High (204x196 dpi)"));
m_resolution->insertItem(i18n("Low (204x98 dpi)"));
m_pagesize->insertItem(i18n("A4"));
m_pagesize->insertItem(i18n("Letter"));
m_pagesize->insertItem(i18n("Legal"));
- QLabel *m_resolutionlabel = new QLabel(i18n("&Resolution:"), this);
+ QLabel *m_resolutionlabel = new TQLabel(i18n("&Resolution:"), this);
m_resolutionlabel->setBuddy(m_resolution);
- QLabel *m_pagesizelabel = new QLabel(i18n("&Paper size:"), this);
+ QLabel *m_pagesizelabel = new TQLabel(i18n("&Paper size:"), this);
m_pagesizelabel->setBuddy(m_pagesize);
- QGridLayout *l0 = new QGridLayout(this, 3, 2, 10, 10);
+ QGridLayout *l0 = new TQGridLayout(this, 3, 2, 10, 10);
l0->setColStretch(1, 1);
l0->setRowStretch(2, 1);
l0->addWidget(m_resolutionlabel, 0, 0);
@@ -63,7 +63,7 @@ void ConfFax::load()
{
KConfig *conf = KGlobal::config();
conf->setGroup("Fax");
- QString v = conf->readEntry("Page", KGlobal::locale()->pageSize() == QPrinter::A4 ? "a4" : "letter");
+ QString v = conf->readEntry("Page", KGlobal::locale()->pageSize() == TQPrinter::A4 ? "a4" : "letter");
if (v == "letter") m_pagesize->setCurrentItem(1);
else if (v == "legal") m_pagesize->setCurrentItem(2);
else m_pagesize->setCurrentItem(0);
diff --git a/kdeprint/kdeprintfax/conffax.h b/kdeprint/kdeprintfax/conffax.h
index ffcd125ae..888ef5825 100644
--- a/kdeprint/kdeprintfax/conffax.h
+++ b/kdeprint/kdeprintfax/conffax.h
@@ -21,14 +21,14 @@
#ifndef CONFFAX_H
#define CONFFAX_H
-#include <qwidget.h>
+#include <tqwidget.h>
class QComboBox;
class ConfFax : public QWidget
{
public:
- ConfFax(QWidget *parent = 0, const char *name = 0);
+ ConfFax(TQWidget *parent = 0, const char *name = 0);
void load();
void save();
diff --git a/kdeprint/kdeprintfax/conffilters.cpp b/kdeprint/kdeprintfax/conffilters.cpp
index ab828c582..fc33f88b1 100644
--- a/kdeprint/kdeprintfax/conffilters.cpp
+++ b/kdeprint/kdeprintfax/conffilters.cpp
@@ -21,13 +21,13 @@
#include "conffilters.h"
#include "filterdlg.h"
-#include <qpushbutton.h>
-#include <qlayout.h>
-#include <qtooltip.h>
-#include <qfile.h>
-#include <qtextstream.h>
-#include <qregexp.h>
-#include <qheader.h>
+#include <tqpushbutton.h>
+#include <tqlayout.h>
+#include <tqtooltip.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
+#include <tqregexp.h>
+#include <tqheader.h>
#include <klocale.h>
#include <klistview.h>
@@ -35,41 +35,41 @@
#include <kstandarddirs.h>
#include <kmessagebox.h>
-ConfFilters::ConfFilters(QWidget *parent, const char *name)
-: QWidget(parent, name)
+ConfFilters::ConfFilters(TQWidget *parent, const char *name)
+: TQWidget(parent, name)
{
m_filters = new KListView(this);
m_filters->addColumn(i18n("Mime Type"));
m_filters->addColumn(i18n("Command"));
- m_filters->setFrameStyle(QFrame::WinPanel|QFrame::Sunken);
+ m_filters->setFrameStyle(TQFrame::WinPanel|TQFrame::Sunken);
m_filters->setLineWidth(1);
m_filters->setSorting(-1);
m_filters->header()->setStretchEnabled(true, 1);
- connect(m_filters, SIGNAL(doubleClicked(QListViewItem*)), SLOT(slotChange()));
+ connect(m_filters, TQT_SIGNAL(doubleClicked(TQListViewItem*)), TQT_SLOT(slotChange()));
- m_add = new QPushButton(this);
+ m_add = new TQPushButton(this);
m_add->setPixmap(BarIcon("filenew"));
- m_remove = new QPushButton(this);
+ m_remove = new TQPushButton(this);
m_remove->setIconSet(BarIconSet("remove"));
- m_change = new QPushButton(this);
+ m_change = new TQPushButton(this);
m_change->setIconSet(BarIconSet("filter"));
- m_up = new QPushButton(this);
+ m_up = new TQPushButton(this);
m_up->setIconSet(BarIconSet("up"));
- m_down = new QPushButton(this);
+ m_down = new TQPushButton(this);
m_down->setIconSet(BarIconSet("down"));
- connect(m_add, SIGNAL(clicked()), SLOT(slotAdd()));
- connect(m_change, SIGNAL(clicked()), SLOT(slotChange()));
- connect(m_remove, SIGNAL(clicked()), SLOT(slotRemove()));
- connect(m_up, SIGNAL(clicked()), SLOT(slotUp()));
- connect(m_down, SIGNAL(clicked()), SLOT(slotDown()));
- QToolTip::add(m_add, i18n("Add filter"));
- QToolTip::add(m_change, i18n("Modify filter"));
- QToolTip::add(m_remove, i18n("Remove filter"));
- QToolTip::add(m_up, i18n("Move filter up"));
- QToolTip::add(m_down, i18n("Move filter down"));
-
- QHBoxLayout *l0 = new QHBoxLayout(this, 10, 10);
- QVBoxLayout *l1 = new QVBoxLayout(0, 0, 0);
+ connect(m_add, TQT_SIGNAL(clicked()), TQT_SLOT(slotAdd()));
+ connect(m_change, TQT_SIGNAL(clicked()), TQT_SLOT(slotChange()));
+ connect(m_remove, TQT_SIGNAL(clicked()), TQT_SLOT(slotRemove()));
+ connect(m_up, TQT_SIGNAL(clicked()), TQT_SLOT(slotUp()));
+ connect(m_down, TQT_SIGNAL(clicked()), TQT_SLOT(slotDown()));
+ TQToolTip::add(m_add, i18n("Add filter"));
+ TQToolTip::add(m_change, i18n("Modify filter"));
+ TQToolTip::add(m_remove, i18n("Remove filter"));
+ TQToolTip::add(m_up, i18n("Move filter up"));
+ TQToolTip::add(m_down, i18n("Move filter down"));
+
+ QHBoxLayout *l0 = new TQHBoxLayout(this, 10, 10);
+ QVBoxLayout *l1 = new TQVBoxLayout(0, 0, 0);
l0->addWidget(m_filters, 1);
l0->addLayout(l1, 0);
l1->addWidget(m_add);
@@ -80,7 +80,7 @@ ConfFilters::ConfFilters(QWidget *parent, const char *name)
l1->addWidget(m_down);
l1->addStretch(1);
updateButton();
- connect(m_filters, SIGNAL(selectionChanged ()),SLOT(updateButton()));
+ connect(m_filters, TQT_SIGNAL(selectionChanged ()),TQT_SLOT(updateButton()));
}
void ConfFilters::load()
@@ -95,11 +95,11 @@ void ConfFilters::load()
while (!t.eof())
{
line = t.readLine().stripWhiteSpace();
- if ((p=line.find(QRegExp("\\s"))) != -1)
+ if ((p=line.find(TQRegExp("\\s"))) != -1)
{
QString mime(line.left(p)), cmd(line.right(line.length()-p-1).stripWhiteSpace());
if (!mime.isEmpty() && !cmd.isEmpty())
- item = new QListViewItem(m_filters, item, mime, cmd);
+ item = new TQListViewItem(m_filters, item, mime, cmd);
}
}
}
@@ -126,7 +126,7 @@ void ConfFilters::slotAdd()
if (FilterDlg::doIt(this, &mime, &cmd))
if (!mime.isEmpty() && !cmd.isEmpty())
{
- new QListViewItem(m_filters, m_filters->currentItem(), mime, cmd);
+ new TQListViewItem(m_filters, m_filters->currentItem(), mime, cmd);
updateButton();
}
else
diff --git a/kdeprint/kdeprintfax/conffilters.h b/kdeprint/kdeprintfax/conffilters.h
index 38f564b1f..ce3d64156 100644
--- a/kdeprint/kdeprintfax/conffilters.h
+++ b/kdeprint/kdeprintfax/conffilters.h
@@ -21,15 +21,15 @@
#ifndef CONFFILTERS_H
#define CONFFILTERS_H
-#include <qwidget.h>
-#include <qpushbutton.h>
+#include <tqwidget.h>
+#include <tqpushbutton.h>
class KListView;
class ConfFilters : public QWidget
{
Q_OBJECT
public:
- ConfFilters(QWidget *parent = 0, const char *name = 0);
+ ConfFilters(TQWidget *parent = 0, const char *name = 0);
void load();
void save();
diff --git a/kdeprint/kdeprintfax/confgeneral.cpp b/kdeprint/kdeprintfax/confgeneral.cpp
index 3f592e694..757c54af7 100644
--- a/kdeprint/kdeprintfax/confgeneral.cpp
+++ b/kdeprint/kdeprintfax/confgeneral.cpp
@@ -20,10 +20,10 @@
#include "confgeneral.h"
-#include <qlineedit.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qcheckbox.h>
+#include <tqlineedit.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
#include <kglobal.h>
#include <kconfig.h>
@@ -32,26 +32,26 @@
#include <stdlib.h>
-ConfGeneral::ConfGeneral(QWidget *parent, const char *name)
-: QWidget(parent, name)
+ConfGeneral::ConfGeneral(TQWidget *parent, const char *name)
+: TQWidget(parent, name)
{
- m_name = new QLineEdit(this);
- m_company = new QLineEdit(this);
- m_number = new QLineEdit(this);
- QLabel *m_namelabel = new QLabel(i18n("&Name:"), this);
+ m_name = new TQLineEdit(this);
+ m_company = new TQLineEdit(this);
+ m_number = new TQLineEdit(this);
+ QLabel *m_namelabel = new TQLabel(i18n("&Name:"), this);
m_namelabel->setBuddy(m_name);
- QLabel *m_companylabel = new QLabel(i18n("&Company:"), this);
+ QLabel *m_companylabel = new TQLabel(i18n("&Company:"), this);
m_companylabel->setBuddy(m_company);
- QLabel *m_numberlabel = new QLabel(i18n("N&umber:"), this);
+ QLabel *m_numberlabel = new TQLabel(i18n("N&umber:"), this);
m_numberlabel->setBuddy(m_number);
KSeparator *sep = new KSeparator( this );
- m_replace_int_char = new QCheckBox( i18n( "Replace international prefix '+' with:" ), this );
- m_replace_int_char_val = new QLineEdit( this );
+ m_replace_int_char = new TQCheckBox( i18n( "Replace international prefix '+' with:" ), this );
+ m_replace_int_char_val = new TQLineEdit( this );
m_replace_int_char_val->setEnabled( false );
- connect( m_replace_int_char, SIGNAL( toggled( bool ) ), m_replace_int_char_val, SLOT( setEnabled( bool ) ) );
+ connect( m_replace_int_char, TQT_SIGNAL( toggled( bool ) ), m_replace_int_char_val, TQT_SLOT( setEnabled( bool ) ) );
- QGridLayout *l0 = new QGridLayout(this, 6, 2, 10, 10);
+ QGridLayout *l0 = new TQGridLayout(this, 6, 2, 10, 10);
l0->setColStretch(1, 1);
l0->setRowStretch(5, 1);
l0->addWidget(m_namelabel, 0, 0);
@@ -61,7 +61,7 @@ ConfGeneral::ConfGeneral(QWidget *parent, const char *name)
l0->addWidget(m_company, 1, 1);
l0->addWidget(m_number, 2, 1);
l0->addMultiCellWidget( sep, 3, 3, 0, 1 );
- QHBoxLayout *l1 = new QHBoxLayout( this, 0, 10 );
+ TQHBoxLayout *l1 = new TQHBoxLayout( this, 0, 10 );
l0->addMultiCellLayout( l1, 4, 4, 0, 1 );
l1->addWidget( m_replace_int_char );
l1->addWidget( m_replace_int_char_val );
diff --git a/kdeprint/kdeprintfax/confgeneral.h b/kdeprint/kdeprintfax/confgeneral.h
index 5f88106d8..46c54c2a5 100644
--- a/kdeprint/kdeprintfax/confgeneral.h
+++ b/kdeprint/kdeprintfax/confgeneral.h
@@ -21,7 +21,7 @@
#ifndef CONFGENERAL_H
#define CONFGENERAL_H
-#include <qwidget.h>
+#include <tqwidget.h>
class QLineEdit;
class QCheckBox;
@@ -29,15 +29,15 @@ class QCheckBox;
class ConfGeneral : public QWidget
{
public:
- ConfGeneral(QWidget *parent = 0, const char *name = 0);
+ ConfGeneral(TQWidget *parent = 0, const char *name = 0);
void load();
void save();
private:
QLineEdit *m_name, *m_company, *m_number;
- QCheckBox *m_replace_int_char;
- QLineEdit *m_replace_int_char_val;
+ TQCheckBox *m_replace_int_char;
+ TQLineEdit *m_replace_int_char_val;
};
#endif
diff --git a/kdeprint/kdeprintfax/configdlg.cpp b/kdeprint/kdeprintfax/configdlg.cpp
index 669d8c200..3ede8cab7 100644
--- a/kdeprint/kdeprintfax/configdlg.cpp
+++ b/kdeprint/kdeprintfax/configdlg.cpp
@@ -24,11 +24,11 @@
#include "confsystem.h"
#include "conffilters.h"
-#include <qvbox.h>
+#include <tqvbox.h>
#include <klocale.h>
#include <kiconloader.h>
-ConfigDlg::ConfigDlg(QWidget *parent, const char *name)
+ConfigDlg::ConfigDlg(TQWidget *parent, const char *name)
: KDialogBase(IconList, i18n("Configuration"), Ok|Cancel, Ok, parent, name, true)
{
QVBox *page1 = addVBoxPage(i18n("Personal"), i18n("Personal Settings"), DesktopIcon("kdmconfig"));
@@ -62,7 +62,7 @@ void ConfigDlg::save()
m_filters->save();
}
-bool ConfigDlg::configure(QWidget *parent)
+bool ConfigDlg::configure(TQWidget *parent)
{
ConfigDlg dlg(parent);
dlg.load();
diff --git a/kdeprint/kdeprintfax/configdlg.h b/kdeprint/kdeprintfax/configdlg.h
index f4bba762d..1e312b57b 100644
--- a/kdeprint/kdeprintfax/configdlg.h
+++ b/kdeprint/kdeprintfax/configdlg.h
@@ -31,10 +31,10 @@ class ConfFilters;
class ConfigDlg : public KDialogBase
{
public:
- static bool configure(QWidget *parent = 0);
+ static bool configure(TQWidget *parent = 0);
protected:
- ConfigDlg(QWidget *parent = 0, const char *name = 0);
+ ConfigDlg(TQWidget *parent = 0, const char *name = 0);
void load();
void save();
diff --git a/kdeprint/kdeprintfax/confsystem.cpp b/kdeprint/kdeprintfax/confsystem.cpp
index 02ee7e66d..51ea326c8 100644
--- a/kdeprint/kdeprintfax/confsystem.cpp
+++ b/kdeprint/kdeprintfax/confsystem.cpp
@@ -21,10 +21,10 @@
#include "confsystem.h"
#include "defcmds.h"
-#include <qlineedit.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qcombobox.h>
+#include <tqlineedit.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqcombobox.h>
#include <kglobal.h>
#include <kconfig.h>
@@ -38,43 +38,43 @@
#define MGETTY_ID 2
#define OTHER_ID 3
-ConfSystem::ConfSystem(QWidget *parent, const char *name)
-: QWidget(parent, name)
+ConfSystem::ConfSystem(TQWidget *parent, const char *name)
+: TQWidget(parent, name)
{
- m_system = new QComboBox(this);
+ m_system = new TQComboBox(this);
m_system->insertItem("EFax");
m_system->insertItem("HylaFax");
m_system->insertItem("Mgetty-sendfax");
m_system->insertItem( "Other" );
- m_command = new QLineEdit(this);
- QLabel *syslabel = new QLabel(i18n("F&ax system:"), this);
- QLabel *cmdlabel = new QLabel(i18n("Co&mmand:"), this);
+ m_command = new TQLineEdit(this);
+ QLabel *syslabel = new TQLabel(i18n("F&ax system:"), this);
+ QLabel *cmdlabel = new TQLabel(i18n("Co&mmand:"), this);
syslabel->setBuddy(m_system);
cmdlabel->setBuddy(m_command);
- connect(m_system, SIGNAL(activated(int)), SLOT(slotSystemChanged(int)));
+ connect(m_system, TQT_SIGNAL(activated(int)), TQT_SLOT(slotSystemChanged(int)));
m_current = 0;
m_system->setCurrentItem(m_current);
- QWidget *m_dummy1 = new QWidget(this), *m_dummy2 = new QWidget(this);
- m_server = new QLineEdit(m_dummy1);
- m_device = new QComboBox(m_dummy2);
- QLabel *srvlabel = new QLabel(i18n("Fax &server (if any):"), m_dummy1);
- QLabel *devlabel = new QLabel(i18n("&Fax/Modem device:"), m_dummy2);
+ QWidget *m_dummy1 = new TQWidget(this), *m_dummy2 = new TQWidget(this);
+ m_server = new TQLineEdit(m_dummy1);
+ m_device = new TQComboBox(m_dummy2);
+ QLabel *srvlabel = new TQLabel(i18n("Fax &server (if any):"), m_dummy1);
+ QLabel *devlabel = new TQLabel(i18n("&Fax/Modem device:"), m_dummy2);
srvlabel->setBuddy(m_server);
devlabel->setBuddy(m_device);
m_device->insertItem(i18n("Standard Modem Port"));
for (int i=0; i<10; i++)
m_device->insertItem(i18n("Serial Port #%1").arg(i));
m_device->insertItem( i18n( "Other" ) );
- connect( m_device, SIGNAL( activated( int ) ), SLOT( slotDeviceChanged( int ) ) );
- m_device_edit = new QLineEdit( m_dummy2 );
+ connect( m_device, TQT_SIGNAL( activated( int ) ), TQT_SLOT( slotDeviceChanged( int ) ) );
+ m_device_edit = new TQLineEdit( m_dummy2 );
slotDeviceChanged( 0 );
KSeparator *sep = new KSeparator(this);
sep->setMinimumHeight(10);
- QVBoxLayout *l0 = new QVBoxLayout(this, 10, 10);
- QGridLayout *l1 = new QGridLayout(0, 2, 2, 0, 10);
+ QVBoxLayout *l0 = new TQVBoxLayout(this, 10, 10);
+ QGridLayout *l1 = new TQGridLayout(0, 2, 2, 0, 10);
l0->addLayout(l1);
l1->setColStretch(1, 1);
l1->addWidget(syslabel, 0, 0);
@@ -85,10 +85,10 @@ ConfSystem::ConfSystem(QWidget *parent, const char *name)
l0->addWidget(m_dummy1);
l0->addWidget(m_dummy2);
l0->addStretch(1);
- QHBoxLayout *l4 = new QHBoxLayout(m_dummy1, 0, 10);
+ QHBoxLayout *l4 = new TQHBoxLayout(m_dummy1, 0, 10);
l4->addWidget(srvlabel, 0);
l4->addWidget(m_server, 1);
- QGridLayout *l5 = new QGridLayout( m_dummy2, 2, 2, 0, 10 );
+ QGridLayout *l5 = new TQGridLayout( m_dummy2, 2, 2, 0, 10 );
l5->setColStretch( 1, 1 );
l5->addWidget(devlabel, 0, 0);
l5->addWidget(m_device, 0, 1);
@@ -102,7 +102,7 @@ void ConfSystem::load()
m_commands << conf->readPathEntry("EFax", defaultCommand(efax_default_cmd));
m_commands << conf->readPathEntry("HylaFax", defaultCommand(hylafax_default_cmd));
m_commands << conf->readPathEntry("Mgetty", defaultCommand(mgetty_default_cmd));
- m_commands << conf->readPathEntry( "Other", QString::null );
+ m_commands << conf->readPathEntry( "Other", TQString::null );
QString v = conf->readEntry("System", "efax");
if (v == "mgetty") m_current = MGETTY_ID;
else if (v == "hylafax") m_current = HYLAFAX_ID;
@@ -158,10 +158,10 @@ void ConfSystem::save()
}
conf->setGroup("Fax");
if ( m_device->currentItem() != ( m_device->count()-1 ) )
- conf->writeEntry("Device", m_device->currentItem() == 0 ? QString("modem") : QString("ttyS%1").arg(m_device->currentItem()-1));
+ conf->writeEntry("Device", m_device->currentItem() == 0 ? TQString("modem") : TQString("ttyS%1").arg(m_device->currentItem()-1));
else
{
- QString dev = m_device_edit->text();
+ TQString dev = m_device_edit->text();
// strip leading "/dev/"
if ( dev.startsWith( "/dev/" ) )
dev = dev.mid( 5 );
diff --git a/kdeprint/kdeprintfax/confsystem.h b/kdeprint/kdeprintfax/confsystem.h
index 202e5f7a0..4e83d6ff9 100644
--- a/kdeprint/kdeprintfax/confsystem.h
+++ b/kdeprint/kdeprintfax/confsystem.h
@@ -21,8 +21,8 @@
#ifndef CONFSYSTEM_H
#define CONFSYSTEM_H
-#include <qwidget.h>
-#include <qstringlist.h>
+#include <tqwidget.h>
+#include <tqstringlist.h>
class QLineEdit;
class QComboBox;
@@ -31,7 +31,7 @@ class ConfSystem : public QWidget
{
Q_OBJECT
public:
- ConfSystem(QWidget *parent = 0, const char *name = 0);
+ ConfSystem(TQWidget *parent = 0, const char *name = 0);
void load();
void save();
diff --git a/kdeprint/kdeprintfax/defcmds.cpp b/kdeprint/kdeprintfax/defcmds.cpp
index b9fc8beee..09631b51d 100644
--- a/kdeprint/kdeprintfax/defcmds.cpp
+++ b/kdeprint/kdeprintfax/defcmds.cpp
@@ -19,10 +19,10 @@
#include "defcmds.h"
-#include <qregexp.h>
+#include <tqregexp.h>
#include <kstandarddirs.h>
-QString defaultCommand(const QString& cmd)
+TQString defaultCommand(const TQString& cmd)
{
QString str(cmd);
QRegExp r("%exe_(\\w+)");
diff --git a/kdeprint/kdeprintfax/defcmds.h b/kdeprint/kdeprintfax/defcmds.h
index cf9131e86..f76094709 100644
--- a/kdeprint/kdeprintfax/defcmds.h
+++ b/kdeprint/kdeprintfax/defcmds.h
@@ -21,12 +21,12 @@
#ifndef DEFCMDS_H
#define DEFCMDS_H
-#include <qstring.h>
+#include <tqstring.h>
#define efax_default_cmd "%exe_fax %user_{NAME=\"@@\"} %dev_{DEV=@@} PAGE=%page %from_{FROM=\"@@\"} %res_{?\?-l} send %number %files"
#define hylafax_default_cmd "%exe_sendfax %cover_{?\?-n} %server_h %res_{-m?\?-l} %subject_r %time_a %enterprise_x %comment_c %email_f %from_W %page_s -d %name_{@@@}%number %files"
#define mgetty_default_cmd "%exe_faxspool %user_F %email_f %name_D %time_t %number %files %res_{?\?-n} %cover_{?\?-C -}"
-QString defaultCommand(const QString& cmd);
+TQString defaultCommand(const TQString& cmd);
#endif
diff --git a/kdeprint/kdeprintfax/faxab.cpp b/kdeprint/kdeprintfax/faxab.cpp
index 28ba4e5c8..ebd6b9cb2 100644
--- a/kdeprint/kdeprintfax/faxab.cpp
+++ b/kdeprint/kdeprintfax/faxab.cpp
@@ -20,11 +20,11 @@
#include "faxab.h"
-#include <qlabel.h>
-#include <qlayout.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
#include <kpushbutton.h>
#include <klistview.h>
-#include <qheader.h>
+#include <tqheader.h>
#include <klocale.h>
#include <kabc/stdaddressbook.h>
#include <kmessagebox.h>
@@ -34,26 +34,26 @@
#include <kglobal.h>
#include <kconfig.h>
-FaxAB::FaxAB(QWidget *parent, const char *name)
+FaxAB::FaxAB(TQWidget *parent, const char *name)
: KDialog(parent, name, true)
{
m_list = new KListView( this );
m_list->addColumn( i18n( "Name" ) );
m_list->addColumn( i18n( "Fax Number" ) );
m_list->header()->setStretchEnabled( true, 0 );
- QLabel *m_listlabel = new QLabel(i18n("Entries:"), this);
+ QLabel *m_listlabel = new TQLabel(i18n("Entries:"), this);
m_ok = new KPushButton(KStdGuiItem::ok(), this);
QPushButton *m_cancel = new KPushButton(KStdGuiItem::cancel(), this);
QPushButton *m_ab = new KPushButton(KGuiItem(i18n("&Edit Addressbook"), "contents"), this);
- connect(m_ok, SIGNAL(clicked()), SLOT(accept()));
- connect(m_cancel, SIGNAL(clicked()), SLOT(reject()));
- connect(m_ab, SIGNAL(clicked()), SLOT(slotEditAb()));
+ connect(m_ok, TQT_SIGNAL(clicked()), TQT_SLOT(accept()));
+ connect(m_cancel, TQT_SIGNAL(clicked()), TQT_SLOT(reject()));
+ connect(m_ab, TQT_SIGNAL(clicked()), TQT_SLOT(slotEditAb()));
m_ok->setDefault(true);
- QVBoxLayout *l0 = new QVBoxLayout(this, 10, 10);
+ QVBoxLayout *l0 = new TQVBoxLayout(this, 10, 10);
l0->addWidget( m_listlabel );
l0->addWidget( m_list );
- QHBoxLayout *l2 = new QHBoxLayout(0, 0, 10);
+ QHBoxLayout *l2 = new TQHBoxLayout(0, 0, 10);
l0->addLayout(l2, 0);
l2->addWidget(m_ab, 0);
l2->addStretch(1);
@@ -62,11 +62,11 @@ FaxAB::FaxAB(QWidget *parent, const char *name)
KConfig *conf = KGlobal::config();
conf->setGroup( "General" );
- QSize defsize( 400, 200 );
+ TQSize defsize( 400, 200 );
resize( conf->readSizeEntry( "ABSize", &defsize ) );
initialize();
- connect(KABC::StdAddressBook::self(), SIGNAL(addressBookChanged(AddressBook*)), SLOT(slotAbChanged(AddressBook*)));
+ connect(KABC::StdAddressBook::self(), TQT_SIGNAL(addressBookChanged(AddressBook*)), TQT_SLOT(slotAbChanged(AddressBook*)));
}
FaxAB::~FaxAB()
@@ -86,7 +86,7 @@ void FaxAB::initialize()
{
KABC::PhoneNumber::List numbers = (*it).phoneNumbers();
KABC::PhoneNumber::List faxNumbers;
- for (QValueList<KABC::PhoneNumber>::Iterator nit=numbers.begin(); nit!=numbers.end(); ++nit)
+ for (TQValueList<KABC::PhoneNumber>::Iterator nit=numbers.begin(); nit!=numbers.end(); ++nit)
{
if (((*nit).type() & KABC::PhoneNumber::Fax) && !(*nit).number().isEmpty())
faxNumbers << ( *nit );
@@ -102,7 +102,7 @@ void FaxAB::initialize()
entry.m_name = ( *it ).formattedName();
else
{
- QString key = ( *it ).familyName();
+ TQString key = ( *it ).familyName();
if ( !( *it ).givenName().isEmpty() )
{
if ( !key.isEmpty() )
@@ -119,9 +119,9 @@ void FaxAB::initialize()
if (m_entries.count() > 0)
{
- for (QMap<QString,FaxABEntry>::ConstIterator it=m_entries.begin(); it!=m_entries.end(); ++it)
+ for (TQMap<TQString,FaxABEntry>::ConstIterator it=m_entries.begin(); it!=m_entries.end(); ++it)
{
- QCheckListItem *item = new QCheckListItem( m_list, it.key(), QCheckListItem::CheckBox );
+ TQCheckListItem *item = new TQCheckListItem( m_list, it.key(), TQCheckListItem::CheckBox );
item->setText( 1, ( *it ).m_number.number() );
item->setText( 2, ( *it ).m_enterprise );
}
@@ -142,7 +142,7 @@ void FaxAB::slotAbChanged(AddressBook*)
initialize();
}
-bool FaxAB::getEntry(QStringList& number, QStringList& name, QStringList& enterprise, QWidget *parent)
+bool FaxAB::getEntry(TQStringList& number, TQStringList& name, TQStringList& enterprise, TQWidget *parent)
{
FaxAB kab(parent);
if (!kab.isValid())
@@ -152,7 +152,7 @@ bool FaxAB::getEntry(QStringList& number, QStringList& name, QStringList& enterp
}
if (kab.exec())
{
- QListViewItemIterator it( kab.m_list, QListViewItemIterator::Checked );
+ TQListViewItemIterator it( kab.m_list, TQListViewItemIterator::Checked );
while ( it.current() )
{
number << it.current()->text( 1 );
@@ -174,18 +174,18 @@ bool FaxAB::getEntry(QStringList& number, QStringList& name, QStringList& enterp
return false;
}
-bool FaxAB::getEntryByNumber(const QString& number, QString& name, QString& enterprise)
+bool FaxAB::getEntryByNumber(const TQString& number, TQString& name, TQString& enterprise)
{
KABC::AddressBook *bk = KABC::StdAddressBook::self();
for (KABC::AddressBook::Iterator it=bk->begin(); it!=bk->end(); ++it)
{
KABC::PhoneNumber::List numbers = (*it).phoneNumbers();
QStringList filteredNumbers;
- for (QValueList<KABC::PhoneNumber>::Iterator nit=numbers.begin(); nit!=numbers.end(); ++nit)
+ for (TQValueList<KABC::PhoneNumber>::Iterator nit=numbers.begin(); nit!=numbers.end(); ++nit)
{
if (((*nit).type() & KABC::PhoneNumber::Fax) )
{
- QString strippedNumber;
+ TQString strippedNumber;
for (uint i = 0; i < (*nit).number().length(); ++i)
if ((*nit).number()[i].isDigit() || ( *nit ).number()[ i ] == '+')
strippedNumber.append((*nit).number()[i]);
diff --git a/kdeprint/kdeprintfax/faxab.h b/kdeprint/kdeprintfax/faxab.h
index c72662055..03c5532fe 100644
--- a/kdeprint/kdeprintfax/faxab.h
+++ b/kdeprint/kdeprintfax/faxab.h
@@ -22,8 +22,8 @@
#define FAXAB_H
#include <kdialog.h>
-#include <qmap.h>
-#include <qstringlist.h>
+#include <tqmap.h>
+#include <tqstringlist.h>
#include <kabc/phonenumber.h>
class KListView;
@@ -34,12 +34,12 @@ class FaxAB : public KDialog
{
Q_OBJECT
public:
- FaxAB(QWidget *parent = 0, const char *name = 0);
+ FaxAB(TQWidget *parent = 0, const char *name = 0);
~FaxAB();
bool isValid();
- static bool getEntry(QStringList& number, QStringList& name, QStringList& enterprise, QWidget *parent = 0);
- static bool getEntryByNumber(const QString& number, QString& name, QString& enterprise);
+ static bool getEntry(TQStringList& number, TQStringList& name, TQStringList& enterprise, TQWidget *parent = 0);
+ static bool getEntryByNumber(const TQString& number, TQString& name, TQString& enterprise);
protected slots:
void slotEditAb();
@@ -51,14 +51,14 @@ protected:
private:
struct FaxABEntry
{
- QString m_name;
+ TQString m_name;
KABC::PhoneNumber m_number;
- QString m_enterprise;
+ TQString m_enterprise;
};
KListView* m_list;
- QMap<QString,FaxABEntry> m_entries;
- QPushButton* m_ok;
+ TQMap<TQString,FaxABEntry> m_entries;
+ TQPushButton* m_ok;
};
#endif
diff --git a/kdeprint/kdeprintfax/faxctrl.cpp b/kdeprint/kdeprintfax/faxctrl.cpp
index 4cb5f3bc7..bbd8fce59 100644
--- a/kdeprint/kdeprintfax/faxctrl.cpp
+++ b/kdeprint/kdeprintfax/faxctrl.cpp
@@ -23,17 +23,17 @@
#include "defcmds.h"
#include <ktextedit.h>
-#include <qfile.h>
-#include <qtextstream.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
#include <kpushbutton.h>
-#include <qlayout.h>
-#include <qregexp.h>
+#include <tqlayout.h>
+#include <tqregexp.h>
#include <kprinter.h>
-#include <qsimplerichtext.h>
-#include <qpainter.h>
-#include <qpaintdevicemetrics.h>
-#include <qvaluestack.h>
-#include <qstylesheet.h>
+#include <tqsimplerichtext.h>
+#include <tqpainter.h>
+#include <tqpaintdevicemetrics.h>
+#include <tqvaluestack.h>
+#include <tqstylesheet.h>
#include <kprocess.h>
#include <kglobal.h>
@@ -57,51 +57,51 @@
/** \brief Return a string for the page size.
*
- * @param size the page size, which is actually of type @c QPrinter::PageSize
+ * @param size the page size, which is actually of type @c TQPrinter::PageSize
* @return a pointer to a static string for the name of the page size.
*/
char const* pageSizeText(int size)
{
switch(size)
{
- case QPrinter::A4: return "a4";
- case QPrinter::Legal: return "legal";
- case QPrinter::Letter: return "letter";
+ case TQPrinter::A4: return "a4";
+ case TQPrinter::Legal: return "legal";
+ case TQPrinter::Letter: return "letter";
default: return "letter";
}
}
/** \brief Return the default page size.
*/
-static QString pageSize()
+static TQString pageSize()
{
KConfig *conf = KGlobal::config();
conf->setGroup("Fax");
return conf->readEntry("Page", pageSizeText(KGlobal::locale()->pageSize()));
}
-static QString stripNumber( const QString& s )
+static TQString stripNumber( const TQString& s )
{
KConfig *conf = KGlobal::config();
conf->setGroup( "Personal" );
// removes any non-numeric character, except ('+','*','#') (hope it's supported by faxing tools)
- QString strip_s = s;
- strip_s.replace( QRegExp( "[^\\d+*#]" ), "" );
+ TQString strip_s = s;
+ strip_s.replace( TQRegExp( "[^\\d+*#]" ), "" );
if ( strip_s.find( '+' ) != -1 && conf->readBoolEntry( "ReplaceIntChar", false ) )
strip_s.replace( "+", conf->readEntry( "ReplaceIntCharVal" ) );
return strip_s;
}
-static QString tagList( int n, ... )
+static TQString tagList( int n, ... )
{
- QString t;
+ TQString t;
va_list ap;
va_start( ap, n );
for ( int i=0; i<n; i++ )
{
- QString tag = va_arg( ap, const char* );
+ TQString tag = va_arg( ap, const char* );
tag.append( "(_(\\w|\\{[^\\}]*\\}))?" );
if ( t.isEmpty() )
t = tag;
@@ -130,9 +130,9 @@ static QString tagList( int n, ... )
* @param value the Boolean value to control the processing
* @return the new value of the tag
*/
-static QString processTag( const QString& match, bool value)
+static TQString processTag( const TQString& match, bool value)
{
- QString v;
+ TQString v;
int p = match.find( '_' );
if ( p != -1 && match[ p+1 ] == '{' )
{
@@ -159,9 +159,9 @@ static QString processTag( const QString& match, bool value)
return v;
}
-static QString processTag( const QString& match, const QString& value )
+static TQString processTag( const TQString& match, const TQString& value )
{
- QString v;
+ TQString v;
int p = match.find( '_' );
if ( p != -1 )
{
@@ -183,25 +183,25 @@ static QString processTag( const QString& match, const QString& value )
return v;
}
-static bool isTag( const QString& m, const QString& t )
+static bool isTag( const TQString& m, const TQString& t )
{
return ( m == t || m.startsWith( t+"_" ) );
}
-static QString replaceTags( const QString& s, const QString& tags, KdeprintFax *fax = NULL, const KdeprintFax::FaxItem& item = KdeprintFax::FaxItem() )
+static TQString replaceTags( const TQString& s, const TQString& tags, KdeprintFax *fax = NULL, const KdeprintFax::FaxItem& item = KdeprintFax::FaxItem() )
{
// unquote variables (they will be replaced with quoted values later)
- QValueStack<bool> stack;
+ TQValueStack<bool> stack;
KConfig *conf = KGlobal::config();
- QString cmd = s;
+ TQString cmd = s;
bool issinglequote=false;
bool isdoublequote=false;
- QRegExp re_noquote("(\\$\\(|\\)|\\(|\"|'|\\\\|`|"+tags+")");
- QRegExp re_singlequote("('|"+tags+")");
- QRegExp re_doublequote("(\\$\\(|\"|\\\\|`|"+tags+")");
+ TQRegExp re_noquote("(\\$\\(|\\)|\\(|\"|'|\\\\|`|"+tags+")");
+ TQRegExp re_singlequote("('|"+tags+")");
+ TQRegExp re_doublequote("(\\$\\(|\"|\\\\|`|"+tags+")");
for ( int i = re_noquote.search(cmd);
i != -1;
i = (issinglequote?re_singlequote.search(cmd,i)
@@ -245,7 +245,7 @@ static QString replaceTags( const QString& s, const QString& tags, KdeprintFax *
{
// Replace all `...` with safer $(...)
cmd.replace (i, 1, "$(");
- QRegExp re_backticks("(`|\\\\`|\\\\\\\\|\\\\\\$)");
+ TQRegExp re_backticks("(`|\\\\`|\\\\\\\\|\\\\\\$)");
for ( int i2=re_backticks.search(cmd,i+2);
i2!=-1;
i2=re_backticks.search(cmd,i2)
@@ -266,7 +266,7 @@ static QString replaceTags( const QString& s, const QString& tags, KdeprintFax *
}
else
{
- QString match, v;
+ TQString match, v;
// get match
if (issinglequote)
@@ -291,7 +291,7 @@ static QString replaceTags( const QString& s, const QString& tags, KdeprintFax *
if (v.isEmpty())
v = getenv("FAXSERVER");
if (v.isEmpty())
- v = QString::fromLatin1("localhost");
+ v = TQString::fromLatin1("localhost");
v = processTag( match, v );
}
else if (isTag( match, "%page" ))
@@ -351,15 +351,15 @@ static QString replaceTags( const QString& s, const QString& tags, KdeprintFax *
return cmd;
}
-FaxCtrl::FaxCtrl(QWidget *parent, const char *name)
-: QObject(parent, name)
+FaxCtrl::FaxCtrl(TQWidget *parent, const char *name)
+: TQObject(parent, name)
{
m_process = new KProcess();
m_process->setUseShell(true);
- connect(m_process, SIGNAL(receivedStdout(KProcess*,char*,int)), SLOT(slotReceivedStdout(KProcess*,char*,int)));
- connect(m_process, SIGNAL(receivedStderr(KProcess*,char*,int)), SLOT(slotReceivedStdout(KProcess*,char*,int)));
- connect(m_process, SIGNAL(processExited(KProcess*)), SLOT(slotProcessExited(KProcess*)));
- connect(this, SIGNAL(faxSent(bool)), SLOT(cleanTempFiles()));
+ connect(m_process, TQT_SIGNAL(receivedStdout(KProcess*,char*,int)), TQT_SLOT(slotReceivedStdout(KProcess*,char*,int)));
+ connect(m_process, TQT_SIGNAL(receivedStderr(KProcess*,char*,int)), TQT_SLOT(slotReceivedStdout(KProcess*,char*,int)));
+ connect(m_process, TQT_SIGNAL(processExited(KProcess*)), TQT_SLOT(slotProcessExited(KProcess*)));
+ connect(this, TQT_SIGNAL(faxSent(bool)), TQT_SLOT(cleanTempFiles()));
m_logview = 0;
}
@@ -378,7 +378,7 @@ bool FaxCtrl::send(KdeprintFax *f)
// replace tags common to all fax "operations"
m_command = replaceTags( m_command, tagList( 11, "%dev", "%server", "%page", "%res", "%user", "%from", "%email", "%comment", "%time", "%subject", "%cover" ), f );
- m_log = QString::null;
+ m_log = TQString::null;
m_filteredfiles.clear();
cleanTempFiles();
m_files = f->files();
@@ -394,7 +394,7 @@ void FaxCtrl::slotReceivedStdout(KProcess*, char *buffer, int len)
{
QCString str(buffer, len);
kdDebug() << "Received stdout: " << str << endl;
- addLog(QString(str));
+ addLog(TQString(str));
}
void FaxCtrl::slotProcessExited(KProcess*)
@@ -424,18 +424,18 @@ void FaxCtrl::slotProcessExited(KProcess*)
}
}
-QString FaxCtrl::faxCommand()
+TQString FaxCtrl::faxCommand()
{
KConfig *conf = KGlobal::config();
conf->setGroup("System");
QString sys = conf->readPathEntry("System", "efax");
- QString cmd;
+ TQString cmd;
if (sys == "hylafax")
cmd = conf->readPathEntry("HylaFax", hylafax_default_cmd);
else if (sys == "mgetty")
cmd = conf->readPathEntry("Mgetty", mgetty_default_cmd);
else if ( sys == "other" )
- cmd = conf->readPathEntry( "Other", QString::null );
+ cmd = conf->readPathEntry( "Other", TQString::null );
else
cmd = conf->readPathEntry("EFax", efax_default_cmd);
if (cmd.startsWith("%exe_"))
@@ -449,7 +449,7 @@ void FaxCtrl::sendFax()
{
// replace %files tag
QString filestr;
- for (QStringList::ConstIterator it=m_filteredfiles.begin(); it!=m_filteredfiles.end(); ++it)
+ for (TQStringList::ConstIterator it=m_filteredfiles.begin(); it!=m_filteredfiles.end(); ++it)
filestr += (quote(*it)+" ");
m_command.replace("%files", filestr);
}
@@ -461,7 +461,7 @@ void FaxCtrl::sendFax()
addLogTitle( i18n( "Sending fax to %1 (%2)" ).arg( item.number ).arg( item.name ) );
- QString cmd = replaceTags( m_command, tagList( 4, "%number", "%name", "%enterprise", "%rawnumber" ), NULL, item );
+ TQString cmd = replaceTags( m_command, tagList( 4, "%number", "%name", "%enterprise", "%rawnumber" ), NULL, item );
m_process->clearArguments();
*m_process << cmd;
addLog(i18n("Sending to fax using: %1").arg(cmd));
@@ -491,7 +491,7 @@ void FaxCtrl::filter()
m_tempfiles.append(tmp);
m_process->clearArguments();
*m_process << locate("data","kdeprintfax/anytops") << "-m" << KProcess::quote(locate("data","kdeprintfax/faxfilters"))
- << QString::fromLatin1("--mime=%1").arg(mimeType)
+ << TQString::fromLatin1("--mime=%1").arg(mimeType)
<< "-p" << pageSize()
<< KProcess::quote(m_files[0]) << KProcess::quote(tmp);
if (!m_process->start(KProcess::NotifyOnExit, KProcess::AllOutput))
@@ -514,31 +514,31 @@ bool FaxCtrl::abort()
return false;
}
-void FaxCtrl::viewLog(QWidget *)
+void FaxCtrl::viewLog(TQWidget *)
{
if (!m_logview)
{
- QWidget *topView = new QWidget(0, "LogView", WType_TopLevel|WStyle_DialogBorder|WDestructiveClose);
+ QWidget *topView = new TQWidget(0, "LogView", WType_TopLevel|WStyle_DialogBorder|WDestructiveClose);
m_logview = new KTextEdit(topView);
m_logview->setTextFormat( Qt::LogText );
- m_logview->setWordWrap( QTextEdit::WidgetWidth );
+ m_logview->setWordWrap( TQTextEdit::WidgetWidth );
m_logview->setPaper( Qt::white );
//m_logview->setReadOnly(true);
- //m_logview->setWordWrap(QTextEdit::NoWrap);
+ //m_logview->setWordWrap(TQTextEdit::NoWrap);
QPushButton *m_clear = new KPushButton(KStdGuiItem::clear(), topView);
QPushButton *m_close = new KPushButton(KStdGuiItem::close(), topView);
- QPushButton *m_print = new KPushButton( KStdGuiItem::print(), topView );
- QPushButton *m_save = new KPushButton( KStdGuiItem::saveAs(), topView );
+ TQPushButton *m_print = new KPushButton( KStdGuiItem::print(), topView );
+ TQPushButton *m_save = new KPushButton( KStdGuiItem::saveAs(), topView );
m_close->setDefault(true);
- connect(m_clear, SIGNAL(clicked()), SLOT(slotClearLog()));
- connect(m_close, SIGNAL(clicked()), SLOT(slotCloseLog()));
- connect(m_logview, SIGNAL(destroyed()), SLOT(slotCloseLog()));
- connect( m_print, SIGNAL( clicked() ), SLOT( slotPrintLog() ) );
- connect( m_save, SIGNAL( clicked() ), SLOT( slotSaveLog() ) );
+ connect(m_clear, TQT_SIGNAL(clicked()), TQT_SLOT(slotClearLog()));
+ connect(m_close, TQT_SIGNAL(clicked()), TQT_SLOT(slotCloseLog()));
+ connect(m_logview, TQT_SIGNAL(destroyed()), TQT_SLOT(slotCloseLog()));
+ connect( m_print, TQT_SIGNAL( clicked() ), TQT_SLOT( slotPrintLog() ) );
+ connect( m_save, TQT_SIGNAL( clicked() ), TQT_SLOT( slotSaveLog() ) );
- QVBoxLayout *l0 = new QVBoxLayout(topView, 10, 10);
+ QVBoxLayout *l0 = new TQVBoxLayout(topView, 10, 10);
l0->addWidget(m_logview);
- QHBoxLayout *l1 = new QHBoxLayout(0, 0, 10);
+ QHBoxLayout *l1 = new TQHBoxLayout(0, 0, 10);
l0->addLayout(l1);
l1->addStretch(1);
l1->addWidget( m_save );
@@ -557,16 +557,16 @@ void FaxCtrl::viewLog(QWidget *)
}
}
-void FaxCtrl::addLogTitle( const QString& s )
+void FaxCtrl::addLogTitle( const TQString& s )
{
- QString t( s );
+ TQString t( s );
t.prepend( '\n' ).append( '\n' );
addLog( t, true );
}
-void FaxCtrl::addLog(const QString& s, bool isTitle)
+void FaxCtrl::addLog(const TQString& s, bool isTitle)
{
- QString t = QStyleSheet::escape(s);
+ TQString t = TQStyleSheet::escape(s);
if ( isTitle )
t.prepend( "<font color=red><b>" ).append( "</b></font>" );
m_log.append( t + '\n' );
@@ -574,7 +574,7 @@ void FaxCtrl::addLog(const QString& s, bool isTitle)
m_logview->append(t);
}
-QString FaxCtrl::faxSystem()
+TQString FaxCtrl::faxSystem()
{
KConfig *conf = KGlobal::config();
conf->setGroup("System");
@@ -585,14 +585,14 @@ QString FaxCtrl::faxSystem()
void FaxCtrl::cleanTempFiles()
{
- for (QStringList::ConstIterator it=m_tempfiles.begin(); it!=m_tempfiles.end(); ++it)
- QFile::remove(*it);
+ for (TQStringList::ConstIterator it=m_tempfiles.begin(); it!=m_tempfiles.end(); ++it)
+ TQFile::remove(*it);
m_tempfiles.clear();
}
void FaxCtrl::slotClearLog()
{
- m_log = QString::null;
+ m_log = TQString::null;
if (m_logview)
m_logview->clear();
}
@@ -604,7 +604,7 @@ void FaxCtrl::slotCloseLog()
{
QTextEdit *view = m_logview;
m_logview = 0;
- if (obj && obj->inherits("QPushButton"))
+ if (obj && obj->inherits("TQPushButton"))
delete view->parentWidget();
kdDebug() << "slotClose()" << endl;
}
@@ -619,17 +619,17 @@ void FaxCtrl::slotPrintLog()
printer.setDocFileName( "faxlog" );
if ( printer.setup( m_logview->topLevelWidget(), i18n( "Fax Log" ) ) )
{
- QPainter painter( &printer );
- QPaintDeviceMetrics metric( &printer );
- QRect body( 0, 0, metric.width(), metric.height() ), view( body );
- //QString txt = m_logview->text();
- QString txt = m_log;
+ TQPainter painter( &printer );
+ TQPaintDeviceMetrics metric( &printer );
+ TQRect body( 0, 0, metric.width(), metric.height() ), view( body );
+ //TQString txt = m_logview->text();
+ TQString txt = m_log;
txt.replace( '\n', "<br>" );
txt.prepend( "<h2>" + i18n( "KDEPrint Fax Tool Log" ) + "</h2>" );
kdDebug() << "Log: " << txt << endl;
- QSimpleRichText richText( txt, m_logview->font() );
+ TQSimpleRichText richText( txt, m_logview->font() );
richText.setWidth( &painter, body.width() );
do
@@ -649,13 +649,13 @@ void FaxCtrl::slotSaveLog()
{
if ( m_logview )
{
- QString filename = KFileDialog::getSaveFileName( QString::null, QString::null, m_logview );
+ TQString filename = KFileDialog::getSaveFileName( TQString::null, TQString::null, m_logview );
if ( !filename.isEmpty() )
{
- QFile f( filename );
+ TQFile f( filename );
if ( f.open( IO_WriteOnly ) )
{
- QTextStream t( &f );
+ TQTextStream t( &f );
t << i18n( "KDEPrint Fax Tool Log" ) << endl;
t << m_logview->text() << endl;
f.close();
diff --git a/kdeprint/kdeprintfax/faxctrl.h b/kdeprint/kdeprintfax/faxctrl.h
index d3d8086a9..0b8ed1de0 100644
--- a/kdeprint/kdeprintfax/faxctrl.h
+++ b/kdeprint/kdeprintfax/faxctrl.h
@@ -21,9 +21,9 @@
#ifndef FAXCTRL_H
#define FAXCTRL_H
-#include <qobject.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include "kdeprintfax.h"
@@ -34,17 +34,17 @@ class FaxCtrl : public QObject
{
Q_OBJECT
public:
- FaxCtrl(QWidget *parent = 0, const char *name = 0);
+ FaxCtrl(TQWidget *parent = 0, const char *name = 0);
~FaxCtrl();
bool send(KdeprintFax *f);
bool abort();
- void viewLog(QWidget *parent = 0);
- QString faxSystem();
- QString faxCommand();
+ void viewLog(TQWidget *parent = 0);
+ TQString faxSystem();
+ TQString faxCommand();
signals:
- void message(const QString&);
+ void message(const TQString&);
void faxSent(bool);
protected slots:
@@ -59,8 +59,8 @@ protected slots:
protected:
void filter();
void sendFax();
- void addLog(const QString&, bool = false);
- void addLogTitle( const QString& );
+ void addLog(const TQString&, bool = false);
+ void addLogTitle( const TQString& );
private:
KProcess *m_process;
diff --git a/kdeprint/kdeprintfax/filterdlg.cpp b/kdeprint/kdeprintfax/filterdlg.cpp
index 563c37a7d..ea9a88ce9 100644
--- a/kdeprint/kdeprintfax/filterdlg.cpp
+++ b/kdeprint/kdeprintfax/filterdlg.cpp
@@ -21,23 +21,23 @@
#include "filterdlg.h"
#include "filterdlg.moc"
-#include <qlineedit.h>
-#include <qlabel.h>
-#include <qlayout.h>
+#include <tqlineedit.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
#include <klocale.h>
-FilterDlg::FilterDlg(QWidget *parent, const char *name)
+FilterDlg::FilterDlg(TQWidget *parent, const char *name)
: KDialogBase(parent, name, true, i18n("Filter Parameters"), Ok|Cancel, Ok)
{
- QWidget *w = new QWidget(this);
+ QWidget *w = new TQWidget(this);
- m_mime = new QLineEdit(w);
- m_cmd = new QLineEdit(w);
- QLabel *m_mimelabel = new QLabel(i18n("MIME type:"), w);
- QLabel *m_cmdlabel = new QLabel(i18n("Command:"), w);
+ m_mime = new TQLineEdit(w);
+ m_cmd = new TQLineEdit(w);
+ QLabel *m_mimelabel = new TQLabel(i18n("MIME type:"), w);
+ QLabel *m_cmdlabel = new TQLabel(i18n("Command:"), w);
- QGridLayout *l0 = new QGridLayout(w, 2, 2, 10, 5);
+ QGridLayout *l0 = new TQGridLayout(w, 2, 2, 10, 5);
l0->setColStretch(1, 1);
l0->addWidget(m_mimelabel, 0, 0);
l0->addWidget(m_cmdlabel, 1, 0);
@@ -47,8 +47,8 @@ FilterDlg::FilterDlg(QWidget *parent, const char *name)
setMainWidget(w);
m_mime->setFocus();
resize(300, 100);
- connect(m_mime, SIGNAL(textChanged ( const QString & )),this, SLOT(slotTextFilterChanged()));
- connect(m_cmd, SIGNAL(textChanged ( const QString & )),this, SLOT(slotTextFilterChanged()));
+ connect(m_mime, TQT_SIGNAL(textChanged ( const TQString & )),this, TQT_SLOT(slotTextFilterChanged()));
+ connect(m_cmd, TQT_SIGNAL(textChanged ( const TQString & )),this, TQT_SLOT(slotTextFilterChanged()));
slotTextFilterChanged();
}
@@ -57,7 +57,7 @@ void FilterDlg::slotTextFilterChanged( )
enableButtonOK(!m_mime->text().isEmpty() && !m_cmd->text().isEmpty());
}
-bool FilterDlg::doIt(QWidget *parent, QString *mime, QString *cmd)
+bool FilterDlg::doIt(TQWidget *parent, TQString *mime, TQString *cmd)
{
FilterDlg dlg(parent);
if (mime) dlg.m_mime->setText(*mime);
diff --git a/kdeprint/kdeprintfax/filterdlg.h b/kdeprint/kdeprintfax/filterdlg.h
index f1010a2c6..e080393ae 100644
--- a/kdeprint/kdeprintfax/filterdlg.h
+++ b/kdeprint/kdeprintfax/filterdlg.h
@@ -29,9 +29,9 @@ class FilterDlg : public KDialogBase
{
Q_OBJECT
public:
- FilterDlg(QWidget *parent = 0, const char *name = 0);
+ FilterDlg(TQWidget *parent = 0, const char *name = 0);
- static bool doIt(QWidget *parent = 0, QString* mime = 0, QString *cmd = 0);
+ static bool doIt(TQWidget *parent = 0, TQString* mime = 0, TQString *cmd = 0);
protected slots:
void slotTextFilterChanged();
private:
diff --git a/kdeprint/kdeprintfax/kdeprintfax.cpp b/kdeprint/kdeprintfax/kdeprintfax.cpp
index e10416bef..a5f66992b 100644
--- a/kdeprint/kdeprintfax/kdeprintfax.cpp
+++ b/kdeprint/kdeprintfax/kdeprintfax.cpp
@@ -23,15 +23,15 @@
#include "faxctrl.h"
#include "configdlg.h"
-#include <qcheckbox.h>
-#include <qlineedit.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qpushbutton.h>
-#include <qtextedit.h>
-#include <qdatetimeedit.h>
-#include <qcombobox.h>
-#include <qtooltip.h>
+#include <tqcheckbox.h>
+#include <tqlineedit.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqpushbutton.h>
+#include <tqtextedit.h>
+#include <tqdatetimeedit.h>
+#include <tqcombobox.h>
+#include <tqtooltip.h>
#include <kapplication.h>
#include <kstdaction.h>
@@ -40,7 +40,7 @@
#include <kaction.h>
#include <klistbox.h>
#include <klistview.h>
-#include <qheader.h>
+#include <tqheader.h>
#include <klocale.h>
#include <kiconloader.h>
#include <kio/netaccess.h>
@@ -57,29 +57,29 @@
#include <kurldrag.h>
#include <kdebug.h>
-KdeprintFax::KdeprintFax(QWidget *parent, const char *name)
+KdeprintFax::KdeprintFax(TQWidget *parent, const char *name)
: KMainWindow(parent, name)
{
m_faxctrl = new FaxCtrl(this);
m_quitAfterSend = false;
- connect(m_faxctrl, SIGNAL(message(const QString&)), SLOT(slotMessage(const QString&)));
- connect(m_faxctrl, SIGNAL(faxSent(bool)), SLOT(slotFaxSent(bool)));
+ connect(m_faxctrl, TQT_SIGNAL(message(const TQString&)), TQT_SLOT(slotMessage(const TQString&)));
+ connect(m_faxctrl, TQT_SIGNAL(faxSent(bool)), TQT_SLOT(slotFaxSent(bool)));
- QWidget *mainw = new QWidget(this);
+ QWidget *mainw = new TQWidget(this);
setCentralWidget(mainw);
m_files = new KListBox(mainw);
- connect( m_files, SIGNAL( currentChanged( QListBoxItem* ) ), SLOT( slotCurrentChanged() ) );
+ connect( m_files, TQT_SIGNAL( currentChanged( TQListBoxItem* ) ), TQT_SLOT( slotCurrentChanged() ) );
m_upbtn = new KPushButton( mainw );
m_upbtn->setIconSet( SmallIconSet( "up" ) );
- QToolTip::add( m_upbtn, i18n( "Move up" ) );
- connect( m_upbtn, SIGNAL( clicked() ), SLOT( slotMoveUp() ) );
+ TQToolTip::add( m_upbtn, i18n( "Move up" ) );
+ connect( m_upbtn, TQT_SIGNAL( clicked() ), TQT_SLOT( slotMoveUp() ) );
m_upbtn->setEnabled( false );
m_downbtn = new KPushButton( mainw );
m_downbtn->setIconSet( SmallIconSet( "down" ) );
- QToolTip::add( m_downbtn, i18n( "Move down" ) );
- connect( m_downbtn, SIGNAL( clicked() ), SLOT( slotMoveDown() ) );
+ TQToolTip::add( m_downbtn, i18n( "Move down" ) );
+ connect( m_downbtn, TQT_SIGNAL( clicked() ), TQT_SLOT( slotMoveDown() ) );
m_downbtn->setEnabled( false );
- QLabel *m_filelabel = new QLabel(i18n("F&iles:"), mainw);
+ QLabel *m_filelabel = new TQLabel(i18n("F&iles:"), mainw);
m_filelabel->setBuddy(m_files);
KSeparator*m_line = new KSeparator( KSeparator::HLine, mainw);
KSeparator *m_line2 = new KSeparator( KSeparator::HLine, mainw );
@@ -88,54 +88,54 @@ KdeprintFax::KdeprintFax(QWidget *parent, const char *name)
m_numbers->addColumn( i18n("Name") );
m_numbers->addColumn( i18n("Enterprise") );
m_numbers->header()->setStretchEnabled( true );
- m_numbers->setSelectionMode( QListView::Extended );
- connect( m_numbers, SIGNAL( selectionChanged() ), SLOT( slotFaxSelectionChanged() ) );
- connect( m_numbers, SIGNAL( executed( QListViewItem* ) ), SLOT( slotFaxExecuted( QListViewItem* ) ) );
+ m_numbers->setSelectionMode( TQListView::Extended );
+ connect( m_numbers, TQT_SIGNAL( selectionChanged() ), TQT_SLOT( slotFaxSelectionChanged() ) );
+ connect( m_numbers, TQT_SIGNAL( executed( TQListViewItem* ) ), TQT_SLOT( slotFaxExecuted( TQListViewItem* ) ) );
m_newbtn = new KPushButton( mainw );
m_newbtn->setPixmap( SmallIcon( "edit" ) );
- QToolTip::add( m_newbtn, i18n( "Add fax number" ) );
- connect( m_newbtn, SIGNAL( clicked() ), SLOT( slotFaxAdd() ) );
+ TQToolTip::add( m_newbtn, i18n( "Add fax number" ) );
+ connect( m_newbtn, TQT_SIGNAL( clicked() ), TQT_SLOT( slotFaxAdd() ) );
m_abbtn = new KPushButton( mainw );
m_abbtn->setPixmap( SmallIcon( "kaddressbook" ) );
- QToolTip::add( m_abbtn, i18n( "Add fax number from addressbook" ) );
- connect( m_abbtn, SIGNAL( clicked() ), SLOT( slotKab() ) );
+ TQToolTip::add( m_abbtn, i18n( "Add fax number from addressbook" ) );
+ connect( m_abbtn, TQT_SIGNAL( clicked() ), TQT_SLOT( slotKab() ) );
m_delbtn = new KPushButton( mainw );
m_delbtn->setIconSet( SmallIconSet( "edittrash" ) );
- QToolTip::add( m_delbtn, i18n( "Remove fax number" ) );
+ TQToolTip::add( m_delbtn, i18n( "Remove fax number" ) );
m_delbtn->setEnabled( false );
- connect( m_delbtn, SIGNAL( clicked() ), SLOT( slotFaxRemove() ) );
- QLabel *m_commentlabel = new QLabel(i18n("&Comment:"), mainw);
+ connect( m_delbtn, TQT_SIGNAL( clicked() ), TQT_SLOT( slotFaxRemove() ) );
+ QLabel *m_commentlabel = new TQLabel(i18n("&Comment:"), mainw);
KSystemTray *m_tray = new KSystemTray(this);
m_tray->setPixmap(SmallIcon("kdeprintfax"));
m_tray->show();
- m_comment = new QTextEdit(mainw);
+ m_comment = new TQTextEdit(mainw);
// I don't understand why anyone would want to turn off word wrap. It makes
// the text hard to read and write. It provides no benefit. Therefore,
// I commented out the next line. [Ray Lischner]
-// m_comment->setWordWrap(QTextEdit::NoWrap);
+// m_comment->setWordWrap(TQTextEdit::NoWrap);
m_comment->setLineWidth(1);
m_commentlabel->setBuddy(m_comment);
- QLabel *m_timelabel = new QLabel(i18n("Sched&ule:"), mainw);
- m_timecombo = new QComboBox(mainw);
+ QLabel *m_timelabel = new TQLabel(i18n("Sched&ule:"), mainw);
+ m_timecombo = new TQComboBox(mainw);
m_timecombo->insertItem(i18n("Now"));
m_timecombo->insertItem(i18n("At Specified Time"));
m_timecombo->setCurrentItem(0);
m_timelabel->setBuddy(m_timecombo);
m_time = new QTimeEdit(mainw);
- m_time->setTime(QTime::currentTime());
+ m_time->setTime(TQTime::currentTime());
m_time->setEnabled(false);
- connect(m_timecombo, SIGNAL(activated(int)), SLOT(slotTimeComboActivated(int)));
- m_cover = new QCheckBox(i18n("Send Co&ver Sheet"), mainw);
- connect(m_cover, SIGNAL(toggled(bool)), SLOT(slotCoverToggled(bool)));
- m_subject = new QLineEdit( mainw );
- QLabel *m_subjectlabel = new QLabel( i18n( "Su&bject:" ), mainw );
+ connect(m_timecombo, TQT_SIGNAL(activated(int)), TQT_SLOT(slotTimeComboActivated(int)));
+ m_cover = new TQCheckBox(i18n("Send Co&ver Sheet"), mainw);
+ connect(m_cover, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotCoverToggled(bool)));
+ m_subject = new TQLineEdit( mainw );
+ TQLabel *m_subjectlabel = new TQLabel( i18n( "Su&bject:" ), mainw );
m_subjectlabel->setBuddy( m_subject );
- QGridLayout *l0 = new QGridLayout(mainw, 10, 2, 10, 5);
+ QGridLayout *l0 = new TQGridLayout(mainw, 10, 2, 10, 5);
l0->setColStretch(1,1);
l0->addWidget(m_filelabel, 0, 0, Qt::AlignLeft|Qt::AlignTop);
- QHBoxLayout *l2 = new QHBoxLayout( 0, 0, 10 );
- QVBoxLayout *l3 = new QVBoxLayout( 0, 0, 5 );
+ TQHBoxLayout *l2 = new TQHBoxLayout( 0, 0, 10 );
+ TQVBoxLayout *l3 = new TQVBoxLayout( 0, 0, 5 );
l0->addLayout( l2, 0, 1 );
l2->addWidget( m_files );
l2->addLayout( l3 );
@@ -145,8 +145,8 @@ KdeprintFax::KdeprintFax(QWidget *parent, const char *name)
l3->addStretch( 1 );
l0->addMultiCellWidget(m_line, 1, 1, 0, 1);
l0->addRowSpacing(1, 10);
- QHBoxLayout *l5 = new QHBoxLayout( 0, 0, 10 );
- QVBoxLayout *l6 = new QVBoxLayout( 0, 0, 5 );
+ TQHBoxLayout *l5 = new TQHBoxLayout( 0, 0, 10 );
+ TQVBoxLayout *l6 = new TQVBoxLayout( 0, 0, 5 );
l0->addMultiCellLayout( l5, 2, 4, 0, 1 );
l5->addWidget( m_numbers );
l5->addLayout( l6 );
@@ -162,7 +162,7 @@ KdeprintFax::KdeprintFax(QWidget *parent, const char *name)
l0->addWidget(m_commentlabel, 8, 0, Qt::AlignTop|Qt::AlignLeft);
l0->addWidget(m_comment, 8, 1);
l0->addWidget(m_timelabel, 9, 0);
- QHBoxLayout *l1 = new QHBoxLayout(0, 0, 5);
+ QHBoxLayout *l1 = new TQHBoxLayout(0, 0, 5);
l0->addLayout(l1, 9, 1);
l1->addWidget(m_timecombo, 1);
l1->addWidget(m_time, 0);
@@ -188,23 +188,23 @@ KdeprintFax::~KdeprintFax()
void KdeprintFax::initActions()
{
- new KAction(i18n("&Add File..."), "filenew", Qt::Key_Insert, this, SLOT(slotAdd()), actionCollection(), "file_add");
- new KAction(i18n("&Remove File"), "remove", Qt::Key_Delete, this, SLOT(slotRemove()), actionCollection(), "file_remove");
- new KAction(i18n("&Send Fax"), "connect_established", Qt::Key_Return, this, SLOT(slotFax()), actionCollection(), "fax_send");
- new KAction(i18n("A&bort"), "stop", Qt::Key_Escape, this, SLOT(slotAbort()), actionCollection(), "fax_stop");
- new KAction(i18n("A&ddress Book"), "kaddressbook", Qt::CTRL+Qt::Key_A, this, SLOT(slotKab()), actionCollection(), "fax_ab");
- new KAction(i18n("V&iew Log"), "contents", Qt::CTRL+Qt::Key_L, this, SLOT(slotViewLog()), actionCollection(), "fax_log");
- new KAction(i18n("Vi&ew File"), "filefind", Qt::CTRL+Qt::Key_O, this, SLOT(slotView()), actionCollection(), "file_view");
- new KAction( i18n( "&New Fax Recipient..." ), "edit", Qt::CTRL+Qt::Key_N, this, SLOT( slotFaxAdd() ), actionCollection(), "fax_add" );
+ new KAction(i18n("&Add File..."), "filenew", Qt::Key_Insert, this, TQT_SLOT(slotAdd()), actionCollection(), "file_add");
+ new KAction(i18n("&Remove File"), "remove", Qt::Key_Delete, this, TQT_SLOT(slotRemove()), actionCollection(), "file_remove");
+ new KAction(i18n("&Send Fax"), "connect_established", Qt::Key_Return, this, TQT_SLOT(slotFax()), actionCollection(), "fax_send");
+ new KAction(i18n("A&bort"), "stop", Qt::Key_Escape, this, TQT_SLOT(slotAbort()), actionCollection(), "fax_stop");
+ new KAction(i18n("A&ddress Book"), "kaddressbook", Qt::CTRL+Qt::Key_A, this, TQT_SLOT(slotKab()), actionCollection(), "fax_ab");
+ new KAction(i18n("V&iew Log"), "contents", Qt::CTRL+Qt::Key_L, this, TQT_SLOT(slotViewLog()), actionCollection(), "fax_log");
+ new KAction(i18n("Vi&ew File"), "filefind", Qt::CTRL+Qt::Key_O, this, TQT_SLOT(slotView()), actionCollection(), "file_view");
+ new KAction( i18n( "&New Fax Recipient..." ), "edit", Qt::CTRL+Qt::Key_N, this, TQT_SLOT( slotFaxAdd() ), actionCollection(), "fax_add" );
- KStdAction::quit(this, SLOT(slotQuit()), actionCollection());
+ KStdAction::quit(this, TQT_SLOT(slotQuit()), actionCollection());
setStandardToolBarMenuEnabled(true);
- KStdAction::showMenubar(this, SLOT(slotToggleMenuBar()), actionCollection());
- KStdAction::preferences(this, SLOT(slotConfigure()), actionCollection());
- KStdAction::keyBindings(guiFactory(), SLOT(configureShortcuts()),
+ KStdAction::showMenubar(this, TQT_SLOT(slotToggleMenuBar()), actionCollection());
+ KStdAction::preferences(this, TQT_SLOT(slotConfigure()), actionCollection());
+ KStdAction::keyBindings(guiFactory(), TQT_SLOT(configureShortcuts()),
actionCollection());
actionCollection()->action("fax_stop")->setEnabled(false);
- connect(actionCollection()->action("file_remove"), SIGNAL(enabled(bool)), actionCollection()->action("file_view"), SLOT(setEnabled(bool)));
+ connect(actionCollection()->action("file_remove"), TQT_SIGNAL(enabled(bool)), actionCollection()->action("file_view"), TQT_SLOT(setEnabled(bool)));
actionCollection()->action("file_remove")->setEnabled(false);
createGUI();
@@ -218,7 +218,7 @@ void KdeprintFax::slotToggleMenuBar()
void KdeprintFax::slotAdd()
{
- KURL url = KFileDialog::getOpenURL(QString::null, QString::null, this);
+ KURL url = KFileDialog::getOpenURL(TQString::null, TQString::null, this);
if (!url.isEmpty())
addURL(url);
}
@@ -267,7 +267,7 @@ void KdeprintFax::slotKab()
if (FaxAB::getEntry(number, name, enterprise, this))
{
for ( unsigned int i = 0; i<number.count(); i++ )
- new QListViewItem( m_numbers, number[ i ], name[ i ], enterprise[ i ] );
+ new TQListViewItem( m_numbers, number[ i ], name[ i ], enterprise[ i ] );
}
}
@@ -284,11 +284,11 @@ void KdeprintFax::addURL(KURL url)
KMessageBox::error(this, i18n("Unable to retrieve %1.").arg(url.prettyURL()));
}
-void KdeprintFax::setPhone(QString phone)
+void KdeprintFax::setPhone(TQString phone)
{
- QString name, enterprise;
+ TQString name, enterprise;
FaxAB::getEntryByNumber(phone, name, enterprise);
- new QListViewItem( m_numbers, phone, name, enterprise );
+ new TQListViewItem( m_numbers, phone, name, enterprise );
}
void KdeprintFax::sendFax( bool quitAfterSend )
@@ -297,12 +297,12 @@ void KdeprintFax::sendFax( bool quitAfterSend )
m_quitAfterSend = quitAfterSend;
}
-void KdeprintFax::dragEnterEvent(QDragEnterEvent *e)
+void KdeprintFax::dragEnterEvent(TQDragEnterEvent *e)
{
e->accept(KURLDrag::canDecode(e));
}
-void KdeprintFax::dropEvent(QDropEvent *e)
+void KdeprintFax::dropEvent(TQDropEvent *e)
{
KURL::List l;
if (KURLDrag::decode(e, l))
@@ -312,7 +312,7 @@ void KdeprintFax::dropEvent(QDropEvent *e)
}
}
-QStringList KdeprintFax::files()
+TQStringList KdeprintFax::files()
{
QStringList l;
for (uint i=0; i<m_files->count(); i++)
@@ -327,9 +327,9 @@ int KdeprintFax::faxCount() const
}
/*
-QListViewItem* KdeprintFax::faxItem( int i ) const
+TQListViewItem* KdeprintFax::faxItem( int i ) const
{
- QListViewItem *item = m_numbers->firstChild();
+ TQListViewItem *item = m_numbers->firstChild();
while ( i && item && item->nextSibling() )
{
item = item->nextSibling();
@@ -340,29 +340,29 @@ QListViewItem* KdeprintFax::faxItem( int i ) const
return item;
}
-QString KdeprintFax::number( int i ) const
+TQString KdeprintFax::number( int i ) const
{
- QListViewItem *item = faxItem( i );
- return ( item ? item->text( 0 ) : QString::null );
+ TQListViewItem *item = faxItem( i );
+ return ( item ? item->text( 0 ) : TQString::null );
}
-QString KdeprintFax::name( int i ) const
+TQString KdeprintFax::name( int i ) const
{
- QListViewItem *item = faxItem( i );
- return ( item ? item->text( 1 ) : QString::null );
+ TQListViewItem *item = faxItem( i );
+ return ( item ? item->text( 1 ) : TQString::null );
}
-QString KdeprintFax::enterprise( int i ) const
+TQString KdeprintFax::enterprise( int i ) const
{
- QListViewItem *item = faxItem( i );
- return ( item ? item->text( 2 ) : QString::null );
+ TQListViewItem *item = faxItem( i );
+ return ( item ? item->text( 2 ) : TQString::null );
}
*/
KdeprintFax::FaxItemList KdeprintFax::faxList() const
{
FaxItemList list;
- QListViewItemIterator it( m_numbers );
+ TQListViewItemIterator it( m_numbers );
while ( it.current() )
{
FaxItem item;
@@ -375,7 +375,7 @@ KdeprintFax::FaxItemList KdeprintFax::faxList() const
return list;
}
-QString KdeprintFax::comment() const
+TQString KdeprintFax::comment() const
{
return m_comment->text();
}
@@ -385,12 +385,12 @@ bool KdeprintFax::cover() const
return m_cover->isChecked();
}
-QString KdeprintFax::subject() const
+TQString KdeprintFax::subject() const
{
return m_subject->text();
}
-void KdeprintFax::slotMessage(const QString& msg)
+void KdeprintFax::slotMessage(const TQString& msg)
{
m_msglabel->setText(msg);
}
@@ -407,7 +407,7 @@ void KdeprintFax::slotFaxSent(bool status)
else {
if (!status)
KMessageBox::error(this, i18n("Fax error: see log message for more information."));
- slotMessage(QString::null);
+ slotMessage(TQString::null);
}
}
@@ -429,7 +429,7 @@ void KdeprintFax::updateState()
if ( !m_cover->isEnabled() )
m_cover->setChecked(false);
m_comment->setEnabled(cmd.find("%comment") != -1 && m_cover->isChecked());
- //m_comment->setPaper(m_comment->isEnabled() ? colorGroup().brush(QColorGroup::Base) : colorGroup().brush(QColorGroup::Background));
+ //m_comment->setPaper(m_comment->isEnabled() ? colorGroup().brush(TQColorGroup::Base) : colorGroup().brush(TQColorGroup::Background));
if (!m_comment->isEnabled())
{
m_comment->setText("");
@@ -465,10 +465,10 @@ void KdeprintFax::slotTimeComboActivated(int ID)
m_time->setEnabled(ID == 1);
}
-QString KdeprintFax::time() const
+TQString KdeprintFax::time() const
{
if (!m_time->isEnabled())
- return QString::null;
+ return TQString::null;
return m_time->time().toString("hh:mm");
}
@@ -477,7 +477,7 @@ void KdeprintFax::slotMoveUp()
int index = m_files->currentItem();
if ( index > 0 )
{
- QListBoxItem *item = m_files->item( index );
+ TQListBoxItem *item = m_files->item( index );
m_files->takeItem( item );
m_files->insertItem( item, index-1 );
m_files->setCurrentItem( index-1 );
@@ -489,7 +489,7 @@ void KdeprintFax::slotMoveDown()
int index = m_files->currentItem();
if ( index >= 0 && index < ( int )m_files->count()-1 )
{
- QListBoxItem *item = m_files->item( index );
+ TQListBoxItem *item = m_files->item( index );
m_files->takeItem( item );
m_files->insertItem( item, index+1 );
m_files->setCurrentItem( index+1 );
@@ -514,14 +514,14 @@ void KdeprintFax::slotCurrentChanged()
void KdeprintFax::slotFaxSelectionChanged()
{
- QListViewItemIterator it( m_numbers, QListViewItemIterator::Selected );
+ TQListViewItemIterator it( m_numbers, TQListViewItemIterator::Selected );
m_delbtn->setEnabled( it.current() != NULL );
}
void KdeprintFax::slotFaxRemove()
{
- QListViewItemIterator it( m_numbers, QListViewItemIterator::Selected );
- QPtrList<QListViewItem> items;
+ TQListViewItemIterator it( m_numbers, TQListViewItemIterator::Selected );
+ TQPtrList<TQListViewItem> items;
items.setAutoDelete( true );
while ( it.current() )
{
@@ -535,18 +535,18 @@ void KdeprintFax::slotFaxRemove()
void KdeprintFax::slotFaxAdd()
{
- QString number, name, enterprise;
+ TQString number, name, enterprise;
if ( manualFaxDialog( number, name, enterprise ) )
{
- new QListViewItem( m_numbers, number, name, enterprise );
+ new TQListViewItem( m_numbers, number, name, enterprise );
}
}
-void KdeprintFax::slotFaxExecuted( QListViewItem *item )
+void KdeprintFax::slotFaxExecuted( TQListViewItem *item )
{
if ( item )
{
- QString number = item->text( 0 ), name = item->text( 1 ), enterprise = item->text( 2 );
+ TQString number = item->text( 0 ), name = item->text( 1 ), enterprise = item->text( 2 );
if ( manualFaxDialog( number, name, enterprise ) )
{
item->setText( 0, number );
@@ -556,22 +556,22 @@ void KdeprintFax::slotFaxExecuted( QListViewItem *item )
}
}
-bool KdeprintFax::manualFaxDialog( QString& number, QString& name, QString& enterprise )
+bool KdeprintFax::manualFaxDialog( TQString& number, TQString& name, TQString& enterprise )
{
/* dialog construction */
KDialogBase dlg( this, "manualFaxDialog", true, i18n( "Fax Number" ), KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true );
- QWidget *mainw = new QWidget( &dlg );
- QLabel *lab0 = new QLabel( i18n( "Enter recipient fax properties." ), mainw );
- QLabel *lab1 = new QLabel( i18n( "&Number:" ), mainw );
- QLabel *lab2 = new QLabel( i18n( "N&ame:" ), mainw );
- QLabel *lab3 = new QLabel( i18n( "&Enterprise:" ), mainw );
- QLineEdit *edit_number = new QLineEdit( number, mainw );
- QLineEdit *edit_name = new QLineEdit( name, mainw );
- QLineEdit *edit_enterprise = new QLineEdit( enterprise, mainw );
+ TQWidget *mainw = new TQWidget( &dlg );
+ TQLabel *lab0 = new TQLabel( i18n( "Enter recipient fax properties." ), mainw );
+ TQLabel *lab1 = new TQLabel( i18n( "&Number:" ), mainw );
+ TQLabel *lab2 = new TQLabel( i18n( "N&ame:" ), mainw );
+ TQLabel *lab3 = new TQLabel( i18n( "&Enterprise:" ), mainw );
+ TQLineEdit *edit_number = new TQLineEdit( number, mainw );
+ TQLineEdit *edit_name = new TQLineEdit( name, mainw );
+ TQLineEdit *edit_enterprise = new TQLineEdit( enterprise, mainw );
lab1->setBuddy( edit_number );
lab2->setBuddy( edit_name );
lab3->setBuddy( edit_enterprise );
- QGridLayout *l0 = new QGridLayout( mainw, 5, 2, 0, 5 );
+ TQGridLayout *l0 = new TQGridLayout( mainw, 5, 2, 0, 5 );
l0->setColStretch( 1, 1 );
l0->addMultiCellWidget( lab0, 0, 0, 0, 1 );
l0->setRowSpacing( 1, 10 );
diff --git a/kdeprint/kdeprintfax/kdeprintfax.h b/kdeprint/kdeprintfax/kdeprintfax.h
index 795521e82..95f64d443 100644
--- a/kdeprint/kdeprintfax/kdeprintfax.h
+++ b/kdeprint/kdeprintfax/kdeprintfax.h
@@ -42,28 +42,28 @@ class KdeprintFax : public KMainWindow
public:
struct FaxItem
{
- QString number;
- QString name;
- QString enterprise;
+ TQString number;
+ TQString name;
+ TQString enterprise;
};
- typedef QValueList<FaxItem> FaxItemList;
- typedef QValueList<FaxItem>::ConstIterator FaxItemListIterator;
+ typedef TQValueList<FaxItem> FaxItemList;
+ typedef TQValueList<FaxItem>::ConstIterator FaxItemListIterator;
- KdeprintFax(QWidget *parent = 0, const char *name = 0);
+ KdeprintFax(TQWidget *parent = 0, const char *name = 0);
~KdeprintFax();
void addURL(KURL url);
- void setPhone(QString phone);
+ void setPhone(TQString phone);
void sendFax( bool quitAfterSend );
- QStringList files();
+ TQStringList files();
int faxCount() const;
- //QString number( int i = 0 ) const;
- //QString name( int i = 0 ) const;
- //QString enterprise( int i = 0 ) const;
+ //TQString number( int i = 0 ) const;
+ //TQString name( int i = 0 ) const;
+ //TQString enterprise( int i = 0 ) const;
FaxItemList faxList() const;
- QString comment() const;
- QString time() const;
- QString subject() const;
+ TQString comment() const;
+ TQString time() const;
+ TQString subject() const;
bool cover() const;
protected slots:
@@ -73,7 +73,7 @@ protected slots:
void slotRemove();
void slotFax();
void slotAbort();
- void slotMessage(const QString&);
+ void slotMessage(const TQString&);
void slotFaxSent(bool);
void slotViewLog();
void slotConfigure();
@@ -86,16 +86,16 @@ protected slots:
void slotFaxSelectionChanged();
void slotFaxRemove();
void slotFaxAdd();
- void slotFaxExecuted( QListViewItem* );
+ void slotFaxExecuted( TQListViewItem* );
void slotCoverToggled(bool toggle);
protected:
void initActions();
- void dragEnterEvent(QDragEnterEvent*);
- void dropEvent(QDropEvent*);
+ void dragEnterEvent(TQDragEnterEvent*);
+ void dropEvent(TQDropEvent*);
void updateState();
- bool manualFaxDialog( QString& number, QString& name, QString& enterprise );
- //QListViewItem* faxItem( int i = 0 ) const;
+ bool manualFaxDialog( TQString& number, TQString& name, TQString& enterprise );
+ //TQListViewItem* faxItem( int i = 0 ) const;
private:
KListBox *m_files;
@@ -107,8 +107,8 @@ private:
QLabel *m_msglabel;
QTimeEdit *m_time;
QComboBox *m_timecombo;
- QPushButton *m_upbtn, *m_downbtn;
- QPushButton *m_newbtn, *m_abbtn, *m_delbtn;
+ TQPushButton *m_upbtn, *m_downbtn;
+ TQPushButton *m_newbtn, *m_abbtn, *m_delbtn;
bool m_quitAfterSend;
};
diff --git a/kdeprint/kdeprintfax/main.cpp b/kdeprint/kdeprintfax/main.cpp
index a4dd3030f..c1a92fd12 100644
--- a/kdeprint/kdeprintfax/main.cpp
+++ b/kdeprint/kdeprintfax/main.cpp
@@ -20,13 +20,13 @@
#include "kdeprintfax.h"
-#include <qfile.h>
+#include <tqfile.h>
#include <kcmdlineargs.h>
#include <kaboutdata.h>
#include <klocale.h>
#include <kapplication.h>
-QString debugFlag;
+TQString debugFlag;
int oneShotFlag = false;
static const char description[] =
@@ -64,7 +64,7 @@ int main(int argc, char *argv[])
for (int i=0;i<args->count();i++)
w->addURL(args->url(i));
- QString phone = args->getOption( "phone" );
+ TQString phone = args->getOption( "phone" );
if( !phone.isEmpty() ) {
w->setPhone( phone );
}
diff --git a/kdeprint/kjobviewer/kjobviewer.cpp b/kdeprint/kjobviewer/kjobviewer.cpp
index 12a7aef1a..6039da9a0 100644
--- a/kdeprint/kjobviewer/kjobviewer.cpp
+++ b/kdeprint/kjobviewer/kjobviewer.cpp
@@ -23,7 +23,7 @@
#include <kdeprint/kmmanager.h>
#include <stdlib.h>
-#include <qpixmap.h>
+#include <tqpixmap.h>
#include <kcmdlineargs.h>
#include <kaboutdata.h>
#include <kmessagebox.h>
@@ -39,22 +39,22 @@ class JobTray : public KSystemTray
{
public:
JobTray(KJobViewerApp *parent, const char *name = 0)
- : KSystemTray(0, name), m_app(parent) { connect( this, SIGNAL( quitSelected() ), kapp, SLOT( quit() ) ); }
+ : KSystemTray(0, name), m_app(parent) { connect( this, TQT_SIGNAL( quitSelected() ), kapp, TQT_SLOT( quit() ) ); }
protected:
- void mousePressEvent(QMouseEvent*);
+ void mousePressEvent(TQMouseEvent*);
private:
KJobViewerApp *m_app;
};
-void JobTray::mousePressEvent(QMouseEvent *e)
+void JobTray::mousePressEvent(TQMouseEvent *e)
{
if (e->button() == Qt::RightButton)
KSystemTray::mousePressEvent(e);
else if (m_app->m_views.count() > 0)
{
KPopupMenu menu;
- QDictIterator<KMJobViewer> it(m_app->m_views);
- QPtrList<KMJobViewer> list;
+ TQDictIterator<KMJobViewer> it(m_app->m_views);
+ TQPtrList<KMJobViewer> list;
list.setAutoDelete(false);
for (; it.current(); ++it)
{
@@ -117,7 +117,7 @@ void KJobViewerApp::initialize()
if (!m_timer)
{
m_timer = KMTimer::self();
- connect(m_timer,SIGNAL(timeout()),SLOT(slotTimer()));
+ connect(m_timer,TQT_SIGNAL(timeout()),TQT_SLOT(slotTimer()));
}
if (prname.isEmpty() && all)
@@ -146,10 +146,10 @@ void KJobViewerApp::initialize()
{
kdDebug() << "creating new view: " << prname << endl;
view = new KMJobViewer();
- connect(view, SIGNAL(jobsShown(KMJobViewer*,bool)), SLOT(slotJobsShown(KMJobViewer*,bool)));
- connect(view, SIGNAL(printerChanged(KMJobViewer*,const QString&)), SLOT(slotPrinterChanged(KMJobViewer*,const QString&)));
- connect(view, SIGNAL(refreshClicked()), SLOT(slotTimer()));
- connect(view, SIGNAL(viewerDestroyed(KMJobViewer*)), SLOT(slotViewerDestroyed(KMJobViewer*)));
+ connect(view, TQT_SIGNAL(jobsShown(KMJobViewer*,bool)), TQT_SLOT(slotJobsShown(KMJobViewer*,bool)));
+ connect(view, TQT_SIGNAL(printerChanged(KMJobViewer*,const TQString&)), TQT_SLOT(slotPrinterChanged(KMJobViewer*,const TQString&)));
+ connect(view, TQT_SIGNAL(refreshClicked()), TQT_SLOT(slotTimer()));
+ connect(view, TQT_SIGNAL(viewerDestroyed(KMJobViewer*)), TQT_SLOT(slotViewerDestroyed(KMJobViewer*)));
m_views.insert(prname, view);
}
@@ -193,12 +193,12 @@ void KJobViewerApp::slotTimer()
// Refresh views. The first time, job list is reloaded,
// other views will simply use reloaded job list
bool trigger(true);
- QDictIterator<KMJobViewer> it(m_views);
+ TQDictIterator<KMJobViewer> it(m_views);
for (; it.current(); ++it, trigger=false)
it.current()->refresh(trigger);
}
-void KJobViewerApp::slotPrinterChanged(KMJobViewer *view, const QString& prname)
+void KJobViewerApp::slotPrinterChanged(KMJobViewer *view, const TQString& prname)
{
KMJobViewer *other = m_views.find(prname);
if (other)
diff --git a/kdeprint/kjobviewer/kjobviewer.h b/kdeprint/kjobviewer/kjobviewer.h
index 389f160a4..022194d1a 100644
--- a/kdeprint/kjobviewer/kjobviewer.h
+++ b/kdeprint/kjobviewer/kjobviewer.h
@@ -22,7 +22,7 @@
#include <kuniqueapplication.h>
#include <kdeprint/kpreloadobject.h>
-#include <qdict.h>
+#include <tqdict.h>
class KMJobViewer;
class KMTimer;
@@ -45,11 +45,11 @@ protected:
protected slots:
void slotJobsShown(KMJobViewer*, bool);
void slotTimer();
- void slotPrinterChanged(KMJobViewer*, const QString&);
+ void slotPrinterChanged(KMJobViewer*, const TQString&);
void slotViewerDestroyed(KMJobViewer*);
private:
- QDict<KMJobViewer> m_views;
+ TQDict<KMJobViewer> m_views;
JobTray *m_tray;
KMTimer *m_timer;
};
diff --git a/kdeprint/kprinter/main.cpp b/kdeprint/kprinter/main.cpp
index 1d88ace83..dd49103c5 100644
--- a/kdeprint/kprinter/main.cpp
+++ b/kdeprint/kprinter/main.cpp
@@ -19,7 +19,7 @@
#include "printwrapper.h"
-#include <qtimer.h>
+#include <tqtimer.h>
#include <kapplication.h>
#include <kcmdlineargs.h>
#include <klocale.h>
@@ -49,7 +49,7 @@ extern "C" int KDE_EXPORT kdemain(int argc, char *argv[])
KApplication app;
PrintWrapper *wrap = new PrintWrapper;
app.setMainWidget(wrap);
- QTimer::singleShot(10,wrap,SLOT(slotPrint()));
+ TQTimer::singleShot(10,wrap,TQT_SLOT(slotPrint()));
int result = app.exec();
delete wrap;
diff --git a/kdeprint/kprinter/printwrapper.cpp b/kdeprint/kprinter/printwrapper.cpp
index a9f566c72..f5e67f96e 100644
--- a/kdeprint/kprinter/printwrapper.cpp
+++ b/kdeprint/kprinter/printwrapper.cpp
@@ -23,14 +23,14 @@
#include <signal.h>
#include <sys/time.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <stdlib.h>
#include <kmessagebox.h>
-#include <qfile.h>
-#include <qtimer.h>
-#include <qregexp.h>
-#include <qsocketnotifier.h>
+#include <tqfile.h>
+#include <tqtimer.h>
+#include <tqregexp.h>
+#include <tqsocketnotifier.h>
#include <kapplication.h>
#include <kcmdlineargs.h>
@@ -47,14 +47,14 @@
#include <kdeprint/kprintdialog.h>
void signal_handler(int);
-QString tempFile;
+TQString tempFile;
bool fromStdin = false;
char job_output = 0; // 0: dialog, 1: console, 2: none
char readchar = '\0';
bool dataread = false;
bool docopy = false;
-void showmsgdialog(const QString& msg, int type = 0)
+void showmsgdialog(const TQString& msg, int type = 0)
{
switch (type)
{
@@ -64,13 +64,13 @@ void showmsgdialog(const QString& msg, int type = 0)
}
}
-void showmsgconsole(const QString& msg, int type = 0)
+void showmsgconsole(const TQString& msg, int type = 0)
{
- QString errmsg = QString::fromLatin1("%1 : ").arg((type == 0 ? i18n("Print info") : (type == 1 ? i18n("Print warning") : i18n("Print error"))));
+ QString errmsg = TQString::fromLatin1("%1 : ").arg((type == 0 ? i18n("Print info") : (type == 1 ? i18n("Print warning") : i18n("Print error"))));
kdDebug() << errmsg << msg << endl;
}
-void showmsg(const QString& msg, int type = 0)
+void showmsg(const TQString& msg, int type = 0)
{
switch (job_output) {
case 0: showmsgdialog(msg,type); break;
@@ -79,7 +79,7 @@ void showmsg(const QString& msg, int type = 0)
}
}
-void errormsg(const QString& msg)
+void errormsg(const TQString& msg)
{
showmsg(msg,2);
exit(1);
@@ -87,20 +87,20 @@ void errormsg(const QString& msg)
void signal_handler(int s)
{
- QFile::remove(tempFile);
+ TQFile::remove(tempFile);
exit(s);
}
-QString copyfile( const QString& filename )
+TQString copyfile( const TQString& filename )
{
kdDebug( 500 ) << "Copying file " << filename << endl;
- QString result;
- QFile f( filename );
+ TQString result;
+ TQFile f( filename );
if ( f.open( IO_ReadOnly ) )
{
KTempFile temp;
temp.setAutoDelete( false );
- QFile *tf = temp.file();
+ TQFile *tf = temp.file();
if ( tf )
{
char buffer[ 0xFFFF ];
@@ -129,7 +129,7 @@ QString copyfile( const QString& filename )
//******************************************************************************************************
PrintWrapper::PrintWrapper()
-: QWidget(), force_stdin(false), check_stdin(true)
+: TQWidget(), force_stdin(false), check_stdin(true)
{
}
@@ -144,11 +144,11 @@ void PrintWrapper::slotPrint()
// read variables from command line
QString printer = args->getOption("d");
QString title = args->getOption("t");
- int ncopies = QString(args->getOption("n")).toInt();
+ int ncopies = TQString(args->getOption("n")).toInt();
QString job_mode = args->getOption("j");
QString system = args->getOption("system");
QCStringList optlist = args->getOptionList("o");
- QMap<QString,QString> opts;
+ TQMap<TQString,TQString> opts;
KURL::List files;
QStringList filestoprint;
force_stdin = args->isSet("stdin");
@@ -164,8 +164,8 @@ void PrintWrapper::slotPrint()
// parse options
for (QCStringList::ConstIterator it=optlist.begin(); it!=optlist.end(); ++it)
{
- QStringList l = QStringList::split('=',QString(*it),false);
- if (l.count() >= 1) opts[l[0]] = (l.count() == 2 ? l[1] : QString::null);
+ QStringList l = TQStringList::split('=',TQString(*it),false);
+ if (l.count() >= 1) opts[l[0]] = (l.count() == 2 ? l[1] : TQString::null);
}
// read file list
@@ -262,11 +262,11 @@ void PrintWrapper::slotPrint()
dlg = KPrintDialog::printerDialog(&kprinter, 0);
if (dlg)
{
- connect(dlg, SIGNAL(printRequested(KPrinter*)), SLOT(slotPrintRequested(KPrinter*)));
+ connect(dlg, TQT_SIGNAL(printRequested(KPrinter*)), TQT_SLOT(slotPrintRequested(KPrinter*)));
if( check_stdin )
{
- notif = new QSocketNotifier( 0, QSocketNotifier::Read, this );
- connect( notif, SIGNAL( activated( int )), this, SLOT( slotGotStdin()));
+ notif = new TQSocketNotifier( 0, TQSocketNotifier::Read, this );
+ connect( notif, TQT_SIGNAL( activated( int )), this, TQT_SLOT( slotGotStdin()));
kdDebug( 500 ) << "waiting for input on stdin" << endl;
}
dlg->exec();
@@ -276,7 +276,7 @@ void PrintWrapper::slotPrint()
errormsg(i18n("Unable to construct the print dialog."));
}
- QTimer::singleShot(10,kapp,SLOT(quit()));
+ TQTimer::singleShot(10,kapp,TQT_SLOT(quit()));
}
void hack( KPrintDialog* dlg );
@@ -297,11 +297,11 @@ void PrintWrapper::slotGotStdin()
void PrintWrapper::slotPrintRequested(KPrinter *kprinter)
{
// re-initialize docName
- kprinter->setDocName(QString::null);
+ kprinter->setDocName(TQString::null);
// download files if needed
- QStringList files = QStringList::split("@@", kprinter->option("kde-filelist"), false), filestoprint;
- for (QStringList::ConstIterator it=files.begin(); it!=files.end(); ++it)
+ QStringList files = TQStringList::split("@@", kprinter->option("kde-filelist"), false), filestoprint;
+ for (TQStringList::ConstIterator it=files.begin(); it!=files.end(); ++it)
{
QString tmpFile;
KURL url = KURL::fromPathOrURL(*it);
@@ -342,10 +342,10 @@ void PrintWrapper::slotPrintRequested(KPrinter *kprinter)
signal(SIGTERM, signal_handler);
# endif
- tempFile = locateLocal("tmp","kprinter_")+QString::number(getpid());
+ tempFile = locateLocal("tmp","kprinter_")+TQString::number(getpid());
filestoprint.append(tempFile);
fromStdin = true;
- FILE *fout = fopen(QFile::encodeName(filestoprint[0]),"w");
+ FILE *fout = fopen(TQFile::encodeName(filestoprint[0]),"w");
if (!fout) errormsg(i18n("Unable to open temporary file."));
char buffer[8192];
int s;
@@ -362,15 +362,15 @@ void PrintWrapper::slotPrintRequested(KPrinter *kprinter)
if (s <= 0)
{
showmsg(i18n("Stdin is empty, no job sent."), 2);
- QFile::remove(filestoprint[0]);
+ TQFile::remove(filestoprint[0]);
return;
}
}
else if ( docopy )
{
- for ( QStringList::Iterator it=filestoprint.begin(); it!=filestoprint.end(); ++it )
+ for ( TQStringList::Iterator it=filestoprint.begin(); it!=filestoprint.end(); ++it )
{
- QString tmp = copyfile( *it );
+ TQString tmp = copyfile( *it );
if ( tmp.isEmpty() )
{
errormsg( i18n( "Unable to copy file %1." ).arg( *it ) );
diff --git a/kdeprint/kprinter/printwrapper.h b/kdeprint/kprinter/printwrapper.h
index 6c4eed45d..54d25368f 100644
--- a/kdeprint/kprinter/printwrapper.h
+++ b/kdeprint/kprinter/printwrapper.h
@@ -20,7 +20,7 @@
#ifndef PRINTWRAPPER_H
#define PRINTWRAPPER_H
-#include <qwidget.h>
+#include <tqwidget.h>
class KPrinter;
class KPrintDialog;
@@ -43,7 +43,7 @@ private:
bool force_stdin;
bool check_stdin;
KPrintDialog* dlg;
- QSocketNotifier* notif;
+ TQSocketNotifier* notif;
};
#endif
diff --git a/kdeprint/printmgr/kcmprintmgr.cpp b/kdeprint/printmgr/kcmprintmgr.cpp
index 0ffe98ecc..7a986e0bf 100644
--- a/kdeprint/printmgr/kcmprintmgr.cpp
+++ b/kdeprint/printmgr/kcmprintmgr.cpp
@@ -20,17 +20,17 @@
#include "kcmprintmgr.h"
#include "kdeprint/kmmainview.h"
-#include <qlayout.h>
+#include <tqlayout.h>
#include <kgenericfactory.h>
#include <kaboutdata.h>
#include <kdebug.h>
#include <klocale.h>
-typedef KGenericFactory<KCMPrintMgr, QWidget> KPrintMgrFactory;
+typedef KGenericFactory<KCMPrintMgr, TQWidget> KPrintMgrFactory;
K_EXPORT_COMPONENT_FACTORY( kcm_printmgr, KPrintMgrFactory("kcmprintmgr") )
-KCMPrintMgr::KCMPrintMgr(QWidget *parent, const char *name, const QStringList &)
+KCMPrintMgr::KCMPrintMgr(TQWidget *parent, const char *name, const TQStringList &)
: KCModule(KPrintMgrFactory::instance(),parent,name)
{
setButtons(KCModule::Ok);
@@ -43,7 +43,7 @@ KCMPrintMgr::KCMPrintMgr(QWidget *parent, const char *name, const QStringList &)
m_mainview = new KMMainView(this,"MainView");
- QVBoxLayout *main_ = new QVBoxLayout(this, 0, 0);
+ QVBoxLayout *main_ = new TQVBoxLayout(this, 0, 0);
main_->addWidget(m_mainview);
main_->activate();
@@ -55,7 +55,7 @@ KCMPrintMgr::KCMPrintMgr(QWidget *parent, const char *name, const QStringList &)
setAboutData(about);
}
-QString KCMPrintMgr::quickHelp() const
+TQString KCMPrintMgr::quickHelp() const
{
return i18n("<h1>Printers</h1>The KDE printing manager is part of KDEPrint which "
"is the interface to the real print subsystem of your Operating System (OS). "
diff --git a/kdeprint/printmgr/kcmprintmgr.h b/kdeprint/printmgr/kcmprintmgr.h
index 7aa43ef58..126930931 100644
--- a/kdeprint/printmgr/kcmprintmgr.h
+++ b/kdeprint/printmgr/kcmprintmgr.h
@@ -27,10 +27,10 @@ class KMMainView;
class KCMPrintMgr : public KCModule
{
public:
- KCMPrintMgr(QWidget *parent, const char *name, const QStringList &);
+ KCMPrintMgr(TQWidget *parent, const char *name, const TQStringList &);
~KCMPrintMgr();
- QString quickHelp() const;
+ TQString quickHelp() const;
private:
KMMainView *m_mainview;
diff --git a/kdeprint/slave/kio_print.cpp b/kdeprint/slave/kio_print.cpp
index 6857ef2e6..4613edeb8 100644
--- a/kdeprint/slave/kio_print.cpp
+++ b/kdeprint/slave/kio_print.cpp
@@ -24,8 +24,8 @@
#include <kdeprint/kmjob.h>
#include <kdeprint/driver.h>
-#include <qfile.h>
-#include <qtextstream.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
#include <klocale.h>
#include <kdebug.h>
#include <kinstance.h>
@@ -39,8 +39,8 @@
#include <kaboutdata.h>
#include <kprocess.h>
#include <ktempfile.h>
-#include <qfile.h>
-#include <qdom.h>
+#include <tqfile.h>
+#include <tqdom.h>
#include <stdio.h>
#include <stdlib.h>
@@ -53,7 +53,7 @@ extern "C"
int KDE_EXPORT kdemain(int argc, char **argv);
}
-void addAtom(KIO::UDSEntry& entry, unsigned int ID, long l, const QString& s = QString::null)
+void addAtom(KIO::UDSEntry& entry, unsigned int ID, long l, const TQString& s = TQString::null)
{
KIO::UDSAtom atom;
atom.m_uds = ID;
@@ -62,7 +62,7 @@ void addAtom(KIO::UDSEntry& entry, unsigned int ID, long l, const QString& s = Q
entry.append(atom);
}
-static void createDirEntry(KIO::UDSEntry& entry, const QString& name, const QString& url, const QString& mime)
+static void createDirEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& url, const TQString& mime)
{
entry.clear();
addAtom(entry, KIO::UDS_NAME, 0, name);
@@ -75,7 +75,7 @@ static void createDirEntry(KIO::UDSEntry& entry, const QString& name, const QStr
//addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, "application/octet-stream");
}
-static void createFileEntry(KIO::UDSEntry& entry, const QString& name, const QString& url, const QString& mime)
+static void createFileEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& url, const TQString& mime)
{
entry.clear();
addAtom(entry, KIO::UDS_NAME, 0, name);
@@ -87,14 +87,14 @@ static void createFileEntry(KIO::UDSEntry& entry, const QString& name, const QSt
addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, "application/octet-stream");
}
-QString buildMenu(const QStringList& items, const QStringList& links, int active)
+TQString buildMenu(const TQStringList& items, const TQStringList& links, int active)
{
if (items.count() == 0 || items.count() != links.count())
- return QString("<td height=20 class=\"menu\">&nbsp;</td>");
+ return TQString("<td height=20 class=\"menu\">&nbsp;</td>");
QString s;
int index = 0;
- for (QStringList::ConstIterator it1=items.begin(), it2=links.begin(); it1!=items.end() && it2!=links.end(); ++it1, ++it2, index++)
+ for (TQStringList::ConstIterator it1=items.begin(), it2=links.begin(); it1!=items.end() && it2!=links.end(); ++it1, ++it2, index++)
{
if (index == active)
s.append("<td height=20 class=\"menuactive\">&nbsp; ").append(*it1).append("&nbsp;</td>");
@@ -106,27 +106,27 @@ QString buildMenu(const QStringList& items, const QStringList& links, int active
return s;
}
-QString buildOptionRow(DrBase *opt, bool f)
+TQString buildOptionRow(DrBase *opt, bool f)
{
QString s("<tr class=\"%1\"><td width=\"41%\">%1</td><td width=\"59%\">%1</td></tr>\n");
s = s.arg(f ? "contentwhite" : "contentyellow").arg(opt->get("text")).arg(opt->prettyText());
return s;
}
-QString buildGroupTable(DrGroup *grp, bool showHeader = true)
+TQString buildGroupTable(DrGroup *grp, bool showHeader = true)
{
QString s("<tr class=\"top\"><td colspan=\"2\">%1</td></tr>\n");
if (showHeader)
s = s.arg(grp->get("text"));
else
- s = QString::null;
+ s = TQString::null;
- QPtrListIterator<DrBase> oit(grp->options());
+ TQPtrListIterator<DrBase> oit(grp->options());
bool f(false);
for (; oit.current(); ++oit, f = !f)
s.append(buildOptionRow(oit.current(), f));
- QPtrListIterator<DrGroup> git(grp->groups());
+ TQPtrListIterator<DrGroup> git(grp->groups());
for (; git.current(); ++git)
s.append(buildGroupTable(git.current()));
@@ -157,7 +157,7 @@ int kdemain(int argc, char **argv)
return 0;
}
-KIO_Print::KIO_Print(const QCString& pool, const QCString& app)
+KIO_Print::KIO_Print(const TQCString& pool, const TQCString& app)
: KIO::SlaveBase("print", pool, app)
{
}
@@ -170,7 +170,7 @@ void KIO_Print::listDir(const KURL& url)
return;
}
- QStringList path = QStringList::split('/', url.path(), false);
+ QStringList path = TQStringList::split('/', url.path(), false);
PRINT_DEBUG << "listing " << url.path() << endl;
QString group = path[0].lower();
@@ -205,7 +205,7 @@ void KIO_Print::listDir(const KURL& url)
return;
}
- QPtrListIterator<KMPrinter> it(*(KMManager::self()->printerList()));
+ TQPtrListIterator<KMPrinter> it(*(KMManager::self()->printerList()));
for (;it.current();++it)
{
if (!(it.current()->type() & mask) || !it.current()->instanceName().isEmpty())
@@ -252,7 +252,7 @@ void KIO_Print::listRoot()
listEntry(entry, false);
// Management entry
- //createFileEntry(entry, i18n("Manager"), "print:/manager", "print/manager", QString::null, S_IFDIR);
+ //createFileEntry(entry, i18n("Manager"), "print:/manager", "print/manager", TQString::null, S_IFDIR);
createDirEntry(entry, i18n("Manager"), "print:/manager", "print/manager");
listEntry(entry, false);
@@ -270,7 +270,7 @@ void KIO_Print::listDirDB( const KURL& url )
{
PRINT_DEBUG << "listDirDB: " << url << endl;
- QStringList pathComps = QStringList::split( '/', url.path(), false );
+ TQStringList pathComps = TQStringList::split( '/', url.path(), false );
KURL remUrl;
remUrl.setProtocol( "http" );
@@ -298,10 +298,10 @@ void KIO_Print::listDirDB( const KURL& url )
if ( getDBFile( remUrl ) )
{
- QDomDocument doc;
+ TQDomDocument doc;
if ( doc.setContent( &m_httpBuffer, false ) )
{
- QDomNodeList l;
+ TQDomNodeList l;
KIO::UDSEntry entry;
switch ( pathComps.size() )
{
@@ -309,7 +309,7 @@ void KIO_Print::listDirDB( const KURL& url )
l = doc.documentElement().elementsByTagName( "make" );
for ( unsigned int i=0; i<l.count(); i++ )
{
- QString make = l.item( i ).toElement().text();
+ TQString make = l.item( i ).toElement().text();
KURL makeUrl = url;
makeUrl.addPath( "/" + make );
createDirEntry( entry, make, makeUrl.url(), "print/folder" );
@@ -321,10 +321,10 @@ void KIO_Print::listDirDB( const KURL& url )
l = doc.documentElement().elementsByTagName( "printer" );
for ( unsigned int i=0; i<l.count(); i++ )
{
- QString ID, name;
- for ( QDomNode n=l.item( i ).firstChild(); !n.isNull(); n=n.nextSibling() )
+ TQString ID, name;
+ for ( TQDomNode n=l.item( i ).firstChild(); !n.isNull(); n=n.nextSibling() )
{
- QDomElement e = n.toElement();
+ TQDomElement e = n.toElement();
if ( e.tagName() == "id" )
ID = e.text();
else if ( e.tagName() == "model" )
@@ -344,7 +344,7 @@ void KIO_Print::listDirDB( const KURL& url )
l = doc.documentElement().elementsByTagName( "driver" );
for ( unsigned int i=0; i<l.count(); i++ )
{
- QString driver = l.item( i ).toElement().text();
+ TQString driver = l.item( i ).toElement().text();
KURL driverUrl = url;
driverUrl.addPath( "/" + driver );
createFileEntry( entry, driver, driverUrl.url(), "print/driver" );
@@ -382,7 +382,7 @@ void KIO_Print::stat(const KURL& url)
}
PRINT_DEBUG << "stat: " << url.url() << endl;
- QStringList path = QStringList::split('/', url.encodedPathAndQuery(-1), false);
+ QStringList path = TQStringList::split('/', url.encodedPathAndQuery(-1), false);
KIO::UDSEntry entry;
QString mime;
bool err(false);
@@ -434,7 +434,7 @@ void KIO_Print::statDB( const KURL& url )
{
PRINT_DEBUG << "statDB: " << url << endl;
KIO::UDSEntry entry;
- QStringList pathComps = QStringList::split( '/', url.path(), false );
+ TQStringList pathComps = TQStringList::split( '/', url.path(), false );
if ( pathComps.size() == 3 )
createFileEntry( entry, i18n( "Printer driver" ), url.url(), "print/driver" );
else
@@ -455,10 +455,10 @@ bool KIO_Print::getDBFile( const KURL& src )
/* start the transfer job */
KIO::TransferJob *job = KIO::get( src, false, false );
- connect( job, SIGNAL( result( KIO::Job* ) ), SLOT( slotResult( KIO::Job* ) ) );
- connect( job, SIGNAL( data( KIO::Job*, const QByteArray& ) ), SLOT( slotData( KIO::Job*, const QByteArray& ) ) );
- connect( job, SIGNAL( totalSize( KIO::Job*, KIO::filesize_t ) ), SLOT( slotTotalSize( KIO::Job*, KIO::filesize_t ) ) );
- connect( job, SIGNAL( processedSize( KIO::Job*, KIO::filesize_t ) ), SLOT( slotProcessedSize( KIO::Job*, KIO::filesize_t ) ) );
+ connect( job, TQT_SIGNAL( result( KIO::Job* ) ), TQT_SLOT( slotResult( KIO::Job* ) ) );
+ connect( job, TQT_SIGNAL( data( KIO::Job*, const TQByteArray& ) ), TQT_SLOT( slotData( KIO::Job*, const TQByteArray& ) ) );
+ connect( job, TQT_SIGNAL( totalSize( KIO::Job*, KIO::filesize_t ) ), TQT_SLOT( slotTotalSize( KIO::Job*, KIO::filesize_t ) ) );
+ connect( job, TQT_SIGNAL( processedSize( KIO::Job*, KIO::filesize_t ) ), TQT_SLOT( slotProcessedSize( KIO::Job*, KIO::filesize_t ) ) );
kapp->enter_loop();
m_httpBuffer.close();
@@ -472,7 +472,7 @@ void KIO_Print::getDB( const KURL& url )
{
PRINT_DEBUG << "downloading PPD file for " << url.url() << endl;
- QStringList pathComps = QStringList::split( '/', url.path(), false );
+ TQStringList pathComps = TQStringList::split( '/', url.path(), false );
if ( pathComps.size() != 3 )
error( KIO::ERR_MALFORMED_URL, url.url() );
else
@@ -513,7 +513,7 @@ void KIO_Print::slotResult( KIO::Job *j )
kapp->exit_loop();
}
-void KIO_Print::slotData( KIO::Job *j, const QByteArray& d )
+void KIO_Print::slotData( KIO::Job *j, const TQByteArray& d )
{
PRINT_DEBUG << "HTTP data received (size=" << d.size() << ")" << endl;
if ( d.size() > 0 )
@@ -546,7 +546,7 @@ void KIO_Print::get(const KURL& url)
return;
}
- QStringList elems = QStringList::split('/', url.encodedPathAndQuery(), false);
+ QStringList elems = TQStringList::split('/', url.encodedPathAndQuery(), false);
QString group(elems[0].lower()), printer(KURL::decode_string(elems[1])), path, query;
KMPrinter *mprinter(0);
@@ -568,7 +568,7 @@ void KIO_Print::get(const KURL& url)
query = group.mid(p+1);
if (!query.isEmpty() && query != "jobs" && query != "completed_jobs")
{
- error(KIO::ERR_MALFORMED_URL, QString::null);
+ error(KIO::ERR_MALFORMED_URL, TQString::null);
return;
}
PRINT_DEBUG << "listing jobs for all printers" << endl;
@@ -635,7 +635,7 @@ void KIO_Print::showPrinterInfo(KMPrinter *printer)
mimeType("text/html");
QString content;
- if (!loadTemplate(QString::fromLatin1("printer.template"), content))
+ if (!loadTemplate(TQString::fromLatin1("printer.template"), content))
{
error(KIO::ERR_INTERNAL, i18n("Unable to load template %1").arg("printer.template"));
return;
@@ -644,10 +644,10 @@ void KIO_Print::showPrinterInfo(KMPrinter *printer)
content = content
.arg(i18n("Properties of %1").arg(printer->printerName()))
.arg(i18n("Properties of %1").arg(printer->printerName()))
- .arg(buildMenu(QStringList::split('|', i18n("General|Driver|Active jobs|Completed jobs"), false),
- QStringList::split('|', "?general|?driver|?jobs|?completed_jobs", true),
+ .arg(buildMenu(TQStringList::split('|', i18n("General|Driver|Active jobs|Completed jobs"), false),
+ TQStringList::split('|', "?general|?driver|?jobs|?completed_jobs", true),
0))
- .arg(QString::null)
+ .arg(TQString::null)
.arg(printer->pixmap())
.arg(printer->name())
.arg(i18n("General Properties"))
@@ -676,7 +676,7 @@ void KIO_Print::showClassInfo(KMPrinter *printer)
mimeType("text/html");
QString content;
- if (!loadTemplate(QString::fromLatin1("class.template"), content))
+ if (!loadTemplate(TQString::fromLatin1("class.template"), content))
{
error(KIO::ERR_INTERNAL, i18n("Unable to load template %1").arg("class.template"));
return;
@@ -684,9 +684,9 @@ void KIO_Print::showClassInfo(KMPrinter *printer)
QString memberContent("<ul>\n");
QStringList members(printer->members());
- for (QStringList::ConstIterator it=members.begin(); it!=members.end(); ++it)
+ for (TQStringList::ConstIterator it=members.begin(); it!=members.end(); ++it)
{
- memberContent.append(QString::fromLatin1("<li><a href=\"print:/printers/%1\">%2</a></li>\n").arg(*it).arg(*it));
+ memberContent.append(TQString::fromLatin1("<li><a href=\"print:/printers/%1\">%2</a></li>\n").arg(*it).arg(*it));
}
memberContent.append("</ul>\n");
@@ -695,10 +695,10 @@ void KIO_Print::showClassInfo(KMPrinter *printer)
content = content
.arg(i18n("Properties of %1").arg(printer->printerName()))
.arg(i18n("Properties of %1").arg(printer->printerName()))
- .arg(buildMenu(QStringList::split('|', i18n("General|Active jobs|Completed jobs"), false),
- QStringList::split('|', "?general|?jobs|?completed_jobs", true),
+ .arg(buildMenu(TQStringList::split('|', i18n("General|Active jobs|Completed jobs"), false),
+ TQStringList::split('|', "?general|?jobs|?completed_jobs", true),
0))
- .arg(QString::null)
+ .arg(TQString::null)
.arg(printer->pixmap())
.arg(printer->name())
.arg(i18n("General Properties"))
@@ -719,25 +719,25 @@ void KIO_Print::showSpecialInfo(KMPrinter *printer)
mimeType("text/html");
QString content;
- if (!loadTemplate(QString::fromLatin1("pseudo.template"), content))
+ if (!loadTemplate(TQString::fromLatin1("pseudo.template"), content))
{
error(KIO::ERR_INTERNAL, i18n("Unable to load template %1").arg("pseudo.template"));
return;
}
QString reqContent("<ul>\n");
- QStringList requirements = QStringList::split(",", printer->option("kde-special-require"), false);
- for (QStringList::ConstIterator it=requirements.begin(); it!=requirements.end(); ++it)
+ QStringList requirements = TQStringList::split(",", printer->option("kde-special-require"), false);
+ for (TQStringList::ConstIterator it=requirements.begin(); it!=requirements.end(); ++it)
reqContent += ("<li>" + (*it) + "</li>\n");
reqContent.append("</ul>\n");
content = content
.arg(i18n("Properties of %1").arg(printer->printerName()))
.arg(i18n("Properties of %1").arg(printer->printerName()))
- .arg(buildMenu(QStringList::split('|', i18n("General"), false),
- QStringList::split('|', "?general", true),
+ .arg(buildMenu(TQStringList::split('|', i18n("General"), false),
+ TQStringList::split('|', "?general", true),
0))
- .arg(QString::null)
+ .arg(TQString::null)
.arg(printer->pixmap())
.arg(printer->name())
.arg(i18n("General Properties"))
@@ -753,9 +753,9 @@ void KIO_Print::showSpecialInfo(KMPrinter *printer)
finished();
}
-bool KIO_Print::loadTemplate(const QString& filename, QString& buffer)
+bool KIO_Print::loadTemplate(const TQString& filename, TQString& buffer)
{
- QFile f(locate("data", QString::fromLatin1("kdeprint/template/")+filename));
+ QFile f(locate("data", TQString::fromLatin1("kdeprint/template/")+filename));
if (f.exists() && f.open(IO_ReadOnly))
{
QTextStream t(&f);
@@ -764,12 +764,12 @@ bool KIO_Print::loadTemplate(const QString& filename, QString& buffer)
}
else
{
- buffer = QString::null;
+ buffer = TQString::null;
return false;
}
}
-void KIO_Print::showData(const QString& pathname)
+void KIO_Print::showData(const TQString& pathname)
{
PRINT_DEBUG << "sending data: " << pathname << endl;
QFile f(pathname);
@@ -792,7 +792,7 @@ void KIO_Print::showData(const QString& pathname)
* - $KDEDIR/share/apps/kdeprint/template/
* - as a desktop icon
*/
-QString KIO_Print::locateData(const QString& item)
+TQString KIO_Print::locateData(const TQString& item)
{
QString path = locate("data", "kdeprint/template/"+item);
if (path.isEmpty())
@@ -811,7 +811,7 @@ void KIO_Print::showJobs(KMPrinter *prt, bool completed)
mgr->addPrinter(prt->printerName(), type);
else
{
- QPtrListIterator<KMPrinter> pit(*(KMManager::self()->printerList()));
+ TQPtrListIterator<KMPrinter> pit(*(KMManager::self()->printerList()));
for (; pit.current(); ++pit)
if (pit.current()->isVirtual() || pit.current()->isSpecial())
continue;
@@ -820,7 +820,7 @@ void KIO_Print::showJobs(KMPrinter *prt, bool completed)
}
QString content;
- if (!loadTemplate(QString::fromLatin1("jobs.template"), content))
+ if (!loadTemplate(TQString::fromLatin1("jobs.template"), content))
{
error(KIO::ERR_INTERNAL, i18n("Unable to load template %1").arg("pseudo.template"));
return;
@@ -832,13 +832,13 @@ void KIO_Print::showJobs(KMPrinter *prt, bool completed)
.arg(i18n("Jobs of %1").arg(prt->printerName()))
.arg(i18n("Jobs of %1").arg(prt->printerName()))
.arg(prt->isClass () ?
- buildMenu(QStringList::split('|', i18n("General|Active jobs|Completed jobs"), false),
- QStringList::split('|', "?general|?jobs|?completed_jobs", true),
+ buildMenu(TQStringList::split('|', i18n("General|Active jobs|Completed jobs"), false),
+ TQStringList::split('|', "?general|?jobs|?completed_jobs", true),
(completed ? 2 : 1)) :
- buildMenu(QStringList::split('|', i18n("General|Driver|Active jobs|Completed jobs"), false),
- QStringList::split('|', "?general|?driver|?jobs|?completed_jobs", true),
+ buildMenu(TQStringList::split('|', i18n("General|Driver|Active jobs|Completed jobs"), false),
+ TQStringList::split('|', "?general|?driver|?jobs|?completed_jobs", true),
(completed ? 3 : 2)))
- .arg(QString::null)
+ .arg(TQString::null)
.arg(prt->pixmap())
.arg(prt->printerName());
}
@@ -846,8 +846,8 @@ void KIO_Print::showJobs(KMPrinter *prt, bool completed)
{
content = content
.arg(i18n("All jobs"))
- .arg(buildMenu(QStringList::split('|', i18n("Active jobs|Completed jobs"), false),
- QStringList::split('|', "?jobs|?completed_jobs", true),
+ .arg(buildMenu(TQStringList::split('|', i18n("Active jobs|Completed jobs"), false),
+ TQStringList::split('|', "?jobs|?completed_jobs", true),
(completed ? 1 : 0)))
.arg("fileprint")
.arg(i18n("All jobs"));
@@ -855,7 +855,7 @@ void KIO_Print::showJobs(KMPrinter *prt, bool completed)
content = content.arg(i18n("ID")).arg(i18n("Owner")).arg(i18n("Printer")).arg(i18n("Name")).arg(i18n("State"));
QString jobContent, cellContent("<td>%1</td>\n");
- QPtrListIterator<KMJob> it(mgr->jobList());
+ TQPtrListIterator<KMJob> it(mgr->jobList());
bool flag(true);
for (; it.current(); ++it, flag = !flag)
{
@@ -874,7 +874,7 @@ void KIO_Print::showJobs(KMPrinter *prt, bool completed)
mgr->removePrinter(prt->printerName(), type);
else
{
- QPtrListIterator<KMPrinter> pit(*(KMManager::self()->printerList()));
+ TQPtrListIterator<KMPrinter> pit(*(KMManager::self()->printerList()));
for (; pit.current(); ++pit)
if (pit.current()->isVirtual() || pit.current()->isSpecial())
continue;
@@ -891,7 +891,7 @@ void KIO_Print::showDriver(KMPrinter *prt)
mimeType("text/html");
QString content;
- if (!loadTemplate(QString::fromLatin1("driver.template"), content))
+ if (!loadTemplate(TQString::fromLatin1("driver.template"), content))
{
error(KIO::ERR_INTERNAL, i18n("Unable to load template %1").arg("pseudo.template"));
return;
@@ -901,17 +901,17 @@ void KIO_Print::showDriver(KMPrinter *prt)
content = content
.arg(i18n("Driver of %1").arg(prt->printerName()))
.arg(i18n("Driver of %1").arg(prt->printerName()))
- .arg(buildMenu(QStringList::split('|', i18n("General|Driver|Active jobs|Completed jobs"), false),
- QStringList::split('|', "?general|?driver|?jobs|?completed_jobs", true),
+ .arg(buildMenu(TQStringList::split('|', i18n("General|Driver|Active jobs|Completed jobs"), false),
+ TQStringList::split('|', "?general|?driver|?jobs|?completed_jobs", true),
1))
- .arg(QString::null)
+ .arg(TQString::null)
.arg(prt->pixmap())
.arg(prt->printerName() + "&nbsp;(" + (driver ? driver->get("text") : i18n("No driver found")) + ")");
if (driver)
content = content.arg(buildGroupTable(driver, false));
else
- content = content.arg(QString::null);
+ content = content.arg(TQString::null);
data(content.local8Bit());
finished();
diff --git a/kdeprint/slave/kio_print.h b/kdeprint/slave/kio_print.h
index 3fa20bbf1..7f622cb6b 100644
--- a/kdeprint/slave/kio_print.h
+++ b/kdeprint/slave/kio_print.h
@@ -22,19 +22,19 @@
#include <kio/slavebase.h>
#include <kio/global.h>
-#include <qstring.h>
-#include <qbuffer.h>
+#include <tqstring.h>
+#include <tqbuffer.h>
class KMPrinter;
namespace KIO {
class Job;
}
-class KIO_Print : public QObject, public KIO::SlaveBase
+class KIO_Print : public TQObject, public KIO::SlaveBase
{
Q_OBJECT
public:
- KIO_Print(const QCString& pool, const QCString& app);
+ KIO_Print(const TQCString& pool, const TQCString& app);
void listDir(const KURL& url);
void get(const KURL& url);
@@ -42,7 +42,7 @@ public:
protected slots:
void slotResult( KIO::Job* );
- void slotData( KIO::Job*, const QByteArray& );
+ void slotData( KIO::Job*, const TQByteArray& );
void slotTotalSize( KIO::Job*, KIO::filesize_t );
void slotProcessedSize( KIO::Job*, KIO::filesize_t );
@@ -55,16 +55,16 @@ private:
void showClassInfo(KMPrinter*);
void showPrinterInfo(KMPrinter*);
void showSpecialInfo(KMPrinter*);
- void showData(const QString&);
- QString locateData(const QString&);
+ void showData(const TQString&);
+ TQString locateData(const TQString&);
void showJobs(KMPrinter *p = 0, bool completed = false);
void showDriver(KMPrinter*);
- bool loadTemplate(const QString& filename, QString& buffer);
+ bool loadTemplate(const TQString& filename, TQString& buffer);
- QBuffer m_httpBuffer;
+ TQBuffer m_httpBuffer;
int m_httpError;
- QString m_httpErrorTxt;
+ TQString m_httpErrorTxt;
};
#endif