summaryrefslogtreecommitdiffstats
path: root/konsole
diff options
context:
space:
mode:
Diffstat (limited to 'konsole')
-rw-r--r--konsole/konsole/TECommon.h20
-rw-r--r--konsole/konsole/TEHistory.cpp10
-rw-r--r--konsole/konsole/TEHistory.h26
-rw-r--r--konsole/konsole/TEPty.cpp18
-rw-r--r--konsole/konsole/TEPty.h18
-rw-r--r--konsole/konsole/TEScreen.cpp30
-rw-r--r--konsole/konsole/TEScreen.h14
-rw-r--r--konsole/konsole/TEWidget.cpp410
-rw-r--r--konsole/konsole/TEWidget.h136
-rw-r--r--konsole/konsole/TEmuVt102.cpp42
-rw-r--r--konsole/konsole/TEmuVt102.h4
-rw-r--r--konsole/konsole/TEmulation.cpp118
-rw-r--r--konsole/konsole/TEmulation.h32
-rw-r--r--konsole/konsole/fontembedder.cpp18
-rw-r--r--konsole/konsole/keytrans.cpp74
-rw-r--r--konsole/konsole/keytrans.h30
-rw-r--r--konsole/konsole/konsole.cpp1010
-rw-r--r--konsole/konsole/konsole.h160
-rw-r--r--konsole/konsole/konsole_part.cpp228
-rw-r--r--konsole/konsole/konsole_part.h44
-rw-r--r--konsole/konsole/konsole_wcwidth.cpp2
-rw-r--r--konsole/konsole/konsole_wcwidth.h6
-rw-r--r--konsole/konsole/konsolebookmarkhandler.cpp26
-rw-r--r--konsole/konsole/konsolebookmarkhandler.h16
-rw-r--r--konsole/konsole/konsolebookmarkmenu.cpp20
-rw-r--r--konsole/konsole/konsolebookmarkmenu.h4
-rw-r--r--konsole/konsole/konsoleiface.h10
-rw-r--r--konsole/konsole/kwrited.cpp26
-rw-r--r--konsole/konsole/kwrited.h10
-rw-r--r--konsole/konsole/main.cpp140
-rw-r--r--konsole/konsole/printsettings.cpp18
-rw-r--r--konsole/konsole/printsettings.h6
-rw-r--r--konsole/konsole/schema.cpp118
-rw-r--r--konsole/konsole/schema.h52
-rw-r--r--konsole/konsole/session.cpp240
-rw-r--r--konsole/konsole/session.h118
-rw-r--r--konsole/konsole/sessioniface.h24
-rw-r--r--konsole/konsole/zmodem_dialog.cpp10
-rw-r--r--konsole/konsole/zmodem_dialog.h6
39 files changed, 1647 insertions, 1647 deletions
diff --git a/konsole/konsole/TECommon.h b/konsole/konsole/TECommon.h
index c541fe0f1..94b5ecc33 100644
--- a/konsole/konsole/TECommon.h
+++ b/konsole/konsole/TECommon.h
@@ -25,7 +25,7 @@
#ifndef TECOMMON_H
#define TECOMMON_H
-#include <qcolor.h>
+#include <tqcolor.h>
#ifndef UINT8
typedef unsigned char UINT8;
@@ -41,14 +41,14 @@ typedef unsigned short UINT16;
*/
struct ColorEntry
{
- ColorEntry(QColor c, bool tr, bool b) : color(c), transparent(tr), bold(b) {}
+ ColorEntry(TQColor c, bool tr, bool b) : color(c), transparent(tr), bold(b) {}
ColorEntry() : transparent(false), bold(false) {} // default constructors
void operator=(const ColorEntry& rhs) {
color = rhs.color;
transparent = rhs.transparent;
bold = rhs.bold;
}
- QColor color;
+ TQColor color;
bool transparent; // if used on bg
bool bold; // if used on fg
};
@@ -105,7 +105,7 @@ public:
UINT8 v; // ... color space. C++ does not do unions, so we cannot ...
UINT8 w; // ... express ourselfs here, properly.
void toggleIntensive(); // Hack or helper?
- QColor color(const ColorEntry* base) const;
+ TQColor color(const ColorEntry* base) const;
friend bool operator == (cacol a, cacol b);
friend bool operator != (cacol a, cacol b);
};
@@ -146,30 +146,30 @@ inline bool operator != (cacol a, cacol b)
return a.t != b.t || a.u != b.u || a.v != b.v || a.w != b.w;
}
-inline const QColor color256(UINT8 u, const ColorEntry* base)
+inline const TQColor color256(UINT8 u, const ColorEntry* base)
{
// 0.. 16: system colors
if (u < 8) return base[u+2 ].color; u -= 8;
if (u < 8) return base[u+2+BASE_COLORS].color; u -= 8;
// 16..231: 6x6x6 rgb color cube
- if (u < 216) return QColor(255*((u/36)%6)/5,
+ if (u < 216) return TQColor(255*((u/36)%6)/5,
255*((u/ 6)%6)/5,
255*((u/ 1)%6)/5); u -= 216;
// 232..255: gray, leaving out black and white
- int gray = u*10+8; return QColor(gray,gray,gray);
+ int gray = u*10+8; return TQColor(gray,gray,gray);
}
-inline QColor cacol::color(const ColorEntry* base) const
+inline TQColor cacol::color(const ColorEntry* base) const
{
switch (t)
{
case CO_DFT: return base[u+0+(v?BASE_COLORS:0)].color;
case CO_SYS: return base[u+2+(v?BASE_COLORS:0)].color;
case CO_256: return color256(u,base);
- case CO_RGB: return QColor(u,v,w);
- default : return QColor(255,0,0); // diagnostic catch all
+ case CO_RGB: return TQColor(u,v,w);
+ default : return TQColor(255,0,0); // diagnostic catch all
}
}
diff --git a/konsole/konsole/TEHistory.cpp b/konsole/konsole/TEHistory.cpp
index a24635acb..cbe8b199d 100644
--- a/konsole/konsole/TEHistory.cpp
+++ b/konsole/konsole/TEHistory.cpp
@@ -144,7 +144,7 @@ bool HistoryScroll::hasScroll()
at 0 in cells.
*/
-HistoryScrollFile::HistoryScrollFile(const QString &logFileName)
+HistoryScrollFile::HistoryScrollFile(const TQString &logFileName)
: HistoryScroll(new HistoryTypeFile(logFileName)),
m_logFileName(logFileName)
{
@@ -246,9 +246,9 @@ void HistoryScrollBuffer::addCells(ca a[], int count)
void HistoryScrollBuffer::normalize()
{
if (!m_buffFilled || !m_arrayIndex) return;
- QPtrVector<histline> newHistBuffer;
+ TQPtrVector<histline> newHistBuffer;
newHistBuffer.resize(m_maxNbLines);
- QBitArray newWrappedLine;
+ TQBitArray newWrappedLine;
newWrappedLine.resize(m_maxNbLines);
for(int i = 0; i < (int) m_maxNbLines-2; i++)
{
@@ -583,7 +583,7 @@ HistoryScroll* HistoryTypeBuffer::getScroll(HistoryScroll *old) const
//////////////////////////////
-HistoryTypeFile::HistoryTypeFile(const QString& fileName)
+HistoryTypeFile::HistoryTypeFile(const TQString& fileName)
: m_fileName(fileName)
{
}
@@ -593,7 +593,7 @@ bool HistoryTypeFile::isOn() const
return true;
}
-const QString& HistoryTypeFile::getFileName() const
+const TQString& HistoryTypeFile::getFileName() const
{
return m_fileName;
}
diff --git a/konsole/konsole/TEHistory.h b/konsole/konsole/TEHistory.h
index 446611e0a..dd5ba7a67 100644
--- a/konsole/konsole/TEHistory.h
+++ b/konsole/konsole/TEHistory.h
@@ -21,9 +21,9 @@
#ifndef TEHISTORY_H
#define TEHISTORY_H
-#include <qcstring.h>
-#include <qptrvector.h>
-#include <qbitarray.h>
+#include <tqcstring.h>
+#include <tqptrvector.h>
+#include <tqbitarray.h>
#include <ktempfile.h>
@@ -95,7 +95,7 @@ protected:
class HistoryScrollFile : public HistoryScroll
{
public:
- HistoryScrollFile(const QString &logFileName);
+ HistoryScrollFile(const TQString &logFileName);
virtual ~HistoryScrollFile();
virtual int getLines();
@@ -109,7 +109,7 @@ public:
private:
int startOfLine(int lineno);
- QString m_logFileName;
+ TQString m_logFileName;
HistoryFile index; // lines Row(int)
HistoryFile cells; // text Row(ca)
HistoryFile lineflags; // flags Row(unsigned char)
@@ -122,7 +122,7 @@ private:
class HistoryScrollBuffer : public HistoryScroll
{
public:
- typedef QMemArray<ca> histline;
+ typedef TQMemArray<ca> histline;
HistoryScrollBuffer(unsigned int maxNbLines = 1000);
virtual ~HistoryScrollBuffer();
@@ -146,8 +146,8 @@ private:
void normalize();
bool m_hasScroll;
- QPtrVector<histline> m_histBuffer;
- QBitArray m_wrappedLine;
+ TQPtrVector<histline> m_histBuffer;
+ TQBitArray m_wrappedLine;
unsigned int m_maxNbLines;
unsigned int m_nbLines;
unsigned int m_arrayIndex;
@@ -181,7 +181,7 @@ public:
// BlockArray-based history
//////////////////////////////////////////////////////////////////////
#include "BlockArray.h"
-#include <qintdict.h>
+#include <tqintdict.h>
class HistoryScrollBlockArray : public HistoryScroll
{
public:
@@ -198,7 +198,7 @@ public:
protected:
BlockArray m_blockArray;
- QIntDict<size_t> m_lineLengths;
+ TQIntDict<size_t> m_lineLengths;
};
//////////////////////////////////////////////////////////////////////
@@ -246,16 +246,16 @@ protected:
class HistoryTypeFile : public HistoryType
{
public:
- HistoryTypeFile(const QString& fileName=QString::null);
+ HistoryTypeFile(const TQString& fileName=TQString::null);
virtual bool isOn() const;
- virtual const QString& getFileName() const;
+ virtual const TQString& getFileName() const;
virtual unsigned int getSize() const;
virtual HistoryScroll* getScroll(HistoryScroll *) const;
protected:
- QString m_fileName;
+ TQString m_fileName;
};
diff --git a/konsole/konsole/TEPty.cpp b/konsole/konsole/TEPty.cpp
index e68ea8ff5..86e916e57 100644
--- a/konsole/konsole/TEPty.cpp
+++ b/konsole/konsole/TEPty.cpp
@@ -126,14 +126,14 @@ void TEPty::setErase(char erase)
/*!
start the client program.
*/
-int TEPty::run(const char* _pgm, QStrList & _args, const char* _term, ulong winid, bool _addutmp,
+int TEPty::run(const char* _pgm, TQStrList & _args, const char* _term, ulong winid, bool _addutmp,
const char* _konsole_dcop, const char* _konsole_dcop_session)
{
clearArguments();
setBinaryExecutable(_pgm);
- QStrListIterator it( _args );
+ TQStrListIterator it( _args );
for (; it.current(); ++it )
arguments.append(it.current());
@@ -143,7 +143,7 @@ int TEPty::run(const char* _pgm, QStrList & _args, const char* _term, ulong wini
setEnvironment("KONSOLE_DCOP",_konsole_dcop);
if (_konsole_dcop_session && _konsole_dcop_session[0])
setEnvironment("KONSOLE_DCOP_SESSION", _konsole_dcop_session);
- setEnvironment("WINDOWID", QString::number(winid));
+ setEnvironment("WINDOWID", TQString::number(winid));
setUsePty(All, _addutmp);
@@ -171,12 +171,12 @@ void TEPty::setWriteable(bool writeable)
TEPty::TEPty()
{
m_bufferFull = false;
- connect(this, SIGNAL(receivedStdout(KProcess *, char *, int )),
- this, SLOT(dataReceived(KProcess *,char *, int)));
- connect(this, SIGNAL(processExited(KProcess *)),
- this, SLOT(donePty()));
- connect(this, SIGNAL(wroteStdin(KProcess *)),
- this, SLOT(writeReady()));
+ connect(this, TQT_SIGNAL(receivedStdout(KProcess *, char *, int )),
+ this, TQT_SLOT(dataReceived(KProcess *,char *, int)));
+ connect(this, TQT_SIGNAL(processExited(KProcess *)),
+ this, TQT_SLOT(donePty()));
+ connect(this, TQT_SIGNAL(wroteStdin(KProcess *)),
+ this, TQT_SLOT(writeReady()));
setUsePty(All, false); // utmp will be overridden later
}
diff --git a/konsole/konsole/TEPty.h b/konsole/konsole/TEPty.h
index 1597d44d8..d6cee77dd 100644
--- a/konsole/konsole/TEPty.h
+++ b/konsole/konsole/TEPty.h
@@ -24,10 +24,10 @@
#include <config.h>
#include <kprocess.h>
-#include <qsocketnotifier.h>
-#include <qstrlist.h>
-#include <qvaluelist.h>
-#include <qmemarray.h>
+#include <tqsocketnotifier.h>
+#include <tqstrlist.h>
+#include <tqvaluelist.h>
+#include <tqmemarray.h>
class TEPty: public KProcess
{
@@ -52,10 +52,10 @@ Q_OBJECT
* the necessary connections to the signals and slots of the
* instance before starting the execution of the client.
*/
- int run( const char* pgm, QStrList & args, const char* term, ulong winid, bool _addutmp,
+ int run( const char* pgm, TQStrList & args, const char* term, ulong winid, bool _addutmp,
const char* konsole_dcop = "", const char* konsole_dcop_session = "" );
void setWriteable(bool writeable);
- QString error() { return m_strError; }
+ TQString error() { return m_strError; }
void setXonXoff(bool on);
void setSize(int lines, int cols);
void setErase(char erase);
@@ -112,7 +112,7 @@ Q_OBJECT
private:
- QString m_strError;
+ TQString m_strError;
struct SendJob {
SendJob() {}
@@ -120,10 +120,10 @@ Q_OBJECT
buffer.duplicate(b,len);
length = len;
}
- QMemArray<char> buffer;
+ TQMemArray<char> buffer;
int length;
};
- QValueList<SendJob> pendingSendJobs;
+ TQValueList<SendJob> pendingSendJobs;
bool m_bufferFull;
};
diff --git a/konsole/konsole/TEScreen.cpp b/konsole/konsole/TEScreen.cpp
index dba8ebd22..54b479844 100644
--- a/konsole/konsole/TEScreen.cpp
+++ b/konsole/konsole/TEScreen.cpp
@@ -422,7 +422,7 @@ void TEScreen::resizeImage(int new_lines, int new_columns)
// make new image
ca* newimg = new ca[(new_lines+1)*new_columns];
- QBitArray newwrapped(new_lines+1);
+ TQBitArray newwrapped(new_lines+1);
clearSelection();
// clear new image
@@ -599,9 +599,9 @@ ca* TEScreen::getCookedImage()
return merged;
}
-QBitArray TEScreen::getCookedLineWrapped()
+TQBitArray TEScreen::getCookedLineWrapped()
{
- QBitArray result(lines);
+ TQBitArray result(lines);
for (int y = 0; (y < lines) && (y < (hist->getLines()-histCursor)); y++)
result[y]=hist->isWrappedLine(y+histCursor);
@@ -775,12 +775,12 @@ void TEScreen::ShowCharacter(unsigned short c)
}
}
-void TEScreen::compose(QString compose)
+void TEScreen::compose(TQString compose)
{
if (lastPos == -1)
return;
- QChar c(image[lastPos].c);
+ TQChar c(image[lastPos].c);
compose.prepend(c);
compose.compose();
image[lastPos].c = compose[0].unicode();
@@ -1175,22 +1175,22 @@ static bool isSpace(UINT16 c)
return false;
if ((c == 32) || (c == 0))
return true;
- QChar qc(c);
+ TQChar qc(c);
return qc.isSpace();
}
-QString TEScreen::getSelText(bool preserve_line_breaks)
+TQString TEScreen::getSelText(bool preserve_line_breaks)
{
- QString result;
- QTextOStream stream(&result);
+ TQString result;
+ TQTextOStream stream(&result);
getSelText(preserve_line_breaks, &stream);
return result;
}
-static QString makeString(int *m, int d, bool stripTrailingSpaces)
+static TQString makeString(int *m, int d, bool stripTrailingSpaces)
{
- QChar* qc = new QChar[d];
+ TQChar* qc = new QChar[d];
int last_space = -1;
int j = 0;
@@ -1215,12 +1215,12 @@ static QString makeString(int *m, int d, bool stripTrailingSpaces)
j = last_space;
}
- QString res(qc, j);
+ TQString res(qc, j);
delete [] qc;
return res;
}
-void TEScreen::getSelText(bool preserve_line_breaks, QTextStream *stream)
+void TEScreen::getSelText(bool preserve_line_breaks, TQTextStream *stream)
{
if (sel_begin == -1)
return; // Selection got clear while selecting.
@@ -1446,7 +1446,7 @@ void TEScreen::getSelText(bool preserve_line_breaks, QTextStream *stream)
delete [] m;
}
-void TEScreen::streamHistory(QTextStream* stream) {
+void TEScreen::streamHistory(TQTextStream* stream) {
sel_begin = 0;
sel_BR = sel_begin;
sel_TL = sel_begin;
@@ -1455,7 +1455,7 @@ void TEScreen::streamHistory(QTextStream* stream) {
clearSelection();
}
-QString TEScreen::getHistoryLine(int no)
+TQString TEScreen::getHistoryLine(int no)
{
sel_begin = loc(0,no);
sel_TL = sel_begin;
diff --git a/konsole/konsole/TEScreen.h b/konsole/konsole/TEScreen.h
index 55cbcb07c..9797b53ab 100644
--- a/konsole/konsole/TEScreen.h
+++ b/konsole/konsole/TEScreen.h
@@ -139,13 +139,13 @@ public: // these are all `Screen' operations
void ShowCharacter(unsigned short c);
// Do composition with last shown character
- void compose(QString compose);
+ void compose(TQString compose);
//
void resizeImage(int new_lines, int new_columns);
//
ca* getCookedImage();
- QBitArray getCookedLineWrapped();
+ TQBitArray getCookedLineWrapped();
/*! return the number of lines. */
int getLines() { return lines; }
@@ -171,10 +171,10 @@ public: // these are all `Screen' operations
void setBusySelecting(bool busy) { sel_busy = busy; }
bool testIsSelected(const int x,const int y);
- QString getSelText(bool preserve_line_breaks);
- void getSelText(bool preserve_line_breaks, QTextStream* stream);
- void streamHistory(QTextStream* stream);
- QString getHistoryLine(int no);
+ TQString getSelText(bool preserve_line_breaks);
+ void getSelText(bool preserve_line_breaks, TQTextStream* stream);
+ void streamHistory(TQTextStream* stream);
+ TQString getHistoryLine(int no);
void checkSelection(int from, int to);
@@ -208,7 +208,7 @@ private: // helper
int lines;
int columns;
ca *image; // [lines][columns]
- QBitArray line_wrapped; // [lines]
+ TQBitArray line_wrapped; // [lines]
// history buffer ---------------
diff --git a/konsole/konsole/TEWidget.cpp b/konsole/konsole/TEWidget.cpp
index 03020a767..cb16ff497 100644
--- a/konsole/konsole/TEWidget.cpp
+++ b/konsole/konsole/TEWidget.cpp
@@ -55,14 +55,14 @@
#include "TEWidget.h"
#include "konsole_wcwidth.h"
-#include <qapplication.h>
-#include <qpainter.h>
-#include <qclipboard.h>
-#include <qstyle.h>
-#include <qfile.h>
-#include <qdragobject.h>
-#include <qlayout.h>
-#include <qregexp.h>
+#include <tqapplication.h>
+#include <tqpainter.h>
+#include <tqclipboard.h>
+#include <tqstyle.h>
+#include <tqfile.h>
+#include <tqdragobject.h>
+#include <tqlayout.h>
+#include <tqregexp.h>
#include <math.h>
#include <stdio.h>
@@ -82,8 +82,8 @@
#include <kshortcut.h>
#include <kurldrag.h>
#include <kio/netaccess.h>
-#include <qlabel.h>
-#include <qtimer.h>
+#include <tqlabel.h>
+#include <tqtimer.h>
#ifndef loc
#define loc(X,Y) ((Y)*columns+(X))
@@ -120,17 +120,17 @@ static const ColorEntry base_color_table[TABLE_COLORS] =
{
// Fixme: could add faint colors here, also.
// normal
- ColorEntry(QColor(0x00,0x00,0x00), 0, 0 ), ColorEntry( QColor(0xB2,0xB2,0xB2), 1, 0 ), // Dfore, Dback
- ColorEntry(QColor(0x00,0x00,0x00), 0, 0 ), ColorEntry( QColor(0xB2,0x18,0x18), 0, 0 ), // Black, Red
- ColorEntry(QColor(0x18,0xB2,0x18), 0, 0 ), ColorEntry( QColor(0xB2,0x68,0x18), 0, 0 ), // Green, Yellow
- ColorEntry(QColor(0x18,0x18,0xB2), 0, 0 ), ColorEntry( QColor(0xB2,0x18,0xB2), 0, 0 ), // Blue, Magenta
- ColorEntry(QColor(0x18,0xB2,0xB2), 0, 0 ), ColorEntry( QColor(0xB2,0xB2,0xB2), 0, 0 ), // Cyan, White
+ ColorEntry(TQColor(0x00,0x00,0x00), 0, 0 ), ColorEntry( TQColor(0xB2,0xB2,0xB2), 1, 0 ), // Dfore, Dback
+ ColorEntry(TQColor(0x00,0x00,0x00), 0, 0 ), ColorEntry( TQColor(0xB2,0x18,0x18), 0, 0 ), // Black, Red
+ ColorEntry(TQColor(0x18,0xB2,0x18), 0, 0 ), ColorEntry( TQColor(0xB2,0x68,0x18), 0, 0 ), // Green, Yellow
+ ColorEntry(TQColor(0x18,0x18,0xB2), 0, 0 ), ColorEntry( TQColor(0xB2,0x18,0xB2), 0, 0 ), // Blue, Magenta
+ ColorEntry(TQColor(0x18,0xB2,0xB2), 0, 0 ), ColorEntry( TQColor(0xB2,0xB2,0xB2), 0, 0 ), // Cyan, White
// intensiv
- ColorEntry(QColor(0x00,0x00,0x00), 0, 1 ), ColorEntry( QColor(0xFF,0xFF,0xFF), 1, 0 ),
- ColorEntry(QColor(0x68,0x68,0x68), 0, 0 ), ColorEntry( QColor(0xFF,0x54,0x54), 0, 0 ),
- ColorEntry(QColor(0x54,0xFF,0x54), 0, 0 ), ColorEntry( QColor(0xFF,0xFF,0x54), 0, 0 ),
- ColorEntry(QColor(0x54,0x54,0xFF), 0, 0 ), ColorEntry( QColor(0xFF,0x54,0xFF), 0, 0 ),
- ColorEntry(QColor(0x54,0xFF,0xFF), 0, 0 ), ColorEntry( QColor(0xFF,0xFF,0xFF), 0, 0 )
+ ColorEntry(TQColor(0x00,0x00,0x00), 0, 1 ), ColorEntry( TQColor(0xFF,0xFF,0xFF), 1, 0 ),
+ ColorEntry(TQColor(0x68,0x68,0x68), 0, 0 ), ColorEntry( TQColor(0xFF,0x54,0x54), 0, 0 ),
+ ColorEntry(TQColor(0x54,0xFF,0x54), 0, 0 ), ColorEntry( TQColor(0xFF,0xFF,0x54), 0, 0 ),
+ ColorEntry(TQColor(0x54,0x54,0xFF), 0, 0 ), ColorEntry( TQColor(0xFF,0x54,0xFF), 0, 0 ),
+ ColorEntry(TQColor(0x54,0xFF,0xFF), 0, 0 ), ColorEntry( TQColor(0xFF,0xFF,0xFF), 0, 0 )
};
/* Note that we use ANSI color order (bgr), while IBMPC color order is (rgb)
@@ -141,14 +141,14 @@ static const ColorEntry base_color_table[TABLE_COLORS] =
IBMPC (rgb) Black Blue Green Cyan Red Magenta Yellow White
*/
-void TEWidget::setDefaultBackColor(const QColor& color)
+void TEWidget::setDefaultBackColor(const TQColor& color)
{
defaultBgColor = color;
if (qAlpha(blend_color) != 0xff && !backgroundPixmap())
setBackgroundColor(getDefaultBackColor());
}
-QColor TEWidget::getDefaultBackColor()
+TQColor TEWidget::getDefaultBackColor()
{
if (defaultBgColor.isValid())
return defaultBgColor;
@@ -163,7 +163,7 @@ const ColorEntry* TEWidget::getColorTable() const
void TEWidget::setColorTable(const ColorEntry table[])
{
for (int i = 0; i < TABLE_COLORS; i++) color_table[i] = table[i];
- const QPixmap* pm = backgroundPixmap();
+ const TQPixmap* pm = backgroundPixmap();
if (!pm)
if (!argb_visual || (qAlpha(blend_color) == 0xff))
setBackgroundColor(getDefaultBackColor());
@@ -173,7 +173,7 @@ void TEWidget::setColorTable(const ColorEntry table[])
int(qRed(blend_color) * alpha) << 16 |
int(qGreen(blend_color) * alpha) << 8 |
int(qBlue(blend_color) * alpha);
- setBackgroundColor(QColor(blend_color, pixel));
+ setBackgroundColor(TQColor(blend_color, pixel));
}
update();
}
@@ -211,7 +211,7 @@ unsigned short vt100_graphics[32] =
};
/*
-static QChar vt100extended(QChar c)
+static TQChar vt100extended(TQChar c)
{
switch (c.unicode())
{
@@ -250,15 +250,15 @@ static QChar vt100extended(QChar c)
return c;
}
-static QChar identicalMap(QChar c)
+static TQChar identicalMap(TQChar c)
{
return c;
}
*/
-void TEWidget::fontChange(const QFont &)
+void TEWidget::fontChange(const TQFont &)
{
- QFontMetrics fm(font());
+ TQFontMetrics fm(font());
font_h = fm.height() + m_lineSpacing;
// waba TEWidget 1.123:
@@ -276,7 +276,7 @@ void TEWidget::fontChange(const QFont &)
}
}
- if (font_w>200) // don't trust unrealistic value, fallback to QFontMetrics::maxWidth()
+ if (font_w>200) // don't trust unrealistic value, fallback to TQFontMetrics::maxWidth()
font_w=fm.maxWidth();
if (font_w<1)
font_w=1;
@@ -303,23 +303,23 @@ void TEWidget::fontChange(const QFont &)
update();
}
-void TEWidget::setVTFont(const QFont& f)
+void TEWidget::setVTFont(const TQFont& f)
{
- QFont font = f;
+ TQFont font = f;
// the font must be small enough to allow at least one line and one character of text to fit
// on screen
- QFontMetrics metrics(f);
+ TQFontMetrics metrics(f);
if ( metrics.height() < height() && metrics.maxWidth() < width() )
{
if (!s_antialias)
- font.setStyleStrategy( QFont::NoAntialias );
- QFrame::setFont(font);
+ font.setStyleStrategy( TQFont::NoAntialias );
+ TQFrame::setFont(font);
fontChange(font);
}
}
-void TEWidget::setFont(const QFont &)
+void TEWidget::setFont(const TQFont &)
{
// ignore font change request if not coming from konsole itself
}
@@ -330,8 +330,8 @@ void TEWidget::setFont(const QFont &)
/* */
/* ------------------------------------------------------------------------- */
-TEWidget::TEWidget(QWidget *parent, const char *name)
-:QFrame(parent,name,WNoAutoErase)
+TEWidget::TEWidget(TQWidget *parent, const char *name)
+:TQFrame(parent,name,WNoAutoErase)
,font_h(1)
,font_w(1)
,font_a(1)
@@ -371,7 +371,7 @@ TEWidget::TEWidget(QWidget *parent, const char *name)
,colorsSwapped(false)
,rimX(1)
,rimY(1)
-,m_imPreeditText(QString::null)
+,m_imPreeditText(TQString::null)
,m_imPreeditLength(0)
,m_imStart(0)
,m_imStartLine(0)
@@ -389,18 +389,18 @@ TEWidget::TEWidget(QWidget *parent, const char *name)
// konsole in opaque mode.
bY = bX = 1;
- cb = QApplication::clipboard();
- QObject::connect( (QObject*)cb, SIGNAL(selectionChanged()),
- this, SLOT(onClearSelection()) );
+ cb = TQApplication::clipboard();
+ TQObject::connect( (TQObject*)cb, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(onClearSelection()) );
- scrollbar = new QScrollBar(this);
+ scrollbar = new TQScrollBar(this);
scrollbar->setCursor( arrowCursor );
- connect(scrollbar, SIGNAL(valueChanged(int)), this, SLOT(scrollChanged(int)));
+ connect(scrollbar, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(scrollChanged(int)));
- blinkT = new QTimer(this);
- connect(blinkT, SIGNAL(timeout()), this, SLOT(blinkEvent()));
- blinkCursorT = new QTimer(this);
- connect(blinkCursorT, SIGNAL(timeout()), this, SLOT(blinkCursorEvent()));
+ blinkT = new TQTimer(this);
+ connect(blinkT, TQT_SIGNAL(timeout()), this, TQT_SLOT(blinkEvent()));
+ blinkCursorT = new TQTimer(this);
+ connect(blinkCursorT, TQT_SIGNAL(timeout()), this, TQT_SLOT(blinkCursorEvent()));
setMouseMarks(true);
setColorTable(base_color_table); // init color table
@@ -488,7 +488,7 @@ enum LineEncode
#include "linefont.h"
-static void drawLineChar(QPainter& paint, int x, int y, int w, int h, uchar code)
+static void drawLineChar(TQPainter& paint, int x, int y, int w, int h, uchar code)
{
//Calculate cell midpoints, end points.
int cx = x + w/2;
@@ -554,10 +554,10 @@ static void drawLineChar(QPainter& paint, int x, int y, int w, int h, uchar code
}
-void TEWidget::drawTextFixed(QPainter &paint, int x, int y,
- QString& str, const ca *attr)
+void TEWidget::drawTextFixed(TQPainter &paint, int x, int y,
+ TQString& str, const ca *attr)
{
- QString drawstr;
+ TQString drawstr;
unsigned int nc=0;
int w;
for(unsigned int i=0;i<str.length();i++)
@@ -597,13 +597,13 @@ void TEWidget::drawTextFixed(QPainter &paint, int x, int y,
attributed string draw primitive
*/
-void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
- QString& str, const ca *attr, bool pm, bool clear)
+void TEWidget::drawAttrStr(TQPainter &paint, TQRect rect,
+ TQString& str, const ca *attr, bool pm, bool clear)
{
int a = font_a + m_lineSpacing / 2;
- QColor fColor = printerFriendly ? Qt::black : attr->f.color(color_table);
- QColor bColor = attr->b.color(color_table);
- QString drawstr;
+ TQColor fColor = printerFriendly ? Qt::black : attr->f.color(color_table);
+ TQColor bColor = attr->b.color(color_table);
+ TQString drawstr;
if ((attr->r & RE_CURSOR) && !isPrinting)
cursorRect = rect;
@@ -639,14 +639,14 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
col = a << 24 | r << 16 | g << 8 | b;
int pixel = a << 24 | (r * a / 255) << 16 | (g * a / 255) << 8 | (b * a / 255);
- paint.fillRect(rect, QColor(col, pixel));
+ paint.fillRect(rect, TQColor(col, pixel));
} else
paint.fillRect(rect, bColor);
}
- QString tmpStr = str.simplifyWhiteSpace();
+ TQString tmpStr = str.simplifyWhiteSpace();
if ( m_isIMEdit && !tmpStr.isEmpty() ) { // imput method edit area background color
- QRect tmpRect = rect;
+ TQRect tmpRect = rect;
if ( str != m_imPreeditText ) { // ugly hack
tmpRect.setLeft( tmpRect.left() + font_w );
tmpRect.setWidth( tmpRect.width() + font_w );
@@ -661,7 +661,7 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
int w = font_w * (m_imSelEnd - m_imSelStart);
int h = font_h;
- QRect tmpRect = QRect( x, y, w, h );
+ TQRect tmpRect = TQRect( x, y, w, h );
if ( str != m_imPreeditText ) { // ugly hack
tmpRect.setLeft( tmpRect.left() + font_w );
tmpRect.setWidth( tmpRect.width() + font_w );
@@ -675,7 +675,7 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
if ((attr->r & RE_CURSOR) && !isPrinting) {
paint.setBackgroundMode( TransparentMode );
int h = font_h - m_lineSpacing;
- QRect r(rect.x(),rect.y()+m_lineSpacing/2,rect.width(),h);
+ TQRect r(rect.x(),rect.y()+m_lineSpacing/2,rect.width(),h);
if (hasFocus())
{
if (!cursorBlinking)
@@ -705,14 +705,14 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
{
// When printing we use a bold font for bold
paint.save();
- QFont f = font();
+ TQFont f = font();
f.setBold(true);
paint.setFont(f);
}
if(!fixed_font)
{
- // The meaning of y differs between different versions of QPainter::drawText!!
+ // The meaning of y differs between different versions of TQPainter::drawText!!
int y = rect.y(); // top of rect
if ( shadow ) {
@@ -725,16 +725,16 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
}
else
{
- // The meaning of y differs between different versions of QPainter::drawText!!
+ // The meaning of y differs between different versions of TQPainter::drawText!!
int y = rect.y()+a; // baseline
if ( shadow ) {
paint.setPen( Qt::black );
- paint.drawText(x+1,y+1, str, -1, bidiEnabled ? QPainter::Auto : QPainter::LTR );
+ paint.drawText(x+1,y+1, str, -1, bidiEnabled ? TQPainter::Auto : TQPainter::LTR );
paint.setPen(fColor);
}
- paint.drawText(x,y, str, -1, bidiEnabled ? QPainter::Auto : QPainter::LTR );
+ paint.drawText(x,y, str, -1, bidiEnabled ? TQPainter::Auto : TQPainter::LTR );
}
if (attr->isBold(color_table) && isPrinting)
@@ -751,18 +751,18 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
int x = rect.x()+1;
if(!fixed_font)
{
- // The meaning of y differs between different versions of QPainter::drawText!!
+ // The meaning of y differs between different versions of TQPainter::drawText!!
int y = rect.y(); // top of rect
drawTextFixed(paint, x, y, str, attr);
}
else
{
- // The meaning of y differs between different versions of QPainter::drawText!!
+ // The meaning of y differs between different versions of TQPainter::drawText!!
int y = rect.y()+a; // baseline
if (bidiEnabled)
paint.drawText(x,y, str, -1);
else
- paint.drawText(x,y, str, -1, QPainter::LTR);
+ paint.drawText(x,y, str, -1, TQPainter::LTR);
}
paint.setClipping(false);
}
@@ -777,7 +777,7 @@ void TEWidget::drawAttrStr(QPainter &paint, QRect rect,
*/
void TEWidget::setCursorPos(const int curx, const int cury)
{
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
@@ -805,12 +805,12 @@ void TEWidget::setImage(const ca* const newimg, int lines, int columns)
updateImageSize(); // Create image
int y,x,len;
- const QPixmap* pm = backgroundPixmap();
- QPainter paint;
+ const TQPixmap* pm = backgroundPixmap();
+ TQPainter paint;
setUpdatesEnabled(false);
paint.begin( this );
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
hasBlinker = false;
@@ -821,7 +821,7 @@ void TEWidget::setImage(const ca* const newimg, int lines, int columns)
int lins = QMIN(this->lines, QMAX(0,lines ));
int cols = QMIN(this->columns,QMAX(0,columns));
- QChar *disstrU = new QChar[cols];
+ TQChar *disstrU = new QChar[cols];
char *dirtyMask = (char *) malloc(cols+2);
//{ static int cnt = 0; printf("setImage %d\n",cnt++); }
@@ -880,7 +880,7 @@ void TEWidget::setImage(const ca* const newimg, int lines, int columns)
disstrU[p++] = c; //fontMap(c);
}
- QString unistr(disstrU, p);
+ TQString unistr(disstrU, p);
// for XIM on the spot input style
m_isIMEdit = m_isIMSel = false;
@@ -905,7 +905,7 @@ void TEWidget::setImage(const ca* const newimg, int lines, int columns)
if (doubleWidth)
fixed_font = false;
drawAttrStr(paint,
- QRect(bX+tLx+font_w*x,bY+tLy+font_h*y,font_w*len,font_h),
+ TQRect(bX+tLx+font_w*x,bY+tLy+font_h*y,font_w*len,font_h),
unistr, &ext[x], pm != NULL, true);
fixed_font = save_fixed_font;
x += len - 1;
@@ -933,25 +933,25 @@ void TEWidget::setImage(const ca* const newimg, int lines, int columns)
}
if (!mResizeWidget)
{
- mResizeWidget = new QFrame(this);
- QFont f = KGlobalSettings::generalFont();
+ mResizeWidget = new TQFrame(this);
+ TQFont f = KGlobalSettings::generalFont();
int fs = f.pointSize();
if (fs == -1)
- fs = QFontInfo(f).pointSize();
+ fs = TQFontInfo(f).pointSize();
f.setPointSize((fs*3)/2);
f.setBold(true);
mResizeWidget->setFont(f);
- mResizeWidget->setFrameShape((QFrame::Shape) (QFrame::Box|QFrame::Raised));
+ mResizeWidget->setFrameShape((TQFrame::Shape) (TQFrame::Box|TQFrame::Raised));
mResizeWidget->setMidLineWidth(4);
- QBoxLayout *l = new QVBoxLayout( mResizeWidget, 10);
- mResizeLabel = new QLabel(i18n("Size: XXX x XXX"), mResizeWidget);
+ TQBoxLayout *l = new TQVBoxLayout( mResizeWidget, 10);
+ mResizeLabel = new TQLabel(i18n("Size: XXX x XXX"), mResizeWidget);
l->addWidget(mResizeLabel, 1, AlignCenter);
mResizeWidget->setMinimumWidth(mResizeLabel->fontMetrics().width(i18n("Size: XXX x XXX"))+20);
mResizeWidget->setMinimumHeight(mResizeLabel->sizeHint().height()+20);
- mResizeTimer = new QTimer(this);
- connect(mResizeTimer, SIGNAL(timeout()), mResizeWidget, SLOT(hide()));
+ mResizeTimer = new TQTimer(this);
+ connect(mResizeTimer, TQT_SIGNAL(timeout()), mResizeWidget, TQT_SLOT(hide()));
}
- QString sizeStr = i18n("Size: %1 x %2").arg(columns).arg(lines);
+ TQString sizeStr = i18n("Size: %1 x %2").arg(columns).arg(lines);
mResizeLabel->setText(sizeStr);
mResizeWidget->move((width()-mResizeWidget->width())/2,
(height()-mResizeWidget->height())/2+20);
@@ -982,10 +982,10 @@ void TEWidget::setBlinkingCursor(bool blink)
image is used and the painting bound by the PaintEvent box.
*/
-void TEWidget::paintEvent( QPaintEvent* pe )
+void TEWidget::paintEvent( TQPaintEvent* pe )
{
- const QPixmap* pm = backgroundPixmap();
- QPainter paint;
+ const TQPixmap* pm = backgroundPixmap();
+ TQPainter paint;
setUpdatesEnabled(false);
paint.begin( this );
paint.setBackgroundMode( TransparentMode );
@@ -996,7 +996,7 @@ void TEWidget::paintEvent( QPaintEvent* pe )
// can thus be larger than the image, but less then the size
// of one character.
- QRect rect = pe->rect().intersect(contentsRect());
+ TQRect rect = pe->rect().intersect(contentsRect());
paintContents(paint, rect, pm != 0);
@@ -1008,7 +1008,7 @@ void TEWidget::paintEvent( QPaintEvent* pe )
// area between the terminal image and the frame border.
// Calculate the contents rect excluding scroll bar.
- QRect innerRect = contentsRect();
+ TQRect innerRect = contentsRect();
if( scrollLoc != SCRNONE )
innerRect.setWidth( innerRect.width() - scrollbar->width() );
@@ -1016,12 +1016,12 @@ void TEWidget::paintEvent( QPaintEvent* pe )
innerRect.setHeight( innerRect.height() );
// Calculate the emulation rect (area needed for actual terminal contents)
- QRect emurect( contentsRect().topLeft(), QSize( columns * font_w + 2 * rimX, lines * font_h + 2 * rimY ));
+ TQRect emurect( contentsRect().topLeft(), TQSize( columns * font_w + 2 * rimX, lines * font_h + 2 * rimY ));
// Now erase() the remaining pixels on all sides of the emulation
// Top
- QRect er( innerRect );
+ TQRect er( innerRect );
er.setBottom( emurect.top() );
erase( er );
@@ -1047,7 +1047,7 @@ void TEWidget::paintEvent( QPaintEvent* pe )
setUpdatesEnabled(true);
}
-void TEWidget::print(QPainter &paint, bool friendly, bool exact)
+void TEWidget::print(TQPainter &paint, bool friendly, bool exact)
{
bool save_fixed_font = fixed_font;
bool save_blinking = blinking;
@@ -1061,10 +1061,10 @@ void TEWidget::print(QPainter &paint, bool friendly, bool exact)
if (exact)
{
- QPixmap pm(contentsRect().right(), contentsRect().bottom());
+ TQPixmap pm(contentsRect().right(), contentsRect().bottom());
pm.fill();
- QPainter pm_paint;
+ TQPainter pm_paint;
pm_paint.begin(&pm, this);
paintContents(pm_paint, contentsRect(), true);
pm_paint.end();
@@ -1083,9 +1083,9 @@ void TEWidget::print(QPainter &paint, bool friendly, bool exact)
blinking = save_blinking;
}
-void TEWidget::paintContents(QPainter &paint, const QRect &rect, bool pm)
+void TEWidget::paintContents(TQPainter &paint, const TQRect &rect, bool pm)
{
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
@@ -1094,7 +1094,7 @@ void TEWidget::paintContents(QPainter &paint, const QRect &rect, bool pm)
int rlx = QMIN(columns-1, QMAX(0,(rect.right() - tLx - bX ) / font_w));
int rly = QMIN(lines-1, QMAX(0,(rect.bottom() - tLy - bY ) / font_h));
- QChar *disstrU = new QChar[columns];
+ TQChar *disstrU = new QChar[columns];
for (int y = luy; y <= rly; y++)
{
Q_UINT16 c = image[loc(lux,y)].c;
@@ -1136,9 +1136,9 @@ void TEWidget::paintContents(QPainter &paint, const QRect &rect, bool pm)
fixed_font = false;
if (doubleWidth)
fixed_font = false;
- QString unistr(disstrU,p);
+ TQString unistr(disstrU,p);
drawAttrStr(paint,
- QRect(bX+tLx+font_w*x,bY+tLy+font_h*y,font_w*len,font_h),
+ TQRect(bX+tLx+font_w*x,bY+tLy+font_h*y,font_w*len,font_h),
unistr, &image[loc(x,y)], pm, !(isBlinkEvent || isPrinting));
fixed_font = save_fixed_font;
}
@@ -1168,7 +1168,7 @@ void TEWidget::blinkCursorEvent()
/* */
/* ------------------------------------------------------------------------- */
-void TEWidget::resizeEvent(QResizeEvent*)
+void TEWidget::resizeEvent(TQResizeEvent*)
{
updateImageSize();
}
@@ -1178,7 +1178,7 @@ void TEWidget::propagateSize()
if (isFixedSize)
{
setSize(columns, lines);
- QFrame::setFixedSize(sizeHint());
+ TQFrame::setFixedSize(sizeHint());
parentWidget()->adjustSize();
parentWidget()->setFixedSize(parentWidget()->sizeHint());
return;
@@ -1226,13 +1226,13 @@ void TEWidget::scrollChanged(int)
void TEWidget::setScroll(int cursor, int slines)
{
//kdDebug(1211)<<"TEWidget::setScroll() disconnect()"<<endl;
- disconnect(scrollbar, SIGNAL(valueChanged(int)), this, SLOT(scrollChanged(int)));
+ disconnect(scrollbar, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(scrollChanged(int)));
//kdDebug(1211)<<"TEWidget::setScroll() setRange()"<<endl;
scrollbar->setRange(0,slines);
//kdDebug(1211)<<"TEWidget::setScroll() setSteps()"<<endl;
scrollbar->setSteps(1,lines);
scrollbar->setValue(cursor);
- connect(scrollbar, SIGNAL(valueChanged(int)), this, SLOT(scrollChanged(int)));
+ connect(scrollbar, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(scrollChanged(int)));
//kdDebug(1211)<<"TEWidget::setScroll() done"<<endl;
}
@@ -1279,7 +1279,7 @@ void TEWidget::setScrollbarLocation(int loc)
/*!
*/
-void TEWidget::mousePressEvent(QMouseEvent* ev)
+void TEWidget::mousePressEvent(TQMouseEvent* ev)
{
//printf("press [%d,%d] %d\n",ev->x()/font_w,ev->y()/font_h,ev->button());
@@ -1289,11 +1289,11 @@ void TEWidget::mousePressEvent(QMouseEvent* ev)
}
if ( !contentsRect().contains(ev->pos()) ) return;
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
- QPoint pos = QPoint((ev->x()-tLx-bX+(font_w/2))/font_w,(ev->y()-tLy-bY)/font_h);
+ TQPoint pos = TQPoint((ev->x()-tLx-bX+(font_w/2))/font_w,(ev->y()-tLy-bY)/font_h);
//printf("press top left [%d,%d] by=%d\n",tLx,tLy, bY);
if ( ev->button() == LeftButton)
@@ -1343,7 +1343,7 @@ void TEWidget::mousePressEvent(QMouseEvent* ev)
else if ( ev->button() == RightButton )
{
if (mouse_marks || (ev->state() & ShiftButton)) {
- configureRequestPoint = QPoint( ev->x(), ev->y() );
+ configureRequestPoint = TQPoint( ev->x(), ev->y() );
emit configureRequest( this, ev->state()&(ShiftButton|ControlButton), ev->x(), ev->y() );
}
else
@@ -1351,7 +1351,7 @@ void TEWidget::mousePressEvent(QMouseEvent* ev)
}
}
-void TEWidget::mouseMoveEvent(QMouseEvent* ev)
+void TEWidget::mouseMoveEvent(TQMouseEvent* ev)
{
// for auto-hiding the cursor, we need mouseTracking
if (ev->state() == NoButton ) return;
@@ -1388,10 +1388,10 @@ void TEWidget::setSelectionEnd()
extendSelection( configureRequestPoint );
}
-void TEWidget::extendSelection( QPoint pos )
+void TEWidget::extendSelection( TQPoint pos )
{
//if ( !contentsRect().contains(ev->pos()) ) return;
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
int scroll = scrollbar->value();
@@ -1401,7 +1401,7 @@ void TEWidget::extendSelection( QPoint pos )
// this widget.
// Adjust position within text area bounds. See FIXME above.
- QPoint oldpos = pos;
+ TQPoint oldpos = pos;
if ( pos.x() < tLx+bX ) pos.setX( tLx+bX );
if ( pos.x() > tLx+bX+columns*font_w-1 ) pos.setX( tLx+bX+columns*font_w );
if ( pos.y() < tLy+bY ) pos.setY( tLy+bY );
@@ -1419,11 +1419,11 @@ void TEWidget::extendSelection( QPoint pos )
scrollbar->setValue(scrollbar->value()-yMouseScroll); // scrollback
}
- QPoint here = QPoint((pos.x()-tLx-bX+(font_w/2))/font_w,(pos.y()-tLy-bY)/font_h);
- QPoint ohere;
- QPoint iPntSelCorr = iPntSel;
+ TQPoint here = TQPoint((pos.x()-tLx-bX+(font_w/2))/font_w,(pos.y()-tLy-bY)/font_h);
+ TQPoint ohere;
+ TQPoint iPntSelCorr = iPntSel;
iPntSelCorr.ry() -= scrollbar->value();
- QPoint pntSelCorr = pntSel;
+ TQPoint pntSelCorr = pntSel;
pntSelCorr.ry() -= scrollbar->value();
bool swapping = false;
@@ -1440,7 +1440,7 @@ void TEWidget::extendSelection( QPoint pos )
swapping = left_not_right != old_left_not_right;
// Find left (left_not_right ? from here : from start)
- QPoint left = left_not_right ? here : iPntSelCorr;
+ TQPoint left = left_not_right ? here : iPntSelCorr;
i = loc(left.x(),left.y());
if (i>=0 && i<=image_size) {
selClass = charClass(image[i].c);
@@ -1449,7 +1449,7 @@ void TEWidget::extendSelection( QPoint pos )
}
// Find left (left_not_right ? from start : from here)
- QPoint right = left_not_right ? iPntSelCorr : here;
+ TQPoint right = left_not_right ? iPntSelCorr : here;
i = loc(right.x(),right.y());
if (i>=0 && i<=image_size) {
selClass = charClass(image[i].c);
@@ -1474,8 +1474,8 @@ void TEWidget::extendSelection( QPoint pos )
// Extend to complete line
bool above_not_below = ( here.y() < iPntSelCorr.y() );
- QPoint above = above_not_below ? here : iPntSelCorr;
- QPoint below = above_not_below ? iPntSelCorr : here;
+ TQPoint above = above_not_below ? here : iPntSelCorr;
+ TQPoint below = above_not_below ? iPntSelCorr : here;
while (above.y()>0 && m_line_wrapped[above.y()-1])
above.ry()--;
@@ -1495,7 +1495,7 @@ void TEWidget::extendSelection( QPoint pos )
here = below; ohere = above;
}
- QPoint newSelBegin = QPoint( ohere.x(), ohere.y() );
+ TQPoint newSelBegin = TQPoint( ohere.x(), ohere.y() );
swapping = !(tripleSelBegin==newSelBegin);
tripleSelBegin = newSelBegin;
@@ -1515,10 +1515,10 @@ void TEWidget::extendSelection( QPoint pos )
swapping = left_not_right != old_left_not_right;
// Find left (left_not_right ? from here : from start)
- QPoint left = left_not_right ? here : iPntSelCorr;
+ TQPoint left = left_not_right ? here : iPntSelCorr;
// Find left (left_not_right ? from start : from here)
- QPoint right = left_not_right ? iPntSelCorr : here;
+ TQPoint right = left_not_right ? iPntSelCorr : here;
if ( right.x() > 0 && !column_selection_mode )
{
i = loc(right.x(),right.y());
@@ -1567,7 +1567,7 @@ void TEWidget::extendSelection( QPoint pos )
emit extendSelectionSignal( here.x()+offset, here.y() );
}
-void TEWidget::mouseReleaseEvent(QMouseEvent* ev)
+void TEWidget::mouseReleaseEvent(TQMouseEvent* ev)
{
//printf("release [%d,%d] %d\n",ev->x()/font_w,ev->y()/font_h,ev->button());
if ( ev->button() == LeftButton)
@@ -1588,7 +1588,7 @@ void TEWidget::mouseReleaseEvent(QMouseEvent* ev)
// outside the range. The procedure used in `mouseMoveEvent'
// applies here, too.
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
@@ -1602,7 +1602,7 @@ void TEWidget::mouseReleaseEvent(QMouseEvent* ev)
}
if ( !mouse_marks && ((ev->button() == RightButton && !(ev->state() & ShiftButton))
|| ev->button() == MidButton) ) {
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
@@ -1611,14 +1611,14 @@ void TEWidget::mouseReleaseEvent(QMouseEvent* ev)
}
}
-void TEWidget::mouseDoubleClickEvent(QMouseEvent* ev)
+void TEWidget::mouseDoubleClickEvent(TQMouseEvent* ev)
{
if ( ev->button() != LeftButton) return;
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
- QPoint pos = QPoint((ev->x()-tLx-bX)/font_w,(ev->y()-tLy-bY)/font_h);
+ TQPoint pos = TQPoint((ev->x()-tLx-bX)/font_w,(ev->y()-tLy-bY)/font_h);
// pass on double click as two clicks.
if (!mouse_marks && !(ev->state() & ShiftButton))
@@ -1631,8 +1631,8 @@ void TEWidget::mouseDoubleClickEvent(QMouseEvent* ev)
emit clearSelectionSignal();
- QPoint bgnSel = pos;
- QPoint endSel = pos;
+ TQPoint bgnSel = pos;
+ TQPoint endSel = pos;
int i = loc(bgnSel.x(),bgnSel.y());
iPntSel = bgnSel;
iPntSel.ry() += scrollbar->value();
@@ -1657,7 +1657,7 @@ void TEWidget::mouseDoubleClickEvent(QMouseEvent* ev)
endSel.setX(x);
// In word selection mode don't select @ (64) if at end of word.
- if ( ( QChar( image[i].c ) == '@' ) && ( ( endSel.x() - bgnSel.x() ) > 0 ) )
+ if ( ( TQChar( image[i].c ) == '@' ) && ( ( endSel.x() - bgnSel.x() ) > 0 ) )
endSel.setX( x - 1 );
actSel = 2; // within selection
@@ -1666,22 +1666,22 @@ void TEWidget::mouseDoubleClickEvent(QMouseEvent* ev)
}
possibleTripleClick=true;
- QTimer::singleShot(QApplication::doubleClickInterval(),this,SLOT(tripleClickTimeout()));
+ TQTimer::singleShot(TQApplication::doubleClickInterval(),this,TQT_SLOT(tripleClickTimeout()));
}
-void TEWidget::wheelEvent( QWheelEvent* ev )
+void TEWidget::wheelEvent( TQWheelEvent* ev )
{
if (ev->orientation() != Qt::Vertical)
return;
if ( mouse_marks )
- QApplication::sendEvent(scrollbar, ev);
+ TQApplication::sendEvent(scrollbar, ev);
else
{
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
- QPoint pos = QPoint((ev->x()-tLx-bX)/font_w,(ev->y()-tLy-bY)/font_h);
+ TQPoint pos = TQPoint((ev->x()-tLx-bX)/font_w,(ev->y()-tLy-bY)/font_h);
emit mouseSignal( ev->delta() > 0 ? 4 : 5, pos.x() + 1, pos.y() + 1 +scrollbar->value() -scrollbar->maxValue() );
}
}
@@ -1691,12 +1691,12 @@ void TEWidget::tripleClickTimeout()
possibleTripleClick=false;
}
-void TEWidget::mouseTripleClickEvent(QMouseEvent* ev)
+void TEWidget::mouseTripleClickEvent(TQMouseEvent* ev)
{
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
- iPntSel = QPoint((ev->x()-tLx-bX)/font_w,(ev->y()-tLy-bY)/font_h);
+ iPntSel = TQPoint((ev->x()-tLx-bX)/font_w,(ev->y()-tLy-bY)/font_h);
emit clearSelectionSignal();
@@ -1717,11 +1717,11 @@ void TEWidget::mouseTripleClickEvent(QMouseEvent* ev)
{ i--; if (x>0) x--; else {x=columns-1; iPntSel.ry()--;} }
emit beginSelectionSignal( x, iPntSel.y(), false );
- tripleSelBegin = QPoint( x, iPntSel.y() );
+ tripleSelBegin = TQPoint( x, iPntSel.y() );
}
else {
emit beginSelectionSignal( 0, iPntSel.y(), false );
- tripleSelBegin = QPoint( 0, iPntSel.y() );
+ tripleSelBegin = TQPoint( 0, iPntSel.y() );
}
while (iPntSel.y()<lines-1 && m_line_wrapped[iPntSel.y()])
@@ -1733,14 +1733,14 @@ void TEWidget::mouseTripleClickEvent(QMouseEvent* ev)
iPntSel.ry() += scrollbar->value();
}
-void TEWidget::focusInEvent( QFocusEvent * )
+void TEWidget::focusInEvent( TQFocusEvent * )
{
repaint(cursorRect, true); // *do* erase area, to get rid of the
// hollow cursor rectangle.
}
-void TEWidget::focusOutEvent( QFocusEvent * )
+void TEWidget::focusOutEvent( TQFocusEvent * )
{
repaint(cursorRect, true); // don't erase area
}
@@ -1750,13 +1750,13 @@ bool TEWidget::focusNextPrevChild( bool next )
if (next)
return false; // This disables changing the active part in konqueror
// when pressing Tab
- return QFrame::focusNextPrevChild( next );
+ return TQFrame::focusNextPrevChild( next );
}
int TEWidget::charClass(UINT16 ch) const
{
- QChar qch=QChar(ch);
+ TQChar qch=TQChar(ch);
if ( qch.isSpace() ) return ' ';
if ( qch.isLetterOrNumber() || word_characters.contains(qch, false) )
@@ -1766,7 +1766,7 @@ int TEWidget::charClass(UINT16 ch) const
return 1;
}
-void TEWidget::setWordCharacters(QString wc)
+void TEWidget::setWordCharacters(TQString wc)
{
word_characters = wc;
}
@@ -1785,10 +1785,10 @@ void TEWidget::setMouseMarks(bool on)
#undef KeyPress
-void TEWidget::emitText(QString text)
+void TEWidget::emitText(TQString text)
{
if (!text.isEmpty()) {
- QKeyEvent e(QEvent::KeyPress, 0,-1,0, text);
+ TQKeyEvent e(TQEvent::KeyPress, 0,-1,0, text);
emit keyPressedSignal(&e); // expose as a big fat keypress event
}
}
@@ -1796,33 +1796,33 @@ void TEWidget::emitText(QString text)
void TEWidget::emitSelection(bool useXselection,bool appendReturn)
// Paste Clipboard by simulating keypress events
{
- QApplication::clipboard()->setSelectionMode( useXselection );
- QString text = QApplication::clipboard()->text();
+ TQApplication::clipboard()->setSelectionMode( useXselection );
+ TQString text = TQApplication::clipboard()->text();
if(appendReturn)
text.append("\r");
if ( ! text.isEmpty() )
{
text.replace("\n", "\r");
- QKeyEvent e(QEvent::KeyPress, 0,-1,0, text);
+ TQKeyEvent e(TQEvent::KeyPress, 0,-1,0, text);
emit keyPressedSignal(&e); // expose as a big fat keypress event
emit clearSelectionSignal();
}
- QApplication::clipboard()->setSelectionMode( false );
+ TQApplication::clipboard()->setSelectionMode( false );
}
-void TEWidget::setSelection(const QString& t)
+void TEWidget::setSelection(const TQString& t)
{
// Disconnect signal while WE set the clipboard
- QClipboard *cb = QApplication::clipboard();
- QObject::disconnect( cb, SIGNAL(selectionChanged()),
- this, SLOT(onClearSelection()) );
+ QClipboard *cb = TQApplication::clipboard();
+ TQObject::disconnect( cb, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(onClearSelection()) );
cb->setSelectionMode( true );
cb->setText(t);
cb->setSelectionMode( false );
- QObject::connect( cb, SIGNAL(selectionChanged()),
- this, SLOT(onClearSelection()) );
+ TQObject::connect( cb, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(onClearSelection()) );
}
void TEWidget::copyClipboard()
@@ -1870,19 +1870,19 @@ void TEWidget::doScroll(int lines)
scrollbar->setValue(scrollbar->value()+lines);
}
-bool TEWidget::eventFilter( QObject *obj, QEvent *e )
+bool TEWidget::eventFilter( TQObject *obj, TQEvent *e )
{
- if ( (e->type() == QEvent::Accel ||
- e->type() == QEvent::AccelAvailable ) && qApp->focusWidget() == this )
+ if ( (e->type() == TQEvent::Accel ||
+ e->type() == TQEvent::AccelAvailable ) && qApp->focusWidget() == this )
{
- static_cast<QKeyEvent *>( e )->ignore();
+ static_cast<TQKeyEvent *>( e )->ignore();
return false;
}
if ( obj != this /* when embedded */ && obj != parent() /* when standalone */ )
return false; // not us
- if ( e->type() == QEvent::KeyPress )
+ if ( e->type() == TQEvent::KeyPress )
{
- QKeyEvent* ke = (QKeyEvent*)e;
+ TQKeyEvent* ke = (TQKeyEvent*)e;
actSel=0; // Key stroke implies a screen update, so TEWidget won't
// know where the current selection is.
@@ -1900,26 +1900,26 @@ bool TEWidget::eventFilter( QObject *obj, QEvent *e )
// in Qt2 when key events were propagated up the tree
// (unhandled? -> parent widget) they passed the event filter only once at
// the beginning. in qt3 this has changed, that is, the event filter is
- // called each time the event is sent (see loop in QApplication::notify,
+ // called each time the event is sent (see loop in TQApplication::notify,
// when internalNotify() is called for KeyPress, whereas internalNotify
// activates also the global event filter) . That's why we stop propagation
// here.
return true;
}
- if ( e->type() == QEvent::Enter )
+ if ( e->type() == TQEvent::Enter )
{
- QObject::disconnect( (QObject*)cb, SIGNAL(dataChanged()),
- this, SLOT(onClearSelection()) );
+ TQObject::disconnect( (TQObject*)cb, TQT_SIGNAL(dataChanged()),
+ this, TQT_SLOT(onClearSelection()) );
}
- if ( e->type() == QEvent::Leave )
+ if ( e->type() == TQEvent::Leave )
{
- QObject::connect( (QObject*)cb, SIGNAL(dataChanged()),
- this, SLOT(onClearSelection()) );
+ TQObject::connect( (TQObject*)cb, TQT_SIGNAL(dataChanged()),
+ this, TQT_SLOT(onClearSelection()) );
}
- return QFrame::eventFilter( obj, e );
+ return TQFrame::eventFilter( obj, e );
}
-void TEWidget::imStartEvent( QIMEvent */*e*/ )
+void TEWidget::imStartEvent( TQIMEvent */*e*/ )
{
m_imStart = m_cursorCol;
m_imStartLine = m_cursorLine;
@@ -1929,16 +1929,16 @@ void TEWidget::imStartEvent( QIMEvent */*e*/ )
m_isIMEdit = m_isIMSel = false;
}
-void TEWidget::imComposeEvent( QIMEvent *e )
+void TEWidget::imComposeEvent( TQIMEvent *e )
{
- QString text = QString::null;
+ TQString text = TQString::null;
if ( m_imPreeditLength > 0 ) {
text.fill( '\010', m_imPreeditLength );
}
m_imEnd = m_imStart + string_width( e->text() );
- QString tmpStr = e->text().left( e->cursorPos() );
+ TQString tmpStr = e->text().left( e->cursorPos() );
m_imSelStart = m_imStart + string_width( tmpStr );
tmpStr = e->text().mid( e->cursorPos(), e->selectionLength() );
@@ -1948,14 +1948,14 @@ void TEWidget::imComposeEvent( QIMEvent *e )
text += e->text();
if ( text.length() > 0 ) {
- QKeyEvent ke( QEvent::KeyPress, 0, -1, 0, text );
+ TQKeyEvent ke( TQEvent::KeyPress, 0, -1, 0, text );
emit keyPressedSignal( &ke );
}
}
-void TEWidget::imEndEvent( QIMEvent *e )
+void TEWidget::imEndEvent( TQIMEvent *e )
{
- QString text = QString::null;
+ TQString text = TQString::null;
if ( m_imPreeditLength > 0 ) {
text.fill( '\010', m_imPreeditLength );
}
@@ -1963,15 +1963,15 @@ void TEWidget::imEndEvent( QIMEvent *e )
m_imEnd = m_imSelStart = m_imSelEnd = 0;
text += e->text();
if ( text.length() > 0 ) {
- QKeyEvent ke( QEvent::KeyPress, 0, -1, 0, text );
+ TQKeyEvent ke( TQEvent::KeyPress, 0, -1, 0, text );
emit keyPressedSignal( &ke );
}
- QPoint tL = contentsRect().topLeft();
+ TQPoint tL = contentsRect().topLeft();
int tLx = tL.x();
int tLy = tL.y();
- QRect repaintRect = QRect( bX+tLx, bY+tLy+font_h*m_imStartLine,
+ TQRect repaintRect = TQRect( bX+tLx, bY+tLy+font_h*m_imStartLine,
contentsRect().width(), contentsRect().height() );
m_imStart = 0;
m_imPreeditLength = 0;
@@ -1982,11 +1982,11 @@ void TEWidget::imEndEvent( QIMEvent *e )
// Override any Ctrl+<key> accelerator when pressed with the keyboard
// focus in TEWidget, so that the key will be passed to the terminal instead.
-bool TEWidget::event( QEvent *e )
+bool TEWidget::event( TQEvent *e )
{
- if ( e->type() == QEvent::AccelOverride )
+ if ( e->type() == TQEvent::AccelOverride )
{
- QKeyEvent *ke = static_cast<QKeyEvent *>( e );
+ TQKeyEvent *ke = static_cast<TQKeyEvent *>( e );
KKey key( ke );
int keyCodeQt = key.keyCodeQt();
@@ -2005,7 +2005,7 @@ bool TEWidget::event( QEvent *e )
return true;
}
}
- return QFrame::event( e );
+ return TQFrame::event( e );
}
/* ------------------------------------------------------------------------- */
@@ -2031,7 +2031,7 @@ void TEWidget::setBellMode(int mode)
m_bellMode=mode;
}
-void TEWidget::Bell(bool visibleSession, QString message)
+void TEWidget::Bell(bool visibleSession, TQString message)
{
if (bellTimer.isActive())
return;
@@ -2060,7 +2060,7 @@ void TEWidget::Bell(bool visibleSession, QString message)
bellTimer.start(BELLVISUAL_DELAY,true);
swapColorTable();
- QTimer::singleShot(200,this,SLOT(swapColorTable()));
+ TQTimer::singleShot(200,this,TQT_SLOT(swapColorTable()));
}
}
@@ -2097,7 +2097,7 @@ void TEWidget::clearImage()
void TEWidget::calcGeometry()
{
- scrollbar->resize(QApplication::style().pixelMetric(QStyle::PM_ScrollBarExtent),
+ scrollbar->resize(TQApplication::style().pixelMetric(TQStyle::PM_ScrollBarExtent),
contentsRect().height());
switch(scrollLoc)
{
@@ -2115,7 +2115,7 @@ void TEWidget::calcGeometry()
case SCRRIGHT:
bX = rimX;
contentWidth = contentsRect().width() - 2 * rimX - scrollbar->width();
- scrollbar->move(contentsRect().topRight() - QPoint(scrollbar->width()-1,0));
+ scrollbar->move(contentsRect().topRight() - TQPoint(scrollbar->width()-1,0));
scrollbar->show();
break;
}
@@ -2152,7 +2152,7 @@ void TEWidget::setSize(int cols, int lins)
int frw = width() - contentsRect().width();
int frh = height() - contentsRect().height();
int scw = (scrollLoc==SCRNONE?0:scrollbar->width());
- m_size = QSize(font_w*cols + 2*rimX + frw + scw, font_h*lins + 2*rimY + frh + /* mysterious */ 1);
+ m_size = TQSize(font_w*cols + 2*rimX + frw + scw, font_h*lins + 2*rimY + frh + /* mysterious */ 1);
updateGeometry();
}
@@ -2167,15 +2167,15 @@ void TEWidget::setFixedSize(int cols, int lins)
makeImage();
}
setSize(cols, lins);
- QFrame::setFixedSize(m_size);
+ TQFrame::setFixedSize(m_size);
}
-QSize TEWidget::sizeHint() const
+TQSize TEWidget::sizeHint() const
{
return m_size;
}
-void TEWidget::styleChange(QStyle &)
+void TEWidget::styleChange(TQStyle &)
{
propagateSize();
}
@@ -2187,15 +2187,15 @@ void TEWidget::styleChange(QStyle &)
/* */
/* --------------------------------------------------------------------- */
-void TEWidget::dragEnterEvent(QDragEnterEvent* e)
+void TEWidget::dragEnterEvent(TQDragEnterEvent* e)
{
- e->accept(QTextDrag::canDecode(e) ||
+ e->accept(TQTextDrag::canDecode(e) ||
KURLDrag::canDecode(e));
}
enum dropPopupOptions { paste, cd, cp, ln, mv };
-void TEWidget::dropEvent(QDropEvent* event)
+void TEWidget::dropEvent(TQDropEvent* event)
{
if (m_drop==0)
{
@@ -2206,7 +2206,7 @@ void TEWidget::dropEvent(QDropEvent* event)
m_drop->insertItem( "cp", cp );
m_drop->insertItem( "ln", ln );
m_drop->insertItem( "mv", mv );
- connect(m_drop, SIGNAL(activated(int)), SLOT(drop_menu_activated(int)));
+ connect(m_drop, TQT_SIGNAL(activated(int)), TQT_SLOT(drop_menu_activated(int)));
};
// The current behaviour when url(s) are dropped is
// * if there is only ONE url and if it's a LOCAL one, ask for paste or cd/cp/ln/mv
@@ -2232,10 +2232,10 @@ void TEWidget::dropEvent(QDropEvent* event)
m_drop->setItemEnabled(cd,false);
}
KURL url = KIO::NetAccess::mostLocalURL( *it, 0 );
- QString tmp;
+ TQString tmp;
if (url.isLocalFile()) {
tmp = url.path(); // local URL : remove protocol. This helps "ln" & "cd" and doesn't harm the others
- } else if ( url.protocol() == QString::fromLatin1( "mailto" ) ) {
+ } else if ( url.protocol() == TQString::fromLatin1( "mailto" ) ) {
justPaste = true;
break;
} else {
@@ -2251,7 +2251,7 @@ void TEWidget::dropEvent(QDropEvent* event)
if (!justPaste) m_drop->popup(mapToGlobal(event->pos()));
}
}
- if(justPaste && QTextDrag::decode(event, dropText)) {
+ if(justPaste && TQTextDrag::decode(event, dropText)) {
kdDebug(1211) << "Drop:" << dropText.local8Bit() << "\n";
emit sendStringToEmu(dropText.local8Bit());
// Paste it
@@ -2261,9 +2261,9 @@ void TEWidget::dropEvent(QDropEvent* event)
void TEWidget::doDrag()
{
dragInfo.state = diDragging;
- dragInfo.dragObject = new QTextDrag(QApplication::clipboard()->text(QClipboard::Selection), this);
+ dragInfo.dragObject = new TQTextDrag(TQApplication::clipboard()->text(QClipboard::Selection), this);
dragInfo.dragObject->dragCopy();
- // Don't delete the QTextDrag object. Qt will delete it when it's done with it.
+ // Don't delete the TQTextDrag object. Qt will delete it when it's done with it.
}
void TEWidget::drop_menu_activated(int item)
@@ -2279,7 +2279,7 @@ void TEWidget::drop_menu_activated(int item)
case cd:
emit sendStringToEmu("cd ");
struct stat statbuf;
- if ( ::stat( QFile::encodeName( dropText ), &statbuf ) == 0 )
+ if ( ::stat( TQFile::encodeName( dropText ), &statbuf ) == 0 )
{
if ( !S_ISDIR(statbuf.st_mode) )
{
diff --git a/konsole/konsole/TEWidget.h b/konsole/konsole/TEWidget.h
index bb4d2c610..35794167a 100644
--- a/konsole/konsole/TEWidget.h
+++ b/konsole/konsole/TEWidget.h
@@ -21,12 +21,12 @@
#ifndef TE_WIDGET_H
#define TE_WIDGET_H
-#include <qbitarray.h>
-#include <qwidget.h>
-#include <qcolor.h>
-#include <qkeycode.h>
-#include <qtimer.h>
-#include <qscrollbar.h>
+#include <tqbitarray.h>
+#include <tqwidget.h>
+#include <tqcolor.h>
+#include <tqkeycode.h>
+#include <tqtimer.h>
+#include <tqscrollbar.h>
#include <kpopupmenu.h>
@@ -47,13 +47,13 @@ class TEWidget : public QFrame
friend class Konsole;
public:
- TEWidget(QWidget *parent=0, const char *name=0);
+ TEWidget(TQWidget *parent=0, const char *name=0);
virtual ~TEWidget();
void setBlendColor(const QRgb color) { blend_color = color; }
- void setDefaultBackColor(const QColor& color);
- QColor getDefaultBackColor();
+ void setDefaultBackColor(const TQColor& color);
+ TQColor getDefaultBackColor();
const ColorEntry* getColorTable() const;
void setColorTable(const ColorEntry table[]);
@@ -78,10 +78,10 @@ public:
uint lineSpacing() const;
void emitSelection(bool useXselection,bool appendReturn);
- void emitText(QString text);
+ void emitText(TQString text);
void setImage(const ca* const newimg, int lines, int columns);
- void setLineWrapped(QBitArray line_wrapped) { m_line_wrapped=line_wrapped; }
+ void setLineWrapped(TQBitArray line_wrapped) { m_line_wrapped=line_wrapped; }
void setCursorPos(const int curx, const int cury);
@@ -96,32 +96,32 @@ public:
void updateImageSize();
void setSize(int cols, int lins);
void setFixedSize(int cols, int lins);
- QSize sizeHint() const;
+ TQSize sizeHint() const;
- void setWordCharacters(QString wc);
- QString wordCharacters() { return word_characters; }
+ void setWordCharacters(TQString wc);
+ TQString wordCharacters() { return word_characters; }
void setBellMode(int mode);
int bellMode() { return m_bellMode; }
enum { BELLSYSTEM=0, BELLNOTIFY=1, BELLVISUAL=2, BELLNONE=3 };
- void Bell(bool visibleSession, QString message);
+ void Bell(bool visibleSession, TQString message);
- void setSelection(const QString &t);
+ void setSelection(const TQString &t);
/**
* Reimplemented. Has no effect. Use setVTFont() to change the font
* used to draw characters in the display.
*/
- virtual void setFont(const QFont &);
+ virtual void setFont(const TQFont &);
/** Returns the font used to draw characters in the display */
- QFont getVTFont() { return font(); }
+ TQFont getVTFont() { return font(); }
/**
* Sets the font used to draw the display. Has no effect if @p font
* is larger than the size of the display itself.
*/
- void setVTFont(const QFont& font);
+ void setVTFont(const TQFont& font);
void setMouseMarks(bool on);
static void setAntialias( bool enable ) { s_antialias = enable; }
@@ -136,7 +136,7 @@ public:
void setBidiEnabled(bool set) { bidiEnabled=set; }
bool isBidiEnabled() { return bidiEnabled; }
- void print(QPainter &paint, bool friendly, bool exact);
+ void print(TQPainter &paint, bool friendly, bool exact);
void setRim(int rim) { rimX=rim; rimY=rim; }
@@ -150,7 +150,7 @@ public slots:
signals:
- void keyPressedSignal(QKeyEvent *e);
+ void keyPressedSignal(TQKeyEvent *e);
void mouseSignal(int cb, int cx, int cy);
void changedFontMetricSignal(int height, int width);
void changedContentSizeSignal(int height, int width);
@@ -168,56 +168,56 @@ signals:
protected:
- virtual void styleChange( QStyle& );
+ virtual void styleChange( TQStyle& );
- bool eventFilter( QObject *, QEvent * );
- bool event( QEvent * );
+ bool eventFilter( TQObject *, TQEvent * );
+ bool event( TQEvent * );
- void drawTextFixed(QPainter &paint, int x, int y,
- QString& str, const ca *attr);
+ void drawTextFixed(TQPainter &paint, int x, int y,
+ TQString& str, const ca *attr);
- void drawAttrStr(QPainter &paint, QRect rect,
- QString& str, const ca *attr, bool pm, bool clear);
- void paintEvent( QPaintEvent * );
+ void drawAttrStr(TQPainter &paint, TQRect rect,
+ TQString& str, const ca *attr, bool pm, bool clear);
+ void paintEvent( TQPaintEvent * );
- void paintContents(QPainter &paint, const QRect &rect, bool pm=false);
+ void paintContents(TQPainter &paint, const TQRect &rect, bool pm=false);
- void resizeEvent(QResizeEvent*);
+ void resizeEvent(TQResizeEvent*);
- void fontChange(const QFont &font);
+ void fontChange(const TQFont &font);
void frameChanged();
- void mouseDoubleClickEvent(QMouseEvent* ev);
- void mousePressEvent( QMouseEvent* );
- void mouseReleaseEvent( QMouseEvent* );
- void mouseMoveEvent( QMouseEvent* );
- void extendSelection( QPoint pos );
- void wheelEvent( QWheelEvent* );
+ void mouseDoubleClickEvent(TQMouseEvent* ev);
+ void mousePressEvent( TQMouseEvent* );
+ void mouseReleaseEvent( TQMouseEvent* );
+ void mouseMoveEvent( TQMouseEvent* );
+ void extendSelection( TQPoint pos );
+ void wheelEvent( TQWheelEvent* );
- void focusInEvent( QFocusEvent * );
- void focusOutEvent( QFocusEvent * );
+ void focusInEvent( TQFocusEvent * );
+ void focusOutEvent( TQFocusEvent * );
bool focusNextPrevChild( bool next );
// Dnd
- void dragEnterEvent(QDragEnterEvent* event);
- void dropEvent(QDropEvent* event);
+ void dragEnterEvent(TQDragEnterEvent* event);
+ void dropEvent(TQDropEvent* event);
void doDrag();
enum DragState { diNone, diPending, diDragging };
struct _dragInfo {
DragState state;
- QPoint start;
- QTextDrag *dragObject;
+ TQPoint start;
+ TQTextDrag *dragObject;
} dragInfo;
virtual int charClass(UINT16) const;
void clearImage();
- void mouseTripleClickEvent(QMouseEvent* ev);
+ void mouseTripleClickEvent(TQMouseEvent* ev);
- void imStartEvent( QIMEvent *e );
- void imComposeEvent( QIMEvent *e );
- void imEndEvent( QIMEvent *e );
+ void imStartEvent( TQIMEvent *e );
+ void imComposeEvent( TQIMEvent *e );
+ void imEndEvent( TQIMEvent *e );
protected slots:
@@ -227,7 +227,7 @@ protected slots:
private:
-// QChar (*fontMap)(QChar); // possible vt100 font extension
+// TQChar (*fontMap)(TQChar); // possible vt100 font extension
bool fixed_font; // has fixed pitch
int font_h; // height
@@ -243,10 +243,10 @@ private:
int contentWidth;
ca *image; // [lines][columns]
int image_size;
- QBitArray m_line_wrapped;
+ TQBitArray m_line_wrapped;
ColorEntry color_table[TABLE_COLORS];
- QColor defaultBgColor;
+ TQColor defaultBgColor;
bool resizing;
bool terminalSizeHint,terminalSizeStartup;
@@ -255,9 +255,9 @@ private:
void makeImage();
- QPoint iPntSel; // initial selection point
- QPoint pntSel; // current selection point
- QPoint tripleSelBegin; // help avoid flicker
+ TQPoint iPntSel; // initial selection point
+ TQPoint pntSel; // current selection point
+ TQPoint tripleSelBegin; // help avoid flicker
int actSel; // selection state
bool word_selection_mode;
bool line_selection_mode;
@@ -265,10 +265,10 @@ private:
bool column_selection_mode;
QClipboard* cb;
- QScrollBar* scrollbar;
+ TQScrollBar* scrollbar;
int scrollLoc;
- QString word_characters;
- QTimer bellTimer; //used to rate-limit bell events. started when a bell event occurs,
+ TQString word_characters;
+ TQTimer bellTimer; //used to rate-limit bell events. started when a bell event occurs,
//and prevents further bell events until it stops
int m_bellMode;
@@ -283,36 +283,36 @@ private:
bool printerFriendly; // paint printer friendly, save ink
bool printerBold; // Use a bold font instead of overstrike for bold
bool isFixedSize; //Columns / lines are locked.
- QTimer* blinkT; // active when hasBlinker
- QTimer* blinkCursorT; // active when hasBlinkingCursor
+ TQTimer* blinkT; // active when hasBlinker
+ TQTimer* blinkCursorT; // active when hasBlinkingCursor
KPopupMenu* m_drop;
- QString dropText;
+ TQString dropText;
int m_dnd_file_count;
bool possibleTripleClick; // is set in mouseDoubleClickEvent and deleted
- // after QApplication::doubleClickInterval() delay
+ // after TQApplication::doubleClickInterval() delay
static bool s_antialias; // do we antialias or not
static bool s_standalone; // are we part of a standalone konsole?
- QFrame *mResizeWidget;
- QLabel *mResizeLabel;
- QTimer *mResizeTimer;
+ TQFrame *mResizeWidget;
+ TQLabel *mResizeLabel;
+ TQTimer *mResizeTimer;
uint m_lineSpacing;
- QRect cursorRect; //for quick changing of cursor
+ TQRect cursorRect; //for quick changing of cursor
- QPoint configureRequestPoint; // remember right mouse button click position
+ TQPoint configureRequestPoint; // remember right mouse button click position
bool colorsSwapped; // true during visual bell
// the rim should normally be 1, 0 only when running in full screen mode.
int rimX; // left/right rim width
int rimY; // top/bottom rim high
- QSize m_size;
+ TQSize m_size;
- QString m_imPreeditText;
+ TQString m_imPreeditText;
int m_imPreeditLength;
int m_imStart;
int m_imStartLine;
diff --git a/konsole/konsole/TEmuVt102.cpp b/konsole/konsole/TEmuVt102.cpp
index 47207de34..0bdb0f42c 100644
--- a/konsole/konsole/TEmuVt102.cpp
+++ b/konsole/konsole/TEmuVt102.cpp
@@ -81,10 +81,10 @@
TEmuVt102::TEmuVt102(TEWidget* gui) : TEmulation(gui)
{
//kdDebug(1211)<<"TEmuVt102 ctor() connecting"<<endl;
- QObject::connect(gui,SIGNAL(mouseSignal(int,int,int)),
- this,SLOT(onMouse(int,int,int)));
- QObject::connect(gui, SIGNAL(sendStringToEmu(const char*)),
- this, SLOT(sendString(const char*)));
+ TQObject::connect(gui,TQT_SIGNAL(mouseSignal(int,int,int)),
+ this,TQT_SLOT(onMouse(int,int,int)));
+ TQObject::connect(gui, TQT_SIGNAL(sendStringToEmu(const char*)),
+ this, TQT_SLOT(sendString(const char*)));
//kdDebug(1211)<<"TEmuVt102 ctor() initToken..."<<endl;
initTokenizer();
//kdDebug(1211)<<"TEmuVt102 ctor() reset()"<<endl;
@@ -100,16 +100,16 @@ void TEmuVt102::changeGUI(TEWidget* newgui)
if (static_cast<TEWidget *>( gui )==newgui) return;
if ( gui ) {
- QObject::disconnect(gui,SIGNAL(mouseSignal(int,int,int)),
- this,SLOT(onMouse(int,int,int)));
- QObject::disconnect(gui, SIGNAL(sendStringToEmu(const char*)),
- this, SLOT(sendString(const char*)));
+ TQObject::disconnect(gui,TQT_SIGNAL(mouseSignal(int,int,int)),
+ this,TQT_SLOT(onMouse(int,int,int)));
+ TQObject::disconnect(gui, TQT_SIGNAL(sendStringToEmu(const char*)),
+ this, TQT_SLOT(sendString(const char*)));
}
TEmulation::changeGUI(newgui);
- QObject::connect(gui,SIGNAL(mouseSignal(int,int,int)),
- this,SLOT(onMouse(int,int,int)));
- QObject::connect(gui, SIGNAL(sendStringToEmu(const char*)),
- this, SLOT(sendString(const char*)));
+ TQObject::connect(gui,TQT_SIGNAL(mouseSignal(int,int,int)),
+ this,TQT_SLOT(onMouse(int,int,int)));
+ TQObject::connect(gui, TQT_SIGNAL(sendStringToEmu(const char*)),
+ this, TQT_SLOT(sendString(const char*)));
}
/*!
@@ -382,9 +382,9 @@ void TEmuVt102::XtermHack()
for (i = 2; i < ppos && '0'<=pbuf[i] && pbuf[i]<'9' ; i++)
arg = 10*arg + (pbuf[i]-'0');
if (pbuf[i] != ';') { ReportErrorToken(); return; }
- QChar *str = new QChar[ppos-i-2];
+ TQChar *str = new QChar[ppos-i-2];
for (int j = 0; j < ppos-i-2; j++) str[j] = pbuf[i+1+j];
- QString unistr(str,ppos-i-2);
+ TQString unistr(str,ppos-i-2);
// arg == 1 doesn't change the title. In XTerm it only changes the icon name
// (btw: arg=0 changes title and icon, arg=1 only icon, arg=2 only title
emit changeTitle(arg,unistr);
@@ -927,7 +927,7 @@ void TEmuVt102::onScrollLock()
the complications towards a configuration file [see KeyTrans class].
*/
-void TEmuVt102::onKeyPress( QKeyEvent* ev )
+void TEmuVt102::onKeyPress( TQKeyEvent* ev )
{
if (!listenToKeyPress) return; // someone else gets the keys
emit notifySessionState(NOTIFYNORMAL);
@@ -986,8 +986,8 @@ void TEmuVt102::onKeyPress( QKeyEvent* ev )
if (!ev->text().isEmpty())
{
if (ev->state() & AltButton) sendString("\033"); // ESC, this is the ALT prefix
- QCString s = m_codec->fromUnicode(ev->text()); // encode for application
- // FIXME: In Qt 2, QKeyEvent::text() would return "\003" for Ctrl-C etc.
+ TQCString s = m_codec->fromUnicode(ev->text()); // encode for application
+ // FIXME: In Qt 2, TQKeyEvent::text() would return "\003" for Ctrl-C etc.
// while in Qt 3 it returns the actual key ("c" or "C") which caused
// the ControlButton to be ignored. This hack seems to work for
// latin1 locales at least. Please anyone find a clean solution (malte)
@@ -1195,8 +1195,8 @@ void TEmuVt102::setConnect(bool c)
TEmulation::setConnect(c);
if (gui)
{
- QObject::disconnect(gui, SIGNAL(sendStringToEmu(const char*)),
- this, SLOT(sendString(const char*)));
+ TQObject::disconnect(gui, TQT_SIGNAL(sendStringToEmu(const char*)),
+ this, TQT_SLOT(sendString(const char*)));
}
if (c)
{ // refresh mouse mode
@@ -1210,8 +1210,8 @@ void TEmuVt102::setConnect(bool c)
else
scrolllock_set_off();
#endif
- QObject::connect(gui, SIGNAL(sendStringToEmu(const char*)),
- this, SLOT(sendString(const char*)));
+ TQObject::connect(gui, TQT_SIGNAL(sendStringToEmu(const char*)),
+ this, TQT_SLOT(sendString(const char*)));
}
}
diff --git a/konsole/konsole/TEmuVt102.h b/konsole/konsole/TEmuVt102.h
index cd49cc089..05f30ac04 100644
--- a/konsole/konsole/TEmuVt102.h
+++ b/konsole/konsole/TEmuVt102.h
@@ -60,14 +60,14 @@ public:
void changeGUI(TEWidget* newgui);
~TEmuVt102();
- virtual void onKeyPress(QKeyEvent*);
+ virtual void onKeyPress(TQKeyEvent*);
public slots: // signals incoming from TEWidget
void onMouse(int cb, int cx, int cy);
signals:
- void changeTitle(int,const QString&);
+ void changeTitle(int,const TQString&);
public:
diff --git a/konsole/konsole/TEmulation.cpp b/konsole/konsole/TEmulation.cpp
index 0ff2a5163..8dd6da437 100644
--- a/konsole/konsole/TEmulation.cpp
+++ b/konsole/konsole/TEmulation.cpp
@@ -75,8 +75,8 @@
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
-#include <qregexp.h>
-#include <qclipboard.h>
+#include <tqregexp.h>
+#include <tqclipboard.h>
#include <assert.h>
@@ -108,8 +108,8 @@ TEmulation::TEmulation(TEWidget* w)
screen[1] = new TEScreen(gui->Lines(),gui->Columns());
scr = screen[0];
- QObject::connect(&bulk_timer1, SIGNAL(timeout()), this, SLOT(showBulk()) );
- QObject::connect(&bulk_timer2, SIGNAL(timeout()), this, SLOT(showBulk()) );
+ TQObject::connect(&bulk_timer1, TQT_SIGNAL(timeout()), this, TQT_SLOT(showBulk()) );
+ TQObject::connect(&bulk_timer2, TQT_SIGNAL(timeout()), this, TQT_SLOT(showBulk()) );
connectGUI();
setKeymap(0); // Default keymap
}
@@ -119,24 +119,24 @@ TEmulation::TEmulation(TEWidget* w)
void TEmulation::connectGUI()
{
- QObject::connect(gui,SIGNAL(changedHistoryCursor(int)),
- this,SLOT(onHistoryCursorChange(int)));
- QObject::connect(gui,SIGNAL(keyPressedSignal(QKeyEvent*)),
- this,SLOT(onKeyPress(QKeyEvent*)));
- QObject::connect(gui,SIGNAL(beginSelectionSignal(const int,const int,const bool)),
- this,SLOT(onSelectionBegin(const int,const int,const bool)) );
- QObject::connect(gui,SIGNAL(extendSelectionSignal(const int,const int)),
- this,SLOT(onSelectionExtend(const int,const int)) );
- QObject::connect(gui,SIGNAL(endSelectionSignal(const bool)),
- this,SLOT(setSelection(const bool)) );
- QObject::connect(gui,SIGNAL(copySelectionSignal()),
- this,SLOT(copySelection()) );
- QObject::connect(gui,SIGNAL(clearSelectionSignal()),
- this,SLOT(clearSelection()) );
- QObject::connect(gui,SIGNAL(isBusySelecting(bool)),
- this,SLOT(isBusySelecting(bool)) );
- QObject::connect(gui,SIGNAL(testIsSelected(const int, const int, bool &)),
- this,SLOT(testIsSelected(const int, const int, bool &)) );
+ TQObject::connect(gui,TQT_SIGNAL(changedHistoryCursor(int)),
+ this,TQT_SLOT(onHistoryCursorChange(int)));
+ TQObject::connect(gui,TQT_SIGNAL(keyPressedSignal(TQKeyEvent*)),
+ this,TQT_SLOT(onKeyPress(TQKeyEvent*)));
+ TQObject::connect(gui,TQT_SIGNAL(beginSelectionSignal(const int,const int,const bool)),
+ this,TQT_SLOT(onSelectionBegin(const int,const int,const bool)) );
+ TQObject::connect(gui,TQT_SIGNAL(extendSelectionSignal(const int,const int)),
+ this,TQT_SLOT(onSelectionExtend(const int,const int)) );
+ TQObject::connect(gui,TQT_SIGNAL(endSelectionSignal(const bool)),
+ this,TQT_SLOT(setSelection(const bool)) );
+ TQObject::connect(gui,TQT_SIGNAL(copySelectionSignal()),
+ this,TQT_SLOT(copySelection()) );
+ TQObject::connect(gui,TQT_SIGNAL(clearSelectionSignal()),
+ this,TQT_SLOT(clearSelection()) );
+ TQObject::connect(gui,TQT_SIGNAL(isBusySelecting(bool)),
+ this,TQT_SLOT(isBusySelecting(bool)) );
+ TQObject::connect(gui,TQT_SIGNAL(testIsSelected(const int, const int, bool &)),
+ this,TQT_SLOT(testIsSelected(const int, const int, bool &)) );
}
/*!
@@ -147,24 +147,24 @@ void TEmulation::changeGUI(TEWidget* newgui)
if (static_cast<TEWidget *>( gui )==newgui) return;
if ( gui ) {
- QObject::disconnect(gui,SIGNAL(changedHistoryCursor(int)),
- this,SLOT(onHistoryCursorChange(int)));
- QObject::disconnect(gui,SIGNAL(keyPressedSignal(QKeyEvent*)),
- this,SLOT(onKeyPress(QKeyEvent*)));
- QObject::disconnect(gui,SIGNAL(beginSelectionSignal(const int,const int,const bool)),
- this,SLOT(onSelectionBegin(const int,const int,const bool)) );
- QObject::disconnect(gui,SIGNAL(extendSelectionSignal(const int,const int)),
- this,SLOT(onSelectionExtend(const int,const int)) );
- QObject::disconnect(gui,SIGNAL(endSelectionSignal(const bool)),
- this,SLOT(setSelection(const bool)) );
- QObject::disconnect(gui,SIGNAL(copySelectionSignal()),
- this,SLOT(copySelection()) );
- QObject::disconnect(gui,SIGNAL(clearSelectionSignal()),
- this,SLOT(clearSelection()) );
- QObject::disconnect(gui,SIGNAL(isBusySelecting(bool)),
- this,SLOT(isBusySelecting(bool)) );
- QObject::disconnect(gui,SIGNAL(testIsSelected(const int, const int, bool &)),
- this,SLOT(testIsSelected(const int, const int, bool &)) );
+ TQObject::disconnect(gui,TQT_SIGNAL(changedHistoryCursor(int)),
+ this,TQT_SLOT(onHistoryCursorChange(int)));
+ TQObject::disconnect(gui,TQT_SIGNAL(keyPressedSignal(TQKeyEvent*)),
+ this,TQT_SLOT(onKeyPress(TQKeyEvent*)));
+ TQObject::disconnect(gui,TQT_SIGNAL(beginSelectionSignal(const int,const int,const bool)),
+ this,TQT_SLOT(onSelectionBegin(const int,const int,const bool)) );
+ TQObject::disconnect(gui,TQT_SIGNAL(extendSelectionSignal(const int,const int)),
+ this,TQT_SLOT(onSelectionExtend(const int,const int)) );
+ TQObject::disconnect(gui,TQT_SIGNAL(endSelectionSignal(const bool)),
+ this,TQT_SLOT(setSelection(const bool)) );
+ TQObject::disconnect(gui,TQT_SIGNAL(copySelectionSignal()),
+ this,TQT_SLOT(copySelection()) );
+ TQObject::disconnect(gui,TQT_SIGNAL(clearSelectionSignal()),
+ this,TQT_SLOT(clearSelection()) );
+ TQObject::disconnect(gui,TQT_SIGNAL(isBusySelecting(bool)),
+ this,TQT_SLOT(isBusySelecting(bool)) );
+ TQObject::disconnect(gui,TQT_SIGNAL(testIsSelected(const int, const int, bool &)),
+ this,TQT_SLOT(testIsSelected(const int, const int, bool &)) );
}
gui=newgui;
connectGUI();
@@ -204,7 +204,7 @@ const HistoryType& TEmulation::history()
return screen[0]->getScroll();
}
-void TEmulation::setCodec(const QTextCodec * qtc)
+void TEmulation::setCodec(const TQTextCodec * qtc)
{
m_codec = qtc;
delete decoder;
@@ -214,8 +214,8 @@ void TEmulation::setCodec(const QTextCodec * qtc)
void TEmulation::setCodec(int c)
{
- setCodec(c ? QTextCodec::codecForName("utf8")
- : QTextCodec::codecForLocale());
+ setCodec(c ? TQTextCodec::codecForName("utf8")
+ : TQTextCodec::codecForLocale());
}
void TEmulation::setKeymap(int no)
@@ -223,12 +223,12 @@ void TEmulation::setKeymap(int no)
keytrans = KeyTrans::find(no);
}
-void TEmulation::setKeymap(const QString &id)
+void TEmulation::setKeymap(const TQString &id)
{
keytrans = KeyTrans::find(id);
}
-QString TEmulation::keymap()
+TQString TEmulation::keymap()
{
return keytrans->id();
}
@@ -276,7 +276,7 @@ void TEmulation::onRcvChar(int c)
/*!
*/
-void TEmulation::onKeyPress( QKeyEvent* ev )
+void TEmulation::onKeyPress( TQKeyEvent* ev )
{
if (!listenToKeyPress) return; // someone else gets the keys
emit notifySessionState(NOTIFYNORMAL);
@@ -308,7 +308,7 @@ void TEmulation::onRcvBlock(const char *s, int len)
bulkStart();
- QString r;
+ TQString r;
int i, l;
for (i = 0; i < len; i++)
@@ -318,7 +318,7 @@ void TEmulation::onRcvBlock(const char *s, int len)
if ((unsigned char) s[i] < 32)
{
if (!r.length()) {
- QString tmp;
+ TQString tmp;
// Flush decoder
while(!tmp.length())
tmp = decoder->toUnicode(" ",1);
@@ -342,7 +342,7 @@ void TEmulation::onRcvBlock(const char *s, int len)
for (int j = 0; j < reslen; j++)
{
- if (r[j].category() == QChar::Mark_NonSpacing)
+ if (r[j].category() == TQChar::Mark_NonSpacing)
scr->compose(r.mid(j,1));
else
onRcvChar(r[j].unicode());
@@ -367,7 +367,7 @@ void TEmulation::onSelectionExtend(const int x, const int y) {
void TEmulation::setSelection(const bool preserve_line_breaks) {
if (!connected) return;
- QString t = scr->getSelText(preserve_line_breaks);
+ TQString t = scr->getSelText(preserve_line_breaks);
if (!t.isNull()) gui->setSelection(t);
}
@@ -391,11 +391,11 @@ void TEmulation::clearSelection() {
void TEmulation::copySelection() {
if (!connected) return;
- QString t = scr->getSelText(true);
- QApplication::clipboard()->setText(t);
+ TQString t = scr->getSelText(true);
+ TQApplication::clipboard()->setText(t);
}
-void TEmulation::streamHistory(QTextStream* stream) {
+void TEmulation::streamHistory(TQTextStream* stream) {
scr->streamHistory(stream);
}
@@ -404,16 +404,16 @@ void TEmulation::findTextBegin()
m_findPos = -1;
}
-bool TEmulation::findTextNext( const QString &str, bool forward, bool caseSensitive, bool regExp )
+bool TEmulation::findTextNext( const TQString &str, bool forward, bool caseSensitive, bool regExp )
{
int pos = -1;
- QString string;
+ TQString string;
if (forward) {
for (int i = (m_findPos==-1?0:m_findPos+1); i<(scr->getHistLines()+scr->getLines()); i++) {
string = scr->getHistoryLine(i);
if (regExp)
- pos = string.find( QRegExp(str,caseSensitive) );
+ pos = string.find( TQRegExp(str,caseSensitive) );
else
pos = string.find(str, 0, caseSensitive);
if(pos!=-1) {
@@ -431,7 +431,7 @@ bool TEmulation::findTextNext( const QString &str, bool forward, bool caseSensit
for(int i = (m_findPos==-1?(scr->getHistLines()+scr->getLines()):m_findPos-1); i>=0; i--) {
string = scr->getHistoryLine(i);
if (regExp)
- pos = string.find( QRegExp(str,caseSensitive) );
+ pos = string.find( TQRegExp(str,caseSensitive) );
else
pos = string.find(str, 0, caseSensitive);
if(pos!=-1) {
@@ -529,9 +529,9 @@ void TEmulation::onImageSizeChange(int lines, int columns)
//kdDebug(1211)<<"TEmulation::onImageSizeChange() done"<<endl;
}
-QSize TEmulation::imageSize()
+TQSize TEmulation::imageSize()
{
- return QSize(scr->getColumns(), scr->getLines());
+ return TQSize(scr->getColumns(), scr->getLines());
}
void TEmulation::onHistoryCursorChange(int cursor)
diff --git a/konsole/konsole/TEmulation.h b/konsole/konsole/TEmulation.h
index 53f05c6e7..7d3ba65d6 100644
--- a/konsole/konsole/TEmulation.h
+++ b/konsole/konsole/TEmulation.h
@@ -23,10 +23,10 @@
#include "TEWidget.h"
#include "TEScreen.h"
-#include <qtimer.h>
+#include <tqtimer.h>
#include <stdio.h>
-#include <qtextcodec.h>
-#include <qguardedptr.h>
+#include <tqtextcodec.h>
+#include <tqguardedptr.h>
#include <keytrans.h>
enum { NOTIFYNORMAL=0, NOTIFYBELL=1, NOTIFYACTIVITY=2, NOTIFYSILENCE=3 };
@@ -41,21 +41,21 @@ public:
~TEmulation();
public:
- QSize imageSize();
+ TQSize imageSize();
virtual void setHistory(const HistoryType&);
- const QTextCodec *codec() { return m_codec; }
- void setCodec(const QTextCodec *);
+ const TQTextCodec *codec() { return m_codec; }
+ void setCodec(const TQTextCodec *);
virtual const HistoryType& history();
- virtual void streamHistory(QTextStream*);
+ virtual void streamHistory(TQTextStream*);
virtual void findTextBegin();
- virtual bool findTextNext( const QString &str, bool forward, bool caseSensitive, bool regExp );
+ virtual bool findTextNext( const TQString &str, bool forward, bool caseSensitive, bool regExp );
public slots: // signals incoming from TEWidget
virtual void onImageSizeChange(int lines, int columns);
virtual void onHistoryCursorChange(int cursor);
- virtual void onKeyPress(QKeyEvent*);
+ virtual void onKeyPress(TQKeyEvent*);
virtual void clearSelection();
virtual void copySelection();
@@ -102,16 +102,16 @@ public:
void setColumns(int columns);
void setKeymap(int no);
- void setKeymap(const QString &id);
+ void setKeymap(const TQString &id);
int keymapNo();
- QString keymap();
+ TQString keymap();
virtual void clearEntireScreen() =0;
virtual void reset() =0;
protected:
- QGuardedPtr<TEWidget> gui;
+ TQGuardedPtr<TEWidget> gui;
TEScreen* scr; // referes to one `screen'
TEScreen* screen[2]; // 0 = primary, 1 = alternate
void setScreen(int n); // set `scr' to `screen[n]'
@@ -121,8 +121,8 @@ protected:
void setCodec(int c); // codec number, 0 = locale, 1=utf8
- const QTextCodec* m_codec;
- QTextDecoder* decoder;
+ const TQTextCodec* m_codec;
+ TQTextDecoder* decoder;
KeyTrans* keytrans;
@@ -140,8 +140,8 @@ private:
private:
- QTimer bulk_timer1;
- QTimer bulk_timer2;
+ TQTimer bulk_timer1;
+ TQTimer bulk_timer2;
int m_findPos;
};
diff --git a/konsole/konsole/fontembedder.cpp b/konsole/konsole/fontembedder.cpp
index f2a189598..dfbd88ce4 100644
--- a/konsole/konsole/fontembedder.cpp
+++ b/konsole/konsole/fontembedder.cpp
@@ -18,15 +18,15 @@
02110-1301 USA.
*/
-#include <qfile.h>
-#include <qtextstream.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
#include <stdlib.h>
#include <iostream>
#include <iomanip>
using namespace std;
-static Q_UINT32 charVal(QChar val)
+static Q_UINT32 charVal(TQChar val)
{
if (val == ' ')
return 0;
@@ -34,9 +34,9 @@ static Q_UINT32 charVal(QChar val)
return 1;
}
-static Q_UINT32 readGlyphLine(QTextStream& input)
+static Q_UINT32 readGlyphLine(TQTextStream& input)
{
- QString line = input.readLine();
+ TQString line = input.readLine();
while (line.length() < 5)
line += ' ';
@@ -48,7 +48,7 @@ static Q_UINT32 readGlyphLine(QTextStream& input)
return val;
}
-static Q_UINT32 readGlyph(QTextStream& input)
+static Q_UINT32 readGlyph(TQTextStream& input)
{
return readGlyphLine(input) |
(readGlyphLine(input) << 5) |
@@ -64,13 +64,13 @@ int main(int argc, char **argv)
qWarning("usage: fontembedder font.src > font.h");
exit(1);
}
- QFile inFile(argv[1]);
+ TQFile inFile(argv[1]);
if (!inFile.open(IO_ReadOnly))
{
qFatal("Can not open %s", argv[1]);
}
- QTextStream input(&inFile);
+ TQTextStream input(&inFile);
Q_UINT32 glyphStates[128];
for (int i = 0; i < 128; ++i)
@@ -78,7 +78,7 @@ int main(int argc, char **argv)
while (!input.atEnd())
{
- QString line = input.readLine();
+ TQString line = input.readLine();
line = line.stripWhiteSpace();
if (line.isEmpty())
continue; //Skip empty lines
diff --git a/konsole/konsole/keytrans.cpp b/konsole/konsole/keytrans.cpp
index f0c8311a7..36e299bc0 100644
--- a/konsole/konsole/keytrans.cpp
+++ b/konsole/konsole/keytrans.cpp
@@ -26,10 +26,10 @@
*/
#include "keytrans.h"
-#include <qbuffer.h>
-#include <qobject.h>
-#include <qintdict.h>
-#include <qfile.h>
+#include <tqbuffer.h>
+#include <tqobject.h>
+#include <tqintdict.h>
+#include <tqfile.h>
#include <kstandarddirs.h>
#include <klocale.h>
@@ -41,7 +41,7 @@
instances represent the individual assignments
*/
-KeyTrans::KeyEntry::KeyEntry(int _ref, int _key, int _bits, int _mask, int _cmd, QString _txt)
+KeyTrans::KeyEntry::KeyEntry(int _ref, int _key, int _bits, int _mask, int _cmd, TQString _txt)
: ref(_ref), key(_key), bits(_bits), mask(_mask), cmd(_cmd), txt(_txt)
{
}
@@ -66,7 +66,7 @@ bool KeyTrans::KeyEntry::anymodspecified(void)
return (mask & (1 << BITS_AnyMod)) && (bits & (1 << BITS_AnyMod));
}
-QString KeyTrans::KeyEntry::text()
+TQString KeyTrans::KeyEntry::text()
{
return txt;
}
@@ -77,7 +77,7 @@ QString KeyTrans::KeyEntry::text()
Takes part in a collection themself.
*/
-KeyTrans::KeyTrans(const QString& path)
+KeyTrans::KeyTrans(const TQString& path)
:m_path(path)
,m_numb(0)
,m_fileRead(false)
@@ -110,10 +110,10 @@ KeyTrans::~KeyTrans()
{
}
-KeyTrans::KeyEntry* KeyTrans::addEntry(int ref, int key, int bits, int mask, int cmd, QString txt)
+KeyTrans::KeyEntry* KeyTrans::addEntry(int ref, int key, int bits, int mask, int cmd, TQString txt)
// returns conflicting entry
{
- for (QPtrListIterator<KeyEntry> it(tableX); it.current(); ++it)
+ for (TQPtrListIterator<KeyEntry> it(tableX); it.current(); ++it)
{
if (it.current()->matches(key,bits,mask))
{
@@ -132,7 +132,7 @@ bool KeyTrans::findEntry(int key, int bits, int* cmd, const char** txt, int* len
if (bits & ((1<<BITS_Shift)|(1<<BITS_Alt)|(1<<BITS_Control)))
bits |= (1<<BITS_AnyMod);
- for (QPtrListIterator<KeyEntry> it(tableX); it.current(); ++it)
+ for (TQPtrListIterator<KeyEntry> it(tableX); it.current(); ++it)
if (it.current()->matches(key,bits,0xffff))
{
*cmd = it.current()->cmd;
@@ -183,7 +183,7 @@ bool KeyTrans::findEntry(int key, int bits, int* cmd, const char** txt, int* len
class KeytabReader
{
public:
- KeytabReader(QString p, QIODevice &d);
+ KeytabReader(TQString p, TQIODevice &d);
public:
void getCc();
void getSymbol();
@@ -192,7 +192,7 @@ public:
void ReportToken(); // diagnostic
private:
int sym;
- QString res;
+ TQString res;
int len;
int slinno;
int scolno;
@@ -200,12 +200,12 @@ private:
int cc;
int linno;
int colno;
- QIODevice* buf;
- QString path;
+ TQIODevice* buf;
+ TQString path;
};
-KeytabReader::KeytabReader(QString p, QIODevice &d)
+KeytabReader::KeytabReader(TQString p, TQIODevice &d)
{
path = p;
buf = &d;
@@ -337,9 +337,9 @@ protected:
void defOprSym(const char* key, int val);
void defModSym(const char* key, int val);
public:
- QDict<QObject> keysyms;
- QDict<QObject> modsyms;
- QDict<QObject> oprsyms;
+ TQDict<TQObject> keysyms;
+ TQDict<TQObject> modsyms;
+ TQDict<TQObject> oprsyms;
};
static KeyTransSymbols * syms = 0L;
@@ -354,17 +354,17 @@ void KeyTrans::readConfig()
{
if (m_fileRead) return;
m_fileRead=true;
- QIODevice* buf(0);
+ TQIODevice* buf(0);
if (m_path=="[buildin]")
{
- QCString txt =
+ TQCString txt =
#include "default.keytab.h"
;
- buf=new QBuffer(txt);
+ buf=new TQBuffer(txt);
}
else
{
- buf=new QFile(m_path);
+ buf=new TQFile(m_path);
};
KeytabReader ktr(m_path,*buf);
ktr.parseTo(this);
@@ -474,17 +474,17 @@ ERROR:
void KeyTransSymbols::defKeySym(const char* key, int val)
{
- keysyms.insert(key,(QObject*)(val+1));
+ keysyms.insert(key,(TQObject*)(val+1));
}
void KeyTransSymbols::defOprSym(const char* key, int val)
{
- oprsyms.insert(key,(QObject*)(val+1));
+ oprsyms.insert(key,(TQObject*)(val+1));
}
void KeyTransSymbols::defModSym(const char* key, int val)
{
- modsyms.insert(key,(QObject*)(val+1));
+ modsyms.insert(key,(TQObject*)(val+1));
}
void KeyTransSymbols::defOprSyms()
@@ -666,7 +666,7 @@ KeyTransSymbols::KeyTransSymbols()
static int keytab_serial = 0; //FIXME: remove,localize
-static QIntDict<KeyTrans> * numb2keymap = 0L;
+static TQIntDict<KeyTrans> * numb2keymap = 0L;
KeyTrans* KeyTrans::find(int numb)
{
@@ -674,9 +674,9 @@ KeyTrans* KeyTrans::find(int numb)
return res ? res : numb2keymap->find(0);
}
-KeyTrans* KeyTrans::find(const QString &id)
+KeyTrans* KeyTrans::find(const TQString &id)
{
- QIntDictIterator<KeyTrans> it(*numb2keymap);
+ TQIntDictIterator<KeyTrans> it(*numb2keymap);
while(it.current())
{
if (it.current()->id() == id)
@@ -700,7 +700,7 @@ void KeyTrans::addKeyTrans()
void KeyTrans::loadAll()
{
if (!numb2keymap)
- numb2keymap = new QIntDict<KeyTrans>;
+ numb2keymap = new TQIntDict<KeyTrans>;
else { // Needed for konsole_part.
numb2keymap->clear();
keytab_serial = 0;
@@ -713,20 +713,20 @@ void KeyTrans::loadAll()
KeyTrans* sc = new KeyTrans("[buildin]");
sc->addKeyTrans();
- QStringList lst = KGlobal::dirs()->findAllResources("data", "konsole/*.keytab");
+ TQStringList lst = KGlobal::dirs()->findAllResources("data", "konsole/*.keytab");
- for(QStringList::Iterator it = lst.begin(); it != lst.end(); ++it )
+ for(TQStringList::Iterator it = lst.begin(); it != lst.end(); ++it )
{
- //QFile file(QFile::encodeName(*it));
- sc = new KeyTrans(QFile::encodeName(*it));
- //KeyTrans* sc = KeyTrans::fromDevice(QFile::encodeName(*it),file);
+ //TQFile file(TQFile::encodeName(*it));
+ sc = new KeyTrans(TQFile::encodeName(*it));
+ //KeyTrans* sc = KeyTrans::fromDevice(TQFile::encodeName(*it),file);
if (sc) sc->addKeyTrans();
}
}
// Debugging material -----------------------------------------------------------
/*
-void TestTokenizer(QBuffer &buf)
+void TestTokenizer(TQBuffer &buf)
{
// opening sequence
@@ -745,10 +745,10 @@ void test()
{
// Opening sequence
- QCString txt =
+ TQCString txt =
#include "default.keytab.h"
;
- QBuffer buf(txt);
+ TQBuffer buf(txt);
if (0) TestTokenizer(buf);
if (1) { KeyTrans kt; kt.scanTable(buf); }
}
diff --git a/konsole/konsole/keytrans.h b/konsole/konsole/keytrans.h
index 62ccc9c72..2ddf5f776 100644
--- a/konsole/konsole/keytrans.h
+++ b/konsole/konsole/keytrans.h
@@ -21,9 +21,9 @@
#ifndef KEYTRANS_H
#define KEYTRANS_H
-#include <qstring.h>
-#include <qptrlist.h>
-#include <qiodevice.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
+#include <tqiodevice.h>
#define BITS_NewLine 0
#define BITS_BsHack 1
@@ -53,27 +53,27 @@ class KeyTrans
friend class KeytabReader;
public:
static KeyTrans* find(int numb);
- static KeyTrans* find(const QString &id);
+ static KeyTrans* find(const TQString &id);
static int count();
static void loadAll();
- KeyTrans(const QString& p);
+ KeyTrans(const TQString& p);
~KeyTrans();
bool findEntry(int key, int bits, int* cmd, const char** txt, int* len,
bool* metaspecified);
- const QString& hdr() {if (!m_fileRead) readConfig(); return m_hdr;}
+ const TQString& hdr() {if (!m_fileRead) readConfig(); return m_hdr;}
int numb() {return m_numb;}
- const QString& id() { return m_id;}
+ const TQString& id() { return m_id;}
class KeyEntry
{
public:
- KeyEntry(int ref, int key, int bits, int mask, int cmd, QString txt);
+ KeyEntry(int ref, int key, int bits, int mask, int cmd, TQString txt);
~KeyEntry();
bool matches(int key, int bits, int mask);
bool metaspecified(void);
bool anymodspecified(void);
- QString text();
+ TQString text();
int ref;
private:
int key;
@@ -81,17 +81,17 @@ class KeyTrans
int mask;
public:
int cmd;
- QString txt;
+ TQString txt;
};
private:
- KeyEntry* addEntry(int ref, int key, int bits, int mask, int cmd, QString txt);
+ KeyEntry* addEntry(int ref, int key, int bits, int mask, int cmd, TQString txt);
void addKeyTrans();
void readConfig();
- QPtrList<KeyEntry> tableX;
- QString m_hdr;
- QString m_path;
- QString m_id;
+ TQPtrList<KeyEntry> tableX;
+ TQString m_hdr;
+ TQString m_path;
+ TQString m_id;
int m_numb;
bool m_fileRead;
KeyTrans();
diff --git a/konsole/konsole/konsole.cpp b/konsole/konsole/konsole.cpp
index 2b85b6f39..9c292daa2 100644
--- a/konsole/konsole/konsole.cpp
+++ b/konsole/konsole/konsole.cpp
@@ -82,14 +82,14 @@ Time to start a requirement list.
#include <config.h>
-#include <qspinbox.h>
-#include <qcheckbox.h>
-#include <qimage.h>
-#include <qlayout.h>
-#include <qpushbutton.h>
-#include <qhbox.h>
-#include <qtoolbutton.h>
-#include <qtooltip.h>
+#include <tqspinbox.h>
+#include <tqcheckbox.h>
+#include <tqimage.h>
+#include <tqlayout.h>
+#include <tqpushbutton.h>
+#include <tqhbox.h>
+#include <tqtoolbutton.h>
+#include <tqtooltip.h>
#include <stdio.h>
#include <stdlib.h>
@@ -100,7 +100,7 @@ Time to start a requirement list.
#include <kfontdialog.h>
#include <kkeydialog.h>
#include <kstandarddirs.h>
-#include <qpainter.h>
+#include <tqpainter.h>
#include <kmenubar.h>
#include <kmessagebox.h>
#include <krootpixmap.h>
@@ -117,7 +117,7 @@ Time to start a requirement list.
#include <kaction.h>
#include <kshell.h>
-#include <qlabel.h>
+#include <tqlabel.h>
#include <kpopupmenu.h>
#include <klocale.h>
#include <sys/wait.h>
@@ -155,13 +155,13 @@ extern bool argb_visual; // declared in main.cpp and konsole_part.cpp
// KonsoleFontSelectAction is now also used for selectSize!
class KonsoleFontSelectAction : public KSelectAction {
public:
- KonsoleFontSelectAction(const QString &text, int accel,
- const QObject* receiver, const char* slot,
- QObject* parent, const char* name = 0 )
+ KonsoleFontSelectAction(const TQString &text, int accel,
+ const TQObject* receiver, const char* slot,
+ TQObject* parent, const char* name = 0 )
: KSelectAction(text, accel, receiver, slot, parent, name) {}
- KonsoleFontSelectAction( const QString &text, const QIconSet& pix,
- int accel, const QObject* receiver,
- const char* slot, QObject* parent,
+ KonsoleFontSelectAction( const TQString &text, const TQIconSet& pix,
+ int accel, const TQObject* receiver,
+ const char* slot, TQObject* parent,
const char* name = 0 )
: KSelectAction(text, pix, accel, receiver, slot, parent, name) {}
@@ -178,14 +178,14 @@ void KonsoleFontSelectAction::slotActivated(int index) {
}
}
-template class QPtrDict<TESession>;
-template class QIntDict<KSimpleConfig>;
-template class QPtrDict<KRadioAction>;
+template class TQPtrDict<TESession>;
+template class TQIntDict<KSimpleConfig>;
+template class TQPtrDict<KRadioAction>;
#define DEFAULT_HISTORY_SIZE 1000
Konsole::Konsole(const char* name, int histon, bool menubaron, bool tabbaron, bool frameon, bool scrollbaron,
- QCString type, bool b_inRestore, const int wanted_tabbar, const QString &workdir )
+ TQCString type, bool b_inRestore, const int wanted_tabbar, const TQString &workdir )
:DCOPObject( "konsole" )
,KMainWindow(0, name)
,m_defaultSession(0)
@@ -270,16 +270,16 @@ Konsole::Konsole(const char* name, int histon, bool menubaron, bool tabbaron, bo
,s_workDir(workdir)
{
isRestored = b_inRestore;
- connect( &m_closeTimeout, SIGNAL(timeout()), this, SLOT(slotCouldNotClose()));
+ connect( &m_closeTimeout, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotCouldNotClose()));
no2command.setAutoDelete(true);
menubar = menuBar();
KAcceleratorManager::setNoAccel( menubar );
- sessionNumberMapper = new QSignalMapper( this );
- connect( sessionNumberMapper, SIGNAL( mapped( int ) ),
- this, SLOT( newSessionTabbar( int ) ) );
+ sessionNumberMapper = new TQSignalMapper( this );
+ connect( sessionNumberMapper, TQT_SIGNAL( mapped( int ) ),
+ this, TQT_SLOT( newSessionTabbar( int ) ) );
colors = new ColorSchemaList();
colors->checkSchemas();
@@ -290,7 +290,7 @@ Konsole::Konsole(const char* name, int histon, bool menubaron, bool tabbaron, bo
// create applications /////////////////////////////////////////////////////
// read and apply default values ///////////////////////////////////////////
resize(321, 321); // Dummy.
- QSize currentSize = size();
+ TQSize currentSize = size();
KConfig * config = KGlobal::config();
config->setDesktopGroup();
applyMainWindowSettings(config);
@@ -303,7 +303,7 @@ Konsole::Konsole(const char* name, int histon, bool menubaron, bool tabbaron, bo
co = defaultSession();
co->setDesktopGroup();
- QString schema = co->readEntry("Schema");
+ TQString schema = co->readEntry("Schema");
readProperties(config, schema, false);
makeBasicGUI();
@@ -331,14 +331,14 @@ Konsole::Konsole(const char* name, int histon, bool menubaron, bool tabbaron, bo
menubar->hide();
if (!frameon) {
b_framevis=false;
- if (te) te->setFrameStyle( QFrame::NoFrame );
+ if (te) te->setFrameStyle( TQFrame::NoFrame );
}
if (!scrollbaron) {
n_scroll = TEWidget::SCRNONE;
if (te) te->setScrollbarLocation(TEWidget::SCRNONE);
}
-// connect(kapp, SIGNAL(kdisplayFontChanged()), this, SLOT(slotFontChanged()));
+// connect(kapp, TQT_SIGNAL(kdisplayFontChanged()), this, TQT_SLOT(slotFontChanged()));
kapp->dcopClient()->setDefaultObject( "konsole" );
}
@@ -378,7 +378,7 @@ void Konsole::setAutoClose(bool on)
void Konsole::showTip()
{
- KTipDialog::showTip(this,QString::null,true);
+ KTipDialog::showTip(this,TQString::null,true);
}
void Konsole::showTipOnStart()
@@ -453,31 +453,31 @@ void Konsole::makeGUI()
if (m_menuCreated) return;
if (m_tabbarSessionsCommands)
- disconnect(m_tabbarSessionsCommands,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
- disconnect(m_session,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ disconnect(m_tabbarSessionsCommands,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
+ disconnect(m_session,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_options)
- disconnect(m_options,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ disconnect(m_options,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_help)
- disconnect(m_help,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ disconnect(m_help,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_rightButton)
- disconnect(m_rightButton,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
- disconnect(m_edit,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
- disconnect(m_view,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ disconnect(m_rightButton,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
+ disconnect(m_edit,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
+ disconnect(m_view,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_bookmarks)
- disconnect(m_bookmarks,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ disconnect(m_bookmarks,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_bookmarksSession)
- disconnect(m_bookmarksSession,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ disconnect(m_bookmarksSession,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_tabbarSessionsCommands)
- connect(m_tabbarSessionsCommands,SIGNAL(aboutToShow()),this,SLOT(loadScreenSessions()));
- connect(m_session,SIGNAL(aboutToShow()),this,SLOT(loadScreenSessions()));
+ connect(m_tabbarSessionsCommands,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(loadScreenSessions()));
+ connect(m_session,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(loadScreenSessions()));
m_menuCreated=true;
// Remove the empty separator Qt inserts if the menu is empty on popup,
// not sure if this will be "fixed" in Qt, for now use this hack (malte)
if(!(isRestored)) {
- if (sender() && sender()->inherits("QPopupMenu") &&
- static_cast<const QPopupMenu *>(sender())->count() == 1)
- const_cast<QPopupMenu *>(static_cast<const QPopupMenu *>(sender()))->removeItemAt(0);
+ if (sender() && sender()->inherits("TQPopupMenu") &&
+ static_cast<const TQPopupMenu *>(sender())->count() == 1)
+ const_cast<TQPopupMenu *>(static_cast<const TQPopupMenu *>(sender()))->removeItemAt(0);
}
KActionCollection* actions = actionCollection();
@@ -494,7 +494,7 @@ void Konsole::makeGUI()
m_signals->insertItem( i18n( "&Kill Task" ) + " (KILL)", SIGKILL);
m_signals->insertItem( i18n( "User Signal &1") + " (USR1)", SIGUSR1);
m_signals->insertItem( i18n( "User Signal &2") + " (USR2)", SIGUSR2);
- connect(m_signals, SIGNAL(activated(int)), SLOT(sendSignal(int)));
+ connect(m_signals, TQT_SIGNAL(activated(int)), TQT_SLOT(sendSignal(int)));
KAcceleratorManager::manage( m_signals );
}
@@ -548,28 +548,28 @@ void Konsole::makeGUI()
//bookmarks menu
if (bookmarkHandler)
- connect( bookmarkHandler, SIGNAL( openURL( const QString&, const QString& )),
- SLOT( enterURL( const QString&, const QString& )));
+ connect( bookmarkHandler, TQT_SIGNAL( openURL( const TQString&, const TQString& )),
+ TQT_SLOT( enterURL( const TQString&, const TQString& )));
if (bookmarkHandlerSession)
- connect( bookmarkHandlerSession, SIGNAL( openURL( const QString&, const QString& )),
- SLOT( newSession( const QString&, const QString& )));
+ connect( bookmarkHandlerSession, TQT_SIGNAL( openURL( const TQString&, const TQString& )),
+ TQT_SLOT( newSession( const TQString&, const TQString& )));
if (m_bookmarks)
- connect(m_bookmarks, SIGNAL(aboutToShow()), SLOT(bookmarks_menu_check()));
+ connect(m_bookmarks, TQT_SIGNAL(aboutToShow()), TQT_SLOT(bookmarks_menu_check()));
if (m_bookmarksSession)
- connect(m_bookmarksSession, SIGNAL(aboutToShow()), SLOT(bookmarks_menu_check()));
+ connect(m_bookmarksSession, TQT_SIGNAL(aboutToShow()), TQT_SLOT(bookmarks_menu_check()));
// Schema Options Menu -----------------------------------------------------
m_schema = new KPopupMenu(this);
m_schema->setCheckable(true);
KAcceleratorManager::manage( m_schema );
- connect(m_schema, SIGNAL(activated(int)), SLOT(schema_menu_activated(int)));
- connect(m_schema, SIGNAL(aboutToShow()), SLOT(schema_menu_check()));
+ connect(m_schema, TQT_SIGNAL(activated(int)), TQT_SLOT(schema_menu_activated(int)));
+ connect(m_schema, TQT_SIGNAL(aboutToShow()), TQT_SLOT(schema_menu_check()));
// Keyboard Options Menu ---------------------------------------------------
m_keytab = new KPopupMenu(this);
m_keytab->setCheckable(true);
KAcceleratorManager::manage( m_keytab );
- connect(m_keytab, SIGNAL(activated(int)), SLOT(keytab_menu_activated(int)));
+ connect(m_keytab, TQT_SIGNAL(activated(int)), TQT_SLOT(keytab_menu_activated(int)));
//options menu
if (m_options)
@@ -579,16 +579,16 @@ void Konsole::makeGUI()
// Tabbar
selectTabbar = new KSelectAction(i18n("&Tab Bar"), 0, this,
- SLOT(slotSelectTabbar()), actions, "tabbar" );
- QStringList tabbaritems;
+ TQT_SLOT(slotSelectTabbar()), actions, "tabbar" );
+ TQStringList tabbaritems;
tabbaritems << i18n("&Hide") << i18n("&Top") << i18n("&Bottom");
selectTabbar->setItems(tabbaritems);
selectTabbar->plug(m_options);
// Scrollbar
selectScrollbar = new KSelectAction(i18n("Sc&rollbar"), 0, this,
- SLOT(slotSelectScrollbar()), actions, "scrollbar" );
- QStringList scrollitems;
+ TQT_SLOT(slotSelectScrollbar()), actions, "scrollbar" );
+ TQStringList scrollitems;
scrollitems << i18n("&Hide") << i18n("&Left") << i18n("&Right");
selectScrollbar->setItems(scrollitems);
selectScrollbar->plug(m_options);
@@ -603,8 +603,8 @@ void Konsole::makeGUI()
// Select Bell
selectBell = new KSelectAction(i18n("&Bell"), SmallIconSet( "bell"), 0 , this,
- SLOT(slotSelectBell()), actions, "bell");
- QStringList bellitems;
+ TQT_SLOT(slotSelectBell()), actions, "bell");
+ TQStringList bellitems;
bellitems << i18n("System &Bell")
<< i18n("System &Notification")
<< i18n("&Visible Bell")
@@ -618,28 +618,28 @@ void Konsole::makeGUI()
actions, 0L );
m_fontsizes->insert( new KAction( i18n( "&Enlarge Font" ),
SmallIconSet( "fontsizeup" ), 0, this,
- SLOT( biggerFont() ), actions,
+ TQT_SLOT( biggerFont() ), actions,
"enlarge_font" ) );
m_fontsizes->insert( new KAction( i18n( "&Shrink Font" ),
SmallIconSet( "fontsizedown" ), 0, this,
- SLOT( smallerFont() ), actions,
+ TQT_SLOT( smallerFont() ), actions,
"shrink_font" ) );
m_fontsizes->insert( new KAction( i18n( "Se&lect..." ),
SmallIconSet( "font" ), 0, this,
- SLOT( slotSelectFont() ), actions,
+ TQT_SLOT( slotSelectFont() ), actions,
"select_font" ) );
if ( b_installBitmapFonts )
{
m_fontsizes->insert( new KAction( i18n( "&Install Bitmap..." ),
SmallIconSet( "font" ), 0, this,
- SLOT( slotInstallBitmapFonts() ), actions,
+ TQT_SLOT( slotInstallBitmapFonts() ), actions,
"install_fonts" ) );
}
m_fontsizes->plug(m_options);
// encoding menu, start with default checked !
- selectSetEncoding = new KSelectAction( i18n( "&Encoding" ), SmallIconSet( "charset" ), 0, this, SLOT(slotSetEncoding()), actions, "set_encoding" );
- QStringList list = KGlobal::charsets()->descriptiveEncodingNames();
+ selectSetEncoding = new KSelectAction( i18n( "&Encoding" ), SmallIconSet( "charset" ), 0, this, TQT_SLOT(slotSetEncoding()), actions, "set_encoding" );
+ TQStringList list = KGlobal::charsets()->descriptiveEncodingNames();
list.prepend( i18n( "Default" ) );
selectSetEncoding->setItems(list);
selectSetEncoding->setCurrentItem (0);
@@ -656,8 +656,8 @@ void Konsole::makeGUI()
if (!b_fixedSize)
{
selectSize = new KonsoleFontSelectAction(i18n("S&ize"), 0, this,
- SLOT(slotSelectSize()), actions, "size");
- QStringList sizeitems;
+ TQT_SLOT(slotSelectSize()), actions, "size");
+ TQStringList sizeitems;
sizeitems << i18n("40x15 (&Small)")
<< i18n("80x24 (&VT100)")
<< i18n("80x25 (&IBM PC)")
@@ -670,13 +670,13 @@ void Konsole::makeGUI()
}
KAction *historyType = new KAction(i18n("Hist&ory..."), "history", 0, this,
- SLOT(slotHistoryType()), actions, "history");
+ TQT_SLOT(slotHistoryType()), actions, "history");
historyType->plug(m_options);
m_options->insertSeparator();
KAction *save_settings = new KAction(i18n("&Save as Default"), "filesave", 0, this,
- SLOT(slotSaveSettings()), actions, "save_default");
+ TQT_SLOT(slotSaveSettings()), actions, "save_default");
save_settings->plug(m_options);
m_options->insertSeparator();
@@ -685,9 +685,9 @@ void Konsole::makeGUI()
m_options->insertSeparator();
- KStdAction::configureNotifications(this, SLOT(slotConfigureNotifications()), actionCollection())->plug(m_options);
- KStdAction::keyBindings(this, SLOT(slotConfigureKeys()), actionCollection())->plug(m_options);
- KAction *configure = KStdAction::preferences(this, SLOT(slotConfigure()), actions);
+ KStdAction::configureNotifications(this, TQT_SLOT(slotConfigureNotifications()), actionCollection())->plug(m_options);
+ KStdAction::keyBindings(this, TQT_SLOT(slotConfigureKeys()), actionCollection())->plug(m_options);
+ KAction *configure = KStdAction::preferences(this, TQT_SLOT(slotConfigure()), actions);
configure->plug(m_options);
if (KGlobalSettings::insertTearOffHandle())
@@ -699,13 +699,13 @@ void Konsole::makeGUI()
{
m_help->insertSeparator(1);
m_help->insertItem(SmallIcon( "idea" ), i18n("&Tip of the Day"),
- this, SLOT(showTip()), 0, -1, 2);
+ this, TQT_SLOT(showTip()), 0, -1, 2);
}
//the different session menus
buildSessionMenus();
- connect(m_session, SIGNAL(activated(int)), SLOT(newSession(int)));
+ connect(m_session, TQT_SIGNAL(activated(int)), TQT_SLOT(newSession(int)));
// Right mouse button menu
if (m_rightButton)
@@ -713,7 +713,7 @@ void Konsole::makeGUI()
updateRMBMenu(); // show menubar / exit fullscreen
KAction* selectionEnd = new KAction(i18n("Set Selection End"), 0, this,
- SLOT(slotSetSelectionEnd()), actions, "selection_end");
+ TQT_SLOT(slotSetSelectionEnd()), actions, "selection_end");
selectionEnd->plug(m_rightButton);
m_copyClipboard->plug(m_rightButton);
@@ -763,23 +763,23 @@ void Konsole::makeGUI()
// insert keymaps into menu
// This sorting seems a bit cumbersome; but it is not called often.
- QStringList kt_titles;
- typedef QMap<QString,KeyTrans*> QStringKeyTransMap;
+ TQStringList kt_titles;
+ typedef TQMap<TQString,KeyTrans*> QStringKeyTransMap;
QStringKeyTransMap kt_map;
for (int i = 0; i < KeyTrans::count(); i++)
{
KeyTrans* ktr = KeyTrans::find(i);
assert( ktr );
- QString title=ktr->hdr().lower();
+ TQString title=ktr->hdr().lower();
kt_titles << title;
kt_map[title] = ktr;
}
kt_titles.sort();
- for ( QStringList::Iterator it = kt_titles.begin(); it != kt_titles.end(); ++it ) {
+ for ( TQStringList::Iterator it = kt_titles.begin(); it != kt_titles.end(); ++it ) {
KeyTrans* ktr = kt_map[*it];
assert( ktr );
- QString title=ktr->hdr();
+ TQString title=ktr->hdr();
m_keytab->insertItem(title.replace('&',"&&"),ktr->numb());
}
@@ -791,39 +791,39 @@ void Konsole::makeGUI()
m_tabPopupMenu = new KPopupMenu( this );
KAcceleratorManager::manage( m_tabPopupMenu );
- m_tabDetachSession= new KAction( i18n("&Detach Session"), SmallIconSet("tab_breakoff"), 0, this, SLOT(slotTabDetachSession()), this );
+ m_tabDetachSession= new KAction( i18n("&Detach Session"), SmallIconSet("tab_breakoff"), 0, this, TQT_SLOT(slotTabDetachSession()), this );
m_tabDetachSession->plug(m_tabPopupMenu);
m_tabPopupMenu->insertItem( i18n("&Rename Session..."), this,
- SLOT(slotTabRenameSession()) );
+ TQT_SLOT(slotTabRenameSession()) );
m_tabPopupMenu->insertSeparator();
m_tabMonitorActivity = new KToggleAction ( i18n( "Monitor for &Activity" ),
- SmallIconSet("activity"), 0, this, SLOT( slotTabToggleMonitor() ), this );
+ SmallIconSet("activity"), 0, this, TQT_SLOT( slotTabToggleMonitor() ), this );
m_tabMonitorActivity->setCheckedState( KGuiItem( i18n( "Stop Monitoring for &Activity" ) ) );
m_tabMonitorActivity->plug(m_tabPopupMenu);
m_tabMonitorSilence = new KToggleAction ( i18n( "Monitor for &Silence" ),
- SmallIconSet("silence"), 0, this, SLOT( slotTabToggleMonitor() ), this );
+ SmallIconSet("silence"), 0, this, TQT_SLOT( slotTabToggleMonitor() ), this );
m_tabMonitorSilence->setCheckedState( KGuiItem( i18n( "Stop Monitoring for &Silence" ) ) );
m_tabMonitorSilence->plug(m_tabPopupMenu);
m_tabMasterMode = new KToggleAction ( i18n( "Send &Input to All Sessions" ), "remote", 0, this,
- SLOT( slotTabToggleMasterMode() ), this);
+ TQT_SLOT( slotTabToggleMasterMode() ), this);
m_tabMasterMode->plug(m_tabPopupMenu);
m_tabPopupMenu->insertSeparator();
- m_tabPopupMenu->insertItem( SmallIconSet("colors"), i18n("Select &Tab Color..."), this, SLOT(slotTabSelectColor()) );
+ m_tabPopupMenu->insertItem( SmallIconSet("colors"), i18n("Select &Tab Color..."), this, TQT_SLOT(slotTabSelectColor()) );
m_tabPopupMenu->insertSeparator();
m_tabPopupTabsMenu = new KPopupMenu( m_tabPopupMenu );
m_tabPopupMenu->insertItem( i18n("Switch to Tab" ), m_tabPopupTabsMenu );
- connect( m_tabPopupTabsMenu, SIGNAL( activated ( int ) ),
- SLOT( activateSession( int ) ) );
+ connect( m_tabPopupTabsMenu, TQT_SIGNAL( activated ( int ) ),
+ TQT_SLOT( activateSession( int ) ) );
m_tabPopupMenu->insertSeparator();
m_tabPopupMenu->insertItem( SmallIcon("fileclose"), i18n("C&lose Session"), this,
- SLOT(slotTabCloseSession()) );
+ TQT_SLOT(slotTabCloseSession()) );
if (m_options) {
// Fill tab bar context menu
@@ -833,21 +833,21 @@ void Konsole::makeGUI()
KSelectAction *viewOptions = new KSelectAction(this);
viewOptions->setText(i18n("Tab &Options"));
- QStringList options;
+ TQStringList options;
options << i18n("&Text && Icons") << i18n("Text &Only") << i18n("&Icons Only");
viewOptions->setItems(options);
viewOptions->setCurrentItem(m_tabViewMode);
viewOptions->plug(m_tabbarPopupMenu);
- connect(viewOptions, SIGNAL(activated(int)), this, SLOT(slotTabSetViewOptions(int)));
+ connect(viewOptions, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotTabSetViewOptions(int)));
slotTabSetViewOptions(m_tabViewMode);
KToggleAction *dynamicTabHideOption = new KToggleAction ( i18n( "&Dynamic Hide" ), 0, this,
- SLOT( slotTabbarToggleDynamicHide() ), this);
+ TQT_SLOT( slotTabbarToggleDynamicHide() ), this);
dynamicTabHideOption->setChecked(b_dynamicTabHide);
dynamicTabHideOption->plug(m_tabbarPopupMenu);
KToggleAction *m_autoResizeTabs = new KToggleAction( i18n("&Auto Resize Tabs"),
- 0, this, SLOT( slotToggleAutoResizeTabs() ), this);
+ 0, this, TQT_SLOT( slotToggleAutoResizeTabs() ), this);
m_autoResizeTabs->setChecked(b_autoResizeTabs);
m_autoResizeTabs->plug(m_tabbarPopupMenu);
}
@@ -858,28 +858,28 @@ void Konsole::slotSetEncoding()
{
if (!se) return;
- QTextCodec * qtc;
+ TQTextCodec * qtc;
if (selectSetEncoding->currentItem() == 0)
{
- qtc = QTextCodec::codecForLocale();
+ qtc = TQTextCodec::codecForLocale();
}
else
{
bool found;
- QString enc = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
+ TQString enc = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
qtc = KGlobal::charsets()->codecForName(enc, found);
// BR114535 : Remove jis7 due to infinite loop.
if ( enc == "jis7" ) {
kdWarning()<<"Encoding Japanese (jis7) currently does not work! BR114535"<<endl;
- qtc = QTextCodec::codecForLocale();
+ qtc = TQTextCodec::codecForLocale();
selectSetEncoding->setCurrentItem( 0 );
}
if(!found)
{
kdWarning() << "Codec " << selectSetEncoding->currentText() << " not found! Using default..." << endl;
- qtc = QTextCodec::codecForLocale();
+ qtc = TQTextCodec::codecForLocale();
selectSetEncoding->setCurrentItem( 0 );
}
}
@@ -896,57 +896,57 @@ void Konsole::makeTabWidget()
tabwidget->setTabCloseActivatePrevious( true );
if (n_tabbar==TabTop)
- tabwidget->setTabPosition(QTabWidget::Top);
+ tabwidget->setTabPosition(TQTabWidget::Top);
else
- tabwidget->setTabPosition(QTabWidget::Bottom);
+ tabwidget->setTabPosition(TQTabWidget::Bottom);
KAcceleratorManager::setNoAccel( tabwidget );
- connect(tabwidget, SIGNAL(movedTab(int,int)), SLOT(slotMovedTab(int,int)));
- connect(tabwidget, SIGNAL(mouseDoubleClick(QWidget*)), SLOT(slotRenameSession()));
- connect(tabwidget, SIGNAL(currentChanged(QWidget*)), SLOT(activateSession(QWidget*)));
- connect( tabwidget, SIGNAL(contextMenu(QWidget*, const QPoint &)),
- SLOT(slotTabContextMenu(QWidget*, const QPoint &)));
- connect( tabwidget, SIGNAL(contextMenu(const QPoint &)),
- SLOT(slotTabbarContextMenu(const QPoint &)));
+ connect(tabwidget, TQT_SIGNAL(movedTab(int,int)), TQT_SLOT(slotMovedTab(int,int)));
+ connect(tabwidget, TQT_SIGNAL(mouseDoubleClick(TQWidget*)), TQT_SLOT(slotRenameSession()));
+ connect(tabwidget, TQT_SIGNAL(currentChanged(TQWidget*)), TQT_SLOT(activateSession(TQWidget*)));
+ connect( tabwidget, TQT_SIGNAL(contextMenu(TQWidget*, const TQPoint &)),
+ TQT_SLOT(slotTabContextMenu(TQWidget*, const TQPoint &)));
+ connect( tabwidget, TQT_SIGNAL(contextMenu(const TQPoint &)),
+ TQT_SLOT(slotTabbarContextMenu(const TQPoint &)));
if (kapp->authorize("shell_access")) {
- connect(tabwidget, SIGNAL(mouseDoubleClick()), SLOT(newSession()));
+ connect(tabwidget, TQT_SIGNAL(mouseDoubleClick()), TQT_SLOT(newSession()));
- m_newSessionButton = new QToolButton( tabwidget );
- QToolTip::add(m_newSessionButton,i18n("Click for new standard session\nClick and hold for session menu"));
+ m_newSessionButton = new TQToolButton( tabwidget );
+ TQToolTip::add(m_newSessionButton,i18n("Click for new standard session\nClick and hold for session menu"));
m_newSessionButton->setIconSet( SmallIcon( "tab_new" ) );
m_newSessionButton->adjustSize();
m_newSessionButton->setPopup( m_tabbarSessionsCommands );
- connect(m_newSessionButton, SIGNAL(clicked()), SLOT(newSession()));
+ connect(m_newSessionButton, TQT_SIGNAL(clicked()), TQT_SLOT(newSession()));
tabwidget->setCornerWidget( m_newSessionButton, BottomLeft );
m_newSessionButton->installEventFilter(this);
- m_removeSessionButton = new QToolButton( tabwidget );
- QToolTip::add(m_removeSessionButton,i18n("Close the current session"));
+ m_removeSessionButton = new TQToolButton( tabwidget );
+ TQToolTip::add(m_removeSessionButton,i18n("Close the current session"));
m_removeSessionButton->setIconSet( SmallIconSet( "tab_remove" ) );
m_removeSessionButton->adjustSize();
m_removeSessionButton->setEnabled(false);
- connect(m_removeSessionButton, SIGNAL(clicked()), SLOT(confirmCloseCurrentSession()));
+ connect(m_removeSessionButton, TQT_SIGNAL(clicked()), TQT_SLOT(confirmCloseCurrentSession()));
tabwidget->setCornerWidget( m_removeSessionButton, BottomRight );
}
}
-bool Konsole::eventFilter( QObject *o, QEvent *ev )
+bool Konsole::eventFilter( TQObject *o, TQEvent *ev )
{
if (o == m_newSessionButton)
{
// Popup the menu when the left mousebutton is pressed and the mouse
// is moved by a small distance.
- if (ev->type() == QEvent::MouseButtonPress)
+ if (ev->type() == TQEvent::MouseButtonPress)
{
- QMouseEvent* mev = static_cast<QMouseEvent*>(ev);
+ TQMouseEvent* mev = static_cast<TQMouseEvent*>(ev);
m_newSessionButtonMousePressPos = mev->pos();
}
- else if (ev->type() == QEvent::MouseMove)
+ else if (ev->type() == TQEvent::MouseMove)
{
- QMouseEvent* mev = static_cast<QMouseEvent*>(ev);
+ TQMouseEvent* mev = static_cast<TQMouseEvent*>(ev);
if ((mev->pos() - m_newSessionButtonMousePressPos).manhattanLength()
> KGlobalSettings::dndEventDelay())
{
@@ -954,9 +954,9 @@ bool Konsole::eventFilter( QObject *o, QEvent *ev )
return true;
}
}
- else if (ev->type() == QEvent::ContextMenu)
+ else if (ev->type() == TQEvent::ContextMenu)
{
- QMouseEvent* mev = static_cast<QMouseEvent*>(ev);
+ TQMouseEvent* mev = static_cast<TQMouseEvent*>(ev);
slotTabbarContextMenu(mev->globalPos());
return true;
}
@@ -969,7 +969,7 @@ void Konsole::makeBasicGUI()
if (kapp->authorize("shell_access")) {
m_tabbarSessionsCommands = new KPopupMenu( this );
KAcceleratorManager::manage( m_tabbarSessionsCommands );
- connect(m_tabbarSessionsCommands, SIGNAL(activated(int)), SLOT(newSessionTabbar(int)));
+ connect(m_tabbarSessionsCommands, TQT_SIGNAL(activated(int)), TQT_SLOT(newSessionTabbar(int)));
}
m_session = new KPopupMenu(this);
@@ -1012,20 +1012,20 @@ void Konsole::makeBasicGUI()
// programs.
if (m_tabbarSessionsCommands)
- connect(m_tabbarSessionsCommands,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
- connect(m_session,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ connect(m_tabbarSessionsCommands,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
+ connect(m_session,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_options)
- connect(m_options,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ connect(m_options,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_help)
- connect(m_help,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ connect(m_help,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_rightButton)
- connect(m_rightButton,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
- connect(m_edit,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
- connect(m_view,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ connect(m_rightButton,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
+ connect(m_edit,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
+ connect(m_view,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_bookmarks)
- connect(m_bookmarks,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ connect(m_bookmarks,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
if (m_bookmarksSession)
- connect(m_bookmarksSession,SIGNAL(aboutToShow()),this,SLOT(makeGUI()));
+ connect(m_bookmarksSession,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(makeGUI()));
menubar->insertItem(i18n("Session") , m_session);
menubar->insertItem(i18n("Edit"), m_edit);
@@ -1040,113 +1040,113 @@ void Konsole::makeBasicGUI()
m_shortcuts = new KActionCollection(this);
m_copyClipboard = new KAction(i18n("&Copy"), "editcopy", 0, this,
- SLOT(slotCopyClipboard()), m_shortcuts, "edit_copy");
+ TQT_SLOT(slotCopyClipboard()), m_shortcuts, "edit_copy");
m_pasteClipboard = new KAction(i18n("&Paste"), "editpaste", Qt::SHIFT+Qt::Key_Insert, this,
- SLOT(slotPasteClipboard()), m_shortcuts, "edit_paste");
+ TQT_SLOT(slotPasteClipboard()), m_shortcuts, "edit_paste");
m_pasteSelection = new KAction(i18n("Paste Selection"), Qt::CTRL+Qt::SHIFT+Qt::Key_Insert, this,
- SLOT(slotPasteSelection()), m_shortcuts, "pasteselection");
+ TQT_SLOT(slotPasteSelection()), m_shortcuts, "pasteselection");
m_clearTerminal = new KAction(i18n("C&lear Terminal"), 0, this,
- SLOT(slotClearTerminal()), m_shortcuts, "clear_terminal");
+ TQT_SLOT(slotClearTerminal()), m_shortcuts, "clear_terminal");
m_resetClearTerminal = new KAction(i18n("&Reset && Clear Terminal"), 0, this,
- SLOT(slotResetClearTerminal()), m_shortcuts, "reset_clear_terminal");
+ TQT_SLOT(slotResetClearTerminal()), m_shortcuts, "reset_clear_terminal");
m_findHistory = new KAction(i18n("&Find in History..."), "find", 0, this,
- SLOT(slotFindHistory()), m_shortcuts, "find_history");
+ TQT_SLOT(slotFindHistory()), m_shortcuts, "find_history");
m_findHistory->setEnabled(b_histEnabled);
m_findNext = new KAction(i18n("Find &Next"), "next", 0, this,
- SLOT(slotFindNext()), m_shortcuts, "find_next");
+ TQT_SLOT(slotFindNext()), m_shortcuts, "find_next");
m_findNext->setEnabled(b_histEnabled);
m_findPrevious = new KAction(i18n("Find Pre&vious"), "previous", 0, this,
- SLOT(slotFindPrevious()), m_shortcuts, "find_previous");
+ TQT_SLOT(slotFindPrevious()), m_shortcuts, "find_previous");
m_findPrevious->setEnabled( b_histEnabled );
m_saveHistory = new KAction(i18n("S&ave History As..."), "filesaveas", 0, this,
- SLOT(slotSaveHistory()), m_shortcuts, "save_history");
+ TQT_SLOT(slotSaveHistory()), m_shortcuts, "save_history");
m_saveHistory->setEnabled(b_histEnabled );
m_clearHistory = new KAction(i18n("Clear &History"), "history_clear", 0, this,
- SLOT(slotClearHistory()), m_shortcuts, "clear_history");
+ TQT_SLOT(slotClearHistory()), m_shortcuts, "clear_history");
m_clearHistory->setEnabled(b_histEnabled);
m_clearAllSessionHistories = new KAction(i18n("Clear All H&istories"), "history_clear", 0,
- this, SLOT(slotClearAllSessionHistories()), m_shortcuts, "clear_all_histories");
+ this, TQT_SLOT(slotClearAllSessionHistories()), m_shortcuts, "clear_all_histories");
m_detachSession = new KAction(i18n("&Detach Session"), SmallIconSet("tab_breakoff"), 0, this,
- SLOT(slotDetachSession()), m_shortcuts, "detach_session");
+ TQT_SLOT(slotDetachSession()), m_shortcuts, "detach_session");
m_detachSession->setEnabled(false);
m_renameSession = new KAction(i18n("&Rename Session..."), Qt::CTRL+Qt::ALT+Qt::Key_S, this,
- SLOT(slotRenameSession()), m_shortcuts, "rename_session");
+ TQT_SLOT(slotRenameSession()), m_shortcuts, "rename_session");
if (kapp->authorizeKAction("zmodem_upload"))
m_zmodemUpload = new KAction( i18n( "&ZModem Upload..." ),
Qt::CTRL+Qt::ALT+Qt::Key_U, this,
- SLOT( slotZModemUpload() ),
+ TQT_SLOT( slotZModemUpload() ),
m_shortcuts, "zmodem_upload" );
monitorActivity = new KToggleAction ( i18n( "Monitor for &Activity" ),
SmallIconSet("activity"), 0, this,
- SLOT( slotToggleMonitor() ), m_shortcuts, "monitor_activity" );
+ TQT_SLOT( slotToggleMonitor() ), m_shortcuts, "monitor_activity" );
monitorActivity->setCheckedState( KGuiItem( i18n( "Stop Monitoring for &Activity" ) ) );
monitorSilence = new KToggleAction ( i18n( "Monitor for &Silence" ),
SmallIconSet("silence"), 0, this,
- SLOT( slotToggleMonitor() ), m_shortcuts, "monitor_silence" );
+ TQT_SLOT( slotToggleMonitor() ), m_shortcuts, "monitor_silence" );
monitorSilence->setCheckedState( KGuiItem( i18n( "Stop Monitoring for &Silence" ) ) );
masterMode = new KToggleAction ( i18n( "Send &Input to All Sessions" ), "remote", 0, this,
- SLOT( slotToggleMasterMode() ), m_shortcuts, "send_input_to_all_sessions" );
+ TQT_SLOT( slotToggleMasterMode() ), m_shortcuts, "send_input_to_all_sessions" );
showMenubar = new KToggleAction ( i18n( "Show &Menubar" ), "showmenu", 0, this,
- SLOT( slotToggleMenubar() ), m_shortcuts, "show_menubar" );
- showMenubar->setCheckedState( KGuiItem( i18n("Hide &Menubar"), "showmenu", QString::null, QString::null ) );
+ TQT_SLOT( slotToggleMenubar() ), m_shortcuts, "show_menubar" );
+ showMenubar->setCheckedState( KGuiItem( i18n("Hide &Menubar"), "showmenu", TQString::null, TQString::null ) );
m_fullscreen = KStdAction::fullScreen(0, 0, m_shortcuts, this );
- connect( m_fullscreen,SIGNAL(toggled(bool)), this,SLOT(updateFullScreen(bool)));
+ connect( m_fullscreen,TQT_SIGNAL(toggled(bool)), this,TQT_SLOT(updateFullScreen(bool)));
m_fullscreen->setChecked(b_fullscreen);
m_saveProfile = new KAction( i18n( "Save Sessions &Profile..." ), SmallIconSet("filesaveas"), 0, this,
- SLOT( slotSaveSessionsProfile() ), m_shortcuts, "save_sessions_profile" );
+ TQT_SLOT( slotSaveSessionsProfile() ), m_shortcuts, "save_sessions_profile" );
//help menu
if (m_help)
- m_help->setAccel(QKeySequence(),m_help->idAt(0));
+ m_help->setAccel(TQKeySequence(),m_help->idAt(0));
// Don't steal F1 (handbook) accel (esp. since it not visible in
// "Configure Shortcuts").
m_closeSession = new KAction(i18n("C&lose Session"), "fileclose", 0, this,
- SLOT(confirmCloseCurrentSession()), m_shortcuts, "close_session");
- m_print = new KAction(i18n("&Print Screen..."), "fileprint", 0, this, SLOT( slotPrint() ), m_shortcuts, "file_print");
- m_quit = new KAction(i18n("&Quit"), "exit", 0, this, SLOT( close() ), m_shortcuts, "file_quit");
+ TQT_SLOT(confirmCloseCurrentSession()), m_shortcuts, "close_session");
+ m_print = new KAction(i18n("&Print Screen..."), "fileprint", 0, this, TQT_SLOT( slotPrint() ), m_shortcuts, "file_print");
+ m_quit = new KAction(i18n("&Quit"), "exit", 0, this, TQT_SLOT( close() ), m_shortcuts, "file_quit");
KShortcut shortcut(Qt::CTRL+Qt::ALT+Qt::Key_N);
shortcut.append(KShortcut(Qt::CTRL+Qt::SHIFT+Qt::Key_N));
- new KAction(i18n("New Session"), shortcut, this, SLOT(newSession()), m_shortcuts, "new_session");
- new KAction(i18n("Activate Menu"), Qt::CTRL+Qt::ALT+Qt::Key_M, this, SLOT(activateMenu()), m_shortcuts, "activate_menu");
- new KAction(i18n("List Sessions"), 0, this, SLOT(listSessions()), m_shortcuts, "list_sessions");
-
- m_moveSessionLeft = new KAction(i18n("&Move Session Left"), QApplication::reverseLayout() ? "forward" : "back",
- QApplication::reverseLayout() ? Qt::CTRL+Qt::SHIFT+Qt::Key_Right : Qt::CTRL+Qt::SHIFT+Qt::Key_Left, this,
- SLOT(moveSessionLeft()), m_shortcuts, "move_session_left");
- m_moveSessionRight = new KAction(i18n("M&ove Session Right"), QApplication::reverseLayout() ? "back" : "forward",
- QApplication::reverseLayout() ? Qt::CTRL+Qt::SHIFT+Qt::Key_Left : Qt::CTRL+Qt::SHIFT+Qt::Key_Right, this,
- SLOT(moveSessionRight()), m_shortcuts, "move_session_right");
-
- new KAction(i18n("Go to Previous Session"), QApplication::reverseLayout() ? Qt::SHIFT+Qt::Key_Right : Qt::SHIFT+Qt::Key_Left,
- this, SLOT(prevSession()), m_shortcuts, "previous_session");
- new KAction(i18n("Go to Next Session"), QApplication::reverseLayout() ? Qt::SHIFT+Qt::Key_Left : Qt::SHIFT+Qt::Key_Right,
- this, SLOT(nextSession()), m_shortcuts, "next_session");
+ new KAction(i18n("New Session"), shortcut, this, TQT_SLOT(newSession()), m_shortcuts, "new_session");
+ new KAction(i18n("Activate Menu"), Qt::CTRL+Qt::ALT+Qt::Key_M, this, TQT_SLOT(activateMenu()), m_shortcuts, "activate_menu");
+ new KAction(i18n("List Sessions"), 0, this, TQT_SLOT(listSessions()), m_shortcuts, "list_sessions");
+
+ m_moveSessionLeft = new KAction(i18n("&Move Session Left"), TQApplication::reverseLayout() ? "forward" : "back",
+ TQApplication::reverseLayout() ? Qt::CTRL+Qt::SHIFT+Qt::Key_Right : Qt::CTRL+Qt::SHIFT+Qt::Key_Left, this,
+ TQT_SLOT(moveSessionLeft()), m_shortcuts, "move_session_left");
+ m_moveSessionRight = new KAction(i18n("M&ove Session Right"), TQApplication::reverseLayout() ? "back" : "forward",
+ TQApplication::reverseLayout() ? Qt::CTRL+Qt::SHIFT+Qt::Key_Left : Qt::CTRL+Qt::SHIFT+Qt::Key_Right, this,
+ TQT_SLOT(moveSessionRight()), m_shortcuts, "move_session_right");
+
+ new KAction(i18n("Go to Previous Session"), TQApplication::reverseLayout() ? Qt::SHIFT+Qt::Key_Right : Qt::SHIFT+Qt::Key_Left,
+ this, TQT_SLOT(prevSession()), m_shortcuts, "previous_session");
+ new KAction(i18n("Go to Next Session"), TQApplication::reverseLayout() ? Qt::SHIFT+Qt::Key_Left : Qt::SHIFT+Qt::Key_Right,
+ this, TQT_SLOT(nextSession()), m_shortcuts, "next_session");
for (int i=1;i<13;i++) { // Due to 12 function keys?
- new KAction(i18n("Switch to Session %1").arg(i), 0, this, SLOT(switchToSession()), m_shortcuts, QString().sprintf("switch_to_session_%02d", i).latin1());
+ new KAction(i18n("Switch to Session %1").arg(i), 0, this, TQT_SLOT(switchToSession()), m_shortcuts, TQString().sprintf("switch_to_session_%02d", i).latin1());
}
- new KAction(i18n("Enlarge Font"), 0, this, SLOT(biggerFont()), m_shortcuts, "bigger_font");
- new KAction(i18n("Shrink Font"), 0, this, SLOT(smallerFont()), m_shortcuts, "smaller_font");
+ new KAction(i18n("Enlarge Font"), 0, this, TQT_SLOT(biggerFont()), m_shortcuts, "bigger_font");
+ new KAction(i18n("Shrink Font"), 0, this, TQT_SLOT(smallerFont()), m_shortcuts, "smaller_font");
- new KAction(i18n("Toggle Bidi"), Qt::CTRL+Qt::ALT+Qt::Key_B, this, SLOT(toggleBidi()), m_shortcuts, "toggle_bidi");
+ new KAction(i18n("Toggle Bidi"), Qt::CTRL+Qt::ALT+Qt::Key_B, this, TQT_SLOT(toggleBidi()), m_shortcuts, "toggle_bidi");
// Should we load all *.desktop files now? Required for Session shortcuts.
if ( KConfigGroup(KGlobal::config(), "General").readBoolEntry("SessionShortcutsEnabled", false) ) {
@@ -1158,7 +1158,7 @@ void Konsole::makeBasicGUI()
m_sessionList = new KPopupMenu(this);
KAcceleratorManager::manage( m_sessionList );
- connect(m_sessionList, SIGNAL(activated(int)), SLOT(activateSession(int)));
+ connect(m_sessionList, TQT_SIGNAL(activated(int)), TQT_SLOT(activateSession(int)));
}
/**
@@ -1287,10 +1287,10 @@ void Konsole::configureRequest(TEWidget* _te, int state, int x, int y)
makeGUI();
KPopupMenu *menu = (state & ControlButton) ? m_session : m_rightButton;
if (menu)
- menu->popup(_te->mapToGlobal(QPoint(x,y)));
+ menu->popup(_te->mapToGlobal(TQPoint(x,y)));
}
-void Konsole::slotTabContextMenu(QWidget* _te, const QPoint & pos)
+void Konsole::slotTabContextMenu(TQWidget* _te, const TQPoint & pos)
{
if (!m_menuCreated)
makeGUI();
@@ -1306,7 +1306,7 @@ void Konsole::slotTabContextMenu(QWidget* _te, const QPoint & pos)
m_tabPopupTabsMenu->clear();
int counter=0;
for (TESession *ses = sessions.first(); ses; ses = sessions.next()) {
- QString title=ses->Title();
+ TQString title=ses->Title();
m_tabPopupTabsMenu->insertItem(SmallIcon(ses->IconName()),title.replace('&',"&&"),counter++);
}
@@ -1323,7 +1323,7 @@ void Konsole::slotTabRenameSession() {
void Konsole::slotTabSelectColor()
{
- QColor color = tabwidget->tabColor( m_contextMenuSession->widget() );
+ TQColor color = tabwidget->tabColor( m_contextMenuSession->widget() );
int result = KColorDialog::getColor( color );
if ( result == KColorDialog::Accepted )
@@ -1351,7 +1351,7 @@ void Konsole::slotTabCloseSession()
confirmCloseCurrentSession(m_contextMenuSession);
}
-void Konsole::slotTabbarContextMenu(const QPoint & pos)
+void Konsole::slotTabbarContextMenu(const TQPoint & pos)
{
if (!m_menuCreated)
makeGUI();
@@ -1365,9 +1365,9 @@ void Konsole::slotTabSetViewOptions(int mode)
for(int i = 0; i < tabwidget->count(); i++) {
- QWidget *page = tabwidget->page(i);
- QIconSet icon = iconSetForSession(sessions.at(i));
- QString title;
+ TQWidget *page = tabwidget->page(i);
+ TQIconSet icon = iconSetForSession(sessions.at(i));
+ TQString title;
if (b_matchTabWinTitle)
title = sessions.at(i)->fullTitle();
else
@@ -1379,10 +1379,10 @@ void Konsole::slotTabSetViewOptions(int mode)
tabwidget->changeTab(page, icon, title);
break;
case ShowTextOnly:
- tabwidget->changeTab(page, QIconSet(), title);
+ tabwidget->changeTab(page, TQIconSet(), title);
break;
case ShowIconOnly:
- tabwidget->changeTab(page, icon, QString::null);
+ tabwidget->changeTab(page, icon, TQString::null);
break;
}
}
@@ -1414,16 +1414,16 @@ void Konsole::slotSaveSessionsProfile()
{
bool ok;
- QString prof = KInputDialog::getText( i18n( "Save Sessions Profile" ),
+ TQString prof = KInputDialog::getText( i18n( "Save Sessions Profile" ),
i18n( "Enter name under which the profile should be saved:" ),
- QString::null, &ok, this );
+ TQString::null, &ok, this );
if ( ok ) {
- QString path = locateLocal( "data",
- QString::fromLatin1( "konsole/profiles/" ) + prof,
+ TQString path = locateLocal( "data",
+ TQString::fromLatin1( "konsole/profiles/" ) + prof,
KGlobal::instance() );
- if ( QFile::exists( path ) )
- QFile::remove( path );
+ if ( TQFile::exists( path ) )
+ TQFile::remove( path );
KSimpleConfig cfg( path );
savePropertiesInternal(&cfg,1);
@@ -1434,7 +1434,7 @@ void Konsole::slotSaveSessionsProfile()
void Konsole::saveProperties(KConfig* config) {
uint counter=0;
uint active=0;
- QString key;
+ TQString key;
if (config != KGlobal::config())
{
@@ -1443,42 +1443,42 @@ void Konsole::saveProperties(KConfig* config) {
sessions.first();
while(counter < sessions.count())
{
- key = QString("Title%1").arg(counter);
+ key = TQString("Title%1").arg(counter);
config->writeEntry(key, sessions.current()->Title());
- key = QString("Schema%1").arg(counter);
+ key = TQString("Schema%1").arg(counter);
config->writeEntry(key, colors->find( sessions.current()->schemaNo() )->relPath());
- key = QString("Encoding%1").arg(counter);
+ key = TQString("Encoding%1").arg(counter);
config->writeEntry(key, sessions.current()->encodingNo());
- key = QString("Args%1").arg(counter);
+ key = TQString("Args%1").arg(counter);
config->writeEntry(key, sessions.current()->getArgs());
- key = QString("Pgm%1").arg(counter);
+ key = TQString("Pgm%1").arg(counter);
config->writeEntry(key, sessions.current()->getPgm());
- key = QString("SessionFont%1").arg(counter);
+ key = TQString("SessionFont%1").arg(counter);
config->writeEntry(key, (sessions.current()->widget())->getVTFont());
- key = QString("Term%1").arg(counter);
+ key = TQString("Term%1").arg(counter);
config->writeEntry(key, sessions.current()->Term());
- key = QString("KeyTab%1").arg(counter);
+ key = TQString("KeyTab%1").arg(counter);
config->writeEntry(key, sessions.current()->keymap());
- key = QString("Icon%1").arg(counter);
+ key = TQString("Icon%1").arg(counter);
config->writeEntry(key, sessions.current()->IconName());
- key = QString("MonitorActivity%1").arg(counter);
+ key = TQString("MonitorActivity%1").arg(counter);
config->writeEntry(key, sessions.current()->isMonitorActivity());
- key = QString("MonitorSilence%1").arg(counter);
+ key = TQString("MonitorSilence%1").arg(counter);
config->writeEntry(key, sessions.current()->isMonitorSilence());
- key = QString("MasterMode%1").arg(counter);
+ key = TQString("MasterMode%1").arg(counter);
config->writeEntry(key, sessions.current()->isMasterMode());
- key = QString("TabColor%1").arg(counter);
+ key = TQString("TabColor%1").arg(counter);
config->writeEntry(key, tabwidget->tabColor((sessions.current())->widget()));
- key = QString("History%1").arg(counter);
+ key = TQString("History%1").arg(counter);
config->writeEntry(key, sessions.current()->history().getSize());
- key = QString("HistoryEnabled%1").arg(counter);
+ key = TQString("HistoryEnabled%1").arg(counter);
config->writeEntry(key, sessions.current()->history().isOn());
- QString cwd=sessions.current()->getCwd();
+ TQString cwd=sessions.current()->getCwd();
if (cwd.isEmpty())
cwd=sessions.current()->getInitial_cwd();
- key = QString("Cwd%1").arg(counter);
+ key = TQString("Cwd%1").arg(counter);
config->writePathEntry(key, cwd);
if (sessions.current()==se)
@@ -1508,7 +1508,7 @@ void Konsole::saveProperties(KConfig* config) {
if (selectSetEncoding)
{
- QString encoding = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
+ TQString encoding = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
config->writeEntry("EncodingName", encoding);
} else { // This will not always work (ie 'winsami' saves as 'ws2')
if (se) config->writeEntry("EncodingName", se->encoding());
@@ -1538,7 +1538,7 @@ void Konsole::saveProperties(KConfig* config) {
// So it has to apply the settings when reading them.
void Konsole::readProperties(KConfig* config)
{
- readProperties(config, QString::null, false);
+ readProperties(config, TQString::null, false);
}
// If --type option was given, load the corresponding schema instead of
@@ -1546,7 +1546,7 @@ void Konsole::readProperties(KConfig* config)
//
// When globalConfigOnly is true only the options that are shared among all
// konsoles are being read.
-void Konsole::readProperties(KConfig* config, const QString &schema, bool globalConfigOnly)
+void Konsole::readProperties(KConfig* config, const TQString &schema, bool globalConfigOnly)
{
if (config==KGlobal::config())
@@ -1557,11 +1557,11 @@ void Konsole::readProperties(KConfig* config, const QString &schema, bool global
b_bidiEnabled = config->readBoolEntry("EnableBidi",false);
s_word_seps= config->readEntry("wordseps",":@-./_~");
b_framevis = config->readBoolEntry("has frame",true);
- QPtrList<TEWidget> tes = activeTEs();
+ TQPtrList<TEWidget> tes = activeTEs();
for (TEWidget *_te = tes.first(); _te; _te = tes.next()) {
_te->setWordCharacters(s_word_seps);
_te->setTerminalSizeHint( config->readBoolEntry("TerminalSizeHint",false) );
- _te->setFrameStyle( b_framevis?(QFrame::WinPanel|QFrame::Sunken):QFrame::NoFrame );
+ _te->setFrameStyle( b_framevis?(TQFrame::WinPanel|TQFrame::Sunken):TQFrame::NoFrame );
_te->setBlinkingCursor(config->readBoolEntry("BlinkingCursor",false));
_te->setCtrlDrag(config->readBoolEntry("CtrlDrag",true));
_te->setCutToBeginningOfLine(config->readBoolEntry("CutToBeginningOfLine",false));
@@ -1596,7 +1596,7 @@ void Konsole::readProperties(KConfig* config, const QString &schema, bool global
// (1) set menu items and Konsole members
- QFont tmpFont = KGlobalSettings::fixedFont();
+ TQFont tmpFont = KGlobalSettings::fixedFont();
defaultFont = config->readFontEntry("defaultfont", &tmpFont);
//set the schema
@@ -1618,7 +1618,7 @@ void Konsole::readProperties(KConfig* config, const QString &schema, bool global
{
if (!rootxpms[te])
rootxpms.insert( te, new KRootPixmap(te) );
- rootxpms[te]->setFadeEffect(sch->tr_x(), QColor(sch->tr_r(), sch->tr_g(), sch->tr_b()));
+ rootxpms[te]->setFadeEffect(sch->tr_x(), TQColor(sch->tr_r(), sch->tr_g(), sch->tr_b()));
}
else
{
@@ -1648,7 +1648,7 @@ void Konsole::readProperties(KConfig* config, const QString &schema, bool global
// The scrollbar location only needs to be changed when the given
// profile scrollbar entry differs from the konsolerc scrollbar entry.
- QPtrList<TEWidget> tes = activeTEs();
+ TQPtrList<TEWidget> tes = activeTEs();
for (TEWidget *_te = tes.first(); _te; _te = tes.next()) {
if (_te->getScrollbarLocation() != n_scroll)
_te->setScrollbarLocation(n_scroll);
@@ -1705,7 +1705,7 @@ void Konsole::pixmap_menu_activated(int item, TEWidget* tewidget)
if (!tewidget)
tewidget=te;
if (item <= 1) pmPath = "";
- QPixmap pm(pmPath);
+ TQPixmap pm(pmPath);
if (pm.isNull()) {
pmPath = "";
item = 1;
@@ -1721,7 +1721,7 @@ void Konsole::pixmap_menu_activated(int item, TEWidget* tewidget)
tewidget->setBackgroundPixmap(pm);
break;
case 3: // center
- { QPixmap bgPixmap;
+ { TQPixmap bgPixmap;
bgPixmap.resize(tewidget->size());
bgPixmap.fill(tewidget->getDefaultBackColor());
bitBlt( &bgPixmap, ( tewidget->size().width() - pm.width() ) / 2,
@@ -1736,7 +1736,7 @@ void Konsole::pixmap_menu_activated(int item, TEWidget* tewidget)
{
float sx = (float)tewidget->size().width() / pm.width();
float sy = (float)tewidget->size().height() / pm.height();
- QWMatrix matrix;
+ TQWMatrix matrix;
matrix.scale( sx, sy );
tewidget->setBackgroundPixmap(pm.xForm( matrix ));
}
@@ -1755,7 +1755,7 @@ void Konsole::slotSelectScrollbar() {
if (m_menuCreated)
n_scroll = selectScrollbar->currentItem();
- QPtrList<TEWidget> tes = activeTEs();
+ TQPtrList<TEWidget> tes = activeTEs();
for (TEWidget *_te = tes.first(); _te; _te = tes.next())
_te->setScrollbarLocation(n_scroll);
activateSession(); // maybe helps in bg
@@ -1764,16 +1764,16 @@ void Konsole::slotSelectScrollbar() {
void Konsole::checkBitmapFonts()
{
{
- QFont f;
+ TQFont f;
f.setRawName("-misc-console-medium-r-normal--16-160-72-72-c-80-iso10646-1");
- QFontInfo fi( f );
+ TQFontInfo fi( f );
if ( !fi.exactMatch() )
b_installBitmapFonts = true;
}
{
- QFont f;
+ TQFont f;
f.setRawName("-misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1");
- QFontInfo fi( f );
+ TQFontInfo fi( f );
if ( !fi.exactMatch() )
b_installBitmapFonts = true;
}
@@ -1787,18 +1787,18 @@ void Konsole::slotInstallBitmapFonts()
if ( !b_installBitmapFonts )
return;
- QStringList sl_installFonts;
+ TQStringList sl_installFonts;
{
- QFont f;
+ TQFont f;
f.setRawName("-misc-console-medium-r-normal--16-160-72-72-c-80-iso10646-1");
- QFontInfo fi( f );
+ TQFontInfo fi( f );
if ( !fi.exactMatch() )
sl_installFonts << "console8x16.pcf.gz";
}
{
- QFont f;
+ TQFont f;
f.setRawName("-misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1");
- QFontInfo fi( f );
+ TQFontInfo fi( f );
if ( !fi.exactMatch() )
sl_installFonts << "9x15.pcf.gz";
}
@@ -1812,10 +1812,10 @@ void Konsole::slotInstallBitmapFonts()
KGuiItem( i18n("&Install" ) ),
i18n("Do Not Install") ) == KMessageBox::Yes )
{
- for ( QStringList::iterator it = sl_installFonts.begin();
+ for ( TQStringList::iterator it = sl_installFonts.begin();
it != sl_installFonts.end(); ++it )
{
- QString sf = "fonts/" + *it;
+ TQString sf = "fonts/" + *it;
if ( KIO::NetAccess::copy( locate( "appdata", sf ),
"fonts:/Personal/", 0 ) )
{
@@ -1833,8 +1833,8 @@ void Konsole::slotInstallBitmapFonts()
void Konsole::slotSelectFont() {
if ( !se ) return;
- QFont font = se->widget()->getVTFont();
- if ( KFontDialog::getFont( font, true ) != QDialog::Accepted )
+ TQFont font = se->widget()->getVTFont();
+ if ( KFontDialog::getFont( font, true ) != TQDialog::Accepted )
return;
se->widget()->setVTFont( font );
@@ -1864,7 +1864,7 @@ void Konsole::updateSchemaMenu()
{
ColorSchema* s = (ColorSchema*)colors->at(i);
assert( s );
- QString title=s->title();
+ TQString title=s->title();
m_schema->insertItem(title.replace('&',"&&"),s->numb(),0);
}
@@ -1907,7 +1907,7 @@ void Konsole::slotToggleMenubar() {
}
if (!showMenubar->isChecked()) {
setCaption(i18n("Use the right mouse button to bring back the menu"));
- QTimer::singleShot(5000,this,SLOT(updateTitle()));
+ TQTimer::singleShot(5000,this,TQT_SLOT(updateTitle()));
}
updateRMBMenu();
}
@@ -1917,7 +1917,7 @@ void Konsole::initTEWidget(TEWidget* new_te, TEWidget* default_te)
new_te->setWordCharacters(default_te->wordCharacters());
new_te->setTerminalSizeHint(default_te->isTerminalSizeHint());
new_te->setTerminalSizeStartup(false);
- new_te->setFrameStyle(b_framevis?(QFrame::WinPanel|QFrame::Sunken):QFrame::NoFrame);
+ new_te->setFrameStyle(b_framevis?(TQFrame::WinPanel|TQFrame::Sunken):TQFrame::NoFrame);
new_te->setBlinkingCursor(default_te->blinkingCursor());
new_te->setCtrlDrag(default_te->ctrlDrag());
new_te->setCutToBeginningOfLine(default_te->cutToBeginningOfLine());
@@ -1931,28 +1931,28 @@ void Konsole::initTEWidget(TEWidget* new_te, TEWidget* default_te)
new_te->setMinimumSize(150,70);
}
-void Konsole::createSessionTab(TEWidget *widget, const QIconSet &iconSet,
- const QString &text, int index)
+void Konsole::createSessionTab(TEWidget *widget, const TQIconSet &iconSet,
+ const TQString &text, int index)
{
switch(m_tabViewMode) {
case ShowIconAndText:
tabwidget->insertTab(widget, iconSet, text, index);
break;
case ShowTextOnly:
- tabwidget->insertTab(widget, QIconSet(), text, index);
+ tabwidget->insertTab(widget, TQIconSet(), text, index);
break;
case ShowIconOnly:
- tabwidget->insertTab(widget, iconSet, QString::null, index);
+ tabwidget->insertTab(widget, iconSet, TQString::null, index);
break;
}
if ( m_tabColor.isValid() )
tabwidget->setTabColor(widget, m_tabColor);
}
-QIconSet Konsole::iconSetForSession(TESession *session) const
+TQIconSet Konsole::iconSetForSession(TESession *session) const
{
if (m_tabViewMode == ShowTextOnly)
- return QIconSet();
+ return TQIconSet();
return SmallIconSet(session->isMasterMode() ? "remote" : session->IconName());
}
@@ -1970,13 +1970,13 @@ void Konsole::slotSelectTabbar() {
if ( tabwidget->isTabBarHidden() )
tabwidget->setTabBarHidden( false );
if ( n_tabbar == TabTop )
- tabwidget->setTabPosition( QTabWidget::Top );
+ tabwidget->setTabPosition( TQTabWidget::Top );
else
- tabwidget->setTabPosition( QTabWidget::Bottom );
+ tabwidget->setTabPosition( TQTabWidget::Bottom );
}
/* FIXME: Still necessary ? */
- QPtrDictIterator<KRootPixmap> it(rootxpms);
+ TQPtrDictIterator<KRootPixmap> it(rootxpms);
for (;it.current();++it)
it.current()->repaint(true);
@@ -2006,7 +2006,7 @@ void Konsole::slotConfigureKeys()
KKeyDialog::configure(m_shortcuts);
m_shortcuts->writeShortcutSettings();
- QStringList ctrlKeys;
+ TQStringList ctrlKeys;
for ( uint i = 0; i < m_shortcuts->count(); i++ )
{
@@ -2021,7 +2021,7 @@ void Konsole::slotConfigureKeys()
// Are there any shortcuts for Session Menu entries?
if ( !b_sessionShortcutsEnabled &&
m_shortcuts->action( i )->shortcut().count() &&
- QString(m_shortcuts->action( i )->name()).startsWith("SSC_") ) {
+ TQString(m_shortcuts->action( i )->name()).startsWith("SSC_") ) {
b_sessionShortcutsEnabled = true;
KConfigGroup group(KGlobal::config(), "General");
group.writeEntry("SessionShortcutsEnabled", true);
@@ -2047,7 +2047,7 @@ void Konsole::slotConfigureKeys()
void Konsole::slotConfigure()
{
- QStringList args;
+ TQStringList args;
args << "kcmkonsole";
KApplication::kdeinitExec( "kcmshell", args );
}
@@ -2055,18 +2055,18 @@ void Konsole::slotConfigure()
void Konsole::reparseConfiguration()
{
KGlobal::config()->reparseConfiguration();
- readProperties(KGlobal::config(), QString::null, true);
+ readProperties(KGlobal::config(), TQString::null, true);
// The .desktop files may have been changed by user...
b_sessionShortcutsMapped = false;
// Mappings may have to be changed...get a fresh mapper.
- disconnect( sessionNumberMapper, SIGNAL( mapped( int ) ),
- this, SLOT( newSessionTabbar( int ) ) );
+ disconnect( sessionNumberMapper, TQT_SIGNAL( mapped( int ) ),
+ this, TQT_SLOT( newSessionTabbar( int ) ) );
delete sessionNumberMapper;
- sessionNumberMapper = new QSignalMapper( this );
- connect( sessionNumberMapper, SIGNAL( mapped( int ) ),
- this, SLOT( newSessionTabbar( int ) ) );
+ sessionNumberMapper = new TQSignalMapper( this );
+ connect( sessionNumberMapper, TQT_SIGNAL( mapped( int ) ),
+ this, TQT_SLOT( newSessionTabbar( int ) ) );
sl_sessionShortCuts.clear();
buildSessionMenus();
@@ -2077,12 +2077,12 @@ void Konsole::reparseConfiguration()
{
KAction* action = m_shortcuts->action( i );
bool b_foundSession = false;
- if ( QString(action->name()).startsWith("SSC_") ) {
- QString name = QString(action->name());
+ if ( TQString(action->name()).startsWith("SSC_") ) {
+ TQString name = TQString(action->name());
// Check to see if shortcut's session has been loaded.
- for ( QStringList::Iterator it = sl_sessionShortCuts.begin(); it != sl_sessionShortCuts.end(); ++it ) {
- if ( QString::compare( *it, name ) == 0 ) {
+ for ( TQStringList::Iterator it = sl_sessionShortCuts.begin(); it != sl_sessionShortCuts.end(); ++it ) {
+ if ( TQString::compare( *it, name ) == 0 ) {
b_foundSession = true;
break;
}
@@ -2128,7 +2128,7 @@ void Konsole::reparseConfiguration()
void Konsole::changeTabTextColor( TESession* ses, int rgb )
{
if ( !ses ) return;
- QColor color;
+ TQColor color;
color.setRgb( rgb );
if ( !color.isValid() ) {
kdWarning()<<" Invalid RGB color "<<rgb<<endl;
@@ -2208,21 +2208,21 @@ void Konsole::updateTitle(TESession* _se)
setIconText( _se->IconText() );
}
tabwidget->setTabIconSet(_se->widget(), iconSetForSession(_se));
- QString icon = _se->IconName();
+ TQString icon = _se->IconName();
KRadioAction *ra = session2action.find(_se);
if (ra && (ra->icon() != icon))
ra->setIcon(icon);
if (m_tabViewMode == ShowIconOnly)
- tabwidget->changeTab( _se->widget(), QString::null );
+ tabwidget->changeTab( _se->widget(), TQString::null );
else if (b_matchTabWinTitle)
tabwidget->setTabLabel( _se->widget(), _se->fullTitle().replace('&',"&&"));
}
-void Konsole::initSessionFont(QFont font) {
+void Konsole::initSessionFont(TQFont font) {
te->setVTFont( font );
}
-void Konsole::initSessionKeyTab(const QString &keyTab) {
+void Konsole::initSessionKeyTab(const TQString &keyTab) {
se->setKeymap(keyTab);
updateKeytabMenu();
}
@@ -2269,7 +2269,7 @@ void Konsole::updateFullScreen( bool on )
updateTitle(); // restore caption of window
}
updateRMBMenu();
- te->setFrameStyle( b_framevis && !b_fullscreen ?(QFrame::WinPanel|QFrame::Sunken):QFrame::NoFrame );
+ te->setFrameStyle( b_framevis && !b_fullscreen ?(TQFrame::WinPanel|TQFrame::Sunken):TQFrame::NoFrame );
}
/* --| sessions |------------------------------------------------------------ */
@@ -2285,16 +2285,16 @@ void Konsole::updateFullScreen( bool on )
void Konsole::disableMasterModeConnections()
{
- QPtrListIterator<TESession> from_it(sessions);
+ TQPtrListIterator<TESession> from_it(sessions);
for (; from_it.current(); ++from_it) {
TESession *from = from_it.current();
if (from->isMasterMode()) {
- QPtrListIterator<TESession> to_it(sessions);
+ TQPtrListIterator<TESession> to_it(sessions);
for (; to_it.current(); ++to_it) {
TESession *to = to_it.current();
if (to!=from)
- disconnect(from->widget(),SIGNAL(keyPressedSignal(QKeyEvent*)),
- to->getEmulation(),SLOT(onKeyPress(QKeyEvent*)));
+ disconnect(from->widget(),TQT_SIGNAL(keyPressedSignal(TQKeyEvent*)),
+ to->getEmulation(),TQT_SLOT(onKeyPress(TQKeyEvent*)));
}
}
}
@@ -2302,16 +2302,16 @@ void Konsole::disableMasterModeConnections()
void Konsole::enableMasterModeConnections()
{
- QPtrListIterator<TESession> from_it(sessions);
+ TQPtrListIterator<TESession> from_it(sessions);
for (; from_it.current(); ++from_it) {
TESession *from = from_it.current();
if (from->isMasterMode()) {
- QPtrListIterator<TESession> to_it(sessions);
+ TQPtrListIterator<TESession> to_it(sessions);
for (; to_it.current(); ++to_it) {
TESession *to = to_it.current();
if (to!=from) {
- connect(from->widget(),SIGNAL(keyPressedSignal(QKeyEvent*)),
- to->getEmulation(),SLOT(onKeyPress(QKeyEvent*)));
+ connect(from->widget(),TQT_SIGNAL(keyPressedSignal(TQKeyEvent*)),
+ to->getEmulation(),TQT_SLOT(onKeyPress(TQKeyEvent*)));
}
}
}
@@ -2319,7 +2319,7 @@ void Konsole::enableMasterModeConnections()
}
}
-void Konsole::feedAllSessions(const QString &text)
+void Konsole::feedAllSessions(const TQString &text)
{
if (!te) return;
bool oldMasterMode = se->isMasterMode();
@@ -2329,9 +2329,9 @@ void Konsole::feedAllSessions(const QString &text)
setMasterMode(false);
}
-void Konsole::sendAllSessions(const QString &text)
+void Konsole::sendAllSessions(const TQString &text)
{
- QString newtext=text;
+ TQString newtext=text;
newtext.append("\r");
feedAllSessions(newtext);
}
@@ -2343,9 +2343,9 @@ KURL Konsole::baseURL() const
return url;
}
-void Konsole::enterURL(const QString& URL, const QString&)
+void Konsole::enterURL(const TQString& URL, const TQString&)
{
- QString path, login, host, newtext;
+ TQString path, login, host, newtext;
if (URL.startsWith("file:")) {
KURL uglyurl(URL);
@@ -2358,7 +2358,7 @@ void Konsole::enterURL(const QString& URL, const QString&)
newtext = u.protocol();
bool isSSH = (newtext == "ssh");
if (u.port() && isSSH)
- newtext += " -p " + QString().setNum(u.port());
+ newtext += " -p " + TQString().setNum(u.port());
if (u.hasUser())
newtext += " -l " + u.user();
@@ -2368,7 +2368,7 @@ void Konsole::enterURL(const QString& URL, const QString&)
if (u.hasHost()) {
newtext = newtext + " " + u.host();
if (u.port() && !isSSH)
- newtext += QString(" %1").arg(u.port());
+ newtext += TQString(" %1").arg(u.port());
se->setUserTitle(31,""); // we don't know remote cwd
te->emitText(newtext + "\r");
}
@@ -2406,12 +2406,12 @@ void Konsole::runSession(TESession* s)
// give some time to get through the
// resize events before starting up.
- QTimer::singleShot(100,s,SLOT(run()));
+ TQTimer::singleShot(100,s,TQT_SLOT(run()));
}
void Konsole::addSession(TESession* s)
{
- QString newTitle = s->Title();
+ TQString newTitle = s->Title();
bool nameOk;
int count = 1;
@@ -2440,7 +2440,7 @@ void Konsole::addSession(TESession* s)
s->IconName(),
0,
this,
- SLOT(activateSession()),
+ TQT_SLOT(activateSession()),
m_shortcuts);
ra->setExclusiveGroup("sessions");
ra->setChecked(true);
@@ -2466,12 +2466,12 @@ void Konsole::addSession(TESession* s)
m_removeSessionButton->setEnabled(tabwidget->count()>1);
}
-QString Konsole::currentSession()
+TQString Konsole::currentSession()
{
return se->SessionId();
}
-QString Konsole::sessionId(const int position)
+TQString Konsole::sessionId(const int position)
{
if (position<=0 || position>(int)sessions.count())
return "";
@@ -2486,16 +2486,16 @@ void Konsole::listSessions()
m_sessionList->insertTitle(i18n("Session List"));
m_sessionList->setKeyboardShortcutsEnabled(true);
for (TESession *ses = sessions.first(); ses; ses = sessions.next()) {
- QString title=ses->Title();
+ TQString title=ses->Title();
m_sessionList->insertItem(SmallIcon(ses->IconName()),title.replace('&',"&&"),counter++);
}
m_sessionList->adjustSize();
- m_sessionList->popup(mapToGlobal(QPoint((width()/2)-(m_sessionList->width()/2),(height()/2)-(m_sessionList->height()/2))));
+ m_sessionList->popup(mapToGlobal(TQPoint((width()/2)-(m_sessionList->width()/2),(height()/2)-(m_sessionList->height()/2))));
}
void Konsole::switchToSession()
{
- activateSession( QString( sender()->name() ).right( 2 ).toInt() -1 );
+ activateSession( TQString( sender()->name() ).right( 2 ).toInt() -1 );
}
void Konsole::activateSession(int position)
@@ -2505,13 +2505,13 @@ void Konsole::activateSession(int position)
activateSession( sessions.at(position) );
}
-void Konsole::activateSession(QWidget* w)
+void Konsole::activateSession(TQWidget* w)
{
activateSession(tabwidget->indexOf(w));
w->setFocus();
}
-void Konsole::activateSession(const QString &sessionId)
+void Konsole::activateSession(const TQString &sessionId)
{
TESession* activate=NULL;
@@ -2534,7 +2534,7 @@ void Konsole::activateSession()
{
TESession* s = NULL;
// finds the session based on which button was activated
- QPtrDictIterator<TESession> it( action2session ); // iterator for dict
+ TQPtrDictIterator<TESession> it( action2session ); // iterator for dict
while ( it.current() )
{
KRadioAction *ra = (KRadioAction*)it.currentKey();
@@ -2579,7 +2579,7 @@ void Konsole::activateSession(TESession *s)
}
ra->setChecked(true);
- QTimer::singleShot(1,this,SLOT(allowPrevNext())); // hack, hack, hack
+ TQTimer::singleShot(1,this,TQT_SLOT(allowPrevNext())); // hack, hack, hack
tabwidget->showPage( se->widget() );
te = se->widget();
@@ -2619,7 +2619,7 @@ void Konsole::slotUpdateSessionConfig(TESession *session)
activateSession(se);
}
-void Konsole::slotResizeSession(TESession *session, QSize size)
+void Konsole::slotResizeSession(TESession *session, TQSize size)
{
TESession *oldSession = se;
if (se != session)
@@ -2629,7 +2629,7 @@ void Konsole::slotResizeSession(TESession *session, QSize size)
}
// Called by newSession and DCOP function below
-void Konsole::setSessionEncoding( const QString &encoding, TESession *session )
+void Konsole::setSessionEncoding( const TQString &encoding, TESession *session )
{
if ( encoding.isEmpty() )
return;
@@ -2638,8 +2638,8 @@ void Konsole::setSessionEncoding( const QString &encoding, TESession *session )
session = se;
bool found = false;
- QString enc = KGlobal::charsets()->encodingForName(encoding);
- QTextCodec * qtc = KGlobal::charsets()->codecForName(enc, found);
+ TQString enc = KGlobal::charsets()->encodingForName(encoding);
+ TQTextCodec * qtc = KGlobal::charsets()->codecForName(enc, found);
if ( !found || !qtc )
return;
@@ -2647,13 +2647,13 @@ void Konsole::setSessionEncoding( const QString &encoding, TESession *session )
// it corresponds to.
int i = 0;
bool found_encoding = false;
- QStringList encodingNames = KGlobal::charsets()->descriptiveEncodingNames();
- QStringList::ConstIterator it = encodingNames.begin();
- QString t_encoding = encoding.lower();
+ TQStringList encodingNames = KGlobal::charsets()->descriptiveEncodingNames();
+ TQStringList::ConstIterator it = encodingNames.begin();
+ TQString t_encoding = encoding.lower();
while ( it != encodingNames.end() && !found_encoding )
{
- if ( QString::compare( KGlobal::charsets()->encodingForName(*it),
+ if ( TQString::compare( KGlobal::charsets()->encodingForName(*it),
t_encoding ) == 0 ) {
found_encoding = true;
}
@@ -2676,19 +2676,19 @@ void Konsole::setSessionEncoding( const QString &encoding, TESession *session )
}
// Called via DCOP only
-void Konsole::slotSetSessionEncoding(TESession *session, const QString &encoding)
+void Konsole::slotSetSessionEncoding(TESession *session, const TQString &encoding)
{
setSessionEncoding( encoding, session );
}
-void Konsole::slotGetSessionSchema(TESession *session, QString &schema)
+void Konsole::slotGetSessionSchema(TESession *session, TQString &schema)
{
int no = session->schemaNo();
ColorSchema* s = colors->find( no );
schema = s->relPath();
}
-void Konsole::slotSetSessionSchema(TESession *session, const QString &schema)
+void Konsole::slotSetSessionSchema(TESession *session, const TQString &schema)
{
ColorSchema* s = colors->find( schema );
setSchema(s, session->widget());
@@ -2710,7 +2710,7 @@ KSimpleConfig *Konsole::defaultSession()
return m_defaultSession;
}
-void Konsole::setDefaultSession(const QString &filename)
+void Konsole::setDefaultSession(const TQString &filename)
{
delete m_defaultSession;
m_defaultSession = new KSimpleConfig(locate("appdata", filename), true /* read only */);
@@ -2720,16 +2720,16 @@ void Konsole::setDefaultSession(const QString &filename)
m_defaultSessionFilename=filename;
}
-void Konsole::newSession(const QString &pgm, const QStrList &args, const QString &term, const QString &icon, const QString &title, const QString &cwd)
+void Konsole::newSession(const TQString &pgm, const TQStrList &args, const TQString &term, const TQString &icon, const TQString &title, const TQString &cwd)
{
KSimpleConfig *co = defaultSession();
newSession(co, pgm, args, term, icon, title, cwd);
}
-QString Konsole::newSession()
+TQString Konsole::newSession()
{
KSimpleConfig *co = defaultSession();
- return newSession(co, QString::null, QStrList());
+ return newSession(co, TQString::null, TQStrList());
}
void Konsole::newSession(int i)
@@ -2778,7 +2778,7 @@ void Konsole::newSessionTabbar(int i)
}
}
-QString Konsole::newSession(const QString &type)
+TQString Konsole::newSession(const TQString &type)
{
KSimpleConfig *co;
if (type.isEmpty())
@@ -2788,18 +2788,18 @@ QString Konsole::newSession(const QString &type)
return newSession(co);
}
-QString Konsole::newSession(KSimpleConfig *co, QString program, const QStrList &args,
- const QString &_term,const QString &_icon,
- const QString &_title, const QString &_cwd)
+TQString Konsole::newSession(KSimpleConfig *co, TQString program, const TQStrList &args,
+ const TQString &_term,const TQString &_icon,
+ const TQString &_title, const TQString &_cwd)
{
- QString emu = "xterm";
- QString icon = "konsole";
- QString key;
- QString sch = s_kconfigSchema;
- QString txt;
- QString cwd;
- QFont font = defaultFont;
- QStrList cmdArgs;
+ TQString emu = "xterm";
+ TQString icon = "konsole";
+ TQString key;
+ TQString sch = s_kconfigSchema;
+ TQString txt;
+ TQString cwd;
+ TQFont font = defaultFont;
+ TQStrList cmdArgs;
if (co) {
co->setDesktopGroup();
@@ -2833,14 +2833,14 @@ QString Konsole::newSession(KSimpleConfig *co, QString program, const QStrList &
cmdArgs = args;
}
else {
- program = QFile::decodeName(konsole_shell(cmdArgs));
+ program = TQFile::decodeName(konsole_shell(cmdArgs));
if (co) {
co->setDesktopGroup();
- QString cmd = co->readPathEntry("Exec");
+ TQString cmd = co->readPathEntry("Exec");
if (!cmd.isEmpty()) {
cmdArgs.append("-c");
- cmdArgs.append(QFile::encodeName(cmd));
+ cmdArgs.append(TQFile::encodeName(cmd));
}
}
}
@@ -2856,8 +2856,8 @@ QString Konsole::newSession(KSimpleConfig *co, QString program, const QStrList &
TEWidget* te_old = te;
te=new TEWidget(tabwidget);
- connect( te, SIGNAL(configureRequest(TEWidget*, int, int, int)),
- this, SLOT(configureRequest(TEWidget*,int,int,int)) );
+ connect( te, TQT_SIGNAL(configureRequest(TEWidget*, int, int, int)),
+ this, TQT_SLOT(configureRequest(TEWidget*,int,int,int)) );
if (te_old) {
initTEWidget(te, te_old);
}
@@ -2870,44 +2870,44 @@ QString Konsole::newSession(KSimpleConfig *co, QString program, const QStrList &
te->setMinimumSize(150,70);
- QString sessionId="session-"+QString::number(++sessionIdCounter);
+ TQString sessionId="session-"+TQString::number(++sessionIdCounter);
TESession* s = new TESession(te, emu,winId(),sessionId,cwd);
- s->setProgram(QFile::encodeName(program),cmdArgs);
+ s->setProgram(TQFile::encodeName(program),cmdArgs);
s->setMonitorSilenceSeconds(monitorSilenceSeconds);
s->enableFullScripting(b_fullScripting);
// If you add any new signal-slot connection below, think about doing it in konsolePart too
- connect( s,SIGNAL(done(TESession*)),
- this,SLOT(doneSession(TESession*)) );
- connect( s, SIGNAL( updateTitle(TESession*) ),
- this, SLOT( updateTitle(TESession*) ) );
- connect( s, SIGNAL( notifySessionState(TESession*, int) ),
- this, SLOT( notifySessionState(TESession*, int)) );
- connect( s, SIGNAL(disableMasterModeConnections()),
- this, SLOT(disableMasterModeConnections()) );
- connect( s, SIGNAL(enableMasterModeConnections()),
- this, SLOT(enableMasterModeConnections()) );
- connect( s, SIGNAL(renameSession(TESession*,const QString&)),
- this, SLOT(slotRenameSession(TESession*, const QString&)) );
- connect( s->getEmulation(), SIGNAL(changeColumns(int)),
- this, SLOT(changeColumns(int)) );
- connect( s->getEmulation(), SIGNAL(changeColLin(int,int)),
- this, SLOT(changeColLin(int,int)) );
- connect( s->getEmulation(), SIGNAL(ImageSizeChanged(int,int)),
- this, SLOT(notifySize(int,int)));
- connect( s, SIGNAL(zmodemDetected(TESession*)),
- this, SLOT(slotZModemDetected(TESession*)));
- connect( s, SIGNAL(updateSessionConfig(TESession*)),
- this, SLOT(slotUpdateSessionConfig(TESession*)));
- connect( s, SIGNAL(resizeSession(TESession*, QSize)),
- this, SLOT(slotResizeSession(TESession*, QSize)));
- connect( s, SIGNAL(setSessionEncoding(TESession*, const QString &)),
- this, SLOT(slotSetSessionEncoding(TESession*, const QString &)));
- connect( s, SIGNAL(getSessionSchema(TESession*, QString &)),
- this, SLOT(slotGetSessionSchema(TESession*, QString &)));
- connect( s, SIGNAL(setSessionSchema(TESession*, const QString &)),
- this, SLOT(slotSetSessionSchema(TESession*, const QString &)));
- connect( s, SIGNAL(changeTabTextColor(TESession*, int)),
- this,SLOT(changeTabTextColor(TESession*, int)) );
+ connect( s,TQT_SIGNAL(done(TESession*)),
+ this,TQT_SLOT(doneSession(TESession*)) );
+ connect( s, TQT_SIGNAL( updateTitle(TESession*) ),
+ this, TQT_SLOT( updateTitle(TESession*) ) );
+ connect( s, TQT_SIGNAL( notifySessionState(TESession*, int) ),
+ this, TQT_SLOT( notifySessionState(TESession*, int)) );
+ connect( s, TQT_SIGNAL(disableMasterModeConnections()),
+ this, TQT_SLOT(disableMasterModeConnections()) );
+ connect( s, TQT_SIGNAL(enableMasterModeConnections()),
+ this, TQT_SLOT(enableMasterModeConnections()) );
+ connect( s, TQT_SIGNAL(renameSession(TESession*,const TQString&)),
+ this, TQT_SLOT(slotRenameSession(TESession*, const TQString&)) );
+ connect( s->getEmulation(), TQT_SIGNAL(changeColumns(int)),
+ this, TQT_SLOT(changeColumns(int)) );
+ connect( s->getEmulation(), TQT_SIGNAL(changeColLin(int,int)),
+ this, TQT_SLOT(changeColLin(int,int)) );
+ connect( s->getEmulation(), TQT_SIGNAL(ImageSizeChanged(int,int)),
+ this, TQT_SLOT(notifySize(int,int)));
+ connect( s, TQT_SIGNAL(zmodemDetected(TESession*)),
+ this, TQT_SLOT(slotZModemDetected(TESession*)));
+ connect( s, TQT_SIGNAL(updateSessionConfig(TESession*)),
+ this, TQT_SLOT(slotUpdateSessionConfig(TESession*)));
+ connect( s, TQT_SIGNAL(resizeSession(TESession*, TQSize)),
+ this, TQT_SLOT(slotResizeSession(TESession*, TQSize)));
+ connect( s, TQT_SIGNAL(setSessionEncoding(TESession*, const TQString &)),
+ this, TQT_SLOT(slotSetSessionEncoding(TESession*, const TQString &)));
+ connect( s, TQT_SIGNAL(getSessionSchema(TESession*, TQString &)),
+ this, TQT_SLOT(slotGetSessionSchema(TESession*, TQString &)));
+ connect( s, TQT_SIGNAL(setSessionSchema(TESession*, const TQString &)),
+ this, TQT_SLOT(slotSetSessionSchema(TESession*, const TQString &)));
+ connect( s, TQT_SIGNAL(changeTabTextColor(TESession*, int)),
+ this,TQT_SLOT(changeTabTextColor(TESession*, int)) );
s->widget()->setVTFont(defaultFont);// Hack to set font again after newSession
s->setSchemaNo(schmno);
@@ -2942,16 +2942,16 @@ QString Konsole::newSession(KSimpleConfig *co, QString program, const QStrList &
/*
* Starts a new session based on URL.
*/
-void Konsole::newSession(const QString& sURL, const QString& title)
+void Konsole::newSession(const TQString& sURL, const TQString& title)
{
- QStrList args;
- QString protocol, path, login, host;
+ TQStrList args;
+ TQString protocol, path, login, host;
KURL url = KURL(sURL);
if ((url.protocol() == "file") && (url.hasPath())) {
KSimpleConfig *co = defaultSession();
path = url.path();
- newSession(co, QString::null, QStrList(), QString::null, QString::null,
+ newSession(co, TQString::null, TQStrList(), TQString::null, TQString::null,
title.isEmpty() ? path : title, path);
return;
}
@@ -2962,7 +2962,7 @@ void Konsole::newSession(const QString& sURL, const QString& title)
host = url.host();
if (url.port() && isSSH) {
args.append("-p");
- args.append(QCString().setNum(url.port()));
+ args.append(TQCString().setNum(url.port()));
}
if (url.hasUser()) {
login = url.user();
@@ -2971,10 +2971,10 @@ void Konsole::newSession(const QString& sURL, const QString& title)
}
args.append(host.latin1());
if (url.port() && !isSSH)
- args.append(QCString().setNum(url.port()));
+ args.append(TQCString().setNum(url.port()));
newSession( NULL, protocol.latin1() /* protocol */, args /* arguments */,
- QString::null /*term*/, QString::null /*icon*/,
- title.isEmpty() ? path : title /*title*/, QString::null /*cwd*/);
+ TQString::null /*term*/, TQString::null /*icon*/,
+ title.isEmpty() ? path : title /*title*/, TQString::null /*cwd*/);
return;
}
/*
@@ -3050,7 +3050,7 @@ void Konsole::doneSession(TESession* s)
// Since the timer approach only works at good weather,
// the whole construction is not suited to what it
// should do. Affected is the TEEmulation::setConnect.
- QTimer::singleShot(1,this,SLOT(activateSession()));
+ TQTimer::singleShot(1,this,TQT_SLOT(activateSession()));
}
else
close();
@@ -3122,12 +3122,12 @@ void Konsole::moveSessionLeft()
ra->unplug(m_view);
ra->plug(m_view,(m_view->count()-sessions.count()+1)+position-1);
- QColor oldcolor = tabwidget->tabColor(se->widget());
+ TQColor oldcolor = tabwidget->tabColor(se->widget());
tabwidget->blockSignals(true);
tabwidget->removePage(se->widget());
tabwidget->blockSignals(false);
- QString title = se->Title();
+ TQString title = se->Title();
createSessionTab(se->widget(), iconSetForSession(se),
title.replace('&', "&&"), position-1);
tabwidget->showPage(se->widget());
@@ -3155,12 +3155,12 @@ void Konsole::moveSessionRight()
ra->unplug(m_view);
ra->plug(m_view,(m_view->count()-sessions.count()+1)+position+1);
- QColor oldcolor = tabwidget->tabColor(se->widget());
+ TQColor oldcolor = tabwidget->tabColor(se->widget());
tabwidget->blockSignals(true);
tabwidget->removePage(se->widget());
tabwidget->blockSignals(false);
- QString title = se->Title();
+ TQString title = se->Title();
createSessionTab(se->widget(), iconSetForSession(se),
title.replace('&', "&&"), position+1);
tabwidget->showPage(se->widget());
@@ -3197,7 +3197,7 @@ void Konsole::initMasterMode(bool state)
slotToggleMasterMode();
}
-void Konsole::initTabColor(QColor color)
+void Konsole::initTabColor(TQColor color)
{
if ( color.isValid() )
tabwidget->setTabColor( se->widget(), color );
@@ -3244,7 +3244,7 @@ void Konsole::setMasterMode(bool _state, TESession* _se)
void Konsole::notifySessionState(TESession* session, int state)
{
- QString state_iconname;
+ TQString state_iconname;
switch(state)
{
case NOTIFYNORMAL : if(session->isMasterMode())
@@ -3263,9 +3263,9 @@ void Konsole::notifySessionState(TESession* session, int state)
&& session->testAndSetStateIconName(state_iconname)
&& m_tabViewMode != ShowTextOnly) {
- QPixmap normal = KGlobal::instance()->iconLoader()->loadIcon(state_iconname,
+ TQPixmap normal = KGlobal::instance()->iconLoader()->loadIcon(state_iconname,
KIcon::Small, 0, KIcon::DefaultState, 0L, true);
- QPixmap active = KGlobal::instance()->iconLoader()->loadIcon(state_iconname,
+ TQPixmap active = KGlobal::instance()->iconLoader()->loadIcon(state_iconname,
KIcon::Small, 0, KIcon::ActiveState, 0L, true);
// make sure they are not larger than 16x16
@@ -3274,9 +3274,9 @@ void Konsole::notifySessionState(TESession* session, int state)
if (active.width() > 16 || active.height() > 16)
active.convertFromImage(active.convertToImage().smoothScale(16,16));
- QIconSet iconset;
- iconset.setPixmap(normal, QIconSet::Small, QIconSet::Normal);
- iconset.setPixmap(active, QIconSet::Small, QIconSet::Active);
+ TQIconSet iconset;
+ iconset.setPixmap(normal, TQIconSet::Small, TQIconSet::Normal);
+ iconset.setPixmap(active, TQIconSet::Small, TQIconSet::Active);
tabwidget->setTabIconSet(session->widget(), iconset);
}
@@ -3308,7 +3308,7 @@ void Konsole::buildSessionMenus()
m_quit->plug(m_session);
}
-static void insertItemSorted(KPopupMenu *menu, const QIconSet &iconSet, const QString &txt, int id)
+static void insertItemSorted(KPopupMenu *menu, const TQIconSet &iconSet, const TQString &txt, int id)
{
const int defaultId = SESSION_NEW_SHELL_ID; // The id of the 'new' item.
int index = menu->indexOf(defaultId);
@@ -3332,7 +3332,7 @@ static void insertItemSorted(KPopupMenu *menu, const QIconSet &iconSet, const QS
menu->insertItem(iconSet, txt, id, index);
}
-void Konsole::addSessionCommand(const QString &path)
+void Konsole::addSessionCommand(const TQString &path)
{
KSimpleConfig* co;
if (path.isEmpty())
@@ -3340,18 +3340,18 @@ void Konsole::addSessionCommand(const QString &path)
else
co = new KSimpleConfig(path,true);
co->setDesktopGroup();
- QString typ = co->readEntry("Type");
- QString txt = co->readEntry("Name");
+ TQString typ = co->readEntry("Type");
+ TQString txt = co->readEntry("Name");
// try to locate the binary
- QString exec= co->readPathEntry("Exec");
+ TQString exec= co->readPathEntry("Exec");
if (exec.startsWith("sudo su -c \'")) {
exec = exec.mid(12,exec.length()-13);
}
exec = KRun::binaryName(exec, false);
exec = KShell::tildeExpand(exec);
- QString pexec = KGlobal::dirs()->findExe(exec);
+ TQString pexec = KGlobal::dirs()->findExe(exec);
if (typ.isEmpty() || txt.isEmpty() || typ != "KonsoleApplication"
|| ( !exec.isEmpty() && pexec.isEmpty() ) )
@@ -3368,11 +3368,11 @@ void Konsole::addSessionCommand(const QString &path)
if ( ( b_sessionShortcutsMapped == true ) || ( cmd_serial == SESSION_NEW_SHELL_ID ) ) return;
// Add an empty shortcut for each Session.
- QString comment = co->readEntry("Comment");
+ TQString comment = co->readEntry("Comment");
if (comment.isEmpty())
comment=txt.prepend(i18n("New "));
- QString name = comment;
+ TQString name = comment;
name.prepend("SSC_"); // Allows easy searching for Session ShortCuts
name.replace(" ", "_");
sl_sessionShortCuts << name;
@@ -3384,7 +3384,7 @@ void Konsole::addSessionCommand(const QString &path)
} else {
sessionAction = new KAction( comment, 0, this, 0, m_shortcuts, name.latin1() );
}
- connect( sessionAction, SIGNAL( activated() ), sessionNumberMapper, SLOT( map() ) );
+ connect( sessionAction, TQT_SIGNAL( activated() ), sessionNumberMapper, TQT_SLOT( map() ) );
sessionNumberMapper->setMapping( sessionAction, cmd_serial );
}
@@ -3399,11 +3399,11 @@ void Konsole::loadSessionCommands()
if (!kapp->authorize("shell_access"))
return;
- addSessionCommand(QString::null);
+ addSessionCommand(TQString::null);
- QStringList lst = KGlobal::dirs()->findAllResources("appdata", "*.desktop", false, true);
+ TQStringList lst = KGlobal::dirs()->findAllResources("appdata", "*.desktop", false, true);
- for(QStringList::Iterator it = lst.begin(); it != lst.end(); ++it )
+ for(TQStringList::Iterator it = lst.begin(); it != lst.end(); ++it )
if (!(*it).endsWith("/shell.desktop"))
addSessionCommand(*it);
@@ -3421,12 +3421,12 @@ void Konsole::createSessionMenus()
}
KSimpleConfig *cfg = no2command[SESSION_NEW_SHELL_ID];
- QString txt = cfg->readEntry("Name");
- QString icon = cfg->readEntry("Icon", "konsole");
+ TQString txt = cfg->readEntry("Name");
+ TQString icon = cfg->readEntry("Icon", "konsole");
insertItemSorted(m_tabbarSessionsCommands, SmallIconSet(icon),
txt.replace('&',"&&"), SESSION_NEW_SHELL_ID );
- QString comment = cfg->readEntry("Comment");
+ TQString comment = cfg->readEntry("Comment");
if (comment.isEmpty())
comment=txt.prepend(i18n("New "));
insertItemSorted(m_session, SmallIconSet(icon),
@@ -3438,16 +3438,16 @@ void Konsole::createSessionMenus()
m_session->insertSeparator();
m_tabbarSessionsCommands->insertSeparator();
- QIntDictIterator<KSimpleConfig> it( no2command );
+ TQIntDictIterator<KSimpleConfig> it( no2command );
for ( ; it.current(); ++it ) {
if ( it.currentKey() == SESSION_NEW_SHELL_ID )
continue;
- QString txt = (*it).readEntry("Name");
- QString icon = (*it).readEntry("Icon", "konsole");
+ TQString txt = (*it).readEntry("Name");
+ TQString icon = (*it).readEntry("Icon", "konsole");
insertItemSorted(m_tabbarSessionsCommands, SmallIconSet(icon),
txt.replace('&',"&&"), it.currentKey() );
- QString comment = (*it).readEntry("Comment");
+ TQString comment = (*it).readEntry("Comment");
if (comment.isEmpty())
comment=txt.prepend(i18n("New "));
insertItemSorted(m_session, SmallIconSet(icon),
@@ -3465,18 +3465,18 @@ void Konsole::createSessionMenus()
}
}
-void Konsole::addScreenSession(const QString &path, const QString &socket)
+void Konsole::addScreenSession(const TQString &path, const TQString &socket)
{
KTempFile *tmpFile = new KTempFile();
tmpFile->setAutoDelete(true);
KSimpleConfig *co = new KSimpleConfig(tmpFile->name());
co->setDesktopGroup();
co->writeEntry("Name", socket);
- QString txt = i18n("Screen is a program controlling screens!", "Screen at %1").arg(socket);
+ TQString txt = i18n("Screen is a program controlling screens!", "Screen at %1").arg(socket);
co->writeEntry("Comment", txt);
- co->writePathEntry("Exec", QString::fromLatin1("SCREENDIR=%1 screen -r %2")
+ co->writePathEntry("Exec", TQString::fromLatin1("SCREENDIR=%1 screen -r %2")
.arg(path).arg(socket));
- QString icon = "konsole";
+ TQString icon = "konsole";
cmd_serial++;
m_session->insertItem( SmallIconSet( icon ), txt, cmd_serial, cmd_serial - 1 );
m_tabbarSessionsCommands->insertItem( SmallIconSet( icon ), txt, cmd_serial );
@@ -3487,22 +3487,22 @@ void Konsole::loadScreenSessions()
{
if (!kapp->authorize("shell_access"))
return;
- QCString screenDir = getenv("SCREENDIR");
+ TQCString screenDir = getenv("SCREENDIR");
if (screenDir.isEmpty())
- screenDir = QFile::encodeName(QDir::homeDirPath()) + "/.screen/";
+ screenDir = TQFile::encodeName(TQDir::homeDirPath()) + "/.screen/";
// Some distributions add a shell function called screen that sets
// $SCREENDIR to ~/tmp. In this case the variable won't be set here.
- if (!QFile::exists(screenDir))
- screenDir = QFile::encodeName(QDir::homeDirPath()) + "/tmp/";
- QStringList sessions;
- // Can't use QDir as it doesn't support FIFOs :(
+ if (!TQFile::exists(screenDir))
+ screenDir = TQFile::encodeName(TQDir::homeDirPath()) + "/tmp/";
+ TQStringList sessions;
+ // Can't use TQDir as it doesn't support FIFOs :(
DIR *dir = opendir(screenDir);
if (dir)
{
struct dirent *entry;
while ((entry = readdir(dir)))
{
- QCString path = screenDir + "/" + entry->d_name;
+ TQCString path = screenDir + "/" + entry->d_name;
struct stat st;
if (stat(path, &st) != 0)
continue;
@@ -3512,13 +3512,13 @@ void Konsole::loadScreenSessions()
(fd = open(path, O_WRONLY | O_NONBLOCK)) != -1)
{
::close(fd);
- sessions.append(QFile::decodeName(entry->d_name));
+ sessions.append(TQFile::decodeName(entry->d_name));
}
}
closedir(dir);
}
resetScreenSessions();
- for (QStringList::ConstIterator it = sessions.begin(); it != sessions.end(); ++it)
+ for (TQStringList::ConstIterator it = sessions.begin(); it != sessions.end(); ++it)
addScreenSession(screenDir, *it);
}
@@ -3558,7 +3558,7 @@ void Konsole::setSchema(int numb, TEWidget* tewidget)
if (s) setSchema(s, tewidget);
}
-void Konsole::setSchema(const QString & path)
+void Konsole::setSchema(const TQString & path)
{
ColorSchema* s = colors->find(path);
if (!s)
@@ -3605,10 +3605,10 @@ void Konsole::setSchema(ColorSchema* s, TEWidget* tewidget)
if (!argb_visual) {
if (!rootxpms[tewidget])
rootxpms.insert( tewidget, new KRootPixmap(tewidget) );
- rootxpms[tewidget]->setFadeEffect(s->tr_x(), QColor(s->tr_r(), s->tr_g(), s->tr_b()));
+ rootxpms[tewidget]->setFadeEffect(s->tr_x(), TQColor(s->tr_r(), s->tr_g(), s->tr_b()));
} else {
tewidget->setBlendColor(qRgba(s->tr_r(), s->tr_g(), s->tr_b(), int(s->tr_x() * 255)));
- tewidget->setErasePixmap( QPixmap() ); // make sure any background pixmap is unset
+ tewidget->setErasePixmap( TQPixmap() ); // make sure any background pixmap is unset
}
} else {
if (rootxpms[tewidget]) {
@@ -3620,7 +3620,7 @@ void Konsole::setSchema(ColorSchema* s, TEWidget* tewidget)
}
tewidget->setColorTable(s->table());
- QPtrListIterator<TESession> ses_it(sessions);
+ TQPtrListIterator<TESession> ses_it(sessions);
for (; ses_it.current(); ++ses_it)
if (tewidget==ses_it.current()->widget()) {
ses_it.current()->setSchemaNo(s->numb());
@@ -3649,30 +3649,30 @@ void Konsole::detachSession(TESession* _se) {
// Disable master mode when detaching master
setMasterMode(false);
} else {
- QPtrListIterator<TESession> from_it(sessions);
+ TQPtrListIterator<TESession> from_it(sessions);
for(; from_it.current(); ++from_it) {
TESession *from = from_it.current();
if(from->isMasterMode())
- disconnect(from->widget(), SIGNAL(keyPressedSignal(QKeyEvent*)),
- _se->getEmulation(), SLOT(onKeyPress(QKeyEvent*)));
+ disconnect(from->widget(), TQT_SIGNAL(keyPressedSignal(TQKeyEvent*)),
+ _se->getEmulation(), TQT_SLOT(onKeyPress(TQKeyEvent*)));
}
}
- QColor se_tabtextcolor = tabwidget->tabColor( _se->widget() );
+ TQColor se_tabtextcolor = tabwidget->tabColor( _se->widget() );
- disconnect( _se,SIGNAL(done(TESession*)),
- this,SLOT(doneSession(TESession*)) );
+ disconnect( _se,TQT_SIGNAL(done(TESession*)),
+ this,TQT_SLOT(doneSession(TESession*)) );
- disconnect( _se->getEmulation(),SIGNAL(ImageSizeChanged(int,int)), this,SLOT(notifySize(int,int)));
- disconnect( _se->getEmulation(),SIGNAL(changeColLin(int, int)), this,SLOT(changeColLin(int,int)) );
- disconnect( _se->getEmulation(),SIGNAL(changeColumns(int)), this,SLOT(changeColumns(int)) );
- disconnect( _se, SIGNAL(changeTabTextColor(TESession*, int)), this, SLOT(changeTabTextColor(TESession*, int)) );
+ disconnect( _se->getEmulation(),TQT_SIGNAL(ImageSizeChanged(int,int)), this,TQT_SLOT(notifySize(int,int)));
+ disconnect( _se->getEmulation(),TQT_SIGNAL(changeColLin(int, int)), this,TQT_SLOT(changeColLin(int,int)) );
+ disconnect( _se->getEmulation(),TQT_SIGNAL(changeColumns(int)), this,TQT_SLOT(changeColumns(int)) );
+ disconnect( _se, TQT_SIGNAL(changeTabTextColor(TESession*, int)), this, TQT_SLOT(changeTabTextColor(TESession*, int)) );
- disconnect( _se,SIGNAL(updateTitle(TESession*)), this,SLOT(updateTitle(TESession*)) );
- disconnect( _se,SIGNAL(notifySessionState(TESession*,int)), this,SLOT(notifySessionState(TESession*,int)) );
- disconnect( _se,SIGNAL(disableMasterModeConnections()), this,SLOT(disableMasterModeConnections()) );
- disconnect( _se,SIGNAL(enableMasterModeConnections()), this,SLOT(enableMasterModeConnections()) );
- disconnect( _se,SIGNAL(renameSession(TESession*,const QString&)), this,SLOT(slotRenameSession(TESession*,const QString&)) );
+ disconnect( _se,TQT_SIGNAL(updateTitle(TESession*)), this,TQT_SLOT(updateTitle(TESession*)) );
+ disconnect( _se,TQT_SIGNAL(notifySessionState(TESession*,int)), this,TQT_SLOT(notifySessionState(TESession*,int)) );
+ disconnect( _se,TQT_SIGNAL(disableMasterModeConnections()), this,TQT_SLOT(disableMasterModeConnections()) );
+ disconnect( _se,TQT_SIGNAL(enableMasterModeConnections()), this,TQT_SLOT(enableMasterModeConnections()) );
+ disconnect( _se,TQT_SIGNAL(renameSession(TESession*,const TQString&)), this,TQT_SLOT(slotRenameSession(TESession*,const TQString&)) );
// TODO: "type" isn't passed properly
Konsole* konsole = new Konsole(name(), b_histEnabled, !menubar->isHidden(), n_tabbar != TabNone, b_framevis,
@@ -3696,7 +3696,7 @@ void Konsole::detachSession(TESession* _se) {
else
se = sessions.at(sessionIndex ? sessionIndex - 1 : 0);
session2action.find(se)->setChecked(true);
- QTimer::singleShot(1,this,SLOT(activateSession()));
+ TQTimer::singleShot(1,this,TQT_SLOT(activateSession()));
}
if (sessions.count()==1)
@@ -3724,8 +3724,8 @@ void Konsole::attachSession(TESession* session)
te=new TEWidget(tabwidget);
- connect( te, SIGNAL(configureRequest(TEWidget*, int, int, int)),
- this, SLOT(configureRequest(TEWidget*,int,int,int)) );
+ connect( te, TQT_SIGNAL(configureRequest(TEWidget*, int, int, int)),
+ this, TQT_SLOT(configureRequest(TEWidget*,int,int,int)) );
te->resize(se_widget->size());
te->setSize(se_widget->Columns(), se_widget->Lines());
@@ -3739,9 +3739,9 @@ void Konsole::attachSession(TESession* session)
enableMasterModeConnections();
}
- QString title=session->Title();
+ TQString title=session->Title();
KRadioAction *ra = new KRadioAction(title.replace('&',"&&"), session->IconName(),
- 0, this, SLOT(activateSession()), m_shortcuts);
+ 0, this, TQT_SLOT(activateSession()), m_shortcuts);
ra->setExclusiveGroup("sessions");
ra->setChecked(true);
@@ -3755,25 +3755,25 @@ void Konsole::attachSession(TESession* session)
if (m_menuCreated)
ra->plug(m_view);
- connect( session,SIGNAL(done(TESession*)),
- this,SLOT(doneSession(TESession*)) );
+ connect( session,TQT_SIGNAL(done(TESession*)),
+ this,TQT_SLOT(doneSession(TESession*)) );
- connect( session,SIGNAL(updateTitle(TESession*)), this,SLOT(updateTitle(TESession*)) );
- connect( session,SIGNAL(notifySessionState(TESession*,int)), this,SLOT(notifySessionState(TESession*,int)) );
+ connect( session,TQT_SIGNAL(updateTitle(TESession*)), this,TQT_SLOT(updateTitle(TESession*)) );
+ connect( session,TQT_SIGNAL(notifySessionState(TESession*,int)), this,TQT_SLOT(notifySessionState(TESession*,int)) );
- connect( session,SIGNAL(disableMasterModeConnections()), this,SLOT(disableMasterModeConnections()) );
- connect( session,SIGNAL(enableMasterModeConnections()), this,SLOT(enableMasterModeConnections()) );
- connect( session,SIGNAL(renameSession(TESession*,const QString&)), this,SLOT(slotRenameSession(TESession*,const QString&)) );
- connect( session->getEmulation(),SIGNAL(ImageSizeChanged(int,int)), this,SLOT(notifySize(int,int)));
- connect( session->getEmulation(),SIGNAL(changeColumns(int)), this,SLOT(changeColumns(int)) );
- connect( session->getEmulation(),SIGNAL(changeColLin(int, int)), this,SLOT(changeColLin(int,int)) );
+ connect( session,TQT_SIGNAL(disableMasterModeConnections()), this,TQT_SLOT(disableMasterModeConnections()) );
+ connect( session,TQT_SIGNAL(enableMasterModeConnections()), this,TQT_SLOT(enableMasterModeConnections()) );
+ connect( session,TQT_SIGNAL(renameSession(TESession*,const TQString&)), this,TQT_SLOT(slotRenameSession(TESession*,const TQString&)) );
+ connect( session->getEmulation(),TQT_SIGNAL(ImageSizeChanged(int,int)), this,TQT_SLOT(notifySize(int,int)));
+ connect( session->getEmulation(),TQT_SIGNAL(changeColumns(int)), this,TQT_SLOT(changeColumns(int)) );
+ connect( session->getEmulation(),TQT_SIGNAL(changeColLin(int, int)), this,TQT_SLOT(changeColLin(int,int)) );
- connect( session, SIGNAL(changeTabTextColor(TESession*, int)), this, SLOT(changeTabTextColor(TESession*, int)) );
+ connect( session, TQT_SIGNAL(changeTabTextColor(TESession*, int)), this, TQT_SLOT(changeTabTextColor(TESession*, int)) );
activateSession(session);
}
-void Konsole::setSessionTitle( QString& title, TESession* ses )
+void Konsole::setSessionTitle( TQString& title, TESession* ses )
{
if ( !ses )
ses = se;
@@ -3782,7 +3782,7 @@ void Konsole::setSessionTitle( QString& title, TESession* ses )
}
void Konsole::renameSession(TESession* ses) {
- QString title = ses->Title();
+ TQString title = ses->Title();
bool ok;
title = KInputDialog::getText( i18n( "Rename Session" ),
@@ -3798,10 +3798,10 @@ void Konsole::slotRenameSession() {
renameSession(se);
}
-void Konsole::slotRenameSession(TESession* ses, const QString &name)
+void Konsole::slotRenameSession(TESession* ses, const TQString &name)
{
KRadioAction *ra = session2action.find(ses);
- QString title=name;
+ TQString title=name;
title=title.replace('&',"&&");
ra->setText(title);
ra->setIcon( ses->IconName() ); // I don't know why it is needed here
@@ -3820,28 +3820,28 @@ void Konsole::slotClearAllSessionHistories() {
HistoryTypeDialog::HistoryTypeDialog(const HistoryType& histType,
unsigned int histSize,
- QWidget *parent)
+ TQWidget *parent)
: KDialogBase(Plain, i18n("History Configuration"),
Help | Default | Ok | Cancel, Ok,
parent, 0, true, true)
{
- QFrame *mainFrame = plainPage();
+ TQFrame *mainFrame = plainPage();
- QHBoxLayout *hb = new QHBoxLayout(mainFrame);
+ TQHBoxLayout *hb = new TQHBoxLayout(mainFrame);
- m_btnEnable = new QCheckBox(i18n("&Enable"), mainFrame);
- connect(m_btnEnable, SIGNAL(toggled(bool)), SLOT(slotHistEnable(bool)));
+ m_btnEnable = new TQCheckBox(i18n("&Enable"), mainFrame);
+ connect(m_btnEnable, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotHistEnable(bool)));
- m_label = new QLabel(i18n("&Number of lines: "), mainFrame);
+ m_label = new TQLabel(i18n("&Number of lines: "), mainFrame);
- m_size = new QSpinBox(0, 10 * 1000 * 1000, 100, mainFrame);
+ m_size = new TQSpinBox(0, 10 * 1000 * 1000, 100, mainFrame);
m_size->setValue(histSize);
m_size->setSpecialValueText(i18n("Unlimited (number of lines)", "Unlimited"));
m_label->setBuddy( m_size );
- m_setUnlimited = new QPushButton(i18n("&Set Unlimited"), mainFrame);
- connect( m_setUnlimited,SIGNAL(clicked()), this,SLOT(slotSetUnlimited()) );
+ m_setUnlimited = new TQPushButton(i18n("&Set Unlimited"), mainFrame);
+ connect( m_setUnlimited,TQT_SIGNAL(clicked()), this,TQT_SLOT(slotSetUnlimited()) );
hb->addWidget(m_btnEnable);
hb->addSpacing(10);
@@ -3935,11 +3935,11 @@ void Konsole::slotFindHistory()
{
if( !m_finddialog ) {
m_finddialog = new KonsoleFind( this, "konsolefind", false);
- connect(m_finddialog,SIGNAL(search()),this,SLOT(slotFind()));
- connect(m_finddialog,SIGNAL(done()),this,SLOT(slotFindDone()));
+ connect(m_finddialog,TQT_SIGNAL(search()),this,TQT_SLOT(slotFind()));
+ connect(m_finddialog,TQT_SIGNAL(done()),this,TQT_SLOT(slotFindDone()));
}
- QString string;
+ TQString string;
string = m_finddialog->getText();
m_finddialog->setText(string.isEmpty() ? m_find_pattern : string);
@@ -3957,7 +3957,7 @@ void Konsole::slotFindNext()
return;
}
- QString string;
+ TQString string;
string = m_finddialog->getText();
m_finddialog->setText(string.isEmpty() ? m_find_pattern : string);
@@ -3971,7 +3971,7 @@ void Konsole::slotFindPrevious()
return;
}
- QString string;
+ TQString string;
string = m_finddialog->getText();
m_finddialog->setText(string.isEmpty() ? m_find_pattern : string);
@@ -4031,7 +4031,7 @@ void Konsole::slotSaveHistory()
{
// FIXME - mostLocalURL can't handle non-existing files yet, so this
// code doesn't work.
- KURL s_url = KFileDialog::getSaveURL(QString::null, QString::null, 0L, i18n("Save History"));
+ KURL s_url = KFileDialog::getSaveURL(TQString::null, TQString::null, 0L, i18n("Save History"));
if( s_url.isEmpty())
return;
KURL url = KIO::NetAccess::mostLocalURL( s_url, 0 );
@@ -4042,21 +4042,21 @@ void Konsole::slotSaveHistory()
}
int query = KMessageBox::Continue;
- QFileInfo info;
- QString name( url.path() );
+ TQFileInfo info;
+ TQString name( url.path() );
info.setFile( name );
if( info.exists() )
query = KMessageBox::warningContinueCancel( this,
i18n( "A file with this name already exists.\nDo you want to overwrite it?" ), i18n("File Exists"), i18n("Overwrite") );
if (query==KMessageBox::Continue) {
- QFile file(url.path());
+ TQFile file(url.path());
if(!file.open(IO_WriteOnly)) {
KMessageBox::sorry(this, i18n("Unable to write to file."));
return;
}
- QTextStream textStream(&file);
+ TQTextStream textStream(&file);
assert( se && se->getEmulation() );
se->getEmulation()->streamHistory( &textStream );
@@ -4076,7 +4076,7 @@ void Konsole::slotZModemUpload()
i18n("<p>The current session already has a ZModem file transfer in progress."));
return;
}
- QString zmodem = KGlobal::dirs()->findExe("sz");
+ TQString zmodem = KGlobal::dirs()->findExe("sz");
if (zmodem.isEmpty())
zmodem = KGlobal::dirs()->findExe("lsz");
if (zmodem.isEmpty())
@@ -4088,12 +4088,12 @@ void Konsole::slotZModemUpload()
return;
}
- QStringList files = KFileDialog::getOpenFileNames(QString::null, QString::null, this,
+ TQStringList files = KFileDialog::getOpenFileNames(TQString::null, TQString::null, this,
i18n("Select Files to Upload"));
if (files.isEmpty())
return;
- se->startZModem(zmodem, QString::null, files);
+ se->startZModem(zmodem, TQString::null, files);
}
void Konsole::slotZModemDetected(TESession *session)
@@ -4103,7 +4103,7 @@ void Konsole::slotZModemDetected(TESession *session)
if(se != session)
activateSession(session);
- QString zmodem = KGlobal::dirs()->findExe("rz");
+ TQString zmodem = KGlobal::dirs()->findExe("rz");
if (zmodem.isEmpty())
zmodem = KGlobal::dirs()->findExe("lrz");
if (zmodem.isEmpty())
@@ -4129,7 +4129,7 @@ void Konsole::slotZModemDetected(TESession *session)
else
{
const KURL &url = dlg.selectedURL();
- session->startZModem(zmodem, url.path(), QStringList());
+ session->startZModem(zmodem, url.path(), TQStringList());
}
}
@@ -4141,7 +4141,7 @@ void Konsole::slotPrint()
{
printer.setFullPage(false);
printer.setCreator("Konsole");
- QPainter paint;
+ TQPainter paint;
paint.begin(&printer);
se->print(paint, printer.option("app-konsole-printfriendly") == "true",
printer.option("app-konsole-printexact") == "true");
@@ -4152,7 +4152,7 @@ void Konsole::slotPrint()
void Konsole::toggleBidi()
{
b_bidiEnabled=!b_bidiEnabled;
- QPtrList<TEWidget> tes = activeTEs();
+ TQPtrList<TEWidget> tes = activeTEs();
for (TEWidget *_te = tes.first(); _te; _te = tes.next()) {
_te->setBidiEnabled(b_bidiEnabled);
_te->repaint();
@@ -4163,25 +4163,25 @@ void Konsole::toggleBidi()
SizeDialog::SizeDialog(const unsigned int columns,
const unsigned int lines,
- QWidget *parent)
+ TQWidget *parent)
: KDialogBase(Plain, i18n("Size Configuration"),
Help | Default | Ok | Cancel, Ok,
parent)
{
- QFrame *mainFrame = plainPage();
+ TQFrame *mainFrame = plainPage();
- QHBoxLayout *hb = new QHBoxLayout(mainFrame);
+ TQHBoxLayout *hb = new TQHBoxLayout(mainFrame);
- m_columns = new QSpinBox(20,1000,1,mainFrame);
+ m_columns = new TQSpinBox(20,1000,1,mainFrame);
m_columns->setValue(columns);
- m_lines = new QSpinBox(4,1000,1,mainFrame);
+ m_lines = new TQSpinBox(4,1000,1,mainFrame);
m_lines->setValue(lines);
- hb->addWidget(new QLabel(i18n("Number of columns:"), mainFrame));
+ hb->addWidget(new TQLabel(i18n("Number of columns:"), mainFrame));
hb->addWidget(m_columns);
hb->addSpacing(10);
- hb->addWidget(new QLabel(i18n("Number of lines:"), mainFrame));
+ hb->addWidget(new TQLabel(i18n("Number of lines:"), mainFrame));
hb->addWidget(m_lines);
setHelp("configure-size");
@@ -4205,16 +4205,16 @@ unsigned int SizeDialog::lines() const
//////////////////////////////////////////////////////////////////////
-KonsoleFind::KonsoleFind( QWidget *parent, const char *name, bool /*modal*/ )
+KonsoleFind::KonsoleFind( TQWidget *parent, const char *name, bool /*modal*/ )
: KEdFind( parent, name, false ), m_editorDialog(0), m_editRegExp(0)
{
- QHBox* row = new QHBox( (QWidget*)group );
- m_asRegExp = new QCheckBox( i18n("As &regular expression"), row, "asRegexp" );
+ TQHBox* row = new TQHBox( (TQWidget*)group );
+ m_asRegExp = new TQCheckBox( i18n("As &regular expression"), row, "asRegexp" );
if (!KTrader::self()->query("KRegExpEditor/KRegExpEditor").isEmpty()) {
- m_editRegExp = new QPushButton( i18n("&Edit..."), row, "editRegExp" );
- connect( m_asRegExp, SIGNAL( toggled(bool) ), m_editRegExp, SLOT( setEnabled(bool) ) );
- connect( m_editRegExp, SIGNAL( clicked() ), this, SLOT( slotEditRegExp() ) );
+ m_editRegExp = new TQPushButton( i18n("&Edit..."), row, "editRegExp" );
+ connect( m_asRegExp, TQT_SIGNAL( toggled(bool) ), m_editRegExp, TQT_SLOT( setEnabled(bool) ) );
+ connect( m_editRegExp, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotEditRegExp() ) );
m_editRegExp->setEnabled( false );
}
}
@@ -4222,7 +4222,7 @@ KonsoleFind::KonsoleFind( QWidget *parent, const char *name, bool /*modal*/ )
void KonsoleFind::slotEditRegExp()
{
if ( m_editorDialog == 0 )
- m_editorDialog = KParts::ComponentFactory::createInstanceFromQuery<QDialog>( "KRegExpEditor/KRegExpEditor", QString::null, this );
+ m_editorDialog = KParts::ComponentFactory::createInstanceFromQuery<TQDialog>( "KRegExpEditor/KRegExpEditor", TQString::null, this );
assert( m_editorDialog );
@@ -4231,7 +4231,7 @@ void KonsoleFind::slotEditRegExp()
iface->setRegExp( getText() );
bool ret = m_editorDialog->exec();
- if ( ret == QDialog::Accepted)
+ if ( ret == TQDialog::Accepted)
setText( iface->regExp() );
}
@@ -4246,7 +4246,7 @@ bool KonsoleFind::reg_exp() const
void Konsole::slotFontChanged()
{
TEWidget *oldTe = te;
- QPtrList<TEWidget> tes = activeTEs();
+ TQPtrList<TEWidget> tes = activeTEs();
for (TEWidget *_te = tes.first(); _te; _te = tes.next()) {
te = _te;
// setFont(n_font);
@@ -4257,7 +4257,7 @@ void Konsole::slotFontChanged()
void Konsole::biggerFont(void) {
if ( !se ) return;
- QFont f = te->getVTFont();
+ TQFont f = te->getVTFont();
f.setPointSize( f.pointSize() + 1 );
te->setVTFont( f );
activateSession();
@@ -4266,30 +4266,30 @@ void Konsole::biggerFont(void) {
void Konsole::smallerFont(void) {
if ( !se ) return;
- QFont f = te->getVTFont();
+ TQFont f = te->getVTFont();
if ( f.pointSize() < 6 ) return; // A minimum size
f.setPointSize( f.pointSize() - 1 );
te->setVTFont( f );
activateSession();
}
-bool Konsole::processDynamic(const QCString &fun, const QByteArray &data, QCString& replyType, QByteArray &replyData)
+bool Konsole::processDynamic(const TQCString &fun, const TQByteArray &data, TQCString& replyType, TQByteArray &replyData)
{
if (b_fullScripting)
{
- if (fun == "feedAllSessions(QString)")
+ if (fun == "feedAllSessions(TQString)")
{
- QString arg0;
- QDataStream arg( data, IO_ReadOnly );
+ TQString arg0;
+ TQDataStream arg( data, IO_ReadOnly );
arg >> arg0;
feedAllSessions(arg0);
replyType = "void";
return true;
}
- else if (fun == "sendAllSessions(QString)")
+ else if (fun == "sendAllSessions(TQString)")
{
- QString arg0;
- QDataStream arg( data, IO_ReadOnly );
+ TQString arg0;
+ TQDataStream arg( data, IO_ReadOnly );
arg >> arg0;
sendAllSessions(arg0);
replyType = "void";
@@ -4304,8 +4304,8 @@ QCStringList Konsole::functionsDynamic()
QCStringList funcs = KonsoleIface::functionsDynamic();
if (b_fullScripting)
{
- funcs << "void feedAllSessions(QString text)";
- funcs << "void sendAllSessions(QString text)";
+ funcs << "void feedAllSessions(TQString text)";
+ funcs << "void sendAllSessions(TQString text)";
}
return funcs;
}
@@ -4327,9 +4327,9 @@ void Konsole::enableFixedSize(bool b)
}
}
-QPtrList<TEWidget> Konsole::activeTEs()
+TQPtrList<TEWidget> Konsole::activeTEs()
{
- QPtrList<TEWidget> ret;
+ TQPtrList<TEWidget> ret;
if (sessions.count()>0)
for (TESession *_se = sessions.first(); _se; _se = sessions.next())
ret.append(_se->widget());
diff --git a/konsole/konsole/konsole.h b/konsole/konsole/konsole.h
index df9157f7b..df9cd714e 100644
--- a/konsole/konsole/konsole.h
+++ b/konsole/konsole/konsole.h
@@ -33,10 +33,10 @@
#include <kwinmodule.h>
-#include <qstrlist.h>
-#include <qintdict.h>
-#include <qptrdict.h>
-#include <qsignalmapper.h>
+#include <tqstrlist.h>
+#include <tqintdict.h>
+#include <tqptrdict.h>
+#include <tqsignalmapper.h>
#include "TEPty.h"
#include "TEWidget.h"
@@ -63,7 +63,7 @@ class KTabWidget;
class QToolButton;
// Defined in main.C
-const char *konsole_shell(QStrList &args);
+const char *konsole_shell(TQStrList &args);
class Konsole : public KMainWindow, virtual public KonsoleIface
{
@@ -74,47 +74,47 @@ public:
Konsole(const char * name, int histon, bool menubaron, bool tabbaron,
bool frameon, bool scrollbaron,
- QCString type = 0, bool b_inRestore = false, const int wanted_tabbar = 0,
- const QString &workdir=QString::null);
+ TQCString type = 0, bool b_inRestore = false, const int wanted_tabbar = 0,
+ const TQString &workdir=TQString::null);
~Konsole();
void setColLin(int columns, int lines);
void setAutoClose(bool on);
void initFullScreen();
void initSessionFont(int fontNo);
- void initSessionFont(QFont f);
- void initSessionKeyTab(const QString &keyTab);
+ void initSessionFont(TQFont f);
+ void initSessionKeyTab(const TQString &keyTab);
void initMonitorActivity(bool on);
void initMonitorSilence(bool on);
void initMasterMode(bool on);
- void initTabColor(QColor color);
+ void initTabColor(TQColor color);
void initHistory(int lines, bool enable);
- void newSession(const QString &program, const QStrList &args, const QString &term, const QString &icon, const QString &title, const QString &cwd);
- void setSchema(const QString & path);
+ void newSession(const TQString &program, const TQStrList &args, const TQString &term, const TQString &icon, const TQString &title, const TQString &cwd);
+ void setSchema(const TQString & path);
void setEncoding(int);
- void setSessionTitle(QString&, TESession* = 0);
- void setSessionEncoding(const QString&, TESession* = 0);
+ void setSessionTitle(TQString&, TESession* = 0);
+ void setSessionEncoding(const TQString&, TESession* = 0);
void enableFullScripting(bool b);
void enableFixedSize(bool b);
- void setDefaultSession(const QString &filename);
+ void setDefaultSession(const TQString &filename);
void showTipOnStart();
// Additional functions for DCOP
int sessionCount() { return sessions.count(); }
- QString currentSession();
- QString newSession(const QString &type);
- QString sessionId(const int position);
+ TQString currentSession();
+ TQString newSession(const TQString &type);
+ TQString sessionId(const int position);
- void activateSession(const QString& sessionId);
- void feedAllSessions(const QString &text);
- void sendAllSessions(const QString &text);
+ void activateSession(const TQString& sessionId);
+ void feedAllSessions(const TQString &text);
+ void sendAllSessions(const TQString &text);
KURL baseURL() const;
- virtual bool processDynamic(const QCString &fun, const QByteArray &data, QCString& replyType, QByteArray &replyData);
+ virtual bool processDynamic(const TQCString &fun, const TQByteArray &data, TQCString& replyType, TQByteArray &replyData);
virtual QCStringList functionsDynamic();
void callReadPropertiesInternal(KConfig *config, int number) { readPropertiesInternal(config,number); }
@@ -124,15 +124,15 @@ public:
public slots:
void activateSession(int position);
- void activateSession(QWidget*);
+ void activateSession(TQWidget*);
void slotUpdateSessionConfig(TESession *session);
- void slotResizeSession(TESession*, QSize);
- void slotSetSessionEncoding(TESession *session, const QString &encoding);
- void slotGetSessionSchema(TESession *session, QString &schema);
- void slotSetSessionSchema(TESession *session, const QString &schema);
+ void slotResizeSession(TESession*, TQSize);
+ void slotSetSessionEncoding(TESession *session, const TQString &encoding);
+ void slotGetSessionSchema(TESession *session, TQString &schema);
+ void slotSetSessionSchema(TESession *session, const TQString &schema);
void makeGUI();
- QString newSession();
+ TQString newSession();
protected:
@@ -184,7 +184,7 @@ private slots:
void slotSelectTabbar();
void slotToggleMenubar();
void slotRenameSession();
- void slotRenameSession(TESession* ses, const QString &name);
+ void slotRenameSession(TESession* ses, const TQString &name);
void slotToggleMonitor();
void slotToggleMasterMode();
void slotClearAllSessionHistories();
@@ -209,8 +209,8 @@ private slots:
void disableMasterModeConnections();
void enableMasterModeConnections();
- void enterURL( const QString&, const QString& );
- void newSession( const QString&, const QString& );
+ void enterURL( const TQString&, const TQString& );
+ void newSession( const TQString&, const TQString& );
void slotFind();
void slotFindDone();
@@ -237,14 +237,14 @@ private slots:
void toggleBidi();
- void slotTabContextMenu(QWidget*, const QPoint &);
+ void slotTabContextMenu(TQWidget*, const TQPoint &);
void slotTabDetachSession();
void slotTabRenameSession();
void slotTabSelectColor();
void slotTabCloseSession();
void slotTabToggleMonitor();
void slotTabToggleMasterMode();
- void slotTabbarContextMenu(const QPoint &);
+ void slotTabbarContextMenu(const TQPoint &);
void slotTabSetViewOptions(int);
void slotTabbarToggleDynamicHide();
void slotToggleAutoResizeTabs();
@@ -253,10 +253,10 @@ private slots:
void slotSetEncoding();
private:
KSimpleConfig *defaultSession();
- QString newSession(KSimpleConfig *co, QString pgm = QString::null, const QStrList &args = QStrList(),
- const QString &_term = QString::null, const QString &_icon = QString::null,
- const QString &_title = QString::null, const QString &_cwd = QString::null);
- void readProperties(KConfig *config, const QString &schema, bool globalConfigOnly);
+ TQString newSession(KSimpleConfig *co, TQString pgm = TQString::null, const TQStrList &args = TQStrList(),
+ const TQString &_term = TQString::null, const TQString &_icon = TQString::null,
+ const TQString &_title = TQString::null, const TQString &_cwd = TQString::null);
+ void readProperties(KConfig *config, const TQString &schema, bool globalConfigOnly);
void applySettingsToGUI();
void makeTabWidget();
void makeBasicGUI();
@@ -270,31 +270,31 @@ private:
void setMasterMode(bool _state, TESession* _se=0);
void buildSessionMenus();
- void addSessionCommand(const QString & path);
+ void addSessionCommand(const TQString & path);
void loadSessionCommands();
void createSessionMenus();
- void addScreenSession(const QString & path, const QString & socket);
+ void addScreenSession(const TQString & path, const TQString & socket);
void resetScreenSessions();
void checkBitmapFonts();
void initTEWidget(TEWidget* new_te, TEWidget* default_te);
- void createSessionTab(TEWidget *widget, const QIconSet& iconSet,
- const QString &text, int index = -1);
- QIconSet iconSetForSession(TESession *session) const;
+ void createSessionTab(TEWidget *widget, const TQIconSet& iconSet,
+ const TQString &text, int index = -1);
+ TQIconSet iconSetForSession(TESession *session) const;
- bool eventFilter( QObject *o, QEvent *e );
+ bool eventFilter( TQObject *o, TQEvent *e );
- QPtrList<TEWidget> activeTEs();
+ TQPtrList<TEWidget> activeTEs();
- QPtrDict<TESession> action2session;
- QPtrDict<KRadioAction> session2action;
- QPtrList<TESession> sessions;
+ TQPtrDict<TESession> action2session;
+ TQPtrDict<KRadioAction> session2action;
+ TQPtrList<TESession> sessions;
- QIntDict<KSimpleConfig> no2command; //QT4 - convert to QList
+ TQIntDict<KSimpleConfig> no2command; //QT4 - convert to QList
KSimpleConfig* m_defaultSession;
- QString m_defaultSessionFilename;
+ TQString m_defaultSessionFilename;
KTabWidget* tabwidget;
TEWidget* te; // the visible TEWidget, either sole one or one of many
@@ -302,9 +302,9 @@ private:
TESession* se_previous;
TESession* m_initialSession;
ColorSchemaList* colors;
- QString s_encodingName;
+ TQString s_encodingName;
- QPtrDict<KRootPixmap> rootxpms;
+ TQPtrDict<KRootPixmap> rootxpms;
KWinModule* kWinModule;
KMenuBar* menubar;
@@ -371,7 +371,7 @@ private:
KonsoleFind* m_finddialog;
bool m_find_first;
bool m_find_found;
- QString m_find_pattern;
+ TQString m_find_pattern;
int cmd_serial;
int cmd_first_screen;
@@ -386,17 +386,17 @@ private:
int sessionIdCounter;
int monitorSilenceSeconds;
- QString s_schema;
- QString s_kconfigSchema;
- QString s_word_seps; // characters that are considered part of a word
- QString pmPath; // pixmap path
- QString dropText;
- QFont defaultFont;
- QSize defaultSize;
+ TQString s_schema;
+ TQString s_kconfigSchema;
+ TQString s_word_seps; // characters that are considered part of a word
+ TQString pmPath; // pixmap path
+ TQString dropText;
+ TQFont defaultFont;
+ TQSize defaultSize;
- QRect _saveGeometry;
+ TQRect _saveGeometry;
- QTimer m_closeTimeout;
+ TQTimer m_closeTimeout;
TabViewModes m_tabViewMode;
bool b_dynamicTabHide;
@@ -426,15 +426,15 @@ private:
TESession* m_contextMenuSession;
- QToolButton* m_newSessionButton;
- QToolButton* m_removeSessionButton;
- QPoint m_newSessionButtonMousePressPos;
+ TQToolButton* m_newSessionButton;
+ TQToolButton* m_removeSessionButton;
+ TQPoint m_newSessionButtonMousePressPos;
- QSignalMapper* sessionNumberMapper;
- QStringList sl_sessionShortCuts;
- QString s_workDir;
+ TQSignalMapper* sessionNumberMapper;
+ TQStringList sl_sessionShortCuts;
+ TQString s_workDir;
- QColor m_tabColor;
+ TQColor m_tabColor;
};
class QSpinBox;
@@ -445,7 +445,7 @@ class HistoryTypeDialog : public KDialogBase
public:
HistoryTypeDialog(const HistoryType& histType,
unsigned int histSize,
- QWidget *parent);
+ TQWidget *parent);
public slots:
@@ -457,10 +457,10 @@ public slots:
bool isOn() const;
protected:
- QLabel* m_label;
- QSpinBox* m_size;
- QCheckBox* m_btnEnable;
- QPushButton* m_setUnlimited;
+ TQLabel* m_label;
+ TQSpinBox* m_size;
+ TQCheckBox* m_btnEnable;
+ TQPushButton* m_setUnlimited;
};
class SizeDialog : public KDialogBase
@@ -469,7 +469,7 @@ class SizeDialog : public KDialogBase
public:
SizeDialog(unsigned int const columns,
unsigned int const lines,
- QWidget *parent);
+ TQWidget *parent);
public slots:
void slotDefault();
@@ -478,24 +478,24 @@ public slots:
unsigned int lines() const;
protected:
- QSpinBox* m_columns;
- QSpinBox* m_lines;
+ TQSpinBox* m_columns;
+ TQSpinBox* m_lines;
};
class KonsoleFind : public KEdFind
{
Q_OBJECT
public:
- KonsoleFind( QWidget *parent = 0, const char *name=0, bool modal=true );
+ KonsoleFind( TQWidget *parent = 0, const char *name=0, bool modal=true );
bool reg_exp() const;
private slots:
void slotEditRegExp();
private:
- QCheckBox* m_asRegExp;
- QDialog* m_editorDialog;
- QPushButton* m_editRegExp;
+ TQCheckBox* m_asRegExp;
+ TQDialog* m_editorDialog;
+ TQPushButton* m_editRegExp;
};
#endif
diff --git a/konsole/konsole/konsole_part.cpp b/konsole/konsole/konsole_part.cpp
index 68ca36024..620a0ebdb 100644
--- a/konsole/konsole/konsole_part.cpp
+++ b/konsole/konsole/konsole_part.cpp
@@ -23,9 +23,9 @@
#include <assert.h>
-#include <qfile.h>
-#include <qlayout.h>
-#include <qwmatrix.h>
+#include <tqfile.h>
+#include <tqlayout.h>
+#include <tqwmatrix.h>
#include <kaboutdata.h>
#include <kcharsets.h>
@@ -38,12 +38,12 @@
#include <kmessagebox.h>
#include <krun.h>
#include <kstdaction.h>
-#include <qlabel.h>
+#include <tqlabel.h>
#include <kprocctrl.h>
-#include <qcheckbox.h>
-#include <qspinbox.h>
-#include <qpushbutton.h>
+#include <tqcheckbox.h>
+#include <tqspinbox.h>
+#include <tqpushbutton.h>
#include <kpopupmenu.h>
#include <krootpixmap.h>
#include <kconfig.h>
@@ -76,9 +76,9 @@ konsoleFactory::~konsoleFactory()
s_aboutData = 0;
}
-KParts::Part *konsoleFactory::createPartObject(QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name, const char *classname,
- const QStringList&)
+KParts::Part *konsoleFactory::createPartObject(TQWidget *parentWidget, const char *widgetName,
+ TQObject *parent, const char *name, const char *classname,
+ const TQStringList&)
{
// kdDebug(1211) << "konsoleFactory::createPart parentWidget=" << parentWidget << " parent=" << parent << endl;
KParts::Part *obj = new konsolePart(parentWidget, widgetName, parent, name, classname);
@@ -97,7 +97,7 @@ KInstance *konsoleFactory::instance()
#define DEFAULT_HISTORY_SIZE 1000
-konsolePart::konsolePart(QWidget *_parentWidget, const char *widgetName, QObject *parent, const char *name, const char *classname)
+konsolePart::konsolePart(TQWidget *_parentWidget, const char *widgetName, TQObject *parent, const char *name, const char *classname)
: KParts::ReadOnlyPart(parent, name)
,te(0)
,se(0)
@@ -131,7 +131,7 @@ konsolePart::konsolePart(QWidget *_parentWidget, const char *widgetName, QObject
m_streamEnabled = ( classname && strcmp( classname, "TerminalEmulator" ) == 0 );
- QStrList eargs;
+ TQStrList eargs;
const char* shell = getenv("SHELL");
@@ -142,8 +142,8 @@ konsolePart::konsolePart(QWidget *_parentWidget, const char *widgetName, QObject
setWidget(te);
te->setFocus();
- connect( te,SIGNAL(configureRequest(TEWidget*,int,int,int)),
- this,SLOT(configureRequest(TEWidget*,int,int,int)) );
+ connect( te,TQT_SIGNAL(configureRequest(TEWidget*,int,int,int)),
+ this,TQT_SLOT(configureRequest(TEWidget*,int,int,int)) );
colors = new ColorSchemaList();
colors->checkSchemas();
@@ -180,30 +180,30 @@ konsolePart::konsolePart(QWidget *_parentWidget, const char *widgetName, QObject
{
m_keytab->clear();
- QStringList kt_titles;
- typedef QMap<QString,KeyTrans*> QStringKeyTransMap;
+ TQStringList kt_titles;
+ typedef TQMap<TQString,KeyTrans*> QStringKeyTransMap;
QStringKeyTransMap kt_map;
for (int i = 0; i < KeyTrans::count(); i++)
{
KeyTrans* ktr = KeyTrans::find(i);
assert( ktr );
- QString title=ktr->hdr().lower();
+ TQString title=ktr->hdr().lower();
kt_titles << title;
kt_map[title] = ktr;
}
kt_titles.sort();
- for ( QStringList::Iterator it = kt_titles.begin(); it != kt_titles.end(); ++it ) {
+ for ( TQStringList::Iterator it = kt_titles.begin(); it != kt_titles.end(); ++it ) {
KeyTrans* ktr = kt_map[*it];
assert( ktr );
- QString title=ktr->hdr();
+ TQString title=ktr->hdr();
m_keytab->insertItem(title.replace('&',"&&"),ktr->numb());
}
}
applySettingsToGUI();
- QTimer::singleShot( 0, this, SLOT( autoShowShell() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( autoShowShell() ) );
}
void konsolePart::autoShowShell()
@@ -229,10 +229,10 @@ void konsolePart::doneSession(TESession*)
if (se && b_autoDestroy)
{
// kdDebug(1211) << "doneSession - disconnecting done" << endl;
- disconnect( se,SIGNAL(done(TESession*)),
- this,SLOT(doneSession(TESession*)) );
+ disconnect( se,TQT_SIGNAL(done(TESession*)),
+ this,TQT_SLOT(doneSession(TESession*)) );
se->setConnect(false);
- //QTimer::singleShot(100,se,SLOT(terminate()));
+ //TQTimer::singleShot(100,se,TQT_SLOT(terminate()));
// kdDebug(1211) << "se->terminate()" << endl;
se->terminate();
}
@@ -241,7 +241,7 @@ void konsolePart::doneSession(TESession*)
void konsolePart::sessionDestroyed()
{
// kdDebug(1211) << "sessionDestroyed()" << endl;
- disconnect( se, SIGNAL( destroyed() ), this, SLOT( sessionDestroyed() ) );
+ disconnect( se, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( sessionDestroyed() ) );
se = 0;
if (b_autoDestroy)
delete this;
@@ -250,7 +250,7 @@ void konsolePart::sessionDestroyed()
void konsolePart::configureRequest(TEWidget*_te,int,int x,int y)
{
if (m_popupMenu)
- m_popupMenu->popup(_te->mapToGlobal(QPoint(x,y)));
+ m_popupMenu->popup(_te->mapToGlobal(TQPoint(x,y)));
}
konsolePart::~konsolePart()
@@ -264,7 +264,7 @@ konsolePart::~konsolePart()
while(se && KProcessController::theKProcessController->waitForProcessExit(1))
;
- disconnect( se, SIGNAL( destroyed() ), this, SLOT( sessionDestroyed() ) );
+ disconnect( se, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( sessionDestroyed() ) );
// kdDebug(1211) << "Deleting se session" << endl;
delete se;
se=0;
@@ -292,8 +292,8 @@ bool konsolePart::openURL( const KURL & url )
if ( url.isLocalFile() ) {
struct stat buff;
- stat( QFile::encodeName( url.path() ), &buff );
- QString text = ( S_ISDIR( buff.st_mode ) ? url.path() : url.directory() );
+ stat( TQFile::encodeName( url.path() ), &buff );
+ TQString text = ( S_ISDIR( buff.st_mode ) ? url.path() : url.directory() );
showShellInDir( text );
}
@@ -301,7 +301,7 @@ bool konsolePart::openURL( const KURL & url )
return true;
}
-void konsolePart::emitOpenURLRequest(const QString &cwd)
+void konsolePart::emitOpenURLRequest(const TQString &cwd)
{
KURL url;
url.setPath(cwd);
@@ -332,7 +332,7 @@ void konsolePart::makeGUI()
m_signals->insertItem( i18n( "&Kill Task" ) + " (KILL)", SIGKILL);
m_signals->insertItem( i18n( "User Signal &1") + " (USR1)", SIGUSR1);
m_signals->insertItem( i18n( "User Signal &2") + " (USR2)", SIGUSR2);
- connect(m_signals, SIGNAL(activated(int)), SLOT(sendSignal(int)));
+ connect(m_signals, TQT_SIGNAL(activated(int)), TQT_SLOT(sendSignal(int)));
}
// Settings Menu ----------------------------------------------------------------
@@ -342,9 +342,9 @@ void konsolePart::makeGUI()
// Scrollbar
selectScrollbar = new KSelectAction(i18n("Sc&rollbar"), 0, this,
- SLOT(slotSelectScrollbar()), settingsActions);
+ TQT_SLOT(slotSelectScrollbar()), settingsActions);
- QStringList scrollitems;
+ TQStringList scrollitems;
scrollitems << i18n("&Hide") << i18n("&Left") << i18n("&Right");
selectScrollbar->setItems(scrollitems);
selectScrollbar->plug(m_options);
@@ -352,9 +352,9 @@ void konsolePart::makeGUI()
// Select Bell
m_options->insertSeparator();
selectBell = new KSelectAction(i18n("&Bell"), SmallIconSet( "bell"), 0 , this,
- SLOT(slotSelectBell()), settingsActions, "bell");
+ TQT_SLOT(slotSelectBell()), settingsActions, "bell");
- QStringList bellitems;
+ TQStringList bellitems;
bellitems << i18n("System &Bell")
<< i18n("System &Notification")
<< i18n("&Visible Bell")
@@ -363,14 +363,14 @@ void konsolePart::makeGUI()
selectBell->plug(m_options);
m_fontsizes = new KActionMenu( i18n( "Font" ), SmallIconSet( "text" ), settingsActions, 0L );
- m_fontsizes->insert( new KAction( i18n( "&Enlarge Font" ), SmallIconSet( "viewmag+" ), 0, this, SLOT( biggerFont() ), settingsActions, "enlarge_font" ) );
- m_fontsizes->insert( new KAction( i18n( "&Shrink Font" ), SmallIconSet( "viewmag-" ), 0, this, SLOT( smallerFont() ), settingsActions, "shrink_font" ) );
- m_fontsizes->insert( new KAction( i18n( "Se&lect..." ), SmallIconSet( "font" ), 0, this, SLOT( slotSelectFont() ), settingsActions, "select_font" ) );
+ m_fontsizes->insert( new KAction( i18n( "&Enlarge Font" ), SmallIconSet( "viewmag+" ), 0, this, TQT_SLOT( biggerFont() ), settingsActions, "enlarge_font" ) );
+ m_fontsizes->insert( new KAction( i18n( "&Shrink Font" ), SmallIconSet( "viewmag-" ), 0, this, TQT_SLOT( smallerFont() ), settingsActions, "shrink_font" ) );
+ m_fontsizes->insert( new KAction( i18n( "Se&lect..." ), SmallIconSet( "font" ), 0, this, TQT_SLOT( slotSelectFont() ), settingsActions, "select_font" ) );
m_fontsizes->plug(m_options);
// encoding menu, start with default checked !
- selectSetEncoding = new KSelectAction( i18n( "&Encoding" ), SmallIconSet("charset" ), 0, this, SLOT(slotSetEncoding()), settingsActions, "set_encoding" );
- QStringList list = KGlobal::charsets()->descriptiveEncodingNames();
+ selectSetEncoding = new KSelectAction( i18n( "&Encoding" ), SmallIconSet("charset" ), 0, this, TQT_SLOT(slotSetEncoding()), settingsActions, "set_encoding" );
+ TQStringList list = KGlobal::charsets()->descriptiveEncodingNames();
list.prepend( i18n( "Default" ) );
selectSetEncoding->setItems(list);
selectSetEncoding->setCurrentItem (0);
@@ -381,7 +381,7 @@ void konsolePart::makeGUI()
{
m_keytab = new KPopupMenu((KMainWindow*)parentWidget);
m_keytab->setCheckable(true);
- connect(m_keytab, SIGNAL(activated(int)), SLOT(keytab_menu_activated(int)));
+ connect(m_keytab, TQT_SIGNAL(activated(int)), TQT_SLOT(keytab_menu_activated(int)));
m_options->insertItem( SmallIconSet( "key_bindings" ), i18n( "&Keyboard" ), m_keytab );
}
@@ -390,23 +390,23 @@ void konsolePart::makeGUI()
{
m_schema = new KPopupMenu((KMainWindow*)parentWidget);
m_schema->setCheckable(true);
- connect(m_schema, SIGNAL(activated(int)), SLOT(schema_menu_activated(int)));
- connect(m_schema, SIGNAL(aboutToShow()), SLOT(schema_menu_check()));
+ connect(m_schema, TQT_SIGNAL(activated(int)), TQT_SLOT(schema_menu_activated(int)));
+ connect(m_schema, TQT_SIGNAL(aboutToShow()), TQT_SLOT(schema_menu_check()));
m_options->insertItem( SmallIconSet( "colorize" ), i18n( "Sch&ema" ), m_schema);
}
KAction *historyType = new KAction(i18n("&History..."), "history", 0, this,
- SLOT(slotHistoryType()), settingsActions, "history");
+ TQT_SLOT(slotHistoryType()), settingsActions, "history");
historyType->plug(m_options);
m_options->insertSeparator();
// Select line spacing
selectLineSpacing = new KSelectAction(i18n("Li&ne Spacing"),
SmallIconSet("leftjust"), 0, this,
- SLOT(slotSelectLineSpacing()), settingsActions );
+ TQT_SLOT(slotSelectLineSpacing()), settingsActions );
- QStringList lineSpacingList;
+ TQStringList lineSpacingList;
lineSpacingList
<< i18n("&0")
<< i18n("&1")
@@ -422,30 +422,30 @@ void konsolePart::makeGUI()
// Blinking Cursor
blinkingCursor = new KToggleAction (i18n("Blinking &Cursor"),
- 0, this,SLOT(slotBlinkingCursor()), settingsActions);
+ 0, this,TQT_SLOT(slotBlinkingCursor()), settingsActions);
blinkingCursor->plug(m_options);
// Frame on/off
showFrame = new KToggleAction(i18n("Show Fr&ame"), 0,
- this, SLOT(slotToggleFrame()), settingsActions);
+ this, TQT_SLOT(slotToggleFrame()), settingsActions);
showFrame->setCheckedState(i18n("Hide Fr&ame"));
showFrame->plug(m_options);
// Word Connectors
KAction *WordSeps = new KAction(i18n("Wor&d Connectors..."), 0, this,
- SLOT(slotWordSeps()), settingsActions);
+ TQT_SLOT(slotWordSeps()), settingsActions);
WordSeps->plug(m_options);
// Use Konsole's Settings
m_options->insertSeparator();
m_useKonsoleSettings = new KToggleAction( i18n("&Use Konsole's Settings"),
- 0, this, SLOT(slotUseKonsoleSettings()), 0, "use_konsole_settings" );
+ 0, this, TQT_SLOT(slotUseKonsoleSettings()), 0, "use_konsole_settings" );
m_useKonsoleSettings->plug(m_options);
// Save Settings
m_options->insertSeparator();
KAction *saveSettings = new KAction(i18n("&Save as Default"), "filesave", 0, this,
- SLOT(saveProperties()), actions, "save_default");
+ TQT_SLOT(saveProperties()), actions, "save_default");
saveSettings->plug(m_options);
if (KGlobalSettings::insertTearOffHandle())
m_options->insertTearOffHandle();
@@ -454,15 +454,15 @@ void konsolePart::makeGUI()
// Popup Menu -------------------------------------------------------------------
m_popupMenu = new KPopupMenu((KMainWindow*)parentWidget);
KAction* selectionEnd = new KAction(i18n("Set Selection End"), 0, te,
- SLOT(setSelectionEnd()), actions, "selection_end");
+ TQT_SLOT(setSelectionEnd()), actions, "selection_end");
selectionEnd->plug(m_popupMenu);
KAction *copyClipboard = new KAction(i18n("&Copy"), "editcopy", 0,
- te, SLOT(copyClipboard()), actions, "edit_copy");
+ te, TQT_SLOT(copyClipboard()), actions, "edit_copy");
copyClipboard->plug(m_popupMenu);
KAction *pasteClipboard = new KAction(i18n("&Paste"), "editpaste", 0,
- te, SLOT(pasteClipboard()), actions, "edit_paste");
+ te, TQT_SLOT(pasteClipboard()), actions, "edit_paste");
pasteClipboard->plug(m_popupMenu);
if (m_signals)
@@ -478,7 +478,7 @@ void konsolePart::makeGUI()
}
KAction *closeSession = new KAction(i18n("&Close Terminal Emulator"), "fileclose", 0, this,
- SLOT(closeCurrentSession()), actions, "close_session");
+ TQT_SLOT(closeCurrentSession()), actions, "close_session");
closeSession->plug(m_popupMenu);
if (KGlobalSettings::insertTearOffHandle())
m_popupMenu->insertTearOffHandle();
@@ -569,10 +569,10 @@ void konsolePart::readProperties()
n_encoding = config->readNumEntry("encoding",0);
- QFont tmpFont = KGlobalSettings::fixedFont();
+ TQFont tmpFont = KGlobalSettings::fixedFont();
defaultFont = config->readFontEntry("defaultfont", &tmpFont);
- QString schema = config->readEntry("Schema");
+ TQString schema = config->readEntry("Schema");
s_kconfigSchema=config->readEntry("schema");
ColorSchema* sch = colors->find(schema.isEmpty() ? s_kconfigSchema : schema);
@@ -588,7 +588,7 @@ void konsolePart::readProperties()
if (sch->useTransparency()) {
if (!rootxpm)
rootxpm = new KRootPixmap(te);
- rootxpm->setFadeEffect(sch->tr_x(), QColor(sch->tr_r(), sch->tr_g(), sch->tr_b()));
+ rootxpm->setFadeEffect(sch->tr_x(), TQColor(sch->tr_r(), sch->tr_g(), sch->tr_b()));
rootxpm->start();
rootxpm->repaint(true);
}
@@ -603,7 +603,7 @@ void konsolePart::readProperties()
te->setBellMode(n_bell);
te->setBlinkingCursor(config->readBoolEntry("BlinkingCursor",false));
- te->setFrameStyle( b_framevis?(QFrame::WinPanel|QFrame::Sunken):QFrame::NoFrame );
+ te->setFrameStyle( b_framevis?(TQFrame::WinPanel|TQFrame::Sunken):TQFrame::NoFrame );
te->setLineSpacing( config->readUnsignedNumEntry( "LineSpacing", 0 ) );
te->setScrollbarLocation(n_scroll);
te->setWordCharacters(s_word_seps);
@@ -656,7 +656,7 @@ void konsolePart::closeCurrentSession()
void konsolePart::slotToggleFrame()
{
b_framevis = showFrame->isChecked();
- te->setFrameStyle( b_framevis?(QFrame::WinPanel|QFrame::Sunken):QFrame::NoFrame);
+ te->setFrameStyle( b_framevis?(TQFrame::WinPanel|TQFrame::Sunken):TQFrame::NoFrame);
}
void konsolePart::slotSelectScrollbar()
@@ -669,8 +669,8 @@ void konsolePart::slotSelectScrollbar()
void konsolePart::slotSelectFont() {
if ( !se ) return;
- QFont font = se->widget()->getVTFont();
- if ( KFontDialog::getFont( font, true ) != QDialog::Accepted )
+ TQFont font = se->widget()->getVTFont();
+ if ( KFontDialog::getFont( font, true ) != TQDialog::Accepted )
return;
se->widget()->setVTFont( font );
@@ -679,7 +679,7 @@ void konsolePart::slotSelectFont() {
void konsolePart::biggerFont(void) {
if ( !se ) return;
- QFont f = te->getVTFont();
+ TQFont f = te->getVTFont();
f.setPointSize( f.pointSize() + 1 );
te->setVTFont( f );
}
@@ -687,7 +687,7 @@ void konsolePart::biggerFont(void) {
void konsolePart::smallerFont(void) {
if ( !se ) return;
- QFont f = te->getVTFont();
+ TQFont f = te->getVTFont();
if ( f.pointSize() < 6 ) return; // A minimum size
f.setPointSize( f.pointSize() - 1 );
te->setVTFont( f );
@@ -732,7 +732,7 @@ void konsolePart::updateSchemaMenu()
m_schema->clear();
for (int i = 0; i < (int) colors->count(); i++) {
ColorSchema* s = (ColorSchema*)colors->at(i);
- QString title=s->title();
+ TQString title=s->title();
m_schema->insertItem(title.replace('&',"&&"),s->numb(),0);
}
@@ -776,7 +776,7 @@ void konsolePart::setSchema(ColorSchema* s)
if (s->useTransparency()) {
if (!rootxpm)
rootxpm = new KRootPixmap(te);
- rootxpm->setFadeEffect(s->tr_x(), QColor(s->tr_r(), s->tr_g(), s->tr_b()));
+ rootxpm->setFadeEffect(s->tr_x(), TQColor(s->tr_r(), s->tr_g(), s->tr_b()));
rootxpm->start();
rootxpm->repaint(true);
}
@@ -804,7 +804,7 @@ void konsolePart::notifySize(int /* columns */, int /* lines */)
void konsolePart::pixmap_menu_activated(int item)
{
if (item <= 1) pmPath = "";
- QPixmap pm(pmPath);
+ TQPixmap pm(pmPath);
if (pm.isNull()) {
pmPath = "";
item = 1;
@@ -819,7 +819,7 @@ void konsolePart::pixmap_menu_activated(int item)
te->setBackgroundPixmap(pm);
break;
case 3: // center
- { QPixmap bgPixmap;
+ { TQPixmap bgPixmap;
bgPixmap.resize(te->size());
bgPixmap.fill(te->getDefaultBackColor());
bitBlt( &bgPixmap, ( te->size().width() - pm.width() ) / 2,
@@ -834,7 +834,7 @@ void konsolePart::pixmap_menu_activated(int item)
{
float sx = (float)te->size().width() / pm.width();
float sy = (float)te->size().height() / pm.height();
- QWMatrix matrix;
+ TQWMatrix matrix;
matrix.scale( sx, sy );
te->setBackgroundPixmap(pm.xForm( matrix ));
}
@@ -879,12 +879,12 @@ void konsolePart::slotSetEncoding()
if (!se) return;
bool found;
- QString enc = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
- QTextCodec * qtc = KGlobal::charsets()->codecForName(enc, found);
+ TQString enc = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
+ TQTextCodec * qtc = KGlobal::charsets()->codecForName(enc, found);
if(!found)
{
kdDebug() << "Codec " << selectSetEncoding->currentText() << " not found!" << endl;
- qtc = QTextCodec::codecForLocale();
+ qtc = TQTextCodec::codecForLocale();
}
n_encoding = selectSetEncoding->currentItem();
@@ -916,7 +916,7 @@ void konsolePart::slotUseKonsoleSettings()
void konsolePart::slotWordSeps() {
bool ok;
- QString seps = KInputDialog::getText( i18n( "Word Connectors" ),
+ TQString seps = KInputDialog::getText( i18n( "Word Connectors" ),
i18n( "Characters other than alphanumerics considered part of a word when double clicking:" ), s_word_seps, &ok, parentWidget );
if ( ok )
{
@@ -940,16 +940,16 @@ void konsolePart::guiActivateEvent( KParts::GUIActivateEvent * )
// Don't let ReadOnlyPart::guiActivateEvent reset the window caption
}
-bool konsolePart::doOpenStream( const QString& )
+bool konsolePart::doOpenStream( const TQString& )
{
return m_streamEnabled;
}
-bool konsolePart::doWriteStream( const QByteArray& data )
+bool konsolePart::doWriteStream( const TQByteArray& data )
{
if ( m_streamEnabled )
{
- QString cmd = QString::fromLocal8Bit( data.data(), data.size() );
+ TQString cmd = TQString::fromLocal8Bit( data.data(), data.size() );
se->sendSession( cmd );
return true;
}
@@ -965,30 +965,30 @@ bool konsolePart::doCloseStream()
HistoryTypeDialog::HistoryTypeDialog(const HistoryType& histType,
unsigned int histSize,
- QWidget *parent)
+ TQWidget *parent)
: KDialogBase(Plain, i18n("History Configuration"),
Help | Default | Ok | Cancel, Ok,
parent)
{
- QFrame *mainFrame = plainPage();
+ TQFrame *mainFrame = plainPage();
- QHBoxLayout *hb = new QHBoxLayout(mainFrame);
+ TQHBoxLayout *hb = new TQHBoxLayout(mainFrame);
- m_btnEnable = new QCheckBox(i18n("&Enable"), mainFrame);
+ m_btnEnable = new TQCheckBox(i18n("&Enable"), mainFrame);
- QObject::connect(m_btnEnable, SIGNAL(toggled(bool)),
- this, SLOT(slotHistEnable(bool)));
+ TQObject::connect(m_btnEnable, TQT_SIGNAL(toggled(bool)),
+ this, TQT_SLOT(slotHistEnable(bool)));
- m_size = new QSpinBox(0, 10 * 1000 * 1000, 100, mainFrame);
+ m_size = new TQSpinBox(0, 10 * 1000 * 1000, 100, mainFrame);
m_size->setValue(histSize);
m_size->setSpecialValueText(i18n("Unlimited (number of lines)", "Unlimited"));
- m_setUnlimited = new QPushButton(i18n("&Set Unlimited"), mainFrame);
- connect( m_setUnlimited,SIGNAL(clicked()), this,SLOT(slotSetUnlimited()) );
+ m_setUnlimited = new TQPushButton(i18n("&Set Unlimited"), mainFrame);
+ connect( m_setUnlimited,TQT_SIGNAL(clicked()), this,TQT_SLOT(slotSetUnlimited()) );
hb->addWidget(m_btnEnable);
hb->addSpacing(10);
- hb->addWidget(new QLabel(i18n("Number of lines:"), mainFrame));
+ hb->addWidget(new TQLabel(i18n("Number of lines:"), mainFrame));
hb->addWidget(m_size);
hb->addSpacing(10);
hb->addWidget(m_setUnlimited);
@@ -1054,8 +1054,8 @@ const char* sensibleShell()
return shell;
}
-void konsolePart::startProgram( const QString& program,
- const QStrList& args )
+void konsolePart::startProgram( const TQString& program,
+ const TQStrList& args )
{
// kdDebug(1211) << "konsolePart::startProgram for " << program << endl;
if ( !se )
@@ -1078,44 +1078,44 @@ void konsolePart::newSession()
{
if ( se ) delete se;
se = new TESession(te, "xterm", parentWidget->winId());
- connect( se,SIGNAL(done(TESession*)),
- this,SLOT(doneSession(TESession*)) );
- connect( se,SIGNAL(openURLRequest(const QString &)),
- this,SLOT(emitOpenURLRequest(const QString &)) );
- connect( se, SIGNAL( updateTitle(TESession*) ),
- this, SLOT( updateTitle(TESession*) ) );
- connect( se, SIGNAL(enableMasterModeConnections()),
- this, SLOT(enableMasterModeConnections()) );
- connect( se, SIGNAL( processExited(KProcess *) ),
- this, SIGNAL( processExited(KProcess *) ) );
- connect( se, SIGNAL( receivedData( const QString& ) ),
- this, SIGNAL( receivedData( const QString& ) ) );
- connect( se, SIGNAL( forkedChild() ),
- this, SIGNAL( forkedChild() ));
+ connect( se,TQT_SIGNAL(done(TESession*)),
+ this,TQT_SLOT(doneSession(TESession*)) );
+ connect( se,TQT_SIGNAL(openURLRequest(const TQString &)),
+ this,TQT_SLOT(emitOpenURLRequest(const TQString &)) );
+ connect( se, TQT_SIGNAL( updateTitle(TESession*) ),
+ this, TQT_SLOT( updateTitle(TESession*) ) );
+ connect( se, TQT_SIGNAL(enableMasterModeConnections()),
+ this, TQT_SLOT(enableMasterModeConnections()) );
+ connect( se, TQT_SIGNAL( processExited(KProcess *) ),
+ this, TQT_SIGNAL( processExited(KProcess *) ) );
+ connect( se, TQT_SIGNAL( receivedData( const TQString& ) ),
+ this, TQT_SIGNAL( receivedData( const TQString& ) ) );
+ connect( se, TQT_SIGNAL( forkedChild() ),
+ this, TQT_SIGNAL( forkedChild() ));
// We ignore the following signals
- //connect( se, SIGNAL(renameSession(TESession*,const QString&)),
- // this, SLOT(slotRenameSession(TESession*, const QString&)) );
- //connect( se->getEmulation(), SIGNAL(changeColumns(int)),
- // this, SLOT(changeColumns(int)) );
- //connect( se, SIGNAL(disableMasterModeConnections()),
- // this, SLOT(disableMasterModeConnections()) );
+ //connect( se, TQT_SIGNAL(renameSession(TESession*,const TQString&)),
+ // this, TQT_SLOT(slotRenameSession(TESession*, const TQString&)) );
+ //connect( se->getEmulation(), TQT_SIGNAL(changeColumns(int)),
+ // this, TQT_SLOT(changeColumns(int)) );
+ //connect( se, TQT_SIGNAL(disableMasterModeConnections()),
+ // this, TQT_SLOT(disableMasterModeConnections()) );
applyProperties();
se->setConnect(true);
// se->run();
- connect( se, SIGNAL( destroyed() ), this, SLOT( sessionDestroyed() ) );
+ connect( se, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( sessionDestroyed() ) );
// setFont( n_font ); // we do this here, to make TEWidget recalculate
// its geometry..
}
-void konsolePart::showShellInDir( const QString& dir )
+void konsolePart::showShellInDir( const TQString& dir )
{
if ( ! m_runningShell )
{
const char* s = sensibleShell();
- QStrList args;
+ TQStrList args;
args.append( s );
startProgram( s, args );
m_runningShell = true;
@@ -1123,19 +1123,19 @@ void konsolePart::showShellInDir( const QString& dir )
if ( ! dir.isNull() )
{
- QString text = dir;
+ TQString text = dir;
KRun::shellQuote(text);
- text = QString::fromLatin1("cd ") + text + '\n';
+ text = TQString::fromLatin1("cd ") + text + '\n';
te->emitText( text );
};
}
void konsolePart::showShell()
{
- if ( ! se ) showShellInDir( QString::null );
+ if ( ! se ) showShellInDir( TQString::null );
}
-void konsolePart::sendInput( const QString& text )
+void konsolePart::sendInput( const TQString& text )
{
te->emitText( text );
}
diff --git a/konsole/konsole/konsole_part.h b/konsole/konsole/konsole_part.h
index 5cff68c4e..2f49a5866 100644
--- a/konsole/konsole/konsole_part.h
+++ b/konsole/konsole/konsole_part.h
@@ -52,10 +52,10 @@ public:
konsoleFactory();
virtual ~konsoleFactory();
- virtual KParts::Part* createPartObject(QWidget *parentWidget = 0, const char *widgetName = 0,
- QObject* parent = 0, const char* name = 0,
+ virtual KParts::Part* createPartObject(TQWidget *parentWidget = 0, const char *widgetName = 0,
+ TQObject* parent = 0, const char* name = 0,
const char* classname = "KParts::Part",
- const QStringList &args = QStringList());
+ const TQStringList &args = TQStringList());
static KInstance *instance();
@@ -70,12 +70,12 @@ class konsolePart: public KParts::ReadOnlyPart, public TerminalInterface, public
{
Q_OBJECT
public:
- konsolePart(QWidget *parentWidget, const char *widgetName, QObject * parent, const char *name, const char *classname = 0);
+ konsolePart(TQWidget *parentWidget, const char *widgetName, TQObject * parent, const char *name, const char *classname = 0);
virtual ~konsolePart();
signals:
void processExited( KProcess * );
- void receivedData( const QString& s );
+ void receivedData( const TQString& s );
void forkedChild();
protected:
virtual bool openURL( const KURL & url );
@@ -93,7 +93,7 @@ signals:
void enableMasterModeConnections();
private slots:
- void emitOpenURLRequest(const QString &url);
+ void emitOpenURLRequest(const TQString &url);
void readProperties();
void saveProperties();
@@ -136,11 +136,11 @@ signals:
void setSchema(ColorSchema* s);
void updateKeytabMenu();
- bool doOpenStream( const QString& );
- bool doWriteStream( const QByteArray& );
+ bool doOpenStream( const TQString& );
+ bool doWriteStream( const TQByteArray& );
bool doCloseStream();
- QWidget* parentWidget;
+ TQWidget* parentWidget;
TEWidget* te;
TESession* se;
ColorSchemaList* colors;
@@ -166,12 +166,12 @@ signals:
KPopupMenu* m_options;
KPopupMenu* m_popupMenu;
- QFont defaultFont;
+ TQFont defaultFont;
- QString pmPath; // pixmap path
- QString s_schema;
- QString s_kconfigSchema;
- QString s_word_seps; // characters that are considered part of a word
+ TQString pmPath; // pixmap path
+ TQString s_schema;
+ TQString s_kconfigSchema;
+ TQString s_word_seps; // characters that are considered part of a word
bool b_framevis:1;
bool b_histEnabled:1;
@@ -194,11 +194,11 @@ public:
// these are the implementations for the TermEmuInterface
// functions...
- void startProgram( const QString& program,
- const QStrList& args );
+ void startProgram( const TQString& program,
+ const TQStrList& args );
void newSession();
- void showShellInDir( const QString& dir );
- void sendInput( const QString& text );
+ void showShellInDir( const TQString& dir );
+ void sendInput( const TQString& text );
void setAutoDestroy( bool );
void setAutoStartShell( bool );
};
@@ -211,7 +211,7 @@ class HistoryTypeDialog : public KDialogBase
public:
HistoryTypeDialog(const HistoryType& histType,
unsigned int histSize,
- QWidget *parent);
+ TQWidget *parent);
public slots:
void slotDefault();
@@ -222,9 +222,9 @@ public slots:
bool isOn() const;
protected:
- QCheckBox* m_btnEnable;
- QSpinBox* m_size;
- QPushButton* m_setUnlimited;
+ TQCheckBox* m_btnEnable;
+ TQSpinBox* m_size;
+ TQPushButton* m_setUnlimited;
};
//////////////////////////////////////////////////////////////////////
diff --git a/konsole/konsole/konsole_wcwidth.cpp b/konsole/konsole/konsole_wcwidth.cpp
index 1592e2de3..73d7c7131 100644
--- a/konsole/konsole/konsole_wcwidth.cpp
+++ b/konsole/konsole/konsole_wcwidth.cpp
@@ -209,7 +209,7 @@ int konsole_wcwidth_cjk(Q_UINT16 ucs)
}
// single byte char: +1, multi byte char: +2
-int string_width( const QString &txt )
+int string_width( const TQString &txt )
{
int w = 0;
diff --git a/konsole/konsole/konsole_wcwidth.h b/konsole/konsole/konsole_wcwidth.h
index 15f6ef9a8..b070beb02 100644
--- a/konsole/konsole/konsole_wcwidth.h
+++ b/konsole/konsole/konsole_wcwidth.h
@@ -6,12 +6,12 @@
#ifndef _KONSOLE_WCWIDTH_H_
#define _KONSOLE_WCWIDTH_H_
-#include <qglobal.h>
-#include <qstring.h>
+#include <tqglobal.h>
+#include <tqstring.h>
int konsole_wcwidth(Q_UINT16 ucs);
//int konsole_wcwidth_cjk(Q_UINT16 ucs);
-int string_width( const QString &txt );
+int string_width( const TQString &txt );
#endif
diff --git a/konsole/konsole/konsolebookmarkhandler.cpp b/konsole/konsole/konsolebookmarkhandler.cpp
index 27bdb4f87..9de6fe3ab 100644
--- a/konsole/konsole/konsolebookmarkhandler.cpp
+++ b/konsole/konsole/konsolebookmarkhandler.cpp
@@ -24,14 +24,14 @@
#include <kio/job.h>
#include <kio/netaccess.h>
#include <kdebug.h>
-#include <qfile.h>
+#include <tqfile.h>
#include "konsole.h"
#include "konsolebookmarkmenu.h"
#include "konsolebookmarkhandler.h"
KonsoleBookmarkHandler::KonsoleBookmarkHandler( Konsole *konsole, bool toplevel )
- : QObject( konsole, "KonsoleBookmarkHandler" ),
+ : TQObject( konsole, "KonsoleBookmarkHandler" ),
KBookmarkOwner(),
m_konsole( konsole )
{
@@ -39,10 +39,10 @@ KonsoleBookmarkHandler::KonsoleBookmarkHandler( Konsole *konsole, bool toplevel
// KDE3.5 - Konsole's bookmarks are now in konsole/bookmarks.xml
// TODO: Consider removing for KDE4
- QString new_bm_file = locateLocal( "data", "konsole/bookmarks.xml" );
- if ( !QFile::exists( new_bm_file ) ) {
- QString old_bm_file = locateLocal( "data", "kfile/bookmarks.xml" );
- if ( QFile::exists( old_bm_file ) )
+ TQString new_bm_file = locateLocal( "data", "konsole/bookmarks.xml" );
+ if ( !TQFile::exists( new_bm_file ) ) {
+ TQString old_bm_file = locateLocal( "data", "kfile/bookmarks.xml" );
+ if ( TQFile::exists( old_bm_file ) )
// We want sync here...
if ( !KIO::NetAccess::copy( KURL( old_bm_file ),
KURL ( new_bm_file ), 0 ) ) {
@@ -59,8 +59,8 @@ KonsoleBookmarkHandler::KonsoleBookmarkHandler( Konsole *konsole, bool toplevel
manager->setUpdate( true );
manager->setShowNSBookmarks( false );
- connect( manager, SIGNAL( changed(const QString &, const QString &) ),
- SLOT( slotBookmarksChanged(const QString &, const QString &) ) );
+ connect( manager, TQT_SIGNAL( changed(const TQString &, const TQString &) ),
+ TQT_SLOT( slotBookmarksChanged(const TQString &, const TQString &) ) );
if (toplevel) {
m_bookmarkMenu = new KonsoleBookmarkMenu( manager, this, m_menu,
@@ -77,25 +77,25 @@ KonsoleBookmarkHandler::~KonsoleBookmarkHandler()
delete m_bookmarkMenu;
}
-QString KonsoleBookmarkHandler::currentURL() const
+TQString KonsoleBookmarkHandler::currentURL() const
{
return m_konsole->baseURL().prettyURL();
}
-QString KonsoleBookmarkHandler::currentTitle() const
+TQString KonsoleBookmarkHandler::currentTitle() const
{
const KURL &u = m_konsole->baseURL();
if (u.isLocalFile())
{
- QString path = u.path();
+ TQString path = u.path();
path = KShell::tildeExpand(path);
return path;
}
return u.prettyURL();
}
-void KonsoleBookmarkHandler::slotBookmarksChanged( const QString &,
- const QString &)
+void KonsoleBookmarkHandler::slotBookmarksChanged( const TQString &,
+ const TQString &)
{
// This is called when someone changes bookmarks in konsole....
m_bookmarkMenu->slotBookmarksChanged("");
diff --git a/konsole/konsole/konsolebookmarkhandler.h b/konsole/konsole/konsolebookmarkhandler.h
index 63ab747d9..a90b8e016 100644
--- a/konsole/konsole/konsolebookmarkhandler.h
+++ b/konsole/konsole/konsolebookmarkhandler.h
@@ -28,7 +28,7 @@ class KPopupMenu;
class KonsoleBookmarkMenu;
class KBookmarkManager;
-class KonsoleBookmarkHandler : public QObject, public KBookmarkOwner
+class KonsoleBookmarkHandler : public TQObject, public KBookmarkOwner
{
Q_OBJECT
@@ -36,27 +36,27 @@ public:
KonsoleBookmarkHandler( Konsole *konsole, bool toplevel );
~KonsoleBookmarkHandler();
- QPopupMenu * popupMenu();
+ TQPopupMenu * popupMenu();
// KBookmarkOwner interface:
- virtual void openBookmarkURL( const QString& url, const QString& title )
+ virtual void openBookmarkURL( const TQString& url, const TQString& title )
{ emit openURL( url, title ); }
- virtual QString currentURL() const;
- virtual QString currentTitle() const;
+ virtual TQString currentURL() const;
+ virtual TQString currentTitle() const;
KPopupMenu *menu() const { return m_menu; }
private slots:
- void slotBookmarksChanged( const QString &, const QString & caller );
+ void slotBookmarksChanged( const TQString &, const TQString & caller );
signals:
- void openURL( const QString& url, const QString& title );
+ void openURL( const TQString& url, const TQString& title );
private:
Konsole *m_konsole;
KPopupMenu *m_menu;
KonsoleBookmarkMenu *m_bookmarkMenu;
- QString m_file;
+ TQString m_file;
};
#endif // KONSOLEBOOKMARKHANDLER_H
diff --git a/konsole/konsole/konsolebookmarkmenu.cpp b/konsole/konsole/konsolebookmarkmenu.cpp
index ea82a75e3..0686cfbf1 100644
--- a/konsole/konsole/konsolebookmarkmenu.cpp
+++ b/konsole/konsole/konsolebookmarkmenu.cpp
@@ -27,7 +27,7 @@
KonsoleBookmarkMenu::KonsoleBookmarkMenu( KBookmarkManager* mgr,
KonsoleBookmarkHandler * _owner, KPopupMenu * _parentMenu,
KActionCollection *collec, bool _isRoot, bool _add,
- const QString & parentAddress )
+ const TQString & parentAddress )
: KBookmarkMenu( mgr, _owner, _parentMenu, collec, _isRoot, _add,
parentAddress),
m_kOwner(_owner)
@@ -36,14 +36,14 @@ KonsoleBookmarkMenu::KonsoleBookmarkMenu( KBookmarkManager* mgr,
/*
* First, we disconnect KBookmarkMenu::slotAboutToShow()
* Then, we connect KonsoleBookmarkMenu::slotAboutToShow().
- * They are named differently because the SLOT() macro thinks we want
+ * They are named differently because the TQT_SLOT() macro thinks we want
* KonsoleBookmarkMenu::KBookmarkMenu::slotAboutToShow()
* Could this be solved if slotAboutToShow() is virtual in KBookmarMenu?
*/
- disconnect( _parentMenu, SIGNAL( aboutToShow() ), this,
- SLOT( slotAboutToShow() ) );
- connect( _parentMenu, SIGNAL( aboutToShow() ),
- SLOT( slotAboutToShow2() ) );
+ disconnect( _parentMenu, TQT_SIGNAL( aboutToShow() ), this,
+ TQT_SLOT( slotAboutToShow() ) );
+ connect( _parentMenu, TQT_SIGNAL( aboutToShow() ),
+ TQT_SLOT( slotAboutToShow2() ) );
}
/*
@@ -68,7 +68,7 @@ void KonsoleBookmarkMenu::slotAboutToShow2()
void KonsoleBookmarkMenu::refill()
{
m_lstSubMenus.clear();
- QPtrListIterator<KAction> it( m_actions );
+ TQPtrListIterator<KAction> it( m_actions );
for (; it.current(); ++it )
it.current()->unplug( m_parentMenu );
m_parentMenu->clear();
@@ -96,7 +96,7 @@ void KonsoleBookmarkMenu::fillBookmarkMenu()
for ( KBookmark bm = parentBookmark.first(); !bm.isNull();
bm = parentBookmark.next(bm) )
{
- QString text = bm.text();
+ TQString text = bm.text();
text.replace( '&', "&&" );
if ( !separatorInserted && m_bIsRoot) { // inserted before the first konq bookmark, to avoid the separator if no konq bookmark
m_parentMenu->insertSeparator();
@@ -113,7 +113,7 @@ void KonsoleBookmarkMenu::fillBookmarkMenu()
// kdDebug(1203) << "Creating URL bookmark menu item for " << bm.text() << endl;
// create a normal URL item, with ID as a name
KAction * action = new KAction( text, bm.icon(), 0,
- this, SLOT( slotBookmarkSelected() ),
+ this, TQT_SLOT( slotBookmarkSelected() ),
m_actionCollection, bm.url().url().utf8() );
action->setStatusText( bm.url().prettyURL() );
@@ -149,7 +149,7 @@ void KonsoleBookmarkMenu::fillBookmarkMenu()
void KonsoleBookmarkMenu::slotBookmarkSelected()
{
if ( !m_pOwner ) return; // this view doesn't handle bookmarks...
- m_kOwner->openBookmarkURL( QString::fromUtf8(sender()->name()), /* URL */
+ m_kOwner->openBookmarkURL( TQString::fromUtf8(sender()->name()), /* URL */
( (KAction *)sender() )->text() /* Title */ );
}
diff --git a/konsole/konsole/konsolebookmarkmenu.h b/konsole/konsole/konsolebookmarkmenu.h
index e4540da69..2c3576390 100644
--- a/konsole/konsole/konsolebookmarkmenu.h
+++ b/konsole/konsole/konsolebookmarkmenu.h
@@ -19,7 +19,7 @@
#ifndef KONSOLEBOOKMARKMENU_H
#define KONSOLEBOOKMARKMENU_H
-#include <qptrlist.h>
+#include <tqptrlist.h>
#include <kbookmark.h>
#include <kbookmarkmenu.h>
@@ -44,7 +44,7 @@ public:
KonsoleBookmarkMenu( KBookmarkManager* mgr,
KonsoleBookmarkHandler * _owner, KPopupMenu * _parentMenu,
KActionCollection *collec, bool _isRoot,
- bool _add = true, const QString & parentAddress = "");
+ bool _add = true, const TQString & parentAddress = "");
void fillBookmarkMenu();
diff --git a/konsole/konsole/konsoleiface.h b/konsole/konsole/konsoleiface.h
index fc3002a35..653a945e5 100644
--- a/konsole/konsole/konsoleiface.h
+++ b/konsole/konsole/konsoleiface.h
@@ -30,12 +30,12 @@ class KonsoleIface : virtual public DCOPObject
virtual int sessionCount() = 0;
- virtual QString currentSession() = 0;
- virtual QString newSession() = 0;
- virtual QString newSession(const QString &type) = 0;
- virtual QString sessionId(const int position) = 0;
+ virtual TQString currentSession() = 0;
+ virtual TQString newSession() = 0;
+ virtual TQString newSession(const TQString &type) = 0;
+ virtual TQString sessionId(const int position) = 0;
- virtual void activateSession(const QString &sessionId) = 0;
+ virtual void activateSession(const TQString &sessionId) = 0;
virtual void nextSession() = 0;
virtual void prevSession() = 0;
diff --git a/konsole/konsole/kwrited.cpp b/konsole/konsole/kwrited.cpp
index 7b0e1167b..4255c1938 100644
--- a/konsole/konsole/kwrited.cpp
+++ b/konsole/konsole/kwrited.cpp
@@ -31,7 +31,7 @@
// Qt
#include <dcopclient.h>
-#include <qsocketnotifier.h>
+#include <tqsocketnotifier.h>
// KDE
#include <kuniqueapplication.h>
@@ -61,7 +61,7 @@
- add client complements.
*/
-KWrited::KWrited() : QTextEdit()
+KWrited::KWrited() : TQTextEdit()
{
int pref_width, pref_height;
@@ -71,17 +71,17 @@ KWrited::KWrited() : QTextEdit()
setMinimumWidth(pref_width);
setMinimumHeight(pref_height);
setReadOnly(true);
- setFocusPolicy(QWidget::NoFocus);
- setWordWrap(QTextEdit::WidgetWidth);
+ setFocusPolicy(TQWidget::NoFocus);
+ setWordWrap(TQTextEdit::WidgetWidth);
setTextFormat(Qt::PlainText);
pty = new KPty();
pty->open();
pty->login(KUser().loginName().local8Bit().data(), getenv("DISPLAY"));
- QSocketNotifier *sn = new QSocketNotifier(pty->masterFd(), QSocketNotifier::Read, this);
- connect(sn, SIGNAL(activated(int)), this, SLOT(block_in(int)));
+ TQSocketNotifier *sn = new TQSocketNotifier(pty->masterFd(), TQSocketNotifier::Read, this);
+ connect(sn, TQT_SIGNAL(activated(int)), this, TQT_SLOT(block_in(int)));
- QString txt = i18n("KWrited - Listening on Device %1").arg(pty->ttyName());
+ TQString txt = i18n("KWrited - Listening on Device %1").arg(pty->ttyName());
setCaption(txt);
kdDebug() << txt << endl;
@@ -100,7 +100,7 @@ void KWrited::block_in(int fd)
if (len <= 0)
return;
- insert( QString::fromLocal8Bit( buf, len ).remove('\r') );
+ insert( TQString::fromLocal8Bit( buf, len ).remove('\r') );
show();
raise();
}
@@ -110,18 +110,18 @@ void KWrited::clearText()
clear();
}
-QPopupMenu *KWrited::createPopupMenu( const QPoint &pos )
+TQPopupMenu *KWrited::createPopupMenu( const TQPoint &pos )
{
- QPopupMenu *menu = QTextEdit::createPopupMenu( pos );
+ TQPopupMenu *menu = TQTextEdit::createPopupMenu( pos );
menu->insertItem( i18n( "Clear Messages" ),
- this, SLOT( clearText() ),
+ this, TQT_SLOT( clearText() ),
0, -1, 0 );
return menu;
}
-KWritedModule::KWritedModule( const QCString& obj )
+KWritedModule::KWritedModule( const TQCString& obj )
: KDEDModule( obj )
{
KGlobal::locale()->insertCatalogue("konsole");
@@ -135,7 +135,7 @@ KWritedModule::~KWritedModule()
}
extern "C"
-KDE_EXPORT KDEDModule* create_kwrited( const QCString& obj )
+KDE_EXPORT KDEDModule* create_kwrited( const TQCString& obj )
{
return new KWritedModule( obj );
}
diff --git a/konsole/konsole/kwrited.h b/konsole/konsole/kwrited.h
index 71da6eff1..04cfca548 100644
--- a/konsole/konsole/kwrited.h
+++ b/konsole/konsole/kwrited.h
@@ -21,10 +21,10 @@
#ifndef KWRITED_H
#define KWRITED_H
-#include <qtextedit.h>
+#include <tqtextedit.h>
#include <kdedmodule.h>
-#include <qpopupmenu.h>
-#include <qtextedit.h>
+#include <tqpopupmenu.h>
+#include <tqtextedit.h>
class KPty;
@@ -34,7 +34,7 @@ public:
KWrited();
~KWrited();
protected:
- virtual QPopupMenu *createPopupMenu(const QPoint &);
+ virtual TQPopupMenu *createPopupMenu(const TQPoint &);
private slots:
void block_in(int fd);
void clearText(void);
@@ -47,7 +47,7 @@ class KWritedModule : public KDEDModule
Q_OBJECT
K_DCOP
public:
- KWritedModule( const QCString& obj );
+ KWritedModule( const TQCString& obj );
~KWritedModule();
private:
KWrited* pro;
diff --git a/konsole/konsole/main.cpp b/konsole/konsole/main.cpp
index 48e9eab2a..7be5e5146 100644
--- a/konsole/konsole/main.cpp
+++ b/konsole/konsole/main.cpp
@@ -26,9 +26,9 @@
#include <stdio.h>
#include <stdlib.h>
-#include <qdir.h>
-#include <qsessionmanager.h>
-#include <qwidgetlist.h>
+#include <tqdir.h>
+#include <tqsessionmanager.h>
+#include <tqwidgetlist.h>
#include <dcopclient.h>
@@ -105,7 +105,7 @@ static bool fixed_size = false;
bool argb_visual = false;
-const char *konsole_shell(QStrList &args)
+const char *konsole_shell(TQStrList &args)
{
const char* shell = getenv("SHELL");
if (shell == NULL || *shell == '\0') shell = "/bin/sh";
@@ -134,7 +134,7 @@ const char *konsole_shell(QStrList &args)
class KonsoleSessionManaged: public KSessionManaged {
public:
bool saveState( QSessionManager&sm) {
- QStringList restartCommand = sm.restartCommand();
+ TQStringList restartCommand = sm.restartCommand();
if (has_noxft)
restartCommand.append("--noxft");
if (login_shell)
@@ -288,7 +288,7 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
}
}
}
- // The QApplication ctor used is normally intended for applications not using Qt
+ // The TQApplication ctor used is normally intended for applications not using Qt
// as the primary toolkit (e.g. Motif apps also using Qt), with some slightly
// unpleasant side effects (e.g. #83974). This code checks if qt-copy patch #0078
// is applied, which allows turning this off.
@@ -308,27 +308,27 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
KApplication* a = new KApplication;
#endif
- QString dataPathBase = KStandardDirs::kde_default("data").append("konsole/");
+ TQString dataPathBase = KStandardDirs::kde_default("data").append("konsole/");
KGlobal::dirs()->addResourceType("wallpaper", dataPathBase + "wallpapers");
KImageIO::registerFormats(); // add io for additional image formats
//2.1 secs
- QString title;
+ TQString title;
if(args->isSet("T")) {
- title = QFile::decodeName(args->getOption("T"));
+ title = TQFile::decodeName(args->getOption("T"));
}
if(qtargs->isSet("title")) {
- title = QFile::decodeName(qtargs->getOption("title"));
+ title = TQFile::decodeName(qtargs->getOption("title"));
}
- QString term = "";
+ TQString term = "";
if(args->isSet("tn")) {
- term=QString::fromLatin1(args->getOption("tn"));
+ term=TQString::fromLatin1(args->getOption("tn"));
}
login_shell = args->isSet("ls");
- QStrList eargs;
+ TQStrList eargs;
const char* shell = 0;
if (!args->getOption("e").isEmpty())
@@ -343,19 +343,19 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
if (title.isEmpty() &&
(kapp->caption() == kapp->aboutData()->programName()))
{
- title = QFile::decodeName(shell); // program executed in the title bar
+ title = TQFile::decodeName(shell); // program executed in the title bar
}
showtip = false;
}
- QCString sz = "";
+ TQCString sz = "";
sz = args->getOption("vt_sz");
histon = args->isSet("hist");
menubaron = args->isSet("menubar");
tabbaron = args->isSet("tabbar") && args->isSet("toolbar");
frameon = args->isSet("frame");
scrollbaron = args->isSet("scrollbar");
- QCString wname = qtargs->getOption("name");
+ TQCString wname = qtargs->getOption("name");
full_script = args->isSet("script");
auto_close = args->isSet("close");
fixed_size = !args->isSet("resize");
@@ -363,22 +363,22 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
if (!full_script)
a->dcopClient()->setQtBridgeEnabled(false);
- QCString type = "";
+ TQCString type = "";
if(args->isSet("type")) {
type = args->getOption("type");
}
if(args->isSet("types")) {
- QStringList types = KGlobal::dirs()->findAllResources("appdata", "*.desktop", false, true);
+ TQStringList types = KGlobal::dirs()->findAllResources("appdata", "*.desktop", false, true);
types.sort();
- for(QStringList::ConstIterator it = types.begin();
+ for(TQStringList::ConstIterator it = types.begin();
it != types.end(); ++it)
{
- QString file = *it;
+ TQString file = *it;
file = file.mid(file.findRev('/')+1);
if (file.endsWith(".desktop"))
file = file.left(file.length()-8);
- printf("%s\n", QFile::encodeName(file).data());
+ printf("%s\n", TQFile::encodeName(file).data());
}
return 0;
}
@@ -388,57 +388,57 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
for(int i = 0; i < (int) colors.count(); i++)
{
ColorSchema *schema = colors.find(i);
- QString relPath = schema->relPath();
+ TQString relPath = schema->relPath();
if (!relPath.isEmpty())
- printf("%s\n", QFile::encodeName(relPath).data());
+ printf("%s\n", TQFile::encodeName(relPath).data());
}
return 0;
}
if(args->isSet("keytabs")) {
- QStringList lst = KGlobal::dirs()->findAllResources("data", "konsole/*.keytab");
+ TQStringList lst = KGlobal::dirs()->findAllResources("data", "konsole/*.keytab");
printf("default\n"); // 'buildin' keytab
lst.sort();
- for(QStringList::Iterator it = lst.begin(); it != lst.end(); ++it )
+ for(TQStringList::Iterator it = lst.begin(); it != lst.end(); ++it )
{
- QFileInfo fi(*it);
- QString file = fi.baseName();
- printf("%s\n", QFile::encodeName(file).data());
+ TQFileInfo fi(*it);
+ TQString file = fi.baseName();
+ printf("%s\n", TQFile::encodeName(file).data());
}
return 0;
}
- QString workDir = QFile::decodeName( args->getOption("workdir") );
+ TQString workDir = TQFile::decodeName( args->getOption("workdir") );
- QString keytab = "";
+ TQString keytab = "";
if (args->isSet("keytab"))
- keytab = QFile::decodeName(args->getOption("keytab"));
+ keytab = TQFile::decodeName(args->getOption("keytab"));
- QString schema = "";
+ TQString schema = "";
if (args->isSet("schema"))
schema = args->getOption("schema");
KConfig * sessionconfig = 0;
- QString profile = "";
+ TQString profile = "";
if (args->isSet("profile")) {
profile = args->getOption("profile");
- QString path = locate( "data", "konsole/profiles/" + profile );
- if ( QFile::exists( path ) )
+ TQString path = locate( "data", "konsole/profiles/" + profile );
+ if ( TQFile::exists( path ) )
sessionconfig=new KConfig( path, true );
else
profile = "";
}
if (args->isSet("profiles"))
{
- QStringList profiles = KGlobal::dirs()->findAllResources("data", "konsole/profiles/*", false, true);
+ TQStringList profiles = KGlobal::dirs()->findAllResources("data", "konsole/profiles/*", false, true);
profiles.sort();
- for(QStringList::ConstIterator it = profiles.begin();
+ for(TQStringList::ConstIterator it = profiles.begin();
it != profiles.end(); ++it)
{
- QString file = *it;
+ TQString file = *it;
file = file.mid(file.findRev('/')+1);
- printf("%s\n", QFile::encodeName(file).data());
+ printf("%s\n", TQFile::encodeName(file).data());
}
return 0;
}
@@ -487,19 +487,19 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
sessionconfig->setDesktopGroup();
int n = 1;
- QString key;
- QString sTitle;
- QString sPgm;
- QString sTerm;
- QString sIcon;
- QString sCwd;
+ TQString key;
+ TQString sTitle;
+ TQString sPgm;
+ TQString sTerm;
+ TQString sIcon;
+ TQString sCwd;
int n_tabbar;
// TODO: Session management stores everything in same group,
// should use one group / mainwindow
while (KMainWindow::canBeRestored(n) || !profile.isEmpty())
{
- sessionconfig->setGroup(QString("%1").arg(n));
+ sessionconfig->setGroup(TQString("%1").arg(n));
if (!sessionconfig->hasKey("Pgm0"))
sessionconfig->setDesktopGroup(); // Backwards compatible
@@ -523,14 +523,14 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
m->enableFullScripting(full_script);
m->enableFixedSize(fixed_size);
m->restore(n);
- sessionconfig->setGroup(QString("%1").arg(n));
+ sessionconfig->setGroup(TQString("%1").arg(n));
if (!sessionconfig->hasKey("Pgm0"))
sessionconfig->setDesktopGroup(); // Backwards compatible
m->makeGUI();
m->setEncoding(sessionconfig->readNumEntry("Encoding0"));
m->setSchema(sessionconfig->readEntry("Schema0"));
// Use konsolerc default as tmpFont instead?
- QFont tmpFont = KGlobalSettings::fixedFont();
+ TQFont tmpFont = KGlobalSettings::fixedFont();
m->initSessionFont(sessionconfig->readFontEntry("SessionFont0", &tmpFont));
m->initSessionKeyTab(sessionconfig->readEntry("KeyTab0"));
m->initMonitorActivity(sessionconfig->readBoolEntry("MonitorActivity0",false));
@@ -548,48 +548,48 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
while (counter < session_count)
{
- key = QString("Title%1").arg(counter);
+ key = TQString("Title%1").arg(counter);
sTitle = sessionconfig->readEntry(key, title);
- key = QString("Args%1").arg(counter);
+ key = TQString("Args%1").arg(counter);
sessionconfig->readListEntry(key, eargs);
- key = QString("Pgm%1").arg(counter);
+ key = TQString("Pgm%1").arg(counter);
// if the -e option is passed on the command line, this overrides the program specified
// in the profile file
if ( args->isSet("e") )
- sPgm = (shell ? QFile::decodeName(shell) : QString::null);
+ sPgm = (shell ? TQFile::decodeName(shell) : TQString::null);
else
sPgm = sessionconfig->readEntry(key, shell);
- key = QString("Term%1").arg(counter);
+ key = TQString("Term%1").arg(counter);
sTerm = sessionconfig->readEntry(key);
- key = QString("Icon%1").arg(counter);
+ key = TQString("Icon%1").arg(counter);
sIcon = sessionconfig->readEntry(key,"konsole");
- key = QString("Cwd%1").arg(counter);
+ key = TQString("Cwd%1").arg(counter);
sCwd = sessionconfig->readPathEntry(key);
m->newSession(sPgm, eargs, sTerm, sIcon, sTitle, sCwd);
m->setSessionTitle(sTitle); // Use title as is
- key = QString("Schema%1").arg(counter);
+ key = TQString("Schema%1").arg(counter);
m->setSchema(sessionconfig->readEntry(key));
- key = QString("Encoding%1").arg(counter);
+ key = TQString("Encoding%1").arg(counter);
m->setEncoding(sessionconfig->readNumEntry(key));
- key = QString("SessionFont%1").arg(counter);
- QFont tmpFont = KGlobalSettings::fixedFont();
+ key = TQString("SessionFont%1").arg(counter);
+ TQFont tmpFont = KGlobalSettings::fixedFont();
m->initSessionFont(sessionconfig->readFontEntry(key, &tmpFont));
- key = QString("KeyTab%1").arg(counter);
+ key = TQString("KeyTab%1").arg(counter);
m->initSessionKeyTab(sessionconfig->readEntry(key));
- key = QString("MonitorActivity%1").arg(counter);
+ key = TQString("MonitorActivity%1").arg(counter);
m->initMonitorActivity(sessionconfig->readBoolEntry(key,false));
- key = QString("MonitorSilence%1").arg(counter);
+ key = TQString("MonitorSilence%1").arg(counter);
m->initMonitorSilence(sessionconfig->readBoolEntry(key,false));
- key = QString("MasterMode%1").arg(counter);
+ key = TQString("MasterMode%1").arg(counter);
m->initMasterMode(sessionconfig->readBoolEntry(key,false));
- key = QString("TabColor%1").arg(counter);
+ key = TQString("TabColor%1").arg(counter);
m->initTabColor(sessionconfig->readColorEntry(key));
// -1 will be changed to the default history in konsolerc
- key = QString("History%1").arg(counter);
- QString key2 = QString("HistoryEnabled%1").arg(counter);
+ key = TQString("History%1").arg(counter);
+ TQString key2 = TQString("HistoryEnabled%1").arg(counter);
m->initHistory(sessionconfig->readNumEntry(key, -1),
sessionconfig->readBoolEntry(key2, true));
counter++;
@@ -614,7 +614,7 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
else
{
Konsole* m = new Konsole(wname,histon,menubaron,tabbaron,frameon,scrollbaron,type, false, 0, workDir);
- m->newSession((shell ? QFile::decodeName(shell) : QString::null), eargs, term, QString::null, title, workDir);
+ m->newSession((shell ? TQFile::decodeName(shell) : TQString::null), eargs, term, TQString::null, title, workDir);
m->enableFullScripting(full_script);
m->enableFixedSize(fixed_size);
//3.8 :-(
@@ -644,7 +644,7 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
//// Temporary code, waiting for Qt to do this properly
// Delete all toplevel widgets that have WDestructiveClose
- QWidgetList *list = QApplication::topLevelWidgets();
+ TQWidgetList *list = TQApplication::topLevelWidgets();
// remove all toplevel widgets that have a parent (i.e. they
// got WTopLevel explicitly), they'll be deleted by the parent
list->first();
@@ -657,8 +657,8 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
}
list->next();
}
- QWidgetListIt it(*list);
- QWidget * w;
+ TQWidgetListIt it(*list);
+ TQWidget * w;
while( (w=it.current()) != 0 ) {
++it;
delete w;
diff --git a/konsole/konsole/printsettings.cpp b/konsole/konsole/printsettings.cpp
index 22997ba28..f27194c14 100644
--- a/konsole/konsole/printsettings.cpp
+++ b/konsole/konsole/printsettings.cpp
@@ -21,24 +21,24 @@
#include "printsettings.h"
#include <klocale.h>
-#include <qcheckbox.h>
-#include <qlayout.h>
+#include <tqcheckbox.h>
+#include <tqlayout.h>
-PrintSettings::PrintSettings(QWidget *parent, const char *name)
+PrintSettings::PrintSettings(TQWidget *parent, const char *name)
: KPrintDialogPage(parent, name)
{
setTitle(i18n("Options"));
- m_printfriendly = new QCheckBox(i18n("Printer &friendly mode (black text, no background)"), this);
+ m_printfriendly = new TQCheckBox(i18n("Printer &friendly mode (black text, no background)"), this);
m_printfriendly->setChecked(true);
- m_printexact = new QCheckBox(i18n("&Pixel for pixel"), this);
+ m_printexact = new TQCheckBox(i18n("&Pixel for pixel"), this);
m_printexact->setChecked(false);
- m_printheader = new QCheckBox(i18n("Print &header"), this);
+ m_printheader = new TQCheckBox(i18n("Print &header"), this);
m_printheader->setChecked(true);
m_printheader->hide(); // Not yet implemented.
- QVBoxLayout *l0 = new QVBoxLayout(this, 0, 10);
+ QVBoxLayout *l0 = new TQVBoxLayout(this, 0, 10);
l0->addWidget(m_printfriendly);
l0->addWidget(m_printexact);
l0->addWidget(m_printheader);
@@ -49,14 +49,14 @@ PrintSettings::~PrintSettings()
{
}
-void PrintSettings::getOptions(QMap<QString,QString>& opts, bool /*incldef*/)
+void PrintSettings::getOptions(TQMap<TQString,TQString>& opts, bool /*incldef*/)
{
opts["app-konsole-printfriendly"] = (m_printfriendly->isChecked() ? "true" : "false");
opts["app-konsole-printexact"] = (m_printexact->isChecked() ? "true" : "false");
opts["app-konsole-printheader"] = (m_printheader->isChecked() ? "true" : "false");
}
-void PrintSettings::setOptions(const QMap<QString,QString>& opts)
+void PrintSettings::setOptions(const TQMap<TQString,TQString>& opts)
{
m_printfriendly->setChecked(opts["app-konsole-printfriendly"] != "false");
m_printexact->setChecked(opts["app-konsole-printexact"] == "true");
diff --git a/konsole/konsole/printsettings.h b/konsole/konsole/printsettings.h
index 5d2f4389e..d4c12a770 100644
--- a/konsole/konsole/printsettings.h
+++ b/konsole/konsole/printsettings.h
@@ -29,11 +29,11 @@ class PrintSettings : public KPrintDialogPage
{
Q_OBJECT
public:
- PrintSettings(QWidget *parent = 0, const char *name = 0);
+ PrintSettings(TQWidget *parent = 0, const char *name = 0);
~PrintSettings();
- void getOptions(QMap<QString,QString>& opts, bool incldef = false);
- void setOptions(const QMap<QString,QString>& opts);
+ void getOptions(TQMap<TQString,TQString>& opts, bool incldef = false);
+ void setOptions(const TQMap<TQString,TQString>& opts);
private:
QCheckBox *m_printfriendly;
diff --git a/konsole/konsole/schema.cpp b/konsole/konsole/schema.cpp
index 0002e198b..8d85329eb 100644
--- a/konsole/konsole/schema.cpp
+++ b/konsole/konsole/schema.cpp
@@ -53,15 +53,15 @@
#include "schema.h"
#include "kapplication.h"
-#include <qdir.h>
-#include <qdatetime.h>
+#include <tqdir.h>
+#include <tqdatetime.h>
#include <kstandarddirs.h>
#include <klocale.h>
#include <kconfig.h>
#include <kdebug.h>
-typedef QPtrListIterator<ColorSchema> ColorSchemaListIterator;
+typedef TQPtrListIterator<ColorSchema> ColorSchemaListIterator;
// Number all the new color schema's (non-default) from 1.
@@ -103,39 +103,39 @@ static const ColorEntry default_table[TABLE_COLORS] =
// gamma correction for the dim colors to compensate for bright X screens.
// It contains the 8 ansiterm/xterm colors in 2 intensities.
{
- ColorEntry( QColor(0x00,0x00,0x00), 0, 0 ), ColorEntry(
-QColor(0xFF,0xFF,0xFF), 1, 0 ), // Dfore, Dback
- ColorEntry( QColor(0x00,0x00,0x00), 0, 0 ), ColorEntry(
-QColor(0xB2,0x18,0x18), 0, 0 ), // Black, Red
- ColorEntry( QColor(0x18,0xB2,0x18), 0, 0 ), ColorEntry(
-QColor(0xB2,0x68,0x18), 0, 0 ), // Green, Yellow
- ColorEntry( QColor(0x18,0x18,0xB2), 0, 0 ), ColorEntry(
-QColor(0xB2,0x18,0xB2), 0, 0 ), // Blue, Magenta
- ColorEntry( QColor(0x18,0xB2,0xB2), 0, 0 ), ColorEntry(
-QColor(0xB2,0xB2,0xB2), 0, 0 ), // Cyan, White
+ ColorEntry( TQColor(0x00,0x00,0x00), 0, 0 ), ColorEntry(
+TQColor(0xFF,0xFF,0xFF), 1, 0 ), // Dfore, Dback
+ ColorEntry( TQColor(0x00,0x00,0x00), 0, 0 ), ColorEntry(
+TQColor(0xB2,0x18,0x18), 0, 0 ), // Black, Red
+ ColorEntry( TQColor(0x18,0xB2,0x18), 0, 0 ), ColorEntry(
+TQColor(0xB2,0x68,0x18), 0, 0 ), // Green, Yellow
+ ColorEntry( TQColor(0x18,0x18,0xB2), 0, 0 ), ColorEntry(
+TQColor(0xB2,0x18,0xB2), 0, 0 ), // Blue, Magenta
+ ColorEntry( TQColor(0x18,0xB2,0xB2), 0, 0 ), ColorEntry(
+TQColor(0xB2,0xB2,0xB2), 0, 0 ), // Cyan, White
// intensive
- ColorEntry( QColor(0x00,0x00,0x00), 0, 1 ), ColorEntry(
-QColor(0xFF,0xFF,0xFF), 1, 0 ),
- ColorEntry( QColor(0x68,0x68,0x68), 0, 0 ), ColorEntry(
-QColor(0xFF,0x54,0x54), 0, 0 ),
- ColorEntry( QColor(0x54,0xFF,0x54), 0, 0 ), ColorEntry(
-QColor(0xFF,0xFF,0x54), 0, 0 ),
- ColorEntry( QColor(0x54,0x54,0xFF), 0, 0 ), ColorEntry(
-QColor(0xFF,0x54,0xFF), 0, 0 ),
- ColorEntry( QColor(0x54,0xFF,0xFF), 0, 0 ), ColorEntry(
-QColor(0xFF,0xFF,0xFF), 0, 0 )
+ ColorEntry( TQColor(0x00,0x00,0x00), 0, 1 ), ColorEntry(
+TQColor(0xFF,0xFF,0xFF), 1, 0 ),
+ ColorEntry( TQColor(0x68,0x68,0x68), 0, 0 ), ColorEntry(
+TQColor(0xFF,0x54,0x54), 0, 0 ),
+ ColorEntry( TQColor(0x54,0xFF,0x54), 0, 0 ), ColorEntry(
+TQColor(0xFF,0xFF,0x54), 0, 0 ),
+ ColorEntry( TQColor(0x54,0x54,0xFF), 0, 0 ), ColorEntry(
+TQColor(0xFF,0x54,0xFF), 0, 0 ),
+ ColorEntry( TQColor(0x54,0xFF,0xFF), 0, 0 ), ColorEntry(
+TQColor(0xFF,0xFF,0xFF), 0, 0 )
};
-ColorSchema::ColorSchema(const QString& pathname)
+ColorSchema::ColorSchema(const TQString& pathname)
:m_fileRead(false)
-,lastRead(new QDateTime())
+,lastRead(new TQDateTime())
{
//start with a valid time, aleXXX
- *lastRead = QDateTime::currentDateTime();
- QString fPath = pathname.startsWith("/") ? pathname : locate("data", "konsole/"+pathname);
- if (fPath.isEmpty() || !QFile::exists(fPath))
+ *lastRead = TQDateTime::currentDateTime();
+ TQString fPath = pathname.startsWith("/") ? pathname : locate("data", "konsole/"+pathname);
+ if (fPath.isEmpty() || !TQFile::exists(fPath))
{
- fRelPath = QString::null;
+ fRelPath = TQString::null;
setDefaultSchema();
}
else
@@ -151,7 +151,7 @@ ColorSchema::ColorSchema(const QString& pathname)
ColorSchema::ColorSchema()
:m_fileRead(false)
-,fRelPath(QString::null)
+,fRelPath(TQString::null)
,lastRead(0L)
{
setDefaultSchema();
@@ -160,7 +160,7 @@ ColorSchema::ColorSchema()
ColorSchema::ColorSchema(KConfig& c)
:m_fileRead(false)
-,fRelPath(QString::null)
+,fRelPath(TQString::null)
,lastRead(0L)
{
clearSchema();
@@ -197,7 +197,7 @@ void ColorSchema::clearSchema()
for (i = 0; i < TABLE_COLORS; i++)
{
- m_table[i].color = QColor(0,0,0);
+ m_table[i].color = TQColor(0,0,0);
m_table[i].transparent = 0;
m_table[i].bold = 0;
}
@@ -226,7 +226,7 @@ void ColorSchema::setDefaultSchema()
}
}
-/* static */ QString ColorSchema::colorName(int i)
+/* static */ TQString ColorSchema::colorName(int i)
{
if ((i<0) || (i>=TABLE_COLORS))
{
@@ -234,14 +234,14 @@ void ColorSchema::setDefaultSchema()
<< i
<< " out of range."
<< endl;
- return QString::null;
+ return TQString::null;
}
- return QString(colornames[i]);
+ return TQString(colornames[i]);
}
void ColorSchema::writeConfigColor(KConfig& c,
- const QString& name,
+ const TQString& name,
const ColorEntry& e) const
{
KConfigGroupSaver(&c,name);
@@ -252,7 +252,7 @@ void ColorSchema::writeConfigColor(KConfig& c,
}
void ColorSchema::readConfigColor(KConfig& c,
- const QString& name,
+ const TQString& name,
ColorEntry& e)
{
KConfigGroupSaver(&c,name);
@@ -264,7 +264,7 @@ void ColorSchema::readConfigColor(KConfig& c,
}
-void ColorSchema::writeConfig(const QString& path) const
+void ColorSchema::writeConfig(const TQString& path) const
{
// KONSOLEDEBUG << "Writing schema " << relPath << " to file " << path << endl;
@@ -291,13 +291,13 @@ static int random_hue = -1;
bool ColorSchema::rereadSchemaFile()
{
- QString fPath = fRelPath.isEmpty() ? "" : (fRelPath.startsWith("/") ? fRelPath : locate("data", "konsole/"+fRelPath));
- if (fPath.isEmpty() || !QFile::exists(fPath))
+ TQString fPath = fRelPath.isEmpty() ? "" : (fRelPath.startsWith("/") ? fRelPath : locate("data", "konsole/"+fRelPath));
+ if (fPath.isEmpty() || !TQFile::exists(fPath))
return false;
//KONSOLEDEBUG << "Rereading schema file " << fPath << endl;
- FILE *sysin = fopen(QFile::encodeName(fPath),"r");
+ FILE *sysin = fopen(TQFile::encodeName(fPath),"r");
if (!sysin)
{
int e = errno;
@@ -313,7 +313,7 @@ bool ColorSchema::rereadSchemaFile()
char line[100];
- *lastRead = QDateTime::currentDateTime();
+ *lastRead = TQDateTime::currentDateTime();
while (fscanf(sysin,"%80[^\n]\n",line) > 0)
{
@@ -332,7 +332,7 @@ bool ColorSchema::rereadSchemaFile()
if (!strcmp(rend,"full" )) attr = 4; else
continue;
- QString qline(line);
+ TQString qline(line);
m_imagePath = locate("wallpaper", qline.mid( qline.find(" ",7)+1 ) );
m_alignment = attr;
}
@@ -362,7 +362,7 @@ bool ColorSchema::rereadSchemaFile()
if (!(0 <= cv && cv <= 255 )) continue;
if (!(0 <= tr && tr <= 1 )) continue;
if (!(0 <= bo && bo <= 1 )) continue;
- m_table[fi].color = QColor();
+ m_table[fi].color = TQColor();
m_table[fi].color.setHsv(ch,cs,cv);
m_table[fi].transparent = tr;
m_table[fi].bold = bo;
@@ -377,7 +377,7 @@ bool ColorSchema::rereadSchemaFile()
if (!(0 <= cb && cb <= 255 )) continue;
if (!(0 <= tr && tr <= 1 )) continue;
if (!(0 <= bo && bo <= 1 )) continue;
- m_table[fi].color = QColor(cr,cg,cb);
+ m_table[fi].color = TQColor(cr,cg,cb);
m_table[fi].transparent = tr;
m_table[fi].bold = bo;
}
@@ -412,7 +412,7 @@ bool ColorSchema::rereadSchemaFile()
bool ColorSchema::hasSchemaFileChanged() const
{
- QString fPath = fRelPath.isEmpty() ? "" : locate("data", "konsole/"+fRelPath);
+ TQString fPath = fRelPath.isEmpty() ? "" : locate("data", "konsole/"+fRelPath);
//KONSOLEDEBUG << "Checking schema file " << fPath << endl;
@@ -421,11 +421,11 @@ bool ColorSchema::hasSchemaFileChanged() const
//
if (fPath.isEmpty()) return false;
- QFileInfo i(fPath);
+ TQFileInfo i(fPath);
if (i.exists())
{
- QDateTime written = i.lastModified();
+ TQDateTime written = i.lastModified();
if (written != (*lastRead))
{
@@ -446,7 +446,7 @@ bool ColorSchema::hasSchemaFileChanged() const
}
}
-void ColorSchema::updateLastRead(const QDateTime& dt)
+void ColorSchema::updateLastRead(const TQDateTime& dt)
{
if (lastRead)
{
@@ -456,7 +456,7 @@ void ColorSchema::updateLastRead(const QDateTime& dt)
ColorSchemaList::ColorSchemaList() :
- QPtrList<ColorSchema> ()
+ TQPtrList<ColorSchema> ()
{
// KONSOLEDEBUG << "Got new color list" << endl;
@@ -473,7 +473,7 @@ ColorSchemaList::~ColorSchemaList()
}
-ColorSchema *ColorSchemaList::find(const QString& path)
+ColorSchema *ColorSchemaList::find(const TQString& path)
{
if (path.isEmpty())
return find(0);
@@ -525,18 +525,18 @@ ColorSchema *ColorSchemaList::find(int i)
return 0;
}
-bool ColorSchemaList::updateAllSchemaTimes(const QDateTime& now)
+bool ColorSchemaList::updateAllSchemaTimes(const TQDateTime& now)
{
// KONSOLEDEBUG << "Updating time stamps" << endl;
- QStringList list;
+ TQStringList list;
KGlobal::dirs()->findAllResources("data", "konsole/*.schema", false, true, list);
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
bool r = false;
for (it=list.begin(); it!=list.end(); ++it)
{
- QString filename=*it;
+ TQString filename=*it;
int j=filename.findRev('/');
if (j>-1)
filename = filename.mid(8);
@@ -571,7 +571,7 @@ bool ColorSchemaList::updateAllSchemaTimes(const QDateTime& now)
return r;
}
-bool ColorSchemaList::deleteOldSchemas(const QDateTime& now)
+bool ColorSchemaList::deleteOldSchemas(const TQDateTime& now)
{
// KONSOLEDEBUG << "Checking for vanished schemas" << endl;
@@ -615,7 +615,7 @@ bool ColorSchemaList::checkSchemas()
// now.
//
//
- QDateTime now = QDateTime::currentDateTime();
+ TQDateTime now = TQDateTime::currentDateTime();
r = updateAllSchemaTimes(now);
@@ -624,11 +624,11 @@ bool ColorSchemaList::checkSchemas()
return r;
}
-int ColorSchemaList::compareItems(QPtrCollection::Item item1, QPtrCollection::Item item2)
+int ColorSchemaList::compareItems(TQPtrCollection::Item item1, TQPtrCollection::Item item2)
{
ColorSchema* schema1=(ColorSchema*)item1;
ColorSchema* schema2=(ColorSchema*)item2;
- return -1*QString::compare(schema1->title(),schema2->title());
+ return -1*TQString::compare(schema1->title(),schema2->title());
}
diff --git a/konsole/konsole/schema.h b/konsole/konsole/schema.h
index 3ba718350..fc222ebe5 100644
--- a/konsole/konsole/schema.h
+++ b/konsole/konsole/schema.h
@@ -41,8 +41,8 @@
#ifndef SCHEMA_include
#define SCHEMA_include
-#include <qstring.h>
-#include <qptrlist.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
#include "TECommon.h"
@@ -68,7 +68,7 @@ public:
* If the given pathname does not exist, a ColorSchema
* with the same settings as the default schema is returned.
*/
- ColorSchema(const QString& pathname);
+ ColorSchema(const TQString& pathname);
~ColorSchema();
/**
* Construct a color schema from the given config file.
@@ -83,7 +83,7 @@ public:
*/
ColorSchema();
- QString relPath() const { return fRelPath; } ;
+ TQString relPath() const { return fRelPath; } ;
/**
* Check if the schema file whose pathname was given
@@ -101,21 +101,21 @@ public:
* Writes a ColorSchema to a config file with the
* given name.
*/
- void writeConfig(const QString& filename) const;
+ void writeConfig(const TQString& filename) const;
/**
* Returns the (non-i18n) name of the i'th color,
- * or QString::null if i is not a color name. This
+ * or TQString::null if i is not a color name. This
* should be used as a group name to store the
* information about the i'th color.
*/
- static QString colorName(int i);
+ static TQString colorName(int i);
/**
* Update the timestamp in the color schema indicating
* when the schema's file whas last checked and read.
*/
- void updateLastRead(const QDateTime& dt);
+ void updateLastRead(const TQDateTime& dt);
protected:
@@ -137,19 +137,19 @@ protected:
* under the given name (ie. in the group name).
*/
void writeConfigColor(KConfig& c,
- const QString& name,
+ const TQString& name,
const ColorEntry& e) const;
/**
* Read a single ColorEntry from the config file.
*/
void readConfigColor(KConfig& c,
- const QString& name,
+ const TQString& name,
ColorEntry& e) ;
public:
int numb() {if (!m_fileRead) rereadSchemaFile();return m_numb;};
- const QString& title() {if (!m_fileRead) rereadSchemaFile();return m_title;};
- const QString& imagePath() {if (!m_fileRead) rereadSchemaFile();return m_imagePath;};
+ const TQString& title() {if (!m_fileRead) rereadSchemaFile();return m_title;};
+ const TQString& imagePath() {if (!m_fileRead) rereadSchemaFile();return m_imagePath;};
int alignment() {if (!m_fileRead) rereadSchemaFile();return m_alignment;};
const ColorEntry* table() {if (!m_fileRead) rereadSchemaFile();return m_table;};
bool useTransparency() {if (!m_fileRead) rereadSchemaFile();return m_useTransparency;};
@@ -157,38 +157,38 @@ protected:
int tr_r() {if (!m_fileRead) rereadSchemaFile();return m_tr_r;};
int tr_g() {if (!m_fileRead) rereadSchemaFile();return m_tr_g;};
int tr_b() {if (!m_fileRead) rereadSchemaFile();return m_tr_b;};
- QDateTime* getLastRead() {return lastRead;}; // Time last checked for updates
+ TQDateTime* getLastRead() {return lastRead;}; // Time last checked for updates
private:
int m_numb;
int m_tr_r, m_tr_g, m_tr_b;
int m_alignment;
- QString m_title;
- QString m_imagePath;
+ TQString m_title;
+ TQString m_imagePath;
ColorEntry m_table[TABLE_COLORS];
bool m_useTransparency:1;
bool m_fileRead:1;
double m_tr_x;
- QString fRelPath; // File name of schema file
+ TQString fRelPath; // File name of schema file
QDateTime *lastRead; // Time last checked for updates
static int serial; // Serial number so that every
// ColorSchema has a unique number.
};
-class ColorSchemaList : protected QPtrList<ColorSchema>
+class ColorSchemaList : protected TQPtrList<ColorSchema>
{
public:
/**
* The following functions are redeclared public since
* they're needed, but we still want to inherit protected
- * from QPtrList to prevent unsightly -- and perhaps dangerous --
+ * from TQPtrList to prevent unsightly -- and perhaps dangerous --
* tampering with the ColorSchemaList.
*/
- uint count() const { return QPtrList<ColorSchema>::count(); } ;
+ uint count() const { return TQPtrList<ColorSchema>::count(); } ;
const ColorSchema *at(unsigned int i)
- { return QPtrList<ColorSchema>::at(i); } ;
+ { return TQPtrList<ColorSchema>::at(i); } ;
- void sort() {QPtrList<ColorSchema>::sort();};
+ void sort() {TQPtrList<ColorSchema>::sort();};
ColorSchemaList();
virtual ~ColorSchemaList();
@@ -206,20 +206,20 @@ public:
* Returns the color schema read from the given path,
* or NULL if no color schema with the given path is found.
*/
- ColorSchema *find(const QString & path);
+ ColorSchema *find(const TQString & path);
/**
* Returns the serial number of the color schema
* with the given serial number, or NULL if there is none.
*/
ColorSchema *find(int);
- ColorSchema *findAny(const QString& path)
+ ColorSchema *findAny(const TQString& path)
{
ColorSchema *p = find(path);
if (p) return p;
return defaultSchema;
} ;
protected:
- virtual int compareItems(QPtrCollection::Item item1, QPtrCollection::Item item2);
+ virtual int compareItems(TQPtrCollection::Item item1, TQPtrCollection::Item item2);
private:
/**
@@ -229,8 +229,8 @@ private:
* can still be found, and deleteOldSchema's does the
* actual removal of schema's without a config file.
*/
- bool updateAllSchemaTimes(const QDateTime&);
- bool deleteOldSchemas(const QDateTime&);
+ bool updateAllSchemaTimes(const TQDateTime&);
+ bool deleteOldSchemas(const TQDateTime&);
/**
* This isn't really used, but it could be. A newly
diff --git a/konsole/konsole/session.cpp b/konsole/konsole/session.cpp
index 2310255a8..53990af2f 100644
--- a/konsole/konsole/session.cpp
+++ b/konsole/konsole/session.cpp
@@ -32,10 +32,10 @@
#include <kstandarddirs.h>
#include <stdlib.h>
-#include <qfile.h>
-#include <qdir.h>
-#include <qregexp.h>
-#include <qtextedit.h>
+#include <tqfile.h>
+#include <tqdir.h>
+#include <tqregexp.h>
+#include <tqtextedit.h>
/*! \class TESession
@@ -47,7 +47,7 @@
of the abilities of the framework - multible sessions.
*/
-TESession::TESession(TEWidget* _te, const QString &_term, ulong _winId, const QString &_sessionId, const QString &_initial_cwd)
+TESession::TESession(TEWidget* _te, const TQString &_term, ulong _winId, const TQString &_sessionId, const TQString &_initial_cwd)
: DCOPObject( _sessionId.latin1() )
, sh(0)
, connected(true)
@@ -62,8 +62,8 @@ TESession::TESession(TEWidget* _te, const QString &_term, ulong _winId, const QS
, silence_seconds(10)
, add_to_utmp(true)
, xon_xoff(false)
- , pgm(QString())
- , args(QStrList())
+ , pgm(TQString())
+ , args(TQStrList())
, sessionId(_sessionId)
, cwd("")
, initial_cwd(_initial_cwd)
@@ -78,10 +78,10 @@ TESession::TESession(TEWidget* _te, const QString &_term, ulong _winId, const QS
em = new TEmuVt102(te);
font_h = te-> fontHeight();
font_w = te-> fontWidth();
- QObject::connect(te,SIGNAL(changedContentSizeSignal(int,int)),
- this,SLOT(onContentSizeChange(int,int)));
- QObject::connect(te,SIGNAL(changedFontMetricSignal(int,int)),
- this,SLOT(onFontMetricChange(int,int)));
+ TQObject::connect(te,TQT_SIGNAL(changedContentSizeSignal(int,int)),
+ this,TQT_SLOT(onContentSizeChange(int,int)));
+ TQObject::connect(te,TQT_SIGNAL(changedFontMetricSignal(int,int)),
+ this,TQT_SLOT(onFontMetricChange(int,int)));
term = _term;
winId = _winId;
@@ -89,17 +89,17 @@ TESession::TESession(TEWidget* _te, const QString &_term, ulong _winId, const QS
setPty( new TEPty() );
- connect( em, SIGNAL( changeTitle( int, const QString & ) ),
- this, SLOT( setUserTitle( int, const QString & ) ) );
- connect( em, SIGNAL( notifySessionState(int) ),
- this, SLOT( notifySessionState(int) ) );
- monitorTimer = new QTimer(this);
- connect(monitorTimer, SIGNAL(timeout()), this, SLOT(monitorTimerDone()));
+ connect( em, TQT_SIGNAL( changeTitle( int, const TQString & ) ),
+ this, TQT_SLOT( setUserTitle( int, const TQString & ) ) );
+ connect( em, TQT_SIGNAL( notifySessionState(int) ),
+ this, TQT_SLOT( notifySessionState(int) ) );
+ monitorTimer = new TQTimer(this);
+ connect(monitorTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(monitorTimerDone()));
- connect( em, SIGNAL( zmodemDetected() ), this, SLOT(slotZModemDetected()));
+ connect( em, TQT_SIGNAL( zmodemDetected() ), this, TQT_SLOT(slotZModemDetected()));
- connect( em, SIGNAL( changeTabTextColor( int ) ),
- this, SLOT( changeTabTextColor( int ) ) );
+ connect( em, TQT_SIGNAL( changeTabTextColor( int ) ),
+ this, TQT_SLOT( changeTabTextColor( int ) ) );
//kdDebug(1211)<<"TESession ctor() done"<<endl;
}
@@ -110,23 +110,23 @@ void TESession::setPty(TEPty *_sh)
delete sh;
}
sh = _sh;
- connect( sh, SIGNAL( forkedChild() ),
- this, SIGNAL( forkedChild() ));
+ connect( sh, TQT_SIGNAL( forkedChild() ),
+ this, TQT_SIGNAL( forkedChild() ));
//kdDebug(1211)<<"TESession ctor() sh->setSize()"<<endl;
sh->setSize(te->Lines(),te->Columns()); // not absolutely nessesary
sh->useUtf8(em->utf8());
//kdDebug(1211)<<"TESession ctor() connecting"<<endl;
- connect( sh,SIGNAL(block_in(const char*,int)),this,SLOT(onRcvBlock(const char*,int)) );
+ connect( sh,TQT_SIGNAL(block_in(const char*,int)),this,TQT_SLOT(onRcvBlock(const char*,int)) );
- connect( em,SIGNAL(sndBlock(const char*,int)),sh,SLOT(send_bytes(const char*,int)) );
- connect( em,SIGNAL(lockPty(bool)),sh,SLOT(lockPty(bool)) );
- connect( em,SIGNAL(useUtf8(bool)),sh,SLOT(useUtf8(bool)) );
+ connect( em,TQT_SIGNAL(sndBlock(const char*,int)),sh,TQT_SLOT(send_bytes(const char*,int)) );
+ connect( em,TQT_SIGNAL(lockPty(bool)),sh,TQT_SLOT(lockPty(bool)) );
+ connect( em,TQT_SIGNAL(useUtf8(bool)),sh,TQT_SLOT(useUtf8(bool)) );
- connect( sh,SIGNAL(done(int)), this,SLOT(done(int)) );
+ connect( sh,TQT_SIGNAL(done(int)), this,TQT_SLOT(done(int)) );
if (!sh->error().isEmpty())
- QTimer::singleShot(0, this, SLOT(ptyError()));
+ TQTimer::singleShot(0, this, TQT_SLOT(ptyError()));
}
void TESession::ptyError()
@@ -143,10 +143,10 @@ void TESession::ptyError()
void TESession::changeWidget(TEWidget* w)
{
- QObject::disconnect(te,SIGNAL(changedContentSizeSignal(int,int)),
- this,SLOT(onContentSizeChange(int,int)));
- QObject::disconnect(te,SIGNAL(changedFontMetricSignal(int,int)),
- this,SLOT(onFontMetricChange(int,int)));
+ TQObject::disconnect(te,TQT_SIGNAL(changedContentSizeSignal(int,int)),
+ this,TQT_SLOT(onContentSizeChange(int,int)));
+ TQObject::disconnect(te,TQT_SIGNAL(changedFontMetricSignal(int,int)),
+ this,TQT_SLOT(onFontMetricChange(int,int)));
te=w;
em->changeGUI(w);
font_h = te->fontHeight();
@@ -155,13 +155,13 @@ void TESession::changeWidget(TEWidget* w)
te->setDefaultBackColor(modifiedBackground);
- QObject::connect(te,SIGNAL(changedContentSizeSignal(int,int)),
- this,SLOT(onContentSizeChange(int,int)));
- QObject::connect(te,SIGNAL(changedFontMetricSignal(int,int)),
- this,SLOT(onFontMetricChange(int,int)));
+ TQObject::connect(te,TQT_SIGNAL(changedContentSizeSignal(int,int)),
+ this,TQT_SLOT(onContentSizeChange(int,int)));
+ TQObject::connect(te,TQT_SIGNAL(changedFontMetricSignal(int,int)),
+ this,TQT_SLOT(onFontMetricChange(int,int)));
}
-void TESession::setProgram( const QString &_pgm, const QStrList &_args )
+void TESession::setProgram( const TQString &_pgm, const TQStrList &_args )
{
pgm = _pgm;
args = _args;
@@ -171,35 +171,35 @@ void TESession::run()
{
// Upon a KPty error, there is no description on what that error was...
// Check to see if the given program is executable.
- QString exec = QFile::encodeName(pgm);
+ TQString exec = TQFile::encodeName(pgm);
exec = KRun::binaryName(exec, false);
exec = KShell::tildeExpand(exec);
- QString pexec = KGlobal::dirs()->findExe(exec);
+ TQString pexec = KGlobal::dirs()->findExe(exec);
if ( pexec.isEmpty() ) {
kdError()<<"can not execute "<<exec<<endl;
- QTimer::singleShot(1, this, SLOT(done()));
+ TQTimer::singleShot(1, this, TQT_SLOT(done()));
return;
}
- QString appId=kapp->dcopClient()->appId();
+ TQString appId=kapp->dcopClient()->appId();
- QString cwd_save = QDir::currentDirPath();
+ TQString cwd_save = TQDir::currentDirPath();
if (!initial_cwd.isEmpty())
- QDir::setCurrent(initial_cwd);
+ TQDir::setCurrent(initial_cwd);
sh->setXonXoff(xon_xoff);
- int result = sh->run(QFile::encodeName(pgm), args, term.latin1(),
+ int result = sh->run(TQFile::encodeName(pgm), args, term.latin1(),
winId, add_to_utmp,
("DCOPRef("+appId+",konsole)").latin1(),
("DCOPRef("+appId+","+sessionId+")").latin1());
if (result < 0) { // Error in opening pseudo teletype
kdWarning()<<"Unable to open a pseudo teletype!"<<endl;
- QTimer::singleShot(0, this, SLOT(ptyError()));
+ TQTimer::singleShot(0, this, TQT_SLOT(ptyError()));
}
sh->setErase(em->getErase());
if (!initial_cwd.isEmpty())
- QDir::setCurrent(cwd_save);
+ TQDir::setCurrent(cwd_save);
else
initial_cwd=cwd_save;
@@ -211,7 +211,7 @@ void TESession::changeTabTextColor( int color )
emit changeTabTextColor( this, color );
}
-void TESession::setUserTitle( int what, const QString &caption )
+void TESession::setUserTitle( int what, const TQString &caption )
{
// (btw: what=0 changes title and icon, what=1 only icon, what=2 only title
if ((what == 0) || (what == 2))
@@ -219,8 +219,8 @@ void TESession::setUserTitle( int what, const QString &caption )
if ((what == 0) || (what == 1))
iconText = caption;
if (what == 11) {
- QString colorString = caption.section(';',0,0);
- QColor backColor = QColor(colorString);
+ TQString colorString = caption.section(';',0,0);
+ TQColor backColor = TQColor(colorString);
if (backColor.isValid()){// change color via \033]11;Color\007
if (backColor != modifiedBackground) {
modifiedBackground = backColor;
@@ -232,7 +232,7 @@ void TESession::setUserTitle( int what, const QString &caption )
renameSession(caption);
if (what == 31) {
cwd=caption;
- cwd=cwd.replace( QRegExp("^~"), QDir::homeDirPath() );
+ cwd=cwd.replace( TQRegExp("^~"), TQDir::homeDirPath() );
emit openURLRequest(cwd);
}
if (what == 32) { // change icon via \033]32;Icon\007
@@ -243,9 +243,9 @@ void TESession::setUserTitle( int what, const QString &caption )
emit updateTitle(this);
}
-QString TESession::fullTitle() const
+TQString TESession::fullTitle() const
{
- QString res = title;
+ TQString res = title;
if ( !userTitle.isEmpty() )
res = userTitle + " - " + res;
return res;
@@ -311,12 +311,12 @@ bool TESession::closeSession()
if (!sh->isRunning() || !sendSignal(SIGHUP))
{
// Forced close.
- QTimer::singleShot(1, this, SLOT(done()));
+ TQTimer::singleShot(1, this, TQT_SLOT(done()));
}
return true;
}
-void TESession::feedSession(const QString &text)
+void TESession::feedSession(const TQString &text)
{
emit disableMasterModeConnections();
setListenToKeyPress(true);
@@ -325,14 +325,14 @@ void TESession::feedSession(const QString &text)
emit enableMasterModeConnections();
}
-void TESession::sendSession(const QString &text)
+void TESession::sendSession(const TQString &text)
{
- QString newtext=text;
+ TQString newtext=text;
newtext.append("\r");
feedSession(newtext);
}
-void TESession::renameSession(const QString &name)
+void TESession::renameSession(const TQString &name)
{
title=name;
emit renameSession(this,name);
@@ -341,8 +341,8 @@ void TESession::renameSession(const QString &name)
TESession::~TESession()
{
//kdDebug(1211) << "disconnnecting..." << endl;
- QObject::disconnect( sh, SIGNAL( done(int) ),
- this, SLOT( done(int) ) );
+ TQObject::disconnect( sh, TQT_SIGNAL( done(int) ),
+ this, TQT_SLOT( done(int) ) );
delete em;
delete sh;
@@ -419,7 +419,7 @@ int TESession::keymapNo()
return em->keymapNo();
}
-QString TESession::keymap()
+TQString TESession::keymap()
{
return em->keymap();
}
@@ -429,12 +429,12 @@ int TESession::fontNo()
return font_no;
}
-const QString & TESession::Term()
+const TQString & TESession::Term()
{
return term;
}
-const QString & TESession::SessionId()
+const TQString & TESession::SessionId()
{
return sessionId;
}
@@ -454,7 +454,7 @@ void TESession::setKeymapNo(int kn)
em->setKeymap(kn);
}
-void TESession::setKeymap(const QString &id)
+void TESession::setKeymap(const TQString &id)
{
em->setKeymap(id);
}
@@ -464,39 +464,39 @@ void TESession::setFontNo(int fn)
font_no = fn;
}
-void TESession::setTitle(const QString& _title)
+void TESession::setTitle(const TQString& _title)
{
title = _title;
//kdDebug(1211)<<"Session setTitle " << title <<endl;
}
-const QString& TESession::Title()
+const TQString& TESession::Title()
{
return title;
}
-void TESession::setIconName(const QString& _iconName)
+void TESession::setIconName(const TQString& _iconName)
{
iconName = _iconName;
}
-void TESession::setIconText(const QString& _iconText)
+void TESession::setIconText(const TQString& _iconText)
{
iconText = _iconText;
//kdDebug(1211)<<"Session setIconText " << iconText <<endl;
}
-const QString& TESession::IconName()
+const TQString& TESession::IconName()
{
return iconName;
}
-const QString& TESession::IconText()
+const TQString& TESession::IconText()
{
return iconText;
}
-bool TESession::testAndSetStateIconName (const QString& newname)
+bool TESession::testAndSetStateIconName (const TQString& newname)
{
if (newname != stateIconName)
{
@@ -528,21 +528,21 @@ void TESession::clearHistory()
}
}
-QStrList TESession::getArgs()
+TQStrList TESession::getArgs()
{
return args;
}
-QString TESession::getPgm()
+TQString TESession::getPgm()
{
return pgm;
}
-QString TESession::getCwd()
+TQString TESession::getCwd()
{
#ifdef HAVE_PROC_CWD
if (cwd.isEmpty()) {
- QFileInfo Cwd(QString("/proc/%1/cwd").arg(sh->pid()));
+ TQFileInfo Cwd(TQString("/proc/%1/cwd").arg(sh->pid()));
if(Cwd.isSymLink())
return Cwd.readLink();
}
@@ -599,7 +599,7 @@ void TESession::slotZModemDetected()
{
if (!zmodemBusy)
{
- QTimer::singleShot(10, this, SLOT(emitZModemDetected()));
+ TQTimer::singleShot(10, this, TQT_SLOT(emitZModemDetected()));
zmodemBusy = true;
}
}
@@ -615,13 +615,13 @@ void TESession::cancelZModem()
zmodemBusy = false;
}
-void TESession::startZModem(const QString &zmodem, const QString &dir, const QStringList &list)
+void TESession::startZModem(const TQString &zmodem, const TQString &dir, const TQStringList &list)
{
zmodemBusy = true;
zmodemProc = new KProcIO;
(*zmodemProc) << zmodem << "-v";
- for(QStringList::ConstIterator it = list.begin();
+ for(TQStringList::ConstIterator it = list.begin();
it != list.end();
++it)
{
@@ -633,23 +633,23 @@ void TESession::startZModem(const QString &zmodem, const QString &dir, const QSt
zmodemProc->start(KProcIO::NotifyOnExit, false);
// Override the read-processing of KProcIO
- disconnect(zmodemProc,SIGNAL (receivedStdout (KProcess *, char *, int)), 0, 0);
- connect(zmodemProc,SIGNAL (receivedStdout (KProcess *, char *, int)),
- this, SLOT(zmodemSendBlock(KProcess *, char *, int)));
- connect(zmodemProc,SIGNAL (receivedStderr (KProcess *, char *, int)),
- this, SLOT(zmodemStatus(KProcess *, char *, int)));
- connect(zmodemProc,SIGNAL (processExited(KProcess *)),
- this, SLOT(zmodemDone()));
-
- disconnect( sh,SIGNAL(block_in(const char*,int)), this, SLOT(onRcvBlock(const char*,int)) );
- connect( sh,SIGNAL(block_in(const char*,int)), this, SLOT(zmodemRcvBlock(const char*,int)) );
- connect( sh,SIGNAL(buffer_empty()), this, SLOT(zmodemContinue()));
+ disconnect(zmodemProc,TQT_SIGNAL (receivedStdout (KProcess *, char *, int)), 0, 0);
+ connect(zmodemProc,TQT_SIGNAL (receivedStdout (KProcess *, char *, int)),
+ this, TQT_SLOT(zmodemSendBlock(KProcess *, char *, int)));
+ connect(zmodemProc,TQT_SIGNAL (receivedStderr (KProcess *, char *, int)),
+ this, TQT_SLOT(zmodemStatus(KProcess *, char *, int)));
+ connect(zmodemProc,TQT_SIGNAL (processExited(KProcess *)),
+ this, TQT_SLOT(zmodemDone()));
+
+ disconnect( sh,TQT_SIGNAL(block_in(const char*,int)), this, TQT_SLOT(onRcvBlock(const char*,int)) );
+ connect( sh,TQT_SIGNAL(block_in(const char*,int)), this, TQT_SLOT(zmodemRcvBlock(const char*,int)) );
+ connect( sh,TQT_SIGNAL(buffer_empty()), this, TQT_SLOT(zmodemContinue()));
zmodemProgress = new ZModemDialog(te->topLevelWidget(), false,
i18n("ZModem Progress"));
- connect(zmodemProgress, SIGNAL(user1Clicked()),
- this, SLOT(zmodemDone()));
+ connect(zmodemProgress, TQT_SIGNAL(user1Clicked()),
+ this, TQT_SLOT(zmodemDone()));
zmodemProgress->show();
}
@@ -673,12 +673,12 @@ void TESession::zmodemContinue()
void TESession::zmodemStatus(KProcess *, char *data, int len)
{
- QCString msg(data, len+1);
+ TQCString msg(data, len+1);
while(!msg.isEmpty())
{
int i = msg.find('\015');
int j = msg.find('\012');
- QCString txt;
+ TQCString txt;
if ((i != -1) && ((j == -1) || (i < j)))
{
msg = msg.mid(i+1);
@@ -694,13 +694,13 @@ void TESession::zmodemStatus(KProcess *, char *data, int len)
msg.truncate(0);
}
if (!txt.isEmpty())
- zmodemProgress->addProgressText(QString::fromLocal8Bit(txt));
+ zmodemProgress->addProgressText(TQString::fromLocal8Bit(txt));
}
}
void TESession::zmodemRcvBlock(const char *data, int len)
{
- QByteArray ba;
+ TQByteArray ba;
ba.duplicate(data, len);
zmodemProc->writeStdin(ba);
// qWarning("--> %d bytes", len);
@@ -714,9 +714,9 @@ void TESession::zmodemDone()
zmodemProc = 0;
zmodemBusy = false;
- disconnect( sh,SIGNAL(block_in(const char*,int)), this ,SLOT(zmodemRcvBlock(const char*,int)) );
- disconnect( sh,SIGNAL(buffer_empty()), this, SLOT(zmodemContinue()));
- connect( sh,SIGNAL(block_in(const char*,int)), this, SLOT(onRcvBlock(const char*,int)) );
+ disconnect( sh,TQT_SIGNAL(block_in(const char*,int)), this ,TQT_SLOT(zmodemRcvBlock(const char*,int)) );
+ disconnect( sh,TQT_SIGNAL(buffer_empty()), this, TQT_SLOT(zmodemContinue()));
+ connect( sh,TQT_SIGNAL(block_in(const char*,int)), this, TQT_SLOT(onRcvBlock(const char*,int)) );
sh->send_bytes("\030\030\030\030", 4); // Abort
sh->send_bytes("\001\013\n", 3); // Try to get prompt back
@@ -725,23 +725,23 @@ void TESession::zmodemDone()
}
-bool TESession::processDynamic(const QCString &fun, const QByteArray &data, QCString& replyType, QByteArray &replyData)
+bool TESession::processDynamic(const TQCString &fun, const TQByteArray &data, TQCString& replyType, TQByteArray &replyData)
{
if (fullScripting)
{
- if (fun == "feedSession(QString)")
+ if (fun == "feedSession(TQString)")
{
- QString arg0;
- QDataStream arg( data, IO_ReadOnly );
+ TQString arg0;
+ TQDataStream arg( data, IO_ReadOnly );
arg >> arg0;
feedSession(arg0);
replyType = "void";
return true;
}
- else if (fun == "sendSession(QString)")
+ else if (fun == "sendSession(TQString)")
{
- QString arg0;
- QDataStream arg( data, IO_ReadOnly );
+ TQString arg0;
+ TQDataStream arg( data, IO_ReadOnly );
arg >> arg0;
sendSession(arg0);
replyType = "void";
@@ -757,8 +757,8 @@ QCStringList TESession::functionsDynamic()
QCStringList funcs = SessionIface::functionsDynamic();
if (fullScripting)
{
- funcs << "void feedSession(QString text)";
- funcs << "void sendSession(QString text)";
+ funcs << "void feedSession(TQString text)";
+ funcs << "void sendSession(TQString text)";
}
return funcs;
}
@@ -767,67 +767,67 @@ QCStringList TESession::functionsDynamic()
void TESession::onRcvBlock( const char* buf, int len )
{
em->onRcvBlock( buf, len );
- emit receivedData( QString::fromLatin1( buf, len ) );
+ emit receivedData( TQString::fromLatin1( buf, len ) );
}
-void TESession::print( QPainter &paint, bool friendly, bool exact )
+void TESession::print( TQPainter &paint, bool friendly, bool exact )
{
te->print(paint, friendly, exact);
}
-QString TESession::schema()
+TQString TESession::schema()
{
- QString currentSchema;
+ TQString currentSchema;
emit getSessionSchema(this, currentSchema);
return currentSchema;
}
-void TESession::setSchema(const QString &schema)
+void TESession::setSchema(const TQString &schema)
{
emit setSessionSchema(this, schema);
}
-QString TESession::font()
+TQString TESession::font()
{
return te->getVTFont().toString();
}
-void TESession::setFont(const QString &font)
+void TESession::setFont(const TQString &font)
{
- QFont tmp;
+ TQFont tmp;
if (tmp.fromString(font))
te->setVTFont(tmp);
else
kdWarning()<<"unknown font: "<<font<<endl;
}
-QString TESession::encoding()
+TQString TESession::encoding()
{
return em->codec()->name();
}
-void TESession::setEncoding(const QString &encoding)
+void TESession::setEncoding(const TQString &encoding)
{
emit setSessionEncoding(this, encoding);
}
-QString TESession::keytab()
+TQString TESession::keytab()
{
return keymap();
}
-void TESession::setKeytab(const QString &keytab)
+void TESession::setKeytab(const TQString &keytab)
{
setKeymap(keytab);
emit updateSessionConfig(this);
}
-QSize TESession::size()
+TQSize TESession::size()
{
return em->imageSize();
}
-void TESession::setSize(QSize size)
+void TESession::setSize(TQSize size)
{
if ((size.width() <= 1) || (size.height() <= 1))
return;
diff --git a/konsole/konsole/session.h b/konsole/konsole/session.h
index 90352cb5e..cbe41ab50 100644
--- a/konsole/konsole/session.h
+++ b/konsole/konsole/session.h
@@ -23,7 +23,7 @@
#include <kapplication.h>
#include <kmainwindow.h>
-#include <qstrlist.h>
+#include <tqstrlist.h>
#include "TEPty.h"
#include "TEWidget.h"
@@ -35,14 +35,14 @@ class KProcIO;
class KProcess;
class ZModemDialog;
-class TESession : public QObject, virtual public SessionIface
+class TESession : public TQObject, virtual public SessionIface
{ Q_OBJECT
public:
TESession(TEWidget* w,
- const QString &term, ulong winId, const QString &sessionId="session-1",
- const QString &initial_cwd = QString::null);
+ const TQString &term, ulong winId, const TQString &sessionId="session-1",
+ const TQString &initial_cwd = TQString::null);
void changeWidget(TEWidget* w);
void setPty( TEPty *_sh );
TEWidget* widget() { return te; }
@@ -58,19 +58,19 @@ public:
int schemaNo();
int encodingNo();
int fontNo();
- const QString& Term();
- const QString& SessionId();
- const QString& Title();
- const QString& IconName();
- const QString& IconText();
- QString fullTitle() const;
+ const TQString& Term();
+ const TQString& SessionId();
+ const TQString& Title();
+ const TQString& IconName();
+ const TQString& IconText();
+ TQString fullTitle() const;
int keymapNo();
- QString keymap();
- QStrList getArgs();
- QString getPgm();
- QString getCwd();
- QString getInitial_cwd() { return initial_cwd; }
- void setInitial_cwd(const QString& _cwd) { initial_cwd=_cwd; }
+ TQString keymap();
+ TQStrList getArgs();
+ TQString getPgm();
+ TQString getCwd();
+ TQString getInitial_cwd() { return initial_cwd; }
+ void setInitial_cwd(const TQString& _cwd) { initial_cwd=_cwd; }
void setHistory(const HistoryType&);
const HistoryType& history();
@@ -82,14 +82,14 @@ public:
void setSchemaNo(int sn);
void setEncodingNo(int index);
void setKeymapNo(int kn);
- void setKeymap(const QString& _id);
+ void setKeymap(const TQString& _id);
void setFontNo(int fn);
- void setTitle(const QString& _title);
- void setIconName(const QString& _iconName);
- void setIconText(const QString& _iconText);
+ void setTitle(const TQString& _title);
+ void setIconName(const TQString& _iconName);
+ void setIconText(const TQString& _iconText);
void setAddToUtmp(bool);
void setXonXoff(bool);
- bool testAndSetStateIconName (const QString& newname);
+ bool testAndSetStateIconName (const TQString& newname);
bool sendSignal(int signal);
void setAutoClose(bool b) { autoClose = b; }
@@ -97,41 +97,41 @@ public:
// Additional functions for DCOP
bool closeSession();
void clearHistory();
- void feedSession(const QString &text);
- void sendSession(const QString &text);
- void renameSession(const QString &name);
- QString sessionName() { return title; }
+ void feedSession(const TQString &text);
+ void sendSession(const TQString &text);
+ void renameSession(const TQString &name);
+ TQString sessionName() { return title; }
int sessionPID() { return sh->pid(); }
- virtual bool processDynamic(const QCString &fun, const QByteArray &data, QCString& replyType, QByteArray &replyData);
+ virtual bool processDynamic(const TQCString &fun, const TQByteArray &data, TQCString& replyType, TQByteArray &replyData);
virtual QCStringList functionsDynamic();
void enableFullScripting(bool b) { fullScripting = b; }
- void startZModem(const QString &rz, const QString &dir, const QStringList &list);
+ void startZModem(const TQString &rz, const TQString &dir, const TQStringList &list);
void cancelZModem();
bool zmodemIsBusy() { return zmodemBusy; }
- void print(QPainter &paint, bool friendly, bool exact);
+ void print(TQPainter &paint, bool friendly, bool exact);
- QString schema();
- void setSchema(const QString &schema);
- QString encoding();
- void setEncoding(const QString &encoding);
- QString keytab();
- void setKeytab(const QString &keytab);
- QSize size();
- void setSize(QSize size);
- void setFont(const QString &font);
- QString font();
+ TQString schema();
+ void setSchema(const TQString &schema);
+ TQString encoding();
+ void setEncoding(const TQString &encoding);
+ TQString keytab();
+ void setKeytab(const TQString &keytab);
+ TQSize size();
+ void setSize(TQSize size);
+ void setFont(const TQString &font);
+ TQString font();
public slots:
void run();
- void setProgram( const QString &_pgm, const QStrList &_args );
+ void setProgram( const TQString &_pgm, const TQStrList &_args );
void done();
void done(int);
void terminate();
- void setUserTitle( int, const QString &caption );
+ void setUserTitle( int, const TQString &caption );
void changeTabTextColor( int );
void ptyError();
void slotZModemDetected();
@@ -147,7 +147,7 @@ signals:
void processExited(KProcess *);
void forkedChild();
- void receivedData( const QString& text );
+ void receivedData( const TQString& text );
void done(TESession*);
void updateTitle(TESession*);
void notifySessionState(TESession* session, int state);
@@ -155,16 +155,16 @@ signals:
void disableMasterModeConnections();
void enableMasterModeConnections();
- void renameSession(TESession* ses, const QString &name);
+ void renameSession(TESession* ses, const TQString &name);
- void openURLRequest(const QString &cwd);
+ void openURLRequest(const TQString &cwd);
void zmodemDetected(TESession *);
void updateSessionConfig(TESession *);
- void resizeSession(TESession *session, QSize size);
- void setSessionEncoding(TESession *session, const QString &encoding);
- void getSessionSchema(TESession *session, QString &schema);
- void setSessionSchema(TESession *session, const QString &schema);
+ void resizeSession(TESession *session, TQSize size);
+ void setSessionEncoding(TESession *session, const TQString &encoding);
+ void getSessionSchema(TESession *session, TQString &schema);
+ void setSessionSchema(TESession *session, const TQString &schema);
private slots:
void onRcvBlock( const char* buf, int len );
@@ -186,7 +186,7 @@ private:
bool masterMode;
bool autoClose;
bool wantedClose;
- QTimer* monitorTimer;
+ TQTimer* monitorTimer;
//FIXME: using the indices here
// is propably very bad. We should
@@ -198,25 +198,25 @@ private:
int font_h;
int font_w;
- QString title;
- QString userTitle;
- QString iconName;
- QString iconText; // as set by: echo -en '\033]1;IconText\007
+ TQString title;
+ TQString userTitle;
+ TQString iconName;
+ TQString iconText; // as set by: echo -en '\033]1;IconText\007
bool add_to_utmp;
bool xon_xoff;
bool fullScripting;
QString stateIconName;
- QString pgm;
- QStrList args;
+ TQString pgm;
+ TQStrList args;
- QString term;
+ TQString term;
ulong winId;
- QString sessionId;
+ TQString sessionId;
- QString cwd;
- QString initial_cwd;
+ TQString cwd;
+ TQString initial_cwd;
// ZModem
bool zmodemBusy;
@@ -225,7 +225,7 @@ private:
// Color/Font Changes by ESC Sequences
- QColor modifiedBackground; // as set by: echo -en '\033]11;Color\007
+ TQColor modifiedBackground; // as set by: echo -en '\033]11;Color\007
int encoding_no;
};
diff --git a/konsole/konsole/sessioniface.h b/konsole/konsole/sessioniface.h
index 51ee5ca80..b77e01bda 100644
--- a/konsole/konsole/sessioniface.h
+++ b/konsole/konsole/sessioniface.h
@@ -32,20 +32,20 @@ class SessionIface : virtual public DCOPObject
virtual bool sendSignal(int signal) =0;
virtual void clearHistory() =0;
- virtual void renameSession(const QString &name) =0;
- virtual QString sessionName() =0;
+ virtual void renameSession(const TQString &name) =0;
+ virtual TQString sessionName() =0;
virtual int sessionPID() =0;
- virtual QString schema() =0;
- virtual void setSchema(const QString &schema) =0;
- virtual QString encoding() =0;
- virtual void setEncoding(const QString &encoding) =0;
- virtual QString keytab() =0;
- virtual void setKeytab(const QString &keyboard) =0;
- virtual QSize size() =0;
- virtual void setSize(QSize size) =0;
- virtual QString font() =0;
- virtual void setFont(const QString &font) =0;
+ virtual TQString schema() =0;
+ virtual void setSchema(const TQString &schema) =0;
+ virtual TQString encoding() =0;
+ virtual void setEncoding(const TQString &encoding) =0;
+ virtual TQString keytab() =0;
+ virtual void setKeytab(const TQString &keyboard) =0;
+ virtual TQSize size() =0;
+ virtual void setSize(TQSize size) =0;
+ virtual TQString font() =0;
+ virtual void setFont(const TQString &font) =0;
};
#endif // SESSIONIFACE_H
diff --git a/konsole/konsole/zmodem_dialog.cpp b/konsole/konsole/zmodem_dialog.cpp
index 31148ddc6..421501c40 100644
--- a/konsole/konsole/zmodem_dialog.cpp
+++ b/konsole/konsole/zmodem_dialog.cpp
@@ -18,24 +18,24 @@
#include "zmodem_dialog.h"
-#include <qtextedit.h>
+#include <tqtextedit.h>
#include <klocale.h>
-ZModemDialog::ZModemDialog(QWidget *parent, bool modal, const QString &caption)
+ZModemDialog::ZModemDialog(TQWidget *parent, bool modal, const TQString &caption)
: KDialogBase(parent, "zmodem_progress", modal, caption,
User1|Close, User1, true,
i18n("&Stop"))
{
setEscapeButton(User1);
enableButton(Close, false);
- textEdit = new QTextEdit(this);
+ textEdit = new TQTextEdit(this);
textEdit->setMinimumSize(400, 100);
setMainWidget(textEdit);
- connect(this, SIGNAL(user1Clicked()), this, SLOT(slotClose()));
+ connect(this, TQT_SIGNAL(user1Clicked()), this, TQT_SLOT(slotClose()));
}
-void ZModemDialog::addProgressText(const QString &txt)
+void ZModemDialog::addProgressText(const TQString &txt)
{
int p = textEdit->paragraphs();
textEdit->insertParagraph(txt, p);
diff --git a/konsole/konsole/zmodem_dialog.h b/konsole/konsole/zmodem_dialog.h
index 045e1c566..26302cdfb 100644
--- a/konsole/konsole/zmodem_dialog.h
+++ b/konsole/konsole/zmodem_dialog.h
@@ -27,12 +27,12 @@ class ZModemDialog : public KDialogBase
{
Q_OBJECT
public:
- ZModemDialog(QWidget *parent, bool modal, const QString &caption);
+ ZModemDialog(TQWidget *parent, bool modal, const TQString &caption);
/**
* Adds a line of text to the progress window
*/
- void addProgressText(const QString &);
+ void addProgressText(const TQString &);
/**
* To indicate the process is finished.
@@ -43,7 +43,7 @@ public slots:
void slotClose();
private:
- QTextEdit *textEdit;
+ TQTextEdit *textEdit;
};
#endif