summaryrefslogtreecommitdiffstats
path: root/kbabel/kbabel
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:51:49 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:51:49 +0000
commit4ae0c208b66e0f7954e194384464fe2d0a2c56dd (patch)
treeb0a7cd1c184f0003c0292eb416ed27f674f9cc43 /kbabel/kbabel
parent1964ea0fb4ab57493ca2ebb709c8d3b5395fd653 (diff)
downloadtdesdk-4ae0c208.tar.gz
tdesdk-4ae0c208.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1157652 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kbabel/kbabel')
-rw-r--r--kbabel/kbabel/charselectview.cpp36
-rw-r--r--kbabel/kbabel/charselectview.h6
-rw-r--r--kbabel/kbabel/commentview.cpp34
-rw-r--r--kbabel/kbabel/commentview.h10
-rw-r--r--kbabel/kbabel/contextview.cpp46
-rw-r--r--kbabel/kbabel/contextview.h4
-rw-r--r--kbabel/kbabel/errorlistview.cpp16
-rw-r--r--kbabel/kbabel/errorlistview.h4
-rw-r--r--kbabel/kbabel/gotodialog.cpp6
-rw-r--r--kbabel/kbabel/gotodialog.h4
-rw-r--r--kbabel/kbabel/headereditor.cpp20
-rw-r--r--kbabel/kbabel/headereditor.h2
-rw-r--r--kbabel/kbabel/hidingmsgedit.cpp52
-rw-r--r--kbabel/kbabel/hidingmsgedit.h42
-rw-r--r--kbabel/kbabel/kbabel.cpp574
-rw-r--r--kbabel/kbabel/kbabel.h50
-rw-r--r--kbabel/kbabel/kbabeliface.h38
-rw-r--r--kbabel/kbabel/kbabelpref.cpp18
-rw-r--r--kbabel/kbabel/kbabelpref.h6
-rw-r--r--kbabel/kbabel/kbabelsplash.cpp32
-rw-r--r--kbabel/kbabel/kbabelsplash.h6
-rw-r--r--kbabel/kbabel/kbabelview.cpp560
-rw-r--r--kbabel/kbabel/kbabelview.h118
-rw-r--r--kbabel/kbabel/kbabelview2.cpp126
-rw-r--r--kbabel/kbabel/kbbookmarkhandler.cpp28
-rw-r--r--kbabel/kbabel/kbbookmarkhandler.h22
-rw-r--r--kbabel/kbabel/kbcatalog.cpp2
-rw-r--r--kbabel/kbabel/kbcatalog.h2
-rw-r--r--kbabel/kbabel/kbcataloglistview.cpp24
-rw-r--r--kbabel/kbabel/kbcataloglistview.h16
-rw-r--r--kbabel/kbabel/kbcataloglistviewitem.cpp32
-rw-r--r--kbabel/kbabel/kbcataloglistviewitem.h26
-rw-r--r--kbabel/kbabel/kbcatalogview.cpp8
-rw-r--r--kbabel/kbabel/kbcatalogview.h6
-rw-r--r--kbabel/kbabel/kbcharselect.cpp24
-rw-r--r--kbabel/kbabel/kbcharselect.h8
-rw-r--r--kbabel/kbabel/kbhighlighting.cpp44
-rw-r--r--kbabel/kbabel/kbhighlighting.h32
-rw-r--r--kbabel/kbabel/main.cpp138
-rw-r--r--kbabel/kbabel/mymultilineedit.cpp300
-rw-r--r--kbabel/kbabel/mymultilineedit.h92
-rw-r--r--kbabel/kbabel/sourceview.cpp12
-rw-r--r--kbabel/kbabel/sourceview.h2
-rw-r--r--kbabel/kbabel/spelldlg.cpp10
-rw-r--r--kbabel/kbabel/spelldlg.h2
-rw-r--r--kbabel/kbabel/taglistview.cpp22
-rw-r--r--kbabel/kbabel/taglistview.h4
47 files changed, 1333 insertions, 1333 deletions
diff --git a/kbabel/kbabel/charselectview.cpp b/kbabel/kbabel/charselectview.cpp
index 12cd765f..2e58b084 100644
--- a/kbabel/kbabel/charselectview.cpp
+++ b/kbabel/kbabel/charselectview.cpp
@@ -33,11 +33,11 @@
#include "charselectview.h"
-#include <qlayout.h>
-#include <qwhatsthis.h>
-#include <qlabel.h>
-#include <qspinbox.h>
-#include <qscrollview.h>
+#include <tqlayout.h>
+#include <tqwhatsthis.h>
+#include <tqlabel.h>
+#include <tqspinbox.h>
+#include <tqscrollview.h>
#include <kconfig.h>
#include <kcursor.h>
@@ -49,24 +49,24 @@
using namespace KBabel;
-CharacterSelectorView::CharacterSelectorView(KBCatalog* catalog,QWidget *parent, Project::Ptr project)
+CharacterSelectorView::CharacterSelectorView(KBCatalog* catalog,TQWidget *parent, Project::Ptr project)
: KBCatalogView(catalog,parent,project)
{
- QVBoxLayout* layout = new QVBoxLayout( this );
- layout->setResizeMode( QLayout::Minimum );
+ TQVBoxLayout* layout = new TQVBoxLayout( this );
+ layout->setResizeMode( TQLayout::Minimum );
layout->setSpacing( KDialog::spacingHint() );
- QHBox* bar = new QHBox(this);
+ TQHBox* bar = new TQHBox(this);
bar->setSpacing( KDialog::spacingHint() );
layout->addWidget (bar);
- QLabel *lTable = new QLabel( i18n( "Table:" ), bar );
- _tableNum = new QSpinBox( 0, 255, 1, bar );
+ TQLabel *lTable = new TQLabel( i18n( "Table:" ), bar );
+ _tableNum = new TQSpinBox( 0, 255, 1, bar );
lTable->setBuddy( _tableNum );
bar->setStretchFactor( _tableNum, 1 );
- QScrollView* scroll = new QScrollView( this );
+ TQScrollView* scroll = new TQScrollView( this );
_table = new KCharSelectTable(scroll,"charselector","helvetica",' ',0);
_table->setNumCols(16);
_table->setNumRows(16);
@@ -74,13 +74,13 @@ CharacterSelectorView::CharacterSelectorView(KBCatalog* catalog,QWidget *parent,
scroll->addChild(_table);
layout->addWidget (scroll);
- connect( _table, SIGNAL( doubleClicked() ), this, SLOT( emitChar() ) );
- connect( _tableNum, SIGNAL( valueChanged(int) ), this, SLOT( setTab(int) ));
+ connect( _table, TQT_SIGNAL( doubleClicked() ), this, TQT_SLOT( emitChar() ) );
+ connect( _tableNum, TQT_SIGNAL( valueChanged(int) ), this, TQT_SLOT( setTab(int) ));
- connect( _catalog, SIGNAL( signalFileOpened(bool) ), this, SLOT (setDisabled (bool)));
- connect( _catalog, SIGNAL( signalFileOpened(bool) ), _table, SLOT (setDisabled (bool)));
+ connect( _catalog, TQT_SIGNAL( signalFileOpened(bool) ), this, TQT_SLOT (setDisabled (bool)));
+ connect( _catalog, TQT_SIGNAL( signalFileOpened(bool) ), _table, TQT_SLOT (setDisabled (bool)));
- QWhatsThis::add(this,
+ TQWhatsThis::add(this,
i18n("<qt><p><b>Character Selector</b></p>"
"<p>This tool allows to insert special characters using "
"double click.</p></qt>"));
@@ -101,7 +101,7 @@ void CharacterSelectorView::saveSettings(KConfig* config)
KConfigGroupSaver saver(config, "KBCharSelector" );
config->writeEntry( "TableNum", _tableNum->value() );
- config->writeEntry( "SelectedChar", QString(_table->chr()) );
+ config->writeEntry( "SelectedChar", TQString(_table->chr()) );
}
void CharacterSelectorView::restoreSettings(KConfig* config)
diff --git a/kbabel/kbabel/charselectview.h b/kbabel/kbabel/charselectview.h
index 76ee19b8..7b0fa8a5 100644
--- a/kbabel/kbabel/charselectview.h
+++ b/kbabel/kbabel/charselectview.h
@@ -45,7 +45,7 @@ public:
/**
* Default constructor
*/
- CharacterSelectorView(KBCatalog* catalog,QWidget *parent, KBabel::Project::Ptr project);
+ CharacterSelectorView(KBCatalog* catalog,TQWidget *parent, KBabel::Project::Ptr project);
void saveSettings(KConfig* config);
void restoreSettings(KConfig* config);
@@ -55,7 +55,7 @@ public slots:
virtual void updateView() {}
signals:
- void characterDoubleClicked( QChar ch );
+ void characterDoubleClicked( TQChar ch );
public slots:
void emitChar();
@@ -65,7 +65,7 @@ private slots:
private:
KCharSelectTable* _table;
- QSpinBox* _tableNum;
+ TQSpinBox* _tableNum;
};
#endif // CHARSELECTVIEW_H
diff --git a/kbabel/kbabel/commentview.cpp b/kbabel/kbabel/commentview.cpp
index bf2301de..57d838b9 100644
--- a/kbabel/kbabel/commentview.cpp
+++ b/kbabel/kbabel/commentview.cpp
@@ -35,11 +35,11 @@
#include "commentview.h"
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qwhatsthis.h>
-#include <qdragobject.h>
-#include <qtextview.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqwhatsthis.h>
+#include <tqdragobject.h>
+#include <tqtextview.h>
#include <kapplication.h>
#include <kconfig.h>
@@ -62,12 +62,12 @@
using namespace KBabel;
-CommentView::CommentView(KBCatalog* catalog,QWidget *parent, Project::Ptr project)
+CommentView::CommentView(KBCatalog* catalog,TQWidget *parent, Project::Ptr project)
: KBCatalogView(catalog,parent, project)
{
setAcceptDrops(true);
- QVBoxLayout* layout=new QVBoxLayout(this);
+ TQVBoxLayout* layout=new TQVBoxLayout(this);
commentEdit = new MsgMultiLineEdit(0, 0, this);
commentEdit->setMinimumHeight(50);
@@ -75,16 +75,16 @@ CommentView::CommentView(KBCatalog* catalog,QWidget *parent, Project::Ptr projec
commentEdit->setHighlightSyntax(false);
KCursor::setAutoHideCursor(commentEdit,true);
- QLabel* label=new QLabel(commentEdit,i18n("&Comment:"),this);
+ TQLabel* label=new TQLabel(commentEdit,i18n("&Comment:"),this);
- QHBoxLayout* hb=new QHBoxLayout(layout);
+ TQHBoxLayout* hb=new TQHBoxLayout(layout);
hb->addSpacing(KDialog::marginHint());
hb->addWidget(label);
layout->addWidget(commentEdit);
layout->setStretchFactor(commentEdit,1);
- QWhatsThis::add(this,
+ TQWhatsThis::add(this,
i18n("<qt><p><b>Comment Editor</b></p>\n\
This edit window shows you the comments of the currently displayed message.<p>\n\
<p>The comments normally contain information about where the message is found in the source\n\
@@ -94,12 +94,12 @@ Hints from other translators are also sometimes contained in comments.</p>\n\
<b>Options->Show Comments</b>.</p></qt>"));
commentEdit->setReadOnly(true);
- connect(commentEdit,SIGNAL(signalUndoCmd(KBabel::EditCommand*)),this,SLOT(forwardCommentEditCmd(KBabel::EditCommand*)));
+ connect(commentEdit,TQT_SIGNAL(signalUndoCmd(KBabel::EditCommand*)),this,TQT_SLOT(forwardCommentEditCmd(KBabel::EditCommand*)));
- connect(commentEdit,SIGNAL(cursorPositionChanged(int,int))
- , this, SIGNAL(signalCursorPosChanged(int,int)));
+ connect(commentEdit,TQT_SIGNAL(cursorPositionChanged(int,int))
+ , this, TQT_SIGNAL(signalCursorPosChanged(int,int)));
- connect(_catalog, SIGNAL(signalFileOpened(bool)), this, SLOT(setDisabled(bool)));
+ connect(_catalog, TQT_SIGNAL(signalFileOpened(bool)), this, TQT_SLOT(setDisabled(bool)));
}
void CommentView::update(EditCommand* cmd, bool undo)
@@ -178,7 +178,7 @@ void CommentView::readFileSettings()
setReadOnly( _catalog->isReadOnly() );
}
-const QString CommentView::selectText(int from, int to)
+const TQString CommentView::selectText(int from, int to)
{
int line, col, endline, endcol;
@@ -203,12 +203,12 @@ int CommentView::currentIndex ()
return commentEdit->currentIndex ();
}
-const QString CommentView::selectedText ()
+const TQString CommentView::selectedText ()
{
return commentEdit->selectedText ();
}
-void CommentView::installEventFilter( const QObject * filterObj )
+void CommentView::installEventFilter( const TQObject * filterObj )
{
commentEdit->installEventFilter( filterObj );
}
diff --git a/kbabel/kbabel/commentview.h b/kbabel/kbabel/commentview.h
index 1531683b..6d637add 100644
--- a/kbabel/kbabel/commentview.h
+++ b/kbabel/kbabel/commentview.h
@@ -35,7 +35,7 @@
class QTextView;
-#include <qwidget.h>
+#include <tqwidget.h>
#include "kbcatalogview.h"
#include "kbcatalog.h"
@@ -51,7 +51,7 @@ public:
/**
* Default constructor
*/
- CommentView(KBCatalog* catalog,QWidget *parent, KBabel::Project::Ptr project);
+ CommentView(KBCatalog* catalog,TQWidget *parent, KBabel::Project::Ptr project);
/**
* this is called from the catalog when updating his views.
@@ -67,13 +67,13 @@ public:
virtual void textSelectAll ();
virtual void textDeselectAll ();
- const QString selectText( int from, int to );
- const QString selectedText ();
+ const TQString selectText( int from, int to );
+ const TQString selectedText ();
bool isActiveView ();
int currentIndex ();
// this method is not virtual!
- void installEventFilter( const QObject * filterObj );
+ void installEventFilter( const TQObject * filterObj );
bool hasFocus ();
diff --git a/kbabel/kbabel/contextview.cpp b/kbabel/kbabel/contextview.cpp
index e56e15dc..264d4e84 100644
--- a/kbabel/kbabel/contextview.cpp
+++ b/kbabel/kbabel/contextview.cpp
@@ -35,9 +35,9 @@
#include "contextview.h"
-#include <qlayout.h>
-#include <qtextview.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqtextview.h>
+#include <tqwhatsthis.h>
#include <kcursor.h>
#include <klocale.h>
@@ -47,19 +47,19 @@
using namespace KBabel;
-ContextView::ContextView(KBCatalog* catalog,QWidget *parent, Project::Ptr project)
+ContextView::ContextView(KBCatalog* catalog,TQWidget *parent, Project::Ptr project)
: KBCatalogView(catalog,parent,project)
{
- QVBoxLayout* layout = new QVBoxLayout( this );
- layout->setResizeMode( QLayout::Minimum );
+ TQVBoxLayout* layout = new TQVBoxLayout( this );
+ layout->setResizeMode( TQLayout::Minimum );
- _textview = new QTextView (this, "context textview");
+ _textview = new TQTextView (this, "context textview");
KCursor::setAutoHideCursor(_textview->viewport(),true);
_textview->setReadOnly(true);
layout->addWidget (_textview);
- QWhatsThis::add(this,
+ TQWhatsThis::add(this,
i18n("<qt><p><b>PO Context</b></p>"
"<p>This window shows the context of the current message "
"in the PO file. Normally it shows four messages in front "
@@ -67,7 +67,7 @@ ContextView::ContextView(KBCatalog* catalog,QWidget *parent, Project::Ptr projec
"<p>You can hide the tools window by deactivating "
"<b>Options->Show Tools</b>.</p></qt></qt>"));
- connect(_catalog, SIGNAL(signalFileOpened(bool)), this, SLOT(setDisabled(bool)));
+ connect(_catalog, TQT_SIGNAL(signalFileOpened(bool)), this, TQT_SLOT(setDisabled(bool)));
}
void ContextView::updateView()
@@ -76,7 +76,7 @@ void ContextView::updateView()
if(total==0)
return;
- QString text;
+ TQString text;
uint startIndex;
uint context = 4;
if(_currentIndex < context)
@@ -100,24 +100,24 @@ void ContextView::updateView()
continue;
}
- QString entry;
- QString temp;
+ TQString entry;
+ TQString temp;
temp = _catalog->comment(i);
if(!temp.isEmpty())
{
- temp = QStyleSheet::convertFromPlainText(temp);
- temp.replace(QRegExp("^<p>"),"");
- temp.replace(QRegExp("</p>$"),"");
+ temp = TQStyleSheet::convertFromPlainText(temp);
+ temp.replace(TQRegExp("^<p>"),"");
+ temp.replace(TQRegExp("</p>$"),"");
entry += "<i>"+temp+"</i><br/>";
}
// FIXME: should care about plural forms
- temp = QStyleSheet::convertFromPlainText(_catalog->msgid(i).first());
- temp.replace(QRegExp("^<p>"),"");
- temp.replace(QRegExp("</p>$"),"");
+ temp = TQStyleSheet::convertFromPlainText(_catalog->msgid(i).first());
+ temp.replace(TQRegExp("^<p>"),"");
+ temp.replace(TQRegExp("</p>$"),"");
entry += temp + "<br/>---<br/>";
- QStringList tempList = _catalog->msgstr(i);
+ TQStringList tempList = _catalog->msgstr(i);
if(tempList.isEmpty())
{
@@ -135,14 +135,14 @@ void ContextView::updateView()
{
uint counter = 1;
temp = "";
- for( QStringList::Iterator i=tempList.begin() ; i != tempList.end() ; ++i)
+ for( TQStringList::Iterator i=tempList.begin() ; i != tempList.end() ; ++i)
{
temp += i18n("Plural %1: %2\n").arg(counter++).arg(*i);
}
}
- temp = QStyleSheet::convertFromPlainText(temp);
- temp.replace(QRegExp("^<p>"),"");
- temp.replace(QRegExp("</p>$"),"");
+ temp = TQStyleSheet::convertFromPlainText(temp);
+ temp.replace(TQRegExp("^<p>"),"");
+ temp.replace(TQRegExp("</p>$"),"");
entry += temp+"<br/>";
}
diff --git a/kbabel/kbabel/contextview.h b/kbabel/kbabel/contextview.h
index 18bd0f4e..f51d3767 100644
--- a/kbabel/kbabel/contextview.h
+++ b/kbabel/kbabel/contextview.h
@@ -44,13 +44,13 @@ public:
/**
* Default constructor
*/
- ContextView(KBCatalog* catalog,QWidget *parent, KBabel::Project::Ptr project);
+ ContextView(KBCatalog* catalog,TQWidget *parent, KBabel::Project::Ptr project);
public slots:
virtual void updateView();
private:
- QTextView* _textview;
+ TQTextView* _textview;
};
#endif // CONTEXTVIEW_H
diff --git a/kbabel/kbabel/errorlistview.cpp b/kbabel/kbabel/errorlistview.cpp
index 2dcd3b12..c49c7940 100644
--- a/kbabel/kbabel/errorlistview.cpp
+++ b/kbabel/kbabel/errorlistview.cpp
@@ -35,9 +35,9 @@
#include "errorlistview.h"
-#include <qlayout.h>
-#include <qtextview.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqtextview.h>
+#include <tqwhatsthis.h>
#include <kcursor.h>
#include <klocale.h>
@@ -47,19 +47,19 @@
using namespace KBabel;
-ErrorListView::ErrorListView(KBCatalog* catalog,QWidget *parent, Project::Ptr project)
+ErrorListView::ErrorListView(KBCatalog* catalog,TQWidget *parent, Project::Ptr project)
: KBCatalogView(catalog,parent,project)
{
- QVBoxLayout* layout = new QVBoxLayout( this );
- layout->setResizeMode( QLayout::Minimum );
+ TQVBoxLayout* layout = new TQVBoxLayout( this );
+ layout->setResizeMode( TQLayout::Minimum );
- _textview = new QTextView (this);
+ _textview = new TQTextView (this);
KCursor::setAutoHideCursor(_textview->viewport(),true);
_textview->setReadOnly(true);
layout->addWidget(_textview);
- QWhatsThis::add(this, i18n( "<qt><p><b>Error List</b></p>"
+ TQWhatsThis::add(this, i18n( "<qt><p><b>Error List</b></p>"
"<p>This window shows the list of errors found by validator tools "
"so you can know why the current message has been marked with an "
"error.</p></qt>" ) );
diff --git a/kbabel/kbabel/errorlistview.h b/kbabel/kbabel/errorlistview.h
index d50e7ec7..cb1886c9 100644
--- a/kbabel/kbabel/errorlistview.h
+++ b/kbabel/kbabel/errorlistview.h
@@ -43,13 +43,13 @@ public:
/**
* Default constructor
*/
- ErrorListView(KBCatalog* catalog,QWidget *parent, KBabel::Project::Ptr project);
+ ErrorListView(KBCatalog* catalog,TQWidget *parent, KBabel::Project::Ptr project);
public slots:
virtual void updateView();
private:
- QTextView* _textview;
+ TQTextView* _textview;
};
#endif // ERRORLISTVIEW_H
diff --git a/kbabel/kbabel/gotodialog.cpp b/kbabel/kbabel/gotodialog.cpp
index f822f0dc..b08b0098 100644
--- a/kbabel/kbabel/gotodialog.cpp
+++ b/kbabel/kbabel/gotodialog.cpp
@@ -31,16 +31,16 @@
**************************************************************************** */
-#include <qstring.h>
+#include <tqstring.h>
#include <klocale.h>
#include <knuminput.h>
#include "gotodialog.h"
-GotoDialog::GotoDialog(int max,QWidget* parent)
+GotoDialog::GotoDialog(int max,TQWidget* parent)
: KDialogBase(parent,0,true,i18n("Go to Entry"),Ok|Cancel)
{
- QGroupBox* box=new QGroupBox(1,Qt::Horizontal,i18n("Go to Entry"),this);
+ TQGroupBox* box=new TQGroupBox(1,Qt::Horizontal,i18n("Go to Entry"),this);
_spinBox= new KIntSpinBox(1,max,1,1,10,box);
setMainWidget(box);
diff --git a/kbabel/kbabel/gotodialog.h b/kbabel/kbabel/gotodialog.h
index 4c8378d8..4c033973 100644
--- a/kbabel/kbabel/gotodialog.h
+++ b/kbabel/kbabel/gotodialog.h
@@ -38,14 +38,14 @@
#endif
#include <kdialogbase.h>
-#include <qgroupbox.h>
+#include <tqgroupbox.h>
class KIntSpinBox;
class GotoDialog : public KDialogBase
{
public:
- GotoDialog(int max, QWidget* parent);
+ GotoDialog(int max, TQWidget* parent);
virtual ~GotoDialog();
/** reimplemented to select contents when shown*/
diff --git a/kbabel/kbabel/headereditor.cpp b/kbabel/kbabel/headereditor.cpp
index 55ad4eb5..2f686652 100644
--- a/kbabel/kbabel/headereditor.cpp
+++ b/kbabel/kbabel/headereditor.cpp
@@ -49,13 +49,13 @@
using namespace KBabel;
HeaderEditor::HeaderEditor(Catalog* cat,const char* name)
- : KDialogBase((QWidget*)0,name,false,QString::null, Ok|Cancel|Default|User1)
+ : KDialogBase((TQWidget*)0,name,false,TQString::null, Ok|Cancel|Default|User1)
{
restoreSettings();
_catalog=cat;
- connect(_catalog,SIGNAL(signalFileOpened(bool)),this,SLOT(readHeader(bool)));
- connect(_catalog,SIGNAL(signalHeaderChanged()),this,SLOT(updateHeader()));
+ connect(_catalog,TQT_SIGNAL(signalFileOpened(bool)),this,TQT_SLOT(readHeader(bool)));
+ connect(_catalog,TQT_SIGNAL(signalHeaderChanged()),this,TQT_SLOT(updateHeader()));
setButtonText(User1,i18n("&Apply Settings"));
setButtonWhatsThis (User1, i18n("<qt><p>This button "
@@ -97,7 +97,7 @@ void HeaderEditor::restoreSettings()
KConfigGroupSaver saver(config, "HeaderEditor" );
- QSize defaultSize(350,250);
+ TQSize defaultSize(350,250);
_editorSize = config->readSizeEntry("Size", &defaultSize );
}
@@ -133,7 +133,7 @@ void HeaderEditor::slotUser1()
if(error)
{
- QString msg=i18n("<qt><p>This is not a valid header.</p>\n"
+ TQString msg=i18n("<qt><p>This is not a valid header.</p>\n"
"<p>Please edit the header before updating!</p></qt>");
KMessageBox::sorry(this,msg);
@@ -160,7 +160,7 @@ void HeaderEditor::slotCancel()
{
updateHeader();
- QDialog::reject();
+ TQDialog::reject();
}
void HeaderEditor::slotOk()
@@ -169,7 +169,7 @@ void HeaderEditor::slotOk()
{
if(!isValid())
{
- QString msg=i18n("<qt><p>This is not a valid header.</p>\n"
+ TQString msg=i18n("<qt><p>This is not a valid header.</p>\n"
"<p>Please edit the header before updating.</p></qt>");
switch(KMessageBox::warningYesNo(this,msg,i18n("Warning"),KStdGuiItem::discard(),i18n("Edit")))
@@ -192,15 +192,15 @@ void HeaderEditor::slotOk()
_catalog->setHeader(header);
}
- QDialog::accept();
+ TQDialog::accept();
}
bool HeaderEditor::isValid()
{
// check the comments
- QStringList comments = QStringList::split('\n',_editor->commentEdit->text());
+ TQStringList comments = TQStringList::split('\n',_editor->commentEdit->text());
- for( QStringList::Iterator it = comments.begin(); it != comments.end(); ++it )
+ for( TQStringList::Iterator it = comments.begin(); it != comments.end(); ++it )
{
if( !(*it).startsWith("#") )
{
diff --git a/kbabel/kbabel/headereditor.h b/kbabel/kbabel/headereditor.h
index 9fb9d6fb..88dda5ee 100644
--- a/kbabel/kbabel/headereditor.h
+++ b/kbabel/kbabel/headereditor.h
@@ -79,7 +79,7 @@ private:
KBabel::Catalog* _catalog;
HeaderWidget* _editor;
- QSize _editorSize;
+ TQSize _editorSize;
};
#endif // HEADEREDITOR_H
diff --git a/kbabel/kbabel/hidingmsgedit.cpp b/kbabel/kbabel/hidingmsgedit.cpp
index f18f8b81..60a62da4 100644
--- a/kbabel/kbabel/hidingmsgedit.cpp
+++ b/kbabel/kbabel/hidingmsgedit.cpp
@@ -31,18 +31,18 @@
#include "mymultilineedit.h"
#include "editcmd.h"
-#include <qptrlist.h>
-#include <qsizepolicy.h>
-#include <qstringlist.h>
-#include <qtabwidget.h>
+#include <tqptrlist.h>
+#include <tqsizepolicy.h>
+#include <tqstringlist.h>
+#include <tqtabwidget.h>
#include <kdebug.h>
#include <klocale.h>
using namespace KBabel;
-HidingMsgEdit::HidingMsgEdit(uint numberOfPlurals, QWidget* eventFilter, KSpell* spell, QWidget *parent, const char *name ) :
- QWidgetStack(parent,name)
+HidingMsgEdit::HidingMsgEdit(uint numberOfPlurals, TQWidget* eventFilter, KSpell* spell, TQWidget *parent, const char *name ) :
+ TQWidgetStack(parent,name)
, _singleEdit(0)
, _multipleEdit(0)
, _eventFilter(eventFilter)
@@ -54,8 +54,8 @@ HidingMsgEdit::HidingMsgEdit(uint numberOfPlurals, QWidget* eventFilter, KSpell*
_allEdits.clear();
setNumberOfPlurals( _numberOfPlurals );
- connect( _multipleEdit, SIGNAL(currentChanged( QWidget* )),
- this, SLOT( newCurrentMultiple( QWidget* )));
+ connect( _multipleEdit, TQT_SIGNAL(currentChanged( TQWidget* )),
+ this, TQT_SLOT( newCurrentMultiple( TQWidget* )));
showSingle();
}
@@ -63,7 +63,7 @@ HidingMsgEdit::HidingMsgEdit(uint numberOfPlurals, QWidget* eventFilter, KSpell*
HidingMsgEdit::~HidingMsgEdit(){
}
-void HidingMsgEdit::setText(QStringList texts, QString msgctxt){
+void HidingMsgEdit::setText(TQStringList texts, TQString msgctxt){
if( texts.count() == 0 )
{
kdWarning() << "HidingMsgEdit::setText with empty text" << endl;
@@ -84,7 +84,7 @@ void HidingMsgEdit::setText(QStringList texts, QString msgctxt){
{
if( _numberOfPlurals )
{
- QStringList::iterator text = texts.begin();
+ TQStringList::iterator text = texts.begin();
uint i;
for( i=0 ; i < _numberOfPlurals && text!= texts.end() ; i++, text++ )
{
@@ -172,12 +172,12 @@ void HidingMsgEdit::setNumberOfPlurals( uint numberOfPlurals )
if( _eventFilter )
_singleEdit->installEventFilter(_eventFilter);
- _multipleEdit = new QTabWidget( this );
+ _multipleEdit = new TQTabWidget( this );
MsgMultiLineEdit* pl;
for(uint i=0 ; i< _numberOfPlurals ; i++)
{
- pl = new MsgMultiLineEdit( i, _spell, _multipleEdit, QString("multipleEdit %1").arg(i).local8Bit());
+ pl = new MsgMultiLineEdit( i, _spell, _multipleEdit, TQString("multipleEdit %1").arg(i).local8Bit());
_allEdits.append(pl);
_multipleEdit->addTab( pl, i18n("Plural %1").arg(i+1));
if( _eventFilter )
@@ -189,12 +189,12 @@ void HidingMsgEdit::setNumberOfPlurals( uint numberOfPlurals )
for( MsgMultiLineEdit* e = _allEdits.first() ; e ; e = _allEdits.next() )
{
- connect( e, SIGNAL( signalUndoCmd( KBabel::EditCommand* )),
- this, SIGNAL( signalUndoCmd( KBabel::EditCommand* )));
- connect( e, SIGNAL( textChanged() ) , this, SIGNAL( textChanged() ));
- connect( e, SIGNAL( textChanged() ) , this, SLOT( emitTextChanged() ));
- connect( e, SIGNAL( cursorPositionChanged( int, int )),
- this, SLOT( emitCursorPositionChanged( int, int )) );
+ connect( e, TQT_SIGNAL( signalUndoCmd( KBabel::EditCommand* )),
+ this, TQT_SIGNAL( signalUndoCmd( KBabel::EditCommand* )));
+ connect( e, TQT_SIGNAL( textChanged() ) , this, TQT_SIGNAL( textChanged() ));
+ connect( e, TQT_SIGNAL( textChanged() ) , this, TQT_SLOT( emitTextChanged() ));
+ connect( e, TQT_SIGNAL( cursorPositionChanged( int, int )),
+ this, TQT_SLOT( emitCursorPositionChanged( int, int )) );
}
showPlurals( plurals );
@@ -213,7 +213,7 @@ uint HidingMsgEdit::currentForm()
else return _multipleEdit->currentPageIndex();
}
-void HidingMsgEdit::newCurrentMultiple( QWidget* widget )
+void HidingMsgEdit::newCurrentMultiple( TQWidget* widget )
{
_currentEdit = dynamic_cast<MsgMultiLineEdit*>(widget);
emit currentFormChanged ( _multipleEdit->currentPageIndex () );
@@ -278,7 +278,7 @@ void HidingMsgEdit::setQuotes(bool on)
}
}
-void HidingMsgEdit::setBgColor( const QColor& color)
+void HidingMsgEdit::setBgColor( const TQColor& color)
{
for( MsgMultiLineEdit* e = _allEdits.first(); e ; e = _allEdits.next() )
{
@@ -286,8 +286,8 @@ void HidingMsgEdit::setBgColor( const QColor& color)
}
}
-void HidingMsgEdit::setHighlightColors(const QColor& quoteColor, const QColor& unquoteColor
- , const QColor& cformatColor, const QColor& accelColor, const QColor& tagColor)
+void HidingMsgEdit::setHighlightColors(const TQColor& quoteColor, const TQColor& unquoteColor
+ , const TQColor& cformatColor, const TQColor& accelColor, const TQColor& tagColor)
{
for( MsgMultiLineEdit* e = _allEdits.first(); e ; e = _allEdits.next() )
{
@@ -328,7 +328,7 @@ void HidingMsgEdit::setHighlightBg( bool on )
}
}
-void HidingMsgEdit::setContextMenu( QPopupMenu *menu )
+void HidingMsgEdit::setContextMenu( TQPopupMenu *menu )
{
for( MsgMultiLineEdit* e = _allEdits.first(); e ; e = _allEdits.next() )
{
@@ -351,10 +351,10 @@ bool HidingMsgEdit::hasFocus ()
if( e->hasFocus() ) return true;
}
- return _multipleEdit->hasFocus() || QWidgetStack::hasFocus();
+ return _multipleEdit->hasFocus() || TQWidgetStack::hasFocus();
}
-void HidingMsgEdit::setDiffColors(const QColor& addColor, const QColor& delColor)
+void HidingMsgEdit::setDiffColors(const TQColor& addColor, const TQColor& delColor)
{
for( MsgMultiLineEdit* e = _allEdits.first(); e ; e = _allEdits.next() )
{
@@ -378,7 +378,7 @@ void HidingMsgEdit::setDiffDisplayMode(bool underlineAdded, bool strikeOutDelete
}
}
-void HidingMsgEdit::setFont(const QFont& font)
+void HidingMsgEdit::setFont(const TQFont& font)
{
for( MsgMultiLineEdit* e = _allEdits.first(); e ; e = _allEdits.next() )
{
diff --git a/kbabel/kbabel/hidingmsgedit.h b/kbabel/kbabel/hidingmsgedit.h
index 38e5d750..226f6e2d 100644
--- a/kbabel/kbabel/hidingmsgedit.h
+++ b/kbabel/kbabel/hidingmsgedit.h
@@ -30,9 +30,9 @@
#ifndef HIDINGMSGEDIT_H
#define HIDINGMSGEDIT_H
-#include <qwidgetstack.h>
-#include <qguardedptr.h>
-#include <qptrlist.h>
+#include <tqwidgetstack.h>
+#include <tqguardedptr.h>
+#include <tqptrlist.h>
#include "mymultilineedit.h"
@@ -49,10 +49,10 @@ namespace KBabel
*@author Stanislav Visnovsky <visnovsky@kde.org>
*/
-class HidingMsgEdit : public QWidgetStack {
+class HidingMsgEdit : public TQWidgetStack {
Q_OBJECT
public:
- HidingMsgEdit(uint numberOfPlurals, QWidget* eventFilter=0, KSpell* spell=0, QWidget *parent=0, const char *name=0);
+ HidingMsgEdit(uint numberOfPlurals, TQWidget* eventFilter=0, KSpell* spell=0, TQWidget *parent=0, const char *name=0);
~HidingMsgEdit();
void setNumberOfPlurals(uint numberOfPlurals);
@@ -64,7 +64,7 @@ public:
bool isOverwriteMode() const { return _currentEdit->isOverwriteMode(); }
bool isModified();
bool hasSelectedText() const { return _currentEdit->hasSelectedText(); }
- QString selectedText () const { return _currentEdit->selectedText(); }
+ TQString selectedText () const { return _currentEdit->selectedText(); }
void processCommand(KBabel::EditCommand* cmd, bool undo=false);
void offset2Pos(int offset, int &row, int &col) const
{ return _currentEdit->offset2Pos(offset, row, col ); }
@@ -74,25 +74,25 @@ public:
{ return _currentEdit->currentIndex(); }
int beginOfLastMarkedText() const
{ return _currentEdit->beginOfLastMarkedText(); }
- virtual void setFont ( const QFont & );
+ virtual void setFont ( const TQFont & );
void setCurrentColor(const MsgMultiLineEdit::TextColor color);
bool spacePoints() const { return _currentEdit->spacePoints(); }
void setSpacePoints(bool on);
bool quotes() const { return _currentEdit->quotes(); }
void setQuotes(bool on);
- void setBgColor( const QColor& color);
+ void setBgColor( const TQColor& color);
bool highlightBg() const { return _currentEdit->highlightBg(); }
bool highlightSyntax() const { return _currentEdit->highlightSyntax(); }
- void setHighlightColors(const QColor& quoteColor, const QColor& unquoteColor
- , const QColor& cformatColor, const QColor& accelColor, const QColor& tagColor);
+ void setHighlightColors(const TQColor& quoteColor, const TQColor& unquoteColor
+ , const TQColor& cformatColor, const TQColor& accelColor, const TQColor& tagColor);
int beginOfMarkedText() { return _currentEdit->beginOfMarkedText(); }
- virtual void insertAt ( const QString & s, int line, int col, bool mark = false )
+ virtual void insertAt ( const TQString & s, int line, int col, bool mark = false )
{ _currentEdit->insertAt( s, line, col, mark ); }
void setDiffMode(bool on);
void setDiffDisplayMode(bool underlineAdded, bool strikeOutDeleted);
- void setDiffColors(const QColor& addColor, const QColor& delColor);
- QString text(int para) { return _currentEdit->text(para); }
+ void setDiffColors(const TQColor& addColor, const TQColor& delColor);
+ TQString text(int para) { return _currentEdit->text(para); }
void setSpellChecker(KSpell* spell);
@@ -101,7 +101,7 @@ public:
// reiplemented to return correct value
bool hasFocus ();
public slots: // Public slots
- void setText(QStringList texts, QString msgctxt = QString::null);
+ void setText(TQStringList texts, TQString msgctxt = TQString::null);
void showSingle();
void showMultiple();
void showPlurals( bool on );
@@ -125,12 +125,12 @@ public slots: // Public slots
virtual void selectAll(bool select=true) { _currentEdit->selectAll(select); }
virtual void setCursorPosition ( int para, int index )
{ _currentEdit->setCursorPosition(para,index); }
- virtual void setContextMenu( QPopupMenu *menu );
+ virtual void setContextMenu( TQPopupMenu *menu );
signals:
void signalUndoCmd(KBabel::EditCommand*);
void textChanged();
- void textChanged(const QString&);
+ void textChanged(const TQString&);
void cursorPositionChanged ( int para, int pos );
void currentFormChanged ( uint form );
@@ -139,7 +139,7 @@ private slots:
void emitTextChanged();
// invoked if TabWidget changes the shown widget
- void newCurrentMultiple( QWidget * );
+ void newCurrentMultiple( TQWidget * );
// invoked by inner cursorPositionChanged() to transform line/col for wrapping
void emitCursorPositionChanged( int para, int pos );
@@ -147,15 +147,15 @@ private: // Private attributes
/** Used for editting non-plural messages */
MsgMultiLineEdit* _singleEdit;
/** Used for editting plural forms */
- QTabWidget* _multipleEdit;
- QWidget* _eventFilter;
+ TQTabWidget* _multipleEdit;
+ TQWidget* _eventFilter;
MsgMultiLineEdit* _currentEdit;
- QPtrList<MsgMultiLineEdit> _allEdits;
+ TQPtrList<MsgMultiLineEdit> _allEdits;
uint _numberOfPlurals;
- QGuardedPtr<KSpell> _spell;
+ TQGuardedPtr<KSpell> _spell;
};
#endif
diff --git a/kbabel/kbabel/kbabel.cpp b/kbabel/kbabel/kbabel.cpp
index cae7bf77..0c3c897d 100644
--- a/kbabel/kbabel/kbabel.cpp
+++ b/kbabel/kbabel/kbabel.cpp
@@ -48,15 +48,15 @@
#include "taglistview.h"
#include "sourceview.h"
-#include <qdragobject.h>
-#include <qlineedit.h>
-#include <qpopupmenu.h>
-#include <qhbox.h>
-#include <qwhatsthis.h>
-#include <qsize.h>
-#include <qtextcodec.h>
-#include <qtooltip.h>
-#include <qtimer.h>
+#include <tqdragobject.h>
+#include <tqlineedit.h>
+#include <tqpopupmenu.h>
+#include <tqhbox.h>
+#include <tqwhatsthis.h>
+#include <tqsize.h>
+#include <tqtextcodec.h>
+#include <tqtooltip.h>
+#include <tqtimer.h>
#include <dcopclient.h>
#include <kdatatool.h>
@@ -108,19 +108,19 @@
using namespace KBabel;
-QPtrList<KBabelPreferences> KBabelMW::prefDialogs;
+TQPtrList<KBabelPreferences> KBabelMW::prefDialogs;
class MyKProgress: public KProgress
{
public:
- MyKProgress( QWidget *parent, const char *name ) : KProgress( parent, name )
+ MyKProgress( TQWidget *parent, const char *name ) : KProgress( parent, name )
{
- setSizePolicy( QSizePolicy::Minimum, QSizePolicy::Preferred );
+ setSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Preferred );
}
- QSize sizeHint() const { return QSize( 1, 1);}
+ TQSize sizeHint() const { return TQSize( 1, 1);}
};
-KBabelMW::KBabelMW(QString projectFile)
+KBabelMW::KBabelMW(TQString projectFile)
: KDockMainWindow (), m_charselectorview(0)
{
if ( projectFile.isEmpty() )
@@ -138,7 +138,7 @@ KBabelMW::KBabelMW(QString projectFile)
init(catalog);
}
-KBabelMW::KBabelMW(KBCatalog* catalog, QString projectFile)
+KBabelMW::KBabelMW(KBCatalog* catalog, TQString projectFile)
: KDockMainWindow (), m_charselectorview(0)
{
if ( projectFile.isEmpty() )
@@ -170,9 +170,9 @@ void KBabelMW::init(KBCatalog* catalog)
_prefDialog=0;
prefDialogs.setAutoDelete(true);
- _statusbarTimer = new QTimer(this, "statusbartimer");
- connect(_statusbarTimer,SIGNAL(timeout()),this
- ,SLOT(clearStatusbarMsg()));
+ _statusbarTimer = new TQTimer(this, "statusbartimer");
+ connect(_statusbarTimer,TQT_SIGNAL(timeout()),this
+ ,TQT_SLOT(clearStatusbarMsg()));
// FIXME:
Q_ASSERT(_project);
@@ -193,87 +193,87 @@ void KBabelMW::init(KBCatalog* catalog)
stateChanged( "fileopened" , StateReverse );
stateChanged( "readonly", StateNoReverse );
- QPopupMenu* popup;
- popup = (QPopupMenu*)(factory()->container("rmb_edit", this));
+ TQPopupMenu* popup;
+ popup = (TQPopupMenu*)(factory()->container("rmb_edit", this));
if(popup)
{
m_view->setRMBEditMenu(popup);
}
- popup = (QPopupMenu*)(factory()->container("rmb_search", this));
+ popup = (TQPopupMenu*)(factory()->container("rmb_search", this));
if(popup)
{
m_view->setRMBSearchMenu(popup);
}
- connect(catalog,SIGNAL(signalUndoAvailable(bool)),this
- ,SLOT(enableUndo(bool)));
- connect(catalog,SIGNAL(signalRedoAvailable(bool)),this
- ,SLOT(enableRedo(bool)));
- connect(catalog,SIGNAL(signalNumberOfFuzziesChanged(uint)),this
- ,SLOT(setNumberOfFuzzies(uint)));
- connect(catalog,SIGNAL(signalNumberOfUntranslatedChanged(uint)),this
- ,SLOT(setNumberOfUntranslated(uint)));
- connect(catalog,SIGNAL(signalTotalNumberChanged(uint)),this
- ,SLOT(setNumberOfTotal(uint)));
- connect(catalog,SIGNAL(signalProgress(int)),_progressBar,SLOT(setProgress(int)));
- connect(catalog,SIGNAL(signalClearProgressBar()),this,SLOT(clearProgressBar()));
- connect(catalog,SIGNAL(signalResetProgressBar(QString,int))
- ,this,SLOT(prepareProgressBar(QString,int)));
- connect(catalog,SIGNAL(signalFileOpened(bool)),this,SLOT(enableDefaults(bool)));
- connect(catalog,SIGNAL(signalFileOpened(bool)),m_view,SLOT(newFileOpened(bool)));
- connect(catalog,SIGNAL(signalModified(bool)),this,SLOT(showModified(bool)));
+ connect(catalog,TQT_SIGNAL(signalUndoAvailable(bool)),this
+ ,TQT_SLOT(enableUndo(bool)));
+ connect(catalog,TQT_SIGNAL(signalRedoAvailable(bool)),this
+ ,TQT_SLOT(enableRedo(bool)));
+ connect(catalog,TQT_SIGNAL(signalNumberOfFuzziesChanged(uint)),this
+ ,TQT_SLOT(setNumberOfFuzzies(uint)));
+ connect(catalog,TQT_SIGNAL(signalNumberOfUntranslatedChanged(uint)),this
+ ,TQT_SLOT(setNumberOfUntranslated(uint)));
+ connect(catalog,TQT_SIGNAL(signalTotalNumberChanged(uint)),this
+ ,TQT_SLOT(setNumberOfTotal(uint)));
+ connect(catalog,TQT_SIGNAL(signalProgress(int)),_progressBar,TQT_SLOT(setProgress(int)));
+ connect(catalog,TQT_SIGNAL(signalClearProgressBar()),this,TQT_SLOT(clearProgressBar()));
+ connect(catalog,TQT_SIGNAL(signalResetProgressBar(TQString,int))
+ ,this,TQT_SLOT(prepareProgressBar(TQString,int)));
+ connect(catalog,TQT_SIGNAL(signalFileOpened(bool)),this,TQT_SLOT(enableDefaults(bool)));
+ connect(catalog,TQT_SIGNAL(signalFileOpened(bool)),m_view,TQT_SLOT(newFileOpened(bool)));
+ connect(catalog,TQT_SIGNAL(signalModified(bool)),this,TQT_SLOT(showModified(bool)));
// allow the view to change the statusbar and caption
- connect(m_view, SIGNAL(signalChangeStatusbar(const QString&)),
- this, SLOT(changeStatusbar(const QString&)));
- connect(m_view, SIGNAL(signalChangeCaption(const QString&)),
- this, SLOT(changeCaption(const QString&)));
- connect(m_view,SIGNAL(signalFirstDisplayed(bool, bool)),this
- ,SLOT(firstEntryDisplayed(bool, bool)));
- connect(m_view,SIGNAL(signalLastDisplayed(bool, bool)),this
- ,SLOT(lastEntryDisplayed(bool, bool)));
- connect(m_view,SIGNAL(signalFuzzyDisplayed(bool)),this
- ,SLOT(fuzzyDisplayed(bool)));
- connect(m_view,SIGNAL(signalUntranslatedDisplayed(bool)),this
- ,SLOT(untranslatedDisplayed(bool)));
- connect(m_view,SIGNAL(signalFaultyDisplayed(bool)),this
- ,SLOT(faultyDisplayed(bool)));
- connect(m_view,SIGNAL(signalDisplayed(const KBabel::DocPosition&)),this
- ,SLOT(displayedEntryChanged(const KBabel::DocPosition&)));
- connect(m_view,SIGNAL(signalFuzzyAfterwards(bool)),this
- ,SLOT(hasFuzzyAfterwards(bool)));
- connect(m_view,SIGNAL(signalFuzzyInFront(bool)),this
- ,SLOT(hasFuzzyInFront(bool)));
- connect(m_view,SIGNAL(signalUntranslatedAfterwards(bool)),this
- ,SLOT(hasUntranslatedAfterwards(bool)));
- connect(m_view,SIGNAL(signalUntranslatedInFront(bool)),this
- ,SLOT(hasUntranslatedInFront(bool)));
- connect(m_view,SIGNAL(signalErrorAfterwards(bool)),this
- ,SLOT(hasErrorAfterwards(bool)));
- connect(m_view,SIGNAL(signalErrorInFront(bool)),this
- ,SLOT(hasErrorInFront(bool)));
- connect(m_view,SIGNAL(signalBackHistory(bool)),this
- ,SLOT(enableBackHistory(bool)));
- connect(m_view,SIGNAL(signalForwardHistory(bool)),this
- ,SLOT(enableForwardHistory(bool)));
-
-
- connect(m_view,SIGNAL(ledColorChanged(const QColor&)),this
- ,SLOT(setLedColor(const QColor&)));
-
-
- connect(m_view,SIGNAL(signalSearchActive(bool)),this,SLOT(enableStop(bool)));
-
- connect(m_view,SIGNAL(signalProgress(int)),_progressBar,SLOT(setProgress(int)));
- connect(m_view,SIGNAL(signalClearProgressBar()),this,SLOT(clearProgressBar()));
- connect(m_view,SIGNAL(signalResetProgressBar(QString,int))
- ,this,SLOT(prepareProgressBar(QString,int)));
-
- connect(m_view,SIGNAL(signalDictionariesChanged())
- , this, SLOT(buildDictMenus()));
- connect(m_view,SIGNAL(signalCursorPosChanged(int,int)), this
- , SLOT(updateCursorPosition(int,int)));
+ connect(m_view, TQT_SIGNAL(signalChangeStatusbar(const TQString&)),
+ this, TQT_SLOT(changeStatusbar(const TQString&)));
+ connect(m_view, TQT_SIGNAL(signalChangeCaption(const TQString&)),
+ this, TQT_SLOT(changeCaption(const TQString&)));
+ connect(m_view,TQT_SIGNAL(signalFirstDisplayed(bool, bool)),this
+ ,TQT_SLOT(firstEntryDisplayed(bool, bool)));
+ connect(m_view,TQT_SIGNAL(signalLastDisplayed(bool, bool)),this
+ ,TQT_SLOT(lastEntryDisplayed(bool, bool)));
+ connect(m_view,TQT_SIGNAL(signalFuzzyDisplayed(bool)),this
+ ,TQT_SLOT(fuzzyDisplayed(bool)));
+ connect(m_view,TQT_SIGNAL(signalUntranslatedDisplayed(bool)),this
+ ,TQT_SLOT(untranslatedDisplayed(bool)));
+ connect(m_view,TQT_SIGNAL(signalFaultyDisplayed(bool)),this
+ ,TQT_SLOT(faultyDisplayed(bool)));
+ connect(m_view,TQT_SIGNAL(signalDisplayed(const KBabel::DocPosition&)),this
+ ,TQT_SLOT(displayedEntryChanged(const KBabel::DocPosition&)));
+ connect(m_view,TQT_SIGNAL(signalFuzzyAfterwards(bool)),this
+ ,TQT_SLOT(hasFuzzyAfterwards(bool)));
+ connect(m_view,TQT_SIGNAL(signalFuzzyInFront(bool)),this
+ ,TQT_SLOT(hasFuzzyInFront(bool)));
+ connect(m_view,TQT_SIGNAL(signalUntranslatedAfterwards(bool)),this
+ ,TQT_SLOT(hasUntranslatedAfterwards(bool)));
+ connect(m_view,TQT_SIGNAL(signalUntranslatedInFront(bool)),this
+ ,TQT_SLOT(hasUntranslatedInFront(bool)));
+ connect(m_view,TQT_SIGNAL(signalErrorAfterwards(bool)),this
+ ,TQT_SLOT(hasErrorAfterwards(bool)));
+ connect(m_view,TQT_SIGNAL(signalErrorInFront(bool)),this
+ ,TQT_SLOT(hasErrorInFront(bool)));
+ connect(m_view,TQT_SIGNAL(signalBackHistory(bool)),this
+ ,TQT_SLOT(enableBackHistory(bool)));
+ connect(m_view,TQT_SIGNAL(signalForwardHistory(bool)),this
+ ,TQT_SLOT(enableForwardHistory(bool)));
+
+
+ connect(m_view,TQT_SIGNAL(ledColorChanged(const TQColor&)),this
+ ,TQT_SLOT(setLedColor(const TQColor&)));
+
+
+ connect(m_view,TQT_SIGNAL(signalSearchActive(bool)),this,TQT_SLOT(enableStop(bool)));
+
+ connect(m_view,TQT_SIGNAL(signalProgress(int)),_progressBar,TQT_SLOT(setProgress(int)));
+ connect(m_view,TQT_SIGNAL(signalClearProgressBar()),this,TQT_SLOT(clearProgressBar()));
+ connect(m_view,TQT_SIGNAL(signalResetProgressBar(TQString,int))
+ ,this,TQT_SLOT(prepareProgressBar(TQString,int)));
+
+ connect(m_view,TQT_SIGNAL(signalDictionariesChanged())
+ , this, TQT_SLOT(buildDictMenus()));
+ connect(m_view,TQT_SIGNAL(signalCursorPosChanged(int,int)), this
+ , TQT_SLOT(updateCursorPosition(int,int)));
if(!catalog->currentURL().isEmpty())
{
@@ -292,18 +292,18 @@ void KBabelMW::init(KBCatalog* catalog)
mailer = new KBabelMailer( this, _project );
- bmHandler = new KBabelBookmarkHandler((QPopupMenu*)factory()->container("bookmark", this));
+ bmHandler = new KBabelBookmarkHandler((TQPopupMenu*)factory()->container("bookmark", this));
// the earlier created KAction for "clear_bookmarks" is now reconnected
KAction* action = actionCollection()->action("clear_bookmarks");
if (action) {
- action->disconnect(SIGNAL(activated()));
- connect(action, SIGNAL(activated()),
- bmHandler, SLOT(slotClearBookmarks()));
+ action->disconnect(TQT_SIGNAL(activated()));
+ connect(action, TQT_SIGNAL(activated()),
+ bmHandler, TQT_SLOT(slotClearBookmarks()));
}
- connect(bmHandler, SIGNAL(signalBookmarkSelected(int)),
- this, SLOT(slotOpenBookmark(int)));
- connect(m_view, SIGNAL(signalNewFileOpened(KURL)),
- bmHandler, SLOT(slotClearBookmarks()));
+ connect(bmHandler, TQT_SIGNAL(signalBookmarkSelected(int)),
+ this, TQT_SLOT(slotOpenBookmark(int)));
+ connect(m_view, TQT_SIGNAL(signalNewFileOpened(KURL)),
+ bmHandler, TQT_SLOT(slotClearBookmarks()));
_config = KSharedConfig::openConfig( "kbabelrc" );
restoreSettings();
@@ -312,17 +312,17 @@ void KBabelMW::init(KBCatalog* catalog)
if(!_config->hasKey("Version"))
{
- QString encodingStr;
+ TQString encodingStr;
switch(catalog->saveSettings().encoding)
{
case KBabel::ProjectSettingsBase::UTF8:
- encodingStr=QTextCodec::codecForName("UTF-8")->name();
+ encodingStr=TQTextCodec::codecForName("UTF-8")->name();
break;
case KBabel::ProjectSettingsBase::UTF16:
- encodingStr=QTextCodec::codecForName("UTF-16")->name();
+ encodingStr=TQTextCodec::codecForName("UTF-16")->name();
break;
default:
- encodingStr=QTextCodec::codecForLocale()->name();
+ encodingStr=TQTextCodec::codecForLocale()->name();
}
if( KBabelSplash::instance ) KBabelSplash::instance->close(); //close splash screen window, if there is one
@@ -335,7 +335,7 @@ void KBabelMW::init(KBCatalog* catalog)
"set to %1. You may want to change this setting "
"according to the settings of your language team.").arg(encodingStr));
- QTimer::singleShot(1,this,SLOT(projectConfigure()));
+ TQTimer::singleShot(1,this,TQT_SLOT(projectConfigure()));
}
_config->writeEntry("Version",VERSION);
@@ -404,296 +404,296 @@ void KBabelMW::setupActions()
KAction* action;
// the file menu
- action = KStdAction::open(this, SLOT(fileOpen()), actionCollection());
+ action = KStdAction::open(this, TQT_SLOT(fileOpen()), actionCollection());
- a_recent = KStdAction::openRecent(this, SLOT(openRecent(const KURL&)), actionCollection());
+ a_recent = KStdAction::openRecent(this, TQT_SLOT(openRecent(const KURL&)), actionCollection());
a_recent->setMaxItems(MAX_RECENT);
- action = KStdAction::revert(m_view,SLOT(revertToSaved()),actionCollection());
- action=KStdAction::save(this, SLOT(fileSave()), actionCollection());
- action = KStdAction::saveAs(this, SLOT(fileSaveAs()), actionCollection());
- action = new KAction(i18n("Save Sp&ecial..."), 0, this, SLOT(fileSaveSpecial()),
+ action = KStdAction::revert(m_view,TQT_SLOT(revertToSaved()),actionCollection());
+ action=KStdAction::save(this, TQT_SLOT(fileSave()), actionCollection());
+ action = KStdAction::saveAs(this, TQT_SLOT(fileSaveAs()), actionCollection());
+ action = new KAction(i18n("Save Sp&ecial..."), 0, this, TQT_SLOT(fileSaveSpecial()),
actionCollection(), "save_special" );
- action = new KAction(i18n("Set &Package..."), 0, m_view, SLOT(setFilePackage()),
+ action = new KAction(i18n("Set &Package..."), 0, m_view, TQT_SLOT(setFilePackage()),
actionCollection(), "set_package" );
- action = KStdAction::mail(this, SLOT(fileMail()), actionCollection());
+ action = KStdAction::mail(this, TQT_SLOT(fileMail()), actionCollection());
- action = new KAction(i18n("&New View"), 0, this, SLOT(fileNewView()),
+ action = new KAction(i18n("&New View"), 0, this, TQT_SLOT(fileNewView()),
actionCollection(), "file_new_view");
- action = new KAction(i18n("New &Window"), 0, this, SLOT(fileNewWindow()),
+ action = new KAction(i18n("New &Window"), 0, this, TQT_SLOT(fileNewWindow()),
actionCollection(), "file_new_window");
action->setShortcut( KStdAccel::openNew() );
- action = KStdAction::quit(this, SLOT(quit()), actionCollection());
+ action = KStdAction::quit(this, TQT_SLOT(quit()), actionCollection());
// the edit menu
- action = KStdAction::undo(m_view, SLOT(undo()), actionCollection());
- action = KStdAction::redo(m_view, SLOT(redo()), actionCollection());
- action = KStdAction::cut(m_view, SIGNAL(signalCut()), actionCollection());
- action = KStdAction::copy(m_view, SIGNAL(signalCopy()), actionCollection());
- action = KStdAction::paste(m_view, SIGNAL(signalPaste()), actionCollection());
- action = KStdAction::selectAll(m_view, SIGNAL(signalSelectAll()), actionCollection());
- action = KStdAction::find(m_view, SLOT(find()), actionCollection());
- action = KStdAction::findNext(m_view, SLOT(findNext()), actionCollection());
- action = KStdAction::findPrev(m_view, SLOT(findPrev()), actionCollection());
- action = KStdAction::replace(m_view, SLOT(replace()), actionCollection());
-
- action = KStdAction::clear( m_view, SLOT(clear()), actionCollection(), "clear" );
+ action = KStdAction::undo(m_view, TQT_SLOT(undo()), actionCollection());
+ action = KStdAction::redo(m_view, TQT_SLOT(redo()), actionCollection());
+ action = KStdAction::cut(m_view, TQT_SIGNAL(signalCut()), actionCollection());
+ action = KStdAction::copy(m_view, TQT_SIGNAL(signalCopy()), actionCollection());
+ action = KStdAction::paste(m_view, TQT_SIGNAL(signalPaste()), actionCollection());
+ action = KStdAction::selectAll(m_view, TQT_SIGNAL(signalSelectAll()), actionCollection());
+ action = KStdAction::find(m_view, TQT_SLOT(find()), actionCollection());
+ action = KStdAction::findNext(m_view, TQT_SLOT(findNext()), actionCollection());
+ action = KStdAction::findPrev(m_view, TQT_SLOT(findPrev()), actionCollection());
+ action = KStdAction::replace(m_view, TQT_SLOT(replace()), actionCollection());
+
+ action = KStdAction::clear( m_view, TQT_SLOT(clear()), actionCollection(), "clear" );
action = new KAction(i18n("Cop&y Msgid to Msgstr"), "msgid2msgstr", CTRL+Key_Space, m_view
- ,SLOT(msgid2msgstr()), actionCollection(), "msgid2msgstr");
+ ,TQT_SLOT(msgid2msgstr()), actionCollection(), "msgid2msgstr");
action = new KAction(i18n("Copy Searc&h Result to Msgstr"), "search2msgstr",
- CTRL+ALT+Key_Space, m_view, SLOT(search2msgstr()),
+ CTRL+ALT+Key_Space, m_view, TQT_SLOT(search2msgstr()),
actionCollection(), "search2msgstr");
action = new KAction(i18n("Copy Msgstr to Other &Plurals"), Key_F11, m_view
- ,SLOT(plural2msgstr()), actionCollection(), "plural2msgstr");
+ ,TQT_SLOT(plural2msgstr()), actionCollection(), "plural2msgstr");
action = new KAction(i18n("Copy Selected Character to Msgstr"), Key_F10, m_charselectorview
- ,SLOT(emitChar()), actionCollection(), "char2msgstr");
+ ,TQT_SLOT(emitChar()), actionCollection(), "char2msgstr");
a_unsetFuzzy = new KAction(i18n("To&ggle Fuzzy Status"), "togglefuzzy", CTRL+Key_U, m_view
- , SLOT(removeFuzzyStatus()), actionCollection(), "edit_toggle_fuzzy");
- action = new KAction(i18n("&Edit Header..."), 0, m_view, SLOT(editHeader()),
+ , TQT_SLOT(removeFuzzyStatus()), actionCollection(), "edit_toggle_fuzzy");
+ action = new KAction(i18n("&Edit Header..."), 0, m_view, TQT_SLOT(editHeader()),
actionCollection(), "edit_edit_header");
action = new KAction(i18n("&Insert Next Tag"), "insert_tag", CTRL+ALT+Key_N
- , m_view, SLOT(insertNextTag())
+ , m_view, TQT_SLOT(insertNextTag())
, actionCollection(),"insert_next_tag");
- connect(m_view,SIGNAL(signalNextTagAvailable(bool)),action
- ,SLOT(setEnabled(bool)));
+ connect(m_view,TQT_SIGNAL(signalNextTagAvailable(bool)),action
+ ,TQT_SLOT(setEnabled(bool)));
action = new KAction(i18n("Insert Next Tag From Msgid P&osition"), "insert_tag", CTRL+Key_M
- , m_view, SLOT(insertNextTagMsgid())
+ , m_view, TQT_SLOT(insertNextTagMsgid())
, actionCollection(),"insert_next_tag_msgid");
- connect(m_view,SIGNAL(signalNextTagAvailable(bool)),action
- ,SLOT(setEnabled(bool)));
+ connect(m_view,TQT_SIGNAL(signalNextTagAvailable(bool)),action
+ ,TQT_SLOT(setEnabled(bool)));
KActionMenu *actionMenu= new KActionMenu(i18n("Inser&t Tag"), "insert_tag"
, actionCollection(),"insert_tag");
m_view->setTagsMenu(actionMenu->popupMenu());
- connect(m_view,SIGNAL(signalTagsAvailable(bool)),actionMenu
- ,SLOT(setEnabled(bool)));
- connect(actionMenu,SIGNAL(activated()),m_view,SLOT(insertNextTag()));
+ connect(m_view,TQT_SIGNAL(signalTagsAvailable(bool)),actionMenu
+ ,TQT_SLOT(setEnabled(bool)));
+ connect(actionMenu,TQT_SIGNAL(activated()),m_view,TQT_SLOT(insertNextTag()));
action = new KAction(i18n("Show Tags Menu"),CTRL+Key_Less
- , m_view, SLOT(showTagsMenu()), actionCollection(),"show_tags_menu");
+ , m_view, TQT_SLOT(showTagsMenu()), actionCollection(),"show_tags_menu");
action->setEnabled(false);
- connect(m_view,SIGNAL(signalTagsAvailable(bool)),action
- ,SLOT(setEnabled(bool)));
+ connect(m_view,TQT_SIGNAL(signalTagsAvailable(bool)),action
+ ,TQT_SLOT(setEnabled(bool)));
action = new KAction(i18n("Move to Next Tag"), 0, CTRL+ALT+Key_M
- , m_view, SLOT(skipToNextTag())
+ , m_view, TQT_SLOT(skipToNextTag())
, actionCollection(),"move_to_next_tag");
action = new KAction(i18n("Move to Previous Tag"), 0, CTRL+ALT+Key_B
- , m_view, SLOT(skipToPreviousTag())
+ , m_view, TQT_SLOT(skipToPreviousTag())
, actionCollection(),"move_to_prev_tag");
action = new KAction(i18n("Insert Next Argument"), "insert_arg", CTRL+ALT+Key_G
- , m_view, SLOT(insertNextArg())
+ , m_view, TQT_SLOT(insertNextArg())
, actionCollection(),"insert_next_arg");
- connect(m_view,SIGNAL(signalNextArgAvailable(bool)),action
- ,SLOT(setEnabled(bool)));
+ connect(m_view,TQT_SIGNAL(signalNextArgAvailable(bool)),action
+ ,TQT_SLOT(setEnabled(bool)));
actionMenu= new KActionMenu(i18n("Inser&t Argument"), "insert_arg"
, actionCollection(),"insert_arg");
m_view->setArgsMenu(actionMenu->popupMenu());
- connect(m_view,SIGNAL(signalArgsAvailable(bool)),actionMenu
- ,SLOT(setEnabled(bool)));
- connect(actionMenu,SIGNAL(activated()),m_view,SLOT(insertNextArg()));
+ connect(m_view,TQT_SIGNAL(signalArgsAvailable(bool)),actionMenu
+ ,TQT_SLOT(setEnabled(bool)));
+ connect(actionMenu,TQT_SIGNAL(activated()),m_view,TQT_SLOT(insertNextArg()));
action = new KAction(i18n("Show Arguments Menu"),CTRL+Key_Percent
- , m_view, SLOT(showArgsMenu()), actionCollection(),"show_args_menu");
+ , m_view, TQT_SLOT(showArgsMenu()), actionCollection(),"show_args_menu");
action->setEnabled(false);
- connect(m_view,SIGNAL(signalArgsAvailable(bool)),action
- ,SLOT(setEnabled(bool)));
+ connect(m_view,TQT_SIGNAL(signalArgsAvailable(bool)),action
+ ,TQT_SLOT(setEnabled(bool)));
// next, the go-menu
action = new KAction(i18n("&Previous"), "previous",
- KStdAccel::shortcut(KStdAccel::Prior), m_view , SLOT(gotoPrev()),
+ KStdAccel::shortcut(KStdAccel::Prior), m_view , TQT_SLOT(gotoPrev()),
actionCollection(),"go_prev_entry");
action = new KAction(i18n("&Next"), "next",
- KStdAccel::shortcut(KStdAccel::Next), m_view , SLOT(gotoNext()),
+ KStdAccel::shortcut(KStdAccel::Next), m_view , TQT_SLOT(gotoNext()),
actionCollection(),"go_next_entry");
- action = KStdAction::goTo(m_view, SLOT(gotoEntry()), actionCollection());
+ action = KStdAction::goTo(m_view, TQT_SLOT(gotoEntry()), actionCollection());
action->setShortcut( KStdAccel::gotoLine());
- action = KStdAction::firstPage(m_view, SLOT(gotoFirst()),actionCollection());
+ action = KStdAction::firstPage(m_view, TQT_SLOT(gotoFirst()),actionCollection());
action->setText(i18n("&First Entry"));
action->setShortcut(CTRL+ALT+Key_Home);
- action = KStdAction::lastPage(m_view, SLOT(gotoLast()),actionCollection());
+ action = KStdAction::lastPage(m_view, TQT_SLOT(gotoLast()),actionCollection());
action->setText(i18n("&Last Entry"));
action->setShortcut(CTRL+ALT+Key_End);
a_prevFoU = new KAction(i18n("P&revious Fuzzy or Untranslated"),"prevfuzzyuntrans",
CTRL+SHIFT+Key_Prior, m_view,
- SLOT(gotoPrevFuzzyOrUntrans()),actionCollection(), "go_prev_fuzzyUntr");
+ TQT_SLOT(gotoPrevFuzzyOrUntrans()),actionCollection(), "go_prev_fuzzyUntr");
a_nextFoU = new KAction(i18n("N&ext Fuzzy or Untranslated"),"nextfuzzyuntrans",
CTRL+SHIFT+Key_Next, m_view,
- SLOT(gotoNextFuzzyOrUntrans()),actionCollection(), "go_next_fuzzyUntr");
+ TQT_SLOT(gotoNextFuzzyOrUntrans()),actionCollection(), "go_next_fuzzyUntr");
a_prevFuzzy = new KAction(i18n("Pre&vious Fuzzy"),"prevfuzzy",
CTRL+Key_Prior, m_view,
- SLOT(gotoPrevFuzzy()),actionCollection(), "go_prev_fuzzy");
+ TQT_SLOT(gotoPrevFuzzy()),actionCollection(), "go_prev_fuzzy");
a_nextFuzzy = new KAction(i18n("Ne&xt Fuzzy"), "nextfuzzy",
CTRL+Key_Next, m_view,
- SLOT(gotoNextFuzzy()),actionCollection(), "go_next_fuzzy");
+ TQT_SLOT(gotoNextFuzzy()),actionCollection(), "go_next_fuzzy");
a_prevUntrans = new KAction(i18n("Prev&ious Untranslated"), "prevuntranslated",
ALT+Key_Prior, m_view,
- SLOT(gotoPrevUntranslated()),actionCollection(), "go_prev_untrans");
+ TQT_SLOT(gotoPrevUntranslated()),actionCollection(), "go_prev_untrans");
a_nextUntrans = new KAction(i18n("Nex&t Untranslated"), "nextuntranslated",
ALT+Key_Next, m_view,
- SLOT(gotoNextUntranslated()),actionCollection(), "go_next_untrans");
+ TQT_SLOT(gotoNextUntranslated()),actionCollection(), "go_next_untrans");
action = new KAction(i18n("Previo&us Error"), "preverror",
SHIFT+Key_Prior, m_view,
- SLOT(gotoPrevError()),actionCollection(), "go_prev_error");
+ TQT_SLOT(gotoPrevError()),actionCollection(), "go_prev_error");
action = new KAction(i18n("Next Err&or"), "nexterror",
SHIFT+Key_Next, m_view,
- SLOT(gotoNextError()),actionCollection(), "go_next_error");
+ TQT_SLOT(gotoNextError()),actionCollection(), "go_next_error");
action = new KAction(i18n("&Back in History"), "back", ALT+Key_Left, m_view,
- SLOT(backHistory()),actionCollection(), "go_back_history");
+ TQT_SLOT(backHistory()),actionCollection(), "go_back_history");
action = new KAction(i18n("For&ward in History"), "forward", ALT+Key_Right, m_view,
- SLOT(forwardHistory()),actionCollection(), "go_forward_history");
+ TQT_SLOT(forwardHistory()),actionCollection(), "go_forward_history");
// the search menu
actionMenu=new KActionMenu(i18n("&Find Text"),
"transsearch",actionCollection(),"dict_search_all");
- connect(actionMenu,SIGNAL(activated()),m_view,SLOT(startSearch()));
+ connect(actionMenu,TQT_SIGNAL(activated()),m_view,TQT_SLOT(startSearch()));
dictMenu = new DictionaryMenu(actionMenu->popupMenu(),actionCollection(),this);
- connect(dictMenu,SIGNAL(activated(const QString)), m_view
- , SLOT(startSearch(const QString)));
+ connect(dictMenu,TQT_SIGNAL(activated(const TQString)), m_view
+ , TQT_SLOT(startSearch(const TQString)));
actionMenu=new KActionMenu(i18n("F&ind Selected Text"),
"transsearch",actionCollection(),"dict_search_selected");
- connect(actionMenu,SIGNAL(activated()),m_view,SLOT(startSelectionSearch()));
+ connect(actionMenu,TQT_SIGNAL(activated()),m_view,TQT_SLOT(startSelectionSearch()));
selectionDictMenu = new DictionaryMenu(actionMenu->popupMenu(),actionCollection(),this);
- connect(selectionDictMenu,SIGNAL(activated(const QString)), m_view
- , SLOT(startSelectionSearch(const QString)));
+ connect(selectionDictMenu,TQT_SIGNAL(activated(const TQString)), m_view
+ , TQT_SLOT(startSelectionSearch(const TQString)));
actionMenu=new KActionMenu(i18n("&Edit Dictionary"),
"transsearch",actionCollection(),"dict_edit");
editDictMenu = new DictionaryMenu(actionMenu->popupMenu(),actionCollection(),this);
- connect(editDictMenu,SIGNAL(activated(const QString)), m_view
- , SLOT(editDictionary(const QString)));
+ connect(editDictMenu,TQT_SIGNAL(activated(const TQString)), m_view
+ , TQT_SLOT(editDictionary(const TQString)));
actionMenu=new KActionMenu(i18n("Con&figure Dictionary"),
"transsearch",actionCollection(),"dict_configure");
configDictMenu = new DictionaryMenu(actionMenu->popupMenu(),actionCollection(),this);
- connect(configDictMenu,SIGNAL(activated(const QString)), m_view
- , SLOT(configureDictionary(const QString)));
+ connect(configDictMenu,TQT_SIGNAL(activated(const TQString)), m_view
+ , TQT_SLOT(configureDictionary(const TQString)));
actionMenu=new KActionMenu(i18n("About Dictionary"), "transsearch",
actionCollection(), "dict_about");
aboutDictMenu = new DictionaryMenu(actionMenu->popupMenu(),actionCollection(),this);
- connect(aboutDictMenu,SIGNAL(activated(const QString)), m_view
- , SLOT(aboutDictionary(const QString)));
+ connect(aboutDictMenu,TQT_SIGNAL(activated(const TQString)), m_view
+ , TQT_SLOT(aboutDictionary(const TQString)));
buildDictMenus();
// the project menu
action = new KAction(i18n("&New..."), "filenew"
- , this, SLOT(projectNew()),actionCollection()
+ , this, TQT_SLOT(projectNew()),actionCollection()
,"project_new");
action = new KAction(i18n("&Open..."), "fileopen"
- , this, SLOT(projectOpen()),actionCollection()
+ , this, TQT_SLOT(projectOpen()),actionCollection()
,"project_open");
action = new KAction(i18n("C&lose"), "fileclose"
- , this, SLOT(projectClose()),actionCollection()
+ , this, TQT_SLOT(projectClose()),actionCollection()
,"project_close");
action->setEnabled (_project->filename() != KBabel::ProjectManager::defaultProjectName() );
action = new KAction(i18n("&Configure..."), "configure"
- , this, SLOT(projectConfigure()),actionCollection()
+ , this, TQT_SLOT(projectConfigure()),actionCollection()
,"project_settings");
- a_recentprojects = new KRecentFilesAction(i18n("Open &Recent"), 0, this, SLOT(projectOpenRecent(const KURL&)), actionCollection(), "recent_projects");
+ a_recentprojects = new KRecentFilesAction(i18n("Open &Recent"), 0, this, TQT_SLOT(projectOpenRecent(const KURL&)), actionCollection(), "recent_projects");
// the tools menu
action = new KAction(i18n("&Spell Check..."), "spellcheck", CTRL+Key_I
- , m_view, SLOT(spellcheckCommon()),actionCollection()
+ , m_view, TQT_SLOT(spellcheckCommon()),actionCollection()
,"spellcheck_common");
action = new KAction(i18n("&Check All..."), "spellcheck_all", 0
- , m_view, SLOT(spellcheckAll()),actionCollection()
+ , m_view, TQT_SLOT(spellcheckAll()),actionCollection()
,"spellcheck_all");
action = new KAction(i18n("C&heck From Cursor Position..."), "spellcheck_from_cursor", 0
- , m_view, SLOT(spellcheckFromCursor()),actionCollection()
+ , m_view, TQT_SLOT(spellcheckFromCursor()),actionCollection()
,"spellcheck_from_cursor");
action = new KAction(i18n("Ch&eck Current..."), "spellcheck_actual", 0
- , m_view, SLOT(spellcheckCurrent()),actionCollection()
+ , m_view, TQT_SLOT(spellcheckCurrent()),actionCollection()
,"spellcheck_current");
action = new KAction(i18n("Check Fro&m Current to End of File..."), 0
- , m_view, SLOT(spellcheckFromCurrent()),actionCollection()
+ , m_view, TQT_SLOT(spellcheckFromCurrent()),actionCollection()
,"spellcheck_from_current");
action = new KAction(i18n("Chec&k Selected Text..."), "spellcheck_selected", 0
- , m_view, SLOT(spellcheckMarked()),actionCollection()
+ , m_view, TQT_SLOT(spellcheckMarked()),actionCollection()
,"spellcheck_marked");
KToggleAction *toggleAction;
toggleAction = new KToggleAction(i18n("&Diffmode"), "autodiff", 0
,actionCollection(), "diff_toggleDiff");
- connect(toggleAction,SIGNAL(toggled(bool)), m_view, SLOT(toggleAutoDiff(bool)));
- connect(m_view,SIGNAL(signalDiffEnabled(bool)), toggleAction
- , SLOT(setChecked(bool)));
+ connect(toggleAction,TQT_SIGNAL(toggled(bool)), m_view, TQT_SLOT(toggleAutoDiff(bool)));
+ connect(m_view,TQT_SIGNAL(signalDiffEnabled(bool)), toggleAction
+ , TQT_SLOT(setChecked(bool)));
toggleAction->setChecked(m_view->autoDiffEnabled());
action = new KAction(i18n("&Show Diff"), "diff", Key_F5
- , m_view, SLOT(diff()),actionCollection()
+ , m_view, TQT_SLOT(diff()),actionCollection()
,"diff_diff");
action = new KAction(i18n("S&how Original Text"), "contents", Key_F6
- , m_view, SLOT(diffShowOrig()),actionCollection()
+ , m_view, TQT_SLOT(diffShowOrig()),actionCollection()
,"diff_showOrig");
action = new KAction(i18n("&Open File for Diff"), "fileopen" ,0
- , m_view, SLOT(openDiffFile()),actionCollection()
+ , m_view, TQT_SLOT(openDiffFile()),actionCollection()
,"diff_openFile");
action = new KAction(i18n("&Rough Translation..."), 0
- , m_view, SLOT(roughTranslation()),actionCollection()
+ , m_view, TQT_SLOT(roughTranslation()),actionCollection()
,"rough_translation");
action = new KAction(i18n("&Catalog Manager..."),"catalogmanager", 0 , this,
- SLOT(openCatalogManager()),actionCollection(), "open_catalog_manager");
+ TQT_SLOT(openCatalogManager()),actionCollection(), "open_catalog_manager");
- new KAction( i18n("Toggle Edit Mode"), 0, Key_Insert,this,SLOT(toggleEditMode()), actionCollection(), "toggle_insert_mode");
+ new KAction( i18n("Toggle Edit Mode"), 0, Key_Insert,this,TQT_SLOT(toggleEditMode()), actionCollection(), "toggle_insert_mode");
- new KAction( i18n("&Word Count"), 0, m_view, SLOT(wordCount()), actionCollection(), "word_count");
+ new KAction( i18n("&Word Count"), 0, m_view, TQT_SLOT(wordCount()), actionCollection(), "word_count");
// next, the settings menu
createStandardStatusBarAction();
- KStdAction::configureToolbars(this,SLOT(optionsEditToolbars()),actionCollection());
+ KStdAction::configureToolbars(this,TQT_SLOT(optionsEditToolbars()),actionCollection());
- KStdAction::keyBindings(guiFactory(),SLOT(configureShortcuts()),actionCollection());
- KStdAction::preferences(this,SLOT(optionsPreferences()),actionCollection());
+ KStdAction::keyBindings(guiFactory(),TQT_SLOT(configureShortcuts()),actionCollection());
+ KStdAction::preferences(this,TQT_SLOT(optionsPreferences()),actionCollection());
setStandardToolBarMenuEnabled ( true );
action = new KAction(i18n("&Stop Searching"), "stop",Key_Escape, m_view,
- SLOT(stopSearch()),actionCollection(), "stop_search");
+ TQT_SLOT(stopSearch()),actionCollection(), "stop_search");
action->setEnabled(false);
new KAction(i18n("&Gettext Info"), 0, this,
- SLOT(gettextHelp()), actionCollection(), "help_gettext");
+ TQT_SLOT(gettextHelp()), actionCollection(), "help_gettext");
// the bookmarks menu
- action = KStdAction::addBookmark(this, SLOT(slotAddBookmark()),
+ action = KStdAction::addBookmark(this, TQT_SLOT(slotAddBookmark()),
actionCollection(), "add_bookmark");
action->setEnabled(false);
// this action is now connected to dummySlot(), and later reconnected
// to bmHandler after that object actually is created
- new KAction(i18n("Clear Bookmarks"), 0, this, SLOT(dummySlot()),
+ new KAction(i18n("Clear Bookmarks"), 0, this, TQT_SLOT(dummySlot()),
actionCollection(), "clear_bookmarks");
setupDynamicActions();
createGUI(0);
- QPopupMenu *popup = static_cast<QPopupMenu*>(factory()->container("settings",this));
+ TQPopupMenu *popup = static_cast<TQPopupMenu*>(factory()->container("settings",this));
popup->insertItem( i18n("&Views"), dockHideShowMenu(), -1, 0 );
}
@@ -707,22 +707,22 @@ void KBabelMW::setupStatusBar()
if(KBabelSettings::ledInStatusbar())
{
- QColor ledColor=KBabelSettings::ledColor();
- QHBox* statusBox = new QHBox(statusBar(),"statusBox");
+ TQColor ledColor=KBabelSettings::ledColor();
+ TQHBox* statusBox = new TQHBox(statusBar(),"statusBox");
statusBox->setSpacing(2);
- new QLabel(" "+i18n("Status: "),statusBox);
+ new TQLabel(" "+i18n("Status: "),statusBox);
_fuzzyLed = new KLed(ledColor,KLed::Off,KLed::Sunken,KLed::Rectangular
,statusBox);
_fuzzyLed->setFixedSize(15,12);
- new QLabel(i18n("fuzzy")+" ",statusBox);
+ new TQLabel(i18n("fuzzy")+" ",statusBox);
_untransLed = new KLed(ledColor,KLed::Off,KLed::Sunken,KLed::Rectangular
,statusBox);
_untransLed->setFixedSize(15,12);
- new QLabel(i18n("untranslated")+" ",statusBox);
+ new TQLabel(i18n("untranslated")+" ",statusBox);
_errorLed = new KLed(ledColor,KLed::Off,KLed::Sunken,KLed::Rectangular
,statusBox);
_errorLed->setFixedSize(15,12);
- new QLabel(i18n("faulty")+" ",statusBox);
+ new TQLabel(i18n("faulty")+" ",statusBox);
statusBox->setFixedWidth(statusBox->sizeHint().width());
statusBar()->addWidget(statusBox);
@@ -735,7 +735,7 @@ void KBabelMW::setupStatusBar()
statusBar()->insertItem(i18n("Line: %1 Col: %2").arg(1).arg(1)
,ID_STATUS_CURSOR);
- QHBox* progressBox = new QHBox(statusBar(),"progressBox");
+ TQHBox* progressBox = new TQHBox(statusBar(),"progressBox");
progressBox->setSpacing(2);
_progressLabel = new KSqueezedTextLabel( "", progressBox );
_progressBar=new MyKProgress(progressBox,"progressbar");
@@ -745,7 +745,7 @@ void KBabelMW::setupStatusBar()
statusBar()->addWidget(progressBox,1);
statusBar()->setMinimumHeight(progressBox->sizeHint().height());
- QWhatsThis::add(statusBar(),
+ TQWhatsThis::add(statusBar(),
i18n("<qt><p><b>Statusbar</b></p>\n\
<p>The statusbar displays some information about the opened file,\n\
like the total number of entries and the number of fuzzy and untranslated\n\
@@ -756,23 +756,23 @@ messages. Also the index and the status of the currently displayed entry is show
void KBabelMW::setupDynamicActions()
{
// dynamic validation tools
- QValueList<KDataToolInfo> tools = ToolAction::validationTools();
+ TQValueList<KDataToolInfo> tools = ToolAction::validationTools();
- QPtrList<KAction> actions = ToolAction::dataToolActionList(
- tools, m_view, SLOT(validateUsingTool( const KDataToolInfo &, const QString & )),
+ TQPtrList<KAction> actions = ToolAction::dataToolActionList(
+ tools, m_view, TQT_SLOT(validateUsingTool( const KDataToolInfo &, const TQString & )),
"validate", false, actionCollection() );
KActionMenu* m_menu = new KActionMenu(i18n("&Validation"), actionCollection(), "dynamic_validation_tools");
KAction* ac = new KAction(i18n("Perform &All Checks"), CTRL+Key_E , m_view,
- SLOT(checkAll()),actionCollection(), "check_all");
+ TQT_SLOT(checkAll()),actionCollection(), "check_all");
ac->setEnabled(false);
m_menu->insert(ac);
m_menu->insert( new KActionSeparator() );
ac = new KAction(i18n("C&heck Syntax"), CTRL+Key_T , m_view,
- SLOT(checkSyntax()),actionCollection(), "check_syntax");
+ TQT_SLOT(checkSyntax()),actionCollection(), "check_syntax");
ac->setEnabled(false);
m_menu->insert(ac);
@@ -784,13 +784,13 @@ void KBabelMW::setupDynamicActions()
// dynamic modify tools
// query available tools
- QValueList<KDataToolInfo> allTools = KDataToolInfo::query
+ TQValueList<KDataToolInfo> allTools = KDataToolInfo::query
("CatalogItem", "application/x-kbabel-catalogitem", KGlobal::instance());
// skip read-only tools for single items
- QValueList<KDataToolInfo> modifyTools;
+ TQValueList<KDataToolInfo> modifyTools;
- QValueList<KDataToolInfo>::ConstIterator entry = allTools.begin();
+ TQValueList<KDataToolInfo>::ConstIterator entry = allTools.begin();
for( ; entry != allTools.end(); ++entry )
{
if( !(*entry).isReadOnly() )
@@ -801,7 +801,7 @@ void KBabelMW::setupDynamicActions()
// create corresponding actions
actions = ToolAction::dataToolActionList(
- modifyTools, m_view, SLOT(modifyUsingTool( const KDataToolInfo &, const QString & )),
+ modifyTools, m_view, TQT_SLOT(modifyUsingTool( const KDataToolInfo &, const TQString & )),
"validate", true, actionCollection() );
// skip validation actions
@@ -833,7 +833,7 @@ void KBabelMW::setupDynamicActions()
// create corresponding actions
actions = ToolAction::dataToolActionList(
- modifyTools, m_view, SLOT(modifyUsingTool( const KDataToolInfo &, const QString & )),
+ modifyTools, m_view, TQT_SLOT(modifyUsingTool( const KDataToolInfo &, const TQString & )),
"validate", true, actionCollection() );
// skip validation actions
@@ -844,7 +844,7 @@ void KBabelMW::setupDynamicActions()
// create corresponding actions
actions = ToolAction::dataToolActionList(
- modifyTools, m_view, SLOT(modifyCatalogUsingTool( const KDataToolInfo &, const QString & )),
+ modifyTools, m_view, TQT_SLOT(modifyCatalogUsingTool( const KDataToolInfo &, const TQString & )),
"validate", true, actionCollection() );
// insert tools
@@ -923,7 +923,7 @@ bool KBabelMW::queryClose()
{
if(m_view->isSearching())
{
- connect(m_view,SIGNAL(signalSearchActive(bool)),this,SLOT(quit()));
+ connect(m_view,TQT_SIGNAL(signalSearchActive(bool)),this,TQT_SLOT(quit()));
m_view->stopSearch();
return false;
}
@@ -932,7 +932,7 @@ bool KBabelMW::queryClose()
{
// stop the activity and try again
m_view->catalog()->stop();
- QTimer::singleShot(0, this, SLOT( close() ));
+ TQTimer::singleShot(0, this, TQT_SLOT( close() ));
return false;
}
@@ -973,13 +973,13 @@ void KBabelMW::quit()
}
-void KBabelMW::dragEnterEvent(QDragEnterEvent *event)
+void KBabelMW::dragEnterEvent(TQDragEnterEvent *event)
{
// accept uri drops only
event->accept(KURLDrag::canDecode(event));
}
-void KBabelMW::dropEvent(QDropEvent *event)
+void KBabelMW::dropEvent(TQDropEvent *event)
{
KURL::List uri;
// see if we can decode a URI.. if not, just ignore it
@@ -989,14 +989,14 @@ void KBabelMW::dropEvent(QDropEvent *event)
}
}
-void KBabelMW::wheelEvent(QWheelEvent *e)
+void KBabelMW::wheelEvent(TQWheelEvent *e)
{
m_view->wheelEvent(e);
}
void KBabelMW::openRecent(const KURL& url)
{
- KBabelView *view = KBabelView::viewForURL(url,QString::null);
+ KBabelView *view = KBabelView::viewForURL(url,TQString::null);
if(view)
{
KWin::activateWindow(view->topLevelWidget()->winId());
@@ -1008,10 +1008,10 @@ void KBabelMW::openRecent(const KURL& url)
void KBabelMW::open(const KURL& url)
{
- open(url,QString::null,false);
+ open(url,TQString::null,false);
}
-void KBabelMW::open(const KURL& url, const QString package, bool newWindow)
+void KBabelMW::open(const KURL& url, const TQString package, bool newWindow)
{
kdDebug(KBABEL) << "opening file with project:" << _project->filename() << endl;
kdDebug(KBABEL) << "URL:" << url.prettyURL() << endl;
@@ -1036,7 +1036,7 @@ void KBabelMW::open(const KURL& url, const QString package, bool newWindow)
}
}
-void KBabelMW::openTemplate(const KURL& openURL,const KURL& saveURL,const QString& package, bool newWindow)
+void KBabelMW::openTemplate(const KURL& openURL,const KURL& saveURL,const TQString& package, bool newWindow)
{
if(newWindow)
{
@@ -1067,7 +1067,7 @@ void KBabelMW::addToRecentFiles(KURL url)
void KBabelMW::fileSave()
{
// do it asynchronously due to kdelibs bug
- QTimer::singleShot( 0, this, SLOT( fileSave_internal() ));
+ TQTimer::singleShot( 0, this, TQT_SLOT( fileSave_internal() ));
}
void KBabelMW::fileSave_internal()
@@ -1091,10 +1091,10 @@ void KBabelMW::fileSave_internal()
KURL url=m_view->currentURL();
DCOPClient *client = kapp->dcopClient();
- QByteArray data;
- QDataStream arg(data, IO_WriteOnly);
+ TQByteArray data;
+ TQDataStream arg(data, IO_WriteOnly);
arg << ((url.directory(false)+url.fileName()).utf8()) ;
- if( !client->send( "catalogmanager-*", "CatalogManagerIFace", "updatedFile(QCString)", data ))
+ if( !client->send( "catalogmanager-*", "CatalogManagerIFace", "updatedFile(TQCString)", data ))
kdDebug(KBABEL) << "Unable to send file update info via DCOP" << endl;
// reenable save action
@@ -1108,10 +1108,10 @@ void KBabelMW::fileSaveAs()
KURL url=m_view->currentURL();
DCOPClient *client = kapp->dcopClient();
- QByteArray data;
- QDataStream arg(data, IO_WriteOnly);
+ TQByteArray data;
+ TQDataStream arg(data, IO_WriteOnly);
arg << ((url.directory(false)+url.fileName()).utf8()) ;
- if( !client->send( "catalogmanager-*", "CatalogManagerIFace", "updatedFile(QCString)", data ))
+ if( !client->send( "catalogmanager-*", "CatalogManagerIFace", "updatedFile(TQCString)", data ))
kdDebug(KBABEL) << "Unable to send file update info via DCOP" << endl;
}
@@ -1122,10 +1122,10 @@ void KBabelMW::fileSaveSpecial()
KURL url=m_view->currentURL();
DCOPClient *client = kapp->dcopClient();
- QByteArray data;
- QDataStream arg(data, IO_WriteOnly);
+ TQByteArray data;
+ TQDataStream arg(data, IO_WriteOnly);
arg << ((url.directory(false)+url.fileName()).utf8()) ;
- if( !client->send( "catalogmanager-*", "CatalogManagerIFace", "updatedFile(QCString)", data ))
+ if( !client->send( "catalogmanager-*", "CatalogManagerIFace", "updatedFile(TQCString)", data ))
kdDebug(KBABEL) << "Unable to send file update info via DCOP" << endl;
}
@@ -1181,7 +1181,7 @@ void KBabelMW::optionsEditToolbars()
{
saveMainWindowSettings( KGlobal::config(), "View" );
KEditToolbar dlg(actionCollection());
- connect(&dlg, SIGNAL(newToolbarConfig()), this, SLOT(newToolbarConfig()));
+ connect(&dlg, TQT_SIGNAL(newToolbarConfig()), this, TQT_SLOT(newToolbarConfig()));
dlg.exec();
}
@@ -1198,8 +1198,8 @@ void KBabelMW::optionsPreferences()
_prefDialog = new KBabelPreferences(m_view->dictionaries());
prefDialogs.append(_prefDialog);
- connect(_prefDialog,SIGNAL(settingsChanged())
- ,m_view,SLOT(updateSettings()));
+ connect(_prefDialog,TQT_SIGNAL(settingsChanged())
+ ,m_view,TQT_SLOT(updateSettings()));
}
int prefHeight=_prefDialog->height();
@@ -1210,7 +1210,7 @@ void KBabelMW::optionsPreferences()
int x=width/2-prefWidth/2;
int y=height/2-prefHeight/2;
- _prefDialog->move(mapToGlobal(QPoint(x,y)));
+ _prefDialog->move(mapToGlobal(TQPoint(x,y)));
if(!_prefDialog->isVisible())
{
@@ -1221,7 +1221,7 @@ void KBabelMW::optionsPreferences()
KWin::activateWindow(_prefDialog->winId());
}
-void KBabelMW::setLedColor(const QColor& color)
+void KBabelMW::setLedColor(const TQColor& color)
{
if(_fuzzyLed)
{
@@ -1239,8 +1239,8 @@ void KBabelMW::setLedColor(const QColor& color)
void KBabelMW::openCatalogManager()
{
- QCString service;
- QString result;
+ TQCString service;
+ TQString result;
DCOPClient * client = kapp->dcopClient();
@@ -1248,7 +1248,7 @@ void KBabelMW::openCatalogManager()
QCStringList apps = client->registeredApplications();
for( QCStringList::Iterator it = apps.begin() ; it != apps.end() ; ++it )
{
- QString clientID = *it;
+ TQString clientID = *it;
if( clientID.startsWith("catalogmanager") )
{
service = *it;
@@ -1259,8 +1259,8 @@ void KBabelMW::openCatalogManager()
// if there is no running catalog manager, start one
if( service.isEmpty() )
{
- QString prog = "catalogmanager";
- QString url = "";
+ TQString prog = "catalogmanager";
+ TQString url = "";
if( kapp->startServiceByDesktopName(prog,url, &result,&service))
{
KMessageBox::error(this, i18n("Unable to use KLauncher to start "
@@ -1271,8 +1271,8 @@ void KBabelMW::openCatalogManager()
}
// set preferred window
- QByteArray data;
- QDataStream arg(data, IO_WriteOnly);
+ TQByteArray data;
+ TQDataStream arg(data, IO_WriteOnly);
arg << (this->winId()) ;
if( !client->send( service, "CatalogManagerIFace", "setPreferredWindow( WId )", data )) kdDebug(KBABEL) << "Unable to set preferred window via DCOP" << endl;
}
@@ -1469,7 +1469,7 @@ void KBabelMW::enableForwardHistory(bool on)
}
-void KBabelMW::prepareProgressBar(QString msg,int max)
+void KBabelMW::prepareProgressBar(TQString msg,int max)
{
if(_statusbarTimer->isActive())
_statusbarTimer->stop();
@@ -1489,7 +1489,7 @@ void KBabelMW::clearProgressBar()
}
-void KBabelMW::changeStatusbar(const QString& text)
+void KBabelMW::changeStatusbar(const TQString& text)
{
// display the text on the statusbar
_progressLabel->setText(" "+text);
@@ -1505,7 +1505,7 @@ void KBabelMW::clearStatusbarMsg()
_progressLabel->setText("");
}
-void KBabelMW::changeCaption(const QString& text)
+void KBabelMW::changeCaption(const TQString& text)
{
// display the text on the caption
setCaption(text + ( _project->filename () != KBabel::ProjectManager::defaultProjectName() ?
@@ -1559,9 +1559,9 @@ void KBabelMW::enableStop(bool flag)
void KBabelMW::gettextHelp()
{
- QString error;
+ TQString error;
KApplication::startServiceByDesktopName("khelpcenter",
- QString("info:/gettext"), &error);
+ TQString("info:/gettext"), &error);
if(!error.isEmpty())
{
@@ -1572,7 +1572,7 @@ void KBabelMW::gettextHelp()
void KBabelMW::buildDictMenus()
{
- QPtrList<ModuleInfo> dictList = m_view->dictionaries();
+ TQPtrList<ModuleInfo> dictList = m_view->dictionaries();
dictList.setAutoDelete(true);
dictMenu->clear();
@@ -1584,10 +1584,10 @@ void KBabelMW::buildDictMenus()
ModuleInfo *info;
for(info = dictList.first(); info !=0; info = dictList.next())
{
- QString accel="Ctrl+Alt+%1";
+ TQString accel="Ctrl+Alt+%1";
dictMenu->add(info->name,info->id, accel);
- accel=QString("Ctrl+%1");
+ accel=TQString("Ctrl+%1");
selectionDictMenu->add(info->name,info->id, accel);
configDictMenu->add(info->name,info->id);
@@ -1607,14 +1607,14 @@ void KBabelMW::updateCursorPosition(int line, int col)
}
-KBabelMW *KBabelMW::winForURL(const KURL& url, QString project)
+KBabelMW *KBabelMW::winForURL(const KURL& url, TQString project)
{
KBabelMW *kb=0;
KBabelView *v = KBabelView::viewForURL(url,project);
if(v)
{
- QObject *p = v->parent();
+ TQObject *p = v->parent();
while(p && !p->inherits("KBabelMW"))
{
p = p->parent();
@@ -1627,14 +1627,14 @@ KBabelMW *KBabelMW::winForURL(const KURL& url, QString project)
return kb;
}
-KBabelMW *KBabelMW::emptyWin(QString project)
+KBabelMW *KBabelMW::emptyWin(TQString project)
{
KBabelMW *kb=0;
KBabelView *v = KBabelView::emptyView(project);
if(v)
{
- QObject *p = v->parent();
+ TQObject *p = v->parent();
while(p && !p->inherits("KBabelMW"))
{
p = p->parent();
@@ -1647,11 +1647,11 @@ KBabelMW *KBabelMW::emptyWin(QString project)
return kb;
}
-void KBabelMW::spellcheckMoreFiles(QStringList filelist)
+void KBabelMW::spellcheckMoreFiles(TQStringList filelist)
{
if( filelist.isEmpty() ) return;
_toSpellcheck = filelist;
- connect( m_view, SIGNAL( signalSpellcheckDone(int) ), this, SLOT( spellcheckDone(int)));
+ connect( m_view, TQT_SIGNAL( signalSpellcheckDone(int) ), this, TQT_SLOT( spellcheckDone(int)));
spellcheckDone( KS_IGNORE ); // use something else than KS_STOP
}
@@ -1659,22 +1659,22 @@ void KBabelMW::spellcheckDone( int result)
{
if( _toSpellcheck.isEmpty() || result == KS_STOP)
{
- disconnect( m_view, SIGNAL( signalSpellcheckDone(int)), this, SLOT(spellcheckDone( int)));
+ disconnect( m_view, TQT_SIGNAL( signalSpellcheckDone(int)), this, TQT_SLOT(spellcheckDone( int)));
KMessageBox::information( this, i18n("MessageBox text", "Spellchecking of multiple files is finished."),
i18n("MessageBox caption", "Spellcheck Done"));
}
else
{
- QString file = _toSpellcheck.first();
+ TQString file = _toSpellcheck.first();
_toSpellcheck.pop_front();
if( m_view->isModified() ) fileSave();
- open(KURL( file ), QString::null, false);
+ open(KURL( file ), TQString::null, false);
kdDebug(KBABEL) << "Starting another spellcheck" << endl;
- QTimer::singleShot( 1, m_view, SLOT(spellcheckAllMulti()));
+ TQTimer::singleShot( 1, m_view, TQT_SLOT(spellcheckAllMulti()));
}
}
-void KBabelMW::initBookmarks(QPtrList<KBabelBookmark> list)
+void KBabelMW::initBookmarks(TQPtrList<KBabelBookmark> list)
{
bmHandler->setBookmarks(list);
}
@@ -1705,12 +1705,12 @@ void KBabelMW::projectNew()
void KBabelMW::projectOpen()
{
- QString oldproject = m_view->project();
+ TQString oldproject = m_view->project();
if( oldproject == KBabel::ProjectManager::defaultProjectName() )
{
- oldproject = QString();
+ oldproject = TQString();
}
- const QString file = KFileDialog::getOpenFileName(oldproject, QString::null, this);
+ const TQString file = KFileDialog::getOpenFileName(oldproject, TQString::null, this);
if (file.isEmpty())
{
return;
@@ -1731,9 +1731,9 @@ void KBabelMW::projectOpenRecent(const KURL& url)
}
}
-void KBabelMW::projectOpen(const QString& file)
+void KBabelMW::projectOpen(const TQString& file)
{
- QString oldproject = m_view->project();
+ TQString oldproject = m_view->project();
if( oldproject == KBabel::ProjectManager::defaultProjectName() )
{
oldproject = "";
@@ -1761,13 +1761,13 @@ void KBabelMW::projectOpen(const QString& file)
void KBabelMW::projectClose()
{
- QString defaultProject = KBabel::ProjectManager::defaultProjectName();
+ TQString defaultProject = KBabel::ProjectManager::defaultProjectName();
m_view->useProject( KBabel::ProjectManager::open(defaultProject) );
_project = ProjectManager::open(defaultProject);
changeProjectActions(defaultProject);
}
-void KBabelMW::changeProjectActions(const QString& project)
+void KBabelMW::changeProjectActions(const TQString& project)
{
bool def = (project == KBabel::ProjectManager::defaultProjectName());
@@ -1792,8 +1792,8 @@ void KBabelMW::projectConfigure()
if(!_projectDialog)
{
_projectDialog = new ProjectDialog(_project);
- connect (_projectDialog, SIGNAL (settingsChanged())
- , m_view, SLOT (updateProjectSettings()));
+ connect (_projectDialog, TQT_SIGNAL (settingsChanged())
+ , m_view, TQT_SLOT (updateProjectSettings()));
}
int prefHeight=_projectDialog->height();
@@ -1804,7 +1804,7 @@ void KBabelMW::projectConfigure()
int x=width/2-prefWidth/2;
int y=height/2-prefHeight/2;
- _projectDialog->move(mapToGlobal(QPoint(x,y)));
+ _projectDialog->move(mapToGlobal(TQPoint(x,y)));
if(!_projectDialog->isVisible())
{
diff --git a/kbabel/kbabel/kbabel.h b/kbabel/kbabel/kbabel.h
index 4ff184c1..f6c5aa18 100644
--- a/kbabel/kbabel/kbabel.h
+++ b/kbabel/kbabel/kbabel.h
@@ -42,8 +42,8 @@
#include <kapplication.h>
#include <kdeversion.h>
#include <kdockwidget.h>
-#include <qstringlist.h>
-#include <qptrlist.h>
+#include <tqstringlist.h>
+#include <tqptrlist.h>
#include <kmdimainfrm.h>
#include "kbabelview.h"
@@ -86,23 +86,23 @@ public:
/**
* Default Constructor
*/
- KBabelMW(QString projectFile = QString());
+ KBabelMW(TQString projectFile = TQString());
/** use this contructor, if you just want to create a new view of an existing catalog*/
- KBabelMW(KBCatalog* catalog, QString projectFile = QString());
+ KBabelMW(KBCatalog* catalog, TQString projectFile = TQString());
/**
* Default Destructor
*/
virtual ~KBabelMW();
- QString project() const { return _project->filename(); }
+ TQString project() const { return _project->filename(); }
- void open(const KURL& url, const QString package, bool newWindow);
- void openTemplate(const KURL& openURL,const KURL& saveURL,const QString& package, bool newWindow=false);
- void projectOpen(const QString& filename);
+ void open(const KURL& url, const TQString package, bool newWindow);
+ void openTemplate(const KURL& openURL,const KURL& saveURL,const TQString& package, bool newWindow=false);
+ void projectOpen(const TQString& filename);
- void spellcheckMoreFiles( QStringList filelist);
+ void spellcheckMoreFiles( TQStringList filelist);
void setSettings(KBabel::SaveSettings,KBabel::IdentitySettings);
void updateSettings();
@@ -111,13 +111,13 @@ public:
* @return A pointer to a KBabel, that has opened file URL or 0 if no
* KBabel was found
*/
- static KBabelMW *winForURL(const KURL& url, QString projectFile = QString::null);
+ static KBabelMW *winForURL(const KURL& url, TQString projectFile = TQString::null);
/**
* @return A pointer to a KBabel, that has opened no file URL or 0 if no
* KBabel was found
*/
- static KBabelMW *emptyWin(QString projectFile = QString::null);
+ static KBabelMW *emptyWin(TQString projectFile = TQString::null);
public slots:
void toggleEditMode();
@@ -126,13 +126,13 @@ protected:
/**
* Overridden virtuals for Qt drag 'n drop (XDND)
*/
- virtual void dragEnterEvent(QDragEnterEvent *event);
- virtual void dropEvent(QDropEvent *event);
+ virtual void dragEnterEvent(TQDragEnterEvent *event);
+ virtual void dropEvent(TQDropEvent *event);
/**
* Overrriden virtual for wheel event handling to forward to KBabelView
*/
- virtual void wheelEvent(QWheelEvent *e);
+ virtual void wheelEvent(TQWheelEvent *e);
/**
* This function is called when it is time for the app to save its
@@ -212,15 +212,15 @@ private slots:
* activity. message is displayed left to the progressbar
* and max is the maximum number for the progressbar
*/
- void prepareProgressBar(QString message,int max);
+ void prepareProgressBar(TQString message,int max);
/**
* resets the progressBar and enables the window
*/
void clearProgressBar();
- void changeStatusbar(const QString& text);
+ void changeStatusbar(const TQString& text);
void clearStatusbarMsg();
- void changeCaption(const QString& text);
+ void changeCaption(const TQString& text);
void showModified(bool);
/**
@@ -228,7 +228,7 @@ private slots:
*/
void enableDefaults(bool readOnly);
- void setLedColor(const QColor& color);
+ void setLedColor(const TQColor& color);
void buildDictMenus();
@@ -254,7 +254,7 @@ private:
void init(KBCatalog* catalog);
void setupActions();
void setupDynamicActions();
- void changeProjectActions(const QString& project);
+ void changeProjectActions(const TQString& project);
void setupStatusBar();
void saveSettings();
void restoreSettings();
@@ -263,7 +263,7 @@ private:
*
* @param list the list of bookmarks.
*/
- void initBookmarks(QPtrList<KBabelBookmark> list);
+ void initBookmarks(TQPtrList<KBabelBookmark> list);
private:
KBabelView *m_view;
@@ -273,22 +273,22 @@ private:
int _currentIndex;
KProgress* _progressBar;
- QLabel* _progressLabel;
+ TQLabel* _progressLabel;
KLed* _fuzzyLed;
KLed* _untransLed;
KLed* _errorLed;
- QTimer *_statusbarTimer;
+ TQTimer *_statusbarTimer;
KBabelPreferences* _prefDialog;
- QStringList _toSpellcheck;
+ TQStringList _toSpellcheck;
/**
* used for updating preferences, that are common in
* the whole application
*/
- static QPtrList<KBabelPreferences> prefDialogs;
+ static TQPtrList<KBabelPreferences> prefDialogs;
// frequently used actions
@@ -316,7 +316,7 @@ private:
KSharedConfig::Ptr _config;
KBabel::ProjectDialog* _projectDialog;
- QMap<QString,QString> _toolsShortcuts;
+ TQMap<TQString,TQString> _toolsShortcuts;
KBabel::KBabelMailer* mailer;
KBabelBookmarkHandler* bmHandler;
diff --git a/kbabel/kbabel/kbabeliface.h b/kbabel/kbabel/kbabeliface.h
index d03b927d..49d19f5c 100644
--- a/kbabel/kbabel/kbabeliface.h
+++ b/kbabel/kbabel/kbabeliface.h
@@ -36,7 +36,7 @@
#define KBABELIFACE_H
#include <dcopobject.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
class KBabelIface : virtual public DCOPObject
{
@@ -44,38 +44,38 @@ class KBabelIface : virtual public DCOPObject
public:
k_dcop:
- virtual void openURL(QCString url, QCString package, WId window, int newWindow) { url = ""; window = 0; newWindow = 0; package= "";}
- virtual void openURL(QCString url, QCString package, WId window, int newWindow, QCString projectFile)
+ virtual void openURL(TQCString url, TQCString package, WId window, int newWindow) { url = ""; window = 0; newWindow = 0; package= "";}
+ virtual void openURL(TQCString url, TQCString package, WId window, int newWindow, TQCString projectFile)
{ url = ""; window = 0; newWindow = 0; projectFile=""; package= "";}
- virtual void openTemplate(QCString openFilename, QCString package, QCString saveFilename, int newWindow) { openFilename = ""; saveFilename = ""; newWindow = 0; package= "";}
- virtual void openTemplate(QCString openFilename, QCString package, QCString saveFilename, int newWindow, QCString projectFile)
+ virtual void openTemplate(TQCString openFilename, TQCString package, TQCString saveFilename, int newWindow) { openFilename = ""; saveFilename = ""; newWindow = 0; package= "";}
+ virtual void openTemplate(TQCString openFilename, TQCString package, TQCString saveFilename, int newWindow, TQCString projectFile)
{ openFilename = ""; saveFilename = ""; newWindow = 0; projectFile=""; package= "";}
/**
* open file url, if not already opened and goto entry
* that is equal msgid
*/
- virtual void gotoFileEntry(QCString url, QCString msgid)=0;
- virtual void gotoFileEntry(QCString url, QCString package, int msgid)=0;
- virtual void gotoFileEntry(QCString url, QCString package, int msgid, QCString projectFile)=0;
+ virtual void gotoFileEntry(TQCString url, TQCString msgid)=0;
+ virtual void gotoFileEntry(TQCString url, TQCString package, int msgid)=0;
+ virtual void gotoFileEntry(TQCString url, TQCString package, int msgid, TQCString projectFile)=0;
- virtual bool findInFile(QCString fileSource, QCString url,
- QString findStr, int caseSensitive, int wholeWords, int isRegExp,
+ virtual bool findInFile(TQCString fileSource, TQCString url,
+ TQString findStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave)=0;
- virtual bool replaceInFile(QCString fileSource, QCString url,
- QString findStr, QString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
+ virtual bool replaceInFile(TQCString fileSource, TQCString url,
+ TQString findStr, TQString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment, int ignoreAccelMarker,
int ignoreContextInfo, int ask, int askForNextFile, int askForSave)=0;
- virtual bool findInFile(QCString fileSource, QCString url,
- QString findStr, int caseSensitive, int wholeWords, int isRegExp,
+ virtual bool findInFile(TQCString fileSource, TQCString url,
+ TQString findStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
- int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave, QCString project )=0;
- virtual bool replaceInFile(QCString fileSource, QCString url,
- QString findStr, QString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
+ int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave, TQCString project )=0;
+ virtual bool replaceInFile(TQCString fileSource, TQCString url,
+ TQString findStr, TQString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment, int ignoreAccelMarker,
- int ignoreContextInfo, int ask, int askForNextFile, int askForSave, QCString project )=0;
- virtual void spellcheck(QStringList fileList)=0;
+ int ignoreContextInfo, int ask, int askForNextFile, int askForSave, TQCString project )=0;
+ virtual void spellcheck(TQStringList fileList)=0;
};
#endif // KBABELIFACE_H
diff --git a/kbabel/kbabel/kbabelpref.cpp b/kbabel/kbabel/kbabelpref.cpp
index 2907f060..2592385e 100644
--- a/kbabel/kbabel/kbabelpref.cpp
+++ b/kbabel/kbabel/kbabelpref.cpp
@@ -42,14 +42,14 @@
#include "colorpreferences.h"
#include "toolaction.h"
#include "toolselectionwidget.h"
-#include "qcombobox.h"
+#include "tqcombobox.h"
#include <klocale.h>
#include <kapplication.h>
using namespace KBabel;
-KBabelPreferences::KBabelPreferences(QPtrList<ModuleInfo> ml)
+KBabelPreferences::KBabelPreferences(TQPtrList<ModuleInfo> ml)
: KConfigDialog(0, "Preferences", KBabelSettings::self())
{
_editorPage = new EditorPreferences(0, "editor");
@@ -59,12 +59,12 @@ KBabelPreferences::KBabelPreferences(QPtrList<ModuleInfo> ml)
, i18n("Options for Editing"));
// this contains a custom widget for tool selection, set it up
- QValueList<KDataToolInfo> tools = ToolAction::validationTools();
+ TQValueList<KDataToolInfo> tools = ToolAction::validationTools();
_editorPage->_kcfg_AutoCheckTools->loadTools( "validate", tools );
- connect( _editorPage->_kcfg_AutoCheckTools, SIGNAL( added( QListBoxItem * ) ),
- this, SLOT (updateButtons()));
- connect( _editorPage->_kcfg_AutoCheckTools, SIGNAL( removed( QListBoxItem * ) ),
- this, SLOT (updateButtons()));
+ connect( _editorPage->_kcfg_AutoCheckTools, TQT_SIGNAL( added( TQListBoxItem * ) ),
+ this, TQT_SLOT (updateButtons()));
+ connect( _editorPage->_kcfg_AutoCheckTools, TQT_SIGNAL( removed( TQListBoxItem * ) ),
+ this, TQT_SLOT (updateButtons()));
addPage(_searchPage = new SearchPreferences(0, "search")
, i18n("title of page in preferences dialog","Search")
@@ -78,8 +78,8 @@ KBabelPreferences::KBabelPreferences(QPtrList<ModuleInfo> ml)
_searchPage->_kcfg_DefaultModule->insertItem(info->name);
}
moduleList = ml;
- connect( _searchPage->_kcfg_DefaultModule, SIGNAL( activated(int) ),
- this, SLOT (updateButtons()));
+ connect( _searchPage->_kcfg_DefaultModule, TQT_SIGNAL( activated(int) ),
+ this, TQT_SLOT (updateButtons()));
addPage(new EditorDiffPreferences(0, "diff")
,i18n("title of page in preferences dialog","Diff")
diff --git a/kbabel/kbabel/kbabelpref.h b/kbabel/kbabel/kbabelpref.h
index a275e11e..6d72aaf1 100644
--- a/kbabel/kbabel/kbabelpref.h
+++ b/kbabel/kbabel/kbabelpref.h
@@ -36,7 +36,7 @@
#define KBABELPREF_H
#include <kconfigdialog.h>
-#include <qptrlist.h>
+#include <tqptrlist.h>
class SearchPreferences;
class EditorPreferences;
@@ -46,7 +46,7 @@ class KBabelPreferences : public KConfigDialog
{
Q_OBJECT
public:
- KBabelPreferences(QPtrList<ModuleInfo>);
+ KBabelPreferences(TQPtrList<ModuleInfo>);
protected slots:
virtual void slotHelp();
@@ -62,7 +62,7 @@ private:
SearchPreferences* _searchPage;
EditorPreferences* _editorPage;
- QPtrList<ModuleInfo> moduleList;
+ TQPtrList<ModuleInfo> moduleList;
};
diff --git a/kbabel/kbabel/kbabelsplash.cpp b/kbabel/kbabel/kbabelsplash.cpp
index a13d8cd7..4166cffe 100644
--- a/kbabel/kbabel/kbabelsplash.cpp
+++ b/kbabel/kbabel/kbabelsplash.cpp
@@ -28,36 +28,36 @@
#include "kbabelsplash.h"
-#include <qapplication.h>
-#include <qlabel.h>
-#include <qpixmap.h>
-#include <qevent.h>
-#include <qstring.h>
-#include <qfontmetrics.h>
-#include <qpainter.h>
+#include <tqapplication.h>
+#include <tqlabel.h>
+#include <tqpixmap.h>
+#include <tqevent.h>
+#include <tqstring.h>
+#include <tqfontmetrics.h>
+#include <tqpainter.h>
#include <kstandarddirs.h>
KBabelSplash* KBabelSplash::instance = 0;
-KBabelSplash::KBabelSplash( QWidget* parent, const char* name )
- : QVBox( parent, name, WType_Dialog|WShowModal|WStyle_Customize|WStyle_NoBorder|WDestructiveClose )
+KBabelSplash::KBabelSplash( TQWidget* parent, const char* name )
+ : TQVBox( parent, name, WType_Dialog|WShowModal|WStyle_Customize|WStyle_NoBorder|WDestructiveClose )
{
setMargin( 0 );
setSpacing( 0 );
- QLabel* picLabel = new QLabel( this );
- QPixmap pixmap;
+ TQLabel* picLabel = new TQLabel( this );
+ TQPixmap pixmap;
if( pixmap.load( locate( "data", "kbabel/pics/splash.png" ) ) )
picLabel->setPixmap( pixmap );
- picLabel->setFrameStyle(QFrame::WinPanel | QFrame::Raised);
+ picLabel->setFrameStyle(TQFrame::WinPanel | TQFrame::Raised);
// Set geometry, with support for Xinerama systems
- QRect r;
+ TQRect r;
r.setSize(sizeHint());
- int ps = QApplication::desktop()->primaryScreen();
- r.moveCenter( QApplication::desktop()->screenGeometry(ps).center() );
+ int ps = TQApplication::desktop()->primaryScreen();
+ r.moveCenter( TQApplication::desktop()->screenGeometry(ps).center() );
setGeometry(r);
delete instance;
@@ -65,7 +65,7 @@ KBabelSplash::KBabelSplash( QWidget* parent, const char* name )
}
-void KBabelSplash::mousePressEvent( QMouseEvent* )
+void KBabelSplash::mousePressEvent( TQMouseEvent* )
{
close();
}
diff --git a/kbabel/kbabel/kbabelsplash.h b/kbabel/kbabel/kbabelsplash.h
index 3ae14c9a..b9a92c53 100644
--- a/kbabel/kbabel/kbabelsplash.h
+++ b/kbabel/kbabel/kbabelsplash.h
@@ -30,7 +30,7 @@
#ifndef KBABELSPLASH_H
#define KBABELSPLASH_H
-#include <qvbox.h>
+#include <tqvbox.h>
class QLabel;
class QMouseEvent;
@@ -43,13 +43,13 @@ class KBabelSplash : public QVBox
Q_OBJECT
public:
- KBabelSplash( QWidget* parent = 0, const char* name = 0 );
+ KBabelSplash( TQWidget* parent = 0, const char* name = 0 );
~KBabelSplash() { instance = 0; }
static KBabelSplash* instance;
protected:
- void mousePressEvent( QMouseEvent* );
+ void mousePressEvent( TQMouseEvent* );
};
#endif
diff --git a/kbabel/kbabel/kbabelview.cpp b/kbabel/kbabel/kbabelview.cpp
index 2e9ebfa3..ca41a7ad 100644
--- a/kbabel/kbabel/kbabelview.cpp
+++ b/kbabel/kbabel/kbabelview.cpp
@@ -39,21 +39,21 @@
#include "kbabelsettings.h"
#include "kbprojectsettings.h"
-#include <qlayout.h>
-
-#include <qlabel.h>
-#include <qframe.h>
-#include <qfileinfo.h>
-#include <qvariant.h>
-#include <qwhatsthis.h>
-#include <qdragobject.h>
-#include <qpopupmenu.h>
-#include <qstylesheet.h>
-#include <qtabwidget.h>
-#include <qtextview.h>
-#include <qtextstream.h>
-#include <qtimer.h>
-#include <qvbox.h>
+#include <tqlayout.h>
+
+#include <tqlabel.h>
+#include <tqframe.h>
+#include <tqfileinfo.h>
+#include <tqvariant.h>
+#include <tqwhatsthis.h>
+#include <tqdragobject.h>
+#include <tqpopupmenu.h>
+#include <tqstylesheet.h>
+#include <tqtabwidget.h>
+#include <tqtextview.h>
+#include <tqtextstream.h>
+#include <tqtimer.h>
+#include <tqvbox.h>
#include <dcopclient.h>
#include <kdeversion.h>
@@ -113,17 +113,17 @@
using namespace KBabel;
-QPtrList<KBabelView> *KBabelView::viewList = 0;
+TQPtrList<KBabelView> *KBabelView::viewList = 0;
KBabelView::KBabelView(KBCatalog* catalog,KBabelMW *parent, Project::Ptr project)
- : QWidget(parent)
+ : TQWidget(parent)
, _redirectedBackSearch (false)
, _project (project)
, m_mainwindow (parent)
, m_sourceview (0)
{
if(!viewList)
- viewList = new QPtrList<KBabelView>;
+ viewList = new TQPtrList<KBabelView>;
viewList->append(this);
@@ -181,7 +181,7 @@ KBabelView::KBabelView(KBCatalog* catalog,KBabelMW *parent, Project::Ptr project
hide();
dictBox = new KBabelDictBox(this,"dictBox");
- QWhatsThis::add(dictBox,
+ TQWhatsThis::add(dictBox,
i18n("<qt><p><b>Search results</b></p>"
"<p>This part of the window shows the results of searching in "
"dictionaries.<p>"
@@ -201,68 +201,68 @@ KBabelView::KBabelView(KBCatalog* catalog,KBabelMW *parent, Project::Ptr project
msgstrEdit->setReadOnly(true);
dictBox->setEnabled(false);
- connect(this, SIGNAL(signalNewFileOpened(KURL)),
- m_cataloglistview, SLOT(slotNewFileOpened()));
+ connect(this, TQT_SIGNAL(signalNewFileOpened(KURL)),
+ m_cataloglistview, TQT_SLOT(slotNewFileOpened()));
- connect(msgstrEdit,SIGNAL(signalUndoCmd(KBabel::EditCommand*)),this,SLOT(forwardMsgstrEditCmd(KBabel::EditCommand*)));
- connect(msgstrEdit,SIGNAL(textChanged()),this
- ,SIGNAL(signalMsgstrChanged()));
+ connect(msgstrEdit,TQT_SIGNAL(signalUndoCmd(KBabel::EditCommand*)),this,TQT_SLOT(forwardMsgstrEditCmd(KBabel::EditCommand*)));
+ connect(msgstrEdit,TQT_SIGNAL(textChanged()),this
+ ,TQT_SIGNAL(signalMsgstrChanged()));
- connect(msgstrEdit,SIGNAL(textChanged(const QString&)),m_cataloglistview
- ,SLOT(msgstrChanged(const QString&)));
+ connect(msgstrEdit,TQT_SIGNAL(textChanged(const TQString&)),m_cataloglistview
+ ,TQT_SLOT(msgstrChanged(const TQString&)));
- connect(this,SIGNAL(signalMsgstrChanged()),this,SLOT(autoCheck()));
- connect(msgstrEdit,SIGNAL(currentFormChanged(uint)), this
- ,SLOT(msgstrPluralFormChanged(uint)));
-
- connect(msgidLabel,SIGNAL(cursorPositionChanged(int,int))
- , this, SIGNAL(signalCursorPosChanged(int,int)));
- connect(msgstrEdit,SIGNAL(cursorPositionChanged(int,int))
- , this, SIGNAL(signalCursorPosChanged(int,int)));
-
- connect(dictBox,SIGNAL(searchStarted()),this
- ,SLOT(forwardSearchStart()));
- connect(dictBox, SIGNAL(progressStarts(const QString&)), this
- ,SLOT(forwardProgressStart(const QString&)));
- connect(dictBox,SIGNAL(progressed(int)),this
- ,SIGNAL(signalProgress(int)));
- connect(dictBox,SIGNAL(searchStopped()),this
- ,SLOT(forwardSearchStop()));
- connect(dictBox,SIGNAL(progressEnds()),this
- ,SIGNAL(signalClearProgressBar()));
-
- connect(dictBox,SIGNAL(modulesChanged()),this,
- SIGNAL(signalDictionariesChanged()));
- connect(dictBox,SIGNAL(errorInModule(const QString&)),this
- ,SLOT(showError(const QString&)));
-
- connect(_catalog,SIGNAL(signalSettingsChanged(KBabel::IdentitySettings)),
- this, SLOT(setNewLanguage()));
-
- connect(_catalog,SIGNAL(signalNumberOfFuzziesChanged(uint)),
- this, SLOT(checkFuzzies()));
- connect(_catalog,SIGNAL(signalNumberOfUntranslatedChanged(uint)),
- this, SLOT(checkUntranslated()));
+ connect(this,TQT_SIGNAL(signalMsgstrChanged()),this,TQT_SLOT(autoCheck()));
+ connect(msgstrEdit,TQT_SIGNAL(currentFormChanged(uint)), this
+ ,TQT_SLOT(msgstrPluralFormChanged(uint)));
+
+ connect(msgidLabel,TQT_SIGNAL(cursorPositionChanged(int,int))
+ , this, TQT_SIGNAL(signalCursorPosChanged(int,int)));
+ connect(msgstrEdit,TQT_SIGNAL(cursorPositionChanged(int,int))
+ , this, TQT_SIGNAL(signalCursorPosChanged(int,int)));
+
+ connect(dictBox,TQT_SIGNAL(searchStarted()),this
+ ,TQT_SLOT(forwardSearchStart()));
+ connect(dictBox, TQT_SIGNAL(progressStarts(const TQString&)), this
+ ,TQT_SLOT(forwardProgressStart(const TQString&)));
+ connect(dictBox,TQT_SIGNAL(progressed(int)),this
+ ,TQT_SIGNAL(signalProgress(int)));
+ connect(dictBox,TQT_SIGNAL(searchStopped()),this
+ ,TQT_SLOT(forwardSearchStop()));
+ connect(dictBox,TQT_SIGNAL(progressEnds()),this
+ ,TQT_SIGNAL(signalClearProgressBar()));
+
+ connect(dictBox,TQT_SIGNAL(modulesChanged()),this,
+ TQT_SIGNAL(signalDictionariesChanged()));
+ connect(dictBox,TQT_SIGNAL(errorInModule(const TQString&)),this
+ ,TQT_SLOT(showError(const TQString&)));
+
+ connect(_catalog,TQT_SIGNAL(signalSettingsChanged(KBabel::IdentitySettings)),
+ this, TQT_SLOT(setNewLanguage()));
+
+ connect(_catalog,TQT_SIGNAL(signalNumberOfFuzziesChanged(uint)),
+ this, TQT_SLOT(checkFuzzies()));
+ connect(_catalog,TQT_SIGNAL(signalNumberOfUntranslatedChanged(uint)),
+ this, TQT_SLOT(checkUntranslated()));
if(buildLeds)
{
- connect(this,SIGNAL(signalFuzzyDisplayed(bool))
- ,this,SLOT(toggleFuzzyLed(bool)));
- connect(this,SIGNAL(signalUntranslatedDisplayed(bool))
- ,this,SLOT(toggleUntransLed(bool)));
- connect(this,SIGNAL(signalFaultyDisplayed(bool))
- ,this,SLOT(toggleErrorLed(bool)));
+ connect(this,TQT_SIGNAL(signalFuzzyDisplayed(bool))
+ ,this,TQT_SLOT(toggleFuzzyLed(bool)));
+ connect(this,TQT_SIGNAL(signalUntranslatedDisplayed(bool))
+ ,this,TQT_SLOT(toggleUntransLed(bool)));
+ connect(this,TQT_SIGNAL(signalFaultyDisplayed(bool))
+ ,this,TQT_SLOT(toggleErrorLed(bool)));
}
- _dropMenu = new QPopupMenu(this);
+ _dropMenu = new TQPopupMenu(this);
_dropMenu->insertItem(i18n("Menu item", "Open"),ID_DROP_OPEN);
_dropMenu->insertItem(i18n("Open Template"),ID_DROP_OPEN_TEMPLATE);
readSettings(_config);
readProject(_project);
- connect (project, SIGNAL(signalSpellcheckSettingsChanged()),
- this, SLOT(updateProjectSettings()));
+ connect (project, TQT_SIGNAL(signalSpellcheckSettingsChanged()),
+ this, TQT_SLOT(updateProjectSettings()));
if(!_catalog->currentURL().isEmpty())
{
@@ -304,10 +304,10 @@ KBabelView::~KBabelView()
void KBabelView::initDockWidgets()
{
// setup main dock widget - original text
- QWidget *tempWidget=new QWidget(this,"msgidWidget");
+ TQWidget *tempWidget=new TQWidget(this,"msgidWidget");
tempWidget->setMinimumSize(350,150);
- QVBoxLayout *layout=new QVBoxLayout(tempWidget);
+ TQVBoxLayout *layout=new TQVBoxLayout(tempWidget);
msgidLabel = new HidingMsgEdit(2, this, 0, tempWidget,"msgidLabel");
msgidLabel->installEventFilter(this);
@@ -330,22 +330,22 @@ void KBabelView::initDockWidgets()
"Many good ideas, especially for the Catalog Manager, are taken\n"
"from KTranslator by Andrea Rizzi.").arg(VERSION).arg(2006));
- QLabel *label=new QLabel(msgidLabel,i18n("O&riginal string (msgid):"),tempWidget);
+ TQLabel *label=new TQLabel(msgidLabel,i18n("O&riginal string (msgid):"),tempWidget);
- QHBoxLayout* hb=new QHBoxLayout(layout);
+ TQHBoxLayout* hb=new TQHBoxLayout(layout);
hb->addSpacing(KDialog::marginHint());
hb->addWidget(label);
layout->addWidget(msgidLabel);
layout->setStretchFactor(msgidLabel,1);
- QWhatsThis::add(tempWidget,
+ TQWhatsThis::add(tempWidget,
i18n("<qt><p><b>Original String</b></p>\n\
<p>This part of the window shows the original message\n\
of the currently displayed entry.</p></qt>"));
KDockWidget* mainDock;
- mainDock = m_mainwindow->createDockWidget( "Original", QPixmap ());
+ mainDock = m_mainwindow->createDockWidget( "Original", TQPixmap ());
//i18n: translators: Dock window caption
mainDock->setCaption(i18n("Original Text"));
mainDock->setGeometry(50, 50, 100, 100);
@@ -356,12 +356,12 @@ of the currently displayed entry.</p></qt>"));
m_mainwindow->setMainDockWidget(mainDock); // master dockwidget
mainDock->show ();
m_mainwindow->setView (mainDock);
- connect (this, SIGNAL (signalCopy ()), this, SLOT (textCopy ()));
- connect (this, SIGNAL (signalCut ()), this, SLOT (textCut ()));
- connect (this, SIGNAL (signalPaste ()), this, SLOT (textPaste ()));
- connect (this, SIGNAL (signalSelectAll ()), this, SLOT (selectAll ()));
+ connect (this, TQT_SIGNAL (signalCopy ()), this, TQT_SLOT (textCopy ()));
+ connect (this, TQT_SIGNAL (signalCut ()), this, TQT_SLOT (textCut ()));
+ connect (this, TQT_SIGNAL (signalPaste ()), this, TQT_SLOT (textPaste ()));
+ connect (this, TQT_SIGNAL (signalSelectAll ()), this, TQT_SLOT (selectAll ()));
- KDockWidget* comment_dock = m_mainwindow->createDockWidget( "Comment", QPixmap ());
+ KDockWidget* comment_dock = m_mainwindow->createDockWidget( "Comment", TQPixmap ());
//i18n: translators: Dock window caption
comment_dock->setCaption(i18n("Comment"));
comment_dock->setGeometry(50, 50, 100, 100);
@@ -372,17 +372,17 @@ of the currently displayed entry.</p></qt>"));
KDockWidget::DockRight, // dock site
20 ); // relation target/this (in percent)
comment_dock->show ();
- connect (this, SIGNAL (signalCopy ()), m_commentview, SLOT (textCopy ()));
- connect (this, SIGNAL (signalCut ()), m_commentview, SLOT (textCut ()));
- connect (this, SIGNAL (signalPaste ()), m_commentview, SLOT (textPaste ()));
- connect (this, SIGNAL (signalSelectAll ()), m_commentview, SLOT (textSelectAll ()));
+ connect (this, TQT_SIGNAL (signalCopy ()), m_commentview, TQT_SLOT (textCopy ()));
+ connect (this, TQT_SIGNAL (signalCut ()), m_commentview, TQT_SLOT (textCut ()));
+ connect (this, TQT_SIGNAL (signalPaste ()), m_commentview, TQT_SLOT (textPaste ()));
+ connect (this, TQT_SIGNAL (signalSelectAll ()), m_commentview, TQT_SLOT (textSelectAll ()));
m_commentview->installEventFilter( this );
// build the msgstr widget
- tempWidget=new QWidget(this,"msgstrWidget");
+ tempWidget=new TQWidget(this,"msgstrWidget");
tempWidget->setMinimumSize(350,150);
- layout=new QVBoxLayout(tempWidget);
+ layout=new TQVBoxLayout(tempWidget);
// if undefined number of plural forms, use 1
int pf = _catalog->defaultNumberOfPluralForms();
@@ -393,9 +393,9 @@ of the currently displayed entry.</p></qt>"));
msgstrEdit->installEventFilter(this);
KCursor::setAutoHideCursor(msgstrEdit,true);
- label=new QLabel(msgstrEdit,i18n("Trans&lated string (msgstr):"),tempWidget);
+ label=new TQLabel(msgstrEdit,i18n("Trans&lated string (msgstr):"),tempWidget);
- hb=new QHBoxLayout(layout);
+ hb=new TQHBoxLayout(layout);
hb->setSpacing(KDialog::spacingHint());
hb->addSpacing(KDialog::marginHint());
@@ -407,7 +407,7 @@ of the currently displayed entry.</p></qt>"));
_fuzzyLed = new KLed(Qt::red,KLed::Off,KLed::Sunken,KLed::Rectangular
,tempWidget);
_fuzzyLed->setFixedSize(15,12);
- label = new QLabel(i18n("fuzzy"),tempWidget);
+ label = new TQLabel(i18n("fuzzy"),tempWidget);
hb->addWidget(_fuzzyLed);
hb->addWidget(label);
@@ -416,7 +416,7 @@ of the currently displayed entry.</p></qt>"));
_untransLed = new KLed(Qt::red,KLed::Off,KLed::Sunken,KLed::Rectangular
,tempWidget);
_untransLed->setFixedSize(15,12);
- label = new QLabel(i18n("untranslated"),tempWidget);
+ label = new TQLabel(i18n("untranslated"),tempWidget);
hb->addWidget(_untransLed);
hb->addWidget(label);
@@ -425,7 +425,7 @@ of the currently displayed entry.</p></qt>"));
_errorLed = new KLed(Qt::red,KLed::Off,KLed::Sunken,KLed::Rectangular
,tempWidget);
_errorLed->setFixedSize(15,12);
- label = new QLabel(i18n("faulty"),tempWidget);
+ label = new TQLabel(i18n("faulty"),tempWidget);
hb->addWidget(_errorLed);
hb->addWidget(label);
@@ -434,24 +434,24 @@ of the currently displayed entry.</p></qt>"));
hb->addStretch(1);
// ### TODO: perhaps it should be moreprecise where the setting can be changed
- QString ledMsg=i18n("<qt><p><b>Status LEDs</b></p>\n"
+ TQString ledMsg=i18n("<qt><p><b>Status LEDs</b></p>\n"
"<p>These LEDs display the status of the currently displayed message.\n"
"You can change their color in the preferences dialog section\n"
"<b>Editor</b> on page <b>Appearance</b></p></qt>");
- QWhatsThis::add(_fuzzyLed,ledMsg);
- QWhatsThis::add(_untransLed,ledMsg);
- QWhatsThis::add(_errorLed,ledMsg);
+ TQWhatsThis::add(_fuzzyLed,ledMsg);
+ TQWhatsThis::add(_untransLed,ledMsg);
+ TQWhatsThis::add(_errorLed,ledMsg);
}
layout->addWidget(msgstrEdit);
layout->setStretchFactor(msgstrEdit,1);
- QWhatsThis::add(tempWidget,
+ TQWhatsThis::add(tempWidget,
i18n("<qt><p><b>Translation Editor</b></p>\n\
<p>This editor displays and lets you edit the translation of the currently displayed message.<p></qt>"));
- KDockWidget* msgstr_dock = m_mainwindow->createDockWidget( "Msgstr", QPixmap ());
+ KDockWidget* msgstr_dock = m_mainwindow->createDockWidget( "Msgstr", TQPixmap ());
//i18n: translators: Dock window caption
msgstr_dock->setCaption(i18n("Translated String"));
msgstr_dock->setEnableDocking(KDockWidget::DockCorner);
@@ -461,7 +461,7 @@ of the currently displayed entry.</p></qt>"));
50 ); // relation target/this (in percent)
msgstr_dock->show ();
- KDockWidget* dock = m_mainwindow->createDockWidget( "Search", QPixmap ());
+ KDockWidget* dock = m_mainwindow->createDockWidget( "Search", TQPixmap ());
//i18n: translators: Dock window caption
dock->setCaption(i18n("the search (noun)","Search"));
//i18n: translators: Dock tab caption
@@ -475,7 +475,7 @@ of the currently displayed entry.</p></qt>"));
KDockWidget* tools = dock;
- dock = m_mainwindow->createDockWidget( "PO context", QPixmap ());
+ dock = m_mainwindow->createDockWidget( "PO context", TQPixmap ());
//i18n: translators: Dock window caption
dock->setCaption(i18n("PO Context"));
//i18n: translators: Dock tab caption
@@ -488,7 +488,7 @@ of the currently displayed entry.</p></qt>"));
20 ); // relation target/this (in percent)
dock->show ();
- dock = m_mainwindow->createDockWidget( "Charselector", QPixmap ());
+ dock = m_mainwindow->createDockWidget( "Charselector", TQPixmap ());
//i18n: translators: Dock window caption
dock->setCaption(i18n("Character Table"));
//i18n: translators: Dock tab caption
@@ -502,7 +502,7 @@ of the currently displayed entry.</p></qt>"));
dock->show ();
- dock = m_mainwindow->createDockWidget( "Tag List", QPixmap ());
+ dock = m_mainwindow->createDockWidget( "Tag List", TQPixmap ());
//i18n: translators: Dock window caption
dock->setCaption(i18n("Tag List"));
//i18n: translators: Dock tab caption
@@ -515,7 +515,7 @@ of the currently displayed entry.</p></qt>"));
20 ); // relation target/this (in percent)
dock->show ();
- dock = m_mainwindow->createDockWidget( "Source Context", QPixmap ());
+ dock = m_mainwindow->createDockWidget( "Source Context", TQPixmap ());
//i18n: translators: Dock window caption
dock->setCaption(i18n("Source Context"));
//i18n: translators: Dock tab caption
@@ -528,7 +528,7 @@ of the currently displayed entry.</p></qt>"));
20 ); // relation target/this (in percent)
dock->show ();
- KDockWidget* translist_dock = m_mainwindow->createDockWidget( "Translation List", QPixmap ());
+ KDockWidget* translist_dock = m_mainwindow->createDockWidget( "Translation List", TQPixmap ());
translist_dock->setCaption(i18n("Translation List"));
translist_dock->setGeometry(50, 50, 100, 100);
translist_dock->setEnableDocking(KDockWidget::DockFullSite);
@@ -537,7 +537,7 @@ of the currently displayed entry.</p></qt>"));
translist_dock->manualDock( mainDock, KDockWidget::DockTop,100);
translist_dock->show ();
- dock = m_mainwindow->createDockWidget( "Error List", QPixmap ());
+ dock = m_mainwindow->createDockWidget( "Error List", TQPixmap ());
//i18n: translators: Dock window caption
dock->setCaption(i18n("Error List"));
//i18n: translators: Dock tab caption
@@ -550,33 +550,33 @@ of the currently displayed entry.</p></qt>"));
20 );
dock->show ();
- connect(m_cataloglistview,SIGNAL(signalSelectionChanged(const KBabel::DocPosition&))
- ,this,SLOT(gotoEntry(const KBabel::DocPosition&)));
- connect(this,SIGNAL(signalDisplayed(const KBabel::DocPosition&))
- ,m_commentview,SLOT(gotoEntry(const KBabel::DocPosition&)));
- connect(this,SIGNAL(signalDisplayed(const KBabel::DocPosition&))
- ,m_contextview,SLOT(gotoEntry(const KBabel::DocPosition&)));
- connect(this,SIGNAL(signalDisplayed(const KBabel::DocPosition&))
- ,m_taglistview,SLOT(gotoEntry(const KBabel::DocPosition&)));
- connect(this,SIGNAL(signalDisplayed(const KBabel::DocPosition&))
- ,m_sourceview,SLOT(gotoEntry(const KBabel::DocPosition&)));
- connect(this,SIGNAL(signalDisplayed(const KBabel::DocPosition&))
- ,m_errorlistview,SLOT(gotoEntry(const KBabel::DocPosition&)));
- connect(this,SIGNAL(signalFaultyDisplayed(bool))
- ,m_errorlistview,SLOT(updateView()));
- connect(m_charselectorview, SIGNAL( characterDoubleClicked(QChar) )
- ,this, SLOT( insertChar(QChar) ));
- connect(m_taglistview,SIGNAL(signalTagSelected(const QString&))
- , this, SLOT(insertTagFromTool(const QString&)));
- connect(m_taglistview,SIGNAL(signalHighlightedTagChanged(int))
- , this, SLOT(skipToTagFromTool(int)));
- connect(this, SIGNAL(signalNextTag(int))
- , m_taglistview, SLOT(highlightTag(int)));
- connect(m_commentview,SIGNAL(signalCursorPosChanged(int,int))
- , m_mainwindow, SLOT(updateCursorPosition(int,int)));
+ connect(m_cataloglistview,TQT_SIGNAL(signalSelectionChanged(const KBabel::DocPosition&))
+ ,this,TQT_SLOT(gotoEntry(const KBabel::DocPosition&)));
+ connect(this,TQT_SIGNAL(signalDisplayed(const KBabel::DocPosition&))
+ ,m_commentview,TQT_SLOT(gotoEntry(const KBabel::DocPosition&)));
+ connect(this,TQT_SIGNAL(signalDisplayed(const KBabel::DocPosition&))
+ ,m_contextview,TQT_SLOT(gotoEntry(const KBabel::DocPosition&)));
+ connect(this,TQT_SIGNAL(signalDisplayed(const KBabel::DocPosition&))
+ ,m_taglistview,TQT_SLOT(gotoEntry(const KBabel::DocPosition&)));
+ connect(this,TQT_SIGNAL(signalDisplayed(const KBabel::DocPosition&))
+ ,m_sourceview,TQT_SLOT(gotoEntry(const KBabel::DocPosition&)));
+ connect(this,TQT_SIGNAL(signalDisplayed(const KBabel::DocPosition&))
+ ,m_errorlistview,TQT_SLOT(gotoEntry(const KBabel::DocPosition&)));
+ connect(this,TQT_SIGNAL(signalFaultyDisplayed(bool))
+ ,m_errorlistview,TQT_SLOT(updateView()));
+ connect(m_charselectorview, TQT_SIGNAL( characterDoubleClicked(TQChar) )
+ ,this, TQT_SLOT( insertChar(TQChar) ));
+ connect(m_taglistview,TQT_SIGNAL(signalTagSelected(const TQString&))
+ , this, TQT_SLOT(insertTagFromTool(const TQString&)));
+ connect(m_taglistview,TQT_SIGNAL(signalHighlightedTagChanged(int))
+ , this, TQT_SLOT(skipToTagFromTool(int)));
+ connect(this, TQT_SIGNAL(signalNextTag(int))
+ , m_taglistview, TQT_SLOT(highlightTag(int)));
+ connect(m_commentview,TQT_SIGNAL(signalCursorPosChanged(int,int))
+ , m_mainwindow, TQT_SLOT(updateCursorPosition(int,int)));
}
-KBabelView *KBabelView::viewForURL(const KURL& url, const QString project)
+KBabelView *KBabelView::viewForURL(const KURL& url, const TQString project)
{
if(url.isEmpty())
return 0;
@@ -587,7 +587,7 @@ KBabelView *KBabelView::viewForURL(const KURL& url, const QString project)
KURL u = url;
u.cleanPath();
- QPtrListIterator<KBabelView> it(*viewList);
+ TQPtrListIterator<KBabelView> it(*viewList);
KBabelView *view=0;
while( it.current() && !view)
{
@@ -605,12 +605,12 @@ KBabelView *KBabelView::viewForURL(const KURL& url, const QString project)
return view;
}
-KBabelView *KBabelView::emptyView(const QString)
+KBabelView *KBabelView::emptyView(const TQString)
{
if(!viewList)
return 0;
- QPtrListIterator<KBabelView> it(*viewList);
+ TQPtrListIterator<KBabelView> it(*viewList);
KBabelView *view=0;
while( it.current() && !view)
{
@@ -684,8 +684,8 @@ void KBabelView::readSettings(KConfig* config)
if(KBabelSettings::autoUnsetFuzzy())
{
- connect(msgstrEdit,SIGNAL(textChanged())
- ,this,SLOT(autoRemoveFuzzyStatus()));
+ connect(msgstrEdit,TQT_SIGNAL(textChanged())
+ ,this,TQT_SLOT(autoRemoveFuzzyStatus()));
}
setupAutoCheckTools();
@@ -770,7 +770,7 @@ void KBabelView::readProject(Project::Ptr project)
spell2.config->setEncoding(_spellcheckSettings.spellEncoding);
spell2.config->setDictionary(_spellcheckSettings.spellDict);
- spell2.kspell= new KSpell(this, "", this, SLOT(dummy(KSpell *)),
+ spell2.kspell= new KSpell(this, "", this, TQT_SLOT(dummy(KSpell *)),
spell2.config, false, false);
if(spell2.kspell->status() == KSpell::Error)
kdWarning(KBABEL) << "Something's wrong with KSpell, can't start on-the-fly checking" << endl;
@@ -853,13 +853,13 @@ void KBabelView::updateSettings()
_errorLed->setColor(KBabelSettings::ledColor());
}
- disconnect(msgstrEdit,SIGNAL(textChanged())
- ,this,SLOT(autoRemoveFuzzyStatus()));
+ disconnect(msgstrEdit,TQT_SIGNAL(textChanged())
+ ,this,TQT_SLOT(autoRemoveFuzzyStatus()));
if(KBabelSettings::autoUnsetFuzzy())
{
- connect(msgstrEdit,SIGNAL(textChanged())
- ,this,SLOT(autoRemoveFuzzyStatus()));
+ connect(msgstrEdit,TQT_SIGNAL(textChanged())
+ ,this,TQT_SLOT(autoRemoveFuzzyStatus()));
}
msgstrEdit->setCleverEditing(KBabelSettings::cleverEditing());
@@ -926,9 +926,9 @@ void KBabelView::setupAutoCheckTools()
if(!KBabelSettings::autoCheckTools().isEmpty() )
{
- QValueList<KDataToolInfo> tools = ToolAction::validationTools();
+ TQValueList<KDataToolInfo> tools = ToolAction::validationTools();
- QValueList<KDataToolInfo>::Iterator it;
+ TQValueList<KDataToolInfo>::Iterator it;
for( it=tools.begin(); it!=tools.end() ; ++it )
{
if(KBabelSettings::autoCheckTools().contains((*it).service()->library()) )
@@ -942,14 +942,14 @@ void KBabelView::setupAutoCheckTools()
}
}
-void KBabelView::setRMBEditMenu(QPopupMenu* popup)
+void KBabelView::setRMBEditMenu(TQPopupMenu* popup)
{
msgidLabel->setContextMenu( popup );
msgstrEdit->setContextMenu( popup );
KContextMenuManager::insert(this,popup);
}
-void KBabelView::setRMBSearchMenu(QPopupMenu* popup)
+void KBabelView::setRMBSearchMenu(TQPopupMenu* popup)
{
dictBox->setRMBMenu(popup);
}
@@ -965,7 +965,7 @@ void KBabelView::restoreView(KConfig *)
void KBabelView::saveSession(KConfig* config)
{
- QString focus;
+ TQString focus;
int line=0,col=0;
if(msgstrEdit->hasFocus())
{
@@ -1009,11 +1009,11 @@ void KBabelView::saveSession(KConfig* config)
void KBabelView::restoreSession(KConfig* config)
{
- QString url=config->readPathEntry("URL");
+ TQString url=config->readPathEntry("URL");
if(!url.isEmpty())
{
- open(KURL( url ), QString::null, false,true);
+ open(KURL( url ), TQString::null, false,true);
}
@@ -1031,7 +1031,7 @@ void KBabelView::restoreSession(KConfig* config)
pos.form=config->readNumEntry("PluralForm");
gotoEntry(pos);
- QString focus=config->readEntry("Focus");
+ TQString focus=config->readEntry("Focus");
int line=config->readNumEntry("CursorLine");
int col=config->readNumEntry("CursorCol");
if(focus=="msgstr")
@@ -1067,7 +1067,7 @@ void KBabelView::newFileOpened(bool readOnly)
msgstrEdit->setReadOnly(readOnly);
msgstrEdit->setFocus();
- QString caption=_catalog->package();
+ TQString caption=_catalog->package();
if(readOnly)
caption+=i18n(" [readonly]");
emit signalChangeCaption(caption);
@@ -1103,7 +1103,7 @@ void KBabelView::open()
open(KURL());
}
-void KBabelView::open(const KURL& _url, const QString & package, bool checkIfModified, bool newView)
+void KBabelView::open(const KURL& _url, const TQString & package, bool checkIfModified, bool newView)
{
#if KDE_IS_VERSION( 3, 5, 0)
KURL url = KIO::NetAccess::mostLocalURL(_url,this);
@@ -1126,7 +1126,7 @@ void KBabelView::open(const KURL& _url, const QString & package, bool checkIfMod
{
if(url.isEmpty())
{
- QString filename;
+ TQString filename;
if ((url = KFileDialog::getOpenURL(currentURL().url(), CatalogImportPlugin::availableImportMimeTypes().join(" ")
,this)).isEmpty())
{
@@ -1192,7 +1192,7 @@ void KBabelView::open(const KURL& _url, const QString & package, bool checkIfMod
}
case RECOVERED_PARSE_ERROR:
{
- QString msg=i18n(
+ TQString msg=i18n(
"The file contained syntax errors and an attempt has been "
"made to recover it.\n"
"Please check the questionable entries by using "
@@ -1243,8 +1243,8 @@ void KBabelView::open(const KURL& _url, const QString & package, bool checkIfMod
_autoSaveDelay = _catalog->saveSettings( ).autoSaveDelay;
if ( _autoSaveDelay ) {
if ( !autoSaveTimer ) {
- autoSaveTimer = new QTimer( this, "AUTOSAVE TIMER" );
- connect( autoSaveTimer, SIGNAL( timeout( ) ), this, SLOT( slotAutoSaveTimeout( ) ) );
+ autoSaveTimer = new TQTimer( this, "AUTOSAVE TIMER" );
+ connect( autoSaveTimer, TQT_SIGNAL( timeout( ) ), this, TQT_SLOT( slotAutoSaveTimeout( ) ) );
}
autoSaveTimer->stop( );
autoSaveTimer->start( 1000 * 60 * _autoSaveDelay );
@@ -1268,7 +1268,7 @@ void KBabelView::revertToSaved()
}
}
- open(_catalog->currentURL(),QString::null,false);
+ open(_catalog->currentURL(),TQString::null,false);
}
void KBabelView::openTemplate(const KURL& openURL, const KURL& saveURL)
@@ -1448,7 +1448,7 @@ bool KBabelView::saveFileAs(KURL url, bool syntaxCheck)
if (KIO::NetAccess::exists(url, false, this))
{
- if(KMessageBox::warningContinueCancel(this,QString("<qt>%1</qt>").arg(i18n("The file %1 already exists. "
+ if(KMessageBox::warningContinueCancel(this,TQString("<qt>%1</qt>").arg(i18n("The file %1 already exists. "
"Do you want to overwrite it?").arg(url.prettyURL())),i18n("Warning"),i18n("&Overwrite"))==KMessageBox::Cancel)
{
return false;
@@ -1468,7 +1468,7 @@ bool KBabelView::saveFileAs(KURL url, bool syntaxCheck)
do
{
// select the right error message
- QString message;
+ TQString message;
switch(stat)
{
case NO_PERMISSIONS:
@@ -1569,7 +1569,7 @@ bool KBabelView::saveFileAs(KURL url, bool syntaxCheck)
bool KBabelView::saveFileSpecial()
{
- QString tmpname;
+ TQString tmpname;
bool result = false;
{
@@ -1596,7 +1596,7 @@ bool KBabelView::saveFileSpecial()
, "filesave"
, i18n("Options for File Saving"));
- if( _prefDialog->exec() == QDialog::Accepted )
+ if( _prefDialog->exec() == TQDialog::Accepted )
{
SaveSettings settings = project->saveSettings();
SaveSettings originalSettings = _catalog->saveSettings();
@@ -1607,7 +1607,7 @@ bool KBabelView::saveFileSpecial()
}
}
- QFile::remove( tmpname );
+ TQFile::remove( tmpname );
return result;
}
@@ -1623,11 +1623,11 @@ bool KBabelView::checkSyntax(bool msgOnlyAtError,bool question)
return false;
bool returnCode=true;
- QString output;
+ TQString output;
Msgfmt::Status result=_catalog->checkSyntax( output );
- const QStringList outputLines = QStringList::split("\n",output);
+ const TQStringList outputLines = TQStringList::split("\n",output);
switch(result)
{
@@ -1654,7 +1654,7 @@ bool KBabelView::checkSyntax(bool msgOnlyAtError,bool question)
case Msgfmt::HeaderError:
case Msgfmt::SyntaxError:
{
- QString msg = ( result == Msgfmt::SyntaxError )
+ TQString msg = ( result == Msgfmt::SyntaxError )
? i18n("msgfmt detected a syntax error.\n")
: i18n("msgfmt detected a header syntax error.\n");
@@ -1695,7 +1695,7 @@ bool KBabelView::checkSyntax(bool msgOnlyAtError,bool question)
case Msgfmt::NoExecutable:
case Msgfmt::Error:
{
- QString msg = i18n("While trying to check syntax with msgfmt an error occurred.\n"
+ TQString msg = i18n("While trying to check syntax with msgfmt an error occurred.\n"
"Please make sure that you have installed\n"
"the GNU gettext package properly.");
if(question)
@@ -1742,9 +1742,9 @@ bool KBabelView::checkAll()
bool a,badresult=false;
- QValueList<KDataToolInfo> tools = ToolAction::validationTools();
+ TQValueList<KDataToolInfo> tools = ToolAction::validationTools();
- QValueList<KDataToolInfo>::ConstIterator entry = tools.begin();
+ TQValueList<KDataToolInfo>::ConstIterator entry = tools.begin();
for( ; entry != tools.end(); ++entry )
{
KDataTool* tool = (*entry).createTool();
@@ -1756,7 +1756,7 @@ bool KBabelView::checkAll()
}
}
- QString output;
+ TQString output;
a = (_catalog->checkSyntax(output, false)!=Msgfmt::Ok);
badresult=badresult||a;
@@ -1831,7 +1831,7 @@ void KBabelView::updateEditor(int form, bool delay)
if(KBabelSettings::autoUnsetFuzzy() && !msgstrEdit->isModified())
{
- disconnect(msgstrEdit,SIGNAL(textChanged()),this,SLOT(autoRemoveFuzzyStatus()));
+ disconnect(msgstrEdit,TQT_SIGNAL(textChanged()),this,TQT_SLOT(autoRemoveFuzzyStatus()));
}
msgidLabel->setText(_catalog->msgid(_currentIndex), _catalog->msgctxt(_currentIndex));
@@ -1844,7 +1844,7 @@ void KBabelView::updateEditor(int form, bool delay)
if(KBabelSettings::autoUnsetFuzzy() && _catalog->isFuzzy(_currentIndex))
{
- connect(msgstrEdit,SIGNAL(textChanged()),this,SLOT(autoRemoveFuzzyStatus()));
+ connect(msgstrEdit,TQT_SIGNAL(textChanged()),this,TQT_SLOT(autoRemoveFuzzyStatus()));
}
msgstrEdit->blockSignals(false);
@@ -1862,7 +1862,7 @@ void KBabelView::updateEditor(int form, bool delay)
{
if (delay)
{
- QTimer::singleShot(0, this, SLOT (startSearch()));
+ TQTimer::singleShot(0, this, TQT_SLOT (startSearch()));
}
else
{
@@ -2034,7 +2034,7 @@ bool KBabelView::findNext_internal(DocPosition& pos, bool forReplace, bool gui)
r = KMessageBox::questionYesNo(this,
i18n("<qt>%n replacement made.<br>End of document reached.<br>Continue from the beginning?</qt>",
"<qt>%n replacements made.<br>End of document reached.<br>Continue from the beginning?</qt>",
- _replacesTotal), QString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
+ _replacesTotal), TQString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
}
else {
r = KMessageBox::Yes;
@@ -2042,7 +2042,7 @@ bool KBabelView::findNext_internal(DocPosition& pos, bool forReplace, bool gui)
}
else {
r = KMessageBox::questionYesNo(this,i18n("End of document reached.\n"
- "Continue from the beginning?"), QString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
+ "Continue from the beginning?"), TQString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
}
if(r == KMessageBox::Yes) {
if(opts.inMsgid && !forReplace)
@@ -2078,23 +2078,23 @@ bool KBabelView::findNext_internal(DocPosition& pos, bool forReplace, bool gui)
if( opts.askForNextFile )
{
int r = KMessageBox::questionYesNo(this,i18n("End of document reached.\n"
- "Continue in the next file?"), QString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
+ "Continue in the next file?"), TQString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
if( r != KMessageBox::Yes ) return false;
}
if( isModified() && !opts.askForSave ) saveFile();
DCOPClient *client = kapp->dcopClient();
- QByteArray data, replyData;
- QCString replyType;
+ TQByteArray data, replyData;
+ TQCString replyType;
bool morefiles = false; // more files to lookup in
if( !client->call( _fileSource,"CatalogManagerIFace",
"findNextFile()", data, replyType, replyData) ) kdDebug(KBABEL) << "unable to call, reply type is " << replyType << endl;
- else if( replyType == "QCString" )
+ else if( replyType == "TQCString" )
{
- QDataStream rep( replyData, IO_ReadOnly);
- QCString f;
+ TQDataStream rep( replyData, IO_ReadOnly);
+ TQCString f;
rep >> f;
- QString foundFile = QString::fromUtf8(f);
+ TQString foundFile = TQString::fromUtf8(f);
morefiles = !f.isEmpty() && !f.isNull();
if( morefiles )
{
@@ -2219,7 +2219,7 @@ bool KBabelView::findPrev_internal(DocPosition& pos, bool forReplace, bool gui)
r = KMessageBox::questionYesNo(this,
i18n("<qt>%n replacement made.<br>Beginning of document reached.<br>Continue from the end?</qt>",
"<qt>%n replacements made.<br>Beginning of document reached.<br>Continue from the end?</qt>",
- _replacesTotal),QString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
+ _replacesTotal),TQString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
}
else {
r = KMessageBox::Yes;
@@ -2228,7 +2228,7 @@ bool KBabelView::findPrev_internal(DocPosition& pos, bool forReplace, bool gui)
}
else {
r = KMessageBox::questionYesNo(this,i18n("Beginning of document reached.\n"
- "Continue from the end?"), QString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
+ "Continue from the end?"), TQString::null, KStdGuiItem::cont(), KStdGuiItem::cancel());
}
if(r == KMessageBox::Yes) {
pos.item = _catalog->numberOfEntries()-1;
@@ -2345,7 +2345,7 @@ void KBabelView::find()
_findDialog = new FindDialog(false,this);
}
- QString marked;
+ TQString marked;
if(msgstrEdit->hasFocus()) {
marked=msgstrEdit->selectedText();
msgstrEdit->selectAll(false);
@@ -2363,7 +2363,7 @@ void KBabelView::find()
if(marked==_lastFoundString)
marked="";
- if( _findDialog->exec(marked) == QDialog::Accepted ) {
+ if( _findDialog->exec(marked) == TQDialog::Accepted ) {
DocPosition pos;
FindOptions opts=_findDialog->findOpts();
opts.askFile = false; // do not search in more files
@@ -2443,7 +2443,7 @@ void KBabelView::replace()
if( !_replaceDialog ) {
_replaceDialog = new FindDialog(true,this);
}
- QString marked;
+ TQString marked;
if(msgstrEdit->hasFocus()) {
marked=msgstrEdit->selectedText();
msgstrEdit->selectAll(false);
@@ -2460,7 +2460,7 @@ void KBabelView::replace()
if(marked==_lastFoundString)
marked="";
- if( _replaceDialog->exec(marked) == QDialog::Accepted ) {
+ if( _replaceDialog->exec(marked) == TQDialog::Accepted ) {
KBabel::ReplaceOptions opts=_replaceDialog->replaceOpts();
if(opts.fromCursor) {
_findBreakAtEnd=false;
@@ -2518,9 +2518,9 @@ void KBabelView::replace()
if(success) {
if(!_replaceAskDialog) {
_replaceAskDialog = new ReplaceDialog(this);
- connect(_replaceAskDialog,SIGNAL(replace()),this,SLOT(replaceNext()));
- connect(_replaceAskDialog,SIGNAL(next()),this,SLOT(findNextReplace()));
- connect(_replaceAskDialog,SIGNAL(replaceAll()),this,SLOT(replaceAll()));
+ connect(_replaceAskDialog,TQT_SIGNAL(replace()),this,TQT_SLOT(replaceNext()));
+ connect(_replaceAskDialog,TQT_SIGNAL(next()),this,TQT_SLOT(findNextReplace()));
+ connect(_replaceAskDialog,TQT_SIGNAL(replaceAll()),this,TQT_SLOT(replaceAll()));
}
if(opts.ask) {
@@ -2551,7 +2551,7 @@ void KBabelView::replaceNext()
Part part;
uint form = 0;
- QString str;
+ TQString str;
if(_replacePos.part==Msgstr) {
part=Msgstr;
@@ -2629,7 +2629,7 @@ void KBabelView::replaceAll()
Part part;
uint form=0;
- QString str;
+ TQString str;
if(_replacePos.part==Msgstr) {
part=Msgstr;
@@ -2689,7 +2689,7 @@ void KBabelView::findNextReplace()
}
-void KBabelView::findInFile(QCString fileSource, FindOptions options)
+void KBabelView::findInFile(TQCString fileSource, FindOptions options)
{
DocPosition pos;
pos.item=0;
@@ -2714,7 +2714,7 @@ void KBabelView::findInFile(QCString fileSource, FindOptions options)
findNext_internal(pos);
}
-void KBabelView::replaceInFile(QCString fileSource, KBabel::ReplaceOptions options)
+void KBabelView::replaceInFile(TQCString fileSource, KBabel::ReplaceOptions options)
{
_replacePos.item=0;
_replacePos.part=Msgid;
@@ -2749,9 +2749,9 @@ void KBabelView::replaceInFile(QCString fileSource, KBabel::ReplaceOptions optio
else {
if(!_replaceAskDialog) {
_replaceAskDialog = new ReplaceDialog(this);
- connect(_replaceAskDialog,SIGNAL(replace()),this,SLOT(replaceNext()));
- connect(_replaceAskDialog,SIGNAL(next()),this,SLOT(findNextReplace()));
- connect(_replaceAskDialog,SIGNAL(replaceAll()),this,SLOT(replaceAll()));
+ connect(_replaceAskDialog,TQT_SIGNAL(replace()),this,TQT_SLOT(replaceNext()));
+ connect(_replaceAskDialog,TQT_SIGNAL(next()),this,TQT_SLOT(findNextReplace()));
+ connect(_replaceAskDialog,TQT_SIGNAL(replaceAll()),this,TQT_SLOT(replaceAll()));
}
if(options.ask) {
@@ -2800,7 +2800,7 @@ void KBabelView::clear()
void KBabelView::msgid2msgstr()
{
// FIXME: should care about plural forms
- QString text = _catalog->msgid(_currentIndex).first();
+ TQString text = _catalog->msgid(_currentIndex).first();
// this is KDE specific:
if(text.find("_: NAME OF TRANSLATORS\\n")==0)
@@ -2830,7 +2830,7 @@ void KBabelView::msgid2msgstr()
// end of KDE specific part
- QRegExp reg=_catalog->miscSettings().contextInfo;
+ TQRegExp reg=_catalog->miscSettings().contextInfo;
if(text.contains(reg))
{
text.replace(reg,"");
@@ -3182,7 +3182,7 @@ void KBabelView::editHeader()
int x=w/2-editWidth/2;
int y=h/2-editHeight/2;
- editor->move(mapToGlobal(QPoint(x,y)));
+ editor->move(mapToGlobal(TQPoint(x,y)));
editor->show();
editor->raise();
@@ -3202,8 +3202,8 @@ void KBabelView::startSearch()
void KBabelView::startSearch(bool delay)
{
- QString msg = _catalog->msgid(_currentIndex,true).first();
- QRegExp reg=_catalog->miscSettings().contextInfo;
+ TQString msg = _catalog->msgid(_currentIndex,true).first();
+ TQRegExp reg=_catalog->miscSettings().contextInfo;
if(msg.contains(reg))
{
msg.replace(reg,"");
@@ -3220,11 +3220,11 @@ void KBabelView::startSearch(bool delay)
}
}
-void KBabelView::startSearch(const QString module)
+void KBabelView::startSearch(const TQString module)
{
// FIXME: should care about plural forms
- QString msg = _catalog->msgid(_currentIndex,true).first();
- QRegExp reg=_catalog->miscSettings().contextInfo;
+ TQString msg = _catalog->msgid(_currentIndex,true).first();
+ TQRegExp reg=_catalog->miscSettings().contextInfo;
if(msg.contains(reg))
{
msg.replace(reg,"");
@@ -3240,7 +3240,7 @@ void KBabelView::startSelectionSearch()
startSelectionSearch(KBabelSettings::defaultModule());
}
-void KBabelView::startSelectionSearch(const QString module)
+void KBabelView::startSelectionSearch(const TQString module)
{
dictBox->setActiveModule(module);
@@ -3256,8 +3256,8 @@ void KBabelView::startSelectionSearch(const QString module)
else
{
// should care about plural forms
- QString msg = _catalog->msgid(_currentIndex,true).first();
- QRegExp reg=_catalog->miscSettings().contextInfo;
+ TQString msg = _catalog->msgid(_currentIndex,true).first();
+ TQRegExp reg=_catalog->miscSettings().contextInfo;
if(msg.contains(reg))
{
msg.replace(reg,"");
@@ -3299,8 +3299,8 @@ void KBabelView::emitEntryState()
if(isError)
{
- QPalette palette=msgstrEdit->palette();
- palette.setColor( QColorGroup::Text, red );
+ TQPalette palette=msgstrEdit->palette();
+ palette.setColor( TQColorGroup::Text, red );
if( _catalog->itemStatus(_currentIndex).contains("syntax error"))
{
@@ -3335,7 +3335,7 @@ void KBabelView::checkUntranslated()
void KBabelView::autoRemoveFuzzyStatus()
{
// only at first text change remove fuzzy status
- disconnect(msgstrEdit,SIGNAL(textChanged()),this,SLOT(autoRemoveFuzzyStatus()));
+ disconnect(msgstrEdit,TQT_SIGNAL(textChanged()),this,TQT_SLOT(autoRemoveFuzzyStatus()));
//removeFuzzyStatus();
}
@@ -3398,18 +3398,18 @@ void KBabelView::toggleErrorLed(bool on)
-void KBabelView::showError(const QString& message)
+void KBabelView::showError(const TQString& message)
{
KMessageBox::error(this,message);
}
-void KBabelView::dragEnterEvent(QDragEnterEvent *event)
+void KBabelView::dragEnterEvent(TQDragEnterEvent *event)
{
// accept uri drops only
event->accept(KURLDrag::canDecode(event));
}
-void KBabelView::dropEvent(QDropEvent *event)
+void KBabelView::dropEvent(TQDropEvent *event)
{
KURL::List uri;
@@ -3421,33 +3421,33 @@ void KBabelView::dropEvent(QDropEvent *event)
}
-bool KBabelView::eventFilter( QObject* object, QEvent* event)
+bool KBabelView::eventFilter( TQObject* object, TQEvent* event)
{
- if(event->type() == QEvent::DragEnter)
+ if(event->type() == TQEvent::DragEnter)
{
- QDragEnterEvent* e = (QDragEnterEvent*) event;
+ TQDragEnterEvent* e = (TQDragEnterEvent*) event;
if(KURLDrag::canDecode(e))
{
e->accept(true);
return true;
}
}
- else if(event->type() == QEvent::Drop)
+ else if(event->type() == TQEvent::Drop)
{
KURL::List uri;
// see if we can decode a URI.. if not, just ignore it
- if (KURLDrag::decode((QDropEvent*)event, uri))
+ if (KURLDrag::decode((TQDropEvent*)event, uri))
{
- processUriDrop(uri ,( (QWidget*)object)->mapToGlobal( ( (QDropEvent*)event )->pos()));
+ processUriDrop(uri ,( (TQWidget*)object)->mapToGlobal( ( (TQDropEvent*)event )->pos()));
return true;
}
}
- else if(event->type() == QEvent::KeyPress)
+ else if(event->type() == TQEvent::KeyPress)
{
// This is a little workaround to use CTRL+ALT+Home, CTRL+ALT+End, Undo keys
// to go to the first and the last entry. Because otherwise
// CTRL+Home and CTRL+End and Undo are caught by QTextEdit
- QKeyEvent *ke = (QKeyEvent*)event;
+ TQKeyEvent *ke = (TQKeyEvent*)event;
if(ke->key() == Key_Home && ke->state() == (AltButton | ControlButton))
{
@@ -3480,7 +3480,7 @@ bool KBabelView::eventFilter( QObject* object, QEvent* event)
return false;
}
-void KBabelView::processUriDrop(KURL::List& uriList, const QPoint& pos)
+void KBabelView::processUriDrop(KURL::List& uriList, const TQPoint& pos)
{
// if we have two entries, the chance is high, that it
// is a drag from the catalog manager
@@ -3526,12 +3526,12 @@ void KBabelView::forwardMsgstrEditCmd(EditCommand* cmd)
/*
if(cmd->terminator()!=0)
{
- kdDebug(KBABEL) << QString::number(cmd->terminator()) << endl;
+ kdDebug(KBABEL) << TQString::number(cmd->terminator()) << endl;
}
else
{
DelTextCmd* delcmd = (DelTextCmd*) cmd;
- kdDebug(KBABEL) << QString::number(delcmd->offset)+":"+delcmd->str+"|" << endl;
+ kdDebug(KBABEL) << TQString::number(delcmd->offset)+":"+delcmd->str+"|" << endl;
}
*/
bool fuzzyRemoved=false;
@@ -3576,9 +3576,9 @@ void KBabelView::autoCheck(bool onlyWhenChanged)
{
if( !_autocheckTools.isEmpty() )
{
- QStringList oldStatus = _catalog->itemStatus(_currentIndex);
+ TQStringList oldStatus = _catalog->itemStatus(_currentIndex);
- QStringList status = _catalog->itemStatus( _currentIndex,true, _autocheckTools );
+ TQStringList status = _catalog->itemStatus( _currentIndex,true, _autocheckTools );
// if there is more than one view, the status changes only in
// one view, so we have to update always.
@@ -3587,12 +3587,12 @@ void KBabelView::autoCheck(bool onlyWhenChanged)
if( !status.isEmpty() )
{
- QString msg = "";
+ TQString msg = "";
// ### TODO: whynot use i18n("context",text) directly?
KLocale* locale=KGlobal::locale();
- for( QStringList::iterator it=status.begin() ; it != status.end() ; ++it )
+ for( TQStringList::iterator it=status.begin() ; it != status.end() ; ++it )
{
if( msg.isEmpty() ) msg = locale->translate("what check found errors",(*it).utf8());
else msg += ", "+locale->translate("what check found errors",(*it).utf8());
@@ -3712,20 +3712,20 @@ void KBabelView::spellcheckCommon()
delete spellDlg;
}
-void KBabelView::addSpellcheckWords( uint pos, QString text, uint index, uint form )
+void KBabelView::addSpellcheckWords( uint pos, TQString text, uint index, uint form )
{
// special format chars
- QString spclChars="abfnrtv'\"?\\";
- QChar accelMarker=_catalog->miscSettings().accelMarker;
+ TQString spclChars="abfnrtv'\"?\\";
+ TQChar accelMarker=_catalog->miscSettings().accelMarker;
uint textLength=text.length();
do
{
- QString word="";
+ TQString word="";
bool wordBegin=false;
while(!wordBegin && pos < textLength)
{
- QChar c=text[pos];
+ TQChar c=text[pos];
if(c.isLetter() || c==accelMarker)
{
wordBegin=true;
@@ -3830,7 +3830,7 @@ void KBabelView::spellcheck()
spell.lastIndex=_currentIndex;
_tagExtractor->setString(msgstrEdit->selectedText());
- QString marked=_tagExtractor->plainString(true);
+ TQString marked=_tagExtractor->plainString(true);
addSpellcheckWords(msgstrEdit->beginOfMarkedText(),marked
,_currentIndex,msgstrEdit->currentForm());
@@ -3839,7 +3839,7 @@ void KBabelView::spellcheck()
{
uint first=0;
uint last=_catalog->numberOfEntries()-1;
- QString text;
+ TQString text;
bool emitProgress=false;
@@ -3863,12 +3863,12 @@ void KBabelView::spellcheck()
int pos=msgstrEdit->currentIndex();
int form=msgstrEdit->currentForm();
- QStringList msgs = _catalog->msgstr(_currentIndex);
+ TQStringList msgs = _catalog->msgstr(_currentIndex);
_tagExtractor->setString((*msgs.at(form)));
text=_tagExtractor->plainString(true);
addSpellcheckWords( pos, text, _currentIndex, form++ );
- for( QStringList::Iterator i=msgs.at(form++) ; i!=msgs.end(); i++)
+ for( TQStringList::Iterator i=msgs.at(form++) ; i!=msgs.end(); i++)
{
_tagExtractor->setString(*i);
text=_tagExtractor->plainString(true);
@@ -3903,9 +3903,9 @@ void KBabelView::spellcheck()
kapp->processEvents(100);
}
- QStringList msgs=_catalog->msgstr(i);
+ TQStringList msgs=_catalog->msgstr(i);
uint formCounter=0;
- for(QStringList::Iterator j=msgs.begin() ; j!=msgs.end() ; ++j)
+ for(TQStringList::Iterator j=msgs.begin() ; j!=msgs.end() ; ++j)
{
_tagExtractor->setString(*j);
text=_tagExtractor->plainString(true);
@@ -3918,12 +3918,12 @@ void KBabelView::spellcheck()
int pos=msgstrEdit->currentIndex();
int form=msgstrEdit->currentForm();
- QStringList msgs = _catalog->msgstr(_currentIndex);
+ TQStringList msgs = _catalog->msgstr(_currentIndex);
_tagExtractor->setString((*msgs.at(form)).left(pos));
text=_tagExtractor->plainString(true);
addSpellcheckWords( 0, text, _currentIndex, form++ );
- for( QStringList::Iterator i=msgs.at(form++) ; i!=msgs.end(); i++)
+ for( TQStringList::Iterator i=msgs.at(form++) ; i!=msgs.end(); i++)
{
_tagExtractor->setString(*i);
text=_tagExtractor->plainString(true);
@@ -3943,7 +3943,7 @@ void KBabelView::spellcheck()
_dontBeep=true;
spell.kspell= new KSpell (this, i18n("Spellcheck"),
- this, SLOT(spellStart(KSpell *)), spell.config, true, true);
+ this, TQT_SLOT(spellStart(KSpell *)), spell.config, true, true);
if( spell.kspell->status() == KSpell::Error )
{
KMessageBox::error( this, i18n("KBabel cannot start spell checker. "
@@ -3951,20 +3951,20 @@ void KBabelView::spellcheck()
return;
}
- connect(spell.kspell, SIGNAL(death()),this, SLOT(spellCleanDone()));
+ connect(spell.kspell, TQT_SIGNAL(death()),this, TQT_SLOT(spellCleanDone()));
- connect(spell.kspell, SIGNAL(misspelling(const QString &, const QStringList &
+ connect(spell.kspell, TQT_SIGNAL(misspelling(const TQString &, const TQStringList &
, unsigned int)), this
- , SLOT(spellMisspelled(const QString &, const QStringList &, unsigned int)));
+ , TQT_SLOT(spellMisspelled(const TQString &, const TQStringList &, unsigned int)));
- connect(spell.kspell, SIGNAL(corrected(const QString &, const QString &, unsigned int))
- , this, SLOT(spellCorrected(const QString &, const QString &, unsigned int)));
+ connect(spell.kspell, TQT_SIGNAL(corrected(const TQString &, const TQString &, unsigned int))
+ , this, TQT_SLOT(spellCorrected(const TQString &, const TQString &, unsigned int)));
- connect(spell.kspell,SIGNAL(ignoreall(const QString &))
- , this, SLOT(spellAddIgnore(const QString &)));
+ connect(spell.kspell,TQT_SIGNAL(ignoreall(const TQString &))
+ , this, TQT_SLOT(spellAddIgnore(const TQString &)));
- connect(spell.kspell, SIGNAL(done(bool))
- , this, SLOT(spellResult(bool)));
+ connect(spell.kspell, TQT_SIGNAL(done(bool))
+ , this, TQT_SLOT(spellResult(bool)));
spell.kspell->setAutoDelete(true); // let KSpell handle delete
}
@@ -3980,7 +3980,7 @@ void KBabelView::spellStart(KSpell *)
// set ignored words
if(_spellcheckSettings.rememberIgnored)
{
- QString urlString = _spellcheckSettings.ignoreURL;
+ TQString urlString = _spellcheckSettings.ignoreURL;
if(urlString.contains("@PACKAGE@"))
{
urlString.replace("@PACKAGE@",_catalog->packageName());
@@ -3989,15 +3989,15 @@ void KBabelView::spellStart(KSpell *)
KURL url(urlString);
if(url.isLocalFile())
{
- QFile file(url.path());
+ TQFile file(url.path());
if(file.open(IO_ReadOnly))
{
- QTextStream stream(&file);
- stream.setEncoding(QTextStream::UnicodeUTF8);
- QString contents = stream.read();
+ TQTextStream stream(&file);
+ stream.setEncoding(TQTextStream::UnicodeUTF8);
+ TQString contents = stream.read();
file.close();
- spell.ignoreList = QStringList::split('\n',contents);
+ spell.ignoreList = TQStringList::split('\n',contents);
}
else if(file.exists())
{
@@ -4023,7 +4023,7 @@ void KBabelView::spellStart(KSpell *)
uint total = spell.ignoreList.count();
uint oldPercent=0;
uint counter=0;
- QStringList::Iterator it;
+ TQStringList::Iterator it;
for(it=spell.ignoreList.begin(); it != spell.ignoreList.end(); ++it)
{
counter++;
@@ -4045,7 +4045,7 @@ void KBabelView::spellStart(KSpell *)
}
-bool KBabelView::markMisspelled(const QString &orig, unsigned int pos)
+bool KBabelView::markMisspelled(const TQString &orig, unsigned int pos)
{
Position *p = spell.posDict.at(pos);
if(!p)
@@ -4081,9 +4081,9 @@ bool KBabelView::markMisspelled(const QString &orig, unsigned int pos)
int end=p->end+spell.posCorrection-spell.inWordCorrection;
// check if this is the correct word
- QString text = *_catalog->msgstr(p->index).at(p->form);
+ TQString text = *_catalog->msgstr(p->index).at(p->form);
text=text.mid(begin,end-begin);
- QChar accelMarker=_catalog->miscSettings().accelMarker;
+ TQChar accelMarker=_catalog->miscSettings().accelMarker;
if(text.contains(accelMarker))
{
@@ -4104,7 +4104,7 @@ bool KBabelView::markMisspelled(const QString &orig, unsigned int pos)
if( n > 0 )
{
// re-get the original text since we replace some things above
- QString text = *_catalog->msgstr(p->index).at(p->form);
+ TQString text = *_catalog->msgstr(p->index).at(p->form);
text=text.mid(begin,end-begin);
bool textFound=false;
@@ -4126,7 +4126,7 @@ bool KBabelView::markMisspelled(const QString &orig, unsigned int pos)
if(e<0) e=text.length();
- QString w=text.mid(lastPos,e-lastPos);
+ TQString w=text.mid(lastPos,e-lastPos);
if(w.contains(accelMarker))
{
w.replace(accelMarker,"");
@@ -4183,7 +4183,7 @@ bool KBabelView::markMisspelled(const QString &orig, unsigned int pos)
return textOk;
}
-void KBabelView::spellMisspelled(const QString &orig, const QStringList &, unsigned int pos)
+void KBabelView::spellMisspelled(const TQString &orig, const TQStringList &, unsigned int pos)
{
kdDebug(KBABEL) << "misspelled: " << orig << " pos: " << pos << endl;
@@ -4192,11 +4192,11 @@ void KBabelView::spellMisspelled(const QString &orig, const QStringList &, unsig
markMisspelled(orig,pos);
}
-void KBabelView::spellCorrected(const QString &orig, const QString &word, unsigned int pos)
+void KBabelView::spellCorrected(const TQString &orig, const TQString &word, unsigned int pos)
{
if(orig != word)
{
- QString newWord(word);
+ TQString newWord(word);
kdDebug(KBABEL) << "corrected: " << orig << " " << newWord
<< " pos: " << pos << endl;
@@ -4222,12 +4222,12 @@ void KBabelView::spellCorrected(const QString &orig, const QString &word, unsign
if(markMisspelled(orig,pos))
{
- QString marked=msgstrEdit->selectedText();
+ TQString marked=msgstrEdit->selectedText();
spell.origWords.append(marked);
if(marked.contains("\n") && !newWord.contains('\n'))
{
- QString s1=newWord;
+ TQString s1=newWord;
s1.replace(" ","\n");
// if only a newline has been replaced with a white space
@@ -4240,11 +4240,11 @@ void KBabelView::spellCorrected(const QString &orig, const QString &word, unsign
// check if the old word had an accelerator. If yes and the new
// word has no accelerator, try to add the accelerator for
// the same char else add in at the same position
- QChar accelMarker=_catalog->miscSettings().accelMarker;
+ TQChar accelMarker=_catalog->miscSettings().accelMarker;
if(marked.contains(accelMarker) && !newWord.contains(accelMarker))
{
int b=marked.find(accelMarker);
- QChar accel=marked[b+1];
+ TQChar accel=marked[b+1];
int nb=newWord.find(accel,0,false);
if(nb>=0)
{
@@ -4308,9 +4308,9 @@ void KBabelView::spellResult(bool flag)
else if(spell.replaced > 0 && spell.what2Check!=Current
&& spell.what2Check!=Marked)
{
- QStringList list;
- QStringList::Iterator origIt;
- QStringList::Iterator newIt;
+ TQStringList list;
+ TQStringList::Iterator origIt;
+ TQStringList::Iterator newIt;
origIt=spell.origWords.begin();
newIt=spell.newWords.begin();
@@ -4332,12 +4332,12 @@ void KBabelView::spellResult(bool flag)
KURL url(_spellcheckSettings.ignoreURL);
if(url.isLocalFile())
{
- QFile file(url.path());
+ TQFile file(url.path());
if(file.open(IO_WriteOnly|IO_Append))
{
- QStringList::Iterator it;
- QTextStream stream(&file);
- stream.setEncoding(QTextStream::UnicodeUTF8);
+ TQStringList::Iterator it;
+ TQTextStream stream(&file);
+ stream.setEncoding(TQTextStream::UnicodeUTF8);
for(it=spell.newIgnoreList.begin();
it!=spell.newIgnoreList.end();
@@ -4368,7 +4368,7 @@ void KBabelView::spellResult(bool flag)
spell.kspell->cleanUp();
emit signalSpellcheckDone(s);
- QTimer::singleShot(0,this,SLOT(cleanUpSpellStruct()));
+ TQTimer::singleShot(0,this,TQT_SLOT(cleanUpSpellStruct()));
}
@@ -4420,7 +4420,7 @@ void KBabelView::cancelSpellcheck()
spell.active=false;
}
-void KBabelView::spellAddIgnore(const QString &word)
+void KBabelView::spellAddIgnore(const TQString &word)
{
if(!spell.ignoreList.contains(word))
{
@@ -4440,7 +4440,7 @@ void KBabelView::forwardSearchStop()
emit signalSearchActive(false);
}
-void KBabelView::forwardProgressStart(const QString& msg)
+void KBabelView::forwardProgressStart(const TQString& msg)
{
emit signalResetProgressBar(msg,100);
}
@@ -4458,16 +4458,16 @@ void KBabelView::slotAutoSaveTimeout( )
void KBabelView::useProject (Project::Ptr project)
{
// FIXME: close the current project first
- disconnect (_project, SIGNAL(signalSpellcheckSettingsChanged()),
- this, SLOT(updateProjectSettings()));
+ disconnect (_project, TQT_SIGNAL(signalSpellcheckSettingsChanged()),
+ this, TQT_SLOT(updateProjectSettings()));
_project = project;
_catalog->useProject(_project);
readProject(_project);
- connect (project, SIGNAL(signalSpellcheckSettingsChanged()),
- this, SLOT(updateProjectSettings()));
+ connect (project, TQT_SIGNAL(signalSpellcheckSettingsChanged()),
+ this, TQT_SLOT(updateProjectSettings()));
}
#include "kbabelview.moc"
diff --git a/kbabel/kbabel/kbabelview.h b/kbabel/kbabel/kbabelview.h
index a52ed4dc..fb86cd6b 100644
--- a/kbabel/kbabel/kbabelview.h
+++ b/kbabel/kbabel/kbabelview.h
@@ -65,8 +65,8 @@ struct ModuleInfo;
#include <kdockwidget.h>
#include <kurl.h>
#include <kconfig.h>
-#include <qwidget.h>
-#include <qstrlist.h>
+#include <tqwidget.h>
+#include <tqstrlist.h>
#include <resources.h>
#include <catalogview.h>
@@ -90,7 +90,7 @@ class TagListView;
* @author Matthias Kiefer <matthias.kiefer@gmx.de>
* @version 0.1
*/
-class KBabelView : public QWidget, public KBabel::CatalogView
+class KBabelView : public TQWidget, public KBabel::CatalogView
{
Q_OBJECT
public:
@@ -109,16 +109,16 @@ public:
* @return the view, that has opened file url or 0 if this
* file is not opened
*/
- static KBabelView *viewForURL(const KURL& url, const QString project);
+ static KBabelView *viewForURL(const KURL& url, const TQString project);
/**
* @return the view, that has no opened file url or 0 if there
* is no such view
*/
- static KBabelView *emptyView(const QString project);
+ static KBabelView *emptyView(const TQString project);
KURL currentURL() const;
- QString project() const { return _project->filename(); }
+ TQString project() const { return _project->filename(); }
void useProject (KBabel::Project::Ptr project);
bool isLastView() const;
@@ -178,7 +178,7 @@ public:
KBCatalog* catalog() const{return _catalog;}
- void processUriDrop(KURL::List& uriList, const QPoint & pos);
+ void processUriDrop(KURL::List& uriList, const TQPoint & pos);
/**
* checks the status of the displayed entry: last, first, fuzzy,...
@@ -186,12 +186,12 @@ public:
*/
void emitEntryState();
- void setRMBEditMenu(QPopupMenu*);
- void setRMBSearchMenu(QPopupMenu*);
- void setTagsMenu(QPopupMenu*);
- void setArgsMenu(QPopupMenu*);
+ void setRMBEditMenu(TQPopupMenu*);
+ void setRMBSearchMenu(TQPopupMenu*);
+ void setTagsMenu(TQPopupMenu*);
+ void setArgsMenu(TQPopupMenu*);
- QPtrList<ModuleInfo> dictionaries();
+ TQPtrList<ModuleInfo> dictionaries();
KBabelDictBox* searchView() { return dictBox; }
bool autoDiffEnabled() const {return _diffEnabled;}
@@ -202,7 +202,7 @@ public slots:
/** opens a filedialog and asks for an url */
void open();
- void open(const KURL& url, const QString & package=QString::null, bool checkModified=true, bool newView=false);
+ void open(const KURL& url, const TQString & package=TQString::null, bool checkModified=true, bool newView=false);
void setFilePackage();
void revertToSaved();
@@ -217,8 +217,8 @@ public slots:
bool findNext();
bool findPrev();
void find();
- void findInFile(QCString fileSource, KBabel::FindOptions options);
- void replaceInFile(QCString fileSource, KBabel::ReplaceOptions options);
+ void findInFile(TQCString fileSource, KBabel::FindOptions options);
+ void replaceInFile(TQCString fileSource, KBabel::ReplaceOptions options);
void replace();
void selectAll();
void deselectAll();
@@ -259,7 +259,7 @@ public slots:
void insertNextTag();
void insertNextTagMsgid();
void insertNextArg();
- void insertTagFromTool( const QString& tag );
+ void insertTagFromTool( const TQString& tag );
void showTagsMenu();
void showArgsMenu();
void skipToNextTag();
@@ -282,23 +282,23 @@ public slots:
void stopSearch();
void startSearch();
void startSelectionSearch();
- void startSearch(const QString id);
- void startSelectionSearch(const QString id);
+ void startSearch(const TQString id);
+ void startSelectionSearch(const TQString id);
- void configureDictionary(const QString id);
- void editDictionary(const QString id);
- void aboutDictionary(const QString id);
+ void configureDictionary(const TQString id);
+ void editDictionary(const TQString id);
+ void aboutDictionary(const TQString id);
/**
* this was originally protected, but we need this to expose for
* KBabelMW forwarding
*/
- virtual void wheelEvent(QWheelEvent*);
+ virtual void wheelEvent(TQWheelEvent*);
protected:
- virtual void dragEnterEvent(QDragEnterEvent *event);
- virtual void dropEvent(QDropEvent *event);
- virtual bool eventFilter(QObject*, QEvent* event);
+ virtual void dragEnterEvent(TQDragEnterEvent *event);
+ virtual void dropEvent(TQDropEvent *event);
+ virtual bool eventFilter(TQObject*, TQEvent* event);
signals:
/** emited when a fuzzy catalogentry is shown */
@@ -346,15 +346,15 @@ signals:
/**
* Use this signal to change the content of the statusbar
*/
- void signalChangeStatusbar(const QString& text);
+ void signalChangeStatusbar(const TQString& text);
/**
* Use this signal to change the content of the caption
*/
- void signalChangeCaption(const QString& text);
+ void signalChangeCaption(const TQString& text);
void signalNewFileOpened(KURL url);
- void signalResetProgressBar(QString,int);
+ void signalResetProgressBar(TQString,int);
void signalProgress(int);
void signalClearProgressBar();
@@ -365,7 +365,7 @@ signals:
void signalForwardHistory(bool have);
void signalBackHistory(bool have);
- void ledColorChanged(const QColor& color);
+ void ledColorChanged(const TQColor& color);
void signalDictionariesChanged();
@@ -441,12 +441,12 @@ private:
* Inserts a text into the msgstr (into the current form) using undoable commands.
* if @param clearFirst is set to true, it will clear the contents of msgstr before inserting
*/
- void modifyMsgstrText(const uint offset, const QString& text, bool clearFirst=false);
+ void modifyMsgstrText(const uint offset, const TQString& text, bool clearFirst=false);
protected slots:
- bool validateUsingTool( const KDataToolInfo & info, const QString & command );
- void modifyUsingTool( const KDataToolInfo & info, const QString & command );
- void modifyCatalogUsingTool( const KDataToolInfo & info, const QString & command );
+ bool validateUsingTool( const KDataToolInfo & info, const TQString & command );
+ void modifyUsingTool( const KDataToolInfo & info, const TQString & command );
+ void modifyCatalogUsingTool( const KDataToolInfo & info, const TQString & command );
private slots:
void msgstrPluralFormChanged (uint index);
@@ -455,7 +455,7 @@ private slots:
/** connected to the catalog. it is called when a new file is opened*/
void newFileOpened(bool readOnly);
- void showError(const QString& message);
+ void showError(const TQString& message);
void toggleFuzzyLed(bool on);
void toggleUntransLed(bool on);
@@ -493,7 +493,7 @@ private slots:
void informDictionary();
void setNewLanguage();
- void forwardProgressStart(const QString& msg);
+ void forwardProgressStart(const TQString& msg);
void forwardSearchStart();
void forwardSearchStop();
@@ -520,14 +520,14 @@ private slots:
void insertArg(int n);
void updateArgs();
- void insertChar(QChar ch);
+ void insertChar(TQChar ch);
void showTryLaterMessageBox();
void dummy(KSpell*) {}
private:
- static QPtrList<KBabelView> *viewList;
+ static TQPtrList<KBabelView> *viewList;
HidingMsgEdit* msgstrEdit;
HidingMsgEdit* msgidLabel;
@@ -537,7 +537,7 @@ private:
FindDialog* _replaceDialog;
ReplaceDialog* _replaceAskDialog;
- QPopupMenu* _dropMenu;
+ TQPopupMenu* _dropMenu;
KLed* _fuzzyLed;
KLed* _untransLed;
@@ -551,8 +551,8 @@ private:
bool _autoSearchTempDisabled;
- QValueList<uint> _backHistory;
- QValueList<uint> _forwardHistory;
+ TQValueList<uint> _backHistory;
+ TQValueList<uint> _forwardHistory;
// flag to not beep, when switching to the next entry, because
// go -> next or prev entry was used.
@@ -566,7 +566,7 @@ private:
/**
* the string that was marked during the last search
*/
- QString _lastFoundString;
+ TQString _lastFoundString;
/*
* flag, if internal find functions should break at end or ask for
@@ -590,13 +590,13 @@ private:
int _replaceExtraOffset;
/** appId for a source of the next files to be searched */
- QCString _fileSource;
+ TQCString _fileSource;
- QStringList _tags;
- QPopupMenu *_tagsMenu;
+ TQStringList _tags;
+ TQPopupMenu *_tagsMenu;
- QStringList _args;
- QPopupMenu *_argsMenu;
+ TQStringList _args;
+ TQPopupMenu *_argsMenu;
bool _diffEnabled;
bool _loadingDiffFile;
@@ -606,7 +606,7 @@ private:
* flag, set if editing KDE documentation PO-file
*/
bool _editingDocumentation;
- QPtrList<KDataTool> _autocheckTools;
+ TQPtrList<KDataTool> _autocheckTools;
//spellcheck things
private:
@@ -624,13 +624,13 @@ private:
{
KSpell *kspell;
KSpellConfig* config;
- QStringList wordList;
+ TQStringList wordList;
bool active;
int misspelled;
int replaced;
int posCorrection;
uint lastIndex;
- QPtrList<Position> posDict;
+ TQPtrList<Position> posDict;
SpellWhat what2Check;
// the last word, that was misspelled
@@ -639,11 +639,11 @@ private:
// needed if words with '-' are treated as seperate words
int inWordCorrection;
- QStringList origWords;
- QStringList newWords;
+ TQStringList origWords;
+ TQStringList newWords;
- QStringList ignoreList;
- QStringList newIgnoreList;
+ TQStringList ignoreList;
+ TQStringList newIgnoreList;
} spell;
struct {
@@ -665,23 +665,23 @@ private:
* @returns false, if the there is a synchronization error,
* means the word has not been found in the editor.
*/
- bool markMisspelled(const QString &orig, unsigned int pos);
+ bool markMisspelled(const TQString &orig, unsigned int pos);
private slots:
void spellcheck();
void cancelSpellcheck();
void spellStart(KSpell*);
- void spellMisspelled(const QString &orig, const QStringList &sug, unsigned int pos);
- void spellCorrected(const QString &orig, const QString &newWord, unsigned int pos);
+ void spellMisspelled(const TQString &orig, const TQStringList &sug, unsigned int pos);
+ void spellCorrected(const TQString &orig, const TQString &newWord, unsigned int pos);
void spellResult(bool);
void spellCleanDone();
- void spellAddIgnore(const QString &);
+ void spellAddIgnore(const TQString &);
// initialize spellchecking struct
void cleanUpSpellStruct();
void slotAutoSaveTimeout( );
private:
- void addSpellcheckWords(uint pos, QString text, uint index, uint form);
+ void addSpellcheckWords(uint pos, TQString text, uint index, uint form);
private:
// configuration file
@@ -692,7 +692,7 @@ private:
KBabel::RegExpExtractor* _tagExtractor;
KBabel::RegExpExtractor* _argExtractor;
- QTimer * autoSaveTimer;
+ TQTimer * autoSaveTimer;
int _autoSaveDelay;
int _currentTag;
diff --git a/kbabel/kbabel/kbabelview2.cpp b/kbabel/kbabel/kbabelview2.cpp
index c07990d0..101674a3 100644
--- a/kbabel/kbabel/kbabelview2.cpp
+++ b/kbabel/kbabel/kbabelview2.cpp
@@ -43,12 +43,12 @@
#include <kurl.h>
#include <kio/netaccess.h>
-#include <qcheckbox.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qmessagebox.h>
-#include <qpopupmenu.h>
-#include <qvbox.h>
+#include <tqcheckbox.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqmessagebox.h>
+#include <tqpopupmenu.h>
+#include <tqvbox.h>
#include "catalogsettings.h"
#include "editcmd.h"
@@ -65,25 +65,25 @@
using namespace KBabel;
-QPtrList<ModuleInfo> KBabelView::dictionaries()
+TQPtrList<ModuleInfo> KBabelView::dictionaries()
{
- QPtrList<ModuleInfo> list = dictBox->moduleInfos();
+ TQPtrList<ModuleInfo> list = dictBox->moduleInfos();
return list;
}
-void KBabelView::configureDictionary(const QString id)
+void KBabelView::configureDictionary(const TQString id)
{
dictBox->configure(id);
}
-void KBabelView::editDictionary(const QString id)
+void KBabelView::editDictionary(const TQString id)
{
dictBox->edit(id);
}
-void KBabelView::aboutDictionary(const QString id)
+void KBabelView::aboutDictionary(const TQString id)
{
dictBox->aboutModule(id);
}
@@ -121,7 +121,7 @@ void KBabelView::setNewLanguage()
}
-void KBabelView::wheelEvent(QWheelEvent *e)
+void KBabelView::wheelEvent(TQWheelEvent *e)
{
if( _catalog->numberOfEntries() == 0 ) return;
@@ -196,12 +196,12 @@ void KBabelView::updateTags()
{
_tagsMenu->clear();
- QStringList tList;
- QStringList::Iterator it;
+ TQStringList tList;
+ TQStringList::Iterator it;
int counter=0;
for(it=_tags.begin(); it!=_tags.end(); ++it)
{
- QString s = *it;
+ TQString s = *it;
if( s.startsWith("&") ) s = "&"+s;
if(!tList.contains(s))
{
@@ -259,7 +259,7 @@ void KBabelView::selectTag()
// count number of eofs in tag
uint diff=0;
// FIXME: what about plural forms
- QString msgid = _catalog->msgid(_currentIndex).first();
+ TQString msgid = _catalog->msgid(_currentIndex).first();
for( uint i = _tagExtractor->matchIndex(_currentTag); i < _tagExtractor->matchIndex(_currentTag)+_tags[_currentTag].length()+1; i++ )
{
@@ -269,14 +269,14 @@ void KBabelView::selectTag()
emit signalNextTag (_currentTag);
}
-void KBabelView::setTagsMenu(QPopupMenu *menu)
+void KBabelView::setTagsMenu(TQPopupMenu *menu)
{
_tagsMenu=menu;
- connect(_tagsMenu,SIGNAL(activated(int)),this,SLOT(insertTag(int)));
+ connect(_tagsMenu,TQT_SIGNAL(activated(int)),this,TQT_SLOT(insertTag(int)));
}
-void KBabelView::modifyMsgstrText(const uint offset, const QString& text, bool clearFirst)
+void KBabelView::modifyMsgstrText(const uint offset, const TQString& text, bool clearFirst)
{
_catalog->applyBeginCommand( _currentIndex, Msgstr ,this);
@@ -296,7 +296,7 @@ void KBabelView::modifyMsgstrText(const uint offset, const QString& text, bool c
void KBabelView::insertTag(int n)
{
- QString tag = _tagsMenu->text(n);
+ TQString tag = _tagsMenu->text(n);
if( tag.startsWith( "&&" ) ) tag = tag.remove(0,1); // replace && -> &. && is used for correct menu display
modifyMsgstrText( msgstrEdit->currentIndex(), tag );
@@ -324,9 +324,9 @@ void KBabelView::insertNextTagMsgid()
int offset = msgstrEdit->beginOfLastMarkedText(); //msgstrEdit->currentIndex();
- QString s = (*_catalog->msgstr(_currentIndex).at(msgstrEdit->currentForm())).left(offset);
+ TQString s = (*_catalog->msgstr(_currentIndex).at(msgstrEdit->currentForm())).left(offset);
- QString t;
+ TQString t;
if( _catalog->pluralForm( _currentIndex ) == KDESpecific )
{
@@ -359,7 +359,7 @@ void KBabelView::showTagsMenu()
{
int y=msgstrEdit->height()/2;
int x=msgstrEdit->width()/2;
- _tagsMenu->exec(msgstrEdit->mapToGlobal( QPoint(x,y) ) );
+ _tagsMenu->exec(msgstrEdit->mapToGlobal( TQPoint(x,y) ) );
return;
}
@@ -376,12 +376,12 @@ void KBabelView::updateArgs()
{
_argsMenu->clear();
- QStringList tList;
- QStringList::Iterator it;
+ TQStringList tList;
+ TQStringList::Iterator it;
int counter=0;
for(it=_args.begin(); it!=_args.end(); ++it)
{
- QString s = *it;
+ TQString s = *it;
if(!tList.contains(s))
{
_argsMenu->insertItem(s,counter);
@@ -403,17 +403,17 @@ void KBabelView::updateArgs()
}
}
-void KBabelView::setArgsMenu(QPopupMenu *menu)
+void KBabelView::setArgsMenu(TQPopupMenu *menu)
{
_argsMenu=menu;
- connect(_argsMenu,SIGNAL(activated(int)),this,SLOT(insertArg(int)));
+ connect(_argsMenu,TQT_SIGNAL(activated(int)),this,TQT_SLOT(insertArg(int)));
}
void KBabelView::insertArg(int n)
{
- QString arg = _argsMenu->text(n);
+ TQString arg = _argsMenu->text(n);
modifyMsgstrText( msgstrEdit->currentIndex(), arg );
}
@@ -422,7 +422,7 @@ void KBabelView::insertNextArg()
{
int offset = msgstrEdit->currentIndex();
- QString s = (*_catalog->msgstr(_currentIndex).at(msgstrEdit->currentForm())).left(offset);
+ TQString s = (*_catalog->msgstr(_currentIndex).at(msgstrEdit->currentForm())).left(offset);
if( _catalog->pluralForm( _currentIndex ) == KDESpecific )
{
@@ -444,7 +444,7 @@ void KBabelView::insertNextArg()
return;
}
- QString t=_args[num];
+ TQString t=_args[num];
modifyMsgstrText( offset,t );
}
@@ -455,7 +455,7 @@ void KBabelView::showArgsMenu()
{
int y=msgstrEdit->height()/2;
int x=msgstrEdit->width()/2;
- _argsMenu->exec(msgstrEdit->mapToGlobal( QPoint(x,y) ) );
+ _argsMenu->exec(msgstrEdit->mapToGlobal( TQPoint(x,y) ) );
return;
}
@@ -507,7 +507,7 @@ void KBabelView::diffInternal(bool autoDf)
_diffing = true;
uint diffIndex = _currentIndex;
- QString diffString;
+ TQString diffString;
Catalog::DiffResult r = _catalog->diff(_currentIndex, &diffString);
@@ -521,9 +521,9 @@ void KBabelView::diffInternal(bool autoDf)
bool wasEnabled=_diffEnabled;
_diffEnabled=false;
- QValueList<DiffEntry> diffList;
- QString error;
- QString package = _catalog->packageName()+".po";
+ TQValueList<DiffEntry> diffList;
+ TQString error;
+ TQString package = _catalog->packageName()+".po";
kdDebug(KBABEL) << "getting list for " << package << endl;
if(dictBox->messagesForPackage(package,diffList,error))
@@ -569,12 +569,12 @@ void KBabelView::diffInternal(bool autoDf)
case 2:
{
// get the list of all entries
- QValueList<DiffEntry> diffList = _catalog->asDiffList();
+ TQValueList<DiffEntry> diffList = _catalog->asDiffList();
- QValueList<DiffEntry> resultList;
+ TQValueList<DiffEntry> resultList;
// swap msgstr and msgid
- QValueList<DiffEntry>::iterator it;
+ TQValueList<DiffEntry>::iterator it;
DiffEntry entry;
for ( it = diffList.begin(); it != diffList.end(); ++it )
@@ -663,18 +663,18 @@ bool KBabelView::openDiffFile(bool autoDiff)
KURL poBaseURL( _project->catManSettings().poBaseDir );
- QString poBase = poBaseURL.path();
+ TQString poBase = poBaseURL.path();
int len = poBase.length();
if(fileURL.path().left(len) == poBase)
{
- QString fileRelPath = fileURL.path().mid(len);
+ TQString fileRelPath = fileURL.path().mid(len);
if(fileRelPath[0] == '/')
fileRelPath=fileRelPath.mid(1);
if(_project->settings()->diffBaseDir().right(1) != "/")
_project->settings()->diffBaseDir() += '/';
- QString diffFilePath = _project->settings()->diffBaseDir() + fileRelPath;
+ TQString diffFilePath = _project->settings()->diffBaseDir() + fileRelPath;
KURL diffFileURL(diffFilePath);
@@ -706,7 +706,7 @@ bool KBabelView::openDiffFile(bool autoDiff)
Catalog cat;
- connect(&cat,SIGNAL(signalProgress(int)),this,SIGNAL(signalProgress(int)));
+ connect(&cat,TQT_SIGNAL(signalProgress(int)),this,TQT_SIGNAL(signalProgress(int)));
emit signalResetProgressBar(i18n("loading file for diff"),100);
ConversionStatus stat = cat.openURL(url);
@@ -786,19 +786,19 @@ void KBabelView::showTryLaterMessageBox()
this, "information", true, true,
KStdGuiItem::ok() );
- QVBox *topcontents = new QVBox (dialog);
+ TQVBox *topcontents = new TQVBox (dialog);
topcontents->setSpacing(KDialog::spacingHint()*2);
topcontents->setMargin(KDialog::marginHint()*2);
- QWidget *contents = new QWidget(topcontents);
- QHBoxLayout * lay = new QHBoxLayout(contents);
+ TQWidget *contents = new TQWidget(topcontents);
+ TQHBoxLayout * lay = new TQHBoxLayout(contents);
lay->setSpacing(KDialog::spacingHint()*2);
lay->addStretch(1);
- QLabel *label1 = new QLabel( contents);
- label1->setPixmap(QMessageBox::standardIcon(QMessageBox::Information));
+ TQLabel *label1 = new TQLabel( contents);
+ label1->setPixmap(TQMessageBox::standardIcon(TQMessageBox::Information));
lay->add( label1 );
- QLabel *label2 = new QLabel( i18n("The search string has not been found yet.\n"
+ TQLabel *label2 = new TQLabel( i18n("The search string has not been found yet.\n"
"However, the string might be found "
"in the files being searched at the moment.\n"
"Please try later."), contents);
@@ -807,11 +807,11 @@ void KBabelView::showTryLaterMessageBox()
lay->add( label2 );
lay->addStretch(1);
- QCheckBox *checkbox = new QCheckBox(i18n("Do not show in this find/replace session again"), topcontents);
+ TQCheckBox *checkbox = new TQCheckBox(i18n("Do not show in this find/replace session again"), topcontents);
dialog->setMainWidget(topcontents);
dialog->enableButtonSeparator(false);
- dialog->incInitialSize( QSize(50,0) );
+ dialog->incInitialSize( TQSize(50,0) );
dialog->exec();
@@ -822,7 +822,7 @@ void KBabelView::showTryLaterMessageBox()
void KBabelView::setFilePackage()
{
bool result=false;
- QString p = KInputDialog::getText(QString::null, i18n("Enter new package for the current file:"),_catalog->package(),&result,this);
+ TQString p = KInputDialog::getText(TQString::null, i18n("Enter new package for the current file:"),_catalog->package(),&result,this);
if( result )
{
_catalog->setPackage(p);
@@ -830,7 +830,7 @@ void KBabelView::setFilePackage()
}
}
-void KBabelView::insertTagFromTool( const QString& tag )
+void KBabelView::insertTagFromTool( const TQString& tag )
{
modifyMsgstrText(msgstrEdit->currentIndex(),tag);
@@ -848,14 +848,14 @@ void KBabelView::plural2msgstr()
int currentFormBegin, currentFormEnd, pos;
uint i;
- QStringList msgs = _catalog->msgstr(_currentIndex);
- QString text= *msgs.at(msgstrEdit->currentForm());
+ TQStringList msgs = _catalog->msgstr(_currentIndex);
+ TQString text= *msgs.at(msgstrEdit->currentForm());
uint numForms = _catalog->numberOfPluralForms(_currentIndex);
if( text.isEmpty() || _catalog->pluralForm(_currentIndex) == NoPluralForm) return;
- QString result;
+ TQString result;
switch( _catalog->pluralForm(_currentIndex) )
{
@@ -864,7 +864,7 @@ void KBabelView::plural2msgstr()
_catalog->applyBeginCommand( _currentIndex, Msgstr ,this);
i=0;
- for( QStringList::Iterator it=msgs.begin() ; it!=msgs.end() ; ++it )
+ for( TQStringList::Iterator it=msgs.begin() ; it!=msgs.end() ; ++it )
{
if( i!= msgstrEdit->currentForm() )
{
@@ -912,7 +912,7 @@ void KBabelView::plural2msgstr()
text=text.mid(currentFormBegin,currentFormEnd-currentFormBegin);
- QString result=text;
+ TQString result=text;
for( i=1; i<numForms ; i++ )
result+="\\n\n"+text;
@@ -925,7 +925,7 @@ void KBabelView::plural2msgstr()
}
-bool KBabelView::validateUsingTool( const KDataToolInfo & info, const QString &command )
+bool KBabelView::validateUsingTool( const KDataToolInfo & info, const TQString &command )
{
if(currentURL().isEmpty())
return false;
@@ -940,7 +940,7 @@ bool KBabelView::validateUsingTool( const KDataToolInfo & info, const QString &c
bool result=_catalog->checkUsingTool(tool);
emitEntryState();
- QString checkName = *(info.userCommands().at( info.commands().findIndex(command) ));
+ TQString checkName = *(info.userCommands().at( info.commands().findIndex(command) ));
if(result)
{
@@ -972,7 +972,7 @@ bool KBabelView::validateUsingTool( const KDataToolInfo & info, const QString &c
return result;
}
-void KBabelView::modifyUsingTool( const KDataToolInfo & info, const QString &command )
+void KBabelView::modifyUsingTool( const KDataToolInfo & info, const TQString &command )
{
KDataTool* tool = info.createTool();
if( !tool )
@@ -987,7 +987,7 @@ void KBabelView::modifyUsingTool( const KDataToolInfo & info, const QString &com
delete tool;
}
-void KBabelView::modifyCatalogUsingTool( const KDataToolInfo & info, const QString &command )
+void KBabelView::modifyCatalogUsingTool( const KDataToolInfo & info, const TQString &command )
{
KDataTool* tool = info.createTool();
if( !tool )
@@ -1002,7 +1002,7 @@ void KBabelView::modifyCatalogUsingTool( const KDataToolInfo & info, const QStri
delete tool;
}
-void KBabelView::insertChar( QChar ch )
+void KBabelView::insertChar( TQChar ch )
{
if( isReadOnly() || _catalog->package().isEmpty() )
return;
diff --git a/kbabel/kbabel/kbbookmarkhandler.cpp b/kbabel/kbabel/kbbookmarkhandler.cpp
index fde1b051..2685905b 100644
--- a/kbabel/kbabel/kbbookmarkhandler.cpp
+++ b/kbabel/kbabel/kbbookmarkhandler.cpp
@@ -31,15 +31,15 @@
**************************************************************************** */
-#include <qpopupmenu.h>
-#include <qregexp.h>
-#include <qstring.h>
+#include <tqpopupmenu.h>
+#include <tqregexp.h>
+#include <tqstring.h>
#include "kbbookmarkhandler.h"
// implementation of KBabelBookmark
-KBabelBookmark::KBabelBookmark(int msgindex, QString msgtext)
+KBabelBookmark::KBabelBookmark(int msgindex, TQString msgtext)
{
_msgindex = msgindex;
if (msgtext.length() > 32) {
@@ -49,7 +49,7 @@ KBabelBookmark::KBabelBookmark(int msgindex, QString msgtext)
// insert one '&' before every consecutive group of ampersands to keep the
// first of these from acting either as accelerator or mask in the menu
- QRegExp rx("&+");
+ TQRegExp rx("&+");
int pos = msgtext.find(rx);
while (pos >= 0) {
msgtext.insert(pos, '&');
@@ -64,14 +64,14 @@ int KBabelBookmark::msgindex() const
return _msgindex;
}
-QString KBabelBookmark::msgtext() const
+TQString KBabelBookmark::msgtext() const
{
return _msgtext;
}
// implementation of KBabelBookmarkHandler
-KBabelBookmarkHandler::KBabelBookmarkHandler(QPopupMenu* menu)
+KBabelBookmarkHandler::KBabelBookmarkHandler(TQPopupMenu* menu)
{
_menu = menu;
_list.setAutoDelete(true);
@@ -80,7 +80,7 @@ KBabelBookmarkHandler::KBabelBookmarkHandler(QPopupMenu* menu)
void KBabelBookmarkHandler::addBookmark(KBabelBookmark* b)
{
// check if a bookmark to the current msgid exists already
- QPtrListIterator<KBabelBookmark> it(_list);
+ TQPtrListIterator<KBabelBookmark> it(_list);
KBabelBookmark* temp;
while((temp = it.current()) != 0) {
@@ -94,18 +94,18 @@ void KBabelBookmarkHandler::addBookmark(KBabelBookmark* b)
// if it's okay then add the bookmark
_list.append(b);
- _menu->insertItem(QString("#%1 - %2").arg(b->msgindex()).arg(b->msgtext()),
- this, SIGNAL(signalBookmarkSelected(int)), 0, b->msgindex());
+ _menu->insertItem(TQString("#%1 - %2").arg(b->msgindex()).arg(b->msgtext()),
+ this, TQT_SIGNAL(signalBookmarkSelected(int)), 0, b->msgindex());
}
-void KBabelBookmarkHandler::addBookmark(int msgindex, QString msgtext)
+void KBabelBookmarkHandler::addBookmark(int msgindex, TQString msgtext)
{
addBookmark(new KBabelBookmark(msgindex, msgtext));
}
-void KBabelBookmarkHandler::setBookmarks(QPtrList<KBabelBookmark> list)
+void KBabelBookmarkHandler::setBookmarks(TQPtrList<KBabelBookmark> list)
{
- QPtrListIterator<KBabelBookmark> it(list);
+ TQPtrListIterator<KBabelBookmark> it(list);
KBabelBookmark* temp;
while((temp = it.current()) != 0) {
@@ -114,7 +114,7 @@ void KBabelBookmarkHandler::setBookmarks(QPtrList<KBabelBookmark> list)
}
}
-QPtrList<KBabelBookmark> KBabelBookmarkHandler::bookmarks() const
+TQPtrList<KBabelBookmark> KBabelBookmarkHandler::bookmarks() const
{
return _list;
}
diff --git a/kbabel/kbabel/kbbookmarkhandler.h b/kbabel/kbabel/kbbookmarkhandler.h
index f47c2dbf..42e94959 100644
--- a/kbabel/kbabel/kbbookmarkhandler.h
+++ b/kbabel/kbabel/kbbookmarkhandler.h
@@ -34,8 +34,8 @@
#ifndef KBBOOKMARKHANDLER_H
#define KBBOOKMARKHANDLER_H
-#include <qobject.h>
-#include <qptrlist.h>
+#include <tqobject.h>
+#include <tqptrlist.h>
class QPopupMenu;
class QString;
@@ -55,7 +55,7 @@ class KBabelBookmark
* @param msgindex the index of the bookmarked msgid.
* @param msgtext the msgid.
*/
- KBabelBookmark(int msgindex, QString msgtext);
+ KBabelBookmark(int msgindex, TQString msgtext);
/**
* Return the index of the msgid.
@@ -68,7 +68,7 @@ class KBabelBookmark
*
* @return the msgid.
*/
- QString msgtext() const;
+ TQString msgtext() const;
private:
/**
@@ -78,7 +78,7 @@ class KBabelBookmark
/**
* The classes' own copy of the msgid.
*/
- QString _msgtext;
+ TQString _msgtext;
};
@@ -96,7 +96,7 @@ class KBabelBookmarkHandler : public QObject
* @param menu the pointer to the menu where the bookmarks will be
* displayed.
*/
- KBabelBookmarkHandler(QPopupMenu* menu);
+ KBabelBookmarkHandler(TQPopupMenu* menu);
/**
* Add a bookmark.
@@ -113,20 +113,20 @@ class KBabelBookmarkHandler : public QObject
* @param msgindex the index of the bookmark's msgid.
* @param msgtext the msgindex of the bookmark to be added.
*/
- void addBookmark(int msgindex, QString msgtext);
+ void addBookmark(int msgindex, TQString msgtext);
/**
* Provide the handler with a list of bookmarks.
* Especially useful when creating a new view of the KBabel window.
*
* @param list the list to be copied.
*/
- void setBookmarks(QPtrList<KBabelBookmark> list);
+ void setBookmarks(TQPtrList<KBabelBookmark> list);
/**
* Return the list of bookmarks for a new view of the KBabel window.
*
* @return the internal list of bookmarks
*/
- QPtrList<KBabelBookmark> bookmarks() const;
+ TQPtrList<KBabelBookmark> bookmarks() const;
public slots:
/**
@@ -145,11 +145,11 @@ class KBabelBookmarkHandler : public QObject
/**
* The pointer to the menu.
*/
- QPopupMenu* _menu;
+ TQPopupMenu* _menu;
/**
* The internal list for storing the bookmarks.
*/
- QPtrList<KBabelBookmark> _list;
+ TQPtrList<KBabelBookmark> _list;
};
#endif // KBBOOKMARKHANDLER_H
diff --git a/kbabel/kbabel/kbcatalog.cpp b/kbabel/kbabel/kbcatalog.cpp
index 52205484..4c4e269a 100644
--- a/kbabel/kbabel/kbcatalog.cpp
+++ b/kbabel/kbabel/kbcatalog.cpp
@@ -35,7 +35,7 @@
#include "headereditor.h"
-KBCatalog::KBCatalog(QString configFile, QObject* parent, const char* name)
+KBCatalog::KBCatalog(TQString configFile, TQObject* parent, const char* name)
: KBabel::Catalog(parent,name,configFile)
{
_headerEditor=0;
diff --git a/kbabel/kbabel/kbcatalog.h b/kbabel/kbabel/kbcatalog.h
index ae6508cf..2c2846d4 100644
--- a/kbabel/kbabel/kbcatalog.h
+++ b/kbabel/kbabel/kbcatalog.h
@@ -48,7 +48,7 @@ class KBCatalog : public KBabel::Catalog
Q_OBJECT
public:
- KBCatalog(QString configFile = QString::null ,QObject* parent=0, const char* name=0);
+ KBCatalog(TQString configFile = TQString::null ,TQObject* parent=0, const char* name=0);
virtual ~KBCatalog();
HeaderEditor* headerEditor();
diff --git a/kbabel/kbabel/kbcataloglistview.cpp b/kbabel/kbabel/kbcataloglistview.cpp
index 51f9b008..e04da3c2 100644
--- a/kbabel/kbabel/kbcataloglistview.cpp
+++ b/kbabel/kbabel/kbcataloglistview.cpp
@@ -28,17 +28,17 @@
#include <klocale.h>
#include <klistview.h>
-#include <qcolor.h>
-#include <qlayout.h>
+#include <tqcolor.h>
+#include <tqlayout.h>
#include <kglobalsettings.h>
using namespace KBabel;
-KBCatalogListView::KBCatalogListView(KBCatalog* catalog, QWidget *parent, KBabel::Project::Ptr project)
- : QWidget(parent)
+KBCatalogListView::KBCatalogListView(KBCatalog* catalog, TQWidget *parent, KBabel::Project::Ptr project)
+ : TQWidget(parent)
{
m_catalog= catalog;
- QVBoxLayout* layout=new QVBoxLayout(this);
+ TQVBoxLayout* layout=new TQVBoxLayout(this);
m_listview = new KListView(this, "catalogListView");
m_listview->addColumn(i18n("Id"));
@@ -52,7 +52,7 @@ KBCatalogListView::KBCatalogListView(KBCatalog* catalog, QWidget *parent, KBabel
layout->addWidget(m_listview);
layout->setStretchFactor(m_listview,1);
- connect(m_listview,SIGNAL(selectionChanged(QListViewItem *)), this,SLOT(selectionChanged(QListViewItem *)));
+ connect(m_listview,TQT_SIGNAL(selectionChanged(TQListViewItem *)), this,TQT_SLOT(selectionChanged(TQListViewItem *)));
}
KBCatalogListView::~KBCatalogListView()
@@ -60,7 +60,7 @@ KBCatalogListView::~KBCatalogListView()
}
-void KBCatalogListView::selectionChanged ( QListViewItem * item)
+void KBCatalogListView::selectionChanged ( TQListViewItem * item)
{
DocPosition pos;
int number = m_items->find(reinterpret_cast<KBCatalogListViewItem*>(item));
@@ -74,7 +74,7 @@ void KBCatalogListView::selectionChanged ( QListViewItem * item)
void KBCatalogListView::setSelectedItem(int index)
{
- QListViewItem * item = m_items->at(index);
+ TQListViewItem * item = m_items->at(index);
// block signals - don't reemit the selected item signal
blockSignals(true);
@@ -100,7 +100,7 @@ void KBCatalogListView::update(EditCommand* cmd, bool undo)
*/
}
-void KBCatalogListView::msgstrChanged(const QString& str)
+void KBCatalogListView::msgstrChanged(const TQString& str)
{
KBCatalogListViewItem * item = reinterpret_cast<KBCatalogListViewItem *>(m_listview->selectedItem());
item->setMsgStr(str);
@@ -112,12 +112,12 @@ void KBCatalogListView::slotNewFileOpened()
KBCatalogListViewItem * tempItem;
if(m_catalog)
{
- m_items = new QPtrVector<KBCatalogListViewItem>(m_catalog->numberOfEntries());
+ m_items = new TQPtrVector<KBCatalogListViewItem>(m_catalog->numberOfEntries());
for(uint i=0;i<m_catalog->numberOfEntries();i++)
{
- QString msgid = ( *m_catalog->msgid(i).at(0) );
- QString msgstr = ( *m_catalog->msgstr(i).at(0) );
+ TQString msgid = ( *m_catalog->msgid(i).at(0) );
+ TQString msgstr = ( *m_catalog->msgstr(i).at(0) );
tempItem = new KBCatalogListViewItem(m_listview,0,i+1,
msgid,
msgstr);
diff --git a/kbabel/kbabel/kbcataloglistview.h b/kbabel/kbabel/kbcataloglistview.h
index d9737871..c2c46bdf 100644
--- a/kbabel/kbabel/kbcataloglistview.h
+++ b/kbabel/kbabel/kbcataloglistview.h
@@ -23,11 +23,11 @@
#ifndef KBCATALOGLISTVIEW_H
#define KBCATALOGLISTVIEW_H
-#include <qwidget.h>
+#include <tqwidget.h>
#include <catalogview.h>
#include <kconfig.h>
-#include <qwidget.h>
-//#include <qstrlist.h>
+#include <tqwidget.h>
+//#include <tqstrlist.h>
#include <resources.h>
#include "catalog.h"
#include "kbcatalog.h"
@@ -47,11 +47,11 @@ class KListView;
/**
@author
*/
-class KBCatalogListView : public QWidget, public KBabel::CatalogView
+class KBCatalogListView : public TQWidget, public KBabel::CatalogView
{
Q_OBJECT
public:
- KBCatalogListView(KBCatalog* catalog, QWidget *parent, KBabel::Project::Ptr project);
+ KBCatalogListView(KBCatalog* catalog, TQWidget *parent, KBabel::Project::Ptr project);
~KBCatalogListView();
@@ -68,15 +68,15 @@ signals:
public slots:
virtual void slotNewFileOpened();
- void msgstrChanged(const QString&);
+ void msgstrChanged(const TQString&);
private:
KListView * m_listview;
KBCatalog* m_catalog;
- QPtrVector<KBCatalogListViewItem>* m_items;
+ TQPtrVector<KBCatalogListViewItem>* m_items;
private slots:
- void selectionChanged ( QListViewItem * item);
+ void selectionChanged ( TQListViewItem * item);
};
#endif
diff --git a/kbabel/kbabel/kbcataloglistviewitem.cpp b/kbabel/kbabel/kbcataloglistviewitem.cpp
index 5a4012a2..4bbc3049 100644
--- a/kbabel/kbabel/kbcataloglistviewitem.cpp
+++ b/kbabel/kbabel/kbcataloglistviewitem.cpp
@@ -23,10 +23,10 @@
#include "kbcataloglistviewitem.h"
#include <assert.h>
-KBCatalogListViewItem::KBCatalogListViewItem(KListView* lv, KListViewItem* parent, uint id, QString msgid, QString msgstr)
+KBCatalogListViewItem::KBCatalogListViewItem(KListView* lv, KListViewItem* parent, uint id, TQString msgid, TQString msgstr)
: Super(lv, parent, "","",""), m_id(id), m_msgid(msgid), m_msgstr(msgstr)
{
- setText(0,QString::number(id));
+ setText(0,TQString::number(id));
}
@@ -34,14 +34,14 @@ KBCatalogListViewItem::~KBCatalogListViewItem()
{
}
-void KBCatalogListViewItem::setMsgId(const QString& st)
+void KBCatalogListViewItem::setMsgId(const TQString& st)
{
m_msgid = st;
setup();
repaint();
}
-void KBCatalogListViewItem::setMsgStr(const QString& st)
+void KBCatalogListViewItem::setMsgStr(const TQString& st)
{
m_msgstr = st;
setup();
@@ -60,10 +60,10 @@ void KBCatalogListViewItem::setId(const uint id)
repaint();
}
-QString KBCatalogListViewItem::key ( int column, bool ascending ) const{
+TQString KBCatalogListViewItem::key ( int column, bool ascending ) const{
if(column==0)
- return QString().sprintf("%.8u", m_id);
+ return TQString().sprintf("%.8u", m_id);
else if(column==1)
return m_msgid;
else if(column==2)
@@ -84,7 +84,7 @@ void KBCatalogListViewItem::setup()
makeDocAvailable();
- QListView* lv = listView();
+ TQListView* lv = listView();
m_doc_msgid->setWidth(std::max(1, int(lv->columnWidth(1))));
m_doc_msgstr->setWidth(std::max(1, int(lv->columnWidth(2))));
@@ -97,7 +97,7 @@ void KBCatalogListViewItem::setup()
}
-void KBCatalogListViewItem::paintMsgIdCell(QPainter* p, const QColorGroup& cg,
+void KBCatalogListViewItem::paintMsgIdCell(TQPainter* p, const TQColorGroup& cg,
int column, int width, int align)
{
// check width
@@ -123,11 +123,11 @@ void KBCatalogListViewItem::paintMsgIdCell(QPainter* p, const QColorGroup& cg,
// draw it
- m_doc_msgid->draw(p, 0, 0, QRect(0,0, width, height()), cg);
+ m_doc_msgid->draw(p, 0, 0, TQRect(0,0, width, height()), cg);
}
-void KBCatalogListViewItem::paintMsgStrCell(QPainter* p, const QColorGroup& cg,
+void KBCatalogListViewItem::paintMsgStrCell(TQPainter* p, const TQColorGroup& cg,
int column, int width, int align)
{
// check width
@@ -162,11 +162,11 @@ void KBCatalogListViewItem::paintMsgStrCell(QPainter* p, const QColorGroup& cg,
// draw it
- m_doc_msgstr->draw(p, 0, 0, QRect(0,0, width, height()), cg);
+ m_doc_msgstr->draw(p, 0, 0, TQRect(0,0, width, height()), cg);
}
-void KBCatalogListViewItem::paintCell(QPainter* p, const QColorGroup& cg,
+void KBCatalogListViewItem::paintCell(TQPainter* p, const TQColorGroup& cg,
int column, int width, int align)
{
assert(m_doc_msgid.get() && m_doc_msgstr.get() && p);
@@ -195,16 +195,16 @@ void KBCatalogListViewItem::makeDocAvailable()
assert(listView());
- m_doc_msgid.reset(new QSimpleRichText(
+ m_doc_msgid.reset(new TQSimpleRichText(
formatMsg(m_msgid), listView()->font()));
- m_doc_msgstr.reset(new QSimpleRichText(
+ m_doc_msgstr.reset(new TQSimpleRichText(
formatMsg(m_msgstr), listView()->font()));
}
-QString KBCatalogListViewItem::formatMsg(const QString str)
+TQString KBCatalogListViewItem::formatMsg(const TQString str)
{
// TODO: Use KBHighlighting for this
- QString tmp_msgid = str;
+ TQString tmp_msgid = str;
tmp_msgid = tmp_msgid.replace( "\\n", "<br>" );
tmp_msgid = tmp_msgid.replace( "<", "&lt;" );
tmp_msgid = tmp_msgid.replace( ">", "&gt;" );
diff --git a/kbabel/kbabel/kbcataloglistviewitem.h b/kbabel/kbabel/kbcataloglistviewitem.h
index 8fa6704a..4a24c159 100644
--- a/kbabel/kbabel/kbcataloglistviewitem.h
+++ b/kbabel/kbabel/kbcataloglistviewitem.h
@@ -24,7 +24,7 @@
#define KBCATALOGLISTVIEWITEM_H
#include <memory>
#include <klistview.h>
-#include <qsimplerichtext.h>
+#include <tqsimplerichtext.h>
#include "mymultilineedit.h"
/**
@@ -34,39 +34,39 @@ class KBCatalogListViewItem : public KListViewItem
{
typedef KListViewItem Super;
public:
- KBCatalogListViewItem(KListView* lv, KListViewItem* parent, uint id, QString msgid, QString msgstr);
+ KBCatalogListViewItem(KListView* lv, KListViewItem* parent, uint id, TQString msgid, TQString msgstr);
~KBCatalogListViewItem();
- void setMsgId(const QString& st);
- void setMsgStr(const QString& st);
+ void setMsgId(const TQString& st);
+ void setMsgStr(const TQString& st);
void setId(const uint id);
uint getId();
protected:
virtual void setup();
- virtual QString key ( int column, bool ascending ) const;
+ virtual TQString key ( int column, bool ascending ) const;
- virtual void paintCell(QPainter* p, const QColorGroup& cg,
+ virtual void paintCell(TQPainter* p, const TQColorGroup& cg,
int column, int width, int align);
private:
void makeDocAvailable();
- void paintMsgIdCell(QPainter* p, const QColorGroup& cg,
+ void paintMsgIdCell(TQPainter* p, const TQColorGroup& cg,
int column, int width, int align);
- void paintMsgStrCell(QPainter* p, const QColorGroup& cg,
+ void paintMsgStrCell(TQPainter* p, const TQColorGroup& cg,
int column, int width, int align);
- QString formatMsg(const QString str);
+ TQString formatMsg(const TQString str);
uint m_id;
- QString m_msgid;
- QString m_msgstr;
+ TQString m_msgid;
+ TQString m_msgstr;
- std::auto_ptr<QSimpleRichText> m_doc_msgid;
- std::auto_ptr<QSimpleRichText> m_doc_msgstr;
+ std::auto_ptr<TQSimpleRichText> m_doc_msgid;
+ std::auto_ptr<TQSimpleRichText> m_doc_msgstr;
};
#endif
diff --git a/kbabel/kbabel/kbcatalogview.cpp b/kbabel/kbabel/kbcatalogview.cpp
index ba8e9c03..ae701c4e 100644
--- a/kbabel/kbabel/kbcatalogview.cpp
+++ b/kbabel/kbabel/kbcatalogview.cpp
@@ -36,8 +36,8 @@
using namespace KBabel;
-KBCatalogView::KBCatalogView(KBCatalog* catalog, QWidget* parent, Project::Ptr project)
- : QWidget (parent), KBabel::CatalogView () , _project (project)
+KBCatalogView::KBCatalogView(KBCatalog* catalog, TQWidget* parent, Project::Ptr project)
+ : TQWidget (parent), KBabel::CatalogView () , _project (project)
{
if (catalog == 0)
kdFatal(KBABEL) << "catalog==0" << endl;
@@ -49,8 +49,8 @@ KBCatalogView::KBCatalogView(KBCatalog* catalog, QWidget* parent, Project::Ptr p
_currentIndex=1; // here we use 1 to accept update at opening a file
- connect ( _project, SIGNAL (signalSettingsChanged()), this, SLOT (readProjectSettings()) );
- connect ( _catalog, SIGNAL (signalFileOpened(bool)), this, SLOT (readFileSettings() ) );
+ connect ( _project, TQT_SIGNAL (signalSettingsChanged()), this, TQT_SLOT (readProjectSettings()) );
+ connect ( _catalog, TQT_SIGNAL (signalFileOpened(bool)), this, TQT_SLOT (readFileSettings() ) );
readProjectSettings();
readFileSettings();
diff --git a/kbabel/kbabel/kbcatalogview.h b/kbabel/kbabel/kbcatalogview.h
index 5f23381a..355e2a4c 100644
--- a/kbabel/kbabel/kbcatalogview.h
+++ b/kbabel/kbabel/kbcatalogview.h
@@ -33,21 +33,21 @@
#ifndef KBCATALOGVIEW_H
#define KBCATALOGVIEW_H
-#include <qwidget.h>
+#include <tqwidget.h>
#include <catalogview.h>
#include "kbcatalog.h"
#include "kbproject.h"
#include "projectsettings.h"
-class KBCatalogView : public QWidget, public KBabel::CatalogView
+class KBCatalogView : public TQWidget, public KBabel::CatalogView
{
Q_OBJECT
public:
/**
* Default constructor
*/
- KBCatalogView(KBCatalog* catalog, QWidget* parent, KBabel::Project::Ptr project);
+ KBCatalogView(KBCatalog* catalog, TQWidget* parent, KBabel::Project::Ptr project);
/**
* Destructor
diff --git a/kbabel/kbabel/kbcharselect.cpp b/kbabel/kbabel/kbcharselect.cpp
index 63316255..8dd87bcc 100644
--- a/kbabel/kbabel/kbcharselect.cpp
+++ b/kbabel/kbabel/kbcharselect.cpp
@@ -37,32 +37,32 @@
#include <kdialog.h>
#include <klocale.h>
-#include <qlabel.h>
-#include <qspinbox.h>
-#include <qscrollview.h>
+#include <tqlabel.h>
+#include <tqspinbox.h>
+#include <tqscrollview.h>
-KBCharSelect::KBCharSelect(QWidget* parent,const char* name)
- : QVBox(parent,name)
+KBCharSelect::KBCharSelect(TQWidget* parent,const char* name)
+ : TQVBox(parent,name)
{
setSpacing( KDialog::spacingHint() );
- QHBox* bar = new QHBox(this);
+ TQHBox* bar = new TQHBox(this);
bar->setSpacing( KDialog::spacingHint() );
- QLabel *lTable = new QLabel( i18n( "Table:" ), bar );
- _tableNum = new QSpinBox( 0, 255, 1, bar );
+ TQLabel *lTable = new TQLabel( i18n( "Table:" ), bar );
+ _tableNum = new TQSpinBox( 0, 255, 1, bar );
lTable->setBuddy( _tableNum );
bar->setStretchFactor( _tableNum, 1 );
- QScrollView* scroll = new QScrollView( this );
+ TQScrollView* scroll = new TQScrollView( this );
_table = new KCharSelectTable(scroll,"charselector","helvetica",' ',0);
_table->setNumCols(16);
_table->setNumRows(16);
scroll->addChild(_table);
- connect( _table, SIGNAL( doubleClicked() ), this, SLOT( emitChar() ) );
- connect( _tableNum, SIGNAL( valueChanged(int) ), this, SLOT( setTab(int) ));
+ connect( _table, TQT_SIGNAL( doubleClicked() ), this, TQT_SLOT( emitChar() ) );
+ connect( _tableNum, TQT_SIGNAL( valueChanged(int) ), this, TQT_SLOT( setTab(int) ));
}
void KBCharSelect::emitChar()
@@ -80,7 +80,7 @@ void KBCharSelect::saveSettings(KConfig* config)
KConfigGroupSaver saver(config, "KBCharSelector" );
config->writeEntry( "TableNum", _tableNum->value() );
- config->writeEntry( "SelectedChar", QString(_table->chr()) );
+ config->writeEntry( "SelectedChar", TQString(_table->chr()) );
}
void KBCharSelect::restoreSettings(KConfig* config)
diff --git a/kbabel/kbabel/kbcharselect.h b/kbabel/kbabel/kbcharselect.h
index 4de3460f..7b42318c 100644
--- a/kbabel/kbabel/kbcharselect.h
+++ b/kbabel/kbabel/kbcharselect.h
@@ -33,7 +33,7 @@
#ifndef KBCHARSELECT_H
#define KBCHARSELECT_H
-#include <qvbox.h>
+#include <tqvbox.h>
class KConfig;
class KCharSelectTable;
@@ -43,13 +43,13 @@ class KBCharSelect : public QVBox
{
Q_OBJECT
public:
- KBCharSelect(QWidget* parent, const char* name=0);
+ KBCharSelect(TQWidget* parent, const char* name=0);
void saveSettings(KConfig* config);
void restoreSettings(KConfig* config);
signals:
- void characterDoubleClicked( QChar ch );
+ void characterDoubleClicked( TQChar ch );
public slots:
void emitChar();
@@ -59,7 +59,7 @@ private slots:
private:
KCharSelectTable* _table;
- QSpinBox* _tableNum;
+ TQSpinBox* _tableNum;
};
#endif // KBCHARSELECT_H
diff --git a/kbabel/kbabel/kbhighlighting.cpp b/kbabel/kbabel/kbhighlighting.cpp
index ce58c483..3d555d7b 100644
--- a/kbabel/kbabel/kbhighlighting.cpp
+++ b/kbabel/kbabel/kbhighlighting.cpp
@@ -34,10 +34,10 @@
**************************************************************************** */
-#include <qcolor.h>
-#include <qregexp.h>
-#include <qstring.h>
-#include <qtextedit.h>
+#include <tqcolor.h>
+#include <tqregexp.h>
+#include <tqstring.h>
+#include <tqtextedit.h>
#include "kapplication.h"
#include <kconfig.h>
@@ -49,7 +49,7 @@
#include "kbhighlighting.h"
#include "resources.h"
-KBabelHighlighter::KBabelHighlighter( QTextEdit * edit, KSpell *spell ) : QObject()
+KBabelHighlighter::KBabelHighlighter( TQTextEdit * edit, KSpell *spell ) : TQObject()
, _edit( edit )
, syntaxHighlighting(true)
, mSpell(0), alwaysEndsWithSpace(true)
@@ -74,7 +74,7 @@ KBabelHighlighter::KBabelHighlighter( QTextEdit * edit, KSpell *spell ) : QObjec
readSettings( );
regexps << accelMarker + "[\\w]";
- connect( _edit, SIGNAL( textChanged( ) ), this, SLOT( highlight( ) ) );
+ connect( _edit, TQT_SIGNAL( textChanged( ) ), this, TQT_SLOT( highlight( ) ) );
setSpellChecker(spell);
}
@@ -97,10 +97,10 @@ void KBabelHighlighter::highlight( )
// create a single line out of the text: remove "\n", so that we only
// have to deal with one single line of text.
- QString text = _edit->text( );
+ TQString text = _edit->text( );
text.replace( "\n", "" );
- QRegExp rx;
+ TQRegExp rx;
int pos;
if (syntaxHighlighting)
@@ -180,7 +180,7 @@ void KBabelHighlighter::doHighlighting( HighlightType type, int pos, int length
_edit->removeSelection( );
}
-void KBabelHighlighter::setHighlightColor( HighlightType type, QColor color )
+void KBabelHighlighter::setHighlightColor( HighlightType type, TQColor color )
{
colors[type] = color;
}
@@ -195,7 +195,7 @@ void KBabelHighlighter::readSettings( )
// FIXME: does not care about different projects yet
KConfig * config = KGlobal::config( );
config->setGroup( "Misc" );
- QString temp = config->readEntry( "AccelMarker", "&" );
+ TQString temp = config->readEntry( "AccelMarker", "&" );
accelMarker = temp[0];
}
@@ -210,14 +210,14 @@ void KBabelHighlighter::flushCurrentWord()
currentPos++;
}
- QChar ch;
+ TQChar ch;
while ((ch = currentWord[(int) currentWord.length() - 1]).isPunct()
&& ch != '(' && ch != '@')
currentWord.truncate( currentWord.length() - 1 );
// try to remove tags (they might not be fully compliant, but
// we don't want to check them anyway
- QRegExp tags("(<[-_.:A-Za-z0-9]*([\\s]*[-_.:A-Za-z0-9]*=\\\\\"[^<>]*\\\\\")*[\\s]*/?>)|(</[-_.:A-Za-z0-9]*[\\s]*>)");
+ TQRegExp tags("(<[-_.:A-Za-z0-9]*([\\s]*[-_.:A-Za-z0-9]*=\\\\\"[^<>]*\\\\\")*[\\s]*/?>)|(</[-_.:A-Za-z0-9]*[\\s]*>)");
if( tags.search (currentWord) != -1 )
{
currentPos += tags.matchedLength();
@@ -228,7 +228,7 @@ void KBabelHighlighter::flushCurrentWord()
if (!currentWord.isEmpty()) {
bool isPlainWord = true;
for (int i = 0; i < (int) currentWord.length(); i++) {
- QChar ch = currentWord[i];
+ TQChar ch = currentWord[i];
if (ch.upper() == ch) {
isPlainWord = false;
break;
@@ -241,15 +241,15 @@ void KBabelHighlighter::flushCurrentWord()
currentWord = "";
}
-QDict<int> KBabelHighlighter::dict(50021);
+TQDict<int> KBabelHighlighter::dict(50021);
-bool KBabelHighlighter::isMisspelled(const QString& wordRaw)
+bool KBabelHighlighter::isMisspelled(const TQString& wordRaw)
{
// We have to treat ampersands (like in "&go" or "g&o") in a special way.
// they must not break the word. And we cannot change the parameter, as
// then the highlight would be one character short. So we have to copy the
// word first.
- QString word = wordRaw;
+ TQString word = wordRaw;
kdDebug(KBABEL) << "isampersand: checking (raw):" << word << endl;
word.replace("&", "" );
kdDebug(KBABEL) << "isMisspelled: checking: " << word << endl;
@@ -271,8 +271,8 @@ bool KBabelHighlighter::isMisspelled(const QString& wordRaw)
return false;
}
-void KBabelHighlighter::slotMisspelling(const QString & originalword,
- const QStringList & suggestions, unsigned int)
+void KBabelHighlighter::slotMisspelling(const TQString & originalword,
+ const TQStringList & suggestions, unsigned int)
{
kdDebug(KBABEL) << "Misspelled " << originalword << ", " << suggestions << endl;
dict.replace( originalword, NotOkay );
@@ -285,8 +285,8 @@ void KBabelHighlighter::setSpellChecker( KSpell* spell )
{
if( mSpell )
{
- disconnect(mSpell, SIGNAL(misspelling(const QString &, const QStringList &, unsigned int)),
- this, SLOT(slotMisspelling(const QString &, const QStringList &, unsigned int)));
+ disconnect(mSpell, TQT_SIGNAL(misspelling(const TQString &, const TQStringList &, unsigned int)),
+ this, TQT_SLOT(slotMisspelling(const TQString &, const TQStringList &, unsigned int)));
// cleanup the cache
dict.clear();
@@ -296,8 +296,8 @@ void KBabelHighlighter::setSpellChecker( KSpell* spell )
if( mSpell )
{
- connect(mSpell, SIGNAL(misspelling(const QString &, const QStringList &, unsigned int)),
- this, SLOT(slotMisspelling(const QString &, const QStringList &, unsigned int)));
+ connect(mSpell, TQT_SIGNAL(misspelling(const TQString &, const TQStringList &, unsigned int)),
+ this, TQT_SLOT(slotMisspelling(const TQString &, const TQStringList &, unsigned int)));
// wait for KSpell to startup correctly
kapp->processEvents(500);
diff --git a/kbabel/kbabel/kbhighlighting.h b/kbabel/kbabel/kbhighlighting.h
index 91a6202d..fe93e0ef 100644
--- a/kbabel/kbabel/kbhighlighting.h
+++ b/kbabel/kbabel/kbhighlighting.h
@@ -37,10 +37,10 @@
#ifndef KBHIGHLIGHTING_H
#define KBHIGHLIGHTING_H
-#include <qmemarray.h>
-#include <qobject.h>
-#include <qstringlist.h>
-#include <qguardedptr.h>
+#include <tqmemarray.h>
+#include <tqobject.h>
+#include <tqstringlist.h>
+#include <tqguardedptr.h>
class KSpell;
class QColor;
@@ -63,21 +63,21 @@ class KBabelHighlighter : public QObject
SpellcheckError
};
- KBabelHighlighter( QTextEdit * edit, KSpell *spell );
+ KBabelHighlighter( TQTextEdit * edit, KSpell *spell );
- void setHighlightColor( HighlightType type, QColor color );
+ void setHighlightColor( HighlightType type, TQColor color );
void setHasErrors( bool err );
void setSpellChecker( KSpell* spell);
- bool isMisspelled(const QString& word);
+ bool isMisspelled(const TQString& word);
public slots:
void highlight( );
void setSyntaxHighlighting( bool enable );
protected slots:
- void slotMisspelling (const QString & originalword,
- const QStringList & suggestions, unsigned int pos);
+ void slotMisspelling (const TQString & originalword,
+ const TQStringList & suggestions, unsigned int pos);
private:
void doHighlighting( HighlightType type, int pos, int length );
@@ -85,18 +85,18 @@ class KBabelHighlighter : public QObject
void flushCurrentWord();
private:
- QTextEdit * _edit;
+ TQTextEdit * _edit;
bool syntaxHighlighting;
- QStringList regexps;
- QMemArray<QColor> colors;
+ TQStringList regexps;
+ TQMemArray<TQColor> colors;
bool _hasErrors;
- QString accelMarker;
+ TQString accelMarker;
- static QDict<int> dict;
- QGuardedPtr<KSpell> mSpell;
- QString currentWord;
+ static TQDict<int> dict;
+ TQGuardedPtr<KSpell> mSpell;
+ TQString currentWord;
int currentPos;
bool alwaysEndsWithSpace;
};
diff --git a/kbabel/kbabel/main.cpp b/kbabel/kbabel/main.cpp
index 40c28926..5758d563 100644
--- a/kbabel/kbabel/main.cpp
+++ b/kbabel/kbabel/main.cpp
@@ -49,41 +49,41 @@
#include <kuniqueapplication.h>
#include <kwin.h>
-#include <qfile.h>
-#include <qfileinfo.h>
-#include <qtimer.h>
+#include <tqfile.h>
+#include <tqfileinfo.h>
+#include <tqtimer.h>
class KBabelInterface : public KBabelIface
{
public:
KBabelInterface();
- virtual void openURL(QCString url, QCString package, WId window, int newWindow);
- virtual void openURL(QCString url, QCString package, WId window, int newWindow, QCString projectFile);
- virtual void openTemplate(QCString openFilename, QCString saveFilename, QCString package, int newWindow );
- virtual void openTemplate(QCString openFilename, QCString saveFilename, QCString package, int newWindow, QCString projectFile );
- virtual void gotoFileEntry(QCString url, QCString msgid);
- virtual void gotoFileEntry(QCString url, QCString package, int msgid);
- virtual void gotoFileEntry(QCString url, QCString package, int msgid, QCString projectFile);
- virtual bool findInFile(QCString fileSource, QCString url,
- QString findStr, int caseSensitive, int wholeWords, int isRegExp,
+ virtual void openURL(TQCString url, TQCString package, WId window, int newWindow);
+ virtual void openURL(TQCString url, TQCString package, WId window, int newWindow, TQCString projectFile);
+ virtual void openTemplate(TQCString openFilename, TQCString saveFilename, TQCString package, int newWindow );
+ virtual void openTemplate(TQCString openFilename, TQCString saveFilename, TQCString package, int newWindow, TQCString projectFile );
+ virtual void gotoFileEntry(TQCString url, TQCString msgid);
+ virtual void gotoFileEntry(TQCString url, TQCString package, int msgid);
+ virtual void gotoFileEntry(TQCString url, TQCString package, int msgid, TQCString projectFile);
+ virtual bool findInFile(TQCString fileSource, TQCString url,
+ TQString findStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave);
- virtual bool replaceInFile(QCString fileSource, QCString url,
- QString findStr, QString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
+ virtual bool replaceInFile(TQCString fileSource, TQCString url,
+ TQString findStr, TQString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
int ignoreAccelMarker, int ignoreContextInfo, int ask, int askForNextFile, int askForSave);
- virtual bool findInFile(QCString fileSource, QCString url,
- QString findStr, int caseSensitive, int wholeWords, int isRegExp,
+ virtual bool findInFile(TQCString fileSource, TQCString url,
+ TQString findStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
- int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave, QCString project );
- virtual bool replaceInFile(QCString fileSource, QCString url,
- QString findStr, QString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
+ int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave, TQCString project );
+ virtual bool replaceInFile(TQCString fileSource, TQCString url,
+ TQString findStr, TQString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
- int ignoreAccelMarker, int ignoreContextInfo, int ask, int askForNextFile, int askForSave, QCString project );
- virtual void spellcheck(QStringList fileList);
+ int ignoreAccelMarker, int ignoreContextInfo, int ask, int askForNextFile, int askForSave, TQCString project );
+ virtual void spellcheck(TQStringList fileList);
private:
- KBabelMW* findInstance( const KURL& url, const QString& project, const QString& package) const;
+ KBabelMW* findInstance( const KURL& url, const TQString& project, const TQString& package) const;
};
@@ -130,8 +130,8 @@ int KBabelApp::newInstance()
KCmdLineArgs *args = KCmdLineArgs::parsedArgs();
- QTimer timer;
- QWidget *splash=0;
+ TQTimer timer;
+ TQWidget *splash=0;
bool showSplash=args->isSet("splash");
if( showSplash && first )
@@ -142,10 +142,10 @@ int KBabelApp::newInstance()
timer.start(4000,true);
}
- QString projectFile=args->getOption("project");
+ TQString projectFile=args->getOption("project");
if( !projectFile.isEmpty() )
{
- QFileInfo fi(projectFile);
+ TQFileInfo fi(projectFile);
projectFile = fi.absFilePath();
}
else
@@ -155,11 +155,11 @@ int KBabelApp::newInstance()
}
kdDebug() << "Project: " << projectFile << endl;
- QCString msgid=args->getOption("gotomsgid");
+ TQCString msgid=args->getOption("gotomsgid");
if(!msgid.isEmpty() && args->count() > 0)
{
kdDebug(KBABEL) << "gotomsgid" << endl;
- QString m = QString::fromLocal8Bit(msgid);
+ TQString m = TQString::fromLocal8Bit(msgid);
kdDebug () << "Resuming DCOP" << endl;
kapp->dcopClient()->resume();
@@ -187,7 +187,7 @@ int KBabelApp::newInstance()
widget->show();
for (int i=0; i < args->count(); i++)
{
- widget->open( args->url(i) , QString::null, i != 0 );
+ widget->open( args->url(i) , TQString::null, i != 0 );
}
kdDebug () << "Resuming DCOP" << endl;
@@ -223,18 +223,18 @@ KBabelInterface::KBabelInterface()
{
}
-void KBabelInterface::openURL(QCString url, QCString package, WId window, int newWindow)
+void KBabelInterface::openURL(TQCString url, TQCString package, WId window, int newWindow)
{
openURL(url,package,window,newWindow, KBabel::ProjectManager::defaultProjectName().local8Bit());
}
-void KBabelInterface::openURL(QCString url, QCString package, WId window, int newWindow, QCString projectFile)
+void KBabelInterface::openURL(TQCString url, TQCString package, WId window, int newWindow, TQCString projectFile)
{
- const QString project( QString::fromLocal8Bit( projectFile ) );
+ const TQString project( TQString::fromLocal8Bit( projectFile ) );
kdDebug() << "openURL " << url << endl;
- KURL u(QString::fromLocal8Bit(url));
+ KURL u(TQString::fromLocal8Bit(url));
kdDebug () << "Suspending DCOP" << endl;
kapp->dcopClient()->suspend();
@@ -256,7 +256,7 @@ void KBabelInterface::openURL(QCString url, QCString package, WId window, int ne
{
kb = static_cast<KBabelMW*>(mw);
KWin::activateWindow(kb->topLevelWidget()->winId());
- kb->open(u, QString::fromUtf8(package),newWindow);
+ kb->open(u, TQString::fromUtf8(package),newWindow);
kdDebug () << "Resuming DCOP" << endl;
kapp->dcopClient()->resume();
@@ -274,7 +274,7 @@ void KBabelInterface::openURL(QCString url, QCString package, WId window, int ne
// it's empty
KWin::setActiveWindow(kb->topLevelWidget()->winId());
kb->projectOpen(projectFile);
- kb->open(u,QString::fromUtf8(package),false);
+ kb->open(u,TQString::fromUtf8(package),false);
kdDebug () << "Resuming DCOP" << endl;
kapp->dcopClient()->resume();
@@ -290,7 +290,7 @@ void KBabelInterface::openURL(QCString url, QCString package, WId window, int ne
{
kb = static_cast<KBabelMW*>(mw);
KWin::activateWindow(kb->topLevelWidget()->winId());
- kb->open(u, QString::fromUtf8(package),newWindow);
+ kb->open(u, TQString::fromUtf8(package),newWindow);
kdDebug () << "Resuming DCOP" << endl;
kapp->dcopClient()->resume();
@@ -306,24 +306,24 @@ void KBabelInterface::openURL(QCString url, QCString package, WId window, int ne
kb->show();
} else kb = static_cast<KBabelMW*>(mw);
KWin::activateWindow(kb->topLevelWidget()->winId());
- kb->open(u,QString::fromUtf8(package),newWindow);
+ kb->open(u,TQString::fromUtf8(package),newWindow);
}
kdDebug () << "Resuming DCOP" << endl;
kapp->dcopClient()->resume();
}
-void KBabelInterface::openTemplate(QCString openFilename, QCString saveFilename, QCString package, int newWindow)
+void KBabelInterface::openTemplate(TQCString openFilename, TQCString saveFilename, TQCString package, int newWindow)
{
openTemplate(openFilename, saveFilename, package, newWindow, KBabel::ProjectManager::defaultProjectName().local8Bit());
}
-void KBabelInterface::openTemplate(QCString openFilename, QCString saveFilename, QCString package, int newWindow, QCString projectFile)
+void KBabelInterface::openTemplate(TQCString openFilename, TQCString saveFilename, TQCString package, int newWindow, TQCString projectFile)
{
- const QString project( QString::fromLocal8Bit( projectFile ) );
+ const TQString project( TQString::fromLocal8Bit( projectFile ) );
- const KURL u( QString::fromLocal8Bit( saveFilename ) );
- const KURL t( QString::fromLocal8Bit( openFilename ) );
+ const KURL u( TQString::fromLocal8Bit( saveFilename ) );
+ const KURL t( TQString::fromLocal8Bit( openFilename ) );
kdDebug () << "Suspending DCOP" << endl;
kapp->dcopClient()->suspend();
@@ -344,14 +344,14 @@ void KBabelInterface::openTemplate(QCString openFilename, QCString saveFilename,
kb = static_cast<KBabelMW*>(mw);
KWin::activateWindow(kb->topLevelWidget()->winId());
kb->projectOpen(projectFile);
- kb->openTemplate(t,u,QString::fromUtf8(package),newWindow);
+ kb->openTemplate(t,u,TQString::fromUtf8(package),newWindow);
}
else
{
kb = new KBabelMW(project);
kb->show();
KWin::activateWindow(kb->topLevelWidget()->winId());
- kb->openTemplate(t,u,QString::fromUtf8(package));
+ kb->openTemplate(t,u,TQString::fromUtf8(package));
}
}
@@ -359,14 +359,14 @@ void KBabelInterface::openTemplate(QCString openFilename, QCString saveFilename,
kapp->dcopClient()->resume();
}
-void KBabelInterface::gotoFileEntry(QCString url, QCString m)
+void KBabelInterface::gotoFileEntry(TQCString url, TQCString m)
{
- const KURL u( QString::fromLocal8Bit( url ) );
- KBabelMW *kb = findInstance( u, KBabel::ProjectManager::defaultProjectName(), QString() );
+ const KURL u( TQString::fromLocal8Bit( url ) );
+ KBabelMW *kb = findInstance( u, KBabel::ProjectManager::defaultProjectName(), TQString() );
if(!kb) return;
- QString msgid = QString::fromUtf8(m);
+ TQString msgid = TQString::fromUtf8(m);
int index = kb->m_view->catalog()->indexForMsgid(msgid);
if(index >= 0)
{
@@ -377,15 +377,15 @@ void KBabelInterface::gotoFileEntry(QCString url, QCString m)
}
}
-void KBabelInterface::gotoFileEntry(QCString url, QCString package, int m)
+void KBabelInterface::gotoFileEntry(TQCString url, TQCString package, int m)
{
gotoFileEntry(url, package, m, KBabel::ProjectManager::defaultProjectName().local8Bit() );
}
-void KBabelInterface::gotoFileEntry(QCString url, QCString package, int m, QCString projectFile)
+void KBabelInterface::gotoFileEntry(TQCString url, TQCString package, int m, TQCString projectFile)
{
- const KURL u ( QString::fromLocal8Bit( url ) );
- const QString p ( QString::fromUtf8( package ) ); // ### VERIFY encoding!
+ const KURL u ( TQString::fromLocal8Bit( url ) );
+ const TQString p ( TQString::fromUtf8( package ) ); // ### VERIFY encoding!
KBabelMW *kb = findInstance( u, projectFile, p );
if(!kb) return;
@@ -396,8 +396,8 @@ void KBabelInterface::gotoFileEntry(QCString url, QCString package, int m, QCStr
kb->m_view->gotoEntry(pos);
}
-bool KBabelInterface::findInFile(QCString fileSource, QCString url,
- QString findStr, int caseSensitive, int wholeWords, int isRegExp,
+bool KBabelInterface::findInFile(TQCString fileSource, TQCString url,
+ TQString findStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave)
{
@@ -408,15 +408,15 @@ bool KBabelInterface::findInFile(QCString fileSource, QCString url,
KBabel::ProjectManager::defaultProjectName().utf8() );
}
-bool KBabelInterface::findInFile(QCString fileSource, QCString url,
- QString findStr, int caseSensitive, int wholeWords, int isRegExp,
+bool KBabelInterface::findInFile(TQCString fileSource, TQCString url,
+ TQString findStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
- int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave, QCString project )
+ int ignoreAccelMarker, int ignoreContextInfo, int askForNextFile, int askForSave, TQCString project )
{
kdDebug(KBABEL) << "findInFile (" <<fileSource<< "): " << url << " for " << findStr << endl;
- const KURL u( QString::fromLocal8Bit( url ) );
- KBabelMW *kb = findInstance( u, QString::fromLocal8Bit(project), QString() );
+ const KURL u( TQString::fromLocal8Bit( url ) );
+ KBabelMW *kb = findInstance( u, TQString::fromLocal8Bit(project), TQString() );
if(!kb) return false;
@@ -439,8 +439,8 @@ bool KBabelInterface::findInFile(QCString fileSource, QCString url,
return true;
}
-bool KBabelInterface::replaceInFile(QCString fileSource, QCString url,
- QString findStr, QString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
+bool KBabelInterface::replaceInFile(TQCString fileSource, TQCString url,
+ TQString findStr, TQString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
int ignoreAccelMarker, int ignoreContextInfo, int ask, int askForNextFile, int askForSave)
{
@@ -451,16 +451,16 @@ bool KBabelInterface::replaceInFile(QCString fileSource, QCString url,
KBabel::ProjectManager::defaultProjectName().utf8() );
}
-bool KBabelInterface::replaceInFile(QCString fileSource, QCString url,
- QString findStr, QString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
+bool KBabelInterface::replaceInFile(TQCString fileSource, TQCString url,
+ TQString findStr, TQString replaceStr, int caseSensitive, int wholeWords, int isRegExp,
int inMsgid, int inMsgstr, int inComment,
int ignoreAccelMarker, int ignoreContextInfo, int ask, int askForNextFile, int askForSave,
- QCString project )
+ TQCString project )
{
kdDebug(KBABEL) << "replaceInFile (" <<fileSource<< "): " << url << " for " << findStr << endl;
- const KURL u ( QString::fromLocal8Bit( url ) );
- KBabelMW *kb = findInstance( u, QString::fromLocal8Bit(project), QString() );
+ const KURL u ( TQString::fromLocal8Bit( url ) );
+ KBabelMW *kb = findInstance( u, TQString::fromLocal8Bit(project), TQString() );
if( !kb ) return false;
@@ -485,15 +485,15 @@ bool KBabelInterface::replaceInFile(QCString fileSource, QCString url,
return true;
}
-void KBabelInterface::spellcheck(QStringList fileList)
+void KBabelInterface::spellcheck(TQStringList fileList)
{
// ### FIXME: the default project might use the wrong language!
- KBabelMW *kb = findInstance( KURL(), KBabel::ProjectManager::defaultProjectName(), QString() );
+ KBabelMW *kb = findInstance( KURL(), KBabel::ProjectManager::defaultProjectName(), TQString() );
kb->show();
kb->spellcheckMoreFiles( fileList );
}
-KBabelMW* KBabelInterface::findInstance( const KURL& url, const QString& project, const QString& package) const
+KBabelMW* KBabelInterface::findInstance( const KURL& url, const TQString& project, const TQString& package) const
{
kdDebug () << "Suspending DCOP" << endl;
kapp->dcopClient()->suspend();
diff --git a/kbabel/kbabel/mymultilineedit.cpp b/kbabel/kbabel/mymultilineedit.cpp
index 820d493e..9b7913d1 100644
--- a/kbabel/kbabel/mymultilineedit.cpp
+++ b/kbabel/kbabel/mymultilineedit.cpp
@@ -41,16 +41,16 @@
#include "editcmd.h"
#include "resources.h"
-#include <qpixmap.h>
-#include <qpainter.h>
-#include <qvaluelist.h>
-#include <qstringlist.h>
-#include <qregexp.h>
-#include <qclipboard.h>
-#include <qapplication.h>
-#include <qdragobject.h>
+#include <tqpixmap.h>
+#include <tqpainter.h>
+#include <tqvaluelist.h>
+#include <tqstringlist.h>
+#include <tqregexp.h>
+#include <tqclipboard.h>
+#include <tqapplication.h>
+#include <tqdragobject.h>
//#include <private/qrichtext_p.h>
-#include <qpopupmenu.h>
+#include <tqpopupmenu.h>
#include <kdebug.h>
#include <kglobal.h>
@@ -62,7 +62,7 @@
using namespace KBabel;
-MyMultiLineEdit::MyMultiLineEdit(int ID, QWidget* parent,const char* name)
+MyMultiLineEdit::MyMultiLineEdit(int ID, TQWidget* parent,const char* name)
:KTextEdit(parent,name), emitUndo(true),
_firstChangedLine(0),
_lastChangedLine(0),
@@ -77,7 +77,7 @@ MyMultiLineEdit::MyMultiLineEdit(int ID, QWidget* parent,const char* name)
setWordWrap( WidgetWidth );
viewport()->setAcceptDrops( false ); // we need our parent to get drops
- connect(this, SIGNAL(selectionChanged()), this, SLOT( onSelectionChanged() ) );
+ connect(this, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT( onSelectionChanged() ) );
}
void MyMultiLineEdit::onSelectionChanged()
@@ -118,11 +118,11 @@ void MyMultiLineEdit::processCommand(EditCommand* cmd, bool undo)
bool oldEmitUndo = emitUndo;
emitUndo = false;
- QPalette _visibleHighlight( palette() );
- QPalette _invisibleHighlight( palette() );
- QColorGroup newcg( colorGroup() );
- newcg.setColor( QColorGroup::HighlightedText, newcg.text() );
- newcg.setColor( QColorGroup::Highlight, newcg.base() );
+ TQPalette _visibleHighlight( palette() );
+ TQPalette _invisibleHighlight( palette() );
+ TQColorGroup newcg( colorGroup() );
+ newcg.setColor( TQColorGroup::HighlightedText, newcg.text() );
+ newcg.setColor( TQColorGroup::Highlight, newcg.base() );
if( hasFocus() ) _invisibleHighlight.setActive( newcg );
else _invisibleHighlight.setInactive( newcg );
setPalette( _invisibleHighlight );
@@ -213,34 +213,34 @@ void MyMultiLineEdit::emitCursorPosition()
emit cursorPositionChanged(line, col);
}
-void MyMultiLineEdit::wheelEvent(QWheelEvent *e)
+void MyMultiLineEdit::wheelEvent(TQWheelEvent *e)
{
e->ignore();
}
-void MyMultiLineEdit::focusInEvent(QFocusEvent *e)
+void MyMultiLineEdit::focusInEvent(TQFocusEvent *e)
{
KTextEdit::focusInEvent(e);
emitCursorPosition();
}
-void MyMultiLineEdit::contentsContextMenuEvent( QContextMenuEvent * e)
+void MyMultiLineEdit::contentsContextMenuEvent( TQContextMenuEvent * e)
{
e->accept();
if( _menu ) _menu->exec( e->globalPos() );
}
-QPopupMenu * MyMultiLineEdit::createPopupMenu()
+TQPopupMenu * MyMultiLineEdit::createPopupMenu()
{
return _menu;
}
-QPopupMenu * MyMultiLineEdit::createPopupMenu(const QPoint &)
+TQPopupMenu * MyMultiLineEdit::createPopupMenu(const TQPoint &)
{
return 0;
}
-void MyMultiLineEdit::setContextMenu( QPopupMenu * menu )
+void MyMultiLineEdit::setContextMenu( TQPopupMenu * menu )
{
_menu = menu;
}
@@ -270,10 +270,10 @@ void MyMultiLineEdit::doKeyboardAction( KeyboardAction action )
{
int x,y;
getCursorPosition( &x, &y );
- QString s = text(x);
+ TQString s = text(x);
if( y < (int)s.length()-1 ) // not the end of paragraph
{
- QString delText = s.mid( y, s.length()-y-1);
+ TQString delText = s.mid( y, s.length()-y-1);
emit signalUndoCmd( new DelTextCmd(currentIndex(), delText, _myID ) );
} else
if( x < paragraphs()-1 ) // not the end of text
@@ -288,7 +288,7 @@ void MyMultiLineEdit::doKeyboardAction( KeyboardAction action )
emitCursorPosition();
}
-void MyMultiLineEdit::setText(const QString& s)
+void MyMultiLineEdit::setText(const TQString& s)
{
_lastParagraph=0;
_lastParagraphOffset=0;
@@ -303,7 +303,7 @@ void MyMultiLineEdit::setText(const QString& s)
emitCursorPosition();
}
-void MyMultiLineEdit::insertAt( const QString & s, int line, int col, bool mark )
+void MyMultiLineEdit::insertAt( const TQString & s, int line, int col, bool mark )
{
// it will invoke insert, don't need to send InsTextCmd
KTextEdit::insertAt(s,line,col);
@@ -316,7 +316,7 @@ void MyMultiLineEdit::insertAt( const QString & s, int line, int col, bool mark
emitCursorPosition();
}
-void MyMultiLineEdit::insert( const QString & text, bool indent, bool checkNewLine, bool removeSelected )
+void MyMultiLineEdit::insert( const TQString & text, bool indent, bool checkNewLine, bool removeSelected )
{
int row,col;
@@ -360,11 +360,11 @@ void MyMultiLineEdit::insert( const QString & text, bool indent, bool checkNewLi
// setup palettes
- QPalette _visibleHighlight( palette() );
- QPalette _invisibleHighlight( palette() );
- QColorGroup newcg( colorGroup() );
- newcg.setColor( QColorGroup::HighlightedText, newcg.text() );
- newcg.setColor( QColorGroup::Highlight, newcg.base() );
+ TQPalette _visibleHighlight( palette() );
+ TQPalette _invisibleHighlight( palette() );
+ TQColorGroup newcg( colorGroup() );
+ newcg.setColor( TQColorGroup::HighlightedText, newcg.text() );
+ newcg.setColor( TQColorGroup::Highlight, newcg.base() );
if( hasFocus() ) _invisibleHighlight.setActive( newcg );
else _invisibleHighlight.setInactive( newcg );
setPalette( _invisibleHighlight );
@@ -391,7 +391,7 @@ void MyMultiLineEdit::clear()
_dontUpdate=true;
- QString s = text();
+ TQString s = text();
if( !s.isEmpty() && emitUndo ) {
emit signalUndoCmd( new BeginCommand(-1,UndefPart) );
emit signalUndoCmd( new DelTextCmd(0,s,_myID) );
@@ -423,10 +423,10 @@ void MyMultiLineEdit::my_backspace()
{
int offset = currentIndex();
- QString s= text(cursorY);
+ TQString s= text(cursorY);
if(cursorX != 0)
{
- QString delTxt(s[cursorX-1]);
+ TQString delTxt(s[cursorX-1]);
emit signalUndoCmd(new DelTextCmd(offset-1,delTxt,_myID));
}
else if( cursorY > 0 || cursorX > 0 ) // not at the beginning
@@ -453,10 +453,10 @@ void MyMultiLineEdit::my_del()
{
int offset = pos2Offset(cursorY, cursorX);
- QString s=text(cursorY);
+ TQString s=text(cursorY);
if(cursorX != (int)s.length()-1)
{
- QString delTxt(s[cursorX]);
+ TQString delTxt(s[cursorX]);
emit signalUndoCmd(new DelTextCmd(offset,delTxt,_myID));
}
else if( cursorY < (int)paragraphs()-1 || ( (cursorY == (int)paragraphs()-1) && (cursorX < (int)text( paragraphs()-1 ).length()-1 ) ) )// !atEnd() )
@@ -583,7 +583,7 @@ void MyMultiLineEdit::setReadOnly(bool on)
setBackgroundMode(PaletteBase);
}
- QTextEdit::setReadOnly(on);
+ TQTextEdit::setReadOnly(on);
}
void MyMultiLineEdit::setOverwriteMode( bool b )
@@ -592,7 +592,7 @@ void MyMultiLineEdit::setOverwriteMode( bool b )
}
/*******************************************************************************/
-MsgMultiLineEdit::MsgMultiLineEdit(int ID, KSpell* spell, QWidget* parent,const char* name)
+MsgMultiLineEdit::MsgMultiLineEdit(int ID, KSpell* spell, TQWidget* parent,const char* name)
:MyMultiLineEdit(ID, parent,name),
_quotes(false),
_cleverEditing(false),
@@ -620,32 +620,32 @@ MsgMultiLineEdit::MsgMultiLineEdit(int ID, KSpell* spell, QWidget* parent,const
diffPos.setAutoDelete(true);
diffPos.clear();
- _whitespace = new QPixmap(2,2,-1,QPixmap::BestOptim);
+ _whitespace = new TQPixmap(2,2,-1,TQPixmap::BestOptim);
_whitespace->fill(_textColor);
- _errorWhitespace = new QPixmap(2,2,-1,QPixmap::BestOptim);
+ _errorWhitespace = new TQPixmap(2,2,-1,TQPixmap::BestOptim);
_errorWhitespace->fill(_errorColor);
- _whitespaceNB = new QPixmap(3,3,-1,QPixmap::BestOptim);
+ _whitespaceNB = new TQPixmap(3,3,-1,TQPixmap::BestOptim);
_whitespaceNB->fill();
- _errorWhitespaceNB = new QPixmap(3,3,-1,QPixmap::BestOptim);
+ _errorWhitespaceNB = new TQPixmap(3,3,-1,TQPixmap::BestOptim);
_errorWhitespaceNB->fill();
- QPainter p(_whitespaceNB);
+ TQPainter p(_whitespaceNB);
p.setPen( _textColor );
p.drawEllipse(_whitespaceNB->rect());
- QPainter q(_errorWhitespaceNB);
+ TQPainter q(_errorWhitespaceNB);
q.setPen( _errorColor );
q.drawEllipse(_errorWhitespaceNB->rect());
// this will setup bitBlt pixmaps
setFont( font() );
highlighter = new KBabelHighlighter( this, spell );
- connect( this, SIGNAL( signalSyntaxHighlightingChanged( bool ) ), highlighter, SLOT( setSyntaxHighlighting( bool ) ) );
+ connect( this, TQT_SIGNAL( signalSyntaxHighlightingChanged( bool ) ), highlighter, TQT_SLOT( setSyntaxHighlighting( bool ) ) );
- connect( this, SIGNAL( selectionChanged() ), this, SLOT( paintSpacePoints() ) );
- connect( this, SIGNAL( cursorPositionChanged( int, int ) ), this, SLOT( paintSpacePoints(int, int) ) );
- connect( this, SIGNAL( textChanged() ), this, SLOT( emittedTextChanged() ) );
+ connect( this, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( paintSpacePoints() ) );
+ connect( this, TQT_SIGNAL( cursorPositionChanged( int, int ) ), this, TQT_SLOT( paintSpacePoints(int, int) ) );
+ connect( this, TQT_SIGNAL( textChanged() ), this, TQT_SLOT( emittedTextChanged() ) );
}
MsgMultiLineEdit::~MsgMultiLineEdit ()
@@ -654,9 +654,9 @@ MsgMultiLineEdit::~MsgMultiLineEdit ()
delete highlighter;
}
-void MsgMultiLineEdit::setText(const QString& s)
+void MsgMultiLineEdit::setText(const TQString& s)
{
- QString str = s;
+ TQString str = s;
if(_showDiff)
{
@@ -664,13 +664,13 @@ void MsgMultiLineEdit::setText(const QString& s)
int lines = s.contains('\n');
diffPos.resize(lines+1);
- QStringList lineList = QStringList::split('\n',s,true);
+ TQStringList lineList = TQStringList::split('\n',s,true);
int lineCounter=-1;
bool haveAdd=false;
bool haveDel=false;
bool multiline=false;
- QStringList::Iterator it;
+ TQStringList::Iterator it;
for(it = lineList.begin(); it != lineList.end(); ++it)
{
lineCounter++;
@@ -791,10 +791,10 @@ void MsgMultiLineEdit::setText(const QString& s)
if(di.begin >= 0)
{
- QValueList<DiffInfo> *list = diffPos[lineCounter];
+ TQValueList<DiffInfo> *list = diffPos[lineCounter];
if(!list)
{
- list = new QValueList<DiffInfo>;
+ list = new TQValueList<DiffInfo>;
diffPos.insert(lineCounter,list);
}
@@ -804,7 +804,7 @@ void MsgMultiLineEdit::setText(const QString& s)
}
}
- QRegExp reg("</?KBABELADD>");
+ TQRegExp reg("</?KBABELADD>");
str.replace(reg,"");
reg.setPattern("</?KBABELDEL>");
str.replace(reg,"");
@@ -833,7 +833,7 @@ void MsgMultiLineEdit::setHighlightBg(bool on)
}
-void MsgMultiLineEdit::setBgColor(const QColor& color)
+void MsgMultiLineEdit::setBgColor(const TQColor& color)
{
_bgColor=color;
@@ -857,8 +857,8 @@ void MsgMultiLineEdit::setHighlightSyntax(bool on)
update();
}
-void MsgMultiLineEdit::setHighlightColors(const QColor& quoteColor, const QColor& unquoteColor
- , const QColor& cformatColor, const QColor& accelColor, const QColor& tagColor)
+void MsgMultiLineEdit::setHighlightColors(const TQColor& quoteColor, const TQColor& unquoteColor
+ , const TQColor& cformatColor, const TQColor& accelColor, const TQColor& tagColor)
{
_quoteColor=quoteColor;
_unquoteColor=unquoteColor;
@@ -875,13 +875,13 @@ void MsgMultiLineEdit::setHighlightColors(const QColor& quoteColor, const QColor
}
-void MsgMultiLineEdit::setFont(const QFont& font)
+void MsgMultiLineEdit::setFont(const TQFont& font)
{
KTextEdit::setFont(font);
// we don't need to calculate a special offset for non-breaking space, since
// they are very similar in size
- QFontMetrics fm(font);
+ TQFontMetrics fm(font);
_wsOffsetX = QMAX(fm.width(' ')/2-2,1);
_wsOffsetY = QMAX(fm.height()/2-1,0);
@@ -897,8 +897,8 @@ void MsgMultiLineEdit::setDiffDisplayMode(bool addUnderline, bool delStrikeOut)
update();
}
-void MsgMultiLineEdit::setDiffColors(const QColor& addColor
- , const QColor& delColor)
+void MsgMultiLineEdit::setDiffColors(const TQColor& addColor
+ , const TQColor& delColor)
{
_diffAddColor = addColor;
_diffDelColor = delColor;
@@ -907,11 +907,11 @@ void MsgMultiLineEdit::setDiffColors(const QColor& addColor
update();
}
-void MsgMultiLineEdit::setTextColor(const QColor &color )
+void MsgMultiLineEdit::setTextColor(const TQColor &color )
{
- QPalette p( palette() );
- QColorGroup newcg( colorGroup() );
- newcg.setColor( QColorGroup::Text, color );
+ TQPalette p( palette() );
+ TQColorGroup newcg( colorGroup() );
+ newcg.setColor( TQColorGroup::Text, color );
if( hasFocus() ) p.setActive( newcg );
else p.setInactive( newcg );
setPalette( p );
@@ -919,7 +919,7 @@ void MsgMultiLineEdit::setTextColor(const QColor &color )
highlighter->setHighlightColor( KBabelHighlighter::Normal, color );
}
-void MsgMultiLineEdit::setErrorColor(const QColor &color )
+void MsgMultiLineEdit::setErrorColor(const TQColor &color )
{
_errorColor = color;
highlighter->setHighlightColor( KBabelHighlighter::Error, color );
@@ -961,17 +961,17 @@ void MsgMultiLineEdit::paintSpacePoints(int, int )
void MsgMultiLineEdit::paintSpacePoints()
{
- QRect r;
- QPainter painter(viewport() );
- const QFontMetrics& fm = fontMetrics();
+ TQRect r;
+ TQPainter painter(viewport() );
+ const TQFontMetrics& fm = fontMetrics();
- int paranum = paragraphAt(QPoint(contentsX(), contentsY()));
+ int paranum = paragraphAt(TQPoint(contentsX(), contentsY()));
if( _spacePoints )
{
int curpara = paranum;
painter.setPen( _currentColor );
- QPixmap* ws, *wsnb;
+ TQPixmap* ws, *wsnb;
if( _currentColor== _errorColor )
{
@@ -988,12 +988,12 @@ void MsgMultiLineEdit::paintSpacePoints()
{
if ( paragraphRect( curpara ).top() > contentsY()+visibleHeight()) break;
- const QString& s = text(curpara);
+ const TQString& s = text(curpara);
int i = s.find( " " );
while( (i >= 0) && (i < (int)s.length()-1) ) // -1 because text will end by EOLN
{
- QPixmap* pm = ( s.at(i).unicode() == 0x00A0U ) ? wsnb : ws;
- QRect r = mapToView( curpara, i );
+ TQPixmap* pm = ( s.at(i).unicode() == 0x00A0U ) ? wsnb : ws;
+ TQRect r = mapToView( curpara, i );
r.moveBy( r.width()/2, (r.height() - fm.descent())/2 );
r.moveBy( -pm->rect().width()/2, -pm->rect().height()/2-1 );
bitBlt(viewport(), r.topLeft(), pm, pm->rect(), Qt::CopyROP);
@@ -1005,19 +1005,19 @@ void MsgMultiLineEdit::paintSpacePoints()
if( _quotes )
{
- QFontMetrics fm( font());
- QRect qs = fm.boundingRect("\"");
+ TQFontMetrics fm( font());
+ TQRect qs = fm.boundingRect("\"");
for( int curpara = paranum; curpara < paragraphs() ; curpara++ )
{
r = paragraphRect(curpara);
if( r.y() > contentsY()+visibleHeight() ) break;
- painter.drawText( QPoint( 0, mapToView( curpara, 0 ).top()) +
- QPoint(0, qs.height() + 4), "\""); // 4 = hardcoded margin in QT
+ painter.drawText( TQPoint( 0, mapToView( curpara, 0 ).top()) +
+ TQPoint(0, qs.height() + 4), "\""); // 4 = hardcoded margin in QT
painter.drawText( mapToView( curpara, QMAX( 0,
((int)text( curpara ).length())-1)).topRight() +
- QPoint(0, qs.height() + 4), "\""); // 4 = hardcoded margin in QT
+ TQPoint(0, qs.height() + 4), "\""); // 4 = hardcoded margin in QT
}
}
@@ -1031,16 +1031,16 @@ void MsgMultiLineEdit::paintSpacePoints()
r = paragraphRect(curpara);
if( r.y() > contentsY()+visibleHeight() ) break;
- QValueList<DiffInfo> *list = diffPos[curpara];
+ TQValueList<DiffInfo> *list = diffPos[curpara];
if(list)
{
- QValueList<DiffInfo>::ConstIterator it;
+ TQValueList<DiffInfo>::ConstIterator it;
for(it = list->begin(); it != list->end(); ++it)
{
- QRect beg = mapToView( curpara, (*it).begin );
- QRect end = mapToView( curpara, (*it).end );
+ TQRect beg = mapToView( curpara, (*it).begin );
+ TQRect end = mapToView( curpara, (*it).end );
- QColor* c = 0;
+ TQColor* c = 0;
if( (*it).add && !_diffUnderlineAdd)
c = &_diffAddColor;
else if(!(*it).add && !_diffStrikeOutDel)
@@ -1051,23 +1051,23 @@ void MsgMultiLineEdit::paintSpacePoints()
// Single or multiple lines?
if ( beg.top() == end.top())
{
- painter.fillRect( QRect( beg.topLeft(),
- QPoint( end.right(), end.bottom())), *c );
+ painter.fillRect( TQRect( beg.topLeft(),
+ TQPoint( end.right(), end.bottom())), *c );
}
else
{
- painter.fillRect( QRect(
+ painter.fillRect( TQRect(
beg.topLeft(),
- QPoint( r.right(), beg.bottom())), *c );
+ TQPoint( r.right(), beg.bottom())), *c );
if( end.top()-beg.bottom() > 2 ) {
// there is a line, not only thin space
- painter.fillRect( QRect(
- QPoint( r.left(), beg.bottom()),
- QPoint( r.right(), end.top())), *c );
+ painter.fillRect( TQRect(
+ TQPoint( r.left(), beg.bottom()),
+ TQPoint( r.right(), end.top())), *c );
}
- painter.fillRect( QRect(
- QPoint( r.left(), end.top()),
- QPoint( end.right(), end.bottom())), *c );
+ painter.fillRect( TQRect(
+ TQPoint( r.left(), end.top()),
+ TQPoint( end.right(), end.bottom())), *c );
}
}
}
@@ -1085,18 +1085,18 @@ void MsgMultiLineEdit::paintSpacePoints()
r = paragraphRect(curpara);
if( r.y() > contentsY()+visibleHeight() ) break;
- QValueList<DiffInfo> *list = diffPos[curpara];
+ TQValueList<DiffInfo> *list = diffPos[curpara];
if(list)
{
- QPen addPen(_diffAddColor,2);
- QPen delPen(_diffDelColor,2);
- QValueList<DiffInfo>::ConstIterator it;
+ TQPen addPen(_diffAddColor,2);
+ TQPen delPen(_diffDelColor,2);
+ TQValueList<DiffInfo>::ConstIterator it;
for(it = list->begin(); it != list->end(); ++it)
{
- QRect beg = mapToView( curpara, (*it).begin );
- QRect end = mapToView( curpara, (*it).end );
+ TQRect beg = mapToView( curpara, (*it).begin );
+ TQRect end = mapToView( curpara, (*it).end );
- QPen* p = 0;
+ TQPen* p = 0;
int dy = 0;
if( (*it).add && _diffUnderlineAdd)
p = &addPen;
@@ -1113,25 +1113,25 @@ void MsgMultiLineEdit::paintSpacePoints()
// Single or multiple lines?
if ( beg.top() == end.top())
painter.drawLine(
- beg.topLeft() + QPoint(0, fm.ascent()-dy),
- end.topRight()+ QPoint(0, fm.ascent()-dy));
+ beg.topLeft() + TQPoint(0, fm.ascent()-dy),
+ end.topRight()+ TQPoint(0, fm.ascent()-dy));
else
{
int y = beg.top() + fm.ascent();
painter.drawLine(
- QPoint(beg.left(), y),
- QPoint(r.right(), y));
+ TQPoint(beg.left(), y),
+ TQPoint(r.right(), y));
y += fm.lineSpacing();
while (y < end.top() + fm.ascent())
{
painter.drawLine(
- QPoint(r.left(), y),
- QPoint(r.right(), y));
+ TQPoint(r.left(), y),
+ TQPoint(r.right(), y));
y += fm.lineSpacing();
}
painter.drawLine(
- QPoint(r.left(), end.top() + fm.ascent()),
- QPoint(end.right(), end.top() + fm.ascent()));
+ TQPoint(r.left(), end.top() + fm.ascent()),
+ TQPoint(end.right(), end.top() + fm.ascent()));
}
}
}
@@ -1165,7 +1165,7 @@ void MsgMultiLineEdit::highlight()
{
/* if( _dontUpdate ) return;
- QColor bg;
+ TQColor bg;
if( _highlightBg ) bg = _bgColor;
else bg = colorGroup().base();
@@ -1185,19 +1185,19 @@ void MsgMultiLineEdit::highlight()
uint i;
- QRegExp markup("(\\\\)|(\")|(\\\\[abfnrtv'\"\?\\\\])|(\\\\\\d+)|(\\\\x[\\dabcdef]+)"
+ TQRegExp markup("(\\\\)|(\")|(\\\\[abfnrtv'\"\?\\\\])|(\\\\\\d+)|(\\\\x[\\dabcdef]+)"
"|(%[\\ddioxXucsfeEgGphln]+)|(&[^\\s])|(&[\\w-]+;)");
for( i = QMAX(_firstChangedLine,0) ; i < QMIN(_lastChangedLine+1,(uint)paragraphs()) ; i++ ) {
- QString line=text(i);
+ TQString line=text(i);
//remove old highlighting
setSelection(i,0,i,line.length());
setColor( _currentColor );
removeSelection();
- QColor colorToUse;
+ TQColor colorToUse;
int index=0;
index=markup.search( line, index );
@@ -1234,7 +1234,7 @@ void MsgMultiLineEdit::highlight()
int lineindex=0;
uint index=0;
int startPara, endPara, startIndex, endIndex;
- QString t= text();
+ TQString t= text();
if(_lastParagraph <= _firstChangedLine)
{
@@ -1245,19 +1245,19 @@ void MsgMultiLineEdit::highlight()
for( ; index<_firstChangedLine ; index++)
lineindex+=paragraphLength(index)+1;
- QRegExp re("<.*>");
+ TQRegExp re("<.*>");
re.setMinimal(true);
if( _firstChangedLine >0 )
{
- QColor c;
- QFont f;
+ TQColor c;
+ TQFont f;
VerticalAlignment v;
getFormat(_firstChangedLine-1, paragraphLength(_firstChangedLine-1)-1, &f, &c, &v);
- QString l = text(_firstChangedLine-1);
+ TQString l = text(_firstChangedLine-1);
if( c==_tagColor && !l.endsWith(">") ) // hope _tagColor will be different than other colors
{
- QRegExp endtag("[^<]*>");
+ TQRegExp endtag("[^<]*>");
tagindex=endtag.search(t, lineindex);
taglength=endtag.matchedLength();
} else {
@@ -1311,26 +1311,26 @@ void MsgMultiLineEdit::highlight()
*/
}
-void MsgMultiLineEdit::drawContents( QPainter *painter, int clipx, int clipy, int clipw, int cliph )
+void MsgMultiLineEdit::drawContents( TQPainter *painter, int clipx, int clipy, int clipw, int cliph )
{
MyMultiLineEdit::drawContents( painter, clipx, clipy, clipw, cliph );
paintSpacePoints();
}
-void MsgMultiLineEdit::paintEvent( QPaintEvent *event )
+void MsgMultiLineEdit::paintEvent( TQPaintEvent *event )
{
MyMultiLineEdit::paintEvent( event );
paintSpacePoints();
}
-QRect MsgMultiLineEdit::mapToView( int para, int index )
+TQRect MsgMultiLineEdit::mapToView( int para, int index )
{
if( para < 0 || para > paragraphs() ||
index < 0 || index > paragraphLength(para) )
- return QRect(); //invalid rectangle
+ return TQRect(); //invalid rectangle
- const QFontMetrics& fm = fontMetrics();
- const QString& paratext = text(para);
+ const TQFontMetrics& fm = fontMetrics();
+ const TQString& paratext = text(para);
// Find index of the first character on the same line as parameter
// 'index' using binary search. Very fast, even for long texts.
@@ -1377,9 +1377,9 @@ QRect MsgMultiLineEdit::mapToView( int para, int index )
// no tag on the line, no bold
linewidth = fm.width( paratext.mid( linestart, index-linestart ));
} else {
- QFont f( font() );
+ TQFont f( font() );
f.setBold( true );
- QFontMetrics bfm( f );
+ TQFontMetrics bfm( f );
// is tag single displayed line?
if( _tagStartPara == _tagEndPara
&& lineOfChar( _tagStartPara, _tagStartIndex ) == lineOfChar( _tagEndPara, _tagEndIndex ) )
@@ -1400,9 +1400,9 @@ QRect MsgMultiLineEdit::mapToView( int para, int index )
}
else {
// in tag
- QFont f( font() );
+ TQFont f( font() );
f.setBold( true );
- QFontMetrics bfm( f );
+ TQFontMetrics bfm( f );
// is it the first line of the tag?
if( para == _tagStartPara && indexline == lineOfChar( _tagStartPara, _tagStartIndex ) ) {
// start of the line is normal
@@ -1415,23 +1415,23 @@ QRect MsgMultiLineEdit::mapToView( int para, int index )
}
}
- // FIXME as soon as it's possible to ask real margins from QTextEdit:
+ // FIXME as soon as it's possible to ask real margins from TQTextEdit:
const int left_margin = 4;
// const int top_margin = 4;
- QPainter painter( viewport());
- const QRect& linerect = paragraphRect(para);
- return QRect(
- contentsToViewport( QPoint(
+ TQPainter painter( viewport());
+ const TQRect& linerect = paragraphRect(para);
+ return TQRect(
+ contentsToViewport( TQPoint(
left_margin + linerect.left() + linewidth ,
/*top_margin + */linerect.top() + indexline * fm.lineSpacing() + fm.leading())),
- QSize(
+ TQSize(
fm.charWidth( paratext, index ),
fm.lineSpacing()
));
}
-void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
+void MsgMultiLineEdit::keyPressEvent(TQKeyEvent *e)
{
if(!_cleverEditing || isReadOnly())
{
@@ -1447,7 +1447,7 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
int row, col;
getCursorPosition(&row,&col);
- QString str=text(row);
+ TQString str=text(row);
if(e->state() & ShiftButton)
{
@@ -1491,7 +1491,7 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
if( !str.isEmpty())
{
// construct new event without modifiers
- MyMultiLineEdit::keyPressEvent( new QKeyEvent(e->type(), e->key(), e->ascii(), 0,
+ MyMultiLineEdit::keyPressEvent( new TQKeyEvent(e->type(), e->key(), e->ascii(), 0,
e->text(), e->isAutoRepeat(), e->count() ) );
e->accept();
}
@@ -1515,12 +1515,12 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
{
int row, col;
getCursorPosition(&row,&col);
- QString str=text(row);
+ TQString str=text(row);
if(!str.isEmpty() && col < (int)str.length() && str.at(col) == '\\'
&& !isMasked(&str,col))
{
- QString spclChars="abfnrtv'\"?\\";
+ TQString spclChars="abfnrtv'\"?\\";
if(col < (int)str.length()-1
&& spclChars.contains(str.at(col+1)))
{
@@ -1545,9 +1545,9 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
{
int row, col;
getCursorPosition(&row,&col);
- QString str=text(row);
+ TQString str=text(row);
- QString spclChars="abfnrtv'\"?\\";
+ TQString spclChars="abfnrtv'\"?\\";
if(!str.isEmpty() && col > 0 && spclChars.contains(str.at(col-1)))
{
if(col > 1 && str.at(col-2)=='\\' && !isMasked(&str,col-2))
@@ -1571,7 +1571,7 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
int row, col;
getCursorPosition(&row,&col);
- QString str=text(row);
+ TQString str=text(row);
if(col == 0 || str.at(col-1) != '\\' || isMasked(&str,col-1) )
{
@@ -1589,14 +1589,14 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
}
else if(e->key() == Key_Space && ( e->state() & AltButton ) )
{
- insert( QChar( 0x00a0U ) );
+ insert( TQChar( 0x00a0U ) );
e->accept();
return;
}
// ALT+123 feature
else if(( e->state() & AltButton ) && e->text()[0].isDigit() )
{
- QString text=e->text();
+ TQString text=e->text();
while ( text[0].isDigit() ) {
_currentUnicodeNumber = 10*_currentUnicodeNumber+(text[0].digitValue());
text.remove( 0, 1 );
@@ -1608,11 +1608,11 @@ void MsgMultiLineEdit::keyPressEvent(QKeyEvent *e)
}
}
-void MsgMultiLineEdit::keyReleaseEvent(QKeyEvent* e)
+void MsgMultiLineEdit::keyReleaseEvent(TQKeyEvent* e)
{
if ( e->key() == Key_Alt && _currentUnicodeNumber >= 32 )
{
- QString text = QChar( _currentUnicodeNumber );
+ TQString text = TQChar( _currentUnicodeNumber );
_currentUnicodeNumber=0;
insert( text );
}
@@ -1628,7 +1628,7 @@ void MsgMultiLineEdit::setDiffMode(bool on)
}
}
-bool MsgMultiLineEdit::isMasked(QString *str, uint col)
+bool MsgMultiLineEdit::isMasked(TQString *str, uint col)
{
if(col == 0 || !str)
return false;
diff --git a/kbabel/kbabel/mymultilineedit.h b/kbabel/kbabel/mymultilineedit.h
index 30771610..4f076af5 100644
--- a/kbabel/kbabel/mymultilineedit.h
+++ b/kbabel/kbabel/mymultilineedit.h
@@ -36,7 +36,7 @@
#define MYMULTILINEEDIT_H
#include <ktextedit.h>
-#include <qptrvector.h>
+#include <tqptrvector.h>
namespace KBabel
{
@@ -51,7 +51,7 @@ class MyMultiLineEdit : public KTextEdit
{
Q_OBJECT
public:
- MyMultiLineEdit(int ID,QWidget* parent,const char* name=0);
+ MyMultiLineEdit(int ID,TQWidget* parent,const char* name=0);
/**
applies cmd to the displayed text, but does not emit
@@ -79,7 +79,7 @@ public:
*/
int endOfLastMarkedText();
- virtual void insertAt ( const QString & s, int line, int col, bool mark = false );
+ virtual void insertAt ( const TQString & s, int line, int col, bool mark = false );
virtual void removeLine ( int line );
int pos2Offset(uint paragraph, uint index);
@@ -98,7 +98,7 @@ public:
/**
* need to override deleting of popup menus :-(
*/
- void contentsContextMenuEvent( QContextMenuEvent *e );
+ void contentsContextMenuEvent( TQContextMenuEvent *e );
/**
* need to reimplement overwrite mode :-(
@@ -110,27 +110,27 @@ public slots:
virtual void clear();
virtual void paste();
virtual void setReadOnly(bool on);
- virtual void setContextMenu( QPopupMenu *menu );
- virtual void setText(const QString& s);
+ virtual void setContextMenu( TQPopupMenu *menu );
+ virtual void setText(const TQString& s);
virtual void doKeyboardAction( KeyboardAction action );
virtual void removeSelectedText(int selNum = 0);
virtual void onSelectionChanged();
/**
- reimplemented overwrite mode, since QTextEdit handles this internally and does
+ reimplemented overwrite mode, since TQTextEdit handles this internally and does
not use any accessible virtual methods :-((.
*/
virtual void setOverwriteMode(bool b);
protected:
- virtual void focusInEvent(QFocusEvent*);
- virtual QPopupMenu *createPopupMenu();
- virtual QPopupMenu *createPopupMenu(const QPoint &pos);
+ virtual void focusInEvent(TQFocusEvent*);
+ virtual TQPopupMenu *createPopupMenu();
+ virtual TQPopupMenu *createPopupMenu(const TQPoint &pos);
/* the parent handles this */
- virtual void wheelEvent(QWheelEvent*);
+ virtual void wheelEvent(TQWheelEvent*);
bool emitUndo;
@@ -154,7 +154,7 @@ protected:
bool _dontUpdate;
protected slots:
- virtual void insert ( const QString & text, bool indent = FALSE, bool checkNewLine = TRUE, bool removeSelected = TRUE );
+ virtual void insert ( const TQString & text, bool indent = FALSE, bool checkNewLine = TRUE, bool removeSelected = TRUE );
virtual void emitCursorPosition();
signals:
@@ -165,7 +165,7 @@ protected:
int _myID;
private:
- QPopupMenu *_menu;
+ TQPopupMenu *_menu;
bool _overwrite;
};
@@ -176,7 +176,7 @@ class MsgMultiLineEdit : public MyMultiLineEdit
public:
enum TextColor { NormalColor, ErrorColor };
- MsgMultiLineEdit(int ID, KSpell* spell=0, QWidget* parent=0,const char* name=0);
+ MsgMultiLineEdit(int ID, KSpell* spell=0, TQWidget* parent=0,const char* name=0);
virtual ~MsgMultiLineEdit();
/** is displaying surrounding quotes enabled? */
@@ -192,8 +192,8 @@ public:
bool highlightBg() const { return _highlightBg; }
/** enable or disable highlighting background*/
void setHighlightBg(bool on);
- QColor bgColor() const { return _bgColor; }
- void setBgColor(const QColor& color);
+ TQColor bgColor() const { return _bgColor; }
+ void setBgColor(const TQColor& color);
bool spacePoints() const { return _spacePoints; }
void setSpacePoints(bool on);
@@ -201,17 +201,17 @@ public:
bool highlightSyntax() const { return _hlSyntax; }
void highlight();
void setHighlightSyntax(bool on);
- void setHighlightColors(const QColor& quoteColor, const QColor& unquoteColor
- , const QColor& cformatColor, const QColor& accelColor, const QColor& tagColor);
+ void setHighlightColors(const TQColor& quoteColor, const TQColor& unquoteColor
+ , const TQColor& cformatColor, const TQColor& accelColor, const TQColor& tagColor);
- void setFont(const QFont& font);
+ void setFont(const TQFont& font);
void setDiffMode(bool on);
void setDiffDisplayMode(bool underlineAdded, bool strikeOutDeleted);
- void setDiffColors(const QColor& addColor, const QColor& delColor);
+ void setDiffColors(const TQColor& addColor, const TQColor& delColor);
- void setTextColor(const QColor &color);
- void setErrorColor(const QColor &color);
+ void setTextColor(const TQColor &color);
+ void setErrorColor(const TQColor &color);
void setCurrentColor(const TextColor color);
@@ -220,9 +220,9 @@ public:
void selectTag(int start, int length);
public slots:
- virtual void setText(const QString& s);
+ virtual void setText(const TQString& s);
void paintSpacePoints();
- void paintSpacePoints( int para, int pos ); // overloaded for signal QTextEdit::cursorPositionChanged
+ void paintSpacePoints( int para, int pos ); // overloaded for signal TQTextEdit::cursorPositionChanged
/**
* reimplemented to call highlight()
@@ -237,49 +237,49 @@ public slots:
void ensureCursorVisible();
protected:
- virtual void paintEvent (QPaintEvent * event );
- virtual void drawContents( QPainter *painter, int clipx, int clipy, int clipw, int cliph );
+ virtual void paintEvent (TQPaintEvent * event );
+ virtual void drawContents( TQPainter *painter, int clipx, int clipy, int clipw, int cliph );
- virtual void keyPressEvent(QKeyEvent*);
- virtual void keyReleaseEvent(QKeyEvent*);
+ virtual void keyPressEvent(TQKeyEvent*);
+ virtual void keyReleaseEvent(TQKeyEvent*);
private:
/**
* Computes the pixel position in line which corresponds to
* character position xIndex
*/
- QRect mapToView( int para, int index );
+ TQRect mapToView( int para, int index );
/**
* tests if the character in string str at position col is masked with
* '\' by counting the number of '\' backwards
*/
- static bool isMasked(QString *str,uint col);
+ static bool isMasked(TQString *str,uint col);
private:
bool _quotes;
bool _cleverEditing;
bool _highlightBg;
bool _spacePoints;
- QColor _bgColor;
- QColor _textColor;
- QColor _errorColor;
- QColor _currentColor;
+ TQColor _bgColor;
+ TQColor _textColor;
+ TQColor _errorColor;
+ TQColor _currentColor;
- QPixmap* _whitespace;
- QPixmap* _whitespaceNB;
- QPixmap* _errorWhitespace;
- QPixmap* _errorWhitespaceNB;
+ TQPixmap* _whitespace;
+ TQPixmap* _whitespaceNB;
+ TQPixmap* _errorWhitespace;
+ TQPixmap* _errorWhitespaceNB;
int _wsOffsetX;
int _wsOffsetY;
bool _hlSyntax;
- QColor _quoteColor;
- QColor _unquoteColor;
- QColor _cformatColor;
- QColor _accelColor;
- QColor _tagColor;
+ TQColor _quoteColor;
+ TQColor _unquoteColor;
+ TQColor _cformatColor;
+ TQColor _accelColor;
+ TQColor _tagColor;
struct DiffInfo
{
@@ -288,12 +288,12 @@ private:
int end;
};
- QPtrVector< QValueList<DiffInfo> > diffPos;
+ TQPtrVector< TQValueList<DiffInfo> > diffPos;
bool _showDiff;
bool _diffUnderlineAdd;
bool _diffStrikeOutDel;
- QColor _diffAddColor;
- QColor _diffDelColor;
+ TQColor _diffAddColor;
+ TQColor _diffDelColor;
// for Alt+123 feature
int _currentUnicodeNumber;
diff --git a/kbabel/kbabel/sourceview.cpp b/kbabel/kbabel/sourceview.cpp
index 08c0f8a4..00d8a3b2 100644
--- a/kbabel/kbabel/sourceview.cpp
+++ b/kbabel/kbabel/sourceview.cpp
@@ -34,8 +34,8 @@
#include "sourceview.h"
#include "context.h"
-#include <qlayout.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqwhatsthis.h>
#include <kcursor.h>
#include <klocale.h>
@@ -45,16 +45,16 @@
using namespace KBabel;
-SourceView::SourceView(KBCatalog* catalog,QWidget *parent, Project::Ptr project)
+SourceView::SourceView(KBCatalog* catalog,TQWidget *parent, Project::Ptr project)
: KBCatalogView(catalog,parent,project)
{
- QVBoxLayout* layout = new QVBoxLayout( this );
- layout->setResizeMode( QLayout::Minimum );
+ TQVBoxLayout* layout = new TQVBoxLayout( this );
+ layout->setResizeMode( TQLayout::Minimum );
_contextView = new SourceContext (this, project);
layout->addWidget (_contextView);
- connect(_catalog, SIGNAL(signalFileOpened(bool)), this, SLOT(setDisabled(bool)));
+ connect(_catalog, TQT_SIGNAL(signalFileOpened(bool)), this, TQT_SLOT(setDisabled(bool)));
}
void SourceView::updateView()
diff --git a/kbabel/kbabel/sourceview.h b/kbabel/kbabel/sourceview.h
index 8caeed35..a12ca767 100644
--- a/kbabel/kbabel/sourceview.h
+++ b/kbabel/kbabel/sourceview.h
@@ -44,7 +44,7 @@ public:
/**
* Default constructor
*/
- SourceView(KBCatalog* catalog,QWidget *parent, KBabel::Project::Ptr project);
+ SourceView(KBCatalog* catalog,TQWidget *parent, KBabel::Project::Ptr project);
public slots:
virtual void updateView();
diff --git a/kbabel/kbabel/spelldlg.cpp b/kbabel/kbabel/spelldlg.cpp
index 49500e09..de9f2ce6 100644
--- a/kbabel/kbabel/spelldlg.cpp
+++ b/kbabel/kbabel/spelldlg.cpp
@@ -33,14 +33,14 @@
#include "spelldlg.h"
#include "spelldlgwidget.h"
-#include <qcheckbox.h>
-#include <qradiobutton.h>
+#include <tqcheckbox.h>
+#include <tqradiobutton.h>
#include <kconfig.h>
#include <kglobal.h>
#include <klocale.h>
-SpellDlg::SpellDlg(bool haveMarkedText,QWidget *parent,const char *name)
+SpellDlg::SpellDlg(bool haveMarkedText,TQWidget *parent,const char *name)
: KDialogBase(parent,name,true,i18n("Caption of dialog","Spelling")
, Ok|Cancel)
{
@@ -61,7 +61,7 @@ SpellDlg::SpellDlg(bool haveMarkedText,QWidget *parent,const char *name)
KConfig *config = KGlobal::config();
KConfigGroupSaver cs(config,"SpellDlg");
- QString what=config->readEntry("Default","All");
+ TQString what=config->readEntry("Default","All");
if(what=="All")
_mainWidget->allBtn->setChecked(true);
@@ -85,7 +85,7 @@ SpellDlg::~SpellDlg()
KConfig *config=KGlobal::config();
KConfigGroupSaver cs(config,"SpellDlg");
- QString what="All";
+ TQString what="All";
if(_mainWidget->endBtn->isChecked())
what="End";
else if(_mainWidget->beginBtn->isChecked())
diff --git a/kbabel/kbabel/spelldlg.h b/kbabel/kbabel/spelldlg.h
index ea857777..e12fc515 100644
--- a/kbabel/kbabel/spelldlg.h
+++ b/kbabel/kbabel/spelldlg.h
@@ -43,7 +43,7 @@ class SpellDlg : public KDialogBase
Q_OBJECT
public:
- SpellDlg(bool haveMarkedText, QWidget* parent, const char *name=0);
+ SpellDlg(bool haveMarkedText, TQWidget* parent, const char *name=0);
~SpellDlg();
bool all() const;
diff --git a/kbabel/kbabel/taglistview.cpp b/kbabel/kbabel/taglistview.cpp
index 8dedccea..476c2ed7 100644
--- a/kbabel/kbabel/taglistview.cpp
+++ b/kbabel/kbabel/taglistview.cpp
@@ -33,8 +33,8 @@
#include "taglistview.h"
-#include <qlayout.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqwhatsthis.h>
#include <kcursor.h>
#include <klistbox.h>
@@ -44,23 +44,23 @@
using namespace KBabel;
-TagListView::TagListView(KBCatalog* catalog,QWidget *parent, Project::Ptr project)
+TagListView::TagListView(KBCatalog* catalog,TQWidget *parent, Project::Ptr project)
: KBCatalogView(catalog,parent,project)
{
- QVBoxLayout* layout = new QVBoxLayout( this );
- layout->setResizeMode( QLayout::Minimum );
+ TQVBoxLayout* layout = new TQVBoxLayout( this );
+ layout->setResizeMode( TQLayout::Minimum );
_tagBox = new KListBox (this, "taglist textview");
layout->addWidget (_tagBox);
- connect(_tagBox,SIGNAL(selected(const QString&))
- , this, SIGNAL(signalTagSelected(const QString&)));
- connect(_tagBox,SIGNAL(highlighted(int))
- , this, SIGNAL(signalHighlightedTagChanged(int)));
+ connect(_tagBox,TQT_SIGNAL(selected(const TQString&))
+ , this, TQT_SIGNAL(signalTagSelected(const TQString&)));
+ connect(_tagBox,TQT_SIGNAL(highlighted(int))
+ , this, TQT_SIGNAL(signalHighlightedTagChanged(int)));
- connect(_catalog, SIGNAL(signalFileOpened(bool))
- , this, SLOT(setDisabled(bool)));
+ connect(_catalog, TQT_SIGNAL(signalFileOpened(bool))
+ , this, TQT_SLOT(setDisabled(bool)));
}
void TagListView::updateView()
diff --git a/kbabel/kbabel/taglistview.h b/kbabel/kbabel/taglistview.h
index 0435e3ba..d4361a23 100644
--- a/kbabel/kbabel/taglistview.h
+++ b/kbabel/kbabel/taglistview.h
@@ -44,7 +44,7 @@ public:
/**
* Default constructor
*/
- TagListView(KBCatalog* catalog,QWidget *parent, KBabel::Project::Ptr project);
+ TagListView(KBCatalog* catalog,TQWidget *parent, KBabel::Project::Ptr project);
public slots:
virtual void updateView();
@@ -52,7 +52,7 @@ public slots:
signals:
void signalHighlightedTagChanged (int index);
- void signalTagSelected (const QString& tag);
+ void signalTagSelected (const TQString& tag);
private:
KListBox* _tagBox;