summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-04 19:59:21 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-04 19:59:21 +0000
commitb9c374725620ec064db7610132a8b8969fa405b9 (patch)
tree645c03144cac22f7b4fb5bd10985d389e8954290 /src
parent71729070d61b36b96acd7fa9c34bba0cb8f58c3b (diff)
downloadkile-b9c374725620ec064db7610132a8b8969fa405b9.tar.gz
kile-b9c374725620ec064db7610132a8b8969fa405b9.zip
TQt4 port kile
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kile@1239285 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src')
-rw-r--r--src/kile/cleandialog.cpp42
-rw-r--r--src/kile/cleandialog.h9
-rw-r--r--src/kile/codecompletion.cpp320
-rw-r--r--src/kile/codecompletion.h91
-rw-r--r--src/kile/configcheckerdlg.cpp56
-rw-r--r--src/kile/configcheckerdlg.h23
-rw-r--r--src/kile/configcheckerwidget.ui14
-rw-r--r--src/kile/configcheckerwidget.ui.h4
-rw-r--r--src/kile/configcodecompletion.cpp204
-rw-r--r--src/kile/configcodecompletion.h63
-rw-r--r--src/kile/configstructure.cpp162
-rw-r--r--src/kile/configstructure.h60
-rw-r--r--src/kile/configtester.cpp106
-rw-r--r--src/kile/configtester.h49
-rw-r--r--src/kile/convert.cpp84
-rw-r--r--src/kile/convert.h66
-rw-r--r--src/kile/docpart.cpp22
-rw-r--r--src/kile/docpart.h13
-rw-r--r--src/kile/editorkeysequencemanager.cpp82
-rw-r--r--src/kile/editorkeysequencemanager.h62
-rw-r--r--src/kile/envconfigwidget.ui28
-rw-r--r--src/kile/floatdialog.cpp106
-rw-r--r--src/kile/floatdialog.h17
-rw-r--r--src/kile/generalconfigwidget.ui40
-rw-r--r--src/kile/graphicsconfigwidget.ui24
-rw-r--r--src/kile/helpconfigwidget.ui24
-rw-r--r--src/kile/helpconfigwidget.ui.h2
-rw-r--r--src/kile/includegraphicsdialog.cpp182
-rw-r--r--src/kile/includegraphicsdialog.h31
-rw-r--r--src/kile/kile.cpp764
-rw-r--r--src/kile/kile.h89
-rw-r--r--src/kile/kile.kcfg12
-rw-r--r--src/kile/kileabbrevview.cpp112
-rw-r--r--src/kile/kileabbrevview.h38
-rw-r--r--src/kile/kileactions.cpp156
-rw-r--r--src/kile/kileactions.h82
-rw-r--r--src/kile/kileappIface.h14
-rw-r--r--src/kile/kileapplication.cpp26
-rw-r--r--src/kile/kileconfigdialog.cpp54
-rw-r--r--src/kile/kileconfigdialog.h17
-rw-r--r--src/kile/kiledocmanager.cpp302
-rw-r--r--src/kile/kiledocmanager.h53
-rw-r--r--src/kile/kiledocumentinfo.cpp194
-rw-r--r--src/kile/kiledocumentinfo.h87
-rw-r--r--src/kile/kileedit.cpp250
-rw-r--r--src/kile/kileedit.h53
-rw-r--r--src/kile/kileerrorhandler.cpp28
-rw-r--r--src/kile/kileerrorhandler.h9
-rw-r--r--src/kile/kileeventfilter.cpp20
-rw-r--r--src/kile/kileeventfilter.h11
-rw-r--r--src/kile/kileextensions.cpp40
-rw-r--r--src/kile/kileextensions.h86
-rw-r--r--src/kile/kilefileselect.cpp44
-rw-r--r--src/kile/kilefileselect.h15
-rw-r--r--src/kile/kilegrepdialog.cpp318
-rw-r--r--src/kile/kilegrepdialog.h65
-rw-r--r--src/kile/kilehelp.cpp62
-rw-r--r--src/kile/kilehelp.h25
-rw-r--r--src/kile/kileinfo.cpp164
-rw-r--r--src/kile/kileinfo.h64
-rw-r--r--src/kile/kilejscript.cpp194
-rw-r--r--src/kile/kilejscript.h60
-rw-r--r--src/kile/kilekonsolewidget.cpp26
-rw-r--r--src/kile/kilekonsolewidget.h11
-rw-r--r--src/kile/kilelauncher.cpp82
-rw-r--r--src/kile/kilelauncher.h37
-rw-r--r--src/kile/kilelistselector.cpp44
-rw-r--r--src/kile/kilelistselector.h14
-rw-r--r--src/kile/kilelogwidget.cpp46
-rw-r--r--src/kile/kilelogwidget.h23
-rw-r--r--src/kile/kilelyxserver.cpp60
-rw-r--r--src/kile/kilelyxserver.h25
-rw-r--r--src/kile/kilemultitabbar.cpp360
-rw-r--r--src/kile/kilemultitabbar.h85
-rw-r--r--src/kile/kilemultitabbar_p.h31
-rw-r--r--src/kile/kileoutputwidget.cpp14
-rw-r--r--src/kile/kileoutputwidget.h7
-rw-r--r--src/kile/kileproject.cpp154
-rw-r--r--src/kile/kileproject.h96
-rw-r--r--src/kile/kileprojectdlgs.cpp200
-rw-r--r--src/kile/kileprojectdlgs.h55
-rw-r--r--src/kile/kileprojectview.cpp130
-rw-r--r--src/kile/kileprojectview.h32
-rw-r--r--src/kile/kilesidebar.cpp52
-rw-r--r--src/kile/kilesidebar.h30
-rw-r--r--src/kile/kilestatsdlg.cpp58
-rw-r--r--src/kile/kilestatsdlg.h12
-rw-r--r--src/kile/kilestatswidget.cpp158
-rw-r--r--src/kile/kilestatswidget.h57
-rw-r--r--src/kile/kilestdactions.cpp458
-rw-r--r--src/kile/kilestdactions.h6
-rw-r--r--src/kile/kilestdtools.cpp64
-rw-r--r--src/kile/kilestdtools.h25
-rw-r--r--src/kile/kilestructurewidget.cpp192
-rw-r--r--src/kile/kilestructurewidget.h82
-rw-r--r--src/kile/kiletool.cpp138
-rw-r--r--src/kile/kiletool.h105
-rw-r--r--src/kile/kiletoolconfigwidget.cpp186
-rw-r--r--src/kile/kiletoolconfigwidget.h51
-rw-r--r--src/kile/kiletoolmanager.cpp116
-rw-r--r--src/kile/kiletoolmanager.h81
-rw-r--r--src/kile/kileuntitled.cpp14
-rw-r--r--src/kile/kileuntitled.h10
-rw-r--r--src/kile/kileversion.cpp12
-rw-r--r--src/kile/kileversion.h10
-rw-r--r--src/kile/kileviewmanager.cpp122
-rw-r--r--src/kile/kileviewmanager.h54
-rw-r--r--src/kile/kilewizard.cpp6
-rw-r--r--src/kile/kilewizard.h2
-rw-r--r--src/kile/latexcmd.cpp86
-rw-r--r--src/kile/latexcmd.h75
-rw-r--r--src/kile/latexcmddialog.cpp260
-rw-r--r--src/kile/latexcmddialog.h46
-rw-r--r--src/kile/latexconfigwidget.ui36
-rw-r--r--src/kile/latexconfigwidget.ui.h8
-rw-r--r--src/kile/latexoutputfilter.cpp92
-rw-r--r--src/kile/latexoutputfilter.h36
-rw-r--r--src/kile/latexoutputinfo.cpp4
-rw-r--r--src/kile/latexoutputinfo.h4
-rw-r--r--src/kile/latextoolconfigwidget.ui10
-rw-r--r--src/kile/librarytoolconfigwidget.ui14
-rw-r--r--src/kile/main.cpp34
-rw-r--r--src/kile/managetemplatesdialog.cpp96
-rw-r--r--src/kile/managetemplatesdialog.h15
-rw-r--r--src/kile/mathenvdialog.cpp168
-rw-r--r--src/kile/mathenvdialog.h35
-rw-r--r--src/kile/newdocumentwidget.ui22
-rw-r--r--src/kile/newfilewizard.cpp32
-rw-r--r--src/kile/newfilewizard.h9
-rw-r--r--src/kile/newtoolwizard.ui42
-rw-r--r--src/kile/newtoolwizard.ui.h24
-rw-r--r--src/kile/outputfilter.cpp24
-rw-r--r--src/kile/outputfilter.h29
-rw-r--r--src/kile/outputinfo.cpp4
-rw-r--r--src/kile/outputinfo.h20
-rw-r--r--src/kile/plaintolatexconverter.cpp10
-rw-r--r--src/kile/plaintolatexconverter.h8
-rw-r--r--src/kile/postscriptdialog.cpp196
-rw-r--r--src/kile/postscriptdialog.h43
-rw-r--r--src/kile/previewconfigwidget.cpp130
-rw-r--r--src/kile/previewconfigwidget.h17
-rw-r--r--src/kile/previewwidget.cpp42
-rw-r--r--src/kile/previewwidget.h21
-rw-r--r--src/kile/processtoolconfigwidget.ui10
-rw-r--r--src/kile/quickdocumentdialog.cpp1142
-rw-r--r--src/kile/quickdocumentdialog.h152
-rw-r--r--src/kile/quickpreview.cpp104
-rw-r--r--src/kile/quickpreview.h29
-rw-r--r--src/kile/quicktoolconfigwidget.ui34
-rw-r--r--src/kile/quicktoolconfigwidget.ui.h22
-rw-r--r--src/kile/scriptingconfigwidget.ui22
-rw-r--r--src/kile/scriptsmanagementwidget.cpp72
-rw-r--r--src/kile/scriptsmanagementwidget.h17
-rw-r--r--src/kile/structureconfigwidget.ui42
-rw-r--r--src/kile/symbols/Makefile.am2
-rw-r--r--src/kile/symbols/gesymb.cpp46
-rw-r--r--src/kile/symbols/gesymb.h12
-rw-r--r--src/kile/symbolview.cpp112
-rw-r--r--src/kile/symbolview.h35
-rw-r--r--src/kile/symbolviewconfig.ui22
-rw-r--r--src/kile/tabbingdialog.cpp26
-rw-r--r--src/kile/tabbingdialog.h9
-rw-r--r--src/kile/tabulardialog.cpp820
-rw-r--r--src/kile/tabulardialog.h144
-rw-r--r--src/kile/templates.cpp98
-rw-r--r--src/kile/templates.h58
-rw-r--r--src/kile/texdocdialog.cpp242
-rw-r--r--src/kile/texdocdialog.h45
-rw-r--r--src/kile/toolconfigwidget.ui62
-rw-r--r--src/kile/userhelp.cpp60
-rw-r--r--src/kile/userhelp.h19
-rw-r--r--src/kile/userhelpdialog.cpp134
-rw-r--r--src/kile/userhelpdialog.h20
-rw-r--r--src/kile/usermenudialog.cpp64
-rw-r--r--src/kile/usermenudialog.h31
175 files changed, 7311 insertions, 7215 deletions
diff --git a/src/kile/cleandialog.cpp b/src/kile/cleandialog.cpp
index 05cceb6..11c6265 100644
--- a/src/kile/cleandialog.cpp
+++ b/src/kile/cleandialog.cpp
@@ -21,33 +21,33 @@
#include <kpushbutton.h>
#include <klistview.h>
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qpixmap.h>
-#include <qfileinfo.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqpixmap.h>
+#include <tqfileinfo.h>
#include "kiledebug.h"
namespace KileDialog
{
- Clean::Clean(QWidget *parent, const QString & filename, const QStringList & extlist) :
- KDialogBase( KDialogBase::Plain, i18n("Delete Files"), Ok | Cancel, Ok, parent, 0, true, true),
+ Clean::Clean(TQWidget *tqparent, const TQString & filename, const TQStringList & extlist) :
+ KDialogBase( KDialogBase::Plain, i18n("Delete Files"), Ok | Cancel, Ok, tqparent, 0, true, true),
m_extlist(extlist)
{
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(plainPage(), 6,6 );
+ TQVBoxLayout *vbox = new TQVBoxLayout(plainPage(), 6,6 );
// label widgets
- QWidget *labelwidget = new QWidget(plainPage());
- QHBoxLayout *labellayout = new QHBoxLayout(labelwidget);
+ TQWidget *labelwidget = new TQWidget(plainPage());
+ TQHBoxLayout *labeltqlayout = new TQHBoxLayout(labelwidget);
// line 1: picture and label
- QLabel *picture = new QLabel("", labelwidget);
+ TQLabel *picture = new TQLabel("", labelwidget);
picture->setPixmap( KGlobal::instance()->iconLoader()->loadIcon("messagebox_warning", KIcon::NoGroup, KIcon::SizeMedium) );
- QLabel *label = new QLabel(i18n( "Do you really want to delete these files?" ), labelwidget);
- labellayout->addWidget(picture);
- labellayout->addSpacing(20);
- labellayout->addWidget(label);
+ TQLabel *label = new TQLabel(i18n( "Do you really want to delete these files?" ), labelwidget);
+ labeltqlayout->addWidget(picture);
+ labeltqlayout->addSpacing(20);
+ labeltqlayout->addWidget(label);
// line 2: listview
listview = new KListView(plainPage());
@@ -55,15 +55,15 @@ namespace KileDialog
listview->setSorting(-1);
// insert items into listview
- QString base = QFileInfo(filename).baseName(true);
+ TQString base = TQFileInfo(filename).baseName(true);
for (uint i=0; i < m_extlist.count(); ++i)
{
- QCheckListItem *item = new QCheckListItem(listview, base + m_extlist[i], QCheckListItem::CheckBox);
+ TQCheckListItem *item = new TQCheckListItem(listview, base + m_extlist[i], TQCheckListItem::CheckBox);
item->setOn(true);
listview->insertItem(item);
}
- vbox->addWidget(labelwidget,0,Qt::AlignHCenter);
+ vbox->addWidget(labelwidget,0,TQt::AlignHCenter);
vbox->addWidget(listview);
}
@@ -72,18 +72,18 @@ namespace KileDialog
// get all selected items
- const QStringList & Clean::getCleanlist()
+ const TQStringList & Clean::getCleanlist()
{
- QStringList templist;
+ TQStringList templist;
- QCheckListItem *item = (QCheckListItem *)listview->firstChild();
+ TQCheckListItem *item = (TQCheckListItem *)listview->firstChild();
int i = m_extlist.count() - 1;
while ( item )
{
if ( item->isOn() && item->text(0).endsWith(m_extlist[i]) )
templist.append(m_extlist[i]);
- item = (QCheckListItem *)item->nextSibling();
+ item = (TQCheckListItem *)item->nextSibling();
--i;
}
diff --git a/src/kile/cleandialog.h b/src/kile/cleandialog.h
index 18636e7..20e9193 100644
--- a/src/kile/cleandialog.h
+++ b/src/kile/cleandialog.h
@@ -18,7 +18,7 @@
#define CLEANDIALOG_H
#include <kdialogbase.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
class KListView;
@@ -31,15 +31,16 @@ namespace KileDialog
class Clean : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- Clean(QWidget *parent, const QString & filename, const QStringList &extlist);
+ Clean(TQWidget *tqparent, const TQString & filename, const TQStringList &extlist);
~Clean();
- const QStringList & getCleanlist();
+ const TQStringList & getCleanlist();
private:
KListView *listview;
- QStringList m_extlist;
+ TQStringList m_extlist;
};
}
diff --git a/src/kile/codecompletion.cpp b/src/kile/codecompletion.cpp
index ca34243..a738dca 100644
--- a/src/kile/codecompletion.cpp
+++ b/src/kile/codecompletion.cpp
@@ -16,10 +16,10 @@
#include "codecompletion.h"
-#include <qregexp.h>
-#include <qfile.h>
-#include <qtimer.h>
-#include <qdict.h>
+#include <tqregexp.h>
+#include <tqfile.h>
+#include <tqtimer.h>
+#include <tqdict.h>
#include "kiledebug.h"
#include <klocale.h>
@@ -38,12 +38,12 @@
namespace KileDocument
{
- static QRegExp::QRegExp reRef;
- static QRegExp::QRegExp reRefExt;
- static QRegExp::QRegExp reCite;
- static QRegExp::QRegExp reCiteExt;
- static QRegExp::QRegExp reNotRefChars("[^a-zA-Z0-9_@\\.\\+\\-\\*\\:]");
- static QRegExp::QRegExp reNotCiteChars("[^a-zA-Z0-9_@\\-\\:]");
+ static TQRegExp::TQRegExp reRef;
+ static TQRegExp::TQRegExp reRefExt;
+ static TQRegExp::TQRegExp reCite;
+ static TQRegExp::TQRegExp reCiteExt;
+ static TQRegExp::TQRegExp reNotRefChars("[^a-zA-Z0-9_@\\.\\+\\-\\*\\:]");
+ static TQRegExp::TQRegExp reNotCiteChars("[^a-zA-Z0-9_@\\-\\:]");
CodeCompletion::CodeCompletion(KileInfo *info) : m_ki(info), m_view(0L)
{
@@ -59,8 +59,8 @@ namespace KileDocument
m_localAbbrevFile = locateLocal("appdata", "complete/abbreviation/", true) + "kile-abbrevs.cwl";
//reRef.setPattern("^\\\\(pageref|ref|xyz)\\{");
- m_completeTimer = new QTimer( this );
- connect(m_completeTimer, SIGNAL( timeout() ), this, SLOT( slotCompleteValueList() ) );
+ m_completeTimer = new TQTimer( this );
+ connect(m_completeTimer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( slotCompleteValueList() ) );
}
CodeCompletion::~CodeCompletion() {}
@@ -85,11 +85,11 @@ namespace KileDocument
return m_type;
}
- CodeCompletion::Type CodeCompletion::getType( const QString &text )
+ CodeCompletion::Type CodeCompletion::getType( const TQString &text )
{
- if ( text.find( reRef ) != -1 )
+ if ( text.tqfind( reRef ) != -1 )
return CodeCompletion::ctReference;
- else if ( text.find( reCite ) != -1 )
+ else if ( text.tqfind( reCite ) != -1 )
return CodeCompletion::ctCitation;
else
return CodeCompletion::ctNone;
@@ -100,45 +100,45 @@ namespace KileDocument
return m_mode;
}
- CodeCompletion::Type CodeCompletion::insideReference(QString &startpattern)
+ CodeCompletion::Type CodeCompletion::insideReference(TQString &startpattern)
{
if ( m_view->getDoc() )
{
uint column = m_view->cursorColumnReal();
- QString currentline = m_view->getDoc()->textLine(m_view->cursorLine()).left(column);
- int pos = currentline.findRev('\\');
+ TQString currentline = m_view->getDoc()->textLine(m_view->cursorLine()).left(column);
+ int pos = currentline.tqfindRev('\\');
if ( pos >= 0 )
{
- QString command = currentline.mid(pos,column-pos);
+ TQString command = currentline.mid(pos,column-pos);
KILE_DEBUG() << "pos=" << pos << ",column=" << column << ",currentline=" << currentline << ",command=" << command << endl;
- if( command.find(reRefExt) != -1 ){
+ if( command.tqfind(reRefExt) != -1 ){
KILE_DEBUG() << "reRefExt" << endl;
startpattern = command.right(command.length()-reRefExt.cap(0).length());
KILE_DEBUG() << "startpattern=" << startpattern << endl;
- if ( startpattern.find(reNotRefChars) == -1 ){
+ if ( startpattern.tqfind(reNotRefChars) == -1 ){
return CodeCompletion::ctReference ;
}
}
- else if ( command.find(reRef) != -1 ){
+ else if ( command.tqfind(reRef) != -1 ){
startpattern = command.right(command.length()-reRef.cap(0).length());
KILE_DEBUG() << "startpattern=" << startpattern << endl;
- if ( startpattern.find(reNotRefChars) == -1 ){
+ if ( startpattern.tqfind(reNotRefChars) == -1 ){
return CodeCompletion::ctReference ;
}
}
- else if( command.find(reCiteExt) != -1 ){
+ else if( command.tqfind(reCiteExt) != -1 ){
KILE_DEBUG() << "reCiteExt" << endl;
startpattern = command.right(command.length()-reCiteExt.cap(0).length());
KILE_DEBUG() << "startpattern=" << startpattern << endl;
- if ( startpattern.find(reNotCiteChars) == -1 ){
+ if ( startpattern.tqfind(reNotCiteChars) == -1 ){
return CodeCompletion::ctCitation;
}
}
- else if ( command.find(reCite) != -1 ){
+ else if ( command.tqfind(reCite) != -1 ){
startpattern = command.right(command.length()-reCite.cap(0).length());
KILE_DEBUG() << "startpattern=" << startpattern << endl;
- if ( startpattern.find(reNotCiteChars) == -1 ){
+ if ( startpattern.tqfind(reNotCiteChars) == -1 ){
return CodeCompletion::ctCitation;
}
}
@@ -179,7 +179,7 @@ namespace KileDocument
KILE_DEBUG() << " read wordlists..." << endl;
// wordlists for Tex/Latex mode
- QStringList files = KileConfig::completeTex();
+ TQStringList files = KileConfig::completeTex();
setWordlist( files, "tex", &m_texlist );
// wordlist for dictionary mode
@@ -218,29 +218,29 @@ namespace KileDocument
void CodeCompletion::setReferences()
{
// build list of references
- QString references = getCommandList(KileDocument::CmdAttrReference);
- references.replace("*","\\*");
+ TQString references = getCommandList(KileDocument::CmdAttrReference);
+ references.tqreplace("*","\\*");
reRef.setPattern("^\\\\(" + references + ")\\{");
reRefExt.setPattern("^\\\\(" + references + ")\\{[^\\{\\}\\\\]+,");
// build list of citations
- QString citations = getCommandList(KileDocument::CmdAttrCitations);
- citations.replace("*","\\*");
+ TQString citations = getCommandList(KileDocument::CmdAttrCitations);
+ citations.tqreplace("*","\\*");
reCite.setPattern("^\\\\(((c|C|noc)(ite|itep|itet|itealt|itealp|iteauthor|iteyear|iteyearpar|itetext))" + citations + ")\\{");
reCiteExt.setPattern("^\\\\(((c|C|noc)(ite|itep|itet|itealt|itealp|iteauthor|iteyear|iteyearpar|itetext))" + citations + ")\\{[^\\{\\}\\\\]+,");
}
- QString CodeCompletion::getCommandList(KileDocument::CmdAttribute attrtype)
+ TQString CodeCompletion::getCommandList(KileDocument::CmdAttribute attrtype)
{
- QStringList cmdlist;
- QStringList::ConstIterator it;
+ TQStringList cmdlist;
+ TQStringList::ConstIterator it;
// get info about user defined references
KileDocument::LatexCommands *cmd = m_ki->latexCommands();
cmd->commandList(cmdlist,attrtype,false);
// build list of references
- QString commands = QString::null;
+ TQString commands = TQString();
for ( it=cmdlist.begin(); it != cmdlist.end(); ++it )
{
if ( cmd->isStarredEnv(*it) )
@@ -252,13 +252,13 @@ namespace KileDocument
//////////////////// wordlists ////////////////////
- void CodeCompletion::setWordlist( const QStringList &files, const QString &dir,
- QValueList<KTextEditor::CompletionEntry> *entrylist
+ void CodeCompletion::setWordlist( const TQStringList &files, const TQString &dir,
+ TQValueList<KTextEditor::CompletionEntry> *entrylist
)
{
// read wordlists from files
- QStringList wordlist;
+ TQStringList wordlist;
for ( uint i = 0; i < files.count(); ++i )
{
// if checked, the wordlist has to be read
@@ -282,14 +282,14 @@ namespace KileDocument
else if ( dir == "abbreviation" )
{
// read local wordlist
- QStringList localWordlist;
- readWordlist(localWordlist, QString::null, false);
+ TQStringList localWordlist;
+ readWordlist(localWordlist, TQString(), false);
// add local/global wordlists to the abbreviation view
m_abbrevListview->init(&wordlist,&localWordlist);
// finally add local wordlists to the abbreviation list
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it=localWordlist.begin(); it!=localWordlist.end(); ++it )
wordlist.append( *it );
@@ -298,10 +298,10 @@ namespace KileDocument
}
}
- void CodeCompletion::addCommandsToTexlist(QStringList &wordlist)
+ void CodeCompletion::addCommandsToTexlist(TQStringList &wordlist)
{
- QStringList cmdlist;
- QStringList::ConstIterator it;
+ TQStringList cmdlist;
+ TQStringList::ConstIterator it;
KileDocument::LatexCmdAttributes attr;
// get info about user defined commands and environments
@@ -313,8 +313,8 @@ namespace KileDocument
{
if ( cmd->commandAttributes(*it,attr) )
{
- QString command,eos;
- QStringList entrylist;
+ TQString command,eos;
+ TQStringList entrylist;
if ( attr.type < KileDocument::CmdAttrLabel ) // environment
{
command = "\\begin{" + (*it);
@@ -323,7 +323,7 @@ namespace KileDocument
else // command
{
command = (*it);
- // eos = QString::null;
+ // eos = TQString();
}
// get all possibilities into a stringlist
@@ -338,10 +338,10 @@ namespace KileDocument
}
// finally append entries to wordlist
- QStringList::ConstIterator itentry;
+ TQStringList::ConstIterator itentry;
for ( itentry=entrylist.begin(); itentry != entrylist.end(); ++itentry )
{
- QString entry = (*itentry);
+ TQString entry = (*itentry);
if ( ! attr.parameter.isEmpty() )
entry += "{param}";
if ( attr.type == KileDocument::CmdAttrList )
@@ -354,7 +354,7 @@ namespace KileDocument
//////////////////// completion box ////////////////////
- void CodeCompletion::completeWord(const QString &text, CodeCompletion::Mode mode)
+ void CodeCompletion::completeWord(const TQString &text, CodeCompletion::Mode mode)
{
KILE_DEBUG() << "==CodeCompletion::completeWord(" << text << ")=========" << endl;
KILE_DEBUG() << "\tm_view = " << m_view << endl;
@@ -375,8 +375,8 @@ namespace KileDocument
// switch to cmLatex mode, if cmLabel is chosen without any entries
if ( mode==cmLabel && m_labellist.count()==0 ) {
- QString s = doc->textLine(m_ycursor);
- int pos = s.findRev("\\",m_xcursor);
+ TQString s = doc->textLine(m_ycursor);
+ int pos = s.tqfindRev("\\",m_xcursor);
if (pos < 0) {
KILE_DEBUG() << "\tfound no backslash! s=" << s << endl;
return;
@@ -388,7 +388,7 @@ namespace KileDocument
}
// determine the current list
- QValueList<KTextEditor::CompletionEntry> list;
+ TQValueList<KTextEditor::CompletionEntry> list;
switch ( m_mode )
{
case cmLatex: // fall through here
@@ -411,8 +411,8 @@ namespace KileDocument
}
// is it necessary to show the complete dialog?
- QString entry, type;
- QString pattern = ( m_mode != cmEnvironment ) ? text : "\\begin{" + text;
+ TQString entry, type;
+ TQString pattern = ( m_mode != cmEnvironment ) ? text : "\\begin{" + text;
uint n = countEntries( pattern, &list, &entry, &type );
KILE_DEBUG() << "entries = " << n << endl;
@@ -451,12 +451,12 @@ namespace KileDocument
iface->showCompletionBox( list, m_textlen );
}
- void CodeCompletion::appendNewCommands(QValueList<KTextEditor::CompletionEntry> & list)
+ void CodeCompletion::appendNewCommands(TQValueList<KTextEditor::CompletionEntry> & list)
{
KTextEditor::CompletionEntry e;
- const QStringList *ncommands = m_ki->allNewCommands();
- QStringList::ConstIterator it;
- QStringList::ConstIterator itend(ncommands->end());
+ const TQStringList *ncommands = m_ki->allNewCommands();
+ TQStringList::ConstIterator it;
+ TQStringList::ConstIterator itend(ncommands->end());
for ( it = ncommands->begin(); it != itend; ++it )
{
e.text = *it;
@@ -464,17 +464,17 @@ namespace KileDocument
}
}
- void CodeCompletion::completeFromList(const QStringList *list,const QString &pattern)
+ void CodeCompletion::completeFromList(const TQStringList *list,const TQString &pattern)
{
KTextEditor::CompletionEntry e;
KILE_DEBUG() << "completeFromList: " << list->count() << " items" << " << pattern=" << pattern<< endl;
- QStringList sortedlist( *list );
+ TQStringList sortedlist( *list );
sortedlist.sort();
m_labellist.clear();
- QStringList::ConstIterator it;
- QStringList::ConstIterator itend(sortedlist.end());
+ TQStringList::ConstIterator it;
+ TQStringList::ConstIterator itend(sortedlist.end());
for ( it = sortedlist.begin(); it != itend; ++it )
{
e.text = *it;
@@ -530,9 +530,9 @@ namespace KileDocument
// - set cursor position
// - insert bullets
- QString CodeCompletion::filterCompletionText( const QString &text, const QString &type )
+ TQString CodeCompletion::filterCompletionText( const TQString &text, const TQString &type )
{
- static QRegExp::QRegExp reEnv = QRegExp("^\\\\(begin|end)[^a-zA-Z]+");
+ static TQRegExp::TQRegExp reEnv = TQRegExp("^\\\\(begin|end)[^a-zA-Z]+");
KILE_DEBUG() << " complete filter: " << text << " type " << type << endl;
m_type = getType( text ); // remember current type
@@ -554,20 +554,20 @@ namespace KileDocument
m_xoffset = m_yoffset = 0;
// build the text
- QString s,prefix;
+ TQString s,prefix;
Kate::Document *doc = m_view->getDoc();
- QString textline = doc->textLine(row);
+ TQString textline = doc->textLine(row);
switch ( m_mode )
{
case cmLatex:
s = buildLatexText( text, m_yoffset, m_xoffset );
- if ( m_autobrackets && textline.at(col)=='}' && m_text.find('{')>=0 )
+ if ( m_autobrackets && textline.at(col)=='}' && m_text.tqfind('{')>=0 )
{
doc->removeText(row,col,row,col+1);
}
break;
case cmEnvironment:
- prefix = QString::null;
+ prefix = TQString();
if ( m_autoindent )
{
if ( col-m_textlen>0 )
@@ -580,7 +580,7 @@ namespace KileDocument
}
}
s = buildEnvironmentText( text, type, prefix, m_yoffset, m_xoffset );
- if ( m_autobrackets && textline.at(col)=='}' && (textline[m_xstart]!='\\' || m_text.find('{')>=0 ) )
+ if ( m_autobrackets && textline.at(col)=='}' && (textline[m_xstart]!='\\' || m_text.tqfind('{')>=0 ) )
{
doc->removeText(row,col,row,col+1);
}
@@ -621,27 +621,27 @@ namespace KileDocument
//////////////////// text in cmLatex mode ////////////////////
- QString CodeCompletion::buildLatexText( const QString &text, uint &ypos, uint &xpos )
+ TQString CodeCompletion::buildLatexText( const TQString &text, uint &ypos, uint &xpos )
{
return parseText( stripParameter( text ), ypos, xpos, true );
}
//////////////////// text in cmEnvironment mode ////////////////////
- QString CodeCompletion::buildEnvironmentText( const QString &text, const QString &type,
- const QString &prefix, uint &ypos, uint &xpos )
+ TQString CodeCompletion::buildEnvironmentText( const TQString &text, const TQString &type,
+ const TQString &prefix, uint &ypos, uint &xpos )
{
- static QRegExp::QRegExp reEnv = QRegExp("^\\\\(begin|end)\\{([^\\}]*)\\}(.*)");
+ static TQRegExp::TQRegExp reEnv = TQRegExp("^\\\\(begin|end)\\{([^\\}]*)\\}(.*)");
if (reEnv.search(text) == -1) return text;
- QString parameter = stripParameter( reEnv.cap(3) );
- QString start = reEnv.cap(1);
- QString envname = reEnv.cap(2);
- QString whitespace = getWhiteSpace(prefix);
- QString envIndent = m_ki->editorExtension()->autoIndentEnvironment();
+ TQString parameter = stripParameter( reEnv.cap(3) );
+ TQString start = reEnv.cap(1);
+ TQString envname = reEnv.cap(2);
+ TQString whitespace = getWhiteSpace(prefix);
+ TQString envIndent = m_ki->editorExtension()->autoIndentEnvironment();
- QString s = "\\" + start + "{" + envname + "}" + parameter + "\n";
+ TQString s = "\\" + start + "{" + envname + "}" + parameter + "\n";
s += whitespace;
if ( start != "end" )
@@ -678,9 +678,9 @@ namespace KileDocument
return s;
}
- QString CodeCompletion::getWhiteSpace(const QString &s)
+ TQString CodeCompletion::getWhiteSpace(const TQString &s)
{
- QString whitespace = s;
+ TQString whitespace = s;
for ( uint i=0; i<whitespace.length(); ++i )
{
if ( ! whitespace[i].isSpace() )
@@ -691,11 +691,11 @@ namespace KileDocument
//////////////////// text in cmAbbreviation mode ////////////////////
- QString CodeCompletion::buildAbbreviationText( const QString &text )
+ TQString CodeCompletion::buildAbbreviationText( const TQString &text )
{
- QString s;
+ TQString s;
- int index = text.find( '=' );
+ int index = text.tqfind( '=' );
if ( index >= 0 )
{
// determine text to insert
@@ -717,7 +717,7 @@ namespace KileDocument
//////////////////// text in cmLabel mode ////////////////////
- QString CodeCompletion::buildLabelText( const QString &text )
+ TQString CodeCompletion::buildLabelText( const TQString &text )
{
if ( text.at( 0 ) == ' ' )
{
@@ -737,10 +737,10 @@ namespace KileDocument
//////////////////// some functions ////////////////////
- QString CodeCompletion::parseText( const QString &text, uint &ypos, uint &xpos, bool checkgroup )
+ TQString CodeCompletion::parseText( const TQString &text, uint &ypos, uint &xpos, bool checkgroup )
{
bool foundgroup = false;
- QString s = "";
+ TQString s = "";
xpos = ypos = 0;
for ( uint i = 0; i < text.length(); ++i )
@@ -808,7 +808,7 @@ namespace KileDocument
int pos = 0;
// search for braces, brackets and parens
- switch ( QChar( s[ 1 ] ) )
+ switch ( TQChar( s[ 1 ] ) )
{
case 'l' :
if ( s.left( 6 ) == "\\left " )
@@ -849,10 +849,10 @@ namespace KileDocument
// strip all names enclosed in braces
// consider also beamer like stuff [<...>] and <...>
- QString CodeCompletion::stripParameter( const QString &text )
+ TQString CodeCompletion::stripParameter( const TQString &text )
{
- QString s = "";
- const QChar *ch = text.unicode();
+ TQString s = "";
+ const TQChar *ch = text.tqunicode();
bool ignore = false;
@@ -889,20 +889,20 @@ namespace KileDocument
//////////////////// read wordlists ////////////////////
- void CodeCompletion::readWordlist( QStringList &wordlist, const QString &filename, bool global )
+ void CodeCompletion::readWordlist( TQStringList &wordlist, const TQString &filename, bool global )
{
- QString file = ( global )
+ TQString file = ( global )
? KGlobal::dirs()->findResource( "appdata", "complete/" + filename )
: m_localAbbrevFile;
if ( file.isEmpty() ) return;
- QFile f( file );
+ TQFile f( file );
if ( f.open( IO_ReadOnly ) )
{ // file opened successfully
- QTextStream t( &f ); // use a text stream
+ TQTextStream t( &f ); // use a text stream
while ( ! t.eof() )
{ // until end of file...
- QString s = t.readLine().stripWhiteSpace(); // line of text excluding '\n'
+ TQString s = t.readLine().stripWhiteSpace(); // line of text excluding '\n'
if ( ! ( s.isEmpty() || s.at( 0 ) == '#' ) )
{
wordlist.append( s );
@@ -912,14 +912,14 @@ namespace KileDocument
}
}
- void CodeCompletion::setCompletionEntries( QValueList<KTextEditor::CompletionEntry> *list,
- const QStringList &wordlist )
+ void CodeCompletion::setCompletionEntries( TQValueList<KTextEditor::CompletionEntry> *list,
+ const TQStringList &wordlist )
{
// clear the list of completion entries
list->clear();
KTextEditor::CompletionEntry e;
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
// build new entries
for ( it=wordlist.begin(); it != wordlist.end(); ++it )
@@ -929,31 +929,31 @@ namespace KileDocument
e.type = "";
// add new entry
- if ( list->findIndex(e) == -1 )
+ if ( list->tqfindIndex(e) == -1 )
list->append(e);
}
}
- void CodeCompletion::setCompletionEntriesTexmode( QValueList<KTextEditor::CompletionEntry> *list,
- const QStringList &wordlist )
+ void CodeCompletion::setCompletionEntriesTexmode( TQValueList<KTextEditor::CompletionEntry> *list,
+ const TQStringList &wordlist )
{
// clear the list of completion entries
list->clear();
- // create a QMap for a user defined sort
+ // create a TQMap for a user defined sort
// order: \abc, \abc[], \abc{}, \abc*, \abc*[], \abc*{}, \abcd, \abcD
- QStringList keylist;
- QMap<QString,QString> map;
+ TQStringList keylist;
+ TQMap<TQString,TQString> map;
for ( uint i=0; i< wordlist.count(); ++i )
{
- QString s = wordlist[i];
+ TQString s = wordlist[i];
for ( uint j=0; j<s.length(); ++j )
{
- QChar ch = s[j];
- if ( ch>='A' && ch<='Z' )
+ TQChar ch = s[j];
+ if ( ch.latin1()>='A' && ch.latin1()<='Z' )
s[j] = (int)ch + 32 ;
- else if ( ch>='a' && ch<='z' )
+ else if ( ch.latin1()>='a' && ch.latin1()<='z' )
s[j] = (int)ch - 32 ;
else if ( ch == '}' )
s[j] = 48;
@@ -967,7 +967,7 @@ namespace KileDocument
s[j] = 52;
}
// don't allow duplicate entries
- if ( ! map.contains(s) )
+ if ( ! map.tqcontains(s) )
{
map[s] = wordlist[i];
keylist.append(s);
@@ -982,12 +982,12 @@ namespace KileDocument
// if the last 5 chars of an environment are '\item', it is a
// list environment, where the '\item' tag is also inserted
KTextEditor::CompletionEntry e;
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it=keylist.begin(); it != keylist.end(); ++it )
{
// get real entry
- QString s = map[*it];
+ TQString s = map[*it];
if ( s.left( 7 ) == "\\begin{" && s.right( 5 ) == "\\item" )
{
e.text = s.left( s.length() - 5 ); // list environment entry
@@ -1009,11 +1009,11 @@ namespace KileDocument
// because special functions are only called, when there are 0
// or 1 entries.
- uint CodeCompletion::countEntries( const QString &pattern,
- QValueList<KTextEditor::CompletionEntry> *list,
- QString *entry, QString *type )
+ uint CodeCompletion::countEntries( const TQString &pattern,
+ TQValueList<KTextEditor::CompletionEntry> *list,
+ TQString *entry, TQString *type )
{
- QValueList<KTextEditor::CompletionEntry>::Iterator it;
+ TQValueList<KTextEditor::CompletionEntry>::Iterator it;
uint n = 0;
for ( it = list->begin(); it != list->end() && n < 2; ++it )
@@ -1029,19 +1029,19 @@ namespace KileDocument
return n;
}
- QString CodeCompletion::findExpansion(const QString &abbrev)
+ TQString CodeCompletion::findExpansion(const TQString &abbrev)
{
- QValueList<KTextEditor::CompletionEntry>::Iterator it;
+ TQValueList<KTextEditor::CompletionEntry>::Iterator it;
for ( it=m_abbrevlist.begin(); it!=m_abbrevlist.end(); ++it )
{
- QString s = (*it).text;
- int index = s.find("=");
+ TQString s = (*it).text;
+ int index = s.tqfind("=");
if ( index>=0 && s.left(index)==abbrev )
return s.right( s.length()-index-1 );
}
- return QString::null;
+ return TQString();
}
void CodeCompletion::editComplete(Kate::View *view, Mode mode)
@@ -1059,7 +1059,7 @@ namespace KileDocument
// check for a special case: call from inside of a reference command
if ( mode==cmLatex )
{
- QString startpattern;
+ TQString startpattern;
CodeCompletion::Type reftype = insideReference(startpattern);
if ( reftype != CodeCompletion::ctNone )
{
@@ -1069,7 +1069,7 @@ namespace KileDocument
}
}
- QString word;
+ TQString word;
Type type;
if ( getCompleteWord(( mode == cmLatex ) ? true : false, word, type ) )
{
@@ -1085,7 +1085,7 @@ namespace KileDocument
}
}
- void CodeCompletion::editCompleteList(Type type,const QString &pattern)
+ void CodeCompletion::editCompleteList(Type type,const TQString &pattern)
{
KILE_DEBUG() << "==editCompleteList=============" << endl;
m_keylistType = type;
@@ -1138,7 +1138,7 @@ namespace KileDocument
CompletionAborted();
}
- void CodeCompletion::slotFilterCompletion( KTextEditor::CompletionEntry* c, QString *s )
+ void CodeCompletion::slotFilterCompletion( KTextEditor::CompletionEntry* c, TQString *s )
{
KILE_DEBUG() << "==slotFilterCompletion (" << m_kilecompletion << "," << m_inprogress << ")=============" << endl;
if ( inProgress() ) // dani 28.09.2004
@@ -1151,7 +1151,7 @@ namespace KileDocument
}
}
- void CodeCompletion::slotCharactersInserted(int, int, const QString& string )
+ void CodeCompletion::slotCharactersInserted(int, int, const TQString& string )
{
KILE_DEBUG() << "==slotCharactersInserted (" << m_kilecompletion << "," << m_inprogress << ", " << m_ref << ", " << string << ")=============" << endl;
@@ -1176,7 +1176,7 @@ namespace KileDocument
// of a reference command without a labellist.
if ( ! m_ref )
{
- QString startpattern;
+ TQString startpattern;
CodeCompletion::Type reftype = insideReference(startpattern);
if ( reftype != CodeCompletion::ctNone )
{
@@ -1186,7 +1186,7 @@ namespace KileDocument
}
}
- QString word;
+ TQString word;
Type type;
bool found = ( m_ref ) ? getReferenceWord(word) : getCompleteWord(true,word,type );
if ( found )
@@ -1220,17 +1220,17 @@ namespace KileDocument
//////////////////// testing characters (dani) ////////////////////
- static bool isBackslash ( QChar ch )
+ static bool isBackslash ( TQChar ch )
{
return ( ch == '\\' );
}
- bool CodeCompletion::getCompleteWord(bool latexmode, QString &text, Type &type )
+ bool CodeCompletion::getCompleteWord(bool latexmode, TQString &text, Type &type )
{
if ( !m_view ) return false;
uint row, col;
- QChar ch;
+ TQChar ch;
// get current position
m_view->cursorPositionReal( &row, &col );
@@ -1240,7 +1240,7 @@ namespace KileDocument
return "";
// get current text line
- QString textline = m_view->getDoc()->textLine( row );
+ TQString textline = m_view->getDoc()->textLine( row );
//
int n = 0; // number of characters
@@ -1267,12 +1267,12 @@ namespace KileDocument
return !text.isEmpty();
}
- bool CodeCompletion::getReferenceWord(QString &text)
+ bool CodeCompletion::getReferenceWord(TQString &text)
{
if ( !m_view ) return false;
uint row, col;
- QChar ch;
+ TQChar ch;
// get current position
m_view->cursorPositionReal( &row, &col );
@@ -1281,10 +1281,10 @@ namespace KileDocument
return false;
// get current text line
- QString textline = m_view->getDoc()->textLine( row );
+ TQString textline = m_view->getDoc()->textLine( row );
// search the current reference string
- int pos = textline.findRev(reNotRefChars,col-1);
+ int pos = textline.tqfindRev(reNotRefChars,col-1);
if ( pos < 0 )
pos = 0;
@@ -1293,18 +1293,18 @@ namespace KileDocument
return ( (uint)pos < col-1 );
}
- void CodeCompletion::getDocumentWords(const QString &text,
- QValueList<KTextEditor::CompletionEntry> &list)
+ void CodeCompletion::getDocumentWords(const TQString &text,
+ TQValueList<KTextEditor::CompletionEntry> &list)
{
KILE_DEBUG() << "getDocumentWords: " << endl;
list.clear();
- QRegExp reg("(\\\\?\\b" + QString(text[0]) + "[^\\W\\d_]+)\\b");
+ TQRegExp reg("(\\\\?\\b" + TQString(text[0]) + "[^\\W\\d_]+)\\b");
Kate::Document *doc = m_view->getDoc();
- QString s;
+ TQString s;
KTextEditor::CompletionEntry e;
- QDict<bool> seen;
+ TQDict<bool> seen;
bool alreadyseen = true;
for (uint i=0; i<doc->numLines(); ++i) {
@@ -1313,7 +1313,7 @@ namespace KileDocument
while ( pos >= 0 ) {
pos = reg.search(s,pos);
if ( pos >= 0 ) {
- if ( reg.cap(1).at(0)!='\\' && text!=reg.cap(1) && !seen.find(reg.cap(1)) ) {
+ if ( reg.cap(1).at(0)!='\\' && text!=reg.cap(1) && !seen.tqfind(reg.cap(1)) ) {
e.text = reg.cap(1); // normal entry
e.type = "";
list.append( e );
@@ -1327,7 +1327,7 @@ namespace KileDocument
//////////////////// counting backslashes (dani) ////////////////////
- bool CodeCompletion::oddBackslashes( const QString& text, int index )
+ bool CodeCompletion::oddBackslashes( const TQString& text, int index )
{
uint n = 0;
while ( index >= 0 && isBackslash( text.at( index ) ) )
@@ -1340,22 +1340,22 @@ namespace KileDocument
//////////////////// complete auto abbreviation ////////////////////
- bool CodeCompletion::completeAutoAbbreviation(const QString &text)
+ bool CodeCompletion::completeAutoAbbreviation(const TQString &text)
{
if ( text.length() != 1 )
return false;
- QChar ch = text[0];
+ TQChar ch = text[0];
if ( ! (ch.isSpace() || ch.isPunct()) )
return false;
uint row,col;
m_view->cursorPositionReal( &row, &col );
- QString abbrev = getAbbreviationWord(row,col-1);
+ TQString abbrev = getAbbreviationWord(row,col-1);
if ( abbrev.isEmpty() )
return false;
- QString expansion = findExpansion(abbrev);
+ TQString expansion = findExpansion(abbrev);
if ( expansion.isEmpty() )
return false;
@@ -1371,14 +1371,14 @@ namespace KileDocument
return true;
}
- QString CodeCompletion::getAbbreviationWord(uint row, uint col)
+ TQString CodeCompletion::getAbbreviationWord(uint row, uint col)
{
- QString textline = m_view->getDoc()->textLine( row );
+ TQString textline = m_view->getDoc()->textLine( row );
int index = (int)col;
while ( --index >= 0 )
{
- QChar ch = textline.at( index );
+ TQChar ch = textline.at( index );
if ( ! ch.isLetterOrNumber() )
break;
}
@@ -1392,12 +1392,12 @@ namespace KileDocument
{
m_abbrevListview = listview;
- connect( m_abbrevListview, SIGNAL(updateAbbrevList(const QString &, const QString &)),
- this, SLOT(slotUpdateAbbrevList(const QString &, const QString &)) );
+ connect( m_abbrevListview, TQT_SIGNAL(updateAbbrevList(const TQString &, const TQString &)),
+ this, TQT_SLOT(slotUpdateAbbrevList(const TQString &, const TQString &)) );
}
- void CodeCompletion::slotUpdateAbbrevList(const QString &ds, const QString &as)
+ void CodeCompletion::slotUpdateAbbrevList(const TQString &ds, const TQString &as)
{
if ( ! ds.isEmpty() )
{
@@ -1409,10 +1409,10 @@ namespace KileDocument
}
}
- void CodeCompletion::deleteAbbreviationEntry( const QString &entry )
+ void CodeCompletion::deleteAbbreviationEntry( const TQString &entry )
{
KILE_DEBUG() << "=== CodeCompletion::deleteAbbreviationEntry (" << entry << ")" << endl;
- QValueList<KTextEditor::CompletionEntry>::Iterator it;
+ TQValueList<KTextEditor::CompletionEntry>::Iterator it;
for ( it=m_abbrevlist.begin(); it!=m_abbrevlist.end(); ++it )
{
if ( (*it).text == entry )
@@ -1423,10 +1423,10 @@ namespace KileDocument
}
}
- void CodeCompletion::addAbbreviationEntry( const QString &entry )
+ void CodeCompletion::addAbbreviationEntry( const TQString &entry )
{
KILE_DEBUG() << "=== CodeCompletion::addAbbreviationEntry (" << entry << ")" << endl;
- QValueList<KTextEditor::CompletionEntry>::Iterator it;
+ TQValueList<KTextEditor::CompletionEntry>::Iterator it;
for ( it=m_abbrevlist.begin(); it!=m_abbrevlist.end(); ++it )
{
if ( (*it).text > entry )
@@ -1435,7 +1435,7 @@ namespace KileDocument
KTextEditor::CompletionEntry e;
e.text = entry;
- e.type = QString::null;
+ e.type = TQString();
if ( it == m_abbrevlist.begin() )
m_abbrevlist.prepend(e);
diff --git a/src/kile/codecompletion.h b/src/kile/codecompletion.h
index d1da2e0..ad7eea4 100644
--- a/src/kile/codecompletion.h
+++ b/src/kile/codecompletion.h
@@ -17,7 +17,7 @@
#ifndef CODECOMPLETION_H
#define CODECOMPLETION_H
-#include <qobject.h>
+#include <tqobject.h>
#include <kate/view.h>
#include <kate/document.h>
@@ -28,14 +28,14 @@
#include "kileabbrevview.h"
//default bullet char (a cross)
-static const QChar s_bullet_char = QChar(0xd7);
-static const QString s_bullet = QString(&s_bullet_char, 1);
+static const TQChar s_bullet_char = TQChar(0xd7);
+static const TQString s_bullet = TQString(&s_bullet_char, 1);
/**
*@author Holger Danielsson
*/
-class QTimer;
+class TQTimer;
class KileInfo;
@@ -44,9 +44,10 @@ namespace KileDocument
//FIXME fix the way the Kate::View is passed, I'm not 100% confident m_view doesn't turn into a wild pointer
//FIXME refactor the complete class, it's pretty ugly, there are too many methods with similar names suggesting that the code could be more efficient
-class CodeCompletion : public QObject
+class CodeCompletion : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
CodeCompletion(KileInfo *ki);
@@ -80,7 +81,7 @@ public:
bool autoComplete();
CodeCompletion::Mode getMode();
CodeCompletion::Type getType();
- CodeCompletion::Type getType(const QString &text);
+ CodeCompletion::Type getType(const TQString &text);
KileInfo* info() const { return m_ki;}
@@ -92,49 +93,49 @@ public:
public slots:
//in these two methods we should set m_view
- void slotCharactersInserted(int, int, const QString&);
+ void slotCharactersInserted(int, int, const TQString&);
void editComplete(Kate::View *view, KileDocument::CodeCompletion::Mode mode);
void slotCompletionDone(KTextEditor::CompletionEntry);
void slotCompleteValueList();
void slotCompletionAborted();
- void slotFilterCompletion(KTextEditor::CompletionEntry* c,QString *s);
+ void slotFilterCompletion(KTextEditor::CompletionEntry* c,TQString *s);
// a abbreviation was modified ind the abbreviation view (add, edit or delete)
// so the abbreviation list was must also be updated
- void slotUpdateAbbrevList(const QString &ds, const QString &as);
+ void slotUpdateAbbrevList(const TQString &ds, const TQString &as);
private:
- void completeWord(const QString &text, CodeCompletion::Mode mode);
- QString filterCompletionText(const QString &text, const QString &type);
+ void completeWord(const TQString &text, CodeCompletion::Mode mode);
+ TQString filterCompletionText(const TQString &text, const TQString &type);
void CompletionDone(KTextEditor::CompletionEntry);
void CompletionAborted();
- void completeFromList(const QStringList *list,const QString &pattern=QString::null);
- void editCompleteList(KileDocument::CodeCompletion::Type type,const QString &pattern=QString::null);
- bool getCompleteWord(bool latexmode, QString &text, KileDocument::CodeCompletion::Type &type);
- bool getReferenceWord(QString &text);
- bool oddBackslashes(const QString& text, int index);
+ void completeFromList(const TQStringList *list,const TQString &pattern=TQString());
+ void editCompleteList(KileDocument::CodeCompletion::Type type,const TQString &pattern=TQString());
+ bool getCompleteWord(bool latexmode, TQString &text, KileDocument::CodeCompletion::Type &type);
+ bool getReferenceWord(TQString &text);
+ bool oddBackslashes(const TQString& text, int index);
- void appendNewCommands(QValueList<KTextEditor::CompletionEntry> & list);
- void getDocumentWords(const QString &text,QValueList<KTextEditor::CompletionEntry> &list);
+ void appendNewCommands(TQValueList<KTextEditor::CompletionEntry> & list);
+ void getDocumentWords(const TQString &text,TQValueList<KTextEditor::CompletionEntry> &list);
- bool completeAutoAbbreviation(const QString &text);
- QString getAbbreviationWord(uint row, uint col);
+ bool completeAutoAbbreviation(const TQString &text);
+ TQString getAbbreviationWord(uint row, uint col);
- CodeCompletion::Type insideReference(QString &startpattern);
+ CodeCompletion::Type insideReference(TQString &startpattern);
private:
// wordlists
- QValueList<KTextEditor::CompletionEntry> m_texlist;
- QValueList<KTextEditor::CompletionEntry> m_dictlist;
- QValueList<KTextEditor::CompletionEntry> m_abbrevlist;
- QValueList<KTextEditor::CompletionEntry> m_labellist;
+ TQValueList<KTextEditor::CompletionEntry> m_texlist;
+ TQValueList<KTextEditor::CompletionEntry> m_dictlist;
+ TQValueList<KTextEditor::CompletionEntry> m_abbrevlist;
+ TQValueList<KTextEditor::CompletionEntry> m_labellist;
KileInfo *m_ki;
- QTimer *m_completeTimer;
+ TQTimer *m_completeTimer;
// some flags
bool m_isenabled;
@@ -167,41 +168,41 @@ private:
CodeCompletion::Type m_keylistType;
// local abbreviation
- QString m_localAbbrevFile;
+ TQString m_localAbbrevFile;
KileAbbrevView *m_abbrevListview;
// internal parameter
Kate::View *m_view; // View
- QString m_text; // current pattern
+ TQString m_text; // current pattern
uint m_textlen; // length of current pattern
CodeCompletion::Mode m_mode; // completion mode
uint m_ycursor,m_xcursor,m_xstart; // current cursor position
uint m_yoffset,m_xoffset; // offset of the new cursor position
- QString buildLatexText(const QString &text, uint &ypos, uint &xpos);
- QString buildEnvironmentText(const QString &text, const QString &type, const QString &prefix, uint &ypos, uint &xpos);
- QString getWhiteSpace(const QString &s);
- QString buildAbbreviationText(const QString &text);
- QString buildLabelText(const QString &text);
+ TQString buildLatexText(const TQString &text, uint &ypos, uint &xpos);
+ TQString buildEnvironmentText(const TQString &text, const TQString &type, const TQString &prefix, uint &ypos, uint &xpos);
+ TQString getWhiteSpace(const TQString &s);
+ TQString buildAbbreviationText(const TQString &text);
+ TQString buildLabelText(const TQString &text);
- QString parseText(const QString &text, uint &ypos, uint &xpos, bool checkgroup);
- QString stripParameter(const QString &text);
+ TQString parseText(const TQString &text, uint &ypos, uint &xpos, bool checkgroup);
+ TQString stripParameter(const TQString &text);
- void setWordlist(const QStringList &files,const QString &dir, QValueList<KTextEditor::CompletionEntry> *entrylist);
- void readWordlist(QStringList &wordlist, const QString &filename, bool global);
- void addCommandsToTexlist(QStringList &wordlist);
+ void setWordlist(const TQStringList &files,const TQString &dir, TQValueList<KTextEditor::CompletionEntry> *entrylist);
+ void readWordlist(TQStringList &wordlist, const TQString &filename, bool global);
+ void addCommandsToTexlist(TQStringList &wordlist);
void setReferences();
- QString getCommandList(KileDocument::CmdAttribute attrtype);
+ TQString getCommandList(KileDocument::CmdAttribute attrtype);
- void setCompletionEntries(QValueList<KTextEditor::CompletionEntry> *list, const QStringList &wordlist);
- void setCompletionEntriesTexmode(QValueList<KTextEditor::CompletionEntry> *list, const QStringList &wordlist);
+ void setCompletionEntries(TQValueList<KTextEditor::CompletionEntry> *list, const TQStringList &wordlist);
+ void setCompletionEntriesTexmode(TQValueList<KTextEditor::CompletionEntry> *list, const TQStringList &wordlist);
- uint countEntries(const QString &pattern, QValueList<KTextEditor::CompletionEntry> *list, QString *entry, QString *type);
+ uint countEntries(const TQString &pattern, TQValueList<KTextEditor::CompletionEntry> *list, TQString *entry, TQString *type);
- void addAbbreviationEntry( const QString &entry );
- void deleteAbbreviationEntry( const QString &entry );
- QString findExpansion(const QString &abbrev);
+ void addAbbreviationEntry( const TQString &entry );
+ void deleteAbbreviationEntry( const TQString &entry );
+ TQString findExpansion(const TQString &abbrev);
void autoInsertDollar();
};
diff --git a/src/kile/configcheckerdlg.cpp b/src/kile/configcheckerdlg.cpp
index aea6723..feeea6b 100644
--- a/src/kile/configcheckerdlg.cpp
+++ b/src/kile/configcheckerdlg.cpp
@@ -15,10 +15,10 @@
#include "configcheckerdlg.h"
-#include <qfileinfo.h>
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qpainter.h>
+#include <tqfileinfo.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqpainter.h>
#include <klocale.h>
#include <kcursor.h>
@@ -34,19 +34,19 @@
namespace KileDialog
{
-ResultItem::ResultItem(KListBox *lb, const QString &tool, int status, const QValueList<ConfigTest> &tests) : QListBoxItem(lb)
+ResultItem::ResultItem(KListBox *lb, const TQString &tool, int status, const TQValueList<ConfigTest> &tests) : TQListBoxItem(lb)
{
- QString rt = "<hr><b><font color=\"%1\">%2</font></b> (%3)<br><ul>";
+ TQString rt = "<hr><b><font color=\"%1\">%2</font></b> (%3)<br><ul>";
for ( uint i = 0; i < tests.count(); ++i)
{
- QString itemcolor = "black";
+ TQString itemcolor = "black";
if ( tests[i].status() == ConfigTest::Failure ) itemcolor = "#FFA201";
else if ( tests[i].status() == ConfigTest::Critical ) itemcolor = "#AA0000";
- rt += QString("<li><b><font color=\"%1\">%2</font></b>: &nbsp;%3</li>").arg(itemcolor).arg(tests[i].name()).arg(tests[i].resultText());
+ rt += TQString("<li><b><font color=\"%1\">%2</font></b>: &nbsp;%3</li>").tqarg(itemcolor).tqarg(tests[i].name()).tqarg(tests[i].resultText());
}
rt += "</ul>";
- QString color = "#00AA00", statustr = i18n("Passed");
+ TQString color = "#00AA00", statustr = i18n("Passed");
if ( status == ConfigTest::Failure )
{
color = "#FFA201";
@@ -58,25 +58,25 @@ ResultItem::ResultItem(KListBox *lb, const QString &tool, int status, const QVal
statustr = i18n("Critical failure, Kile will not function properly");
}
- m_richText = new QSimpleRichText(rt.arg(color).arg(tool).arg(statustr), listBox()->font());
+ m_richText = new TQSimpleRichText(rt.tqarg(color).tqarg(tool).tqarg(statustr), listBox()->font());
m_richText->setWidth(listBox()->width());
//this is for sorting only
- setText(QString::number(status) + ':' + tool);
+ setText(TQString::number(status) + ':' + tool);
}
-void ResultItem::paint(QPainter *p)
+void ResultItem::paint(TQPainter *p)
{
- m_richText->draw(p, 0, 0, QRect(), listBox()->colorGroup());
+ m_richText->draw(p, 0, 0, TQRect(), listBox()->tqcolorGroup());
}
-ConfigChecker::ConfigChecker(QWidget* parent) :
- KDialogBase( Plain, i18n("System Check"), Ok|Cancel|User1, Ok, parent, 0, true, true, KGuiItem("&Save Results...")),
+ConfigChecker::ConfigChecker(TQWidget* tqparent) :
+ KDialogBase( Plain, i18n("System Check"), Ok|Cancel|User1, Ok, tqparent, 0, true, true, KGuiItem("&Save Results...")),
m_tester(0L)
{
- QGridLayout *layout = new QGridLayout(plainPage(), 1, 1);
+ TQGridLayout *tqlayout = new TQGridLayout(plainPage(), 1, 1);
m_widget = new ConfigCheckerWidget(plainPage());
- layout->addWidget(m_widget, 1, 1);
+ tqlayout->addWidget(m_widget, 1, 1);
enableButton(Ok, false);
enableButton(User1, false);
@@ -93,7 +93,7 @@ KProgress* ConfigChecker::progressBar()
return m_widget->progressBar();
}
-QLabel* ConfigChecker::label()
+TQLabel* ConfigChecker::label()
{
return m_widget->label();
}
@@ -105,12 +105,12 @@ KListBox* ConfigChecker::listBox()
void ConfigChecker::run()
{
- m_tester = new Tester(this, "configtester");
+ m_tester = new Tester(TQT_TQOBJECT(this), "configtester");
- connect(m_tester, SIGNAL(started()), this, SLOT(started()));
- connect(m_tester, SIGNAL(percentageDone(int)), this, SLOT(setPercentageDone(int)));
- connect(m_tester, SIGNAL(finished(bool)), this, SLOT(finished(bool)));
- connect(this, SIGNAL(user1Clicked()), this, SLOT(saveResults()));
+ connect(m_tester, TQT_SIGNAL(started()), this, TQT_SLOT(started()));
+ connect(m_tester, TQT_SIGNAL(percentageDone(int)), this, TQT_SLOT(setPercentageDone(int)));
+ connect(m_tester, TQT_SIGNAL(finished(bool)), this, TQT_SLOT(finished(bool)));
+ connect(this, TQT_SIGNAL(user1Clicked()), this, TQT_SLOT(saveResults()));
m_tester->runTests();
}
@@ -143,8 +143,8 @@ void ConfigChecker::finished(bool ok)
{
label()->setText(i18n("Finished testing your system..."));
- QStringList tools = m_tester->testedTools();
- QStringList critical, failure;
+ TQStringList tools = m_tester->testedTools();
+ TQStringList critical, failure;
for ( uint i = 0; i < tools.count(); ++i )
{
int status = m_tester->statusForTool(tools[i]);
@@ -155,11 +155,11 @@ void ConfigChecker::finished(bool ok)
listBox()->sort();
- QString cap = i18n("Test Results");
+ TQString cap = i18n("Test Results");
if ( critical.count() > 0 )
- KMessageBox::error(this, i18n("<qt>The following tools did not pass all <b>critical</b> tests:<br>%1<br>Your system is not ready to use. Please consult the results to find out what to fix.</qt>").arg(critical.join(", ")), cap);
+ KMessageBox::error(this, i18n("<qt>The following tools did not pass all <b>critical</b> tests:<br>%1<br>Your system is not ready to use. Please consult the results to find out what to fix.</qt>").tqarg(critical.join(", ")), cap);
else if ( failure.count() > 0 )
- KMessageBox::information(this, i18n("The following tools did not pass all tests:\n %1\nYou will still be able to use Kile; however, not all features are guaranteed to work.").arg(failure.join(", ")), cap);
+ KMessageBox::information(this, i18n("The following tools did not pass all tests:\n %1\nYou will still be able to use Kile; however, not all features are guaranteed to work.").tqarg(failure.join(", ")), cap);
else
KMessageBox::information(this, i18n("No problems detected, your system is ready to use."), cap);
}
diff --git a/src/kile/configcheckerdlg.h b/src/kile/configcheckerdlg.h
index 74e8bf0..9d56298 100644
--- a/src/kile/configcheckerdlg.h
+++ b/src/kile/configcheckerdlg.h
@@ -16,14 +16,14 @@
#ifndef KILEDIALOG_CONFIGCHECKER_H
#define KILEDIALOG_CONFIGCHECKER_H
-#include <qsimplerichtext.h>
+#include <tqsimplerichtext.h>
#include <kdialogbase.h>
#include "configtester.h"
-class QLabel;
-class QPainter;
+class TQLabel;
+class TQPainter;
class KProgress;
class KListBox;
@@ -32,26 +32,27 @@ class ConfigCheckerWidget;
namespace KileDialog
{
- class ResultItem : public QListBoxItem
+ class ResultItem : public TQListBoxItem
{
public:
- ResultItem(KListBox *lb, const QString &tool, int status, const QValueList<ConfigTest> &tests);
- int width(const QListBox *) const { return m_richText->widthUsed(); }
- int height(const QListBox *) const { return m_richText->height(); }
+ ResultItem(KListBox *lb, const TQString &tool, int status, const TQValueList<ConfigTest> &tests);
+ int width(const TQListBox *) const { return m_richText->widthUsed(); }
+ int height(const TQListBox *) const { return m_richText->height(); }
protected:
- void paint(QPainter *);
+ void paint(TQPainter *);
private:
- QSimpleRichText *m_richText;
+ TQSimpleRichText *m_richText;
};
class ConfigChecker : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- ConfigChecker(QWidget* parent = 0);
+ ConfigChecker(TQWidget* tqparent = 0);
~ConfigChecker();
public slots:
@@ -64,7 +65,7 @@ namespace KileDialog
private:
KProgress* progressBar();
- QLabel* label();
+ TQLabel* label();
KListBox* listBox();
private:
diff --git a/src/kile/configcheckerwidget.ui b/src/kile/configcheckerwidget.ui
index 921c056..5dc3114 100644
--- a/src/kile/configcheckerwidget.ui
+++ b/src/kile/configcheckerwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>ConfigCheckerWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>ConfigCheckerWidget</cstring>
</property>
@@ -20,7 +20,7 @@
<verstretch>1</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>580</width>
<height>480</height>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>m_lbChecking</cstring>
</property>
@@ -54,7 +54,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>m_grpResults</cstring>
</property>
@@ -85,7 +85,7 @@
<verstretch>1</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>480</width>
<height>0</height>
@@ -101,10 +101,10 @@
</includes>
<functions>
<function specifier="non virtual" returnType="KProgress *">progressBar()</function>
- <function specifier="non virtual" returnType="QLabel *">label()</function>
+ <function specifier="non virtual" returnType="TQLabel *">label()</function>
<function specifier="non virtual" returnType="KListBox *">listBox()</function>
</functions>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>kprogress.h</includehint>
<includehint>klistbox.h</includehint>
diff --git a/src/kile/configcheckerwidget.ui.h b/src/kile/configcheckerwidget.ui.h
index e526b11..b4bd59f 100644
--- a/src/kile/configcheckerwidget.ui.h
+++ b/src/kile/configcheckerwidget.ui.h
@@ -2,7 +2,7 @@
** ui.h extension file, included from the uic-generated form implementation.
**
** If you wish to add, delete or rename functions or slots use
-** Qt Designer which will update this file, preserving your code. Create an
+** TQt Designer which will update this file, preserving your code. Create an
** init() function in place of a constructor, and a destroy() function in
** place of a destructor.
*****************************************************************************/
@@ -16,7 +16,7 @@ KProgress* ConfigCheckerWidget::progressBar()
}
-QLabel* ConfigCheckerWidget::label()
+TQLabel* ConfigCheckerWidget::label()
{
return m_lbChecking;
}
diff --git a/src/kile/configcodecompletion.cpp b/src/kile/configcodecompletion.cpp
index 8cd952e..ad400f2 100644
--- a/src/kile/configcodecompletion.cpp
+++ b/src/kile/configcodecompletion.cpp
@@ -22,37 +22,37 @@
#include <kmessagebox.h>
#include <klocale.h>
-#include <qlayout.h>
-#include <qtabwidget.h>
-#include <qgroupbox.h>
-#include <qvgroupbox.h>
-#include <qbuttongroup.h>
-#include <qlabel.h>
-#include <qspinbox.h>
-#include <qframe.h>
-#include <qwhatsthis.h>
-#include <qstringlist.h>
-#include <qfileinfo.h>
-#include <qdir.h>
+#include <tqlayout.h>
+#include <tqtabwidget.h>
+#include <tqgroupbox.h>
+#include <tqvgroupbox.h>
+#include <tqbuttongroup.h>
+#include <tqlabel.h>
+#include <tqspinbox.h>
+#include <tqframe.h>
+#include <tqwhatsthis.h>
+#include <tqstringlist.h>
+#include <tqfileinfo.h>
+#include <tqdir.h>
#include "kilelistselector.h"
#include "kileconfig.h"
#include "kilelogwidget.h"
#include "kiletool_enums.h"
-ConfigCodeCompletion::ConfigCodeCompletion(KConfig *config, KileWidget::LogMsg *logwidget, QWidget *parent, const char *name )
- : QWidget(parent,name), m_config(config), m_logwidget(logwidget)
+ConfigCodeCompletion::ConfigCodeCompletion(KConfig *config, KileWidget::LogMsg *logwidget, TQWidget *tqparent, const char *name )
+ : TQWidget(tqparent,name), m_config(config), m_logwidget(logwidget)
{
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(this, 5,KDialog::spacingHint() );
+ TQVBoxLayout *vbox = new TQVBoxLayout(this, 5,KDialog::spacingHint() );
// Groupbox with TabDialog and two button
- QGroupBox *gb_tab= new QGroupBox(i18n("Complete Modes"), this );
- QGridLayout *grid_tab = new QGridLayout( gb_tab, 2,1, 12,8, "" );
+ TQGroupBox *gb_tab= new TQGroupBox(i18n("Complete Modes"), this );
+ TQGridLayout *grid_tab = new TQGridLayout( gb_tab, 2,1, 12,8, "" );
grid_tab->addRowSpacing( 0, 12 );
// create TabWidget
- tab = new QTabWidget(gb_tab);
+ tab = new TQTabWidget(gb_tab);
// add three pages: Tex/Latex, Dictionary, Abbreviation
addPage(tab, TexPage, i18n("TeX/LaTeX"), "tex");
@@ -64,32 +64,32 @@ ConfigCodeCompletion::ConfigCodeCompletion(KConfig *config, KileWidget::LogMsg *
remove = new KPushButton(i18n("Remove"),gb_tab);
grid_tab->addMultiCellWidget(tab,1,1,0,1);
- grid_tab->addWidget(add,2,0,Qt::AlignRight);
- grid_tab->addWidget(remove,2,1,Qt::AlignLeft);
+ grid_tab->addWidget(add,2,0,TQt::AlignRight);
+ grid_tab->addWidget(remove,2,1,TQt::AlignLeft);
// below: OptionBox
- QButtonGroup *bg_options = new QButtonGroup( this, "bgOptions" );
+ TQButtonGroup *bg_options = new TQButtonGroup( this, "bgOptions" );
bg_options->setColumnLayout(0, Qt::Vertical );
- bg_options->layout()->setSpacing( 6 );
- bg_options->layout()->setMargin( 11 );
- QGridLayout *bg_optionsLayout = new QGridLayout( bg_options->layout() );
- bg_optionsLayout->setAlignment( Qt::AlignTop );
-
- cb_setcursor = new QCheckBox(i18n("Place cursor"),bg_options);
- cb_setbullets = new QCheckBox(i18n("Insert bullets"),bg_options);
- cb_closeenv = new QCheckBox(i18n("Close environments"),bg_options);
- cb_usecomplete = new QCheckBox(i18n("Use complete"),bg_options);
- cb_autocomplete = new QCheckBox(i18n("Auto completion (LaTeX)"),bg_options);
- lb_latexthreshold = new QLabel(i18n("Threshold:"),bg_options);
- sp_latexthreshold = new QSpinBox(1,9,1,bg_options);
- QLabel *lb_latexletters = new QLabel(i18n("letters"),bg_options);
- cb_autocompletetext = new QCheckBox(i18n("Auto completion (text)"),bg_options);
- lb_textthreshold = new QLabel(i18n("Threshold:"),bg_options);
- sp_textthreshold = new QSpinBox(1,9,1,bg_options);
- QLabel *lb_textletters = new QLabel(i18n("letters"),bg_options);
- cb_showabbrevview = new QCheckBox(i18n("Show abbreviations"),bg_options);
- cb_autocompleteabbrev = new QCheckBox(i18n("Auto completion (abbrev.)"),bg_options);
- cb_citeoutofbraces = new QCheckBox(i18n("Move out of braces (citation keylists)"),bg_options);
+ bg_options->tqlayout()->setSpacing( 6 );
+ bg_options->tqlayout()->setMargin( 11 );
+ TQGridLayout *bg_optionsLayout = new TQGridLayout( bg_options->tqlayout() );
+ bg_optionsLayout->tqsetAlignment( TQt::AlignTop );
+
+ cb_setcursor = new TQCheckBox(i18n("Place cursor"),bg_options);
+ cb_setbullets = new TQCheckBox(i18n("Insert bullets"),bg_options);
+ cb_closeenv = new TQCheckBox(i18n("Close environments"),bg_options);
+ cb_usecomplete = new TQCheckBox(i18n("Use complete"),bg_options);
+ cb_autocomplete = new TQCheckBox(i18n("Auto completion (LaTeX)"),bg_options);
+ lb_latexthreshold = new TQLabel(i18n("Threshold:"),bg_options);
+ sp_latexthreshold = new TQSpinBox(1,9,1,bg_options);
+ TQLabel *lb_latexletters = new TQLabel(i18n("letters"),bg_options);
+ cb_autocompletetext = new TQCheckBox(i18n("Auto completion (text)"),bg_options);
+ lb_textthreshold = new TQLabel(i18n("Threshold:"),bg_options);
+ sp_textthreshold = new TQSpinBox(1,9,1,bg_options);
+ TQLabel *lb_textletters = new TQLabel(i18n("letters"),bg_options);
+ cb_showabbrevview = new TQCheckBox(i18n("Show abbreviations"),bg_options);
+ cb_autocompleteabbrev = new TQCheckBox(i18n("Auto completion (abbrev.)"),bg_options);
+ cb_citeoutofbraces = new TQCheckBox(i18n("Move out of braces (citation keylists)"),bg_options);
bg_optionsLayout->addWidget(cb_setcursor,0,0);
bg_optionsLayout->addWidget(cb_setbullets,1,0);
@@ -107,37 +107,37 @@ ConfigCodeCompletion::ConfigCodeCompletion(KConfig *config, KileWidget::LogMsg *
bg_optionsLayout->addWidget(cb_autocompleteabbrev,3,2);
bg_optionsLayout->addMultiCellWidget(cb_citeoutofbraces,4,4,0,7);
- // tune layout
+ // tune tqlayout
bg_optionsLayout->setColSpacing(1,20);
bg_optionsLayout->setColSpacing(3,12);
bg_optionsLayout->setColSpacing(5,8);
bg_optionsLayout->setColStretch(7,1);
- QWhatsThis::add(cb_setcursor,i18n("Try to place the cursor."));
- QWhatsThis::add(cb_setbullets,i18n("Insert bullets, where the user must input data."));
- QWhatsThis::add(cb_closeenv,i18n("Also close an environment, when an opening command is inserted."));
- QWhatsThis::add(cb_usecomplete,i18n("Enable components of word completion."));
- QWhatsThis::add(cb_autocomplete,i18n("Directional or popup-based completion with TeX/LaTeX commands, which are given in all selected word completion lists. This mode can only be selected, if no other plugin for autocompletion is active."));
- QWhatsThis::add(cb_autocompletetext,i18n("Directional or popup-based completion from words in the current document. This mode can only be selected, if no other plugin for autocompletion is active."));
- QWhatsThis::add(sp_latexthreshold,i18n("Automatically show a completion list of TeX/LaTeX commands, when the word has this length."));
- QWhatsThis::add(sp_textthreshold,i18n("Automatically show a completion list, when the word has this length."));
- QWhatsThis::add(cb_citeoutofbraces,i18n("Move cursor out of braces after selecting from a citation keylist."));
+ TQWhatsThis::add(cb_setcursor,i18n("Try to place the cursor."));
+ TQWhatsThis::add(cb_setbullets,i18n("Insert bullets, where the user must input data."));
+ TQWhatsThis::add(cb_closeenv,i18n("Also close an environment, when an opening command is inserted."));
+ TQWhatsThis::add(cb_usecomplete,i18n("Enable components of word completion."));
+ TQWhatsThis::add(cb_autocomplete,i18n("Directional or popup-based completion with TeX/LaTeX commands, which are given in all selected word completion lists. This mode can only be selected, if no other plugin for autocompletion is active."));
+ TQWhatsThis::add(cb_autocompletetext,i18n("Directional or popup-based completion from words in the current document. This mode can only be selected, if no other plugin for autocompletion is active."));
+ TQWhatsThis::add(sp_latexthreshold,i18n("Automatically show a completion list of TeX/LaTeX commands, when the word has this length."));
+ TQWhatsThis::add(sp_textthreshold,i18n("Automatically show a completion list, when the word has this length."));
+ TQWhatsThis::add(cb_citeoutofbraces,i18n("Move cursor out of braces after selecting from a citation keylist."));
// bottom: warning
- QLabel *lb_automodes = new QLabel(i18n("Warning: all autocompletion modes will be disabled, if you enable KTextEditor plugin word completion."),this);
+ TQLabel *lb_automodes = new TQLabel(i18n("Warning: all autocompletion modes will be disabled, if you enable KTextEditor plugin word completion."),this);
- // add OptionBox and TabDialog into the layout
+ // add OptionBox and TabDialog into the tqlayout
vbox->addWidget(gb_tab);
vbox->addWidget(bg_options);
vbox->addWidget(lb_automodes);
vbox->addStretch();
- connect(tab,SIGNAL(currentChanged(QWidget*)),this,SLOT(showPage(QWidget*)));
- connect(add,SIGNAL(clicked()),this,SLOT(addClicked()));
- connect(remove,SIGNAL(clicked()),this,SLOT(removeClicked()));
+ connect(tab,TQT_SIGNAL(currentChanged(TQWidget*)),this,TQT_SLOT(showPage(TQWidget*)));
+ connect(add,TQT_SIGNAL(clicked()),this,TQT_SLOT(addClicked()));
+ connect(remove,TQT_SIGNAL(clicked()),this,TQT_SLOT(removeClicked()));
// justify height
- QCheckListItem *item = new QCheckListItem(m_listview[AbbreviationPage], "Test", QCheckListItem::CheckBox);
+ TQCheckListItem *item = new TQCheckListItem(m_listview[AbbreviationPage], "Test", TQCheckListItem::CheckBox);
int h = 6*(item->height()+1) + 1;
for ( uint i=TexPage; i<NumPages; ++i )
m_listview[i]->setFixedHeight(h);
@@ -151,16 +151,16 @@ ConfigCodeCompletion::~ConfigCodeCompletion()
{
}
-void ConfigCodeCompletion::addPage(QTabWidget *tab, CompletionPage page, const QString &title, const QString &dirname)
+void ConfigCodeCompletion::addPage(TQTabWidget *tab, CompletionPage page, const TQString &title, const TQString &dirname)
{
- m_page[page] = new QWidget(tab);
+ m_page[page] = new TQWidget(tab);
m_listview[page] = new KListView( m_page[page] );
m_listview[page]->addColumn(i18n("Complete Files"));
m_listview[page]->addColumn(i18n("Local File"));
m_listview[page]->setFullWidth(true);
- QGridLayout *grid = new QGridLayout(m_page[page], 1,1, 10,10);
+ TQGridLayout *grid = new TQGridLayout(m_page[page], 1,1, 10,10);
grid->addWidget(m_listview[page],0,0);
// add Tab
@@ -169,7 +169,7 @@ void ConfigCodeCompletion::addPage(QTabWidget *tab, CompletionPage page, const Q
// remember directory name
m_dirname << dirname;
- connect(m_listview[page], SIGNAL(clicked( QListViewItem *)), this, SLOT(slotListviewClicked(QListViewItem *)));
+ connect(m_listview[page], TQT_SIGNAL(clicked( TQListViewItem *)), this, TQT_SLOT(slotListviewClicked(TQListViewItem *)));
}
//////////////////// read/write configuration ////////////////////
@@ -240,7 +240,7 @@ void ConfigCodeCompletion::writeConfig(void)
{
if ( autoModeLatex || autoModeText || autoModeAbbrev)
{
- QString msg = i18n("You enabled the KTextEditor-Plugin for word completion, "
+ TQString msg = i18n("You enabled the KTextEditor-Plugin for word completion, "
"but this conflicts with the auto completion modes of Kile. "
"As only one of these completion modes can be used, the "
"autocompletion modes of Kile will be disabled.");
@@ -277,26 +277,26 @@ bool ConfigCodeCompletion::kateCompletionPlugin()
void ConfigCodeCompletion::setListviewEntries(CompletionPage page)
{
- QString listname = m_dirname[page];
- QString localdir = m_localCwlDir + listname + '/';
- QString globaldir = m_globalCwlDir + listname + '/';
+ TQString listname = m_dirname[page];
+ TQString localdir = m_localCwlDir + listname + '/';
+ TQString globaldir = m_globalCwlDir + listname + '/';
// Daten aus der Konfigurationsliste in das ListView-Widget eintragen
m_listview[page]->setUpdatesEnabled(false);
m_listview[page]->clear();
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it=m_wordlist[page].begin(); it!=m_wordlist[page].end(); ++it )
{
- QString basename = (*it).right( (*it).length()-2 );
- bool localExists = QFileInfo(localdir+basename+".cwl").exists();
+ TQString basename = (*it).right( (*it).length()-2 );
+ bool localExists = TQFileInfo(localdir+basename+".cwl").exists();
- QCheckListItem *item = new QCheckListItem(m_listview[page],basename,QCheckListItem::CheckBox);
+ TQCheckListItem *item = new TQCheckListItem(m_listview[page],basename,TQCheckListItem::CheckBox);
if ( localExists )
{
item->setOn( (*it).at(0) == '1' ? true : false );
item->setText(1,"+");
}
- else if ( QFileInfo(globaldir+basename+".cwl").exists() )
+ else if ( TQFileInfo(globaldir+basename+".cwl").exists() )
{
item->setOn( (*it).at(0) == '1' ? true : false );
}
@@ -335,11 +335,11 @@ bool ConfigCodeCompletion::getListviewEntries(CompletionPage page)
}
// now check all entries if they have changed
- QStringList newfiles;
+ TQStringList newfiles;
int index = 0;
- QCheckListItem *item = (QCheckListItem *)m_listview[page]->firstChild();
+ TQCheckListItem *item = (TQCheckListItem *)m_listview[page]->firstChild();
while ( item ) {
- QString s = ( item->isOn() ) ? "1-" : "0-";
+ TQString s = ( item->isOn() ) ? "1-" : "0-";
s += item->text(0);
newfiles.append(s);
@@ -348,7 +348,7 @@ bool ConfigCodeCompletion::getListviewEntries(CompletionPage page)
changed = true;
// go on
- item = (QCheckListItem *)item->nextSibling();
+ item = (TQCheckListItem *)item->nextSibling();
++index;
}
@@ -359,21 +359,21 @@ bool ConfigCodeCompletion::getListviewEntries(CompletionPage page)
return changed;
}
-bool ConfigCodeCompletion::isListviewEntry(KListView *listview, const QString &filename)
+bool ConfigCodeCompletion::isListviewEntry(KListView *listview, const TQString &filename)
{
- QCheckListItem *item = (QCheckListItem *)listview->firstChild();
+ TQCheckListItem *item = (TQCheckListItem *)listview->firstChild();
while ( item )
{
if ( item->text() == filename )
return true;
- item = (QCheckListItem *)item->nextSibling();
+ item = (TQCheckListItem *)item->nextSibling();
}
return false;
}
//////////////////// tabpages parameter ////////////////////
-KListView *ConfigCodeCompletion::getListview(QWidget *page)
+KListView *ConfigCodeCompletion::getListview(TQWidget *page)
{
for ( uint i=TexPage; i<NumPages; ++i )
{
@@ -383,19 +383,19 @@ KListView *ConfigCodeCompletion::getListview(QWidget *page)
return 0;
}
-QString ConfigCodeCompletion::getListname(QWidget *page)
+TQString ConfigCodeCompletion::getListname(TQWidget *page)
{
for ( uint i=TexPage; i<NumPages; ++i )
{
if ( page == m_page[i] )
return m_dirname[i];
}
- return QString::null;
+ return TQString();
}
//////////////////// shwo tabpages ////////////////////
-void ConfigCodeCompletion::showPage(QWidget *page)
+void ConfigCodeCompletion::showPage(TQWidget *page)
{
KListView *listview = getListview(page);
if ( listview )
@@ -409,10 +409,10 @@ void ConfigCodeCompletion::showPage(QWidget *page)
void ConfigCodeCompletion::getCwlDirs()
{
m_localCwlDir = locateLocal("appdata","complete/");
- m_globalCwlDir = QString::null;
+ m_globalCwlDir = TQString();
- QStringList dirs = KGlobal::dirs()->findDirs("appdata","complete/");
- for ( QStringList::ConstIterator it=dirs.begin(); it!=dirs.end(); ++it )
+ TQStringList dirs = KGlobal::dirs()->findDirs("appdata","complete/");
+ for ( TQStringList::ConstIterator it=dirs.begin(); it!=dirs.end(); ++it )
{
if ( (*it) != m_localCwlDir )
{
@@ -427,13 +427,13 @@ void ConfigCodeCompletion::getCwlDirs()
// with filename as key and filepath as value. Additionally all
// filenames are added to a stringlist.
-void ConfigCodeCompletion::getCwlFiles(QMap<QString,QString> &map, QStringList &list, const QString &dir)
+void ConfigCodeCompletion::getCwlFiles(TQMap<TQString,TQString> &map, TQStringList &list, const TQString &dir)
{
- QStringList files = QDir(dir,"*.cwl").entryList();
- for ( QStringList::ConstIterator it=files.begin(); it!=files.end(); ++it )
+ TQStringList files = TQDir(dir,"*.cwl").entryList();
+ for ( TQStringList::ConstIterator it=files.begin(); it!=files.end(); ++it )
{
- QString filename = QFileInfo(*it).fileName();
- if ( ! map.contains(filename) )
+ TQString filename = TQFileInfo(*it).fileName();
+ if ( ! map.tqcontains(filename) )
{
map[filename] = dir + '/' + (*it);
list << filename;
@@ -444,12 +444,12 @@ void ConfigCodeCompletion::getCwlFiles(QMap<QString,QString> &map, QStringList &
void ConfigCodeCompletion::addClicked()
{
// determine current subdirectory for current tab page
- QString listname = getListname(tab->currentPage());
+ TQString listname = getListname(tab->currentPage());
// get a sorted list of all cwl files from both directories
- QMap<QString,QString> filemap;
- QStringList filelist;
+ TQMap<TQString,TQString> filemap;
+ TQStringList filelist;
getCwlFiles(filemap,filelist,m_localCwlDir+listname);
getCwlFiles(filemap,filelist,m_globalCwlDir+listname);
filelist.sort();
@@ -461,25 +461,25 @@ void ConfigCodeCompletion::addClicked()
if ( dlg->currentItem() >= 0 )
{
KListView *listview = getListview(tab->currentPage()); // get current page
- QStringList filenames = dlg->selected(); // get selected files
- for ( QStringList::ConstIterator it=filenames.begin(); it!=filenames.end(); ++it )
+ TQStringList filenames = dlg->selected(); // get selected files
+ for ( TQStringList::ConstIterator it=filenames.begin(); it!=filenames.end(); ++it )
{
- QString filename = *it;
+ TQString filename = *it;
// could we accept the wordlist?
- QFileInfo fi( filemap[filename] );
+ TQFileInfo fi( filemap[filename] );
if ( !filename.isEmpty() && fi.exists() && fi.isReadable() )
{
- QString basename = filename.left(filename.length()-4);
+ TQString basename = filename.left(filename.length()-4);
// check if this entry already exists
if ( isListviewEntry(listview,basename) )
{
- m_logwidget->printMsg(KileTool::Info,i18n("Wordlist '%1' is already used.").arg(basename),i18n("Complete"));
+ m_logwidget->printMsg(KileTool::Info,i18n("Wordlist '%1' is already used.").tqarg(basename),i18n("Complete"));
continue;
}
// add new entry
- QCheckListItem *item = new QCheckListItem(listview,basename,QCheckListItem::CheckBox);
+ TQCheckListItem *item = new TQCheckListItem(listview,basename,TQCheckListItem::CheckBox);
item->setOn(true);
item->setSelected(true);
if ( filemap[filename].left(m_localCwlDir.length()) == m_localCwlDir )
@@ -499,9 +499,9 @@ void ConfigCodeCompletion::addClicked()
void ConfigCodeCompletion::removeClicked()
{
- QWidget *page = tab->currentPage();
+ TQWidget *page = tab->currentPage();
KListView *list = getListview(page); // determine page
- QCheckListItem *item = (QCheckListItem *)list->selectedItem(); // determine entry
+ TQCheckListItem *item = (TQCheckListItem *)list->selectedItem(); // determine entry
if ( item )
{
@@ -512,7 +512,7 @@ void ConfigCodeCompletion::removeClicked()
}
}
-void ConfigCodeCompletion::slotListviewClicked(QListViewItem *)
+void ConfigCodeCompletion::slotListviewClicked(TQListViewItem *)
{
KListView *listview = getListview(tab->currentPage()); // get current page
remove->setEnabled( listview->selectedItems().count() > 0 );
diff --git a/src/kile/configcodecompletion.h b/src/kile/configcodecompletion.h
index 2c24feb..1f23898 100644
--- a/src/kile/configcodecompletion.h
+++ b/src/kile/configcodecompletion.h
@@ -17,12 +17,12 @@
#ifndef CONFIGCODECOMPLETION_H
#define CONFIGCODECOMPLETION_H
-#include <qwidget.h>
-#include <qtabwidget.h>
-#include <qcheckbox.h>
-#include <qlabel.h>
-#include <qspinbox.h>
-#include <qstring.h>
+#include <tqwidget.h>
+#include <tqtabwidget.h>
+#include <tqcheckbox.h>
+#include <tqlabel.h>
+#include <tqspinbox.h>
+#include <tqstring.h>
#include <kdeversion.h>
#include <klistview.h>
@@ -35,11 +35,12 @@
namespace KileWidget { class LogMsg; }
-class ConfigCodeCompletion : public QWidget
+class ConfigCodeCompletion : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- ConfigCodeCompletion(KConfig *config, KileWidget::LogMsg *logwidget, QWidget *parent=0, const char *name=0);
+ ConfigCodeCompletion(KConfig *config, KileWidget::LogMsg *logwidget, TQWidget *tqparent=0, const char *name=0);
~ConfigCodeCompletion();
void readConfig(void);
@@ -52,48 +53,48 @@ private:
KileWidget::LogMsg *m_logwidget;
// tabs, views, pages, wordlists
- QTabWidget *tab;
+ TQTabWidget *tab;
KListView *m_listview[NumPages];
- QWidget *m_page[NumPages];
- QStringList m_wordlist[NumPages];
- QStringList m_dirname;
+ TQWidget *m_page[NumPages];
+ TQStringList m_wordlist[NumPages];
+ TQStringList m_dirname;
// button
KPushButton *add,*remove;
// Checkboxes/Spinboxes
- QCheckBox *cb_usecomplete, *cb_autocomplete;
- QCheckBox *cb_setcursor, *cb_setbullets;
- QCheckBox *cb_closeenv;
- QSpinBox *sp_latexthreshold;
- QLabel *lb_latexthreshold;
- QCheckBox *cb_autocompletetext;
- QSpinBox *sp_textthreshold;
- QLabel *lb_textthreshold;
- QCheckBox *cb_autocompleteabbrev;
- QCheckBox *cb_showabbrevview;
- QCheckBox *cb_citeoutofbraces;
+ TQCheckBox *cb_usecomplete, *cb_autocomplete;
+ TQCheckBox *cb_setcursor, *cb_setbullets;
+ TQCheckBox *cb_closeenv;
+ TQSpinBox *sp_latexthreshold;
+ TQLabel *lb_latexthreshold;
+ TQCheckBox *cb_autocompletetext;
+ TQSpinBox *sp_textthreshold;
+ TQLabel *lb_textthreshold;
+ TQCheckBox *cb_autocompleteabbrev;
+ TQCheckBox *cb_showabbrevview;
+ TQCheckBox *cb_citeoutofbraces;
bool kateCompletionPlugin();
- KListView *getListview(QWidget *page);
- QString getListname(QWidget *page);
- void addPage(QTabWidget *tab, CompletionPage page, const QString &title, const QString &dirname);
+ KListView *getListview(TQWidget *page);
+ TQString getListname(TQWidget *page);
+ void addPage(TQTabWidget *tab, CompletionPage page, const TQString &title, const TQString &dirname);
void setListviewEntries(CompletionPage page);
bool getListviewEntries(CompletionPage page);
- bool isListviewEntry(KListView *listview, const QString &filename);
+ bool isListviewEntry(KListView *listview, const TQString &filename);
void updateColumnWidth(KListView *listview);
- QString m_localCwlDir, m_globalCwlDir;
- void getCwlFiles(QMap<QString,QString> &map, QStringList &list, const QString &dir);
+ TQString m_localCwlDir, m_globalCwlDir;
+ void getCwlFiles(TQMap<TQString,TQString> &map, TQStringList &list, const TQString &dir);
void getCwlDirs();
private slots:
- void showPage(QWidget *page);
+ void showPage(TQWidget *page);
void addClicked();
void removeClicked();
- void slotListviewClicked(QListViewItem *);
+ void slotListviewClicked(TQListViewItem *);
};
#endif
diff --git a/src/kile/configstructure.cpp b/src/kile/configstructure.cpp
index 15bd3d7..31e23c7 100644
--- a/src/kile/configstructure.cpp
+++ b/src/kile/configstructure.cpp
@@ -22,66 +22,66 @@
#include <klocale.h>
#include <kiconloader.h>
-#include <qlayout.h>
-#include <qtabwidget.h>
-#include <qgroupbox.h>
-#include <qvgroupbox.h>
-#include <qframe.h>
-#include <qstringlist.h>
-#include <qpushbutton.h>
-#include <qcombobox.h>
-#include <qspinbox.h>
-#include <qpainter.h>
-#include <qrect.h>
-#include <qlabel.h>
+#include <tqlayout.h>
+#include <tqtabwidget.h>
+#include <tqgroupbox.h>
+#include <tqvgroupbox.h>
+#include <tqframe.h>
+#include <tqstringlist.h>
+#include <tqpushbutton.h>
+#include <tqcombobox.h>
+#include <tqspinbox.h>
+#include <tqpainter.h>
+#include <tqrect.h>
+#include <tqlabel.h>
namespace KileStructure
{
//////////////////// KileCenteredTableItem ////////////////////
-void KileCenteredTableItem::paint(QPainter* p,const QColorGroup& cg,const QRect& cr,bool selected)
+void KileCenteredTableItem::paint(TQPainter* p,const TQColorGroup& cg,const TQRect& cr,bool selected)
{
int w = cr.width();
int h = cr.height();
if (selected && colSpan()==1 ) {
- p->fillRect( 0,0,w,h, cg.brush( QColorGroup::Highlight ) );
+ p->fillRect( 0,0,w,h, cg.brush( TQColorGroup::Highlight ) );
p->setPen( cg.highlightedText() );
} else {
- p->fillRect( 0,0,w,h, Qt::white );
- p->setPen( Qt::black );
+ p->fillRect( 0,0,w,h, TQt::white );
+ p->setPen( TQt::black );
/*
- QFont f( p->font() );
+ TQFont f( p->font() );
f.setBold(true);
p->setFont(f);
*/
}
- p->drawText( 2,0,w-4,h, Qt::AlignHCenter|AlignVCenter, text() );
+ p->drawText( 2,0,w-4,h, TQt::AlignHCenter|AlignVCenter, text() );
}
//////////////////// KileTable ////////////////////
-KileTable::KileTable(QWidget *dialog, QWidget *parent, const char *name) : QTable(parent,name)
+KileTable::KileTable(TQWidget *dialog, TQWidget *tqparent, const char *name) : TQTable(tqparent,name)
{
setShowGrid(false);
- setSelectionMode(QTable::NoSelection);
- setFocusStyle(QTable::FollowStyle);
+ setSelectionMode(TQTable::NoSelection);
+ setFocusStyle(TQTable::FollowStyle);
verticalHeader()->hide();
setLeftMargin(0);
- setVScrollBarMode(QScrollView::AlwaysOff);
- setHScrollBarMode(QScrollView::AlwaysOff);
- setFocusPolicy(QWidget::NoFocus);
+ setVScrollBarMode(TQScrollView::AlwaysOff);
+ setHScrollBarMode(TQScrollView::AlwaysOff);
+ setFocusPolicy(TQ_NoFocus);
horizontalHeader()->setResizeEnabled(false);
horizontalHeader()->setClickEnabled(false);
- connect(this,SIGNAL(clickedCell(KileTable *,int,int)),dialog,SLOT(clickedTable(KileTable *,int,int)));
+ connect(this,TQT_SIGNAL(clickedCell(KileTable *,int,int)),dialog,TQT_SLOT(clickedTable(KileTable *,int,int)));
}
-void KileTable::contentsMousePressEvent(QMouseEvent *ev)
+void KileTable::contentsMousePressEvent(TQMouseEvent *ev)
{
ev->accept();
emit( clickedCell( this,rowAt(ev->y()), columnAt(ev->x()) ));
@@ -89,18 +89,18 @@ void KileTable::contentsMousePressEvent(QMouseEvent *ev)
//////////////////// ConfigStructure ////////////////////
-ConfigStructure::ConfigStructure(QWidget *parent, const char *name )
- : QWidget(parent,name)
+ConfigStructure::ConfigStructure(TQWidget *tqparent, const char *name )
+ : TQWidget(tqparent,name)
{
m_entries << i18n( "Files" ) << i18n( "Labels" ) << i18n( "References" )
<< i18n( "Index" ) << i18n( "Graphics" ) << i18n( "Sectioning" );
- QHBoxLayout *hbox = new QHBoxLayout(this, 5,KDialog::spacingHint() );
+ TQHBoxLayout *hbox = new TQHBoxLayout(this, 5,KDialog::spacingHint() );
// Groupbox with entries
- QVGroupBox *gb_entries= new QVGroupBox(i18n("Entries"), this );
- QWidget *widget1 = new QWidget(gb_entries);
- QVBoxLayout *vbox1 = new QVBoxLayout(widget1, 5,KDialog::spacingHint() );
+ TQVGroupBox *gb_entries= new TQVGroupBox(i18n("Entries"), this );
+ TQWidget *widget1 = new TQWidget(gb_entries);
+ TQVBoxLayout *vbox1 = new TQVBoxLayout(widget1, 5,KDialog::spacingHint() );
// table with entries
m_entriestable = new KileTable(this,widget1);
@@ -108,31 +108,31 @@ ConfigStructure::ConfigStructure(QWidget *parent, const char *name )
m_entriestable->setNumRows(6);
m_entriestable->setColumnReadOnly(0,true);
- QStringList list1;
+ TQStringList list1;
list1 << i18n( "Title" ) << i18n( "Visible" ) << i18n( "Open" );
m_entriestable->setColumnLabels(list1);
m_entriestable->horizontalHeader()->setLabel(1,SmallIcon("structure"), i18n( "Visible" ));
m_entriestable->horizontalHeader()->setLabel(2,SmallIcon("structure"), i18n( "Node" ));
for ( uint i=0; i<m_entries.count(); ++i ) {
- QTableItem *item = new QTableItem(m_entriestable,QTableItem::Never, m_entries[i]);
+ TQTableItem *item = new TQTableItem(m_entriestable,TQTableItem::Never, m_entries[i]);
m_entriestable->setItem( i,0,item );
- m_visible[i] = new QCheckTableItem(m_entriestable,"");
+ m_visible[i] = new TQCheckTableItem(m_entriestable,"");
m_entriestable->setItem( i,1, m_visible[i] );
- m_defaultopen[i] = new QCheckTableItem(m_entriestable,"close");
+ m_defaultopen[i] = new TQCheckTableItem(m_entriestable,"close");
m_entriestable->setItem( i,2, m_defaultopen[i] );
}
// groupbox with sectioning
- QVGroupBox *gb_sectioning= new QVGroupBox(i18n("Sectioning"), this );
- QWidget *widget2 = new QWidget(gb_sectioning);
- QVBoxLayout *vbox2 = new QVBoxLayout(widget2, 5,KDialog::spacingHint() );
+ TQVGroupBox *gb_sectioning= new TQVGroupBox(i18n("Sectioning"), this );
+ TQWidget *widget2 = new TQWidget(gb_sectioning);
+ TQVBoxLayout *vbox2 = new TQVBoxLayout(widget2, 5,KDialog::spacingHint() );
// document class
- QWidget *widget3 = new QWidget(widget2);
- QHBoxLayout *hbox3 = new QHBoxLayout(widget3, 5,KDialog::spacingHint() );
- QLabel *label7 = new QLabel(i18n("Document class:"), widget3);
- comboclasses = new QComboBox(widget3);
+ TQWidget *widget3 = new TQWidget(widget2);
+ TQHBoxLayout *hbox3 = new TQHBoxLayout(widget3, 5,KDialog::spacingHint() );
+ TQLabel *label7 = new TQLabel(i18n("Document class:"), widget3);
+ comboclasses = new TQComboBox(widget3);
hbox3->addWidget(label7);
hbox3->addSpacing(10);
hbox3->addWidget(comboclasses);
@@ -145,33 +145,33 @@ ConfigStructure::ConfigStructure(QWidget *parent, const char *name )
m_sectioningtable->setColumnReadOnly(0,true);
m_sectioningtable->setColumnReadOnly(1,true);
- QStringList list2;
+ TQStringList list2;
list2 << i18n( "Level" ) << i18n( "LaTeX Command" ) << i18n( "Structure Node" );
m_sectioningtable->setColumnLabels(list2);
m_sectioningtable->horizontalHeader()->setLabel(2,SmallIcon("structure"),"Structure Node");
// default structure level
- QGroupBox *structGroup = new QGroupBox(2, Qt::Horizontal, i18n("Structure View"), widget2);
- QLabel *label9 = new QLabel(i18n("Default expansion &level: "),structGroup);
- m_structurelevel = new QSpinBox(1,5, 1, structGroup);
+ TQGroupBox *structGroup = new TQGroupBox(2, Qt::Horizontal, i18n("Structure View"), widget2);
+ TQLabel *label9 = new TQLabel(i18n("Default expansion &level: "),structGroup);
+ m_structurelevel = new TQSpinBox(1,5, 1, structGroup);
label9->setBuddy(m_structurelevel);
- QGroupBox *classGroup = new QGroupBox(1,Qt::Horizontal,i18n("Document Classes"), widget2);
- QWidget *widget4 = new QWidget(classGroup);
- QHBoxLayout *hbox4 = new QHBoxLayout(widget4, 5,KDialog::spacingHint() );
- QLabel *label10 = new QLabel("Manage classes:",widget4);
- add = new QPushButton(i18n("Add"), widget4);
- remove = new QPushButton(i18n("Remove"), widget4);
+ TQGroupBox *classGroup = new TQGroupBox(1,Qt::Horizontal,i18n("Document Classes"), widget2);
+ TQWidget *widget4 = new TQWidget(classGroup);
+ TQHBoxLayout *hbox4 = new TQHBoxLayout(widget4, 5,KDialog::spacingHint() );
+ TQLabel *label10 = new TQLabel("Manage classes:",widget4);
+ add = new TQPushButton(i18n("Add"), widget4);
+ remove = new TQPushButton(i18n("Remove"), widget4);
hbox4->addWidget(label10);
hbox4->addStretch();
hbox4->addWidget(add);
hbox4->addWidget(remove);
- // add widgets to the left vertical layout
+ // add widgets to the left vertical tqlayout
vbox1->addWidget(m_entriestable);
vbox1->addStretch();
- // add widgets to the right vertical layout
+ // add widgets to the right vertical tqlayout
vbox2->addWidget(widget3);
vbox2->addSpacing(10);
vbox2->addWidget(m_sectioningtable);
@@ -180,7 +180,7 @@ ConfigStructure::ConfigStructure(QWidget *parent, const char *name )
vbox2->addWidget(classGroup);
vbox2->addStretch();
- // add both groupboxes to horizontal layout
+ // add both groupboxes to horizontal tqlayout
hbox->addWidget(gb_entries);
hbox->addWidget(gb_sectioning);
hbox->setStretchFactor(gb_entries,3);
@@ -188,37 +188,37 @@ ConfigStructure::ConfigStructure(QWidget *parent, const char *name )
// set default sectioning commands
comboclasses->insertItem("latex");
- QStringList *sectcommands = new QStringList;
+ TQStringList *sectcommands = new TQStringList;
*sectcommands << "part" << "chapter" << "section" << "subsection" << "subsubsection";
m_docclasses["latex"] = sectcommands;
showSectioning(m_docclasses["latex"]);
remove->setEnabled(false);
- connect(m_structurelevel,SIGNAL(valueChanged(int)),this,SLOT(spinboxChanged(int)));
- connect(comboclasses,SIGNAL(activated(const QString &)),this,SLOT(comboboxChanged(const QString &)));
- connect(add,SIGNAL(clicked()),this,SLOT(clickedAdd()));
+ connect(m_structurelevel,TQT_SIGNAL(valueChanged(int)),this,TQT_SLOT(spinboxChanged(int)));
+ connect(comboclasses,TQT_SIGNAL(activated(const TQString &)),this,TQT_SLOT(comboboxChanged(const TQString &)));
+ connect(add,TQT_SIGNAL(clicked()),this,TQT_SLOT(clickedAdd()));
add->setEnabled(false);
}
ConfigStructure::~ConfigStructure()
{
- QMap<QString, const QStringList*>::Iterator it, end = m_docclasses.end();
+ TQMap<TQString, const TQStringList*>::Iterator it, end = m_docclasses.end();
for(it = m_docclasses.begin() ; it != end ; ++it)
delete *it;
}
void ConfigStructure::polish()
{
- // QWidget::polish();
+ // TQWidget::polish();
- uint w = m_entriestable->sizeHint().width();
+ uint w = m_entriestable->tqsizeHint().width();
m_entriestable->setColumnWidth(0,3*w/7);
m_entriestable->setColumnWidth(1,2*w/7);
m_entriestable->setColumnWidth(2,2*w/7+1);
m_entriestable->setColumnStretchable(2,true);
- w = m_sectioningtable->sizeHint().width();
+ w = m_sectioningtable->tqsizeHint().width();
m_sectioningtable->setColumnWidth(0,w/6);
m_sectioningtable->setColumnWidth(1,3*w/6);
m_sectioningtable->setColumnWidth(2,2*w/6+1);
@@ -245,44 +245,44 @@ void ConfigStructure::clickedTable(KileTable *table,int row, int col)
void ConfigStructure::spinboxChanged(int)
{
- if ( m_docclasses.contains( comboclasses->currentText() ) ) {
+ if ( m_docclasses.tqcontains( comboclasses->currentText() ) ) {
changeSectioning(m_docclasses[comboclasses->currentText()]);
}
}
-void ConfigStructure::comboboxChanged(const QString &name)
+void ConfigStructure::comboboxChanged(const TQString &name)
{
- if ( m_docclasses.contains(name) ) {
+ if ( m_docclasses.tqcontains(name) ) {
showSectioning(m_docclasses[name]);
remove->setEnabled( name != "latex" );
}
}
-void ConfigStructure::changeSectioning(const QStringList *list)
+void ConfigStructure::changeSectioning(const TQStringList *list)
{
for (uint i=0; i<list->count(); ++i) {
- QString label = ( i < (uint)m_structurelevel->value() ) ? "open" : "close";
+ TQString label = ( i < (uint)m_structurelevel->value() ) ? "open" : "close";
m_sectioningtable->setText(i,2,label);
}
}
-void ConfigStructure::showSectioning(const QStringList *list)
+void ConfigStructure::showSectioning(const TQStringList *list)
{
- QString label1,label2,label3;
+ TQString label1,label2,label3;
for (uint i=0; i<5; ++i) {
if ( i < list->count() ) {
- label1 = QString("%1").arg(i+1);
+ label1 = TQString("%1").tqarg(i+1);
label2 = (*list)[i];
label3 = ( i < (uint)m_structurelevel->value() ) ? "open" : "close";
} else {
- label1 = label2 = label3 = QString::null;
+ label1 = label2 = label3 = TQString();
}
KileCenteredTableItem *item1 = new KileCenteredTableItem(m_sectioningtable,
- QTableItem::Never,label1);
+ TQTableItem::Never,label1);
m_sectioningtable->setItem( i,0,item1 );
m_sectioningtable->setText( i,1,label2 );
KileCenteredTableItem *item3 = new KileCenteredTableItem(m_sectioningtable,
- QTableItem::Never,label3);
+ TQTableItem::Never,label3);
m_sectioningtable->setItem( i,2,item3 );
}
}
@@ -309,13 +309,13 @@ void ConfigStructure::readConfig(KConfig *config)
}
config->setGroup( "Structure Sectioning" );
- QStringList classlist = config->readListEntry("classes");
+ TQStringList classlist = config->readListEntry("classes");
classlist.sort();
for ( uint i=0; i<classlist.count(); ++i ) {
- QStringList list = config->readListEntry(classlist[i]);
+ TQStringList list = config->readListEntry(classlist[i]);
if ( list.count() > 0 ) {
comboclasses->insertItem(classlist[i]);
- QStringList *sectioningcommands = new QStringList(list);
+ TQStringList *sectioningcommands = new TQStringList(list);
m_docclasses[classlist[i]] = sectioningcommands;
}
}
@@ -335,12 +335,12 @@ void ConfigStructure::writeConfig(KConfig *config)
}
config->setGroup( "Structure Sectioning" );
- QStringList classlist;
+ TQStringList classlist;
for ( int i=0; i<comboclasses->count(); ++i ) {
- QString entry = comboclasses->text(i);
+ TQString entry = comboclasses->text(i);
if ( entry != "latex" ) {
classlist << entry;
- QString entrylist = m_docclasses[entry]->join(",");
+ TQString entrylist = m_docclasses[entry]->join(",");
config->writeEntry( entry, entrylist );
}
}
diff --git a/src/kile/configstructure.h b/src/kile/configstructure.h
index 9041642..4e49368 100644
--- a/src/kile/configstructure.h
+++ b/src/kile/configstructure.h
@@ -17,19 +17,19 @@
#ifndef CONFIGSTRUCTURE_H
#define CONFIGSTRUCTURE_H
-#include <qwidget.h>
-#include <qtable.h>
-#include <qstring.h>
-#include <qstringlist.h>
-#include <qmap.h>
+#include <tqwidget.h>
+#include <tqtable.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
+#include <tqmap.h>
class KConfig;
-class QRect;
-class QPainter;
-class QSpinBox;
-class QComboBox;
-class QPushButton;
+class TQRect;
+class TQPainter;
+class TQSpinBox;
+class TQComboBox;
+class TQPushButton;
/**
*@author Holger Danielsson
@@ -40,49 +40,51 @@ namespace KileStructure
enum { None=0x0, Visible=0x1, Opened=0x2 };
-class KileCenteredTableItem : public QTableItem
+class KileCenteredTableItem : public TQTableItem
{
public:
- KileCenteredTableItem(QTable *table,EditType et,const QString& text) : QTableItem(table,et,text) {}
- void paint(QPainter* p,const QColorGroup& cg,const QRect& cr,bool selected);
- int alignment() const { return Qt::AlignHCenter; }
+ KileCenteredTableItem(TQTable *table,EditType et,const TQString& text) : TQTableItem(table,et,text) {}
+ void paint(TQPainter* p,const TQColorGroup& cg,const TQRect& cr,bool selected);
+ int tqalignment() const { return TQt::AlignHCenter; }
};
-class KileTable : public QTable
+class KileTable : public TQTable
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileTable(QWidget *dialog, QWidget *parent=0, const char *name=0);
- void paintFocus(QPainter *, const QRect &) {}
+ KileTable(TQWidget *dialog, TQWidget *tqparent=0, const char *name=0);
+ void paintFocus(TQPainter *, const TQRect &) {}
protected:
- void contentsMousePressEvent(QMouseEvent *ev);
+ void contentsMousePressEvent(TQMouseEvent *ev);
signals:
void clickedCell(KileTable *,int row,int cell);
};
-class ConfigStructure : public QWidget
+class ConfigStructure : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- ConfigStructure(QWidget *parent=0, const char *name=0);
+ ConfigStructure(TQWidget *tqparent=0, const char *name=0);
~ConfigStructure();
void readConfig(KConfig *config);
void writeConfig(KConfig *config);
private:
- QStringList m_entries;
- QComboBox *comboclasses;
- QSpinBox *m_structurelevel;
- QPushButton *add, *remove;
+ TQStringList m_entries;
+ TQComboBox *comboclasses;
+ TQSpinBox *m_structurelevel;
+ TQPushButton *add, *remove;
KileTable *m_entriestable,*m_sectioningtable;
- QCheckTableItem *m_visible[6], *m_defaultopen[6];
- QMap<QString,const QStringList *> m_docclasses;
+ TQCheckTableItem *m_visible[6], *m_defaultopen[6];
+ TQMap<TQString,const TQStringList *> m_docclasses;
- void showSectioning(const QStringList *list);
- void changeSectioning(const QStringList *list);
+ void showSectioning(const TQStringList *list);
+ void changeSectioning(const TQStringList *list);
public slots:
void polish();
@@ -91,7 +93,7 @@ private slots:
void clickedTable(KileTable *table,int row,int col);
void clickedAdd();
void spinboxChanged(int);
- void comboboxChanged(const QString &name);
+ void comboboxChanged(const TQString &name);
};
}
diff --git a/src/kile/configtester.cpp b/src/kile/configtester.cpp
index eeaf5cb..a68cfe3 100644
--- a/src/kile/configtester.cpp
+++ b/src/kile/configtester.cpp
@@ -15,7 +15,7 @@
#include "configtester.h"
-#include <qfile.h>
+#include <tqfile.h>
#include <kio/netaccess.h>
#include <klocale.h>
@@ -32,14 +32,14 @@
#include "kiletool.h"
ConfigTest::ConfigTest() :
- m_name(QString::null),
- m_arg(QString::null),
- m_altArg(QString::null),
+ m_name(TQString()),
+ m_arg(TQString()),
+ m_altArg(TQString()),
m_mustPass(false)
{
}
-ConfigTest::ConfigTest(const QString &name, bool mustpass, const QString &arg, const QString &altarg /*= QString::null*/) :
+ConfigTest::ConfigTest(const TQString &name, bool mustpass, const TQString &arg, const TQString &altarg /*= TQString()*/) :
m_name(name),
m_arg(arg),
m_altArg(altarg),
@@ -62,22 +62,22 @@ int ConfigTest::status() const
else return Failure;
}
-QString ConfigTest::name() const
+TQString ConfigTest::name() const
{
return prettyName(m_name);
}
-QString ConfigTest::resultText() const
+TQString ConfigTest::resultText() const
{
- QString str = successMessage(m_name);
+ TQString str = successMessage(m_name);
if ( status() == Failure ) str = failureMessage(m_name);
else if ( status() == Critical ) str = criticalMessage(m_name);
if ( m_name == "binary" )
{
str += " (" + m_altArg + " => " + m_arg + ')';
- if ( status()==Failure && s_msgFailure.contains(m_altArg) )
- str += QString("<br>(%1)").arg( s_msgFailure[m_altArg] );
+ if ( status()==Failure && s_msgFailure.tqcontains(m_altArg) )
+ str += TQString("<br>(%1)").tqarg( s_msgFailure[m_altArg] );
return str;
}
else if ( m_name == "version" )
@@ -86,41 +86,41 @@ QString ConfigTest::resultText() const
return str;
}
-QMap<QString,QString> ConfigTest::s_prettyName;
-QMap<QString,QString> ConfigTest::s_msgSuccess;
-QMap<QString,QString> ConfigTest::s_msgFailure;
-QMap<QString,QString> ConfigTest::s_msgCritical;
+TQMap<TQString,TQString> ConfigTest::s_prettyName;
+TQMap<TQString,TQString> ConfigTest::s_msgSuccess;
+TQMap<TQString,TQString> ConfigTest::s_msgFailure;
+TQMap<TQString,TQString> ConfigTest::s_msgCritical;
-void ConfigTest::addPrettyName(const QString &test, const QString &prettyName) { s_prettyName [test] = prettyName;}
-void ConfigTest::addSuccessMessage(const QString &test, const QString &msg) { s_msgSuccess [test] = msg; }
-void ConfigTest::addFailureMessage(const QString &test, const QString &msg) { s_msgFailure [test] = msg; }
-void ConfigTest::addCriticalMessage(const QString &test, const QString &msg) { s_msgCritical [test] = msg; }
+void ConfigTest::addPrettyName(const TQString &test, const TQString &prettyName) { s_prettyName [test] = prettyName;}
+void ConfigTest::addSuccessMessage(const TQString &test, const TQString &msg) { s_msgSuccess [test] = msg; }
+void ConfigTest::addFailureMessage(const TQString &test, const TQString &msg) { s_msgFailure [test] = msg; }
+void ConfigTest::addCriticalMessage(const TQString &test, const TQString &msg) { s_msgCritical [test] = msg; }
-QString ConfigTest::prettyName(const QString &test)
+TQString ConfigTest::prettyName(const TQString &test)
{
- if ( s_prettyName.contains(test) ) return s_prettyName[test];
+ if ( s_prettyName.tqcontains(test) ) return s_prettyName[test];
else return test;
}
-QString ConfigTest::successMessage(const QString &test)
+TQString ConfigTest::successMessage(const TQString &test)
{
- if ( s_msgSuccess.contains(test) ) return s_msgSuccess[test];
+ if ( s_msgSuccess.tqcontains(test) ) return s_msgSuccess[test];
else return i18n("Passed");
}
-QString ConfigTest::failureMessage(const QString &test)
+TQString ConfigTest::failureMessage(const TQString &test)
{
- if ( s_msgFailure.contains(test) ) return s_msgFailure[test];
+ if ( s_msgFailure.tqcontains(test) ) return s_msgFailure[test];
else return i18n("Failed");
}
-QString ConfigTest::criticalMessage(const QString &test)
+TQString ConfigTest::criticalMessage(const TQString &test)
{
- if ( s_msgCritical.contains(test) ) return s_msgCritical[test];
+ if ( s_msgCritical.tqcontains(test) ) return s_msgCritical[test];
else return i18n("Critical failure");
}
-Tester::Tester(QObject *parent, const char *name) : QObject(parent, name), m_process(0L)
+Tester::Tester(TQObject *tqparent, const char *name) : TQObject(tqparent, name), m_process(0L)
{
ConfigTest::addPrettyName("binary", i18n("Binary"));
ConfigTest::addCriticalMessage("binary", i18n("Could not find the binary for this essential tool."));
@@ -131,7 +131,7 @@ Tester::Tester(QObject *parent, const char *name) : QObject(parent, name), m_pro
ConfigTest::addPrettyName("version", i18n("Version"));
ConfigTest::addPrettyName("kile", i18n("Running in Kile"));
- QString str = i18n("Kile is not configured correctly. Go to Settings->Configure Kile->Tools and either fix the problem or change to the default settings.");
+ TQString str = i18n("Kile is not configured correctly. Go to Settings->Configure Kile->Tools and either fix the problem or change to the default settings.");
ConfigTest::addCriticalMessage("kile", str);
ConfigTest::addFailureMessage("kile", str);
@@ -161,16 +161,16 @@ void Tester::saveResults(const KURL & dest)
void Tester::runTests()
{
- QString srcdir = KGlobal::dirs()->findResourceDir("appdata","test/runTests.sh") + "test";
+ TQString srcdir = KGlobal::dirs()->findResourceDir("appdata","test/runTests.sh") + "test";
KILE_DEBUG() << "Tester::runTests: srcdir = " << srcdir << endl;
m_tempDir = new KTempDir();
- QString destdir = m_tempDir->name();
+ TQString destdir = m_tempDir->name();
KILE_DEBUG() << "Tester::runTests: destdir = " << destdir << endl;
m_resultsFile = destdir + "results.rc";
- QString shellname = KGlobal::dirs()->findExe("sh");
+ TQString shellname = KGlobal::dirs()->findExe("sh");
KILE_DEBUG() << "Tester::runTests: shellname = " << shellname << endl;
- m_process = new KShellProcess(QFile::encodeName( shellname ));
+ m_process = new KShellProcess(TQFile::encodeName( shellname ));
if (! KileConfig::teXPaths().isEmpty())
{
m_process->setEnvironment("TEXINPUTS", KileInfo::expandEnvironmentVars( KileConfig::teXPaths() + ":$TEXINPUTS"));
@@ -178,8 +178,8 @@ void Tester::runTests()
*m_process << "cd " + KShellProcess::quote(destdir) + " && ";
*m_process << "cp " + KShellProcess::quote(srcdir) +"/* " + KShellProcess::quote(destdir) + " && ";
*m_process << "source runTests.sh " + KShellProcess::quote(m_resultsFile) + " " + KShellProcess::quote(destdir);
- connect(m_process, SIGNAL(receivedStdout(KProcess *, char *, int)), this, SLOT(determineProgress(KProcess *, char *, int)));
- connect(m_process, SIGNAL(processExited(KProcess *)), this, SLOT(processTestResults(KProcess *)));
+ connect(m_process, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)), this, TQT_SLOT(determineProgress(KProcess *, char *, int)));
+ connect(m_process, TQT_SIGNAL(processExited(KProcess *)), this, TQT_SLOT(processTestResults(KProcess *)));
if (m_process->start(KProcess::NotifyOnExit, KProcess::AllOutput)) emit(started());
}
@@ -190,15 +190,15 @@ void Tester::stop()
void Tester::determineProgress(KProcess */*proc*/, char *buf, int len)
{
- static QString s = QString::null;
+ static TQString s = TQString();
- s += QString::fromLocal8Bit(buf, len);
+ s += TQString::fromLocal8Bit(buf, len);
if ( s.endsWith("\n") )
{
bool ok = false;
int number = s.toInt(&ok);
if (ok) emit(percentageDone(number));
- s = QString::null;
+ s = TQString();
}
}
@@ -209,9 +209,9 @@ void Tester::processTestResults (KProcess *proc)
emit(percentageDone(100));
KSimpleConfig config(m_resultsFile, true);
- QStringList groups = config.groupList();
- QStringList::Iterator itend = groups.end();
- for ( QStringList::Iterator it = groups.begin(); it != itend; ++it )
+ TQStringList groups = config.groupList();
+ TQStringList::Iterator itend = groups.end();
+ for ( TQStringList::Iterator it = groups.begin(); it != itend; ++it )
processTool(&config, *it);
emit(finished(true));
@@ -223,41 +223,41 @@ void Tester::processTestResults (KProcess *proc)
}
}
-void Tester::processTool(KConfig *config, const QString &tool)
+void Tester::processTool(KConfig *config, const TQString &tool)
{
config->setGroup(tool);
- QStringList criticaltests = QStringList::split(",", config->readEntry("mustpass", ""));
+ TQStringList criticaltests = TQStringList::split(",", config->readEntry("mustpass", ""));
//Did we find the executable?
- QValueList<ConfigTest> tests;
- tests << ConfigTest("binary", criticaltests.contains("where"), config->readEntry("where"), config->readEntry("executable"));
- if (config->hasKey("version") ) tests << ConfigTest("version", criticaltests.contains("version"), config->readEntry("version"));
- if (config->hasKey("basic") ) tests << ConfigTest("basic", criticaltests.contains("basic"), config->readEntry("basic"));
- if (config->hasKey("src") ) tests << ConfigTest("src", criticaltests.contains("src"), config->readEntry("src"));
- if (config->hasKey("kile") ) tests << ConfigTest("kile", criticaltests.contains("kile"), config->readEntry("kile"));
+ TQValueList<ConfigTest> tests;
+ tests << ConfigTest("binary", criticaltests.tqcontains("where"), config->readEntry("where"), config->readEntry("executable"));
+ if (config->hasKey("version") ) tests << ConfigTest("version", criticaltests.tqcontains("version"), config->readEntry("version"));
+ if (config->hasKey("basic") ) tests << ConfigTest("basic", criticaltests.tqcontains("basic"), config->readEntry("basic"));
+ if (config->hasKey("src") ) tests << ConfigTest("src", criticaltests.tqcontains("src"), config->readEntry("src"));
+ if (config->hasKey("kile") ) tests << ConfigTest("kile", criticaltests.tqcontains("kile"), config->readEntry("kile"));
addResult(tool, tests);
}
-void Tester::addResult(const QString &tool, const QValueList<ConfigTest> &tests)
+void Tester::addResult(const TQString &tool, const TQValueList<ConfigTest> &tests)
{
m_results [tool] = tests;
}
-QStringList Tester::testedTools()
+TQStringList Tester::testedTools()
{
return m_results.keys();
}
-QValueList<ConfigTest> Tester::resultForTool(const QString & tool)
+TQValueList<ConfigTest> Tester::resultForTool(const TQString & tool)
{
return m_results[tool];
}
-int Tester::statusForTool(const QString & tool)
+int Tester::statusForTool(const TQString & tool)
{
- QValueList<ConfigTest> tests = m_results[tool];
+ TQValueList<ConfigTest> tests = m_results[tool];
int status = ConfigTest::Success;
for ( uint i = 0; i < tests.count(); ++i)
{
diff --git a/src/kile/configtester.h b/src/kile/configtester.h
index c330a25..8646970 100644
--- a/src/kile/configtester.h
+++ b/src/kile/configtester.h
@@ -16,7 +16,7 @@
#ifndef CONFIGCHECKER_H
#define CONFIGCHECKER_H
-#include <qobject.h>
+#include <tqobject.h>
class KTempDir;
class KConfig;
@@ -30,46 +30,47 @@ class KURL;
class ConfigTest
{
public:
- enum Status { Success = 3, Failure = 2, Critical = 1 };
+ enum tqStatus { Success = 3, Failure = 2, Critical = 1 };
ConfigTest();
- ConfigTest(const QString &name, bool mustpass, const QString &arg, const QString &altarg = QString::null);
+ ConfigTest(const TQString &name, bool mustpass, const TQString &arg, const TQString &altarg = TQString());
int status() const;
- QString resultText() const;
- QString name() const;
+ TQString resultText() const;
+ TQString name() const;
private:
- QString m_name, m_arg, m_altArg;
+ TQString m_name, m_arg, m_altArg;
bool m_mustPass;
public:
- static void addPrettyName(const QString &test, const QString &prettyName);
- static void addSuccessMessage(const QString &test, const QString &msg);
- static void addFailureMessage(const QString &test, const QString &msg);
- static void addCriticalMessage(const QString &test, const QString &msg);
+ static void addPrettyName(const TQString &test, const TQString &prettyName);
+ static void addSuccessMessage(const TQString &test, const TQString &msg);
+ static void addFailureMessage(const TQString &test, const TQString &msg);
+ static void addCriticalMessage(const TQString &test, const TQString &msg);
- static QString prettyName(const QString &test);
- static QString successMessage(const QString &test);
- static QString failureMessage(const QString &test);
- static QString criticalMessage(const QString &test);
+ static TQString prettyName(const TQString &test);
+ static TQString successMessage(const TQString &test);
+ static TQString failureMessage(const TQString &test);
+ static TQString criticalMessage(const TQString &test);
private:
- static QMap<QString,QString> s_prettyName, s_msgSuccess, s_msgFailure, s_msgCritical;
+ static TQMap<TQString,TQString> s_prettyName, s_msgSuccess, s_msgFailure, s_msgCritical;
};
-class Tester : public QObject
+class Tester : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- Tester(QObject *parent = 0, const char *name = 0);
+ Tester(TQObject *tqparent = 0, const char *name = 0);
~Tester();
- QStringList testedTools();
- QValueList<ConfigTest> resultForTool(const QString &);
- int statusForTool(const QString &);
+ TQStringList testedTools();
+ TQValueList<ConfigTest> resultForTool(const TQString &);
+ int statusForTool(const TQString &);
public slots:
void runTests();
@@ -84,13 +85,13 @@ signals:
private slots:
void determineProgress(KProcess *, char *, int);
void processTestResults (KProcess *);
- void processTool(KConfig *, const QString &);
+ void processTool(KConfig *, const TQString &);
- void addResult(const QString &tool, const QValueList<ConfigTest> &tests);
+ void addResult(const TQString &tool, const TQValueList<ConfigTest> &tests);
private:
- QMap<QString,QValueList<ConfigTest> > m_results;
- QString m_resultsFile;
+ TQMap<TQString,TQValueList<ConfigTest> > m_results;
+ TQString m_resultsFile;
KTempDir *m_tempDir;
KProcess *m_process;
};
diff --git a/src/kile/convert.cpp b/src/kile/convert.cpp
index e5c1f5d..2572ab4 100644
--- a/src/kile/convert.cpp
+++ b/src/kile/convert.cpp
@@ -15,9 +15,9 @@
#include "convert.h"
-#include <qregexp.h>
-#include <qtextcodec.h>
-#include <qfile.h>
+#include <tqregexp.h>
+#include <tqtextcodec.h>
+#include <tqfile.h>
#include <kmessagebox.h>
#include <kglobal.h>
@@ -25,9 +25,9 @@
#include "kiledebug.h"
#include <kate/document.h>
-QMap<QString, ConvertMap*> ConvertMap::g_maps;
+TQMap<TQString, ConvertMap*> ConvertMap::g_maps;
-bool ConvertMap::create(const QString & encoding)
+bool ConvertMap::create(const TQString & encoding)
{
KILE_DEBUG() << "\tlooking for map for " << encoding << endl;
ConvertMap * map = g_maps[encoding];
@@ -49,9 +49,9 @@ bool ConvertMap::create(const QString & encoding)
return ( map != 0L );
}
-QString ConvertMap::encodingNameFor(const QString & name)
+TQString ConvertMap::encodingNameFor(const TQString & name)
{
- QString std;
+ TQString std;
for ( uint i = 0; i < name.length(); ++i )
if ( !name[i].isSpace() )
std += name[i];
@@ -67,9 +67,9 @@ QString ConvertMap::encodingNameFor(const QString & name)
return name;
}
-QString ConvertMap::isoNameFor(const QString & name)
+TQString ConvertMap::isoNameFor(const TQString & name)
{
- QString std;
+ TQString std;
for ( uint i = 0; i < name.length(); ++i )
if ( !name[i].isSpace() )
std += name[i];
@@ -85,44 +85,44 @@ QString ConvertMap::isoNameFor(const QString & name)
return name;
}
-ConvertMap::ConvertMap(const QString & enc )
+ConvertMap::ConvertMap(const TQString & enc )
{
m_aliases.append(encodingNameFor(enc));
m_aliases.append(isoNameFor(enc));
}
-void ConvertMap::addPair(QChar c, const QString & enc)
+void ConvertMap::addPair(TQChar c, const TQString & enc)
{
m_toASCII[c] = commandIsTerminated(enc) ? enc : enc + "{}" ;
m_toEncoding[enc] = c;
}
-bool ConvertMap::commandIsTerminated(const QString & command)
+bool ConvertMap::commandIsTerminated(const TQString & command)
{
- static QRegExp reCommandSequences("\\\\([a-zA-Z]+|\\\"|\\')$");
+ static TQRegExp reCommandSequences("\\\\([a-zA-Z]+|\\\"|\\')$");
return (reCommandSequences.search(command) == -1);
}
bool ConvertMap::load()
{
- static QRegExp reMap("^(.*):(.*)");
+ static TQRegExp reMap("^(.*):(.*)");
//makeMap(encoding());
//if map already exists, replace it
- QFile qf(KGlobal::dirs()->findResource("appdata","encodings/" + encoding() + ".enc"));
+ TQFile qf(KGlobal::dirs()->findResource("appdata","encodings/" + encoding() + ".enc"));
if ( qf.open(IO_ReadOnly) )
{
- QTextStream stream( &qf );
- QTextCodec *codec = QTextCodec::codecForName(isoName().ascii());
+ TQTextStream stream( &qf );
+ TQTextCodec *codec = TQTextCodec::codecForName(isoName().ascii());
if ( codec ) stream.setCodec(codec);
while ( !stream.atEnd() )
{
//parse the line
- if ( stream.readLine().find(reMap) != -1)
+ if ( stream.readLine().tqfind(reMap) != -1)
addPair(reMap.cap(1)[0], reMap.cap(2));
}
qf.close();
@@ -136,13 +136,13 @@ bool ConvertMap::load()
//BEGIN ConvertIO classes
ConvertIO::ConvertIO(Kate::Document *doc) :
m_doc(doc),
- m_text(QString::null),
- m_line(QString::null),
+ m_text(TQString()),
+ m_line(TQString()),
m_nLine(0)
{
}
-QString & ConvertIO::currentLine()
+TQString & ConvertIO::currentLine()
{
return m_line;
}
@@ -173,11 +173,11 @@ ConvertIOFile::ConvertIOFile(Kate::Document *doc, const KURL & url) : ConvertIO(
void ConvertIOFile::writeText()
{
- QFile qf(m_url.path());
+ TQFile qf(m_url.path());
if ( qf.open(IO_WriteOnly) )
{
//read the file
- QTextStream stream( &qf );
+ TQTextStream stream( &qf );
stream << m_text;
qf.close();
}
@@ -185,7 +185,7 @@ void ConvertIOFile::writeText()
kdWarning() << "Could not open " << m_url.path() << endl;
}
-ConvertBase::ConvertBase(const QString & encoding, ConvertIO * io) :
+ConvertBase::ConvertBase(const TQString & encoding, ConvertIO * io) :
m_io(io),
m_encoding(encoding),
m_map(0L)
@@ -195,16 +195,16 @@ ConvertBase::ConvertBase(const QString & encoding, ConvertIO * io) :
//END ConvertIO classes
//BEGIN ConvertBase
-QString ConvertBase::mapNext(uint &i)
+TQString ConvertBase::mapNext(uint &i)
{
- return (QString)m_io->currentLine()[i++];
+ return (TQString)m_io->currentLine()[i++];
}
bool ConvertBase::convert()
{
if ( ! setMap() ) return false;
- m_io->text() = QString::null;
+ m_io->text() = TQString();
do
{
m_io->nextLine();
@@ -234,41 +234,41 @@ bool ConvertBase::setMap()
//END ConvertBase
//BEGIN ConvertEncToASCII
-QString ConvertEncToASCII::mapNext(uint &i)
+TQString ConvertEncToASCII::mapNext(uint &i)
{
- return m_map->canDecode(m_io->currentLine()[i]) ? m_map->toASCII(m_io->currentLine()[i++]) : (QString)m_io->currentLine()[i++];
+ return m_map->canDecode(m_io->currentLine()[i]) ? m_map->toASCII(m_io->currentLine()[i++]) : (TQString)m_io->currentLine()[i++];
}
//END ConvertEncToASCII
//BEGIN ConvertASCIIToEnc
//i is the position of the '\'
-QString ConvertASCIIToEnc::nextSequence(uint &i)
+TQString ConvertASCIIToEnc::nextSequence(uint &i)
{
//get first two characters
- QString seq = (QString)m_io->currentLine()[i++];
+ TQString seq = (TQString)m_io->currentLine()[i++];
if ( m_io->currentLine()[i].isLetter() )
{
while ( m_io->currentLine()[i].isLetter() )
- seq += (QString)m_io->currentLine()[i++];
+ seq += (TQString)m_io->currentLine()[i++];
}
else
- return seq + (QString)m_io->currentLine()[i++];
+ return seq + (TQString)m_io->currentLine()[i++];
return seq;
}
-bool ConvertASCIIToEnc::isModifier(const QString & seq)
+bool ConvertASCIIToEnc::isModifier(const TQString & seq)
{
- static QRegExp reModifier("\\\\([cHkruv]|\"|\'|\\^|`|~|=|\\.)");
+ static TQRegExp reModifier("\\\\([cHkruv]|\"|\'|\\^|`|~|=|\\.)");
return reModifier.exactMatch(seq);
}
-QString ConvertASCIIToEnc::getSequence(uint &i)
+TQString ConvertASCIIToEnc::getSequence(uint &i)
{
- QString seq = nextSequence(i);
- static QRegExp reBraces("\\{([a-zA-Z]?)\\}");
+ TQString seq = nextSequence(i);
+ static TQRegExp reBraces("\\{([a-zA-Z]?)\\}");
if ( isModifier(seq) )
{
@@ -291,8 +291,8 @@ QString ConvertASCIIToEnc::getSequence(uint &i)
}
else
{
- QChar nextChar = m_io->currentLine()[i++];
- if ( !nextChar.isSpace() ) seq += (QString)nextChar;
+ TQChar nextChar = m_io->currentLine()[i++];
+ if ( !nextChar.isSpace() ) seq += (TQString)nextChar;
}
}
}
@@ -305,11 +305,11 @@ QString ConvertASCIIToEnc::getSequence(uint &i)
return seq;
}
-QString ConvertASCIIToEnc::mapNext(uint &i)
+TQString ConvertASCIIToEnc::mapNext(uint &i)
{
if ( m_io->currentLine()[i] == '\\' )
{
- QString seq = getSequence(i);
+ TQString seq = getSequence(i);
KILE_DEBUG() << "'\tsequence: " << seq << endl;
if ( m_map->canEncode(seq) )
{
diff --git a/src/kile/convert.h b/src/kile/convert.h
index 651d330..0e2b372 100644
--- a/src/kile/convert.h
+++ b/src/kile/convert.h
@@ -16,9 +16,9 @@
#ifndef CONVERT_H
#define CONVERT_H
-#include <qstring.h>
-#include <qstringlist.h>
-#include <qmap.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
+#include <tqmap.h>
#include <kurl.h>
@@ -27,39 +27,39 @@ namespace Kate { class Document; }
class ConvertMap
{
protected:
- ConvertMap(const QString & encoding);
+ ConvertMap(const TQString & encoding);
public:
- const QString & encoding() const { return m_aliases[0]; }
- const QString & isoName() const { return m_aliases[1]; }
+ const TQString & encoding() const { return m_aliases[0]; }
+ const TQString & isoName() const { return m_aliases[1]; }
- QChar toEncoding(const QString & enc) { return m_toEncoding[enc]; }
- QString toASCII(const QChar & c) { return m_toASCII[c]; }
+ TQChar toEncoding(const TQString & enc) { return m_toEncoding[enc]; }
+ TQString toASCII(const TQChar & c) { return m_toASCII[c]; }
- void addPair(QChar c, const QString & enc);
+ void addPair(TQChar c, const TQString & enc);
- bool canDecode(const QChar & c) { return ( m_toASCII.contains(c) > 0 ); }
- bool canEncode(const QString & enc) { return ( m_toEncoding.contains(enc) > 0 ); }
+ bool canDecode(const TQChar & c) { return ( m_toASCII.tqcontains(c) > 0 ); }
+ bool canEncode(const TQString & enc) { return ( m_toEncoding.tqcontains(enc) > 0 ); }
bool load();
private:
- bool commandIsTerminated(const QString &);
+ bool commandIsTerminated(const TQString &);
private:
- QStringList m_aliases;
- QMap<QChar, QString> m_toASCII;
- QMap<QString, QChar> m_toEncoding;
+ TQStringList m_aliases;
+ TQMap<TQChar, TQString> m_toASCII;
+ TQMap<TQString, TQChar> m_toEncoding;
//static members
public:
- static bool create(const QString & encoding);
- static QString encodingNameFor(const QString &);
- static QString isoNameFor(const QString &);
- static ConvertMap * mapFor(const QString & enc) { return g_maps[enc]; }
+ static bool create(const TQString & encoding);
+ static TQString encodingNameFor(const TQString &);
+ static TQString isoNameFor(const TQString &);
+ static ConvertMap * mapFor(const TQString & enc) { return g_maps[enc]; }
private:
- static QMap<QString, ConvertMap*> g_maps;
+ static TQMap<TQString, ConvertMap*> g_maps;
};
class ConvertIO
@@ -69,15 +69,15 @@ public:
virtual ~ConvertIO() {}
virtual void nextLine(); //read next line
- virtual QString & currentLine();
- virtual QString & text() { return m_text; }
+ virtual TQString & currentLine();
+ virtual TQString & text() { return m_text; }
virtual void writeText();
virtual uint current(); //current line number
virtual bool done();
protected:
Kate::Document *m_doc;
- QString m_text, m_line;
+ TQString m_text, m_line;
uint m_nLine;
};
@@ -95,7 +95,7 @@ private:
class ConvertBase
{
public:
- ConvertBase(const QString & encoding, ConvertIO * io);
+ ConvertBase(const TQString & encoding, ConvertIO * io);
virtual ~ConvertBase() {};
public:
@@ -104,32 +104,32 @@ public:
protected:
virtual bool setMap();
- virtual QString mapNext(uint &);
+ virtual TQString mapNext(uint &);
ConvertIO *m_io;
- QString m_encoding;
+ TQString m_encoding;
ConvertMap *m_map;
};
class ConvertEncToASCII : public ConvertBase
{
public:
- ConvertEncToASCII(const QString & encoding, ConvertIO * io) : ConvertBase(encoding, io) {}
+ ConvertEncToASCII(const TQString & encoding, ConvertIO * io) : ConvertBase(encoding, io) {}
protected:
- QString mapNext(uint &);
+ TQString mapNext(uint &);
};
class ConvertASCIIToEnc : public ConvertBase
{
public:
- ConvertASCIIToEnc(const QString & encoding, ConvertIO * io) : ConvertBase(encoding, io) {}
+ ConvertASCIIToEnc(const TQString & encoding, ConvertIO * io) : ConvertBase(encoding, io) {}
protected:
- QString getSequence(uint &);
- QString nextSequence(uint &);
- bool isModifier(const QString &);
- QString mapNext(uint &);
+ TQString getSequence(uint &);
+ TQString nextSequence(uint &);
+ bool isModifier(const TQString &);
+ TQString mapNext(uint &);
};
#endif
diff --git a/src/kile/docpart.cpp b/src/kile/docpart.cpp
index c11b5d2..62977a9 100644
--- a/src/kile/docpart.cpp
+++ b/src/kile/docpart.cpp
@@ -27,26 +27,26 @@
#include <khtml_part.h>
#include <khtml_settings.h>
-DocumentationViewer::DocumentationViewer(QWidget *parent, const char *name ) : KHTMLPart(parent,name, 0, 0, BrowserViewGUI)
+DocumentationViewer::DocumentationViewer(TQWidget *tqparent, const char *name ) : KHTMLPart(tqparent,name, 0, 0, BrowserViewGUI)
{
m_hpos = 0;
KConfig konqConfig("konquerorrc");
konqConfig.setGroup("HTML Settings");
//const KHTMLSettings * set = settings();
//( const_cast<KHTMLSettings *>(set) )->init( &konqConfig, false );
- QString rc = KGlobal::dirs()->findResource("appdata", "docpartui.rc");
+ TQString rc = KGlobal::dirs()->findResource("appdata", "docpartui.rc");
setXMLFile(rc);
- (void) KStdAction::back(this, SLOT(back()), actionCollection(),"Back" );
- (void) KStdAction::forward(this, SLOT(forward()), actionCollection(),"Forward" );
- (void) KStdAction::home(this, SLOT(home()), actionCollection(),"Home" );
+ (void) KStdAction::back(this, TQT_SLOT(back()), actionCollection(),"Back" );
+ (void) KStdAction::forward(this, TQT_SLOT(forward()), actionCollection(),"Forward" );
+ (void) KStdAction::home(this, TQT_SLOT(home()), actionCollection(),"Home" );
}
DocumentationViewer::~DocumentationViewer() {}
-void DocumentationViewer::urlSelected(const QString &url, int button, int state,const QString & target, KParts::URLArgs args)
+void DocumentationViewer::urlSelected(const TQString &url, int button, int state,const TQString & target, KParts::URLArgs args)
{
KURL cURL = completeURL(url);
- QString mime = KMimeType::findByURL(cURL).data()->name();
+ TQString mime = KMimeType::findByURL(cURL).data()->name();
//load this URL in the embedded viewer if KHTML can handle it, or when mimetype detection failed
KService::Ptr service = KService::serviceByDesktopName("khtml");
@@ -78,7 +78,7 @@ void DocumentationViewer::forward()
{
++m_hpos;
openURL( KURL( m_history[m_hpos]) );
- emit updateStatus( backEnable() , forwardEnable() );
+ emit updatetqStatus( backEnable() , forwardEnable() );
}
}
@@ -88,12 +88,12 @@ void DocumentationViewer::back()
if ( backEnable() ) {
--m_hpos;
openURL( KURL(m_history[m_hpos]) );
- emit updateStatus( backEnable() , forwardEnable() );
+ emit updatetqStatus( backEnable() , forwardEnable() );
}
}
-void DocumentationViewer::addToHistory( const QString & url )
+void DocumentationViewer::addToHistory( const TQString & url )
{
if ( m_history.count() > 0 )
{
@@ -106,7 +106,7 @@ void DocumentationViewer::addToHistory( const QString & url )
m_history.append(url);
m_hpos = m_history.count()-1;
- emit updateStatus( backEnable() , forwardEnable() );
+ emit updatetqStatus( backEnable() , forwardEnable() );
}
diff --git a/src/kile/docpart.h b/src/kile/docpart.h
index b031934..bc9af56 100644
--- a/src/kile/docpart.h
+++ b/src/kile/docpart.h
@@ -17,14 +17,15 @@
#define DOCPART_H
#include <khtml_part.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
class DocumentationViewer : public KHTMLPart
{
Q_OBJECT
+ TQ_OBJECT
public:
- DocumentationViewer(QWidget *parent=0, const char *name=0);
+ DocumentationViewer(TQWidget *tqparent=0, const char *name=0);
~DocumentationViewer();
bool backEnable();
bool forwardEnable();
@@ -33,16 +34,16 @@ public slots:
void home();
void forward();
void back();
- void addToHistory( const QString & url );
+ void addToHistory( const TQString & url );
signals:
- void updateStatus( bool back, bool forward );
+ void updatetqStatus( bool back, bool forward );
protected:
- virtual void urlSelected( const QString &url, int button=0, int state=0,const QString &_target= QString::null, KParts::URLArgs args = KParts::URLArgs());
+ virtual void urlSelected( const TQString &url, int button=0, int state=0,const TQString &_target= TQString(), KParts::URLArgs args = KParts::URLArgs());
private:
- QStringList m_history;
+ TQStringList m_history;
unsigned int m_hpos;
};
diff --git a/src/kile/editorkeysequencemanager.cpp b/src/kile/editorkeysequencemanager.cpp
index 9d6ab40..213b959 100644
--- a/src/kile/editorkeysequencemanager.cpp
+++ b/src/kile/editorkeysequencemanager.cpp
@@ -23,17 +23,17 @@
namespace KileEditorKeySequence {
- Manager::Manager(KileInfo* kileInfo, QObject *parent, const char *name) : QObject(parent, name), m_kileInfo(kileInfo) {
+ Manager::Manager(KileInfo* kileInfo, TQObject *tqparent, const char *name) : TQObject(tqparent, name), m_kileInfo(kileInfo) {
}
Manager::~Manager() {
}
- void Manager::addAction(const QString& seq, Action *action) {
+ void Manager::addAction(const TQString& seq, Action *action) {
if(seq.isEmpty()) {
return;
}
- if(m_actionMap.find(seq) == m_actionMap.end()) {
+ if(m_actionMap.tqfind(seq) == m_actionMap.end()) {
m_actionMap[seq] = action;
m_watchedKeySequencesList.push_back(seq);
emit watchedKeySequencesChanged();
@@ -41,11 +41,11 @@ namespace KileEditorKeySequence {
}
- void Manager::removeKeySequence(const QString& seq) {
+ void Manager::removeKeySequence(const TQString& seq) {
if(seq.isEmpty()) {
return;
}
- QMap<QString, Action*>::iterator it = m_actionMap.find(seq);
+ TQMap<TQString, Action*>::iterator it = m_actionMap.tqfind(seq);
if(it != m_actionMap.end()) {
delete (it.data());
m_actionMap.remove(it);
@@ -54,13 +54,13 @@ namespace KileEditorKeySequence {
}
}
- void Manager::removeKeySequence(const QStringList& l) {
+ void Manager::removeKeySequence(const TQStringList& l) {
bool changed = false;
- for(QStringList::const_iterator i = l.begin(); i != l.end(); ++i) {
+ for(TQStringList::const_iterator i = l.begin(); i != l.end(); ++i) {
if((*i).isEmpty()) {
continue;
}
- QMap<QString, Action*>::iterator it = m_actionMap.find(*i);
+ TQMap<TQString, Action*>::iterator it = m_actionMap.tqfind(*i);
if(it != m_actionMap.end()) {
delete (it.data());
m_actionMap.remove(it);
@@ -73,9 +73,9 @@ namespace KileEditorKeySequence {
}
}
- void Manager::addActionMap(const QMap<QString, Action*>& map) {
+ void Manager::addActionMap(const TQMap<TQString, Action*>& map) {
bool changed = false;
- for(QMap<QString, Action*>::const_iterator i = map.begin(); i != map.end(); ++i) {
+ for(TQMap<TQString, Action*>::const_iterator i = map.begin(); i != map.end(); ++i) {
if(i.key().isEmpty()) {
continue;
}
@@ -89,24 +89,24 @@ namespace KileEditorKeySequence {
}
}
- QString Manager::getKeySequence(const Action* a) {
- for(QMap<QString, Action*>::const_iterator i = m_actionMap.begin(); i != m_actionMap.end(); ++i) {
+ TQString Manager::getKeySequence(const Action* a) {
+ for(TQMap<TQString, Action*>::const_iterator i = m_actionMap.begin(); i != m_actionMap.end(); ++i) {
if(i.data() == a) {
return i.key();
}
}
- return QString();
+ return TQString();
}
- Action* Manager::getAction(const QString& seq) {
- QMap<QString, Action*>::iterator i = m_actionMap.find(seq);
+ Action* Manager::getAction(const TQString& seq) {
+ TQMap<TQString, Action*>::iterator i = m_actionMap.tqfind(seq);
return (i == m_actionMap.end()) ? 0L : (*i);
}
- void Manager::setEditorKeySequence(const QString& /* seq */, Action* /* action */) {
+ void Manager::setEditorKeySequence(const TQString& /* seq */, Action* /* action */) {
}
- void Manager::keySequenceTyped(const QString& seq) {
+ void Manager::keySequenceTyped(const TQString& seq) {
m_actionMap[seq]->execute();
}
@@ -117,12 +117,12 @@ namespace KileEditorKeySequence {
}
- const QStringList& Manager::getWatchedKeySequences() {
+ const TQStringList& Manager::getWatchedKeySequences() {
return m_watchedKeySequencesList;
}
- bool Manager::isSequenceAssigned(const QString& seq) const {
- for(QValueList<QString>::const_iterator i = m_watchedKeySequencesList.begin(); i != m_watchedKeySequencesList.end(); ++i) {
+ bool Manager::isSequenceAssigned(const TQString& seq) const {
+ for(TQValueList<TQString>::const_iterator i = m_watchedKeySequencesList.begin(); i != m_watchedKeySequencesList.end(); ++i) {
if((*i).startsWith(seq)) {
return true;
}
@@ -130,24 +130,24 @@ namespace KileEditorKeySequence {
return false;
}
- QPair<int, QString> Manager::checkSequence(const QString& seq, const QString& skip) {
- for(QValueList<QString>::iterator i = m_watchedKeySequencesList.begin(); i != m_watchedKeySequencesList.end(); ++i) {
+ TQPair<int, TQString> Manager::checkSequence(const TQString& seq, const TQString& skip) {
+ for(TQValueList<TQString>::iterator i = m_watchedKeySequencesList.begin(); i != m_watchedKeySequencesList.end(); ++i) {
if((*i) == skip) {
continue;
}
if((*i).startsWith(seq)) {
- return (*i == seq) ? qMakePair<int, QString>(1, seq) : qMakePair<int, QString>(2, *i);
+ return (*i == seq) ? tqMakePair<int, TQString>(1, seq) : tqMakePair<int, TQString>(2, *i);
}
if(!(*i).isEmpty() && seq.startsWith(*i)) {
- return qMakePair<int, QString>(3, *i);
+ return tqMakePair<int, TQString>(3, *i);
}
}
- return qMakePair<int, QString>(0, QString());
+ return tqMakePair<int, TQString>(0, TQString());
}
-Recorder::Recorder(Kate::View *view, Manager *manager) : QObject(view), m_manager(manager), m_view(view) {
- connect(m_manager, SIGNAL(watchedKeySequencesChanged()), this, SLOT(reloadWatchedKeySequences()));
- connect(this, SIGNAL(detectedTypedKeySequence(const QString&)), m_manager, SLOT(keySequenceTyped(const QString&)));
+Recorder::Recorder(Kate::View *view, Manager *manager) : TQObject(view), m_manager(manager), m_view(view) {
+ connect(m_manager, TQT_SIGNAL(watchedKeySequencesChanged()), this, TQT_SLOT(reloadWatchedKeySequences()));
+ connect(this, TQT_SIGNAL(detectedTypedKeySequence(const TQString&)), m_manager, TQT_SLOT(keySequenceTyped(const TQString&)));
m_view->cursorPositionReal(&m_oldLine, &m_oldCol);
reloadWatchedKeySequences();
}
@@ -155,13 +155,13 @@ Recorder::Recorder(Kate::View *view, Manager *manager) : QObject(view), m_manage
Recorder::~Recorder() {
}
-bool Recorder::eventFilter(QObject* /* o */, QEvent *e) {
- if (e->type() == QEvent::KeyPress) {
- QKeyEvent *keyEvent = (QKeyEvent*)(e);
+bool Recorder::eventFilter(TQObject* /* o */, TQEvent *e) {
+ if (e->type() == TQEvent::KeyPress) {
+ TQKeyEvent *keyEvent = (TQKeyEvent*)(e);
uint curLine, curCol;
m_view->cursorPositionReal(&curLine, &curCol);
if(curLine != m_oldLine || m_oldCol+1 != curCol) {
- m_typedSequence = QString();
+ m_typedSequence = TQString();
m_oldLine = curLine;
m_oldCol = curCol;
}
@@ -177,12 +177,12 @@ bool Recorder::eventFilter(QObject* /* o */, QEvent *e) {
return false;
}
- bool Recorder::seekForKeySequence(const QString& s) {
+ bool Recorder::seekForKeySequence(const TQString& s) {
for(uint i = 0; i < s.length(); ++i) {
- QString toCheck = s.right(s.length() - i);
- if(m_watchedKeySequencesList.contains(toCheck) > 0) {
+ TQString toCheck = s.right(s.length() - i);
+ if(m_watchedKeySequencesList.tqcontains(toCheck) > 0) {
m_view->getDoc()->removeText(m_oldLine, m_oldCol-(s.length() - i - 1), m_oldLine, m_oldCol);
- m_typedSequence = QString::null; // clean m_typedSequence to avoid wrong action triggering if one presses keys without printable character
+ m_typedSequence = TQString(); // clean m_typedSequence to avoid wrong action triggering if one presses keys without printable character
emit detectedTypedKeySequence(toCheck);
return true;
}
@@ -193,7 +193,7 @@ bool Recorder::eventFilter(QObject* /* o */, QEvent *e) {
void Recorder::reloadWatchedKeySequences() {
m_watchedKeySequencesList = m_manager->getWatchedKeySequences();
m_maxSequenceLength = 0;
- for(QStringList::iterator i = m_watchedKeySequencesList.begin(); i != m_watchedKeySequencesList.end(); ++i) {
+ for(TQStringList::iterator i = m_watchedKeySequencesList.begin(); i != m_watchedKeySequencesList.end(); ++i) {
m_maxSequenceLength = MAX(m_maxSequenceLength, (*i).length());
}
if(m_maxSequenceLength < m_typedSequence.length()) {
@@ -207,8 +207,8 @@ bool Recorder::eventFilter(QObject* /* o */, QEvent *e) {
Action::~Action() {
}
- QString Action::getDescription() const {
- return QString();
+ TQString Action::getDescription() const {
+ return TQString();
}
ExecuteJScriptAction::ExecuteJScriptAction(KileJScript::JScript *jScript, KileJScript::Manager *jScriptManager) : m_jScript(jScript), m_jScriptManager(jScriptManager){
@@ -221,8 +221,8 @@ bool Recorder::eventFilter(QObject* /* o */, QEvent *e) {
m_jScriptManager->executeJScript(m_jScript);
}
- QString ExecuteJScriptAction::getDescription() const {
- return i18n("Script execution of %1").arg(m_jScript->getFileName());
+ TQString ExecuteJScriptAction::getDescription() const {
+ return i18n("Script execution of %1").tqarg(m_jScript->getFileName());
}
diff --git a/src/kile/editorkeysequencemanager.h b/src/kile/editorkeysequencemanager.h
index 51461cb..131168f 100644
--- a/src/kile/editorkeysequencemanager.h
+++ b/src/kile/editorkeysequencemanager.h
@@ -14,11 +14,11 @@
#ifndef EDITORKEYSEQUENCEMANAGER_H
#define EDITORKEYSEQUENCEMANAGER_H
-#include <qevent.h>
-#include <qmap.h>
-#include <qobject.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqevent.h>
+#include <tqmap.h>
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
// include <kaction.h>
#include <kate/view.h>
@@ -47,7 +47,7 @@ namespace KileEditorKeySequence {
/**
* Returns a textual representation of the action.
**/
- virtual QString getDescription() const;
+ virtual TQString getDescription() const;
};
/**
@@ -59,7 +59,7 @@ namespace KileEditorKeySequence {
virtual ~ExecuteJScriptAction();
virtual void execute();
- virtual QString getDescription() const;
+ virtual TQString getDescription() const;
protected:
KileJScript::JScript *m_jScript;
@@ -78,8 +78,9 @@ namespace KileEditorKeySequence {
* the cursor advance by one position, i.e. for example tabs are not allowed in key
* sequences.
**/
- class Manager : public QObject {
+ class Manager : public TQObject {
Q_OBJECT
+ TQ_OBJECT
friend class Recorder;
@@ -87,7 +88,7 @@ namespace KileEditorKeySequence {
/**
* Constructs a new manager object.
**/
- Manager(KileInfo* kileInfo, QObject *parent = 0, const char *name = 0);
+ Manager(KileInfo* kileInfo, TQObject *tqparent = 0, const char *name = 0);
virtual ~Manager();
/**
@@ -95,14 +96,14 @@ namespace KileEditorKeySequence {
* @param seq the key sequence
* @param action the action for the sequence
**/
- void addAction(const QString& seq, Action *action);
+ void addAction(const TQString& seq, Action *action);
/**
* Convenience method. Adds a key sequence-to-action map to this
* manager, removing any existing mappings.
* @warning This method overrides any exising mappings !
**/
- void addActionMap(const QMap<QString, Action*>& map);
+ void addActionMap(const TQMap<TQString, Action*>& map);
/**
* Removes all the mappings.
@@ -113,35 +114,35 @@ namespace KileEditorKeySequence {
* Returns a list of all the key sequences that are currently being
* watched.
**/
- const QStringList& getWatchedKeySequences();
+ const TQStringList& getWatchedKeySequences();
/**
* Returns the key sequence that corresponds to an action.
* @param a the action that is considered
**/
- QString getKeySequence(const Action* a);
+ TQString getKeySequence(const Action* a);
/**
* Returns the action that corresponds to a key sequence.
**/
- Action* getAction(const QString& seq);
+ Action* getAction(const TQString& seq);
/**
* Remove a key sequence, i.e. the key sequence is no longer watched.
* @param seq the key sequence that should be removed
**/
- void removeKeySequence(const QString& seq);
+ void removeKeySequence(const TQString& seq);
/**
* Convenience method. Removes every key sequence contained in the list.
- * @see removeKeySequence(const QString& seq)
+ * @see removeKeySequence(const TQString& seq)
**/
- void removeKeySequence(const QStringList& l);
+ void removeKeySequence(const TQStringList& l);
/**
* @warning not implemented yet !
**/
- void setEditorKeySequence(const QString& seq, Action *action);
+ void setEditorKeySequence(const TQString& seq, Action *action);
/**
* Checks whether the sequence "seq" is already assigned to an action.
@@ -151,7 +152,7 @@ namespace KileEditorKeySequence {
* @return "true" if and only the sequence "seq" or another sequence
* that starts with "seq" is assigned to an action
**/
- bool isSequenceAssigned(const QString& seq) const;
+ bool isSequenceAssigned(const TQString& seq) const;
/**
* Performs a few checks on a key sequence.
@@ -162,9 +163,9 @@ namespace KileEditorKeySequence {
* stored
*
* in the second component: a string that corresponds to one
- * of the previous cases (in the case 0: QString())
+ * of the previous cases (in the case 0: TQString())
**/
- QPair<int, QString> checkSequence(const QString& seq, const QString& skip = QString());
+ TQPair<int, TQString> checkSequence(const TQString& seq, const TQString& skip = TQString());
signals:
/**
@@ -177,20 +178,21 @@ namespace KileEditorKeySequence {
* Signalises to the manager that a (watched) sequence has been typed.
* @param seq the sequence that has been typed
**/
- void keySequenceTyped(const QString& seq);
+ void keySequenceTyped(const TQString& seq);
protected:
KileInfo *m_kileInfo;
- QMap<QString, Action*> m_actionMap;
- QStringList m_watchedKeySequencesList;
+ TQMap<TQString, Action*> m_actionMap;
+ TQStringList m_watchedKeySequencesList;
};
/**
* This class keeps track of the characters that are typed. It is used in
* conjunction with a Kate view and a KileEditorKeySequence::Manager.
**/
- class Recorder : public QObject {
+ class Recorder : public TQObject {
Q_OBJECT
+ TQ_OBJECT
public:
Recorder(Kate::View *view, Manager *manager);
virtual ~Recorder();
@@ -200,7 +202,7 @@ namespace KileEditorKeySequence {
* Emitted whenever a key sequence that is currently watched has
* been typed.
**/
- void detectedTypedKeySequence(const QString& seq);
+ void detectedTypedKeySequence(const TQString& seq);
public slots:
@@ -211,19 +213,19 @@ namespace KileEditorKeySequence {
protected:
Manager *m_manager;
- QString m_typedSequence;
+ TQString m_typedSequence;
uint m_maxSequenceLength;
uint m_oldCol, m_oldLine;
Kate::View* m_view;
- QStringList m_watchedKeySequencesList;
+ TQStringList m_watchedKeySequencesList;
- virtual bool eventFilter(QObject *o, QEvent *e);
+ virtual bool eventFilter(TQObject *o, TQEvent *e);
/**
* Checks whether a key sequence is currently watched.
* @param s the key sequence that should be checked
**/
- bool seekForKeySequence(const QString& s);
+ bool seekForKeySequence(const TQString& s);
};
}
diff --git a/src/kile/envconfigwidget.ui b/src/kile/envconfigwidget.ui
index 792fb33..da30fd4 100644
--- a/src/kile/envconfigwidget.ui
+++ b/src/kile/envconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetEnvironmentConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetEnvironmentConfig</cstring>
</property>
@@ -19,7 +19,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_bgEnv</cstring>
</property>
@@ -38,7 +38,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_CompleteEnvironment</cstring>
</property>
@@ -48,7 +48,7 @@
</widget>
</vbox>
</widget>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_bgGraphics</cstring>
</property>
@@ -59,7 +59,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_envIndentation</cstring>
</property>
@@ -70,7 +70,7 @@
<string>Enable auto indentation of environments.</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_envIndentSpaces</cstring>
</property>
@@ -81,15 +81,15 @@
<string>Use spaces instead of a tabulator to autoindent environments.</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout2</cstring>
+ <cstring>tqlayout2</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>m_lbNumSpaces</cstring>
</property>
@@ -110,14 +110,14 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QSpinBox">
+ <widget class="TQSpinBox">
<property name="name">
<cstring>kcfg_envIndentNumSpaces</cstring>
</property>
@@ -129,7 +129,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -155,7 +155,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>300</width>
<height>20</height>
@@ -168,5 +168,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/src/kile/floatdialog.cpp b/src/kile/floatdialog.cpp
index e515d70..3bac29e 100644
--- a/src/kile/floatdialog.cpp
+++ b/src/kile/floatdialog.cpp
@@ -16,9 +16,9 @@
#include "floatdialog.h"
-#include <qlayout.h>
-#include <qbuttongroup.h>
-#include <qregexp.h>
+#include <tqlayout.h>
+#include <tqbuttongroup.h>
+#include <tqregexp.h>
#include <klocale.h>
#include "kiledebug.h"
@@ -28,66 +28,66 @@
namespace KileDialog
{
-FloatEnvironmentDialog::FloatEnvironmentDialog(KConfig *config, KileInfo *ki, QWidget *parent)
- : Wizard(config,parent), m_ki(ki)
+FloatEnvironmentDialog::FloatEnvironmentDialog(KConfig *config, KileInfo *ki, TQWidget *tqparent)
+ : Wizard(config,tqparent), m_ki(ki)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- QGridLayout *grid = new QGridLayout(page, 6,2, 8,8);
+ TQGridLayout *grid = new TQGridLayout(page, 6,2, 8,8);
// environment groupbox
- QButtonGroup *egroup = new QButtonGroup( i18n("Environment"),page);
+ TQButtonGroup *egroup = new TQButtonGroup( i18n("Environment"),page);
egroup->setColumnLayout(0, Qt::Vertical );
- egroup->layout()->setSpacing( 6 );
- egroup->layout()->setMargin( 11 );
- QGridLayout *egrouplayout = new QGridLayout( egroup->layout() );
- egrouplayout->setAlignment( Qt::AlignTop );
+ egroup->tqlayout()->setSpacing( 6 );
+ egroup->tqlayout()->setMargin( 11 );
+ TQGridLayout *egrouptqlayout = new TQGridLayout( egroup->tqlayout() );
+ egrouptqlayout->tqsetAlignment( TQt::AlignTop );
- m_rbFigure = new QRadioButton(i18n("&Figure"), egroup);
- m_rbTable = new QRadioButton(i18n("T&able"), egroup);
+ m_rbFigure = new TQRadioButton(i18n("&Figure"), egroup);
+ m_rbTable = new TQRadioButton(i18n("T&able"), egroup);
- egrouplayout->addWidget( m_rbFigure, 0,0 );
- egrouplayout->addWidget( m_rbTable, 0,1 );
+ egrouptqlayout->addWidget( m_rbFigure, 0,0 );
+ egrouptqlayout->addWidget( m_rbTable, 0,1 );
// position groupbox
- QButtonGroup *pgroup = new QButtonGroup( i18n("Position"),page);
+ TQButtonGroup *pgroup = new TQButtonGroup( i18n("Position"),page);
pgroup->setColumnLayout(0, Qt::Vertical );
- pgroup->layout()->setSpacing( 6 );
- pgroup->layout()->setMargin( 11 );
- QGridLayout *pgrouplayout = new QGridLayout( pgroup->layout() );
- pgrouplayout->setAlignment( Qt::AlignTop );
-
- QLabel *label1 = new QLabel(i18n("Here exact:"), pgroup);
- QLabel *label2 = new QLabel(i18n("Top of page:"), pgroup);
- QLabel *label3 = new QLabel(i18n("Bottom of page:"), pgroup);
- QLabel *label4 = new QLabel(i18n("Extra page:"), pgroup);
- m_cbHere = new QCheckBox(pgroup);
- m_cbTop = new QCheckBox(pgroup);
- m_cbBottom = new QCheckBox(pgroup);
- m_cbPage = new QCheckBox(pgroup);
-
- pgrouplayout->addWidget( label1, 0,0 );
- pgrouplayout->addWidget( label2, 1,0 );
- pgrouplayout->addWidget( label3, 0,2 );
- pgrouplayout->addWidget( label4, 1,2 );
- pgrouplayout->addWidget( m_cbHere, 0,1 );
- pgrouplayout->addWidget( m_cbTop, 1,1 );
- pgrouplayout->addWidget( m_cbBottom, 0,3 );
- pgrouplayout->addWidget( m_cbPage, 1,3 );
+ pgroup->tqlayout()->setSpacing( 6 );
+ pgroup->tqlayout()->setMargin( 11 );
+ TQGridLayout *pgrouptqlayout = new TQGridLayout( pgroup->tqlayout() );
+ pgrouptqlayout->tqsetAlignment( TQt::AlignTop );
+
+ TQLabel *label1 = new TQLabel(i18n("Here exact:"), pgroup);
+ TQLabel *label2 = new TQLabel(i18n("Top of page:"), pgroup);
+ TQLabel *label3 = new TQLabel(i18n("Bottom of page:"), pgroup);
+ TQLabel *label4 = new TQLabel(i18n("Extra page:"), pgroup);
+ m_cbHere = new TQCheckBox(pgroup);
+ m_cbTop = new TQCheckBox(pgroup);
+ m_cbBottom = new TQCheckBox(pgroup);
+ m_cbPage = new TQCheckBox(pgroup);
+
+ pgrouptqlayout->addWidget( label1, 0,0 );
+ pgrouptqlayout->addWidget( label2, 1,0 );
+ pgrouptqlayout->addWidget( label3, 0,2 );
+ pgrouptqlayout->addWidget( label4, 1,2 );
+ pgrouptqlayout->addWidget( m_cbHere, 0,1 );
+ pgrouptqlayout->addWidget( m_cbTop, 1,1 );
+ pgrouptqlayout->addWidget( m_cbBottom, 0,3 );
+ pgrouptqlayout->addWidget( m_cbPage, 1,3 );
// center environment
- QLabel *label5 = new QLabel(i18n("Center:"),page);
- m_cbCenter = new QCheckBox(page);
+ TQLabel *label5 = new TQLabel(i18n("Center:"),page);
+ m_cbCenter = new TQCheckBox(page);
// Caption
- QLabel *label6 = new QLabel(i18n("Ca&ption:"),page);
+ TQLabel *label6 = new TQLabel(i18n("Ca&ption:"),page);
m_edCaption = new KLineEdit("",page);
m_edCaption->setMinimumWidth(300);
label6->setBuddy(m_edCaption);
// Label
- QLabel *label7 = new QLabel(i18n("&Label:"),page);
+ TQLabel *label7 = new TQLabel(i18n("&Label:"),page);
m_edLabel = new KLineEdit("",page);
m_edLabel->setMinimumWidth(300);
label7->setBuddy(m_edLabel);
@@ -117,8 +117,8 @@ FloatEnvironmentDialog::FloatEnvironmentDialog(KConfig *config, KileInfo *ki, QW
setFocusProxy( m_edCaption );
// signals and slots
- connect(m_rbFigure, SIGNAL(clicked()), this, SLOT(slotEnvironmentClicked()));
- connect(m_rbTable, SIGNAL(clicked()), this, SLOT(slotEnvironmentClicked()));
+ connect(m_rbFigure, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotEnvironmentClicked()));
+ connect(m_rbTable, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotEnvironmentClicked()));
}
@@ -126,10 +126,10 @@ FloatEnvironmentDialog::FloatEnvironmentDialog(KConfig *config, KileInfo *ki, QW
void FloatEnvironmentDialog::slotOk()
{
- QString envname = ( m_rbFigure->isChecked() ) ? "figure" : "table";
- QString indent = m_ki->editorExtension()->autoIndentEnvironment();
+ TQString envname = ( m_rbFigure->isChecked() ) ? "figure" : "table";
+ TQString indent = m_ki->editorExtension()->autoIndentEnvironment();
- QString position;
+ TQString position;
if ( m_cbHere->isChecked() )
position += 'h';
if ( m_cbTop->isChecked() )
@@ -152,11 +152,11 @@ void FloatEnvironmentDialog::slotOk()
m_td.tagEnd = indent + '\n';
- QString caption = m_edCaption->text();
+ TQString caption = m_edCaption->text();
if ( ! caption.isEmpty() )
m_td.tagEnd += indent + "\\caption{" + caption + "}\n";
- QString label = m_edLabel->text();
+ TQString label = m_edLabel->text();
if ( !label.isEmpty() && label!=m_prefix )
m_td.tagEnd += indent + "\\label{" + label + "}\n";
@@ -170,7 +170,7 @@ void FloatEnvironmentDialog::slotOk()
void FloatEnvironmentDialog::slotEnvironmentClicked()
{
- QString caption,oldprefix;
+ TQString caption,oldprefix;
if ( m_rbFigure->isChecked() ) {
caption = i18n("Figure Environment");
@@ -183,8 +183,8 @@ void FloatEnvironmentDialog::slotEnvironmentClicked()
}
setCaption(caption);
- QString s = m_edLabel->text();
- s.replace( QRegExp(oldprefix),m_prefix);
+ TQString s = m_edLabel->text();
+ s.tqreplace( TQRegExp(oldprefix),m_prefix);
m_edLabel->setText(s);
}
diff --git a/src/kile/floatdialog.h b/src/kile/floatdialog.h
index 67acced..19bf9ba 100644
--- a/src/kile/floatdialog.h
+++ b/src/kile/floatdialog.h
@@ -20,9 +20,9 @@
#include "kilewizard.h"
#include <klineedit.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qradiobutton.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqradiobutton.h>
#include "kileinfo.h"
@@ -32,9 +32,10 @@ namespace KileDialog
class FloatEnvironmentDialog : public Wizard
{
Q_OBJECT
+ TQ_OBJECT
public:
- FloatEnvironmentDialog(KConfig *config, KileInfo *ki, QWidget *parent);
+ FloatEnvironmentDialog(KConfig *config, KileInfo *ki, TQWidget *tqparent);
~FloatEnvironmentDialog() {}
public slots:
@@ -45,11 +46,11 @@ private slots:
private:
KLineEdit *m_edLabel, *m_edCaption;
- QRadioButton *m_rbFigure, *m_rbTable;
- QCheckBox *m_cbHere,*m_cbTop,*m_cbBottom,*m_cbPage;
- QCheckBox *m_cbCenter;
+ TQRadioButton *m_rbFigure, *m_rbTable;
+ TQCheckBox *m_cbHere,*m_cbTop,*m_cbBottom,*m_cbPage;
+ TQCheckBox *m_cbCenter;
- QString m_prefix;
+ TQString m_prefix;
KileInfo *m_ki;
};
diff --git a/src/kile/generalconfigwidget.ui b/src/kile/generalconfigwidget.ui
index 30a88d9..99fb772 100644
--- a/src/kile/generalconfigwidget.ui
+++ b/src/kile/generalconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetGeneralConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetGeneralConfig</cstring>
</property>
@@ -20,7 +20,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox5</cstring>
</property>
@@ -44,7 +44,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox" row="1" column="0" rowspan="1" colspan="2">
+ <widget class="TQCheckBox" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>kcfg_Restore</cstring>
</property>
@@ -52,7 +52,7 @@
<string>&amp;Reopen files and projects on startup</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel2_2</cstring>
</property>
@@ -63,14 +63,14 @@
<cstring>kcfg_DefaultProjectLocation</cstring>
</property>
</widget>
- <widget class="QLineEdit" row="0" column="1">
+ <widget class="TQLineEdit" row="0" column="1">
<property name="name">
<cstring>kcfg_DefaultProjectLocation</cstring>
</property>
</widget>
</grid>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -89,7 +89,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_Autosave</cstring>
</property>
@@ -97,15 +97,15 @@
<string>Auto&amp;save</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout2</cstring>
+ <cstring>tqlayout2</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -131,7 +131,7 @@
</widget>
</hbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox3</cstring>
</property>
@@ -157,7 +157,7 @@
<cstring>kcfg_DocumentClassOptions</cstring>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel3</cstring>
</property>
@@ -168,7 +168,7 @@
<cstring>kcfg_Author</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>textLabel4</cstring>
</property>
@@ -179,7 +179,7 @@
<cstring>kcfg_DocumentClassOptions</cstring>
</property>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>textLabel5</cstring>
</property>
@@ -192,7 +192,7 @@
</widget>
</grid>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox4</cstring>
</property>
@@ -203,7 +203,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_CleanUpAfterClose</cstring>
</property>
@@ -218,7 +218,7 @@
</widget>
</vbox>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_UnfoldConfigTree</cstring>
</property>
@@ -229,7 +229,7 @@
<string>It's impossible to open special tree items in Kile's configuration dialog. You have the choice to open all items, which may lead to a bad size of the dialog, or none of them.</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_RunLyxServer</cstring>
</property>
@@ -239,7 +239,7 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>knuminput.h</includehint>
<includehint>knuminput.h</includehint>
diff --git a/src/kile/graphicsconfigwidget.ui b/src/kile/graphicsconfigwidget.ui
index ce225b6..c3b76b0 100644
--- a/src/kile/graphicsconfigwidget.ui
+++ b/src/kile/graphicsconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetGraphicsConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetGraphicsConfig</cstring>
</property>
@@ -19,7 +19,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_bgGraphics</cstring>
</property>
@@ -30,7 +30,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_tlResolution</cstring>
</property>
@@ -46,7 +46,7 @@
<cstring>kcfg_resolution</cstring>
</property>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>m_tlBbox</cstring>
</property>
@@ -57,7 +57,7 @@
<cstring>kcfg_boundingbox</cstring>
</property>
</widget>
- <widget class="QLabel" row="4" column="0">
+ <widget class="TQLabel" row="4" column="0">
<property name="name">
<cstring>m_tlImageMagick</cstring>
</property>
@@ -65,7 +65,7 @@
<string>ImageMagick:</string>
</property>
</widget>
- <widget class="QLabel" row="1" column="1">
+ <widget class="TQLabel" row="1" column="1">
<property name="name">
<cstring>m_tlResolutionHelp</cstring>
</property>
@@ -81,7 +81,7 @@
<string>(used when the picture offers no resolution)</string>
</property>
</widget>
- <widget class="QCheckBox" row="2" column="1">
+ <widget class="TQCheckBox" row="2" column="1">
<property name="name">
<cstring>kcfg_boundingbox</cstring>
</property>
@@ -89,7 +89,7 @@
<string>Tr&amp;y to determine from the picture</string>
</property>
</widget>
- <widget class="QLabel" row="3" column="1">
+ <widget class="TQLabel" row="3" column="1">
<property name="name">
<cstring>m_tlBBoxHelp</cstring>
</property>
@@ -97,7 +97,7 @@
<string>(you have to install the ImageMagick package to use this option)</string>
</property>
</widget>
- <widget class="QLabel" row="4" column="1">
+ <widget class="TQLabel" row="4" column="1">
<property name="name">
<cstring>m_lbImagemagick</cstring>
</property>
@@ -120,14 +120,14 @@
<variable access="private">KConfig *m_config;</variable>
<variable access="private">KileDocument::LatexCommands *m_commands;</variable>
</variables>
-<slots>
+<Q_SLOTS>
<slot access="private" specifier="non virtual">slotConfigure()</slot>
-</slots>
+</Q_SLOTS>
<functions>
<function access="private" specifier="non virtual">init()</function>
<function specifier="non virtual">setLatexCommands( KConfig * config, KileDocument::LatexCommands * commands )</function>
</functions>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
</includehints>
diff --git a/src/kile/helpconfigwidget.ui b/src/kile/helpconfigwidget.ui
index 2588736..f6d7699 100644
--- a/src/kile/helpconfigwidget.ui
+++ b/src/kile/helpconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetHelpConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetHelpConfig</cstring>
</property>
@@ -19,7 +19,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbLocation</cstring>
</property>
@@ -38,14 +38,14 @@
<cstring>kcfg_location</cstring>
</property>
</widget>
- <widget class="QButtonGroup" row="1" column="0" rowspan="1" colspan="2">
+ <widget class="TQButtonGroup" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>kcfg_use</cstring>
</property>
<property name="title">
<string>Context Sensitive Help</string>
</property>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>m_rbTeTeX</cstring>
</property>
@@ -64,7 +64,7 @@
<number>1</number>
</property>
</widget>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>m_rbKileRef</cstring>
</property>
@@ -84,14 +84,14 @@
</property>
</widget>
</widget>
- <widget class="QButtonGroup" row="2" column="0" rowspan="1" colspan="2">
+ <widget class="TQButtonGroup" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>kcfg_embedded</cstring>
</property>
<property name="title">
<string>User Help</string>
</property>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>m_rbEmbedded</cstring>
</property>
@@ -107,7 +107,7 @@
<string>Use &amp;embedded viewer</string>
</property>
</widget>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>m_rbExternal</cstring>
</property>
@@ -126,7 +126,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>m_pbConfigure</cstring>
</property>
@@ -165,13 +165,13 @@
<variables>
<variable access="private">KileHelp::Help *m_help;</variable>
</variables>
-<slots>
+<Q_SLOTS>
<slot access="private" specifier="nicht virtual">slotConfigure()</slot>
-</slots>
+</Q_SLOTS>
<functions>
<function specifier="non virtual">setHelp( KileHelp::Help * help )</function>
</functions>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
</includehints>
diff --git a/src/kile/helpconfigwidget.ui.h b/src/kile/helpconfigwidget.ui.h
index 7403127..100e19f 100644
--- a/src/kile/helpconfigwidget.ui.h
+++ b/src/kile/helpconfigwidget.ui.h
@@ -2,7 +2,7 @@
** ui.h extension file, included from the uic-generated form implementation.
**
** If you want to add, delete, or rename functions or slots, use
-** Qt Designer to update this file, preserving your code.
+** TQt Designer to update this file, preserving your code.
**
** You should not define a constructor or destructor in this file.
** Instead, write your code in functions called init() and destroy().
diff --git a/src/kile/includegraphicsdialog.cpp b/src/kile/includegraphicsdialog.cpp
index 1cfd825..4bec98e 100644
--- a/src/kile/includegraphicsdialog.cpp
+++ b/src/kile/includegraphicsdialog.cpp
@@ -16,14 +16,14 @@
#include "includegraphicsdialog.h"
-#include <qregexp.h>
-#include <qfileinfo.h>
-#include <qgroupbox.h>
-#include <qvgroupbox.h>
-#include <qlayout.h>
-#include <qpixmap.h>
-#include <qcheckbox.h>
-#include <qlabel.h>
+#include <tqregexp.h>
+#include <tqfileinfo.h>
+#include <tqgroupbox.h>
+#include <tqvgroupbox.h>
+#include <tqlayout.h>
+#include <tqpixmap.h>
+#include <tqcheckbox.h>
+#include <tqlabel.h>
#include <klocale.h>
#include <kfiledialog.h>
@@ -41,8 +41,8 @@
namespace KileDialog
{
-IncludeGraphics::IncludeGraphics(QWidget *parent, const QString &startdir, KileInfo *ki) :
- KDialogBase( Plain, i18n("Include Graphics"), Ok | Cancel, Ok, parent, 0, true, true),
+IncludeGraphics::IncludeGraphics(TQWidget *tqparent, const TQString &startdir, KileInfo *ki) :
+ KDialogBase( Plain, i18n("Include Graphics"), Ok | Cancel, Ok, tqparent, 0, true, true),
m_startdir(startdir),
m_width(0),
m_height(0),
@@ -50,19 +50,19 @@ IncludeGraphics::IncludeGraphics(QWidget *parent, const QString &startdir, KileI
m_proc(0)
{
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(plainPage(), 6,6 );
+ TQVBoxLayout *vbox = new TQVBoxLayout(plainPage(), 6,6 );
// first groupbox: choose picture
- QVGroupBox* group= new QVGroupBox(i18n("File"), plainPage());
+ TQVGroupBox* group= new TQVGroupBox(i18n("File"), plainPage());
- QWidget *widget = new QWidget(group);
- QGridLayout *grid = new QGridLayout( widget, 4,3, 6,6, "");
+ TQWidget *widget = new TQWidget(group);
+ TQGridLayout *grid = new TQGridLayout( widget, 4,3, 6,6, "");
grid->addRowSpacing( 0, fontMetrics().lineSpacing() );
grid->addColSpacing( 0, fontMetrics().lineSpacing() );
grid->setColStretch(1,1);
- // line 1: QLabel
- QLabel *label1 = new QLabel(i18n("Picture:"), widget);
+ // line 1: TQLabel
+ TQLabel *label1 = new TQLabel(i18n("Picture:"), widget);
grid->addWidget( label1, 0,0 );
// line 1: KLineEdit
@@ -74,24 +74,24 @@ IncludeGraphics::IncludeGraphics(QWidget *parent, const QString &startdir, KileI
KPushButton *pb_choose = new KPushButton("", widget, "filechooser_button" );
pb_choose->setPixmap( SmallIcon("fileopen") );
- pb_choose->setFixedWidth(pb_choose->sizeHint().width()); // set width
- grid->addRowSpacing( 0, pb_choose->sizeHint().height()+5 ); // update height of line
+ pb_choose->setFixedWidth(pb_choose->tqsizeHint().width()); // set width
+ grid->addRowSpacing( 0, pb_choose->tqsizeHint().height()+5 ); // update height of line
grid->addWidget(pb_choose,0,2);
// line 2: some (more or less useful) information
- QLabel *label2 = new QLabel(i18n("Info:"), widget);
- infolabel = new QLabel("---", widget);
+ TQLabel *label2 = new TQLabel(i18n("Info:"), widget);
+ infolabel = new TQLabel("---", widget);
grid->addWidget( label2, 1,0 );
grid->addWidget( infolabel, 1,1 );
// line 3: some output options
- QLabel *label3 = new QLabel(i18n("Output:"), widget);
+ TQLabel *label3 = new TQLabel(i18n("Output:"), widget);
- QWidget *cb_widget = new QWidget(widget);
- QGridLayout *cb_grid = new QGridLayout( cb_widget, 1,2, 0,0,"");
- cb_center = new QCheckBox(i18n("Center picture"),cb_widget);
- cb_pdftex = new QCheckBox(i18n("pdftex/pdflatex"),cb_widget);
+ TQWidget *cb_widget = new TQWidget(widget);
+ TQGridLayout *cb_grid = new TQGridLayout( cb_widget, 1,2, 0,0,"");
+ cb_center = new TQCheckBox(i18n("Center picture"),cb_widget);
+ cb_pdftex = new TQCheckBox(i18n("pdftex/pdflatex"),cb_widget);
cb_grid->addWidget(cb_center,0,0);
cb_grid->addWidget(cb_pdftex,0,1);
@@ -99,45 +99,45 @@ IncludeGraphics::IncludeGraphics(QWidget *parent, const QString &startdir, KileI
grid->addWidget( cb_widget, 2,1 );
// line 4: graphics path
- QLabel *label5 = new QLabel(i18n("Path:"), widget);
- cb_graphicspath = new QCheckBox(i18n("Use \\graphicspath command of LaTeX"),widget);
+ TQLabel *label5 = new TQLabel(i18n("Path:"), widget);
+ cb_graphicspath = new TQCheckBox(i18n("Use \\graphicspath command of LaTeX"),widget);
grid->addWidget( label5, 3,0 );
grid->addWidget( cb_graphicspath, 3,1 );
// second groupbox: options
- QVGroupBox* gb_opt= new QVGroupBox(i18n("Options"), plainPage());
- QWidget *widget_opt = new QWidget(gb_opt);
- QGridLayout *grid_opt = new QGridLayout( widget_opt, 2,4, 6,6, "");
-
- QLabel *label7 = new QLabel(i18n("Width:"), widget_opt);
- QLabel *label8 = new QLabel(i18n("Height:"),widget_opt);
- QLabel *label9 = new QLabel(i18n("Angle:"), widget_opt);
- QLabel *label10= new QLabel(i18n("Bounding box:"), widget_opt);
+ TQVGroupBox* gb_opt= new TQVGroupBox(i18n("Options"), plainPage());
+ TQWidget *widget_opt = new TQWidget(gb_opt);
+ TQGridLayout *grid_opt = new TQGridLayout( widget_opt, 2,4, 6,6, "");
+
+ TQLabel *label7 = new TQLabel(i18n("Width:"), widget_opt);
+ TQLabel *label8 = new TQLabel(i18n("Height:"),widget_opt);
+ TQLabel *label9 = new TQLabel(i18n("Angle:"), widget_opt);
+ TQLabel *label10= new TQLabel(i18n("Bounding box:"), widget_opt);
edit_width = new KLineEdit("",widget_opt);
edit_height = new KLineEdit("",widget_opt);
edit_angle = new KLineEdit("",widget_opt);
edit_bb = new KLineEdit("",widget_opt);
- grid_opt->addWidget( label7, 0,0, Qt::AlignRight );
+ grid_opt->addWidget( label7, 0,0, TQt::AlignRight );
grid_opt->addWidget( edit_width, 0,1 );
- grid_opt->addWidget( label9, 0,2, Qt::AlignRight );
+ grid_opt->addWidget( label9, 0,2, TQt::AlignRight );
grid_opt->addWidget( edit_angle, 0,3 );
- grid_opt->addWidget( label8, 1,0, Qt::AlignRight );
+ grid_opt->addWidget( label8, 1,0, TQt::AlignRight );
grid_opt->addWidget( edit_height, 1,1 );
- grid_opt->addWidget( label10, 1,2, Qt::AlignRight );
+ grid_opt->addWidget( label10, 1,2, TQt::AlignRight );
grid_opt->addWidget( edit_bb, 1,3 );
// third groupbox: figure environment
- QGroupBox *gb_fig= new QGroupBox(2,Qt::Horizontal,i18n("Figure Environment"), plainPage());
- QWidget *widget_fig = new QWidget(gb_fig);
- QGridLayout *grid_fig = new QGridLayout( widget_fig, 3,2, 6,6, "");
-
- QLabel *label4 = new QLabel(i18n("Figure:"), widget_fig);
- lb_label = new QLabel(i18n("Label:"), widget_fig);
- lb_caption = new QLabel(i18n("Caption:"), widget_fig);
- cb_figure = new QCheckBox(i18n("Use figure environment"),widget_fig);
+ TQGroupBox *gb_fig= new TQGroupBox(2,Qt::Horizontal,i18n("Figure Environment"), plainPage());
+ TQWidget *widget_fig = new TQWidget(gb_fig);
+ TQGridLayout *grid_fig = new TQGridLayout( widget_fig, 3,2, 6,6, "");
+
+ TQLabel *label4 = new TQLabel(i18n("Figure:"), widget_fig);
+ lb_label = new TQLabel(i18n("Label:"), widget_fig);
+ lb_caption = new TQLabel(i18n("Caption:"), widget_fig);
+ cb_figure = new TQCheckBox(i18n("Use figure environment"),widget_fig);
edit_label = new KLineEdit("fig:",widget_fig);
edit_caption = new KLineEdit("",widget_fig);
@@ -148,7 +148,7 @@ IncludeGraphics::IncludeGraphics(QWidget *parent, const QString &startdir, KileI
grid_fig->addWidget( lb_caption,2,0);
grid_fig->addWidget( edit_caption, 2,1);
- // add to layout
+ // add to tqlayout
vbox->addWidget(group);
vbox->addWidget(gb_opt);
vbox->addWidget(gb_fig);
@@ -159,8 +159,8 @@ IncludeGraphics::IncludeGraphics(QWidget *parent, const QString &startdir, KileI
updateFigure();
// connect
- connect( pb_choose, SIGNAL( clicked() ), this, SLOT( chooseFile() ) );
- connect( cb_figure, SIGNAL(clicked()), this, SLOT(updateFigure() ) );
+ connect( pb_choose, TQT_SIGNAL( clicked() ), this, TQT_SLOT( chooseFile() ) );
+ connect( cb_figure, TQT_SIGNAL(clicked()), this, TQT_SLOT(updateFigure() ) );
setFocusProxy( edit_file );
}
@@ -206,14 +206,14 @@ void IncludeGraphics::updateFigure()
////////////////////////////// determine the whole tag //////////////////////////////
-QString IncludeGraphics::getTemplate()
+TQString IncludeGraphics::getTemplate()
{
- QString s;
+ TQString s;
// state of figure and center checkbox
bool figure = cb_figure->isChecked();
bool center = cb_center->isChecked();
- QString indent = ( figure || center ) ? m_ki->editorExtension()->autoIndentEnvironment() : QString::null;
+ TQString indent = ( figure || center ) ? m_ki->editorExtension()->autoIndentEnvironment() : TQString();
// add start of figure environment ?
if ( figure )
@@ -232,19 +232,19 @@ QString IncludeGraphics::getTemplate()
s += indent + "\\includegraphics";
// add some options
- QString options = getOptions();
+ TQString options = getOptions();
if ( !options.isEmpty() )
s += '[' + options + ']';
// add name of picture
// either take the filename or try to take the relative part of the name
- QString filename = ( cb_graphicspath->isChecked() )
- ? QFileInfo(edit_file->text()).fileName()
- : m_ki->relativePath(QFileInfo(m_ki->getCompileName()).dirPath(), edit_file->text());
+ TQString filename = ( cb_graphicspath->isChecked() )
+ ? TQFileInfo(edit_file->text()).fileName()
+ : m_ki->relativePath(TQFileInfo(m_ki->getCompileName()).dirPath(), edit_file->text());
s += '{' + filename + "}\n";
// add some comments (depending of given resolution, this may be wrong!)
- QString info = getInfo();
+ TQString info = getInfo();
if (info.length() > 0)
s += indent + info + '\n';
@@ -255,10 +255,10 @@ QString IncludeGraphics::getTemplate()
// close figure environment ?
if ( figure )
{
- QString caption = edit_caption->text().stripWhiteSpace();
+ TQString caption = edit_caption->text().stripWhiteSpace();
if ( !caption.isEmpty() )
s += indent + "\\caption{" + caption + "}\n";
- QString label = edit_label->text().stripWhiteSpace();
+ TQString label = edit_label->text().stripWhiteSpace();
if ( !label.isEmpty() && label!="fig:" )
s += indent + "\\label{" + label + "}\n";
s += "\\end{figure}\n";
@@ -267,16 +267,16 @@ QString IncludeGraphics::getTemplate()
return s;
}
-QString IncludeGraphics::getFilename()
+TQString IncludeGraphics::getFilename()
{
return edit_file->text();
}
////////////////////////////// some calculations //////////////////////////////
-QString IncludeGraphics::getOptions()
+TQString IncludeGraphics::getOptions()
{
- QString s = "";
+ TQString s = "";
if ( ! edit_width->text().isEmpty() )
s += ",width=" + edit_width->text();
@@ -300,9 +300,9 @@ QString IncludeGraphics::getOptions()
////////////////////////////// graphics info //////////////////////////////
-QString IncludeGraphics::getInfo()
+TQString IncludeGraphics::getInfo()
{
- QString wcm,hcm,dpi;
+ TQString wcm,hcm,dpi;
int wpx=0,hpx=0;
bool ok = getPictureSize(wpx,hpx,dpi,wcm,hcm);
@@ -310,10 +310,10 @@ QString IncludeGraphics::getInfo()
return "";
else
{
- QFileInfo fi( edit_file->text() );
+ TQFileInfo fi( edit_file->text() );
return "% " + fi.baseName() + '.' + fi.extension(true)
- + QString(": %1x%2 pixel").arg(wpx).arg(hpx)
+ + TQString(": %1x%2 pixel").tqarg(wpx).tqarg(hpx)
+ ", " + dpi + "dpi"
+ ", " + wcm + 'x' + hcm + " cm"
+ ", bb=" + edit_bb->text();
@@ -322,13 +322,13 @@ QString IncludeGraphics::getInfo()
void IncludeGraphics::setInfo()
{
- QString text;
- QString wcm,hcm,dpi;
+ TQString text;
+ TQString wcm,hcm,dpi;
int wpx,hpx;
if ( !edit_file->text().isEmpty() && getPictureSize(wpx,hpx,dpi,wcm,hcm) )
{
- text = QString("%1x%2 pixel").arg(wpx).arg(hpx)
+ text = TQString("%1x%2 pixel").tqarg(wpx).tqarg(hpx)
+ " / " + wcm + 'x' + hcm + " cm"
+ " (" + dpi + "dpi)";
}
@@ -339,12 +339,12 @@ void IncludeGraphics::setInfo()
infolabel->setText(text);
}
-bool IncludeGraphics::getPictureSize(int &wpx, int &hpx, QString &dpi, QString &wcm, QString &hcm)
+bool IncludeGraphics::getPictureSize(int &wpx, int &hpx, TQString &dpi, TQString &wcm, TQString &hcm)
{
wpx = m_width;
hpx = m_height;
- dpi = QString("%1").arg((int)(m_resolution+0.5));
+ dpi = TQString("%1").tqarg((int)(m_resolution+0.5));
// convert from inch to cm
float w = (float)m_width / m_resolution * 2.54;
@@ -358,7 +358,7 @@ bool IncludeGraphics::getPictureSize(int &wpx, int &hpx, QString &dpi, QString &
void IncludeGraphics::chooseFile()
{
- QString filter = ( cb_pdftex->isChecked() )
+ TQString filter = ( cb_pdftex->isChecked() )
? i18n("*.png *.jpg *.pdf|Graphics\n") // dani 31.7.2004
+ "*.png|PNG Files\n"
+ "*.jpg|JPG Files\n"
@@ -371,9 +371,9 @@ void IncludeGraphics::chooseFile()
+ "*.eps|EPS Files\n"
+ "*|All Files";
- QString fn = KFileDialog::getOpenFileName( m_startdir,filter,
+ TQString fn = KFileDialog::getOpenFileName( m_startdir,filter,
this,i18n("Select File") );
- QFileInfo fi(fn);
+ TQFileInfo fi(fn);
// insert the chosen file
edit_file->setText( fn );
@@ -383,8 +383,8 @@ void IncludeGraphics::chooseFile()
// execute the command and filter the result:
// eps|eps.gz --> %%BoundingBox: 0 0 123 456
// bitmaps --> w=123 h=456 dpi=789
- QString grep = " | grep -m1 \"^%%BoundingBox:\"";
- QString ext = QFileInfo(fn).extension();
+ TQString grep = " | grep -m1 \"^%%BoundingBox:\"";
+ TQString ext = TQFileInfo(fn).extension();
if ( ext == "eps" )
execute( "cat " + fn + grep);
else if ( ext == "eps.gz" )
@@ -398,7 +398,7 @@ void IncludeGraphics::chooseFile()
}
}
-void IncludeGraphics::execute(const QString &command)
+void IncludeGraphics::execute(const TQString &command)
{
if ( !m_boundingbox || (!m_imagemagick && command.left(8)=="identify") )
return;
@@ -408,14 +408,14 @@ void IncludeGraphics::execute(const QString &command)
m_proc = new KShellProcess("/bin/sh");
m_proc->clearArguments();
- (*m_proc) << QStringList::split(' ',command);
+ (*m_proc) << TQStringList::split(' ',command);
- connect(m_proc, SIGNAL(receivedStdout(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(receivedStderr(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(processExited(KProcess*)),
- this, SLOT(slotProcessExited(KProcess*)) );
+ connect(m_proc, TQT_SIGNAL(receivedStdout(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(receivedStderr(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(processExited(KProcess*)),
+ this, TQT_SLOT(slotProcessExited(KProcess*)) );
m_output = "";
KILE_DEBUG() << "=== IncludeGraphics::execute ====================" << endl;
@@ -428,7 +428,7 @@ void IncludeGraphics::execute(const QString &command)
void IncludeGraphics::slotProcessOutput(KProcess*,char* buffer,int buflen)
{
- m_output += QString::fromLocal8Bit(buffer,buflen);
+ m_output += TQString::fromLocal8Bit(buffer,buflen);
}
// identify was called
@@ -458,7 +458,7 @@ void IncludeGraphics::slotProcessExited(KProcess* proc)
// so the bounding box has to be calculated in a different way
// this regexp will accept floating point numbers as resolution
- QRegExp reg("w=(\\d+)\\s+h=(\\d+)\\s+dpi=([0-9.]+) (.*)");
+ TQRegExp reg("w=(\\d+)\\s+h=(\\d+)\\s+dpi=([0-9.]+) (.*)");
if ( reg.search(m_output) == -1 )
return;
@@ -484,9 +484,9 @@ void IncludeGraphics::slotProcessExited(KProcess* proc)
int bbh = (int)( (float)m_height*72.0/m_resolution + 0.5 );
// take width and height as parameters for the bounding box
- edit_bb->setText( QString("0 0 ") + QString("%1").arg(bbw)
+ edit_bb->setText( TQString("0 0 ") + TQString("%1").tqarg(bbw)
+ ' '
- + QString("%1").arg(bbh)
+ + TQString("%1").tqarg(bbh)
);
// show information
@@ -506,7 +506,7 @@ void IncludeGraphics::slotOk()
bool IncludeGraphics::checkParameter()
{
- QString filename = edit_file->text().stripWhiteSpace();
+ TQString filename = edit_file->text().stripWhiteSpace();
edit_file->setText(filename);
if ( filename.isEmpty() )
@@ -515,7 +515,7 @@ bool IncludeGraphics::checkParameter()
}
else
{
- QFileInfo fi( filename );
+ TQFileInfo fi( filename );
if ( ! fi.exists() )
{
if ( KMessageBox::warningYesNo( this, i18n("The graphics file does not exist. Proceed any way?") ) == KMessageBox::No ) return false;
diff --git a/src/kile/includegraphicsdialog.h b/src/kile/includegraphicsdialog.h
index e85ff34..b933eb8 100644
--- a/src/kile/includegraphicsdialog.h
+++ b/src/kile/includegraphicsdialog.h
@@ -17,7 +17,7 @@
#ifndef INCLUDEGRAPHICSDIALOG_H
#define INCLUDEGRAPHICSDIALOG_H
-#include <qstring.h>
+#include <tqstring.h>
#include <kdialogbase.h>
@@ -25,8 +25,8 @@
*@author dani
*/
-class QLabel;
-class QCheckBox;
+class TQLabel;
+class TQCheckBox;
class KileInfo;
class KLineEdit;
@@ -39,13 +39,14 @@ namespace KileDialog
class IncludeGraphics : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- IncludeGraphics(QWidget *parent,const QString &startdir,KileInfo *ki);
+ IncludeGraphics(TQWidget *tqparent,const TQString &startdir,KileInfo *ki);
~IncludeGraphics();
- QString getTemplate();
- QString getFilename();
+ TQString getTemplate();
+ TQString getFilename();
private slots:
void chooseFile();
@@ -60,18 +61,18 @@ private:
void readConfig();
void writeConfig();
bool checkParameter();
- QString getOptions();
- QString getInfo();
- bool getPictureSize(int &wpx, int &hpx, QString &dpi, QString &wcm, QString &hcm);
+ TQString getOptions();
+ TQString getInfo();
+ bool getPictureSize(int &wpx, int &hpx, TQString &dpi, TQString &wcm, TQString &hcm);
void setInfo();
- QLabel *infolabel;
+ TQLabel *infolabel;
KLineEdit *edit_file, *edit_label, *edit_caption, *edit_width, *edit_height, *edit_angle, *edit_bb;
- QCheckBox *cb_center, *cb_pdftex, *cb_figure, *cb_graphicspath;
- QLabel *lb_label, *lb_caption;
+ TQCheckBox *cb_center, *cb_pdftex, *cb_figure, *cb_graphicspath;
+ TQLabel *lb_label, *lb_caption;
- QString m_startdir;
- QString m_output;
+ TQString m_startdir;
+ TQString m_output;
// current picture
int m_width,m_height;
@@ -82,7 +83,7 @@ private:
bool m_boundingbox;
float m_defaultresolution;
- void execute(const QString &command);
+ void execute(const TQString &command);
KileInfo *m_ki;
KShellProcess* m_proc;
diff --git a/src/kile/kile.cpp b/src/kile/kile.cpp
index 75f3b2a..322f42e 100644
--- a/src/kile/kile.cpp
+++ b/src/kile/kile.cpp
@@ -19,8 +19,8 @@
#include "kile.h"
-#include <qtooltip.h>
-#include <qguardedptr.h>
+#include <tqtooltip.h>
+#include <tqguardedptr.h>
#include <kaction.h>
#include <khelpmenu.h>
@@ -84,39 +84,39 @@
#include "kilejscript.h"
#include "previewwidget.h"
-Kile::Kile( bool allowRestore, QWidget *parent, const char *name ) :
+Kile::Kile( bool allowRestore, TQWidget *tqparent, const char *name ) :
DCOPObject( "Kile" ),
- KParts::MainWindow( parent, name),
+ KParts::MainWindow( tqparent, name),
KileInfo(this),
m_paPrint(0L)
{
- m_focusWidget = this;
+ m_tqfocusWidget = this;
m_config = KGlobal::config();
readUserSettings();
readRecentFileSettings();
- m_jScriptManager = new KileJScript::Manager(this, m_config, actionCollection(), parent, "KileJScript::Manager");
+ m_jScriptManager = new KileJScript::Manager(this, m_config, actionCollection(), TQT_TQOBJECT(tqparent), "KileJScript::Manager");
setStandardToolBarMenuEnabled(true);
m_masterName = KileConfig::master();
m_singlemode = (m_masterName.isEmpty());
- m_AutosaveTimer = new QTimer();
- connect(m_AutosaveTimer,SIGNAL(timeout()),this,SLOT(autoSaveAll()));
+ m_AutosaveTimer = new TQTimer();
+ connect(m_AutosaveTimer,TQT_SIGNAL(timeout()),this,TQT_SLOT(autoSaveAll()));
m_latexCommands = new KileDocument::LatexCommands(m_config,this); // at first (dani)
m_edit = new KileDocument::EditorExtension(this);
m_help = new KileHelp::Help(m_edit);
m_partManager = new KParts::PartManager( this );
m_eventFilter = new KileEventFilter(m_edit);
- m_errorHandler = new KileErrorHandler(this, this);
+ m_errorHandler = new KileErrorHandler(TQT_TQOBJECT(this), this);
m_quickPreview = new KileTool::QuickPreview(this);
m_extensions = new KileDocument::Extensions();
- connect( m_partManager, SIGNAL( activePartChanged( KParts::Part * ) ), this, SLOT(activePartGUI ( KParts::Part * ) ) );
- connect(this,SIGNAL(configChanged()), m_eventFilter, SLOT(readConfig()));
+ connect( m_partManager, TQT_SIGNAL( activePartChanged( KParts::Part * ) ), TQT_TQOBJECT(this), TQT_SLOT(activePartGUI ( KParts::Part * ) ) );
+ connect(this,TQT_SIGNAL(configChanged()), m_eventFilter, TQT_SLOT(readConfig()));
readGUISettings();
@@ -129,23 +129,23 @@ Kile::Kile( bool allowRestore, QWidget *parent, const char *name ) :
m_currentState = m_wantState = "Editor";
m_bWatchFile = m_logPresent = false;
- viewManager()->setClient(this, this);
+ viewManager()->setClient(TQT_TQOBJECT(this), this);
setupStatusBar();
- m_topWidgetStack = new QWidgetStack( this );
- m_topWidgetStack->setFocusPolicy(QWidget::NoFocus);
+ m_topWidgetStack = new TQWidgetStack( this );
+ m_topWidgetStack->setFocusPolicy(TQ_NoFocus);
- m_horizontalSplitter = new QSplitter(QSplitter::Horizontal,m_topWidgetStack, "horizontalSplitter" );
+ m_horizontalSplitter = new TQSplitter(Qt::Horizontal,m_topWidgetStack, "horizontalSplitter" );
setupSideBar();
- m_verticalSplitter=new QSplitter(QSplitter::Vertical, m_horizontalSplitter, "verticalSplitter");
+ m_verticalSplitter=new TQSplitter(Qt::Vertical, m_horizontalSplitter, "verticalSplitter");
viewManager()->createTabs(m_verticalSplitter);
- connect(viewManager(), SIGNAL(activateView(QWidget*, bool)), this, SLOT(activateView(QWidget*, bool)));
- connect(viewManager(), SIGNAL(prepareForPart(const QString& )), this, SLOT(prepareForPart(const QString& )));
- connect(viewManager(), SIGNAL(startQuickPreview(int)), this, SLOT(slotQuickPreview(int)) );
+ connect(viewManager(), TQT_SIGNAL(activateView(TQWidget*, bool)), TQT_TQOBJECT(this), TQT_SLOT(activateView(TQWidget*, bool)));
+ connect(viewManager(), TQT_SIGNAL(prepareForPart(const TQString& )), TQT_TQOBJECT(this), TQT_SLOT(prepareForPart(const TQString& )));
+ connect(viewManager(), TQT_SIGNAL(startQuickPreview(int)), TQT_TQOBJECT(this), TQT_SLOT(slotQuickPreview(int)) );
setupBottomBar();
setupGraphicTools();
@@ -153,7 +153,7 @@ Kile::Kile( bool allowRestore, QWidget *parent, const char *name ) :
setupActions();
setupTools();
- QValueList<int> sizes;
+ TQValueList<int> sizes;
sizes << m_verSplitTop << m_verSplitBottom;
m_verticalSplitter->setSizes( sizes );
sizes.clear();
@@ -172,26 +172,26 @@ Kile::Kile( bool allowRestore, QWidget *parent, const char *name ) :
m_partManager->setActivePart( 0L );
m_lyxserver = new KileLyxServer(KileConfig::runLyxServer());
- connect(m_lyxserver, SIGNAL(insert(const KileAction::TagData &)), this, SLOT(insertTag(const KileAction::TagData &)));
+ connect(m_lyxserver, TQT_SIGNAL(insert(const KileAction::TagData &)), TQT_TQOBJECT(this), TQT_SLOT(insertTag(const KileAction::TagData &)));
applyMainWindowSettings(m_config, "KileMainWindow" );
m_manager = new KileTool::Manager(this, m_config, m_logWidget, m_outputWidget, m_partManager, m_topWidgetStack, m_paStop, 10000); //FIXME make timeout configurable
- connect(m_manager, SIGNAL(requestGUIState(const QString &)), this, SLOT(prepareForPart(const QString &)));
- connect(m_manager, SIGNAL(requestSaveAll(bool, bool)), docManager(), SLOT(fileSaveAll(bool, bool)));
- connect(m_manager, SIGNAL(jumpToFirstError()), m_errorHandler, SLOT(jumpToFirstError()));
- connect(m_manager, SIGNAL(toolStarted()), m_errorHandler, SLOT(reset()));
- connect(m_manager, SIGNAL(previewDone()), this, SLOT(focusPreview()));
+ connect(m_manager, TQT_SIGNAL(requestGUIState(const TQString &)), TQT_TQOBJECT(this), TQT_SLOT(prepareForPart(const TQString &)));
+ connect(m_manager, TQT_SIGNAL(requestSaveAll(bool, bool)), docManager(), TQT_SLOT(fileSaveAll(bool, bool)));
+ connect(m_manager, TQT_SIGNAL(jumpToFirstError()), m_errorHandler, TQT_SLOT(jumpToFirstError()));
+ connect(m_manager, TQT_SIGNAL(toolStarted()), m_errorHandler, TQT_SLOT(reset()));
+ connect(m_manager, TQT_SIGNAL(previewDone()), TQT_TQOBJECT(this), TQT_SLOT(focusPreview()));
m_toolFactory = new KileTool::Factory(m_manager, m_config);
m_manager->setFactory(m_toolFactory);
m_help->setUserhelp(m_manager,menuBar()); // kile user help (dani)
- connect(docManager(), SIGNAL(updateModeStatus()), this, SLOT(updateModeStatus()));
- connect(docManager(), SIGNAL(updateStructure(bool, KileDocument::Info*)), viewManager(), SLOT(updateStructure(bool, KileDocument::Info*)));
- connect(docManager(), SIGNAL(closingDocument(KileDocument::Info* )), m_kwStructure, SLOT(closeDocumentInfo(KileDocument::Info *)));
- connect(docManager(), SIGNAL(documentInfoCreated(KileDocument::Info* )), m_kwStructure, SLOT(addDocumentInfo(KileDocument::Info* )));
- connect(docManager(), SIGNAL(updateReferences(KileDocument::Info *)), m_kwStructure, SLOT(updateReferences(KileDocument::Info *)));
+ connect(docManager(), TQT_SIGNAL(updateModetqStatus()), TQT_TQOBJECT(this), TQT_SLOT(updateModetqStatus()));
+ connect(docManager(), TQT_SIGNAL(updateStructure(bool, KileDocument::Info*)), viewManager(), TQT_SLOT(updateStructure(bool, KileDocument::Info*)));
+ connect(docManager(), TQT_SIGNAL(closingDocument(KileDocument::Info* )), m_kwStructure, TQT_SLOT(closeDocumentInfo(KileDocument::Info *)));
+ connect(docManager(), TQT_SIGNAL(documentInfoCreated(KileDocument::Info* )), m_kwStructure, TQT_SLOT(addDocumentInfo(KileDocument::Info* )));
+ connect(docManager(), TQT_SIGNAL(updateReferences(KileDocument::Info *)), m_kwStructure, TQT_SLOT(updateReferences(KileDocument::Info *)));
readConfig();
@@ -210,7 +210,7 @@ Kile::Kile( bool allowRestore, QWidget *parent, const char *name ) :
restoreFilesAndProjects(allowRestore);
initMenu();
- updateModeStatus();
+ updateModetqStatus();
actionCollection()->readShortcutSettings("Shortcuts", m_config);
}
@@ -224,20 +224,20 @@ Kile::~Kile()
delete m_edit;
delete m_help;
delete m_AutosaveTimer;
- delete m_lyxserver; //QObject without parent, have to delete it ourselves
+ delete m_lyxserver; //TQObject without tqparent, have to delete it ourselves
delete m_outputInfo;
delete m_outputFilter;
delete m_eventFilter;
}
-void Kile::showEvent(QShowEvent *)
+void Kile::showEvent(TQShowEvent *)
{
- m_focusWidget->setFocus();
+ m_tqfocusWidget->setFocus();
}
-void Kile::hideEvent(QHideEvent *)
+void Kile::hideEvent(TQHideEvent *)
{
- m_focusWidget = focusWidget();
+ m_tqfocusWidget = tqfocusWidget();
}
void Kile::setupStatusBar()
@@ -257,8 +257,8 @@ void Kile::setupSideBar()
m_fileSelector= new KileFileSelect(m_extensions,m_sideBar,"File Selector");
m_sideBar->addTab(m_fileSelector, SmallIcon("fileopen"), i18n("Open File"));
- connect(m_fileSelector,SIGNAL(fileSelected(const KFileItem*)), docManager(), SLOT(fileSelected(const KFileItem*)));
- connect(m_fileSelector->comboEncoding(), SIGNAL(activated(int)),this,SLOT(changeInputEncoding()));
+ connect(m_fileSelector,TQT_SIGNAL(fileSelected(const KFileItem*)), docManager(), TQT_SLOT(fileSelected(const KFileItem*)));
+ connect(m_fileSelector->comboEncoding(), TQT_SIGNAL(activated(int)),this,TQT_SLOT(changeInputEncoding()));
m_fileSelector->comboEncoding()->lineEdit()->setText(KileConfig::defaultEncoding());
m_fileSelector->readConfig();
@@ -278,45 +278,45 @@ void Kile::setupProjectView()
KileProjectView *projectview = new KileProjectView(m_sideBar, this);
// viewManager()->setProjectView(projectview);
m_sideBar->addTab(projectview, SmallIcon("relation"), i18n("Files and Projects"));
- connect(projectview, SIGNAL(fileSelected(const KileProjectItem *)), docManager(), SLOT(fileSelected(const KileProjectItem *)));
- connect(projectview, SIGNAL(fileSelected(const KURL &)), docManager(), SLOT(fileSelected(const KURL &)));
- connect(projectview, SIGNAL(closeURL(const KURL&)), docManager(), SLOT(fileClose(const KURL&)));
- connect(projectview, SIGNAL(closeProject(const KURL&)), docManager(), SLOT(projectClose(const KURL&)));
- connect(projectview, SIGNAL(projectOptions(const KURL&)), docManager(), SLOT(projectOptions(const KURL&)));
- connect(projectview, SIGNAL(projectArchive(const KURL&)), this, SLOT(runArchiveTool(const KURL&)));
- connect(projectview, SIGNAL(removeFromProject(const KileProjectItem *)), docManager(), SLOT(removeFromProject(const KileProjectItem *)));
- connect(projectview, SIGNAL(addFiles(const KURL &)), docManager(), SLOT(projectAddFiles(const KURL &)));
- connect(projectview, SIGNAL(openAllFiles(const KURL &)), docManager(), SLOT(projectOpenAllFiles(const KURL &)));
- connect(projectview, SIGNAL(toggleArchive(KileProjectItem *)), docManager(), SLOT(toggleArchive(KileProjectItem *)));
- connect(projectview, SIGNAL(addToProject(const KURL &)), docManager(), SLOT(addToProject(const KURL &)));
- connect(projectview, SIGNAL(saveURL(const KURL &)), docManager(), SLOT(saveURL(const KURL &)));
- connect(projectview, SIGNAL(buildProjectTree(const KURL &)), docManager(), SLOT(buildProjectTree(const KURL &)));
- connect(docManager(), SIGNAL(projectTreeChanged(const KileProject *)), projectview, SLOT(refreshProjectTree(const KileProject *)));
- connect(docManager(), SIGNAL(removeFromProjectView(const KURL &)),projectview,SLOT(remove(const KURL &)));
- connect(docManager(), SIGNAL(removeFromProjectView(const KileProject *)),projectview,SLOT(remove(const KileProject *)));
- connect(docManager(), SIGNAL(addToProjectView(const KURL &)),projectview,SLOT(add(const KURL &)));
- connect(docManager(), SIGNAL(addToProjectView(const KileProject *)),projectview,SLOT(add(const KileProject *)));
- connect(docManager(),SIGNAL(removeItemFromProjectView(const KileProjectItem *, bool)),projectview,SLOT(removeItem(const KileProjectItem *, bool)));
- connect(docManager(),SIGNAL(addToProjectView(KileProjectItem *)),projectview,SLOT(add(KileProjectItem *)));
+ connect(projectview, TQT_SIGNAL(fileSelected(const KileProjectItem *)), docManager(), TQT_SLOT(fileSelected(const KileProjectItem *)));
+ connect(projectview, TQT_SIGNAL(fileSelected(const KURL &)), docManager(), TQT_SLOT(fileSelected(const KURL &)));
+ connect(projectview, TQT_SIGNAL(closeURL(const KURL&)), docManager(), TQT_SLOT(fileClose(const KURL&)));
+ connect(projectview, TQT_SIGNAL(closeProject(const KURL&)), docManager(), TQT_SLOT(projectClose(const KURL&)));
+ connect(projectview, TQT_SIGNAL(projectOptions(const KURL&)), docManager(), TQT_SLOT(projectOptions(const KURL&)));
+ connect(projectview, TQT_SIGNAL(projectArchive(const KURL&)), TQT_TQOBJECT(this), TQT_SLOT(runArchiveTool(const KURL&)));
+ connect(projectview, TQT_SIGNAL(removeFromProject(const KileProjectItem *)), docManager(), TQT_SLOT(removeFromProject(const KileProjectItem *)));
+ connect(projectview, TQT_SIGNAL(addFiles(const KURL &)), docManager(), TQT_SLOT(projectAddFiles(const KURL &)));
+ connect(projectview, TQT_SIGNAL(openAllFiles(const KURL &)), docManager(), TQT_SLOT(projectOpenAllFiles(const KURL &)));
+ connect(projectview, TQT_SIGNAL(toggleArchive(KileProjectItem *)), docManager(), TQT_SLOT(toggleArchive(KileProjectItem *)));
+ connect(projectview, TQT_SIGNAL(addToProject(const KURL &)), docManager(), TQT_SLOT(addToProject(const KURL &)));
+ connect(projectview, TQT_SIGNAL(saveURL(const KURL &)), docManager(), TQT_SLOT(saveURL(const KURL &)));
+ connect(projectview, TQT_SIGNAL(buildProjectTree(const KURL &)), docManager(), TQT_SLOT(buildProjectTree(const KURL &)));
+ connect(docManager(), TQT_SIGNAL(projectTreeChanged(const KileProject *)), projectview, TQT_SLOT(refreshProjectTree(const KileProject *)));
+ connect(docManager(), TQT_SIGNAL(removeFromProjectView(const KURL &)),projectview,TQT_SLOT(remove(const KURL &)));
+ connect(docManager(), TQT_SIGNAL(removeFromProjectView(const KileProject *)),projectview,TQT_SLOT(remove(const KileProject *)));
+ connect(docManager(), TQT_SIGNAL(addToProjectView(const KURL &)),projectview,TQT_SLOT(add(const KURL &)));
+ connect(docManager(), TQT_SIGNAL(addToProjectView(const KileProject *)),projectview,TQT_SLOT(add(const KileProject *)));
+ connect(docManager(),TQT_SIGNAL(removeItemFromProjectView(const KileProjectItem *, bool)),projectview,TQT_SLOT(removeItem(const KileProjectItem *, bool)));
+ connect(docManager(),TQT_SIGNAL(addToProjectView(KileProjectItem *)),projectview,TQT_SLOT(add(KileProjectItem *)));
}
void Kile::setupStructureView()
{
m_kwStructure = new KileWidget::Structure(this, m_sideBar);
m_sideBar->addTab(m_kwStructure, SmallIcon("view_tree"), i18n("Structure"));
- m_kwStructure->setFocusPolicy(QWidget::ClickFocus);
- connect(this, SIGNAL(configChanged()), m_kwStructure, SIGNAL(configChanged()));
- connect(m_kwStructure, SIGNAL(setCursor(const KURL &,int,int)), this, SLOT(setCursor(const KURL &,int,int)));
- connect(m_kwStructure, SIGNAL(fileOpen(const KURL&, const QString & )), docManager(), SLOT(fileOpen(const KURL&, const QString& )));
- connect(m_kwStructure, SIGNAL(fileNew(const KURL&)), docManager(), SLOT(fileNew(const KURL&)));
- connect(m_kwStructure, SIGNAL(sendText(const QString &)), this, SLOT(insertText(const QString &)));
- connect(m_kwStructure, SIGNAL(sectioningPopup(KileListViewItem *,int)), m_edit, SLOT(sectioningCommand(KileListViewItem *,int)));
+ m_kwStructure->setFocusPolicy(TQ_ClickFocus);
+ connect(TQT_TQOBJECT(this), TQT_SIGNAL(configChanged()), m_kwStructure, TQT_SIGNAL(configChanged()));
+ connect(m_kwStructure, TQT_SIGNAL(setCursor(const KURL &,int,int)), TQT_TQOBJECT(this), TQT_SLOT(setCursor(const KURL &,int,int)));
+ connect(m_kwStructure, TQT_SIGNAL(fileOpen(const KURL&, const TQString & )), docManager(), TQT_SLOT(fileOpen(const KURL&, const TQString& )));
+ connect(m_kwStructure, TQT_SIGNAL(fileNew(const KURL&)), docManager(), TQT_SLOT(fileNew(const KURL&)));
+ connect(m_kwStructure, TQT_SIGNAL(sendText(const TQString &)), TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString &)));
+ connect(m_kwStructure, TQT_SIGNAL(sectioningPopup(KileListViewItem *,int)), m_edit, TQT_SLOT(sectioningCommand(KileListViewItem *,int)));
}
void Kile::setupScriptsManagementView()
{
m_scriptsManagementWidget = new KileWidget::ScriptsManagement(this, m_sideBar);
- connect((QObject*)editorKeySequenceManager(), SIGNAL(watchedKeySequencesChanged()), m_scriptsManagementWidget, SLOT(updateListView()));
+ connect((TQObject*)editorKeySequenceManager(), TQT_SIGNAL(watchedKeySequencesChanged()), m_scriptsManagementWidget, TQT_SLOT(updateListView()));
m_sideBar->addTab(m_scriptsManagementWidget, SmallIcon("jspage"), i18n("Scripts"));
}
@@ -328,87 +328,87 @@ void Kile::enableSymbolViewMFUS()
Click on an icon to insert the command, additionally pressing SHIFT inserts it in math mode,\
pressing CTRL in curly brackets."));
- connect(m_symbolViewRelation,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewOperators,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewArrows,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewMiscMath,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewMiscText,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewDelimiters,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewGreek,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewSpecial,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewCyrillic,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
- connect(m_symbolViewUser,SIGNAL(addToList(const QIconViewItem *)),m_symbolViewMFUS,SLOT(slotAddToList(const QIconViewItem *)));
+ connect(m_symbolViewRelation,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewOperators,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewArrows,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewMiscMath,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewMiscText,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewDelimiters,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewGreek,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewSpecial,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewCyrillic,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
+ connect(m_symbolViewUser,TQT_SIGNAL(addToList(const TQIconViewItem *)),m_symbolViewMFUS,TQT_SLOT(slotAddToList(const TQIconViewItem *)));
}
void Kile::disableSymbolViewMFUS()
{
m_toolBox->setItemEnabled(m_toolBox->indexOf(m_symbolViewMFUS),false);
- m_toolBox->setItemToolTip(m_toolBox->indexOf(m_symbolViewMFUS),QString());
- disconnect(m_symbolViewMFUS,SIGNAL(addtoList(const QIconViewItem *)));
+ m_toolBox->setItemToolTip(m_toolBox->indexOf(m_symbolViewMFUS),TQString());
+ disconnect(m_symbolViewMFUS,TQT_SIGNAL(addtoList(const TQIconViewItem *)));
}
void Kile::setupSymbolViews()
{
- m_toolBox = new QToolBox(m_sideBar);
+ m_toolBox = new TQToolBox(m_sideBar);
m_sideBar->addTab(m_toolBox,SmallIcon("math0"),i18n("Symbols"));
m_symbolViewMFUS = new SymbolView(m_toolBox,SymbolView::MFUS);
m_toolBox->addItem(m_symbolViewMFUS,i18n("Most Frequently Used"));
m_toolBox->setItemEnabled(m_toolBox->indexOf(m_symbolViewMFUS),false);
- connect(m_symbolViewMFUS, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewMFUS, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewRelation = new SymbolView(m_toolBox,SymbolView::Relation);
m_toolBox->addItem(m_symbolViewRelation,SmallIcon("math1"),i18n("Relation"));
- connect(m_symbolViewRelation, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewRelation, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewOperators = new SymbolView(m_toolBox,SymbolView::Operator);
m_toolBox->addItem(m_symbolViewOperators,SmallIcon("math2"),i18n("Operators"));
- connect(m_symbolViewOperators, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewOperators, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewArrows = new SymbolView(m_toolBox,SymbolView::Arrow);
m_toolBox->addItem(m_symbolViewArrows,SmallIcon("math3"),i18n("Arrows"));
- connect(m_symbolViewArrows, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewArrows, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewMiscMath = new SymbolView(m_toolBox,SymbolView::MiscMath);
m_toolBox->addItem(m_symbolViewMiscMath,SmallIcon("math4"),i18n("Miscellaneous Math"));
- connect(m_symbolViewMiscMath, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewMiscMath, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewMiscText = new SymbolView(m_toolBox,SymbolView::MiscText);
m_toolBox->addItem(m_symbolViewMiscText,SmallIcon("math5"),i18n("Miscellaneous Text"));
- connect(m_symbolViewMiscText, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewMiscText, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewDelimiters= new SymbolView(m_toolBox,SymbolView::Delimiters);
m_toolBox->addItem(m_symbolViewDelimiters,SmallIcon("math6"),i18n("Delimiters"));
- connect(m_symbolViewDelimiters, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString& ,const QStringList&)));
+ connect(m_symbolViewDelimiters, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& ,const TQStringList&)));
m_symbolViewGreek = new SymbolView(m_toolBox,SymbolView::Greek);
m_toolBox->addItem(m_symbolViewGreek,SmallIcon("math7"),i18n("Greek"));
- connect(m_symbolViewGreek, SIGNAL(insertText(const QString&, const QStringList&)),
- this, SLOT(insertText(const QString&, const QStringList&)));
+ connect(m_symbolViewGreek, TQT_SIGNAL(insertText(const TQString&, const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString&, const TQStringList&)));
m_symbolViewSpecial = new SymbolView(m_toolBox,SymbolView::Special);
m_toolBox->addItem(m_symbolViewSpecial,SmallIcon("math8"),i18n("Special Characters"));
- connect(m_symbolViewSpecial, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString&, const QStringList&)));
+ connect(m_symbolViewSpecial, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString&, const TQStringList&)));
m_symbolViewCyrillic = new SymbolView(m_toolBox,SymbolView::Cyrillic);
m_toolBox->addItem(m_symbolViewCyrillic,SmallIcon("math10"),i18n("Cyrillic Characters"));
- connect(m_symbolViewCyrillic, SIGNAL(insertText(const QString& ,const QStringList&)),
- this, SLOT(insertText(const QString&, const QStringList&)));
+ connect(m_symbolViewCyrillic, TQT_SIGNAL(insertText(const TQString& ,const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString&, const TQStringList&)));
m_symbolViewUser = new SymbolView(m_toolBox,SymbolView::User);
m_toolBox->addItem(m_symbolViewUser,SmallIcon("math9"),i18n("User Defined"));
- connect(m_symbolViewUser, SIGNAL(insertText(const QString&, const QStringList&)),
- this, SLOT(insertText(const QString&, const QStringList& )));
+ connect(m_symbolViewUser, TQT_SIGNAL(insertText(const TQString&, const TQStringList&)),
+ TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString&, const TQStringList& )));
for (int i=0; i< m_toolBox->count(); i++)
m_toolBox->setItemToolTip(i, i18n("Move the mouse over the icons to see the corresponding LaTeX commands.\nClick on the images to insert the command, additionally pressing SHIFT inserts it in math mode, pressing CTRL in curly brackets."));
@@ -420,42 +420,42 @@ void Kile::setupAbbreviationView()
m_edit->complete()->setAbbreviationListview(m_kileAbbrevView);
m_sideBar->addTab(m_kileAbbrevView, SmallIcon("complete3"), i18n("Abbreviation"));
- connect(m_kileAbbrevView, SIGNAL(sendText(const QString& )), this, SLOT(insertText(const QString& )));
+ connect(m_kileAbbrevView, TQT_SIGNAL(sendText(const TQString& )), TQT_TQOBJECT(this), TQT_SLOT(insertText(const TQString& )));
}
void Kile::setupBottomBar()
{
m_bottomBar = new KileBottomBar(KileConfig::bottomBarSize(), m_verticalSplitter);
- m_bottomBar->setFocusPolicy(QWidget::ClickFocus);
+ m_bottomBar->setFocusPolicy(TQ_ClickFocus);
m_logWidget = new KileWidget::LogMsg( this, m_bottomBar );
- connect(m_logWidget, SIGNAL(showingErrorMessage(QWidget* )), m_bottomBar, SLOT(showPage(QWidget* )));
- connect(m_logWidget, SIGNAL(fileOpen(const KURL&, const QString & )), docManager(), SLOT(fileOpen(const KURL&, const QString& )));
- connect(m_logWidget, SIGNAL(setLine(const QString& )), this, SLOT(setLine(const QString& )));
- connect(m_docManager,SIGNAL(printMsg(int, const QString &, const QString &)),m_logWidget,SLOT(printMsg(int, const QString &, const QString &)));
+ connect(m_logWidget, TQT_SIGNAL(showingErrorMessage(TQWidget* )), m_bottomBar, TQT_SLOT(showPage(TQWidget* )));
+ connect(m_logWidget, TQT_SIGNAL(fileOpen(const KURL&, const TQString & )), docManager(), TQT_SLOT(fileOpen(const KURL&, const TQString& )));
+ connect(m_logWidget, TQT_SIGNAL(setLine(const TQString& )), TQT_TQOBJECT(this), TQT_SLOT(setLine(const TQString& )));
+ connect(m_docManager,TQT_SIGNAL(printMsg(int, const TQString &, const TQString &)),m_logWidget,TQT_SLOT(printMsg(int, const TQString &, const TQString &)));
- m_logWidget->setFocusPolicy(QWidget::ClickFocus);
+ m_logWidget->setFocusPolicy(TQ_ClickFocus);
m_logWidget->setMinimumHeight(40);
m_logWidget->setReadOnly(true);
m_bottomBar->addTab(m_logWidget, SmallIcon("viewlog"), i18n("Log and Messages"));
m_outputWidget = new KileWidget::Output(m_bottomBar);
- m_outputWidget->setFocusPolicy(QWidget::ClickFocus);
+ m_outputWidget->setFocusPolicy(TQ_ClickFocus);
m_outputWidget->setMinimumHeight(40);
m_outputWidget->setReadOnly(true);
m_bottomBar->addTab(m_outputWidget, SmallIcon("output_win"), i18n("Output"));
m_outputInfo=new LatexOutputInfoArray();
m_outputFilter=new LatexOutputFilter(m_outputInfo,m_extensions);
- connect(m_outputFilter, SIGNAL(problem(int, const QString& )), m_logWidget, SLOT(printProblem(int, const QString& )));
+ connect(m_outputFilter, TQT_SIGNAL(problem(int, const TQString& )), m_logWidget, TQT_SLOT(printProblem(int, const TQString& )));
m_texKonsole=new KileWidget::Konsole(this, m_bottomBar,"konsole");
m_bottomBar->addTab(m_texKonsole, SmallIcon("konsole"),i18n("Konsole"));
- connect(viewManager()->tabs(), SIGNAL( currentChanged( QWidget * ) ), m_texKonsole, SLOT(sync()));
+ connect(viewManager()->tabs(), TQT_SIGNAL( currentChanged( TQWidget * ) ), m_texKonsole, TQT_SLOT(sync()));
- m_previewView = new QScrollView (m_bottomBar);
+ m_previewView = new TQScrollView (m_bottomBar);
m_previewWidget = new KileWidget::PreviewWidget (this, m_previewView);
- m_previewView->viewport()->setPaletteBackgroundColor (QColor (0xff, 0xff, 0xff));
+ m_previewView->viewport()->setPaletteBackgroundColor (TQColor (0xff, 0xff, 0xff));
m_previewView->addChild(m_previewWidget, 0, 0);
m_bottomBar->addTab (m_previewView, SmallIcon ("edu_mathematics"), i18n ("Preview"));
@@ -492,162 +492,162 @@ void Kile::setupPreviewTools()
void Kile::setupActions()
{
m_paPrint = KStdAction::print(0,0, actionCollection(), "file_print");
- (void) KStdAction::openNew(docManager(), SLOT(fileNew()), actionCollection(), "file_new" );
- (void) KStdAction::open(docManager(), SLOT(fileOpen()), actionCollection(),"file_open" );
- m_actRecentFiles = KStdAction::openRecent(docManager(), SLOT(fileOpen(const KURL&)), actionCollection(), "file_open_recent");
- connect(docManager(), SIGNAL(addToRecentFiles(const KURL& )), m_actRecentFiles, SLOT(addURL(const KURL& )));
+ (void) KStdAction::openNew(docManager(), TQT_SLOT(fileNew()), actionCollection(), "file_new" );
+ (void) KStdAction::open(docManager(), TQT_SLOT(fileOpen()), actionCollection(),"file_open" );
+ m_actRecentFiles = KStdAction::openRecent(docManager(), TQT_SLOT(fileOpen(const KURL&)), actionCollection(), "file_open_recent");
+ connect(docManager(), TQT_SIGNAL(addToRecentFiles(const KURL& )), m_actRecentFiles, TQT_SLOT(addURL(const KURL& )));
m_actRecentFiles->loadEntries(m_config, "Recent Files");
- (void) KStdAction::save(docManager(), SLOT(fileSave()), actionCollection(),"kile_file_save" );
- (void) KStdAction::saveAs(docManager(), SLOT(fileSaveAs()), actionCollection(),"kile_file_save_as" );
-
- (void) new KAction(i18n("Save All"),"save_all", 0, docManager(), SLOT(fileSaveAll()), actionCollection(),"file_save_all");
- (void) new KAction(i18n("Save Copy As..."),"save_copy_as", 0, docManager(), SLOT(fileSaveCopyAs()), actionCollection(),"file_save_copy_as");
- (void) new KAction(i18n("Create Template From Document..."), 0, docManager(), SLOT(createTemplate()), actionCollection(),"template_create");
- (void) new KAction(i18n("&Remove Template..."),0, docManager(), SLOT(removeTemplate()), actionCollection(), "template_remove");
- (void) KStdAction::close(docManager(), SLOT(fileClose()), actionCollection(),"file_close" );
- (void) new KAction(i18n("Close All"), 0, docManager(), SLOT(fileCloseAll()), actionCollection(),"file_close_all" );
- (void) new KAction(i18n("Close All Ot&hers"), 0, docManager(), SLOT(fileCloseAllOthers()), actionCollection(),"file_close_all_others" );
- (void) new KAction(i18n("S&tatistics"), 0, this, SLOT(showDocInfo()), actionCollection(), "Statistics" );
- (void) new KAction(i18n("&ASCII"), 0, this, SLOT(convertToASCII()), actionCollection(), "file_export_ascii" );
- (void) new KAction(i18n("Latin-&1 (iso 8859-1)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_latin1" );
- (void) new KAction(i18n("Latin-&2 (iso 8859-2)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_latin2" );
- (void) new KAction(i18n("Latin-&3 (iso 8859-3)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_latin3" );
- (void) new KAction(i18n("Latin-&4 (iso 8859-4)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_latin4" );
- (void) new KAction(i18n("Latin-&5 (iso 8859-5)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_latin5" );
- (void) new KAction(i18n("Latin-&9 (iso 8859-9)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_latin9" );
- (void) new KAction(i18n("&Central European (cp-1250)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_cp1250" );
- (void) new KAction(i18n("&Western European (cp-1252)"), 0, this, SLOT(convertToEnc()), actionCollection(), "file_export_cp1252" );
- (void) KStdAction::quit(this, SLOT(close()), actionCollection(),"file_quit" );
-
- (void) KStdAction::gotoLine(m_edit, SLOT(gotoLine()), actionCollection(),"edit_goto_line" );
- (void) new KAction(i18n("Next section"), "nextsection", ALT+Key_Down, m_edit, SLOT(gotoNextSectioning()), actionCollection(),"edit_next_section" );
- (void) new KAction(i18n("Prev section"), "prevsection", ALT+Key_Up, m_edit, SLOT(gotoPrevSectioning()), actionCollection(),"edit_prev_section" );
- (void) new KAction(i18n("Next paragraph"), "nextparagraph", ALT+SHIFT+Key_Down, m_edit, SLOT(gotoNextParagraph()), actionCollection(),"edit_next_paragraph" );
- (void) new KAction(i18n("Prev paragraph"), "prevparagraph", ALT+SHIFT+Key_Up, m_edit, SLOT(gotoPrevParagraph()), actionCollection(),"edit_prev_paragraph" );
-
- (void) new KAction(i18n("Find &in Files..."), "filegrep", ALT+SHIFT+Key_F, this, SLOT(findInFiles()), actionCollection(),"FindInFiles" );
-
- (void) new KAction(i18n("Refresh Str&ucture"), "refreshstructure", Key_F12, this, SLOT(refreshStructure()), actionCollection(),"RefreshStructure" );
+ (void) KStdAction::save(docManager(), TQT_SLOT(fileSave()), actionCollection(),"kile_file_save" );
+ (void) KStdAction::saveAs(docManager(), TQT_SLOT(fileSaveAs()), actionCollection(),"kile_file_save_as" );
+
+ (void) new KAction(i18n("Save All"),"save_all", 0, docManager(), TQT_SLOT(fileSaveAll()), actionCollection(),"file_save_all");
+ (void) new KAction(i18n("Save Copy As..."),"save_copy_as", 0, docManager(), TQT_SLOT(fileSaveCopyAs()), actionCollection(),"file_save_copy_as");
+ (void) new KAction(i18n("Create Template From Document..."), 0, docManager(), TQT_SLOT(createTemplate()), actionCollection(),"template_create");
+ (void) new KAction(i18n("&Remove Template..."),0, docManager(), TQT_SLOT(removeTemplate()), actionCollection(), "template_remove");
+ (void) KStdAction::close(docManager(), TQT_SLOT(fileClose()), actionCollection(),"file_close" );
+ (void) new KAction(i18n("Close All"), 0, docManager(), TQT_SLOT(fileCloseAll()), actionCollection(),"file_close_all" );
+ (void) new KAction(i18n("Close All Ot&hers"), 0, docManager(), TQT_SLOT(fileCloseAllOthers()), actionCollection(),"file_close_all_others" );
+ (void) new KAction(i18n("S&tatistics"), 0, TQT_TQOBJECT(this), TQT_SLOT(showDocInfo()), actionCollection(), "Statistics" );
+ (void) new KAction(i18n("&ASCII"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToASCII()), actionCollection(), "file_export_ascii" );
+ (void) new KAction(i18n("Latin-&1 (iso 8859-1)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_latin1" );
+ (void) new KAction(i18n("Latin-&2 (iso 8859-2)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_latin2" );
+ (void) new KAction(i18n("Latin-&3 (iso 8859-3)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_latin3" );
+ (void) new KAction(i18n("Latin-&4 (iso 8859-4)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_latin4" );
+ (void) new KAction(i18n("Latin-&5 (iso 8859-5)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_latin5" );
+ (void) new KAction(i18n("Latin-&9 (iso 8859-9)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_latin9" );
+ (void) new KAction(i18n("&Central European (cp-1250)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_cp1250" );
+ (void) new KAction(i18n("&Western European (cp-1252)"), 0, TQT_TQOBJECT(this), TQT_SLOT(convertToEnc()), actionCollection(), "file_export_cp1252" );
+ (void) KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection(),"file_quit" );
+
+ (void) KStdAction::gotoLine(m_edit, TQT_SLOT(gotoLine()), actionCollection(),"edit_goto_line" );
+ (void) new KAction(i18n("Next section"), "nextsection", ALT+Key_Down, m_edit, TQT_SLOT(gotoNextSectioning()), actionCollection(),"edit_next_section" );
+ (void) new KAction(i18n("Prev section"), "prevsection", ALT+Key_Up, m_edit, TQT_SLOT(gotoPrevSectioning()), actionCollection(),"edit_prev_section" );
+ (void) new KAction(i18n("Next paragraph"), "nextparagraph", ALT+SHIFT+Key_Down, m_edit, TQT_SLOT(gotoNextParagraph()), actionCollection(),"edit_next_paragraph" );
+ (void) new KAction(i18n("Prev paragraph"), "prevparagraph", ALT+SHIFT+Key_Up, m_edit, TQT_SLOT(gotoPrevParagraph()), actionCollection(),"edit_prev_paragraph" );
+
+ (void) new KAction(i18n("Find &in Files..."), "filegrep", ALT+SHIFT+Key_F, TQT_TQOBJECT(this), TQT_SLOT(findInFiles()), actionCollection(),"FindInFiles" );
+
+ (void) new KAction(i18n("Refresh Str&ucture"), "refreshstructure", Key_F12, TQT_TQOBJECT(this), TQT_SLOT(refreshStructure()), actionCollection(),"RefreshStructure" );
//project actions
- (void) new KAction(i18n("&New Project..."), "window_new", 0, docManager(), SLOT(projectNew()), actionCollection(), "project_new");
- (void) new KAction(i18n("&Open Project..."), "project_open", 0, docManager(), SLOT(projectOpen()), actionCollection(), "project_open");
- m_actRecentProjects = new KRecentFilesAction(i18n("Open &Recent Project"), 0, docManager(), SLOT(projectOpen(const KURL &)), actionCollection(), "project_openrecent");
- connect(docManager(), SIGNAL(removeFromRecentProjects(const KURL& )), m_actRecentProjects, SLOT(removeURL(const KURL& )));
- connect(docManager(), SIGNAL(addToRecentProjects(const KURL& )), m_actRecentProjects, SLOT(addURL(const KURL& )));
+ (void) new KAction(i18n("&New Project..."), "window_new", 0, docManager(), TQT_SLOT(projectNew()), actionCollection(), "project_new");
+ (void) new KAction(i18n("&Open Project..."), "project_open", 0, docManager(), TQT_SLOT(projectOpen()), actionCollection(), "project_open");
+ m_actRecentProjects = new KRecentFilesAction(i18n("Open &Recent Project"), 0, docManager(), TQT_SLOT(projectOpen(const KURL &)), actionCollection(), "project_openrecent");
+ connect(docManager(), TQT_SIGNAL(removeFromRecentProjects(const KURL& )), m_actRecentProjects, TQT_SLOT(removeURL(const KURL& )));
+ connect(docManager(), TQT_SIGNAL(addToRecentProjects(const KURL& )), m_actRecentProjects, TQT_SLOT(addURL(const KURL& )));
m_actRecentProjects->loadEntries(m_config, "Projects");
- (void) new KAction(i18n("A&dd Files to Project..."),"project_add", 0, docManager(), SLOT(projectAddFiles()), actionCollection(), "project_add");
- (void) new KAction(i18n("Refresh Project &Tree"), "rebuild", 0, docManager(), SLOT(buildProjectTree()), actionCollection(), "project_buildtree");
- (void) new KAction(i18n("&Archive"), "package", 0, this, SLOT(runArchiveTool()), actionCollection(), "project_archive");
- (void) new KAction(i18n("Project &Options"), "configure_project", 0, docManager(), SLOT(projectOptions()), actionCollection(), "project_options");
- (void) new KAction(i18n("&Close Project"), "fileclose", 0, docManager(), SLOT(projectClose()), actionCollection(), "project_close");
+ (void) new KAction(i18n("A&dd Files to Project..."),"project_add", 0, docManager(), TQT_SLOT(projectAddFiles()), actionCollection(), "project_add");
+ (void) new KAction(i18n("Refresh Project &Tree"), "rebuild", 0, docManager(), TQT_SLOT(buildProjectTree()), actionCollection(), "project_buildtree");
+ (void) new KAction(i18n("&Archive"), "package", 0, TQT_TQOBJECT(this), TQT_SLOT(runArchiveTool()), actionCollection(), "project_archive");
+ (void) new KAction(i18n("Project &Options"), "configure_project", 0, docManager(), TQT_SLOT(projectOptions()), actionCollection(), "project_options");
+ (void) new KAction(i18n("&Close Project"), "fileclose", 0, docManager(), TQT_SLOT(projectClose()), actionCollection(), "project_close");
// new project actions (dani)
- (void) new KAction(i18n("&Show Projects..."), 0, docManager(), SLOT(projectShow()), actionCollection(), "project_show");
- (void) new KAction(i18n("Re&move Files From Project..."),"project_remove", 0, docManager(), SLOT(projectRemoveFiles()), actionCollection(), "project_remove");
- (void) new KAction(i18n("Show Project &Files..."),"project_show", 0, docManager(), SLOT(projectShowFiles()), actionCollection(), "project_showfiles");
+ (void) new KAction(i18n("&Show Projects..."), 0, docManager(), TQT_SLOT(projectShow()), actionCollection(), "project_show");
+ (void) new KAction(i18n("Re&move Files From Project..."),"project_remove", 0, docManager(), TQT_SLOT(projectRemoveFiles()), actionCollection(), "project_remove");
+ (void) new KAction(i18n("Show Project &Files..."),"project_show", 0, docManager(), TQT_SLOT(projectShowFiles()), actionCollection(), "project_showfiles");
// tbraun
- (void) new KAction(i18n("Open All &Project Files"), 0, docManager(), SLOT(projectOpenAllFiles()), actionCollection(), "project_openallfiles");
- (void) new KAction(i18n("Find in &Project..."), "projectgrep", 0, this, SLOT(findInProjects()), actionCollection(),"project_findfiles" );
+ (void) new KAction(i18n("Open All &Project Files"), 0, docManager(), TQT_SLOT(projectOpenAllFiles()), actionCollection(), "project_openallfiles");
+ (void) new KAction(i18n("Find in &Project..."), "projectgrep", 0, TQT_TQOBJECT(this), TQT_SLOT(findInProjects()), actionCollection(),"project_findfiles" );
//build actions
- (void) new KAction(i18n("Clean"),"trashcan_full",0 , this, SLOT(cleanAll()), actionCollection(),"CleanAll" );
- (void) new KAction(i18n("View Log File"),"viewlog", ALT+Key_0, m_errorHandler, SLOT(ViewLog()), actionCollection(),"ViewLog" );
- (void) new KAction(i18n("Previous LaTeX Error"),"errorprev", 0, m_errorHandler, SLOT(PreviousError()), actionCollection(),"PreviousError" );
- (void) new KAction(i18n("Next LaTeX Error"),"errornext", 0, m_errorHandler, SLOT(NextError()), actionCollection(),"NextError" );
- (void) new KAction(i18n("Previous LaTeX Warning"),"warnprev", 0, m_errorHandler, SLOT(PreviousWarning()), actionCollection(),"PreviousWarning" );
- (void) new KAction(i18n("Next LaTeX Warning"),"warnnext", 0, m_errorHandler, SLOT(NextWarning()), actionCollection(),"NextWarning" );
- (void) new KAction(i18n("Previous LaTeX BadBox"),"bboxprev", 0, m_errorHandler, SLOT(PreviousBadBox()), actionCollection(),"PreviousBadBox" );
- (void) new KAction(i18n("Next LaTeX BadBox"),"bboxnext", 0, m_errorHandler, SLOT(NextBadBox()), actionCollection(),"NextBadBox" );
+ (void) new KAction(i18n("Clean"),"trashcan_full",0 , TQT_TQOBJECT(this), TQT_SLOT(cleanAll()), actionCollection(),"CleanAll" );
+ (void) new KAction(i18n("View Log File"),"viewlog", ALT+Key_0, m_errorHandler, TQT_SLOT(ViewLog()), actionCollection(),"ViewLog" );
+ (void) new KAction(i18n("Previous LaTeX Error"),"errorprev", 0, m_errorHandler, TQT_SLOT(PreviousError()), actionCollection(),"PreviousError" );
+ (void) new KAction(i18n("Next LaTeX Error"),"errornext", 0, m_errorHandler, TQT_SLOT(NextError()), actionCollection(),"NextError" );
+ (void) new KAction(i18n("Previous LaTeX Warning"),"warnprev", 0, m_errorHandler, TQT_SLOT(PreviousWarning()), actionCollection(),"PreviousWarning" );
+ (void) new KAction(i18n("Next LaTeX Warning"),"warnnext", 0, m_errorHandler, TQT_SLOT(NextWarning()), actionCollection(),"NextWarning" );
+ (void) new KAction(i18n("Previous LaTeX BadBox"),"bboxprev", 0, m_errorHandler, TQT_SLOT(PreviousBadBox()), actionCollection(),"PreviousBadBox" );
+ (void) new KAction(i18n("Next LaTeX BadBox"),"bboxnext", 0, m_errorHandler, TQT_SLOT(NextBadBox()), actionCollection(),"NextBadBox" );
m_paStop = new KAction(i18n("&Stop"),"stop",Key_Escape,0,0,actionCollection(),"Stop");
m_paStop->setEnabled(false);
- (void) new KAction(i18n("Editor View"),"edit",CTRL+Key_E , this, SLOT(showEditorWidget()), actionCollection(),"EditorView" );
- (void) new KAction(i18n("Next Document"),"forward",ALT+Key_Right, viewManager(), SLOT(gotoNextView()), actionCollection(), "gotoNextDocument" );
- (void) new KAction(i18n("Previous Document"),"back",ALT+Key_Left, viewManager(), SLOT(gotoPrevView()), actionCollection(), "gotoPrevDocument" );
- (void) new KAction(i18n("Focus Log/Messages View"), CTRL+ALT+Key_M, this, SLOT(focusLog()), actionCollection(), "focus_log");
- (void) new KAction(i18n("Focus Output View"), CTRL+ALT+Key_O, this, SLOT(focusOutput()), actionCollection(), "focus_output");
- (void) new KAction(i18n("Focus Konsole View"), CTRL+ALT+Key_K, this, SLOT(focusKonsole()), actionCollection(), "focus_konsole");
- (void) new KAction(i18n("Focus Editor View"), CTRL+ALT+Key_E, this, SLOT(focusEditor()), actionCollection(), "focus_editor");
+ (void) new KAction(i18n("Editor View"),"edit",CTRL+Key_E , TQT_TQOBJECT(this), TQT_SLOT(showEditorWidget()), actionCollection(),"EditorView" );
+ (void) new KAction(i18n("Next Document"),"forward",ALT+Key_Right, viewManager(), TQT_SLOT(gotoNextView()), actionCollection(), "gotoNextDocument" );
+ (void) new KAction(i18n("Previous Document"),"back",ALT+Key_Left, viewManager(), TQT_SLOT(gotoPrevView()), actionCollection(), "gotoPrevDocument" );
+ (void) new KAction(i18n("Focus Log/Messages View"), CTRL+ALT+Key_M, TQT_TQOBJECT(this), TQT_SLOT(focusLog()), actionCollection(), "focus_log");
+ (void) new KAction(i18n("Focus Output View"), CTRL+ALT+Key_O, TQT_TQOBJECT(this), TQT_SLOT(focusOutput()), actionCollection(), "focus_output");
+ (void) new KAction(i18n("Focus Konsole View"), CTRL+ALT+Key_K, TQT_TQOBJECT(this), TQT_SLOT(focusKonsole()), actionCollection(), "focus_konsole");
+ (void) new KAction(i18n("Focus Editor View"), CTRL+ALT+Key_E, TQT_TQOBJECT(this), TQT_SLOT(focusEditor()), actionCollection(), "focus_editor");
// CodeCompletion (dani)
- (void) new KAction(i18n("(La)TeX Command"),"complete1",CTRL+Key_Space, m_edit, SLOT(completeWord()), actionCollection(), "edit_complete_word");
- (void) new KAction(i18n("Environment"),"complete2",ALT+Key_Space, m_edit, SLOT(completeEnvironment()), actionCollection(), "edit_complete_env");
- (void) new KAction(i18n("Abbreviation"),"complete3",CTRL+ALT+Key_Space, m_edit, SLOT(completeAbbreviation()), actionCollection(), "edit_complete_abbrev");
+ (void) new KAction(i18n("(La)TeX Command"),"complete1",CTRL+Key_Space, m_edit, TQT_SLOT(completeWord()), actionCollection(), "edit_complete_word");
+ (void) new KAction(i18n("Environment"),"complete2",ALT+Key_Space, m_edit, TQT_SLOT(completeEnvironment()), actionCollection(), "edit_complete_env");
+ (void) new KAction(i18n("Abbreviation"),"complete3",CTRL+ALT+Key_Space, m_edit, TQT_SLOT(completeAbbreviation()), actionCollection(), "edit_complete_abbrev");
- (void) new KAction(i18n("Next Bullet"),"nextbullet",CTRL+ALT+Key_Right, m_edit, SLOT(nextBullet()), actionCollection(), "edit_next_bullet");
- (void) new KAction(i18n("Prev Bullet"),"prevbullet",CTRL+ALT+Key_Left, m_edit, SLOT(prevBullet()), actionCollection(), "edit_prev_bullet");
+ (void) new KAction(i18n("Next Bullet"),"nextbullet",CTRL+ALT+Key_Right, m_edit, TQT_SLOT(nextBullet()), actionCollection(), "edit_next_bullet");
+ (void) new KAction(i18n("Prev Bullet"),"prevbullet",CTRL+ALT+Key_Left, m_edit, TQT_SLOT(prevBullet()), actionCollection(), "edit_prev_bullet");
// advanced editor (dani)
- (void) new KAction(i18n("Environment (inside)"),"selenv_i",KShortcut("CTRL+Alt+S,E"), m_edit, SLOT(selectEnvInside()), actionCollection(), "edit_select_inside_env");
- (void) new KAction(i18n("Environment (outside)"),"selenv_o",KShortcut("CTRL+Alt+S,F"), m_edit, SLOT(selectEnvOutside()), actionCollection(), "edit_select_outside_env");
- (void) new KAction(i18n("TeX Group (inside)"),"selgroup_i",KShortcut("CTRL+Alt+S,T"), m_edit, SLOT(selectTexgroupInside()), actionCollection(), "edit_select_inside_group");
- (void) new KAction(i18n("TeX Group (outside)"), "selgroup_o",KShortcut("CTRL+Alt+S,U"),m_edit, SLOT(selectTexgroupOutside()), actionCollection(), "edit_select_outside_group");
- (void) new KAction(i18n("Math Group"), "selmath",KShortcut("CTRL+Alt+S,M"),m_edit, SLOT(selectMathgroup()), actionCollection(), "edit_select_mathgroup");
- (void) new KAction(i18n("Paragraph"),"selpar",KShortcut("CTRL+Alt+S,P"),m_edit, SLOT(selectParagraph()), actionCollection(), "edit_select_paragraph");
- (void) new KAction(i18n("Line"),"selline",KShortcut("CTRL+Alt+S,L"),m_edit, SLOT(selectLine()), actionCollection(), "edit_select_line");
- (void) new KAction(i18n("TeX Word"),"selword",KShortcut("CTRL+Alt+S,W"),m_edit, SLOT(selectWord()), actionCollection(), "edit_select_word");
-
- (void) new KAction(i18n("Environment (inside)"),"delenv_i",KShortcut("CTRL+Alt+T,E"), m_edit, SLOT(deleteEnvInside()), actionCollection(), "edit_delete_inside_env");
- (void) new KAction(i18n("Environment (outside)"),"delenv_o",KShortcut("CTRL+Alt+T,F"),m_edit, SLOT(deleteEnvOutside()), actionCollection(), "edit_delete_outside_env");
- (void) new KAction(i18n("TeX Group (inside)"),"delgroup_i",KShortcut("CTRL+Alt+T,T"), m_edit, SLOT(deleteTexgroupInside()), actionCollection(),"edit_delete_inside_group");
- (void) new KAction(i18n("TeX Group (outside)"),"delgroup_o",KShortcut("CTRL+Alt+T,U"),m_edit, SLOT(deleteTexgroupInside()), actionCollection(), "edit_delete_outside_group");
- (void) new KAction(i18n("Math Group"),"delmath",KShortcut("CTRL+Alt+T,M"),m_edit, SLOT(deleteMathgroup()), actionCollection(), "edit_delete_mathgroup");
- (void) new KAction(i18n("Paragraph"),"delpar",KShortcut("CTRL+Alt+T,P"),m_edit, SLOT(deleteParagraph()), actionCollection(), "edit_delete_paragraph");
- (void) new KAction(i18n("To End of Line"),"deleol",KShortcut("CTRL+Alt+T,I"),m_edit, SLOT(deleteEndOfLine()), actionCollection(), "edit_delete_eol");
- (void) new KAction(i18n("TeX Word"),"delword",KShortcut("CTRL+Alt+T,W"),m_edit, SLOT(deleteWord()), actionCollection(), "edit_delete_word");
-
- (void) new KAction(i18n("Goto Begin"),"gotobeginenv",KShortcut("CTRL+Alt+E,B"), m_edit, SLOT(gotoBeginEnv()), actionCollection(), "edit_begin_env");
- (void) new KAction(i18n("Goto End"),"gotoendenv",KShortcut("CTRL+Alt+E,E"), m_edit, SLOT(gotoEndEnv()), actionCollection(), "edit_end_env");
- (void) new KAction(i18n("Match"),"matchenv",KShortcut("CTRL+Alt+E,M"), m_edit, SLOT(matchEnv()), actionCollection(), "edit_match_env");
- (void) new KAction(i18n("Close"),"closeenv",KShortcut("CTRL+Alt+E,C"), m_edit, SLOT(closeEnv()), actionCollection(), "edit_close_env");
- (void) new KAction(i18n("Close All"),"closeallenv",KShortcut("CTRL+Alt+E,A"), m_edit, SLOT(closeAllEnv()), actionCollection(), "edit_closeall_env");
-
- (void) new KAction(i18n("Goto Begin"),"gotobegingroup",KShortcut("CTRL+Alt+G,B"), m_edit, SLOT(gotoBeginTexgroup()), actionCollection(), "edit_begin_group");
- (void) new KAction(i18n("Goto End"),"gotoendgroup",KShortcut("CTRL+Alt+G,E"), m_edit, SLOT(gotoEndTexgroup()), actionCollection(), "edit_end_group");
- (void) new KAction(i18n("Match"),"matchgroup",KShortcut("CTRL+Alt+G,M"), m_edit, SLOT(matchTexgroup()), actionCollection(), "edit_match_group");
- (void) new KAction(i18n("Close"),"closegroup",KShortcut("CTRL+Alt+G,C"), m_edit, SLOT(closeTexgroup()), actionCollection(), "edit_close_group");
-
- (void) new KAction(i18n("Selection"),"preview_sel",KShortcut("CTRL+Alt+P,S"), this, SLOT(quickPreviewSelection()), actionCollection(),"quickpreview_selection" );
- (void) new KAction(i18n("Environment"),"preview_env",KShortcut("CTRL+Alt+P,E"), this, SLOT(quickPreviewEnvironment()), actionCollection(),"quickpreview_environment" );
- (void) new KAction(i18n("Subdocument"),"preview_subdoc",KShortcut("CTRL+Alt+P,D"), this, SLOT(quickPreviewSubdocument()), actionCollection(),"quickpreview_subdocument" );
- (void) new KAction (i18n ("Mathgroup"), "edu_mathematics", KShortcut("CTRL+Alt+P,M"), this, SLOT(quickPreviewMathgroup()), actionCollection(), "quickpreview_math");
+ (void) new KAction(i18n("Environment (inside)"),"selenv_i",KShortcut("CTRL+Alt+S,E"), m_edit, TQT_SLOT(selectEnvInside()), actionCollection(), "edit_select_inside_env");
+ (void) new KAction(i18n("Environment (outside)"),"selenv_o",KShortcut("CTRL+Alt+S,F"), m_edit, TQT_SLOT(selectEnvOutside()), actionCollection(), "edit_select_outside_env");
+ (void) new KAction(i18n("TeX Group (inside)"),"selgroup_i",KShortcut("CTRL+Alt+S,T"), m_edit, TQT_SLOT(selectTexgroupInside()), actionCollection(), "edit_select_inside_group");
+ (void) new KAction(i18n("TeX Group (outside)"), "selgroup_o",KShortcut("CTRL+Alt+S,U"),m_edit, TQT_SLOT(selectTexgroupOutside()), actionCollection(), "edit_select_outside_group");
+ (void) new KAction(i18n("Math Group"), "selmath",KShortcut("CTRL+Alt+S,M"),m_edit, TQT_SLOT(selectMathgroup()), actionCollection(), "edit_select_mathgroup");
+ (void) new KAction(i18n("Paragraph"),"selpar",KShortcut("CTRL+Alt+S,P"),m_edit, TQT_SLOT(selectParagraph()), actionCollection(), "edit_select_paragraph");
+ (void) new KAction(i18n("Line"),"selline",KShortcut("CTRL+Alt+S,L"),m_edit, TQT_SLOT(selectLine()), actionCollection(), "edit_select_line");
+ (void) new KAction(i18n("TeX Word"),"selword",KShortcut("CTRL+Alt+S,W"),m_edit, TQT_SLOT(selectWord()), actionCollection(), "edit_select_word");
+
+ (void) new KAction(i18n("Environment (inside)"),"delenv_i",KShortcut("CTRL+Alt+T,E"), m_edit, TQT_SLOT(deleteEnvInside()), actionCollection(), "edit_delete_inside_env");
+ (void) new KAction(i18n("Environment (outside)"),"delenv_o",KShortcut("CTRL+Alt+T,F"),m_edit, TQT_SLOT(deleteEnvOutside()), actionCollection(), "edit_delete_outside_env");
+ (void) new KAction(i18n("TeX Group (inside)"),"delgroup_i",KShortcut("CTRL+Alt+T,T"), m_edit, TQT_SLOT(deleteTexgroupInside()), actionCollection(),"edit_delete_inside_group");
+ (void) new KAction(i18n("TeX Group (outside)"),"delgroup_o",KShortcut("CTRL+Alt+T,U"),m_edit, TQT_SLOT(deleteTexgroupInside()), actionCollection(), "edit_delete_outside_group");
+ (void) new KAction(i18n("Math Group"),"delmath",KShortcut("CTRL+Alt+T,M"),m_edit, TQT_SLOT(deleteMathgroup()), actionCollection(), "edit_delete_mathgroup");
+ (void) new KAction(i18n("Paragraph"),"delpar",KShortcut("CTRL+Alt+T,P"),m_edit, TQT_SLOT(deleteParagraph()), actionCollection(), "edit_delete_paragraph");
+ (void) new KAction(i18n("To End of Line"),"deleol",KShortcut("CTRL+Alt+T,I"),m_edit, TQT_SLOT(deleteEndOfLine()), actionCollection(), "edit_delete_eol");
+ (void) new KAction(i18n("TeX Word"),"delword",KShortcut("CTRL+Alt+T,W"),m_edit, TQT_SLOT(deleteWord()), actionCollection(), "edit_delete_word");
+
+ (void) new KAction(i18n("Goto Begin"),"gotobeginenv",KShortcut("CTRL+Alt+E,B"), m_edit, TQT_SLOT(gotoBeginEnv()), actionCollection(), "edit_begin_env");
+ (void) new KAction(i18n("Goto End"),"gotoendenv",KShortcut("CTRL+Alt+E,E"), m_edit, TQT_SLOT(gotoEndEnv()), actionCollection(), "edit_end_env");
+ (void) new KAction(i18n("Match"),"matchenv",KShortcut("CTRL+Alt+E,M"), m_edit, TQT_SLOT(matchEnv()), actionCollection(), "edit_match_env");
+ (void) new KAction(i18n("Close"),"closeenv",KShortcut("CTRL+Alt+E,C"), m_edit, TQT_SLOT(closeEnv()), actionCollection(), "edit_close_env");
+ (void) new KAction(i18n("Close All"),"closeallenv",KShortcut("CTRL+Alt+E,A"), m_edit, TQT_SLOT(closeAllEnv()), actionCollection(), "edit_closeall_env");
+
+ (void) new KAction(i18n("Goto Begin"),"gotobegingroup",KShortcut("CTRL+Alt+G,B"), m_edit, TQT_SLOT(gotoBeginTexgroup()), actionCollection(), "edit_begin_group");
+ (void) new KAction(i18n("Goto End"),"gotoendgroup",KShortcut("CTRL+Alt+G,E"), m_edit, TQT_SLOT(gotoEndTexgroup()), actionCollection(), "edit_end_group");
+ (void) new KAction(i18n("Match"),"matchgroup",KShortcut("CTRL+Alt+G,M"), m_edit, TQT_SLOT(matchTexgroup()), actionCollection(), "edit_match_group");
+ (void) new KAction(i18n("Close"),"closegroup",KShortcut("CTRL+Alt+G,C"), m_edit, TQT_SLOT(closeTexgroup()), actionCollection(), "edit_close_group");
+
+ (void) new KAction(i18n("Selection"),"preview_sel",KShortcut("CTRL+Alt+P,S"), TQT_TQOBJECT(this), TQT_SLOT(quickPreviewSelection()), actionCollection(),"quickpreview_selection" );
+ (void) new KAction(i18n("Environment"),"preview_env",KShortcut("CTRL+Alt+P,E"), TQT_TQOBJECT(this), TQT_SLOT(quickPreviewEnvironment()), actionCollection(),"quickpreview_environment" );
+ (void) new KAction(i18n("Subdocument"),"preview_subdoc",KShortcut("CTRL+Alt+P,D"), TQT_TQOBJECT(this), TQT_SLOT(quickPreviewSubdocument()), actionCollection(),"quickpreview_subdocument" );
+ (void) new KAction (i18n ("Mathgroup"), "edu_mathematics", KShortcut("CTRL+Alt+P,M"), TQT_TQOBJECT(this), TQT_SLOT(quickPreviewMathgroup()), actionCollection(), "quickpreview_math");
KileStdActions::setupStdTags(this,this);
KileStdActions::setupMathTags(this);
KileStdActions::setupBibTags(this);
- (void) new KAction(i18n("Quick Start"),"quickwizard",0 , this, SLOT(quickDocument()), actionCollection(),"wizard_document" );
- connect(docManager(), SIGNAL(startWizard()), this, SLOT(quickDocument()));
- (void) new KAction(i18n("Tabular"),"wizard_tabular",0 , this, SLOT(quickTabular()), actionCollection(),"wizard_tabular" );
- (void) new KAction(i18n("Array"),"wizard_array",0 , this, SLOT(quickArray()), actionCollection(),"wizard_array" );
- (void) new KAction(i18n("Tabbing"),"wizard_tabbing",0 , this, SLOT(quickTabbing()), actionCollection(),"wizard_tabbing" );
- (void) new KAction(i18n("Floats"),"wizard_float",0, this, SLOT(quickFloat()), actionCollection(),"wizard_float" );
- (void) new KAction(i18n("Math"),"wizard_math",0, this, SLOT(quickMathenv()), actionCollection(),"wizard_mathenv" );
- (void) new KAction(i18n("Postscript Tools"),"wizard_pstools",0 , this, SLOT(quickPostscript()), actionCollection(),"wizard_postscript" );
+ (void) new KAction(i18n("Quick Start"),"quickwizard",0 , TQT_TQOBJECT(this), TQT_SLOT(quickDocument()), actionCollection(),"wizard_document" );
+ connect(docManager(), TQT_SIGNAL(startWizard()), TQT_TQOBJECT(this), TQT_SLOT(quickDocument()));
+ (void) new KAction(i18n("Tabular"),"wizard_tabular",0 , TQT_TQOBJECT(this), TQT_SLOT(quickTabular()), actionCollection(),"wizard_tabular" );
+ (void) new KAction(i18n("Array"),"wizard_array",0 , TQT_TQOBJECT(this), TQT_SLOT(quickArray()), actionCollection(),"wizard_array" );
+ (void) new KAction(i18n("Tabbing"),"wizard_tabbing",0 , TQT_TQOBJECT(this), TQT_SLOT(quickTabbing()), actionCollection(),"wizard_tabbing" );
+ (void) new KAction(i18n("Floats"),"wizard_float",0, TQT_TQOBJECT(this), TQT_SLOT(quickFloat()), actionCollection(),"wizard_float" );
+ (void) new KAction(i18n("Math"),"wizard_math",0, TQT_TQOBJECT(this), TQT_SLOT(quickMathenv()), actionCollection(),"wizard_mathenv" );
+ (void) new KAction(i18n("Postscript Tools"),"wizard_pstools",0 , TQT_TQOBJECT(this), TQT_SLOT(quickPostscript()), actionCollection(),"wizard_postscript" );
- (void) new KAction(i18n("Clean"),0 , this, SLOT(cleanBib()), actionCollection(),"CleanBib" );
+ (void) new KAction(i18n("Clean"),0 , TQT_TQOBJECT(this), TQT_SLOT(cleanBib()), actionCollection(),"CleanBib" );
- ModeAction=new KToggleAction(i18n("Define Current Document as '&Master Document'"),"master",0 , this, SLOT(toggleMode()), actionCollection(),"Mode" );
+ ModeAction=new KToggleAction(i18n("Define Current Document as '&Master Document'"),"master",0 , TQT_TQOBJECT(this), TQT_SLOT(toggleMode()), actionCollection(),"Mode" );
KToggleAction *tact = new KToggleAction(i18n("Show S&ide Bar"), 0, 0, 0, actionCollection(),"StructureView" );
tact->setChecked(KileConfig::sideBar());
- connect(tact, SIGNAL(toggled(bool)), m_sideBar, SLOT(setVisible(bool)));
- connect(m_sideBar, SIGNAL(visibilityChanged(bool )), tact, SLOT(setChecked(bool)));
- connect(m_sideBar, SIGNAL(visibilityChanged(bool )), this, SLOT(sideOrBottomBarChanged(bool)));
+ connect(tact, TQT_SIGNAL(toggled(bool)), m_sideBar, TQT_SLOT(setVisible(bool)));
+ connect(m_sideBar, TQT_SIGNAL(visibilityChanged(bool )), tact, TQT_SLOT(setChecked(bool)));
+ connect(m_sideBar, TQT_SIGNAL(visibilityChanged(bool )), TQT_TQOBJECT(this), TQT_SLOT(sideOrBottomBarChanged(bool)));
m_actionMessageView = new KToggleAction(i18n("Show Mess&ages Bar"), 0, 0, 0, actionCollection(),"MessageView" );
m_actionMessageView->setChecked(true);
- connect(m_actionMessageView, SIGNAL(toggled(bool)), m_bottomBar, SLOT(setVisible(bool)));
- connect(m_bottomBar, SIGNAL(visibilityChanged(bool )), m_actionMessageView, SLOT(setChecked(bool)));
- connect(m_bottomBar, SIGNAL(visibilityChanged(bool )), this, SLOT(sideOrBottomBarChanged(bool)));
+ connect(m_actionMessageView, TQT_SIGNAL(toggled(bool)), m_bottomBar, TQT_SLOT(setVisible(bool)));
+ connect(m_bottomBar, TQT_SIGNAL(visibilityChanged(bool )), m_actionMessageView, TQT_SLOT(setChecked(bool)));
+ connect(m_bottomBar, TQT_SIGNAL(visibilityChanged(bool )), TQT_TQOBJECT(this), TQT_SLOT(sideOrBottomBarChanged(bool)));
if (m_singlemode) {ModeAction->setChecked(false);}
else {ModeAction->setChecked(true);}
- WatchFileAction=new KToggleAction(i18n("Watch File Mode"),"watchfile",0 , this, SLOT(toggleWatchFile()), actionCollection(), "WatchFile");
+ WatchFileAction=new KToggleAction(i18n("Watch File Mode"),"watchfile",0 , TQT_TQOBJECT(this), TQT_SLOT(toggleWatchFile()), actionCollection(), "WatchFile");
if (m_bWatchFile) {WatchFileAction->setChecked(true);}
else {WatchFileAction->setChecked(false);}
@@ -655,27 +655,27 @@ void Kile::setupActions()
const KAboutData *aboutData = KGlobal::instance()->aboutData();
KHelpMenu *help_menu = new KHelpMenu( this, aboutData);
- KStdAction::tipOfDay(this, SLOT(showTip()), actionCollection(), "help_tipofday");
-
- (void) new KAction(i18n("TeX Guide"),KShortcut("CTRL+Alt+H,G"), m_help, SLOT(helpTexGuide()), actionCollection(), "help_tex_guide");
- (void) new KAction(i18n("LaTeX"),KShortcut("CTRL+Alt+H,L"), m_help, SLOT(helpLatexIndex()), actionCollection(), "help_latex_index");
- (void) new KAction(i18n("LaTeX Command"),KShortcut("CTRL+Alt+H,C"), m_help, SLOT(helpLatexCommand()), actionCollection(), "help_latex_command");
- (void) new KAction(i18n("LaTeX Subject"),KShortcut("CTRL+Alt+H,S"), m_help, SLOT(helpLatexSubject()), actionCollection(), "help_latex_subject");
- (void) new KAction(i18n("LaTeX Env"),KShortcut("CTRL+Alt+H,E"), m_help, SLOT(helpLatexEnvironment()), actionCollection(), "help_latex_env");
- (void) new KAction(i18n("Context Help"),KShortcut("CTRL+Alt+H,K"), m_help, SLOT(helpKeyword()), actionCollection(), "help_context");
- (void) new KAction(i18n("Documentation Browser"),KShortcut("CTRL+Alt+H,B"), m_help, SLOT(helpDocBrowser()), actionCollection(), "help_docbrowser");
-
- (void) new KAction(i18n("LaTeX Reference"),"help",0 , this, SLOT(helpLaTex()), actionCollection(),"help_latex_reference" );
- (void) KStdAction::helpContents(help_menu, SLOT(appHelpActivated()), actionCollection(), "help_handbook");
- (void) KStdAction::reportBug (help_menu, SLOT(reportBug()), actionCollection(), "report_bug");
- (void) KStdAction::aboutApp(help_menu, SLOT(aboutApplication()), actionCollection(),"help_aboutKile" );
- (void) KStdAction::aboutKDE(help_menu, SLOT(aboutKDE()), actionCollection(),"help_aboutKDE" );
- KAction *kileconfig = KStdAction::preferences(this, SLOT(generalOptions()), actionCollection(),"settings_configure" );
+ KStdAction::tipOfDay(TQT_TQOBJECT(this), TQT_SLOT(showTip()), actionCollection(), "help_tipofday");
+
+ (void) new KAction(i18n("TeX Guide"),KShortcut("CTRL+Alt+H,G"), m_help, TQT_SLOT(helpTexGuide()), actionCollection(), "help_tex_guide");
+ (void) new KAction(i18n("LaTeX"),KShortcut("CTRL+Alt+H,L"), m_help, TQT_SLOT(helpLatexIndex()), actionCollection(), "help_latex_index");
+ (void) new KAction(i18n("LaTeX Command"),KShortcut("CTRL+Alt+H,C"), m_help, TQT_SLOT(helpLatexCommand()), actionCollection(), "help_latex_command");
+ (void) new KAction(i18n("LaTeX Subject"),KShortcut("CTRL+Alt+H,S"), m_help, TQT_SLOT(helpLatexSubject()), actionCollection(), "help_latex_subject");
+ (void) new KAction(i18n("LaTeX Env"),KShortcut("CTRL+Alt+H,E"), m_help, TQT_SLOT(helpLatexEnvironment()), actionCollection(), "help_latex_env");
+ (void) new KAction(i18n("Context Help"),KShortcut("CTRL+Alt+H,K"), m_help, TQT_SLOT(helpKeyword()), actionCollection(), "help_context");
+ (void) new KAction(i18n("Documentation Browser"),KShortcut("CTRL+Alt+H,B"), m_help, TQT_SLOT(helpDocBrowser()), actionCollection(), "help_docbrowser");
+
+ (void) new KAction(i18n("LaTeX Reference"),"help",0 , TQT_TQOBJECT(this), TQT_SLOT(helpLaTex()), actionCollection(),"help_latex_reference" );
+ (void) KStdAction::helpContents(help_menu, TQT_SLOT(appHelpActivated()), actionCollection(), "help_handbook");
+ (void) KStdAction::reportBug (help_menu, TQT_SLOT(reportBug()), actionCollection(), "report_bug");
+ (void) KStdAction::aboutApp(help_menu, TQT_SLOT(aboutApplication()), actionCollection(),"help_aboutKile" );
+ (void) KStdAction::aboutKDE(help_menu, TQT_SLOT(aboutKDE()), actionCollection(),"help_aboutKDE" );
+ KAction *kileconfig = KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(generalOptions()), actionCollection(),"settings_configure" );
kileconfig->setIcon("configure_kile");
- (void) KStdAction::keyBindings(this, SLOT(configureKeys()), actionCollection(),"settings_keys" );
- (void) KStdAction::configureToolbars(this, SLOT(configureToolbars()), actionCollection(),"settings_toolbars" );
- new KAction(i18n("&System Check..."), 0, this, SLOT(slotPerformCheck()), actionCollection(), "settings_perform_check");
+ (void) KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(configureKeys()), actionCollection(),"settings_keys" );
+ (void) KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(configureToolbars()), actionCollection(),"settings_toolbars" );
+ new KAction(i18n("&System Check..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotPerformCheck()), actionCollection(), "settings_perform_check");
m_menuUserTags = new KActionMenu(i18n("User Tags"), SmallIcon("label"), actionCollection(),"menuUserTags");
m_menuUserTags->setDelayed(false);
@@ -683,15 +683,15 @@ void Kile::setupActions()
actionCollection()->readShortcutSettings();
- m_pFullScreen = KStdAction::fullScreen(this, SLOT(slotToggleFullScreen()), actionCollection(), this);
+ m_pFullScreen = KStdAction::fullScreen(TQT_TQOBJECT(this), TQT_SLOT(slotToggleFullScreen()), actionCollection(), this);
}
void Kile::setupTools()
{
KILE_DEBUG() << "==Kile::setupTools()===================" << endl;
- QStringList tools = KileTool::toolList(m_config);
- QString toolMenu;
- QPtrList<KAction> *pl;
+ TQStringList tools = KileTool::toolList(m_config);
+ TQString toolMenu;
+ TQPtrList<KAction> *pl;
unplugActionList("list_compilers");
unplugActionList("list_converters");
@@ -701,7 +701,7 @@ void Kile::setupTools()
for ( uint i = 0; i < tools.count(); ++i)
{
- QString grp = KileTool::groupFor(tools[i], m_config);
+ TQString grp = KileTool::groupFor(tools[i], m_config);
KILE_DEBUG() << tools[i] << " is using group: " << grp << endl;
m_config->setGroup(KileTool::groupFor(tools[i], m_config));
toolMenu = KileTool::menuFor(tools[i], m_config);
@@ -721,9 +721,9 @@ void Kile::setupTools()
KILE_DEBUG() << "\tadding " << tools[i] << " " << toolMenu << " #" << pl->count() << endl;
- if ( action(QString("tool_"+tools[i]).ascii()) == 0L )
+ if ( action(TQString("tool_"+tools[i]).ascii()) == 0L )
{
- KAction *act = new KAction(tools[i], KileTool::iconFor(tools[i], m_config), KShortcut(), this, SLOT(runTool()), actionCollection(), QString("tool_"+tools[i]).ascii());
+ KAction *act = new KAction(tools[i], KileTool::iconFor(tools[i], m_config), KShortcut(), TQT_TQOBJECT(this), TQT_SLOT(runTool()), actionCollection(), TQString("tool_"+tools[i]).ascii());
pl->append(act);
}
}
@@ -743,11 +743,11 @@ void Kile::setupTools()
actionCollection()->readShortcutSettings("Shortcuts", m_config);
}
-void Kile::cleanUpActionList(QPtrList<KAction> &list, const QStringList & tools)
+void Kile::cleanUpActionList(TQPtrList<KAction> &list, const TQStringList & tools)
{
for ( KAction *act = list.first(); act; act = list.next() )
{
- if ( action(act->name()) != 0L && !tools.contains(QString(act->name()).mid(5)) )
+ if ( action(act->name()) != 0L && !tools.tqcontains(TQString(act->name()).mid(5)) )
{
list.remove(act);
if ( act->isPlugged(toolBar("toolsToolBar")) ) act->unplug(toolBar("toolsToolBar"));
@@ -760,7 +760,7 @@ void Kile::setupUserTagActions()
KShortcut tagaccels[10] = {CTRL+SHIFT+Key_1, CTRL+SHIFT+Key_2,CTRL+SHIFT+Key_3,CTRL+SHIFT+Key_4,CTRL+SHIFT+Key_5,CTRL+SHIFT+Key_6,CTRL+SHIFT+Key_7,
CTRL+SHIFT+Key_8,CTRL+SHIFT+Key_9,CTRL+SHIFT+Key_0};
- m_actionEditTag = new KAction(i18n("Edit User Tags..."),0 , this, SLOT(editUserMenu()), m_menuUserTags,"EditUserMenu" );
+ m_actionEditTag = new KAction(i18n("Edit User Tags..."),0 , TQT_TQOBJECT(this), TQT_SLOT(editUserMenu()), m_menuUserTags,"EditUserMenu" );
m_menuUserTags->insert(m_actionEditTag);
if ( m_listUserTags.size() > 0 ) {
m_actionEditSeparator = new KActionSeparator();
@@ -769,8 +769,8 @@ void Kile::setupUserTagActions()
for (uint i=0; i<m_listUserTags.size(); ++i)
{
KShortcut sc; if (i<10) { sc = tagaccels[i]; } else { sc = 0; }
- QString name = QString::number(i+1)+": "+m_listUserTags[i].text;
- KileAction::Tag *menuItem = new KileAction::Tag(name, sc, this, SLOT(insertTag(const KileAction::TagData &)), actionCollection(), QString("tag_user_" + m_listUserTags[i].text).ascii(), m_listUserTags[i]);
+ TQString name = TQString::number(i+1)+": "+m_listUserTags[i].text;
+ KileAction::Tag *menuItem = new KileAction::Tag(name, sc, TQT_TQOBJECT(this), TQT_SLOT(insertTag(const KileAction::TagData &)), actionCollection(), TQString("tag_user_" + m_listUserTags[i].text).ascii(), m_listUserTags[i]);
m_listUserTagsActions.append(menuItem);
m_menuUserTags->insert(menuItem);
}
@@ -783,7 +783,7 @@ void Kile::restoreFilesAndProjects(bool allowRestore)
if (! (allowRestore && KileConfig::restore()) )
return;
- QFileInfo fi;
+ TQFileInfo fi;
KURL url;
for (uint i=0; i < m_listProjectsOpenOnStart.count(); ++i)
@@ -801,7 +801,7 @@ void Kile::restoreFilesAndProjects(bool allowRestore)
}
if (ModeAction) ModeAction->setChecked(!m_singlemode);
- updateModeStatus();
+ updateModetqStatus();
m_listProjectsOpenOnStart.clear();
m_listDocsOpenOnStart.clear();
@@ -823,7 +823,7 @@ void Kile::showTip()
KTipDialog::showTip(this, "kile/tips", true);
}
-void Kile::setLine( const QString &line )
+void Kile::setLine( const TQString &line )
{
bool ok;
uint l=line.toUInt(&ok,10);
@@ -836,7 +836,7 @@ void Kile::setLine( const QString &line )
view->gotoLineNumber(l-1);
showEditorWidget();
- newStatus();
+ newtqStatus();
}
}
@@ -868,18 +868,18 @@ void Kile::runArchiveTool(const KURL &url)
}
-int Kile::run(const QString & tool)
+int Kile::run(const TQString & tool)
{
return m_manager->runBlocking(tool);
}
-int Kile::runWith(const QString &tool, const QString &config)
+int Kile::runWith(const TQString &tool, const TQString &config)
{
return m_manager->runBlocking(tool, config);
}
//TODO: move to KileView::Manager
-void Kile::activateView(QWidget* w, bool updateStruct /* = true */ ) //Needs to be QWidget because of QTabWidget::currentChanged
+void Kile::activateView(TQWidget* w, bool updateStruct /* = true */ ) //Needs to be TQWidget because of TQTabWidget::currentChanged
{
//KILE_DEBUG() << "==Kile::activateView==========================" << endl;
if (!w->inherits("Kate::View"))
@@ -907,27 +907,27 @@ void Kile::activateView(QWidget* w, bool updateStruct /* = true */ ) //Needs to
if (updateStruct) viewManager()->updateStructure();
}
-void Kile::updateModeStatus()
+void Kile::updateModetqStatus()
{
- KILE_DEBUG() << "==Kile::updateModeStatus()==========" << endl;
+ KILE_DEBUG() << "==Kile::updateModetqStatus()==========" << endl;
KileProject *project = docManager()->activeProject();
- QString shortName = m_masterName;
- int pos = shortName.findRev('/');
+ TQString shortName = m_masterName;
+ int pos = shortName.tqfindRev('/');
shortName.remove(0,pos+1);
if (project)
{
if (m_singlemode)
- statusBar()->changeItem(i18n("Project: %1").arg(project->name()), ID_HINTTEXT);
+ statusBar()->changeItem(i18n("Project: %1").tqarg(project->name()), ID_HINTTEXT);
else
- statusBar()->changeItem(i18n("Project: %1 (Master document: %2)").arg(project->name()).arg(shortName), ID_HINTTEXT);
+ statusBar()->changeItem(i18n("Project: %1 (Master document: %2)").tqarg(project->name()).tqarg(shortName), ID_HINTTEXT);
}
else
{
if (m_singlemode)
statusBar()->changeItem(i18n("Normal mode"), ID_HINTTEXT);
else
- statusBar()->changeItem(i18n("Master document: %1").arg(shortName), ID_HINTTEXT);
+ statusBar()->changeItem(i18n("Master document: %1").tqarg(shortName), ID_HINTTEXT);
}
if (m_singlemode)
@@ -937,7 +937,7 @@ void Kile::updateModeStatus()
}
else
{
- ModeAction->setText(i18n("Normal mode (current master document: %1)").arg(shortName));
+ ModeAction->setText(i18n("Normal mode (current master document: %1)").tqarg(shortName));
ModeAction->setChecked(true);
}
@@ -945,7 +945,7 @@ void Kile::updateModeStatus()
updateMenu();
}
-void Kile::openDocument(const QString & url)
+void Kile::openDocument(const TQString & url)
{
KILE_DEBUG() << "==Kile::openDocument(" << url << ")==========" << endl;
docManager()->fileSelected(KURL::fromPathOrURL(url));
@@ -973,7 +973,7 @@ void Kile::enableAutosave(bool as)
else m_AutosaveTimer->stop();
}
-void Kile::openProject(const QString& proj)
+void Kile::openProject(const TQString& proj)
{
docManager()->projectOpen(KURL::fromPathOrURL(proj));
}
@@ -1110,7 +1110,7 @@ void Kile::convertToEnc(Kate::Document *doc)
if (sender())
{
ConvertIO io(doc);
- QString name = QString(sender()->name()).section('_', -1);
+ TQString name = TQString(TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->name()).section('_', -1);
ConvertASCIIToEnc conv = ConvertASCIIToEnc(name, &io);
conv.convert();
doc->setEncoding(ConvertMap::encodingNameFor(name));
@@ -1118,7 +1118,7 @@ void Kile::convertToEnc(Kate::Document *doc)
}
////////////////// GENERAL SLOTS //////////////
-void Kile::newStatus(const QString & msg)
+void Kile::newtqStatus(const TQString & msg)
{
statusBar()->changeItem(msg,ID_LINE_COLUMN);
}
@@ -1150,25 +1150,25 @@ void Kile::newCaption()
setCaption("");
}
-void Kile::grepItemSelected(const QString &abs_filename, int line)
+void Kile::grepItemSelected(const TQString &abs_filename, int line)
{
KILE_DEBUG() << "Open file: "
<< abs_filename << " (" << line << ")" << endl;
docManager()->fileOpen(KURL::fromPathOrURL(abs_filename));
- setLine(QString::number(line));
+ setLine(TQString::number(line));
}
void Kile::findInFiles()
{
- static QGuardedPtr<KileGrepDialog> dlg = 0;
+ static TQGuardedPtr<KileGrepDialog> dlg = 0;
if ( ! dlg )
{
KILE_DEBUG() << "grep guard: create findInFiles dlg" << endl;
dlg = new KileGrepDialog(0L,this,KileGrep::Directory);
dlg->show();
- connect(dlg, SIGNAL(itemSelected(const QString &, int)),
- this, SLOT(grepItemSelected(const QString &, int)));
+ connect(dlg, TQT_SIGNAL(itemSelected(const TQString &, int)),
+ TQT_TQOBJECT(this), TQT_SLOT(grepItemSelected(const TQString &, int)));
}
else
{
@@ -1180,15 +1180,15 @@ void Kile::findInFiles()
void Kile::findInProjects()
{
- static QGuardedPtr<KileGrepDialog> project_dlg = 0;
+ static TQGuardedPtr<KileGrepDialog> project_dlg = 0;
if ( ! project_dlg )
{
KILE_DEBUG() << "grep guard: create findInProjects dlg" << endl;
project_dlg = new KileGrepDialog(0L,this,KileGrep::Project);
project_dlg->show();
- connect(project_dlg, SIGNAL(itemSelected(const QString &, int)),
- this, SLOT(grepItemSelected(const QString &, int)));
+ connect(project_dlg, TQT_SIGNAL(itemSelected(const TQString &, int)),
+ TQT_TQOBJECT(this), TQT_SLOT(grepItemSelected(const TQString &, int)));
}
else
{
@@ -1212,7 +1212,7 @@ void Kile::showEditorWidget()
if (view) view->setFocus();
setupStatusBar();
- updateModeStatus();
+ updateModetqStatus();
newCaption();
}
@@ -1238,7 +1238,7 @@ bool Kile::resetPart()
}
setupStatusBar();
- updateModeStatus();
+ updateModetqStatus();
newCaption();
m_currentState = "Editor";
@@ -1266,9 +1266,9 @@ void Kile::activePartGUI(KParts::Part * part)
//kghostview (which has the print action defined in
//a KParts::BrowserExtension)
KParts::BrowserExtension *ext = KParts::BrowserExtension::childObject(part);
- if (ext && ext->metaObject()->slotNames().contains( "print()" ) ) //part is a BrowserExtension, connect printAction()
+ if (ext && ext->tqmetaObject()->slotNames().tqcontains( "print()" ) ) //part is a BrowserExtension, connect printAction()
{
- connect(m_paPrint, SIGNAL(activated()), ext, SLOT(print()));
+ connect(m_paPrint, TQT_SIGNAL(activated()), ext, TQT_SLOT(print()));
m_paPrint->plug(toolBar("mainToolBar"),3); //plug this action into its default location
m_paPrint->setEnabled(true);
}
@@ -1285,7 +1285,7 @@ void Kile::activePartGUI(KParts::Part * part)
m_wantState = "Editor";
}
-void Kile::showToolBars(const QString & wantState)
+void Kile::showToolBars(const TQString & wantState)
{
// save state of all toolbars
static bool mainToolBar = true;
@@ -1347,12 +1347,12 @@ void Kile::setViewerToolBars()
void Kile::enableKileGUI(bool enable)
{
int id;
- QString text;
+ TQString text;
- QMenuBar *menubar = menuBar();
+ TQMenuBar *menubar = menuBar();
for (uint i=0; i<menubar->count(); ++i) {
id = menubar->idAt(i);
- QPopupMenu *popup = menubar->findItem(id)->popup();
+ TQPopupMenu *popup = menubar->tqfindItem(id)->popup();
if ( popup ) {
text = popup->name();
if ( text == "menu_build" ||
@@ -1373,7 +1373,7 @@ void Kile::enableKileGUI(bool enable)
void Kile::initMenu()
{
- QStringList projectlist,filelist,actionlist;
+ TQStringList projectlist,filelist,actionlist;
projectlist
<< "project_add" << "project_remove"
@@ -1453,8 +1453,8 @@ void Kile::initMenu()
<< "tag_textit" << "tag_textsl" << "tag_textbf" << "tag_underline"
<< "tag_texttt" << "tag_textsc" << "tag_emph" << "tag_strong"
<< "tag_rmfamily" << "tag_sffamily" << "tag_ttfamily"
- << "tag_mdseries" << "tag_bfseries" << "tag_upshape"
- << "tag_itshape" << "tag_slshape" << "tag_scshape"
+ << "tag_mdseries" << "tag_bfseries" << "tag_uptqshape"
+ << "tag_ittqshape" << "tag_sltqshape" << "tag_sctqshape"
<< "tag_newline" << "tag_newpage" << "tag_linebreak" << "tag_pagebreak"
<< "tag_bigskip" << "tag_medskip" << "tag_smallskip"
<< "tag_hspace" << "tag_hspace*" << "tag_vspace" << "tag_vspace*"
@@ -1478,9 +1478,9 @@ void Kile::initMenu()
setMenuItems(actionlist,m_dictMenuAction);
}
-void Kile::setMenuItems(QStringList &list, QMap<QString,bool> &dict)
+void Kile::setMenuItems(TQStringList &list, TQMap<TQString,bool> &dict)
{
- for ( QStringList::Iterator it=list.begin(); it!=list.end(); ++it ) {
+ for ( TQStringList::Iterator it=list.begin(); it!=list.end(); ++it ) {
dict[(*it)] = true;
}
}
@@ -1489,7 +1489,7 @@ void Kile::updateMenu()
{
KILE_DEBUG() << "==Kile::updateKileMenu()====================" << endl;
KAction *a;
- QMap<QString,bool>::Iterator it;
+ TQMap<TQString,bool>::Iterator it;
// update project menus
m_actRecentProjects->setEnabled( m_actRecentProjects->items().count() > 0 );
@@ -1511,18 +1511,18 @@ void Kile::updateMenu()
bool file_open = ( viewManager()->currentTextView() );
KILE_DEBUG() << "\tprojectopen=" << project_open << " fileopen=" << file_open << endl;
- QMenuBar *menubar = menuBar();
+ TQMenuBar *menubar = menuBar();
for ( uint i=0; i<menubar->count(); ++i ) {
int menu_id = menubar->idAt(i);
- QPopupMenu *menu = menubar->findItem(menu_id)->popup();
+ TQPopupMenu *menu = menubar->tqfindItem(menu_id)->popup();
if ( menu ) {
- QString menu_name = menu->name();
+ TQString menu_name = menu->name();
for ( uint j=0; j<menu->count(); ++j ) {
int sub_id = menu->idAt(j);
- QPopupMenu *submenu = menu->findItem(sub_id)->popup();
+ TQPopupMenu *submenu = menu->tqfindItem(sub_id)->popup();
if ( submenu ) {
- QString submenu_name = submenu->name();
- if ( m_dictMenuFile.contains(submenu_name) ) {
+ TQString submenu_name = submenu->name();
+ if ( m_dictMenuFile.tqcontains(submenu_name) ) {
// if ( m_menuFileList.findIndex( submenu_name ) >= 0 ) {
menu->setItemEnabled(sub_id, file_open);
}
@@ -1536,7 +1536,7 @@ void Kile::updateMenu()
KActionPtrList::Iterator itact;
for ( itact=actions.begin(); itact!=actions.end(); ++itact )
{
- if ( m_dictMenuAction.contains( (*itact)->name() ) )
+ if ( m_dictMenuAction.tqcontains( (*itact)->name() ) )
(*itact)->setEnabled(file_open);
}
@@ -1548,7 +1548,7 @@ void Kile::updateMenu()
}
-void Kile::updateActionList(QPtrList<KAction> *list, bool state)
+void Kile::updateActionList(TQPtrList<KAction> *list, bool state)
{
for ( KAction *a=list->first(); a; a=list->next() ) {
a->setEnabled(state);
@@ -1556,7 +1556,7 @@ void Kile::updateActionList(QPtrList<KAction> *list, bool state)
}
//TODO: move to KileView::Manager
-void Kile::prepareForPart(const QString & state)
+void Kile::prepareForPart(const TQString & state)
{
KILE_DEBUG() << "==Kile::prepareForPart====================" << endl;
@@ -1576,14 +1576,14 @@ void Kile::prepareForPart(const QString & state)
void Kile::runTool()
{
focusLog();
- QString name = sender()->name();
- name.replace(QRegExp("^.*tool_"), "");
+ TQString name = TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->name();
+ name.tqreplace(TQRegExp("^.*tool_"), "");
m_manager->run(name);
}
void Kile::cleanAll(KileDocument::TextInfo *docinfo)
{
- static QString noactivedoc = i18n("There is no active document or it is not saved.");
+ static TQString noactivedoc = i18n("There is no active document or it is not saved.");
if (docinfo == 0)
{
Kate::Document *doc = activeTextDocument();
@@ -1625,52 +1625,52 @@ void Kile::insertTag(const KileAction::TagData& data)
editorExtension()->insertTag(data, view);
}
-void Kile::insertTag(const QString& tagB, const QString& tagE, int dx, int dy)
+void Kile::insertTag(const TQString& tagB, const TQString& tagE, int dx, int dy)
{
- insertTag(KileAction::TagData(QString::null,tagB,tagE,dx,dy));
+ insertTag(KileAction::TagData(TQString(),tagB,tagE,dx,dy));
}
void Kile::insertAmsTag(const KileAction::TagData& data)
{
- insertTag(data, QStringList("amsmath"));
+ insertTag(data, TQStringList("amsmath"));
}
-void Kile::insertTag(const KileAction::TagData& data,const QStringList &pkgs)
+void Kile::insertTag(const KileAction::TagData& data,const TQStringList &pkgs)
{
- KILE_DEBUG() << "void Kile::insertTag(const KileAction::TagData& data,const QStringList " << pkgs.join(",") << ")" << endl;
+ KILE_DEBUG() << "void Kile::insertTag(const KileAction::TagData& data,const TQStringList " << pkgs.join(",") << ")" << endl;
insertTag(data);
KileDocument::Info *docinfo = docManager()->textInfoFor(getCompileName());
if ( docinfo )
{
- const QStringList *packagelist = allPackages(docinfo);
- QStringList::const_iterator it;
- QStringList warnPkgs;
+ const TQStringList *packagelist = allPackages(docinfo);
+ TQStringList::const_iterator it;
+ TQStringList warnPkgs;
for ( it = pkgs.begin() ; it != pkgs.end() ; it++ )
- if( !(*packagelist).contains(*it) )
+ if( !(*packagelist).tqcontains(*it) )
warnPkgs.append(*it);
if( warnPkgs.count() > 0 )
{
if( warnPkgs.count() == 1 )
- m_logWidget->printMsg(KileTool::Error, i18n("You have to include the package %1.").arg(warnPkgs.join(",")),
+ m_logWidget->printMsg(KileTool::Error, i18n("You have to include the package %1.").tqarg(warnPkgs.join(",")),
i18n("Insert text"));
else
- m_logWidget->printMsg(KileTool::Error, i18n("You have to include the packages %1.").arg(warnPkgs.join(",")),
+ m_logWidget->printMsg(KileTool::Error, i18n("You have to include the packages %1.").tqarg(warnPkgs.join(",")),
i18n("Insert text"));
}
}
}
-void Kile::insertText(const QString &text)
+void Kile::insertText(const TQString &text)
{
- insertTag( KileAction::TagData(QString::null,text,"%C",0,0) );
+ insertTag( KileAction::TagData(TQString(),text,"%C",0,0) );
}
-void Kile::insertText(const QString &text, const QStringList &pkgs)
+void Kile::insertText(const TQString &text, const TQStringList &pkgs)
{
- insertTag( KileAction::TagData(QString::null,text,"%C",0,0),pkgs );
+ insertTag( KileAction::TagData(TQString(),text,"%C",0,0),pkgs );
}
void Kile::quickDocument()
@@ -1745,12 +1745,12 @@ void Kile::quickMathenv()
void Kile::quickPostscript()
{
- QString startdir = QDir::homeDirPath();
- QString texfilename = QString::null;
+ TQString startdir = TQDir::homeDirPath();
+ TQString texfilename = TQString();
Kate::View *view = viewManager()->currentTextView();
if ( view ) {
- startdir = QFileInfo(view->getDoc()->url().path()).dirPath();
+ startdir = TQFileInfo(view->getDoc()->url().path()).dirPath();
texfilename = getCompileName();
}
@@ -1761,7 +1761,7 @@ void Kile::quickPostscript()
void Kile::helpLaTex()
{
- QString loc = locate("html","en/kile/latexhelp.html");
+ TQString loc = locate("html","en/kile/latexhelp.html");
KileTool::ViewHTML *tool = new KileTool::ViewHTML("ViewHTML", m_manager, false);
tool->setFlags(KileTool::NeedSourceExists | KileTool::NeedSourceRead);
tool->setSource(loc);
@@ -1830,7 +1830,7 @@ void Kile::readUserSettings()
int len = m_config->readNumEntry("nUserTags",0);
for (int i = 0; i < len; ++i)
{
- m_listUserTags.append(KileDialog::UserTags::splitTag(m_config->readEntry("userTagName"+QString::number(i),i18n("no name")) , m_config->readEntry("userTag"+QString::number(i),"") ));
+ m_listUserTags.append(KileDialog::UserTags::splitTag(m_config->readEntry("userTagName"+TQString::number(i),i18n("no name")) , m_config->readEntry("userTag"+TQString::number(i),"") ));
}
//convert user tools to new KileTool classes
@@ -1838,8 +1838,8 @@ void Kile::readUserSettings()
len= m_config->readNumEntry("nUserTools",0);
for (int i=0; i< len; ++i)
{
- tempItem.name=m_config->readEntry("userToolName"+QString::number(i),i18n("no name"));
- tempItem.tag =m_config->readEntry("userTool"+QString::number(i),"");
+ tempItem.name=m_config->readEntry("userToolName"+TQString::number(i),i18n("no name"));
+ tempItem.tag =m_config->readEntry("userTool"+TQString::number(i),"");
m_listUserTools.append(tempItem);
}
if ( len > 0 )
@@ -1855,7 +1855,7 @@ void Kile::readUserSettings()
KileTool::setGUIOptions(tempItem.name, "Other", "gear", m_config);
m_config->setGroup(KileTool::groupFor(tempItem.name, "Default"));
- QString bin = KRun::binaryName(tempItem.tag, false);
+ TQString bin = KRun::binaryName(tempItem.tag, false);
m_config->writeEntry("command", bin);
m_config->writeEntry("options", tempItem.tag.mid(bin.length()));
m_config->writeEntry("class", "Base");
@@ -1866,7 +1866,7 @@ void Kile::readUserSettings()
if ( i < 10 )
{
m_config->setGroup("Shortcuts");
- m_config->writeEntry("tool_" + tempItem.name, "Alt+Shift+" + QString::number(i + 1) ); //should be alt+shift+
+ m_config->writeEntry("tool_" + tempItem.name, "Alt+Shift+" + TQString::number(i + 1) ); //should be alt+shift+
}
}
}
@@ -1885,11 +1885,11 @@ void Kile::readRecentFileSettings()
m_config->setGroup("FilesOpenOnStart");
int n = m_config->readNumEntry("NoDOOS", 0);
for (int i=0; i < n; ++i)
- m_listDocsOpenOnStart.append(m_config->readPathEntry("DocsOpenOnStart"+QString::number(i), ""));
+ m_listDocsOpenOnStart.append(m_config->readPathEntry("DocsOpenOnStart"+TQString::number(i), ""));
n = m_config->readNumEntry("NoPOOS", 0);
for (int i=0; i < n; ++i)
- m_listProjectsOpenOnStart.append(m_config->readPathEntry("ProjectsOpenOnStart"+QString::number(i), ""));
+ m_listProjectsOpenOnStart.append(m_config->readPathEntry("ProjectsOpenOnStart"+TQString::number(i), ""));
}
void Kile::readConfig()
@@ -1928,11 +1928,11 @@ void Kile::saveSettings()
m_config->setGroup("FilesOpenOnStart");
m_config->writeEntry("NoDOOS", m_listDocsOpenOnStart.count());
for (uint i=0; i < m_listDocsOpenOnStart.count(); ++i)
- m_config->writePathEntry("DocsOpenOnStart"+QString::number(i), m_listDocsOpenOnStart[i]);
+ m_config->writePathEntry("DocsOpenOnStart"+TQString::number(i), m_listDocsOpenOnStart[i]);
m_config->writeEntry("NoPOOS", m_listProjectsOpenOnStart.count());
for (uint i=0; i < m_listProjectsOpenOnStart.count(); ++i)
- m_config->writePathEntry("ProjectsOpenOnStart"+QString::number(i), m_listProjectsOpenOnStart[i]);
+ m_config->writePathEntry("ProjectsOpenOnStart"+TQString::number(i), m_listProjectsOpenOnStart[i]);
if (!m_singlemode)
KileConfig::setMaster(m_masterName);
@@ -1946,8 +1946,8 @@ void Kile::saveSettings()
for (uint i=0; i < m_listUserTags.size(); ++i)
{
KileAction::TagData td( m_listUserTags[i]);
- m_config->writeEntry( "userTagName"+QString::number(i), td.text );
- m_config->writeEntry( "userTag"+QString::number(i), KileDialog::UserTags::completeTag(td) );
+ m_config->writeEntry( "userTagName"+TQString::number(i), td.text );
+ m_config->writeEntry( "userTag"+TQString::number(i), KileDialog::UserTags::completeTag(td) );
}
actionCollection()->writeShortcutSettings();
@@ -1960,8 +1960,8 @@ void Kile::saveSettings()
KileConfig::setMainwindowWidth(width());
KileConfig::setMainwindowHeight(height());
- QValueList<int> sizes;
- QValueList<int>::Iterator it;
+ TQValueList<int> sizes;
+ TQValueList<int>::Iterator it;
sizes=m_horizontalSplitter->sizes();
it = sizes.begin();
m_horSplitLeft=*it;
@@ -2008,7 +2008,7 @@ void Kile::toggleMode()
ModeAction->setChecked(false);
m_logPresent=false;
m_singlemode=true;
- m_masterName=QString::null;
+ m_masterName=TQString();
}
else if (m_singlemode && viewManager()->currentTextView())
{
@@ -2021,19 +2021,19 @@ void Kile::toggleMode()
return;
}
- QString shortName = m_masterName;
+ TQString shortName = m_masterName;
int pos;
- while ( (pos = (int)shortName.find('/')) != -1 )
+ while ( (pos = (int)shortName.tqfind('/')) != -1 )
shortName.remove(0,pos+1);
- ModeAction->setText(i18n("Normal mode (current master document: %1)").arg(shortName));
+ ModeAction->setText(i18n("Normal mode (current master document: %1)").tqarg(shortName));
ModeAction->setChecked(true);
m_singlemode=false;
}
else
ModeAction->setChecked(false);
- updateModeStatus();
+ updateModetqStatus();
KILE_DEBUG() << "SETTING master to " << m_masterName << " singlemode = " << m_singlemode << endl;
}
@@ -2112,8 +2112,8 @@ void Kile::slotPerformCheck()
void Kile::configureKeys()
{
KKeyDialog dlg( false, this );
- QPtrList<KXMLGUIClient> clients = guiFactory()->clients();
- for( QPtrListIterator<KXMLGUIClient> it( clients ); it.current(); ++it )
+ TQPtrList<KXMLGUIClient> clients = guiFactory()->clients();
+ for( TQPtrListIterator<KXMLGUIClient> it( clients ); it.current(); ++it )
{
dlg.insert( (*it)->actionCollection() );
}
@@ -2142,7 +2142,7 @@ void Kile::changeInputEncoding()
if( !textInfo )
return;
- QString encoding = m_fileSelector->comboEncoding()->lineEdit()->text();
+ TQString encoding = m_fileSelector->comboEncoding()->lineEdit()->text();
if(!encoding.isNull())
doc->setEncoding(encoding);
@@ -2164,10 +2164,10 @@ void Kile::cleanBib()
if ( ! view )
return;
- QRegExp reOptional( "(ALT|OPT)(\\w+)\\s*=\\s*(\\S.*)" );
- QRegExp reNonEmptyEntry( ".*\\w.*" );
+ TQRegExp reOptional( "(ALT|OPT)(\\w+)\\s*=\\s*(\\S.*)" );
+ TQRegExp reNonEmptyEntry( ".*\\w.*" );
- QString s;
+ TQString s;
uint i=0;
while(i < view->getDoc()->numLines())
{
@@ -2177,8 +2177,8 @@ void Kile::cleanBib()
if ( reOptional.search( s ) >= 0 )
{
// yes! capture type and entry
- QString type = reOptional.cap( 2 );
- QString entry = reOptional.cap( 3 );
+ TQString type = reOptional.cap( 2 );
+ TQString entry = reOptional.cap( 3 );
view->getDoc()->removeLine( i );
view->getDoc()->setModified(true);
if ( reNonEmptyEntry.search( entry ) >= 0 )
@@ -2196,11 +2196,11 @@ void Kile::cleanBib()
for ( i=0; i < view->getDoc()->numLines() ; i++ )
{
j = i+1;
- if ( j < view->getDoc()->numLines() && view->getDoc()->textLine(j).contains( QRegExp("^\\s*\\}\\s*$") ) )
+ if ( j < view->getDoc()->numLines() && view->getDoc()->textLine(j).tqcontains( TQRegExp("^\\s*\\}\\s*$") ) )
{
s = view->getDoc()->textLine( i );
view->getDoc()->removeLine( i );
- s.remove( QRegExp(",\\s*$") );
+ s.remove( TQRegExp(",\\s*$") );
view->getDoc()->setModified( true );
view->getDoc()->insertLine( i, s);
}
@@ -2212,10 +2212,10 @@ void Kile::includeGraphics()
Kate::View *view = viewManager()->currentTextView();
if ( !view ) return;
- QFileInfo fi( view->getDoc()->url().path() );
+ TQFileInfo fi( view->getDoc()->url().path() );
KileDialog::IncludeGraphics *dialog = new KileDialog::IncludeGraphics(this, fi.dirPath(), this);
- if ( dialog->exec() == QDialog::Accepted )
+ if ( dialog->exec() == TQDialog::Accepted )
{
insertTag(dialog->getTemplate(), "%C", 0,0);
docManager()->projectAddFile( dialog->getFilename(),true );
@@ -2226,7 +2226,7 @@ void Kile::includeGraphics()
void Kile::slotToggleFullScreen()
{
- //FIXME for Qt 3.3.x we can do: setWindowState(windowState() ^ WindowFullScreen);
+ //FIXME for TQt 3.3.x we can do: setWindowState(windowState() ^ WindowFullScreen);
if (!m_pFullScreen->isChecked())
showNormal();
else
@@ -2263,19 +2263,19 @@ void Kile::citeViewBib()
KILE_DEBUG() << "===void Kile::citeViewBib()===" << endl;
DCOPClient *client = kapp->dcopClient();
- QByteArray params, replyData;
- QCString replyType;
+ TQByteArray params, replyData;
+ TQCString replyType;
- QDataStream stream(params, IO_WriteOnly);
+ TQDataStream stream(params, IO_WriteOnly);
QCStringList functions,remoteApps,remoteObjs;
- const QCString viewBibApp = "kbib"; // currently these things are hardcoded because only kbib supports it
- const QCString viewBibObj = "kbibapp";
- const QCString viewBibFncDef = "QString cite()";
- const QCString viewBibFnc = "cite()";
+ const TQCString viewBibApp = "kbib"; // currently these things are hardcoded because only kbib supports it
+ const TQCString viewBibObj = "kbibapp";
+ const TQCString viewBibFncDef = "TQString cite()";
+ const TQCString viewBibFnc = "cite()";
remoteApps = client->registeredApplications();
- if( !remoteApps.contains(viewBibApp) )
+ if( !remoteApps.tqcontains(viewBibApp) )
{
m_logWidget->printMsg(KileTool::Warning,
i18n("No ViewBib tool running, trying to start it now"),
@@ -2289,7 +2289,7 @@ void Kile::citeViewBib()
}
remoteObjs = client->remoteObjects(viewBibApp);
- if( !remoteObjs.contains(viewBibObj) )
+ if( !remoteObjs.tqcontains(viewBibObj) )
{
m_logWidget->printMsg(KileTool::Warning,
i18n("The ViewBib tool does not have the correct interface"),
@@ -2298,7 +2298,7 @@ void Kile::citeViewBib()
}
functions = client->remoteFunctions(viewBibApp,viewBibObj);
- if( !functions.contains(viewBibFncDef) )
+ if( !functions.tqcontains(viewBibFncDef) )
{
m_logWidget->printMsg(KileTool::Warning,
i18n("The ViewBib tool does not have the correct definition of the cite function"),
@@ -2313,10 +2313,10 @@ void Kile::citeViewBib()
return;
}
else{
- QDataStream reply(replyData, IO_ReadOnly);
- if (replyType == "QString")
+ TQDataStream reply(replyData, IO_ReadOnly);
+ if (replyType == TQSTRING_OBJECT_NAME_STRING)
{
- QString result;
+ TQString result;
reply >> result;
if (result.isEmpty())
@@ -2327,7 +2327,7 @@ void Kile::citeViewBib()
}
else
{
- insertTag(KileAction::TagData(i18n("ViewBib Citation"), result, QString::null, result.length()));
+ insertTag(KileAction::TagData(i18n("ViewBib Citation"), result, TQString(), result.length()));
}
}
diff --git a/src/kile/kile.h b/src/kile/kile.h
index e186854..a382437 100644
--- a/src/kile/kile.h
+++ b/src/kile/kile.h
@@ -24,12 +24,12 @@
#include <kparts/partmanager.h>
#include <kparts/part.h>
-#include <qsplitter.h>
-#include <qwidget.h>
-#include <qstringlist.h>
-#include <qwidgetstack.h>
-#include <qstring.h>
-#include <qtoolbox.h>
+#include <tqsplitter.h>
+#include <tqwidget.h>
+#include <tqstringlist.h>
+#include <tqwidgetstack.h>
+#include <tqstring.h>
+#include <tqtoolbox.h>
#include "kileappIface.h"
#include "docpart.h"
@@ -51,10 +51,10 @@
#define KILERC_VERSION 6
-class QFileInfo;
-class QTimer;
-class QSignalMapper;
-class QIconViewItem;
+class TQFileInfo;
+class TQTimer;
+class TQSignalMapper;
+class TQIconViewItem;
class KToolBar;
class KAction;
@@ -82,7 +82,7 @@ namespace KileWidget { class LogMsg; class Output; class Konsole; class Structur
//TODO remove once we stop supporting pre 1.7 user tools
struct userItem
{
- QString name, tag;
+ TQString name, tag;
};
/**
@@ -95,32 +95,33 @@ struct userItem
class Kile : public KParts::MainWindow, public KileAppDCOPIface, public KileInfo
{
Q_OBJECT
+ TQ_OBJECT
public:
- Kile( bool allowRestore = true, QWidget *parent = 0, const char *name = 0 );
+ Kile( bool allowRestore = true, TQWidget *tqparent = 0, const char *name = 0 );
~Kile();
public slots:
/**
* @param line : Jump to give line in current editor (can be called via DCOP interface).
**/
- void setLine( const QString &line);
+ void setLine( const TQString &line);
void setCursor(const KURL &, int, int);
void setActive();
- int run(const QString &);
- int runWith(const QString &, const QString &);
+ int run(const TQString &);
+ int runWith(const TQString &, const TQString &);
void runArchiveTool();
void runArchiveTool(const KURL&);
- void openDocument(const QString & url);
- void fileSelected(const QString & url) { openDocument(url); } //backwards compatibility
+ void openDocument(const TQString & url);
+ void fileSelected(const TQString & url) { openDocument(url); } //backwards compatibility
void closeDocument();
void showTip();
/* actions */
private:
- void showEvent(QShowEvent *e);
- void hideEvent(QHideEvent *e);
- QWidget *m_focusWidget;
+ void showEvent(TQShowEvent *e);
+ void hideEvent(TQHideEvent *e);
+ TQWidget *m_tqfocusWidget;
void setupStatusBar();
void setupSideBar();
@@ -137,22 +138,22 @@ private:
void setupActions();
void setupTools();
void setupUserTagActions();
- void cleanUpActionList(QPtrList<KAction> &, const QStringList & tools);
+ void cleanUpActionList(TQPtrList<KAction> &, const TQStringList & tools);
bool kateCompletionPlugin();
void checkKateSettings();
void initMenu();
- void setMenuItems(QStringList &list, QMap<QString,bool> &dict);
+ void setMenuItems(TQStringList &list, TQMap<TQString,bool> &dict);
void updateMenu();
- void updateActionList(QPtrList<KAction> *list, bool state);
- QMap<QString,bool> m_dictMenuAction, m_dictMenuFile, m_dictMenuProject;
+ void updateActionList(TQPtrList<KAction> *list, bool state);
+ TQMap<TQString,bool> m_dictMenuAction, m_dictMenuFile, m_dictMenuProject;
KToolBar *m_toolsToolBar;
KActionMenu *m_menuUserTags;
- QValueList<KileAction::TagData> m_listUserTags;
- QValueList<userItem> m_listUserTools;
- QPtrList<KAction> m_listUserTagsActions, m_listQuickActions, m_listCompilerActions, m_listConverterActions, m_listViewerActions, m_listOtherActions;
+ TQValueList<KileAction::TagData> m_listUserTags;
+ TQValueList<userItem> m_listUserTools;
+ TQPtrList<KAction> m_listUserTagsActions, m_listQuickActions, m_listCompilerActions, m_listConverterActions, m_listViewerActions, m_listOtherActions;
KAction *m_actionEditTag;
KActionSeparator *m_actionEditSeparator;
KAction *m_paStop, *m_paPrint;
@@ -166,14 +167,14 @@ private:
//widgets
KileSideBar *m_sideBar;
KileAbbrevView *m_kileAbbrevView;
- QWidgetStack *m_topWidgetStack;
- QSplitter *m_horizontalSplitter, *m_verticalSplitter;
- QToolBox *m_toolBox;
+ TQWidgetStack *m_topWidgetStack;
+ TQSplitter *m_horizontalSplitter, *m_verticalSplitter;
+ TQToolBox *m_toolBox;
SymbolView *m_symbolViewMFUS, *m_symbolViewRelation, *m_symbolViewArrows, *m_symbolViewMiscMath, *m_symbolViewMiscText, *m_symbolViewOperators, *m_symbolViewUser, *m_symbolViewDelimiters, *m_symbolViewGreek, *m_symbolViewSpecial, *m_symbolViewCyrillic;
//parts
KParts::PartManager *m_partManager;
- QString m_wantState, m_currentState;
+ TQString m_wantState, m_currentState;
private slots:
void toggleMode();
@@ -186,18 +187,18 @@ private slots:
private slots:
bool resetPart();
void activePartGUI(KParts::Part *);
- void showToolBars(const QString &);
+ void showToolBars(const TQString &);
void enableKileGUI(bool);
void slotToggleFullScreen();
public slots:
- void prepareForPart(const QString &);
+ void prepareForPart(const TQString &);
/* config */
private:
KConfig *m_config;
int m_horSplitRight, m_horSplitLeft, m_verSplitTop, m_verSplitBottom;
- QStringList m_recentFilesList, m_listDocsOpenOnStart, m_listProjectsOpenOnStart;
+ TQStringList m_recentFilesList, m_listDocsOpenOnStart, m_listProjectsOpenOnStart;
void setViewerToolBars();
signals:
@@ -226,7 +227,7 @@ private slots:
* Activates (sets up the GUI for the editor part) the view.
* @param updateStruct If true, force an update of the structure view.
**/
- void activateView(QWidget* view , bool updateStruct = true);
+ void activateView(TQWidget* view , bool updateStruct = true);
void focusLog();
void focusOutput();
@@ -242,13 +243,13 @@ public slots:
void changeInputEncoding();
- void newStatus(const QString& = QString::null);
- void updateModeStatus();
+ void newtqStatus(const TQString& = TQString());
+ void updateModetqStatus();
void newCaption();
void citeViewBib();
public slots:
- void openProject(const QString& proj);
+ void openProject(const TQString& proj);
private:
KRecentFilesAction *m_actRecentProjects;
@@ -270,7 +271,7 @@ private slots:
void enableAutosave(bool);
private:
- QTimer *m_AutosaveTimer;
+ TQTimer *m_AutosaveTimer;
private slots:
void runTool();
@@ -280,7 +281,7 @@ private slots:
void findInFiles();
void findInProjects();
- void grepItemSelected(const QString &abs_filename, int line);
+ void grepItemSelected(const TQString &abs_filename, int line);
/* insert tags */
private slots:
@@ -296,14 +297,14 @@ private slots:
*
* warns if latex packages in pkgs are not included in the document
**/
- void insertTag(const KileAction::TagData& td, const QStringList& pkgs);
+ void insertTag(const KileAction::TagData& td, const TQStringList& pkgs);
/**
* An overloaded member function, behaves essentially as above.
**/
- void insertTag(const QString& tagB, const QString& tagE, int dx, int dy);
+ void insertTag(const TQString& tagB, const TQString& tagE, int dx, int dy);
void insertAmsTag(const KileAction::TagData& td);
- void insertText(const QString &text, const QStringList &pkgs);
- void insertText(const QString &text);
+ void insertText(const TQString &text, const TQStringList &pkgs);
+ void insertText(const TQString &text);
void quickTabular();
void quickArray();
diff --git a/src/kile/kile.kcfg b/src/kile/kile.kcfg
index 611e876..e856904 100644
--- a/src/kile/kile.kcfg
+++ b/src/kile/kile.kcfg
@@ -3,10 +3,10 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
- <include>qapplication.h</include>
- <include>qstring.h</include>
- <include>qtextcodec.h</include>
- <include>qdir.h</include>
+ <include>tqapplication.h</include>
+ <include>tqstring.h</include>
+ <include>tqtextcodec.h</include>
+ <include>tqdir.h</include>
<kcfgfile name="kilerc"/>
@@ -262,7 +262,7 @@
<entry name="InputEncoding" type="String">
<label></label>
<default code="true">
- QString::fromLatin1(QTextCodec::codecForLocale()->name())
+ TQString::fromLatin1(TQTextCodec::codecForLocale()->name())
</default>
</entry>
<entry name="lastDir" type="Path">
@@ -286,7 +286,7 @@
<entry name="DefaultProjectLocation" type="String">
<label>The default location where the projects must be created.</label>
<default code="true">
- QDir::home().absPath()
+ TQDir::home().absPath()
</default>
</entry>
</group>
diff --git a/src/kile/kileabbrevview.cpp b/src/kile/kileabbrevview.cpp
index 69efeb6..5711dff 100644
--- a/src/kile/kileabbrevview.cpp
+++ b/src/kile/kileabbrevview.cpp
@@ -20,18 +20,18 @@
#include <kmessagebox.h>
#include "kiledebug.h"
-#include <qheader.h>
-#include <qlayout.h>
-#include <qregexp.h>
-#include <qvalidator.h>
-#include <qfile.h>
-
-KileAbbrevView::KileAbbrevView(QWidget *parent, const char *name)
- : KListView(parent, name), m_changes(false)
+#include <tqheader.h>
+#include <tqlayout.h>
+#include <tqregexp.h>
+#include <tqvalidator.h>
+#include <tqfile.h>
+
+KileAbbrevView::KileAbbrevView(TQWidget *tqparent, const char *name)
+ : KListView(tqparent, name), m_changes(false)
{
addColumn(i18n("Short"));
- addColumn(QString::null);
+ addColumn(TQString());
addColumn(i18n("Expanded Text"));
setAllColumnsShowFocus(true);
setFullWidth(true);
@@ -42,13 +42,13 @@ KileAbbrevView::KileAbbrevView(QWidget *parent, const char *name)
//setShadeSortColumn(true); // default: true
header()->setMovingEnabled(false); // default: true
- m_popup = new QPopupMenu( this );
+ m_popup = new TQPopupMenu( this );
- connect(this, SIGNAL(mouseButtonClicked(int,QListViewItem *,const QPoint &,int)),
- this, SLOT(slotMouseButtonClicked(int,QListViewItem *,const QPoint &,int)));
+ connect(this, TQT_SIGNAL(mouseButtonClicked(int,TQListViewItem *,const TQPoint &,int)),
+ this, TQT_SLOT(slotMouseButtonClicked(int,TQListViewItem *,const TQPoint &,int)));
- connect(this, SIGNAL(contextMenu(KListView *,QListViewItem *,const QPoint &)),
- this, SLOT(slotContextMenu(KListView *,QListViewItem *,const QPoint &)));
+ connect(this, TQT_SIGNAL(contextMenu(KListView *,TQListViewItem *,const TQPoint &)),
+ this, TQT_SLOT(slotContextMenu(KListView *,TQListViewItem *,const TQPoint &)));
}
KileAbbrevView::~KileAbbrevView()
@@ -57,7 +57,7 @@ KileAbbrevView::~KileAbbrevView()
//////////////////// init abbreviation view with wordlists ////////////////////
-void KileAbbrevView::init(const QStringList *globallist, const QStringList *locallist)
+void KileAbbrevView::init(const TQStringList *globallist, const TQStringList *locallist)
{
setUpdatesEnabled(false);
clear();
@@ -68,14 +68,14 @@ void KileAbbrevView::init(const QStringList *globallist, const QStringList *loca
m_changes = false;
}
-void KileAbbrevView::addWordlist(const QStringList *wordlist, bool global)
+void KileAbbrevView::addWordlist(const TQStringList *wordlist, bool global)
{
- QString type = ( global ) ? QString::null : "*";
+ TQString type = ( global ) ? TQString() : "*";
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it=wordlist->begin(); it!=wordlist->end(); ++it )
{
- int index = (*it).find( '=' );
+ int index = (*it).tqfind( '=' );
if ( index >= 0 )
{
insertItem( new KListViewItem(this,(*it).left(index),type,(*it).right( (*it).length()-index-1 )) );
@@ -85,25 +85,25 @@ void KileAbbrevView::addWordlist(const QStringList *wordlist, bool global)
//////////////////// save local abbreviation list ////////////////////
-void KileAbbrevView::saveLocalAbbreviation(const QString &filename)
+void KileAbbrevView::saveLocalAbbreviation(const TQString &filename)
{
if ( ! m_changes )
return;
KILE_DEBUG() << "=== KileAbbrevView::saveLocalAbbreviation ===================" << endl;
// create the file
- QFile abbrevfile(filename);
+ TQFile abbrevfile(filename);
if ( ! abbrevfile.open( IO_WriteOnly ) )
return;
- QTextStream stream( &abbrevfile );
+ TQTextStream stream( &abbrevfile );
stream << "# abbreviation mode: editable abbreviations\n";
stream << "# dani/2007\n";
- //QTextCodec *codec = QTextCodec::codecForName(m_ki->activeTextDocument()->encoding().ascii());
+ //TQTextCodec *codec = TQTextCodec::codecForName(m_ki->activeTextDocument()->encoding().ascii());
// stream.setCodec(codec);
- QListViewItemIterator it( this );
+ TQListViewItemIterator it( this );
while ( it.current() )
{
if ( it.current()->text(KileAbbrevView::ALVlocal) == "*" )
@@ -122,9 +122,9 @@ void KileAbbrevView::saveLocalAbbreviation(const QString &filename)
//////////////////// find abbreviation ////////////////////
-bool KileAbbrevView::findAbbreviation(const QString &abbrev)
+bool KileAbbrevView::findAbbreviation(const TQString &abbrev)
{
- QListViewItemIterator it( this );
+ TQListViewItemIterator it( this );
while ( it.current() )
{
if ( it.current()->text(KileAbbrevView::ALVabbrev) == abbrev )
@@ -137,7 +137,7 @@ bool KileAbbrevView::findAbbreviation(const QString &abbrev)
//////////////////// item clicked ////////////////////
-void KileAbbrevView::slotMouseButtonClicked(int button, QListViewItem *item, const QPoint &, int)
+void KileAbbrevView::slotMouseButtonClicked(int button, TQListViewItem *item, const TQPoint &, int)
{
if ( button==1 && item )
{
@@ -147,7 +147,7 @@ void KileAbbrevView::slotMouseButtonClicked(int button, QListViewItem *item, con
//////////////////// context menu ////////////////////
-void KileAbbrevView::slotContextMenu(KListView *, QListViewItem *item, const QPoint &pos)
+void KileAbbrevView::slotContextMenu(KListView *, TQListViewItem *item, const TQPoint &pos)
{
m_popup->clear();
m_popup->disconnect();
@@ -161,27 +161,27 @@ void KileAbbrevView::slotContextMenu(KListView *, QListViewItem *item, const QPo
m_popup->insertItem(i18n("&Delete"),ALVdelete);
}
- connect(m_popup, SIGNAL(activated(int)), this, SLOT(slotPopupAbbreviation(int)));
+ connect(m_popup, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotPopupAbbreviation(int)));
// show context menu
m_popup->exec(pos);
}
-void KileAbbrevView::addAbbreviation(const QString &abbrev, const QString &expansion)
+void KileAbbrevView::addAbbreviation(const TQString &abbrev, const TQString &expansion)
{
insertItem( new KListViewItem(this,abbrev,"*",expansion) );
- QString newAbbrev = abbrev + '=' + expansion;
+ TQString newAbbrev = abbrev + '=' + expansion;
- emit( updateAbbrevList(QString::null,newAbbrev) );
+ emit( updateAbbrevList(TQString(),newAbbrev) );
m_changes = true;
}
-void KileAbbrevView::changeAbbreviation(KListViewItem *item, const QString &abbrev, const QString &expansion)
+void KileAbbrevView::changeAbbreviation(KListViewItem *item, const TQString &abbrev, const TQString &expansion)
{
if ( item )
{
- QString oldAbbrev = item->text(ALVabbrev) + '=' + item->text(ALVexpansion);
- QString newAbbrev = abbrev + '=' + expansion;
+ TQString oldAbbrev = item->text(ALVabbrev) + '=' + item->text(ALVexpansion);
+ TQString newAbbrev = abbrev + '=' + expansion;
item->setText(ALVabbrev,abbrev);
item->setText(ALVexpansion,expansion);
@@ -192,16 +192,16 @@ void KileAbbrevView::changeAbbreviation(KListViewItem *item, const QString &abbr
void KileAbbrevView::deleteAbbreviation(KListViewItem *item)
{
- QString abbrev = item->text(ALVabbrev);
- QString message = i18n("Delete the abbreviation '%1'?").arg(abbrev);
+ TQString abbrev = item->text(ALVabbrev);
+ TQString message = i18n("Delete the abbreviation '%1'?").tqarg(abbrev);
if ( KMessageBox::questionYesNo( this,
"<center>" + message + "</center>",
i18n("Delete Abbreviation") ) == KMessageBox::Yes )
{
- QString s = item->text(ALVabbrev) + '=' + item->text(ALVexpansion);
+ TQString s = item->text(ALVabbrev) + '=' + item->text(ALVexpansion);
delete item;
- emit( updateAbbrevList(s,QString::null) );
+ emit( updateAbbrevList(s,TQString()) );
m_changes = true;
}
}
@@ -221,9 +221,9 @@ void KileAbbrevView::slotPopupAbbreviation(int id)
if ( mode != ALVnone )
{
KileAbbrevInputDialog *dialog = new KileAbbrevInputDialog(this,item,mode);
- if ( dialog->exec() == QDialog::Accepted )
+ if ( dialog->exec() == TQDialog::Accepted )
{
- QString abbrev,expansion;
+ TQString abbrev,expansion;
dialog->abbreviation(abbrev,expansion);
if ( mode == ALVadd )
addAbbreviation(abbrev,expansion);
@@ -240,9 +240,9 @@ KileAbbrevInputDialog::KileAbbrevInputDialog(KileAbbrevView *listview, KListView
: KDialogBase(listview,name, true, i18n("Add Abbreviation"), KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true),
m_listview(listview), m_abbrevItem(item), m_mode(mode)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- QVBoxLayout *vl = new QVBoxLayout(page, 0, spacingHint());
+ TQVBoxLayout *vl = new TQVBoxLayout(page, 0, spacingHint());
if ( m_mode == KileAbbrevView::ALVedit )
{
@@ -251,8 +251,8 @@ KileAbbrevInputDialog::KileAbbrevInputDialog(KileAbbrevView *listview, KListView
m_expansion = m_abbrevItem->text(KileAbbrevView::ALVexpansion);
}
- QLabel *abbrev = new QLabel(i18n("&Abbreviation:"),page);
- QLabel *expansion = new QLabel(i18n("&Expanded Text:"),page);
+ TQLabel *abbrev = new TQLabel(i18n("&Abbreviation:"),page);
+ TQLabel *expansion = new TQLabel(i18n("&Expanded Text:"),page);
m_leAbbrev = new KLineEdit(m_abbrev,page);
m_leExpansion = new KLineEdit(m_expansion,page);
@@ -265,16 +265,16 @@ KileAbbrevInputDialog::KileAbbrevInputDialog(KileAbbrevView *listview, KListView
abbrev->setBuddy(m_leAbbrev);
expansion->setBuddy(m_leExpansion);
- QRegExp reg("[a-zA-Z0-9]+");
- QRegExpValidator *abbrevValidator = new QRegExpValidator(reg,this);
+ TQRegExp reg("[a-zA-Z0-9]+");
+ TQRegExpValidator *abbrevValidator = new TQRegExpValidator(reg,TQT_TQOBJECT(this));
m_leAbbrev->setValidator(abbrevValidator);
- connect(m_leAbbrev,SIGNAL(textChanged(const QString &)),
- this,SLOT(slotTextChanged(const QString &)));
- connect(m_leExpansion,SIGNAL(textChanged(const QString &)),
- this,SLOT(slotTextChanged(const QString &)));
+ connect(m_leAbbrev,TQT_SIGNAL(textChanged(const TQString &)),
+ this,TQT_SLOT(slotTextChanged(const TQString &)));
+ connect(m_leExpansion,TQT_SIGNAL(textChanged(const TQString &)),
+ this,TQT_SLOT(slotTextChanged(const TQString &)));
- slotTextChanged(QString::null);
+ slotTextChanged(TQString());
m_leAbbrev->setFocus();
page->setMinimumWidth(350);
}
@@ -283,13 +283,13 @@ KileAbbrevInputDialog::~KileAbbrevInputDialog()
{
}
-void KileAbbrevInputDialog::abbreviation(QString &abbrev, QString &expansion)
+void KileAbbrevInputDialog::abbreviation(TQString &abbrev, TQString &expansion)
{
abbrev = m_leAbbrev->text();
expansion = m_leExpansion->text().stripWhiteSpace();
}
-void KileAbbrevInputDialog::slotTextChanged(const QString &)
+void KileAbbrevInputDialog::slotTextChanged(const TQString &)
{
bool state = ( m_mode == KileAbbrevView::ALVadd )
? ! m_listview->findAbbreviation( m_leAbbrev->text() ) : true;
@@ -300,8 +300,8 @@ void KileAbbrevInputDialog::slotTextChanged(const QString &)
void KileAbbrevInputDialog::slotOk()
{
- QString abbrev = m_leAbbrev->text();
- QString expansion = m_leExpansion->text().stripWhiteSpace();
+ TQString abbrev = m_leAbbrev->text();
+ TQString expansion = m_leExpansion->text().stripWhiteSpace();
if ( abbrev.isEmpty() || expansion.isEmpty() )
{
diff --git a/src/kile/kileabbrevview.h b/src/kile/kileabbrevview.h
index 040a55a..f27ee07 100644
--- a/src/kile/kileabbrevview.h
+++ b/src/kile/kileabbrevview.h
@@ -16,9 +16,9 @@
#ifndef KILEABBREVVIEW_H
#define KILEABBREVVIEW_H
-#include <qstring.h>
-#include <qlabel.h>
-#include <qpopupmenu.h>
+#include <tqstring.h>
+#include <tqlabel.h>
+#include <tqpopupmenu.h>
#include <klineedit.h>
#include <klistbox.h>
@@ -30,36 +30,37 @@
class KileAbbrevView : public KListView
{
Q_OBJECT
+ TQ_OBJECT
public:
enum { ALVabbrev=0, ALVlocal=1, ALVexpansion=2 };
enum { ALVnone=0, ALVadd=1, ALVedit=2, ALVdelete=3 };
- KileAbbrevView(QWidget *parent=0, const char *name=0);
+ KileAbbrevView(TQWidget *tqparent=0, const char *name=0);
~KileAbbrevView();
- void init(const QStringList *globallist, const QStringList *locallist);
- bool findAbbreviation(const QString &abbrev);
- void saveLocalAbbreviation(const QString &filename);
+ void init(const TQStringList *globallist, const TQStringList *locallist);
+ bool findAbbreviation(const TQString &abbrev);
+ void saveLocalAbbreviation(const TQString &filename);
signals:
- void updateAbbrevList(const QString &ds, const QString &as);
- void sendText(const QString &text);
+ void updateAbbrevList(const TQString &ds, const TQString &as);
+ void sendText(const TQString &text);
private slots:
- void slotMouseButtonClicked(int button, QListViewItem *item, const QPoint &pos, int);
- void slotContextMenu(KListView *, QListViewItem *item, const QPoint &pos);
+ void slotMouseButtonClicked(int button, TQListViewItem *item, const TQPoint &pos, int);
+ void slotContextMenu(KListView *, TQListViewItem *item, const TQPoint &pos);
void slotPopupAbbreviation(int id);
private:
- QPopupMenu* m_popup;
+ TQPopupMenu* m_popup;
bool m_changes;
- void addAbbreviation(const QString &abbrev, const QString &expansion);
- void changeAbbreviation(KListViewItem *item,const QString &abbrev, const QString &expansion);
+ void addAbbreviation(const TQString &abbrev, const TQString &expansion);
+ void changeAbbreviation(KListViewItem *item,const TQString &abbrev, const TQString &expansion);
void deleteAbbreviation(KListViewItem *item);
- void addWordlist(const QStringList *wordlist, bool global);
+ void addWordlist(const TQStringList *wordlist, bool global);
};
@@ -68,12 +69,13 @@ private:
class KileAbbrevInputDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
KileAbbrevInputDialog(KileAbbrevView *listview, KListViewItem *item, int mode, const char *name=0);
~KileAbbrevInputDialog();
- void abbreviation(QString &abbrev, QString &expansion);
+ void abbreviation(TQString &abbrev, TQString &expansion);
private:
KileAbbrevView *m_listview;
@@ -82,13 +84,13 @@ private:
KLineEdit *m_leExpansion;
int m_mode;
- QString m_abbrev, m_expansion;
+ TQString m_abbrev, m_expansion;
public slots:
void slotOk();
private slots:
- void slotTextChanged(const QString &text);
+ void slotTextChanged(const TQString &text);
};
diff --git a/src/kile/kileactions.cpp b/src/kile/kileactions.cpp
index 99314d2..057d7a3 100644
--- a/src/kile/kileactions.cpp
+++ b/src/kile/kileactions.cpp
@@ -22,12 +22,12 @@
#include "kileactions.h"
-#include <qstring.h>
-#include <qstringlist.h>
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qfileinfo.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqfileinfo.h>
#include <klineedit.h>
#include <kglobal.h>
@@ -48,35 +48,35 @@ namespace KileAction
////////////////
// Tag //
////////////////
-Tag::Tag( const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent
- , const char *name, const QString &tagBegin, const QString &tagEnd
- , int dx, int dy, const QString &description)
- : KAction(text, cut, parent, name),
+Tag::Tag( const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent
+ , const char *name, const TQString &tagBegin, const TQString &tagEnd
+ , int dx, int dy, const TQString &description)
+ : KAction(text, cut, tqparent, name),
m_data(text,tagBegin, tagEnd, dx, dy, description)
{
init(receiver,slot);
}
-Tag::Tag( const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent
- , const char *name, const QString &tagBegin, const QString &tagEnd
- , int dx, int dy, const QString &description)
- : KAction(text, pix, cut, parent, name),
+Tag::Tag( const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent
+ , const char *name, const TQString &tagBegin, const TQString &tagEnd
+ , int dx, int dy, const TQString &description)
+ : KAction(text, pix, cut, tqparent, name),
m_data(text,tagBegin, tagEnd, dx, dy, description)
{
init(receiver,slot);
}
-Tag::Tag( const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent
+Tag::Tag( const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent
, const char *name, const TagData& data)
- : KAction(text, cut, parent, name),
+ : KAction(text, cut, tqparent, name),
m_data(data)
{
init(receiver,slot);
}
-Tag::Tag( const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent
+Tag::Tag( const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent
, const char *name, const TagData& data)
- : KAction(text, pix, cut, parent, name),
+ : KAction(text, pix, cut, tqparent, name),
m_data(data)
{
init(receiver,slot);
@@ -86,10 +86,10 @@ Tag::~Tag()
{
}
-void Tag::init(const QObject *receiver, const char *slot)
+void Tag::init(const TQObject *receiver, const char *slot)
{
- connect(this, SIGNAL(activated()), SLOT(emitData()));
- connect(this, SIGNAL(activated(const KileAction::TagData&)), receiver, slot);
+ connect(this, TQT_SIGNAL(activated()), TQT_SLOT(emitData()));
+ connect(this, TQT_SIGNAL(activated(const KileAction::TagData&)), receiver, slot);
}
void Tag::emitData()
@@ -100,36 +100,36 @@ void Tag::emitData()
////////////////
// InputTag //
////////////////
-InputTag::InputTag(KileInfo* ki, const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent, uint options
- , const QString &tagBegin, const QString &tagEnd
- , int dx, int dy, const QString &description, const QString &hint, const QString &alter)
- : Tag(text, cut, receiver, slot, parent, name, tagBegin, tagEnd, dx, dy, description), m_ki(ki),
- m_parent(wparent), m_options(options), m_hint(hint), m_alter(alter)
+InputTag::InputTag(KileInfo* ki, const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent, uint options
+ , const TQString &tagBegin, const TQString &tagEnd
+ , int dx, int dy, const TQString &description, const TQString &hint, const TQString &alter)
+ : Tag(text, cut, receiver, slot, tqparent, name, tagBegin, tagEnd, dx, dy, description), m_ki(ki),
+ m_parent(wtqparent), m_options(options), m_hint(hint), m_alter(alter)
{
init();
}
-InputTag::InputTag( KileInfo* ki, const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const QString &tagBegin, const QString &tagEnd
- , int dx, int dy, const QString &description, const QString &hint, const QString &alter)
- : Tag(text, pix, cut, receiver, slot, parent, name, tagBegin, tagEnd, dx, dy, description), m_ki(ki),
- m_parent(wparent), m_options(options), m_hint(hint), m_alter(alter)
+InputTag::InputTag( KileInfo* ki, const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TQString &tagBegin, const TQString &tagEnd
+ , int dx, int dy, const TQString &description, const TQString &hint, const TQString &alter)
+ : Tag(text, pix, cut, receiver, slot, tqparent, name, tagBegin, tagEnd, dx, dy, description), m_ki(ki),
+ m_parent(wtqparent), m_options(options), m_hint(hint), m_alter(alter)
{
init();
}
-InputTag::InputTag( KileInfo* ki, const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const TagData& data, const QString &hint, const QString &alter)
- : Tag(text,cut,receiver, slot, parent, name,data), m_ki(ki),
- m_parent(wparent), m_options(options), m_hint(hint), m_alter(alter)
+InputTag::InputTag( KileInfo* ki, const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TagData& data, const TQString &hint, const TQString &alter)
+ : Tag(text,cut,receiver, slot, tqparent, name,data), m_ki(ki),
+ m_parent(wtqparent), m_options(options), m_hint(hint), m_alter(alter)
{
init();
}
-InputTag::InputTag( KileInfo* ki, const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const TagData& data, const QString &hint, const QString &alter)
- : Tag(text, pix, cut,receiver, slot, parent, name,data), m_ki(ki),
- m_parent(wparent), m_options(options), m_hint(hint), m_alter(alter)
+InputTag::InputTag( KileInfo* ki, const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TagData& data, const TQString &hint, const TQString &alter)
+ : Tag(text, pix, cut,receiver, slot, tqparent, name,data), m_ki(ki),
+ m_parent(wtqparent), m_options(options), m_hint(hint), m_alter(alter)
{
init();
}
@@ -154,12 +154,12 @@ void InputTag::emitData()
TagData td(m_data);
- td.tagBegin.replace("%R",dlg->tag());
- td.tagEnd.replace("%R",dlg->tag());
+ td.tagBegin.tqreplace("%R",dlg->tag());
+ td.tagEnd.tqreplace("%R",dlg->tag());
- QString alt = dlg->useAlternative() ? "*" : "";
- td.tagBegin.replace("%A", alt);
- td.tagEnd.replace("%A", alt);
+ TQString alt = dlg->useAlternative() ? "*" : "";
+ td.tagBegin.tqreplace("%A", alt);
+ td.tagEnd.tqreplace("%A", alt);
if ( dlg->useLabel() )
{
@@ -180,7 +180,7 @@ void InputTag::emitData()
// refresh document structure and project tree when a file was inserted
if ( dlg->useAddProjectFile() )
{
- m_ki->docManager()->projectAddFile( QFileInfo(m_ki->getCompileName()).dirPath(true) + '/' + dlg->tag() );
+ m_ki->docManager()->projectAddFile( TQFileInfo(m_ki->getCompileName()).dirPath(true) + '/' + dlg->tag() );
}
}
delete dlg;
@@ -190,24 +190,24 @@ void InputTag::emitData()
/*
InputDialog
*/
-InputDialog::InputDialog(const QString &caption, uint options, const QStringList& history, const QString& hint, const QString& alter, KileInfo *ki, QWidget *parent, const char *name)
- : KDialogBase (parent, name, true, caption, KDialogBase::Ok | KDialogBase::Cancel, KDialogBase::Ok, true), m_ki(ki)
+InputDialog::InputDialog(const TQString &caption, uint options, const TQStringList& history, const TQString& hint, const TQString& alter, KileInfo *ki, TQWidget *tqparent, const char *name)
+ : KDialogBase (tqparent, name, true, caption, KDialogBase::Ok | KDialogBase::Cancel, KDialogBase::Ok, true), m_ki(ki)
{
- QString newcaption = caption;
+ TQString newcaption = caption;
setCaption(newcaption.remove("&"));
m_labelprefix = ( newcaption == "chapter" ) ? "chap:" : "sec:";
m_usedSelection = false;
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- QGridLayout *gbox = new QGridLayout( page, 6,3,5,5,"");
+ TQGridLayout *gbox = new TQGridLayout( page, 6,3,5,5,"");
- QLabel *lb = new QLabel(hint, page);
+ TQLabel *lb = new TQLabel(hint, page);
gbox->addMultiCellWidget(lb,0,0,0,2);
- m_tag=QString::null;
- QWidget *focus;
+ m_tag=TQString();
+ TQWidget *focus;
if ( (options & KileAction::KeepHistory) || (options & KileAction::FromLabelList) || (options & KileAction::FromBibItemList) )
{
KComboBox *input = new KComboBox(true, page, "input_dialog_input");
@@ -215,14 +215,14 @@ InputDialog::InputDialog(const QString &caption, uint options, const QStringList
input->setMinimumWidth(300);
focus = input;
- connect(input, SIGNAL(textChanged(const QString&)), this, SLOT(setTag(const QString&)));
- connect(this, SIGNAL(setInput(const QString&)), input, SLOT(setEditText(const QString&)));
+ connect(input, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(setTag(const TQString&)));
+ connect(this, TQT_SIGNAL(setInput(const TQString&)), input, TQT_SLOT(setEditText(const TQString&)));
if ( options & KileAction::ShowBrowseButton )
gbox->addWidget(input,1,0);
else
gbox->addMultiCellWidget(input,1,1,0,2);
- const QStringList *list;
+ const TQStringList *list;
if (options & KileAction::FromLabelList)
{
@@ -252,8 +252,8 @@ InputDialog::InputDialog(const QString &caption, uint options, const QStringList
input->setMinimumWidth(300);
focus = input;
- connect(input, SIGNAL(textChanged(const QString&)), this, SLOT(setTag(const QString&)));
- connect(this, SIGNAL(setInput(const QString&)), input, SLOT(setText(const QString&)));
+ connect(input, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(setTag(const TQString&)));
+ connect(this, TQT_SIGNAL(setInput(const TQString&)), input, TQT_SLOT(setText(const TQString&)));
if ( options & KileAction::ShowBrowseButton )
gbox->addWidget(input,1,0);
else
@@ -272,14 +272,14 @@ InputDialog::InputDialog(const QString &caption, uint options, const QStringList
pbutton->setPixmap( SmallIcon("fileopen") );
gbox->addWidget(pbutton,1,2);
gbox->setColSpacing(1,8);
- gbox->setColSpacing(2, pbutton->sizeHint().width()+5 );
- connect(pbutton, SIGNAL(clicked()), this, SLOT(slotBrowse()));
+ gbox->setColSpacing(2, pbutton->tqsizeHint().width()+5 );
+ connect(pbutton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotBrowse()));
}
if ( options & KileAction::ShowAlternative)
{
- QCheckBox * m_checkbox = new QCheckBox(alter, page, "input_dialog_checkbox");
- connect(m_checkbox, SIGNAL(clicked()), this, SLOT(slotAltClicked()));
+ TQCheckBox * m_checkbox = new TQCheckBox(alter, page, "input_dialog_checkbox");
+ connect(m_checkbox, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAltClicked()));
m_useAlternative=false;
gbox->addMultiCellWidget(m_checkbox,2,2,0,2);
}
@@ -289,7 +289,7 @@ InputDialog::InputDialog(const QString &caption, uint options, const QStringList
if ( m_useLabel )
{
// Label
- QLabel *label = new QLabel(i18n("&Label:"),page);
+ TQLabel *label = new TQLabel(i18n("&Label:"),page);
m_edLabel = new KLineEdit("",page);
m_edLabel->setMinimumWidth(300);
m_edLabel->setText(m_labelprefix);
@@ -313,20 +313,20 @@ InputDialog::~InputDialog()
void InputDialog::slotBrowse()
{
- QString fn;
- QFileInfo fi(m_ki->getCompileName());
+ TQString fn;
+ TQFileInfo fi(m_ki->getCompileName());
// Called from InputDialog after a \input- or \include command:
// so we are only looking for a LaTeX source document
- QString filter = m_ki->extensions()->latexDocumentFileFilter() + '\n' + "*|" + i18n("All Files");
+ TQString filter = m_ki->extensions()->latexDocumentFileFilter() + '\n' + "*|" + i18n("All Files");
fn = KFileDialog::getOpenFileName(fi.absFilePath(), filter, this,i18n("Select File") );
if ( !fn.isEmpty() )
{
- QString path = m_ki->relativePath(fi.dirPath(), fn);
+ TQString path = m_ki->relativePath(fi.dirPath(), fn);
// if the file has no extension, we add the default TeX extension
- if ( QFileInfo(path).extension().isEmpty() )
+ if ( TQFileInfo(path).extension().isEmpty() )
path += m_ki->extensions()->latexDocumentDefault();
setTag(path);
@@ -339,46 +339,46 @@ void InputDialog::slotAltClicked()
m_useAlternative = !m_useAlternative;
}
-void InputDialog::setTag(const QString &tag)
+void InputDialog::setTag(const TQString &tag)
{
m_tag = tag;
}
-QString InputDialog::label()
+TQString InputDialog::label()
{
if ( m_edLabel )
{
- QString label = m_edLabel->text().stripWhiteSpace();
+ TQString label = m_edLabel->text().stripWhiteSpace();
if ( !label.isEmpty() && label!=m_labelprefix )
return "\\label{" + label + "}\n";
}
- return QString::null;
+ return TQString();
}
/////////////////
// SelectTag //
/////////////////
-Select::Select(const QString &text, const KShortcut &cut, KActionCollection *parent, const char *name )
- : KSelectAction(text,cut,parent,name)
+Select::Select(const TQString &text, const KShortcut &cut, KActionCollection *tqparent, const char *name )
+ : KSelectAction(text,cut,tqparent,name)
{
init();
}
void Select::init()
{
- connect(this, SIGNAL(activated(const QString&)), SLOT(emitData(const QString &)));
+ connect(this, TQT_SIGNAL(activated(const TQString&)), TQT_SLOT(emitData(const TQString &)));
}
-void Select::emitData(const QString & name)
+void Select::emitData(const TQString & name)
{
m_dict[name]->activate();
}
-void Select::setItems(QPtrList<KAction>& list)
+void Select::setItems(TQPtrList<KAction>& list)
{
- QStringList tmp;
+ TQStringList tmp;
for (uint i=0; i < list.count(); ++i)
{
diff --git a/src/kile/kileactions.h b/src/kile/kileactions.h
index 4ca1888..a88aa35 100644
--- a/src/kile/kileactions.h
+++ b/src/kile/kileactions.h
@@ -15,14 +15,14 @@
#ifndef KILEACTIONS_H
#define KILEACTIONS_H
-#include <qdict.h>
+#include <tqdict.h>
#include <kaction.h>
#include <kdialogbase.h>
#include <klineedit.h>
-class QCheckBox;
-class QLineEdit;
+class TQCheckBox;
+class TQLineEdit;
class KileInfo;
@@ -37,39 +37,40 @@ enum { KeepHistory=1, ShowAlternative=2, ShowBrowseButton=4, FromLabelList=8, Fr
class TagData
{
public:
- TagData(const QString &t, const QString &tB = QString::null, const QString &tE = QString::null, int x = 0, int y = 0, const QString &desc = QString::null)
+ TagData(const TQString &t, const TQString &tB = TQString(), const TQString &tE = TQString(), int x = 0, int y = 0, const TQString &desc = TQString())
: text(t), tagBegin(tB), tagEnd(tE), dx(x), dy(y), description(desc) {}
- TagData() : text(QString::null), tagBegin(QString::null), tagEnd(QString::null), dx(0), dy(0), description(QString::null) {}
+ TagData() : text(TQString()), tagBegin(TQString()), tagEnd(TQString()), dx(0), dy(0), description(TQString()) {}
- QString text;
- QString tagBegin, tagEnd;
+ TQString text;
+ TQString tagBegin, tagEnd;
int dx,dy;
- QString description;
+ TQString description;
};
class Tag : public KAction
{
Q_OBJECT
+ TQ_OBJECT
public:
//constructors
- Tag(const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name
- , const QString &tagBegin, const QString &tagEnd = QString::null, int dx=0, int dy=0, const QString &description = QString::null);
+ Tag(const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name
+ , const TQString &tagBegin, const TQString &tagEnd = TQString(), int dx=0, int dy=0, const TQString &description = TQString());
- Tag(const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name
- , const QString &tagBegin, const QString &tagEnd = QString::null, int dx=0, int dy=0, const QString &description = QString::null);
+ Tag(const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name
+ , const TQString &tagBegin, const TQString &tagEnd = TQString(), int dx=0, int dy=0, const TQString &description = TQString());
- Tag(const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name
+ Tag(const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name
, const TagData& data);
- Tag(const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name
+ Tag(const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name
, const TagData& data);
~Tag();
private:
- void init(const QObject *receiver = 0, const char *slot = 0);
+ void init(const TQObject *receiver = 0, const char *slot = 0);
signals:
//sends along tagdata so that receiver knows what to insert
@@ -89,20 +90,21 @@ protected:
class InputTag : public Tag
{
Q_OBJECT
+ TQ_OBJECT
public:
//constructors
- InputTag(KileInfo* ki, const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const QString &tagBegin, const QString &tagEnd = QString::null, int dx=0, int dy=0, const QString &description = QString::null, const QString &hint = QString::null, const QString &alter = QString::null);
+ InputTag(KileInfo* ki, const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TQString &tagBegin, const TQString &tagEnd = TQString(), int dx=0, int dy=0, const TQString &description = TQString(), const TQString &hint = TQString(), const TQString &alter = TQString());
- InputTag(KileInfo* ki, const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const QString &tagBegin, const QString &tagEnd = QString::null, int dx=0, int dy=0, const QString &description = QString::null, const QString &hint = QString::null, const QString &alter = QString::null);
+ InputTag(KileInfo* ki, const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TQString &tagBegin, const TQString &tagEnd = TQString(), int dx=0, int dy=0, const TQString &description = TQString(), const TQString &hint = TQString(), const TQString &alter = TQString());
- InputTag(KileInfo* ki, const QString &text, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const TagData& data, const QString &hint = QString::null, const QString &alter = QString::null);
+ InputTag(KileInfo* ki, const TQString &text, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TagData& data, const TQString &hint = TQString(), const TQString &alter = TQString());
- InputTag(KileInfo* ki, const QString &text, const QString& pix, const KShortcut &cut, const QObject *receiver, const char *slot, KActionCollection *parent, const char *name, QWidget *wparent,uint options
- , const TagData& data, const QString &hint = QString::null, const QString &alter = QString::null);
+ InputTag(KileInfo* ki, const TQString &text, const TQString& pix, const KShortcut &cut, const TQObject *receiver, const char *slot, KActionCollection *tqparent, const char *name, TQWidget *wtqparent,uint options
+ , const TagData& data, const TQString &hint = TQString(), const TQString &alter = TQString());
~InputTag();
@@ -110,7 +112,7 @@ public:
bool hasAlternative() { return (m_options & ShowAlternative); }
bool hasBrowseButton() { return (m_options & ShowBrowseButton); }
- void addToHistory(const QString& str) { if ( m_history.first() != str ) m_history.prepend(str); }
+ void addToHistory(const TQString& str) { if ( m_history.first() != str ) m_history.prepend(str); }
private:
void init();
@@ -121,11 +123,11 @@ private slots:
private:
KileInfo *m_ki;
- QStringList m_history;
- QWidget *m_parent;
+ TQStringList m_history;
+ TQWidget *m_parent;
uint m_options;
- QString m_hint;
- QString m_alter;
+ TQString m_hint;
+ TQString m_alter;
};
@@ -135,9 +137,10 @@ private:
class InputDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- InputDialog(const QString &caption, uint options, const QStringList& history, const QString &hint, const QString &alter, KileInfo *ki, QWidget *parent=0, const char *name=0);
+ InputDialog(const TQString &caption, uint options, const TQStringList& history, const TQString &hint, const TQString &alter, KileInfo *ki, TQWidget *tqparent=0, const char *name=0);
~InputDialog();
bool useAlternative() {return m_useAlternative;}
@@ -148,21 +151,21 @@ public slots:
void slotBrowse();
void slotAltClicked();
- void setTag(const QString&);
+ void setTag(const TQString&);
signals:
- void setInput(const QString&);
+ void setInput(const TQString&);
public:
- QString tag() { return m_tag; }
- QString label();
+ TQString tag() { return m_tag; }
+ TQString label();
bool usedSelection() { return m_usedSelection; }
KLineEdit *m_edLabel;
private:
- QString m_tag;
- QString m_labelprefix;
+ TQString m_tag;
+ TQString m_labelprefix;
bool m_useAlternative,m_useLabel,m_usedSelection,m_useAddProjectFile;
KileInfo *m_ki;
};
@@ -170,10 +173,11 @@ private:
class Select : public KSelectAction
{
Q_OBJECT
+ TQ_OBJECT
public:
//constructors
- Select(const QString &text, const KShortcut &cut, KActionCollection *parent, const char *name);
+ Select(const TQString &text, const KShortcut &cut, KActionCollection *tqparent, const char *name);
private:
void init();
@@ -182,13 +186,13 @@ signals:
void activated(const KAction&);
public slots:
- void setItems(QPtrList<KAction> &);
+ void setItems(TQPtrList<KAction> &);
private slots:
- void emitData(const QString&);
+ void emitData(const TQString&);
private:
- QDict<KAction> m_dict;
+ TQDict<KAction> m_dict;
};
}
diff --git a/src/kile/kileappIface.h b/src/kile/kileappIface.h
index 64e1b42..6a82ea1 100644
--- a/src/kile/kileappIface.h
+++ b/src/kile/kileappIface.h
@@ -22,15 +22,15 @@ class KileAppDCOPIface : virtual public DCOPObject
K_DCOP
k_dcop:
- virtual void openDocument(const QString &)=0;
- virtual void insertText(const QString &)=0;
- virtual void fileSelected(const QString &)=0; //backwards compatibility
+ virtual void openDocument(const TQString &)=0;
+ virtual void insertText(const TQString &)=0;
+ virtual void fileSelected(const TQString &)=0; //backwards compatibility
virtual void closeDocument()=0;
- virtual void openProject(const QString &)=0;
- virtual void setLine( const QString &)=0;
+ virtual void openProject(const TQString &)=0;
+ virtual void setLine( const TQString &)=0;
virtual void setActive()=0;
- virtual int run(const QString &)=0;
- virtual int runWith(const QString &, const QString &)=0;
+ virtual int run(const TQString &)=0;
+ virtual int runWith(const TQString &, const TQString &)=0;
};
#endif
diff --git a/src/kile/kileapplication.cpp b/src/kile/kileapplication.cpp
index 7764d51..b78a160 100644
--- a/src/kile/kileapplication.cpp
+++ b/src/kile/kileapplication.cpp
@@ -19,29 +19,29 @@
#include <kstandarddirs.h>
#include <kate/document.h>
-#include <qframe.h>
-#include <qpixmap.h>
-#include <qlabel.h>
-#include <qpainter.h>
-#include <qfont.h>
-#include <qfontmetrics.h>
+#include <tqframe.h>
+#include <tqpixmap.h>
+#include <tqlabel.h>
+#include <tqpainter.h>
+#include <tqfont.h>
+#include <tqfontmetrics.h>
-static QFrame *pix=0;
-static QWidget *splash=0;
+static TQFrame *pix=0;
+static TQWidget *splash=0;
KileApplication::KileApplication()
{
- QRect screen = QApplication::desktop()->screenGeometry();
- QPixmap pm(KGlobal::dirs()->findResource("appdata","pics/kile_splash.png"));
- splash = new QWidget( 0, "splash", WDestructiveClose | WStyle_Customize | WStyle_NoBorder | WX11BypassWM | WStyle_StaysOnTop );
- pix=new QFrame(splash,"pix",QWidget::WStyle_NoBorder | QWidget::WStyle_Customize);
+ TQRect screen = TQApplication::desktop()->screenGeometry();
+ TQPixmap pm(KGlobal::dirs()->findResource("appdata","pics/kile_splash.png"));
+ splash = new TQWidget( 0, "splash", WDestructiveClose | WStyle_Customize | WStyle_NoBorder | WX11BypassWM | WStyle_StaysOnTop );
+ pix=new TQFrame(splash,"pix",TQWidget::WStyle_NoBorder | TQWidget::WStyle_Customize);
pix->setBackgroundPixmap(pm);
pix->setLineWidth(0);
pix->setGeometry( 0,0,398, 120 );
splash->adjustSize();
splash->setCaption( "Kile" );
- splash->move( screen.center() - QPoint( splash->width() / 2, splash->height() / 2 ) );
+ splash->move( screen.center() - TQPoint( splash->width() / 2, splash->height() / 2 ) );
splash->show();
}
KileApplication::~KileApplication(){
diff --git a/src/kile/kileconfigdialog.cpp b/src/kile/kileconfigdialog.cpp
index 17ec1ed..c974778 100644
--- a/src/kile/kileconfigdialog.cpp
+++ b/src/kile/kileconfigdialog.cpp
@@ -20,7 +20,7 @@
// - items are shown as a tree list
// - encoding config page and spelling page are removed,
// because settings are also avaiblable with Kate
-// - geometry of the dialog are saved and restored, because
+// - tqgeometry of the dialog are saved and restored, because
// the initial values may be bad in some languages
// 2007-03-17 dani
@@ -29,9 +29,9 @@
#include "kileconfigdialog.h"
-#include <qvbox.h>
-#include <qlayout.h>
-#include <qtextcodec.h>
+#include <tqvbox.h>
+#include <tqlayout.h>
+#include <tqtextcodec.h>
#include <kdeversion.h>
#include <klocale.h>
@@ -54,9 +54,9 @@
namespace KileDialog
{
- Config::Config(KConfig *config, KileInfo *ki, QWidget* parent)
- : KDialogBase( KDialogBase::TreeList, Qt::WStyle_DialogBorder,
- parent, "kileconfiguration", true, i18n("Configure"), Ok|Cancel, Ok ),
+ Config::Config(KConfig *config, KileInfo *ki, TQWidget* tqparent)
+ : KDialogBase( KDialogBase::TreeList, TQt::WStyle_DialogBorder,
+ tqparent, "kileconfiguration", true, i18n("Configure"), Ok|Cancel, Ok ),
m_config(config),
m_ki(ki)
{
@@ -91,13 +91,13 @@ namespace KileDialog
// calculate size for opening
if ( ! m_config->hasGroup("KileConfigDialog") )
- incInitialSize(QSize(50,0));
+ incInitialSize(TQSize(50,0));
else
setInitialSize( configDialogSize("KileConfigDialog") );
// setup connections
- //connect(m_manager, SIGNAL(widgetModified()), this, SLOT(slotWidgetModified()));
- connect(this, SIGNAL(okClicked()), m_manager, SLOT(updateSettings()));
+ //connect(m_manager, TQT_SIGNAL(widgetModified()), this, TQT_SLOT(slotWidgetModified()));
+ connect(this, TQT_SIGNAL(okClicked()), m_manager, TQT_SLOT(updateSettings()));
}
Config::~Config()
@@ -116,9 +116,9 @@ namespace KileDialog
//////////////////// add a new folder ////////////////////
- void Config::addConfigFolder(const QString &section,const QString &icon)
+ void Config::addConfigFolder(const TQString &section,const TQString &icon)
{
- QStringList path;
+ TQStringList path;
path << section;
#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
@@ -130,18 +130,18 @@ namespace KileDialog
//////////////////// add a new page ////////////////////
- void Config::addConfigPage(QWidget *page,
- const QString &sectionName,const QString &itemName,
- const QString &pixmapName, const QString &header,
+ void Config::addConfigPage(TQWidget *page,
+ const TQString &sectionName,const TQString &itemName,
+ const TQString &pixmapName, const TQString &header,
bool addSpacer)
{
KILE_DEBUG() << "slot: add config page item=" << itemName << endl;
// add page
- QStringList path;
+ TQStringList path;
path << sectionName << itemName;
- QVBox *vbox = addVBoxPage(path, header,
+ TQVBox *vbox = addVBoxPage(path, header,
#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
SmallIcon(pixmapName,KIcon::SizeSmallMedium)
#else
@@ -150,10 +150,10 @@ namespace KileDialog
);
vbox->setSpacing(0);
vbox->setMargin(0);
- page->reparent(((QWidget*)vbox),0,QPoint());
+ page->reparent(((TQWidget*)vbox),0,TQPoint());
if ( addSpacer )
{
- QFrame *spacer = new QFrame(vbox);
+ TQFrame *spacer = new TQFrame(vbox);
vbox->setStretchFactor(spacer,1);
}
@@ -270,7 +270,7 @@ namespace KileDialog
KTextEditor::ConfigInterfaceExtension *iface;
iface = dynamic_cast<KTextEditor::ConfigInterfaceExtension *>( view->getDoc() );
- QStringList path;
+ TQStringList path;
for (uint i=0; i<iface->configPages(); i++)
{
path.clear();
@@ -278,29 +278,29 @@ namespace KileDialog
// create a new vbox page and add the config page
#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
- QVBox *page = addVBoxPage(path,iface->configPageFullName(i), iface->configPagePixmap(i,KIcon::SizeSmallMedium) );
+ TQVBox *page = addVBoxPage(path,iface->configPageFullName(i), iface->configPagePixmap(i,KIcon::SizeSmallMedium) );
#else
- QVBox *page = addVBoxPage(path,iface->configPageFullName(i), iface->configPagePixmap(i) );
+ TQVBox *page = addVBoxPage(path,iface->configPageFullName(i), iface->configPagePixmap(i) );
#endif
KTextEditor::ConfigPage *configPage = iface->configPage(i,page);
- connect( configPage, SIGNAL(changed()), this, SLOT(slotChanged()) );
+ connect( configPage, TQT_SIGNAL(changed()), this, TQT_SLOT(slotChanged()) );
editorPages.append(configPage);
}
}
//////////////////// encoding ////////////////////
- QString Config::readKateEncoding()
+ TQString Config::readKateEncoding()
{
m_config->setGroup("Kate Document Defaults");
- return m_config->readEntry("Encoding",QString::null);
+ return m_config->readEntry("Encoding",TQString());
}
void Config::syncKileEncoding()
{
- QString enc = readKateEncoding();
+ TQString enc = readKateEncoding();
if ( enc.isEmpty() )
- enc = QString::fromLatin1(QTextCodec::codecForLocale()->name());
+ enc = TQString::tqfromLatin1(TQTextCodec::codecForLocale()->name());
KileConfig::setDefaultEncoding( enc );
}
//////////////////// slots ////////////////////
diff --git a/src/kile/kileconfigdialog.h b/src/kile/kileconfigdialog.h
index a447ecc..66d0117 100644
--- a/src/kile/kileconfigdialog.h
+++ b/src/kile/kileconfigdialog.h
@@ -29,7 +29,7 @@
#include "structureconfigwidget.h" // structure view (dani)
#include "symbolviewconfig.h"
-class QFrame;
+class TQFrame;
class KConfig;
namespace KileWidget { class ToolConfig; }
@@ -48,9 +48,10 @@ namespace KileDialog
class Config : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- Config( KConfig *config, KileInfo *ki, QWidget* parent = 0);
+ Config( KConfig *config, KileInfo *ki, TQWidget* tqparent = 0);
~Config();
virtual void show();
@@ -90,11 +91,11 @@ namespace KileDialog
// setup configuration
- void addConfigFolder(const QString &section,const QString &icon);
+ void addConfigFolder(const TQString &section,const TQString &icon);
- void addConfigPage( QWidget *page,
- const QString &sectionName,const QString &itemName,
- const QString &pixmapName, const QString &header=QString::null,
+ void addConfigPage( TQWidget *page,
+ const TQString &sectionName,const TQString &itemName,
+ const TQString &pixmapName, const TQString &header=TQString(),
bool addSpacer = true );
void setupGeneralOptions();
@@ -114,11 +115,11 @@ namespace KileDialog
void writeGeneralOptionsConfig();
// synchronize encoding
- QString readKateEncoding();
+ TQString readKateEncoding();
void syncKileEncoding();
// editor pages
- QPtrList<KTextEditor::ConfigPage> editorPages;
+ TQPtrList<KTextEditor::ConfigPage> editorPages;
};
}
#endif
diff --git a/src/kile/kiledocmanager.cpp b/src/kile/kiledocmanager.cpp
index b94b4c4..8acc06c 100644
--- a/src/kile/kiledocmanager.cpp
+++ b/src/kile/kiledocmanager.cpp
@@ -22,9 +22,9 @@
#include "kiledocmanager.h"
-#include <qtextcodec.h>
-#include <qfile.h>
-#include <qdir.h>
+#include <tqtextcodec.h>
+#include <tqfile.h>
+#include <tqdir.h>
#include <kate/document.h>
#include <kate/view.h>
@@ -75,8 +75,8 @@
namespace KileDocument
{
-Manager::Manager(KileInfo *info, QObject *parent, const char *name) :
- QObject(parent, name),
+Manager::Manager(KileInfo *info, TQObject *tqparent, const char *name) :
+ TQObject(tqparent, name),
m_ki(info)
{
m_textInfoList.setAutoDelete(false);
@@ -84,10 +84,10 @@ Manager::Manager(KileInfo *info, QObject *parent, const char *name) :
Kate::Document::setFileChangedDialogsActivated (true);
if ( KileConfig::defaultEncoding() == "invalid" )
- KileConfig::setDefaultEncoding(QString::fromLatin1(QTextCodec::codecForLocale()->name()));
+ KileConfig::setDefaultEncoding(TQString::tqfromLatin1(TQTextCodec::codecForLocale()->name()));
- QWidget *par = m_ki ? m_ki->parentWidget() : 0;
- m_kpd = new KProgressDialog(par, 0, i18n("Open Project..."), QString::null, true);
+ TQWidget *par = m_ki ? m_ki->tqparentWidget() : 0;
+ m_kpd = new KProgressDialog(par, 0, i18n("Open Project..."), TQString(), true);
m_kpd->showCancelButton(false);
m_kpd->setLabel(i18n("Scanning project files..."));
m_kpd->setAutoClose(true);
@@ -164,13 +164,13 @@ Info* Manager::getInfo() const
return 0L;
}
-TextInfo* Manager::textInfoFor(const QString & path) const
+TextInfo* Manager::textInfoFor(const TQString & path) const
{
if( path.isEmpty() )
return 0L;
KILE_DEBUG() << "==KileInfo::textInfoFor(" << path << ")==========================" << endl;
- QPtrListIterator<TextInfo> it(m_textInfoList);
+ TQPtrListIterator<TextInfo> it(m_textInfoList);
while ( true )
{
if ( it.current()->url().path() == path)
@@ -191,7 +191,7 @@ TextInfo* Manager::textInfoForURL(const KURL& url)
return 0L;
KILE_DEBUG() << "==KileInfo::textInfoFor(" << url << ")==========================" << endl;
- QPtrListIterator<TextInfo> it(m_textInfoList);
+ TQPtrListIterator<TextInfo> it(m_textInfoList);
TextInfo *info;
while ( (info = it.current()) != 0L )
{
@@ -211,7 +211,7 @@ TextInfo* Manager::textInfoFor(Kate::Document* doc) const
if( !doc )
return 0L;
- QPtrListIterator<TextInfo> it(m_textInfoList);
+ TQPtrListIterator<TextInfo> it(m_textInfoList);
while ( true )
{
if ( it.current()->getDoc() == doc)
@@ -235,7 +235,7 @@ KileProject* Manager::projectFor(const KURL &projecturl)
KileProject *project = 0;
//find project with url = projecturl
- QPtrListIterator<KileProject> it(m_projects);
+ TQPtrListIterator<KileProject> it(m_projects);
while ( it.current() )
{
if ((*it)->url() == projecturl)
@@ -248,12 +248,12 @@ KileProject* Manager::projectFor(const KURL &projecturl)
return project;
}
-KileProject* Manager::projectFor(const QString &name)
+KileProject* Manager::projectFor(const TQString &name)
{
KileProject *project = 0;
//find project with url = projecturl
- QPtrListIterator<KileProject> it(m_projects);
+ TQPtrListIterator<KileProject> it(m_projects);
while ( it.current() )
{
if ((*it)->name() == name)
@@ -270,11 +270,11 @@ KileProjectItem* Manager::itemFor(const KURL &url, KileProject *project /*=0L*/)
{
if (project == 0L)
{
- QPtrListIterator<KileProject> it(m_projects);
+ TQPtrListIterator<KileProject> it(m_projects);
while ( it.current() )
{
KILE_DEBUG() << "looking in project " << (*it)->name() << endl;
- if ((*it)->contains(url))
+ if ((*it)->tqcontains(url))
{
KILE_DEBUG() << "\t\tfound!" << endl;
return (*it)->item(url);
@@ -285,7 +285,7 @@ KileProjectItem* Manager::itemFor(const KURL &url, KileProject *project /*=0L*/)
}
else
{
- if ( project->contains(url) )
+ if ( project->tqcontains(url) )
return project->item(url);
}
@@ -308,13 +308,13 @@ KileProjectItemList* Manager::itemsFor(Info *docinfo) const
KileProjectItemList *list = new KileProjectItemList();
list->setAutoDelete(false);
- QPtrListIterator<KileProject> it(m_projects);
+ TQPtrListIterator<KileProject> it(m_projects);
while ( it.current() )
{
KILE_DEBUG() << "\tproject: " << (*it)->name() << endl;
- if ((*it)->contains(docinfo))
+ if ((*it)->tqcontains(docinfo))
{
- KILE_DEBUG() << "\t\tcontains" << endl;
+ KILE_DEBUG() << "\t\ttqcontains" << endl;
list->append((*it)->item(docinfo));
}
++it;
@@ -337,7 +337,7 @@ KileProject* Manager::activeProject()
{
for (uint i=0; i < m_projects.count(); ++i)
{
- if (m_projects.at(i)->contains(doc->url()) )
+ if (m_projects.at(i)->tqcontains(doc->url()) )
{
curpr = m_projects.at(i);
break;
@@ -455,7 +455,7 @@ bool Manager::removeTextDocumentInfo(TextInfo *docinfo, bool closingproject /* =
return false;
}
-Kate::Document* Manager::createDocument(const QString& name, const KURL& url, TextInfo *docinfo, const QString & encoding, const QString & highlight)
+Kate::Document* Manager::createDocument(const TQString& name, const KURL& url, TextInfo *docinfo, const TQString & encoding, const TQString & highlight)
{
KILE_DEBUG() << "==Kate::Document* Manager::createDocument()===========" << endl;
@@ -466,7 +466,7 @@ Kate::Document* Manager::createDocument(const QString& name, const KURL& url, Te
KILE_DEBUG() << "\tappending document " << doc << endl;
//set the default encoding
- QString enc = encoding.isNull() ? KileConfig::defaultEncoding() : encoding;
+ TQString enc = encoding.isNull() ? KileConfig::defaultEncoding() : encoding;
doc->setEncoding(enc);
KILE_DEBUG() << "url is = " << docinfo->url() << endl;
@@ -483,23 +483,23 @@ Kate::Document* Manager::createDocument(const QString& name, const KURL& url, Te
doc->setDocName(name.isEmpty() ? url.fileName() : name);
//handle changes of the document
- connect(doc, SIGNAL(nameChanged(Kate::Document *)), m_ki->parentWidget(), SLOT(newCaption()));
- connect(doc, SIGNAL(fileNameChanged()), m_ki->parentWidget(), SLOT(newCaption()));
- connect(doc, SIGNAL(modStateChanged(Kate::Document*)), this, SLOT(newDocumentStatus(Kate::Document*)));
- connect(doc, SIGNAL(modifiedOnDisc(Kate::Document*, bool, unsigned char)), this, SIGNAL(documentStatusChanged(Kate::Document*, bool, unsigned char)));
+ connect(doc, TQT_SIGNAL(nameChanged(Kate::Document *)), m_ki->tqparentWidget(), TQT_SLOT(newCaption()));
+ connect(doc, TQT_SIGNAL(fileNameChanged()), m_ki->tqparentWidget(), TQT_SLOT(newCaption()));
+ connect(doc, TQT_SIGNAL(modStateChanged(Kate::Document*)), this, TQT_SLOT(newDocumenttqStatus(Kate::Document*)));
+ connect(doc, TQT_SIGNAL(modifiedOnDisc(Kate::Document*, bool, unsigned char)), this, TQT_SIGNAL(documentStatusChanged(Kate::Document*, bool, unsigned char)));
docinfo->setDoc(doc);
docinfo->setHighlightMode(highlight);
// FIXME: the whole structure updating stuff needs to be rewritten; updates should originate from
// the docinfo only, i.e. the structure view should just react to changes!
- connect(docinfo, SIGNAL(completed(KileDocument::Info*)), m_ki->structureWidget(), SLOT(update(KileDocument::Info*)));
+ connect(docinfo, TQT_SIGNAL(completed(KileDocument::Info*)), m_ki->structureWidget(), TQT_SLOT(update(KileDocument::Info*)));
KILE_DEBUG() << "createDocument: url " << doc->url() << " name " << doc->docName() << endl;
KILE_DEBUG() << "createDocument: SANITY check: " << (docinfo->getDoc() == docFor(docinfo->url())) << endl;
return doc;
}
-Kate::View* Manager::loadItem(KileDocument::Type type, KileProjectItem *item, const QString & text, bool openProjectItemViews)
+Kate::View* Manager::loadItem(KileDocument::Type type, KileProjectItem *item, const TQString & text, bool openProjectItemViews)
{
Kate::View *view = 0L;
@@ -507,7 +507,7 @@ Kate::View* Manager::loadItem(KileDocument::Type type, KileProjectItem *item, co
if ( item->type() != KileProjectItem::Image )
{
- view = loadText(type, QString::null, item->url(), item->encoding(), openProjectItemViews && item->isOpen(), item->highlight(), text);
+ view = loadText(type, TQString(), item->url(), item->encoding(), openProjectItemViews && item->isOpen(), item->highlight(), text);
KILE_DEBUG() << "\tloadItem: docfor = " << docFor(item->url().path()) << endl;
TextInfo *docinfo = textInfoFor(item->url().path());
@@ -532,7 +532,7 @@ Kate::View* Manager::loadItem(KileDocument::Type type, KileProjectItem *item, co
return view;
}
-Kate::View* Manager::loadText(KileDocument::Type type, const QString& name, const KURL &url , const QString & encoding /* = QString::null */, bool create /* = true */, const QString & highlight /* = QString::null */, const QString & text /* = QString::null */, int index /* = - 1 */, const KURL& baseDirectory /* = KURL() */)
+Kate::View* Manager::loadText(KileDocument::Type type, const TQString& name, const KURL &url , const TQString & encoding /* = TQString() */, bool create /* = true */, const TQString & highlight /* = TQString() */, const TQString & text /* = TQString() */, int index /* = - 1 */, const KURL& baseDirectory /* = KURL() */)
{
KILE_DEBUG() << "==loadText(" << url.url() << ")=================" << endl;
//if doc already opened, update the structure view and return the view
@@ -560,7 +560,7 @@ Kate::View* Manager::loadText(KileDocument::Type type, const QString& name, cons
//FIXME: template stuff should be in own class
Kate::View* Manager::loadTemplate(TemplateItem *sel)
{
- QString text = QString::null;
+ TQString text = TQString();
if (sel && sel->name() != DEFAULT_EMPTY_CAPTION && sel->name() != DEFAULT_EMPTY_LATEX_CAPTION && sel->name() != DEFAULT_EMPTY_BIBTEX_CAPTION)
{
@@ -569,7 +569,7 @@ Kate::View* Manager::loadTemplate(TemplateItem *sel)
if (!tempdoc->openURL(KURL(sel->path())))
{
- KMessageBox::error(m_ki->parentWidget(), i18n("Could not find template: %1").arg(sel->name()),i18n("File Not Found"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("Could not find template: %1").tqarg(sel->name()),i18n("File Not Found"));
}
else
{
@@ -582,17 +582,17 @@ Kate::View* Manager::loadTemplate(TemplateItem *sel)
KileDocument::Type type = sel ? sel->type() : KileDocument::Undefined;
//always set the base directory for scripts
- return createDocumentWithText(text, type, QString(), (type == KileDocument::Script ? m_ki->scriptManager()->getLocalJScriptDirectory() : QString()));
+ return createDocumentWithText(text, type, TQString(), (type == KileDocument::Script ? m_ki->scriptManager()->getLocalJScriptDirectory() : TQString()));
}
-Kate::View* Manager::createDocumentWithText(const QString& text, KileDocument::Type type /* = KileDocument::Undefined */, const QString& extension, const KURL& baseDirectory)
+Kate::View* Manager::createDocumentWithText(const TQString& text, KileDocument::Type type /* = KileDocument::Undefined */, const TQString& extension, const KURL& baseDirectory)
{
- Kate::View *view = loadText(type, KileUntitled::next() + (extension.isEmpty() ? QString::null : '.' + extension), KURL(), QString::null, true, QString::null, text, -1, baseDirectory);
+ Kate::View *view = loadText(type, KileUntitled::next() + (extension.isEmpty() ? TQString() : '.' + extension), KURL(), TQString(), true, TQString(), text, -1, baseDirectory);
if (view)
{
//FIXME this shouldn't be necessary!!!
view->getDoc()->setModified(true);
- newDocumentStatus(view->getDoc());
+ newDocumenttqStatus(view->getDoc());
}
return view;
@@ -600,26 +600,26 @@ Kate::View* Manager::createDocumentWithText(const QString& text, KileDocument::T
Kate::View* Manager::createNewJScript()
{
- Kate::View *view = createDocumentWithText(QString::null, Script, "js", m_ki->scriptManager()->getLocalJScriptDirectory());
+ Kate::View *view = createDocumentWithText(TQString(), Script, "js", m_ki->scriptManager()->getLocalJScriptDirectory());
emit(updateStructure(false, 0L));
- emit(updateModeStatus());
+ emit(updateModetqStatus());
return view;
}
Kate::View* Manager::createNewLaTeXDocument()
{
- Kate::View *view = createDocumentWithText(QString::null, LaTeX);
+ Kate::View *view = createDocumentWithText(TQString(), LaTeX);
emit(updateStructure(false, 0L));
- emit(updateModeStatus());
+ emit(updateModetqStatus());
return view;
}
-void Manager::replaceTemplateVariables(QString &line)
+void Manager::replaceTemplateVariables(TQString &line)
{
- line=line.replace("$$AUTHOR$$", KileConfig::author());
- line=line.replace("$$DOCUMENTCLASSOPTIONS$$", KileConfig::documentClassOptions());
- if (!KileConfig::templateEncoding().isEmpty()) { line=line.replace("$$INPUTENCODING$$", "\\usepackage["+ KileConfig::templateEncoding() +"]{inputenc}");}
- else { line = line.replace("$$INPUTENCODING$$","");}
+ line=line.tqreplace("$$AUTHOR$$", KileConfig::author());
+ line=line.tqreplace("$$DOCUMENTCLASSOPTIONS$$", KileConfig::documentClassOptions());
+ if (!KileConfig::templateEncoding().isEmpty()) { line=line.tqreplace("$$INPUTENCODING$$", "\\usepackage["+ KileConfig::templateEncoding() +"]{inputenc}");}
+ else { line = line.tqreplace("$$INPUTENCODING$$","");}
}
void Manager::createTemplate()
@@ -629,13 +629,13 @@ void Manager::createTemplate()
{
if (view->getDoc()->isModified() )
{
- KMessageBox::information(m_ki->parentWidget(),i18n("Please save the file first."));
+ KMessageBox::information(m_ki->tqparentWidget(),i18n("Please save the file first."));
return;
}
}
else
{
- KMessageBox::information(m_ki->parentWidget(),i18n("Open/create a document first."));
+ KMessageBox::information(m_ki->tqparentWidget(),i18n("Open/create a document first."));
return;
}
@@ -644,7 +644,7 @@ void Manager::createTemplate()
if(type == KileDocument::Undefined || type == KileDocument::Text)
{
- KMessageBox::information(m_ki->parentWidget(),i18n("Sorry, but a template for this type of document cannot be created."));
+ KMessageBox::information(m_ki->tqparentWidget(),i18n("Sorry, but a template for this type of document cannot be created."));
return;
}
@@ -660,13 +660,13 @@ void Manager::removeTemplate()
void Manager::fileNew()
{
- NewFileWizard *nfw = new NewFileWizard(m_ki->templateManager(), m_ki->parentWidget());
+ NewFileWizard *nfw = new NewFileWizard(m_ki->templateManager(), m_ki->tqparentWidget());
if (nfw->exec())
{
loadTemplate(nfw->getSelection());
if ( nfw->useWizard() ) emit ( startWizard() );
emit(updateStructure(false, 0L));
- emit(updateModeStatus());
+ emit(updateModetqStatus());
}
delete nfw;
}
@@ -674,33 +674,33 @@ void Manager::fileNew()
void Manager::fileNew(const KURL & url)
{
//create an empty file
- QFile file(url.path());
+ TQFile file(url.path());
file.open(IO_ReadWrite);
file.close();
- fileOpen(url, QString::null);
+ fileOpen(url, TQString());
}
void Manager::fileOpen()
{
//determine the starting dir for the file dialog
- QString compileName = m_ki->getCompileName();
- QString currentDir;
- if ( QFileInfo(compileName).exists() )
- currentDir = QFileInfo(compileName).dirPath(true);
+ TQString compileName = m_ki->getCompileName();
+ TQString currentDir;
+ if ( TQFileInfo(compileName).exists() )
+ currentDir = TQFileInfo(compileName).dirPath(true);
else
currentDir = m_ki->fileSelector()->dirOperator()->url().path();
// use a filter for fileOpen dialog
Extensions *extensions = m_ki->extensions();
- QString filter = extensions->latexDocumentFileFilter() + '\n'
+ TQString filter = extensions->latexDocumentFileFilter() + '\n'
+ extensions->latexPackageFileFilter() + '\n'
+ extensions->bibtexFileFilter() + '\n'
+ extensions->metapostFileFilter() + '\n'
+ "*|" + i18n("All Files");
//get the URLs
- KEncodingFileDialog::Result result = KEncodingFileDialog::getOpenURLsAndEncoding( KileConfig::defaultEncoding(), currentDir, filter, m_ki->parentWidget(), i18n("Open Files") );
+ KEncodingFileDialog::Result result = KEncodingFileDialog::getOpenURLsAndEncoding( KileConfig::defaultEncoding(), currentDir, filter, m_ki->tqparentWidget(), i18n("Open Files") );
//open them
KURL::List urls = result.URLs;
@@ -730,9 +730,9 @@ void Manager::saveURL(const KURL & url)
if (doc) doc->save();
}
-void Manager::newDocumentStatus(Kate::Document *doc)
+void Manager::newDocumenttqStatus(Kate::Document *doc)
{
- KILE_DEBUG() << "void Manager::newDocumentStatus(Kate::Document)" << endl;
+ KILE_DEBUG() << "void Manager::newDocumenttqStatus(Kate::Document)" << endl;
if (doc == 0L) return;
//sync terminal
@@ -748,7 +748,7 @@ void Manager::newDocumentStatus(Kate::Document *doc)
void Manager::fileSaveAll(bool amAutoSaving, bool disUntitled )
{
Kate::View *view= 0L;
- QFileInfo fi;
+ TQFileInfo fi;
int saveResult = Kate::View::SAVE_ERROR;
KURL url, backupUrl;
@@ -775,7 +775,7 @@ void Manager::fileSaveAll(bool amAutoSaving, bool disUntitled )
{
if( !fi.isWritable() )
{
- if ( autosaveWarnings.contains(url.path()) )
+ if ( autosaveWarnings.tqcontains(url.path()) )
{
KILE_DEBUG() << "File " << url.prettyURL() << " is not writeable (again), trying next file" << endl;
continue;
@@ -818,7 +818,7 @@ void Manager::fileSaveAll(bool amAutoSaving, bool disUntitled )
else
{
KILE_DEBUG()<<"backing up failed ("<<url.prettyURL()<<" -> "<<backupUrl.prettyURL()<<")"<<endl;
- emit printMsg(KileTool::Error,i18n("The file %1 could not be saved, check the permissions and the free disk space!").arg(backupUrl.prettyURL()),i18n("Autosave"));
+ emit printMsg(KileTool::Error,i18n("The file %1 could not be saved, check the permissions and the free disk space!").tqarg(backupUrl.prettyURL()),i18n("Autosave"));
}
}
@@ -827,7 +827,7 @@ void Manager::fileSaveAll(bool amAutoSaving, bool disUntitled )
fi.refresh();
if(saveResult == Kate::View::SAVE_ERROR && fi.size() == 0 && !url.isEmpty()) // we probably hit bug #125809, inform the user of the possible consequences
- emit printMsg(KileTool::Error,i18n("Kile encountered problems while saving the file %1. Do you have enough free disk space left?").arg(url.url()),i18n("Saving"));
+ emit printMsg(KileTool::Error,i18n("Kile encountered problems while saving the file %1. Do you have enough free disk space left?").tqarg(url.url()),i18n("Saving"));
}
}
}
@@ -838,7 +838,7 @@ void Manager::fileSaveAll(bool amAutoSaving, bool disUntitled )
emit(updateStructure(false,NULL));
}
-void Manager::fileOpen(const KURL & url, const QString & encoding, int index)
+void Manager::fileOpen(const KURL & url, const TQString & encoding, int index)
{
KILE_DEBUG() << "==Kile::fileOpen==========================" << endl;
@@ -852,7 +852,7 @@ void Manager::fileOpen(const KURL & url, const QString & encoding, int index)
bool isopen = m_ki->isOpen(realurl);
- Kate::View *view = loadText(m_ki->extensions()->determineDocumentType(realurl), QString::null, realurl, encoding, true, QString::null, QString::null, index);
+ Kate::View *view = loadText(m_ki->extensions()->determineDocumentType(realurl), TQString(), realurl, encoding, true, TQString(), TQString(), index);
KileProjectItem *item = itemFor(realurl);
if(!isopen)
@@ -864,7 +864,7 @@ void Manager::fileOpen(const KURL & url, const QString & encoding, int index)
}
emit(updateStructure(true, 0L));
- emit(updateModeStatus());
+ emit(updateModetqStatus());
// update undefined references in this file
emit(updateReferences(textInfoFor(realurl.path())) );
m_ki->fileSelector()->blockSignals(false);
@@ -922,8 +922,8 @@ void Manager::fileSaveAs(Kate::View* view)
KURL saveURL;
while(true)
{
- QString filter = info->getFileFilter() + "\n* |" + i18n("All Files");
- result = KEncodingFileDialog::getSaveURLAndEncoding(KileConfig::defaultEncoding(), startURL.url(), filter, m_ki->parentWidget(), i18n("Save File"));
+ TQString filter = info->getFileFilter() + "\n* |" + i18n("All Files");
+ result = KEncodingFileDialog::getSaveURLAndEncoding(KileConfig::defaultEncoding(), startURL.url(), filter, m_ki->tqparentWidget(), i18n("Save File"));
if(result.URLs.isEmpty() || result.URLs.first().isEmpty())
{
return;
@@ -934,7 +934,7 @@ void Manager::fileSaveAs(Kate::View* view)
}
if(KIO::NetAccess::exists(saveURL, true, kapp->mainWidget())) // check for writing possibility
{
- int r = KMessageBox::warningContinueCancel(m_ki->parentWidget(), i18n("A file with the name \"%1\" exists already. Do you want to overwrite it ?").arg(saveURL.fileName()), i18n("Overwrite File ?"), KGuiItem(i18n("&Overwrite")), QString::null);
+ int r = KMessageBox::warningContinueCancel(m_ki->tqparentWidget(), i18n("A file with the name \"%1\" exists already. Do you want to overwrite it ?").tqarg(saveURL.fileName()), i18n("Overwrite File ?"), KGuiItem(i18n("&Overwrite")), TQString());
if(r != KMessageBox::Continue)
{
continue;
@@ -1077,7 +1077,7 @@ bool Manager::fileClose(Kate::Document *doc /* = 0L*/, bool closingproject /*= f
removeTextDocumentInfo(docinfo, closingproject);
emit removeFromProjectView(url);
- emit updateModeStatus();
+ emit updateModetqStatus();
}
else
return false;
@@ -1108,13 +1108,13 @@ void Manager::buildProjectTree(KileProject *project)
project->buildProjectTree();
}
else if (m_projects.count() == 0)
- KMessageBox::error(m_ki->parentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to build the tree for, then choose Refresh Project Tree again."),i18n( "Could Not Refresh Project Tree"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to build the tree for, then choose Refresh Project Tree again."),i18n( "Could Not Refresh Project Tree"));
}
void Manager::projectNew()
{
KILE_DEBUG() << "==Kile::projectNew==========================" << endl;
- KileNewProjectDlg *dlg = new KileNewProjectDlg(m_ki->templateManager(), m_ki->extensions(), m_ki->parentWidget());
+ KileNewProjectDlg *dlg = new KileNewProjectDlg(m_ki->templateManager(), m_ki->extensions(), m_ki->tqparentWidget());
KILE_DEBUG()<< "\tdialog created" << endl;
if (dlg->exec())
@@ -1132,7 +1132,7 @@ void Manager::projectNew()
if (dlg->createNewFile())
{
- QString filename = dlg->file();
+ TQString filename = dlg->file();
//create the new document and fill it with the template
//TODO: shell expand the filename
@@ -1160,7 +1160,7 @@ void Manager::projectNew()
project->buildProjectTree();
//project->save();
addProject(project);
- emit(updateModeStatus());
+ emit(updateModetqStatus());
emit(addToRecentProjects(project->url()));
}
}
@@ -1171,13 +1171,13 @@ void Manager::addProject(const KileProject *project)
m_projects.append(project);
KILE_DEBUG() << "\tnow " << m_projects.count() << " projects" << endl;
emit addToProjectView(project);
- connect(project, SIGNAL(projectTreeChanged(const KileProject *)), this, SIGNAL(projectTreeChanged(const KileProject *)));
+ connect(project, TQT_SIGNAL(projectTreeChanged(const KileProject *)), this, TQT_SIGNAL(projectTreeChanged(const KileProject *)));
}
-KileProject* Manager::selectProject(const QString& caption)
+KileProject* Manager::selectProject(const TQString& caption)
{
- QStringList list;
- QPtrListIterator<KileProject> it(m_projects);
+ TQStringList list;
+ TQPtrListIterator<KileProject> it(m_projects);
while (it.current())
{
list.append((*it)->name());
@@ -1185,10 +1185,10 @@ KileProject* Manager::selectProject(const QString& caption)
}
KileProject *project = 0;
- QString name = QString::null;
+ TQString name = TQString();
if (list.count() > 1)
{
- KileListSelector *dlg = new KileListSelector(list, caption, i18n("Select Project"), m_ki->parentWidget());
+ KileListSelector *dlg = new KileListSelector(list, caption, i18n("Select Project"), m_ki->tqparentWidget());
if (dlg->exec())
{
name = list[dlg->currentItem()];
@@ -1220,16 +1220,16 @@ void Manager::addToProject(const KURL & url)
void Manager::addToProject(KileProject* project, const KURL & url)
{
const KURL realurl = symlinkFreeURL(url);
- QFileInfo fi(realurl.path());
+ TQFileInfo fi(realurl.path());
- if (project->contains(realurl))
+ if (project->tqcontains(realurl))
{
- emit printMsg(KileTool::Info,i18n("The file %1 is already member of the project %2").arg(realurl.filename()).arg(project->name()),i18n("Add to Project"));
+ emit printMsg(KileTool::Info,i18n("The file %1 is already member of the project %2").tqarg(realurl.filename()).tqarg(project->name()),i18n("Add to Project"));
return;
}
else if(!fi.exists() || !fi.isReadable())
{
- emit printMsg( KileTool::Info,i18n("The file %1 can not be added because it does not exist or is not readable").arg(realurl.filename()),i18n("Add to Project"));
+ emit printMsg( KileTool::Info,i18n("The file %1 can not be added because it does not exist or is not readable").tqarg(realurl.filename()),i18n("Add to Project"));
return;
}
@@ -1248,7 +1248,7 @@ void Manager::removeFromProject(const KileProjectItem *item)
if (item->project()->url() == item->url())
{
- KMessageBox::error(m_ki->parentWidget(), i18n("This file is the project file, it holds all the information about your project. Therefore it is not allowed to remove this file from its project."), i18n("Cannot Remove File From Project"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("This file is the project file, it holds all the information about your project. Therefore it is not allowed to remove this file from its project."), i18n("Cannot Remove File From Project"));
return;
}
@@ -1271,14 +1271,14 @@ void Manager::projectOpenItem(KileProjectItem *item, bool openProjectItemViews)
if (m_ki->isOpen(item->url())) //remove item from projectview (this file was opened before as a normal file)
emit removeFromProjectView(item->url());
- Kate::View *view = loadItem(m_ki->extensions()->determineDocumentType(item->url()), item, QString::null, openProjectItemViews);
+ Kate::View *view = loadItem(m_ki->extensions()->determineDocumentType(item->url()), item, TQString(), openProjectItemViews);
if ( (!item->isOpen()) && (view == 0L) && (item->getInfo()) ) //doc shouldn't be displayed, trash the doc
trashDoc(item->getInfo());
else if (view != 0L)
view->setCursorPosition(item->lineNumber(), item->columnNumber());
- //oops, doc apparently was open while the project settings wants it closed, don't trash it the doc, update openstate instead
+ //oops, doc aptqparently was open while the project settings wants it closed, don't trash it the doc, update openstate instead
if ((!item->isOpen()) && (view != 0L))
item->setOpenState(true);
}
@@ -1294,16 +1294,16 @@ KileProject* Manager::projectOpen(const KURL & url, int step, int max, bool open
{
m_kpd->cancel();
- KMessageBox::information(m_ki->parentWidget(), i18n("The project you tried to open is already opened. If you wanted to reload the project, close the project before you re-open it."),i18n("Project Already Open"));
+ KMessageBox::information(m_ki->tqparentWidget(), i18n("The project you tried to open is already opened. If you wanted to reload the project, close the project before you re-open it."),i18n("Project Already Open"));
return 0L;
}
- QFileInfo fi(realurl.path());
+ TQFileInfo fi(realurl.path());
if ( ! fi.isReadable() )
{
m_kpd->cancel();
- if (KMessageBox::warningYesNo(m_ki->parentWidget(), i18n("The project file for this project does not exists or is not readable. Remove this project from the recent projects list?"),i18n("Could Not Load Project File")) == KMessageBox::Yes)
+ if (KMessageBox::warningYesNo(m_ki->tqparentWidget(), i18n("The project file for this project does not exists or is not readable. Remove this project from the recent projects list?"),i18n("Could Not Load Project File")) == KMessageBox::Yes)
emit(removeFromRecentProjects(realurl));
return 0L;
@@ -1330,8 +1330,8 @@ KileProject* Manager::projectOpen(const KURL & url, int step, int max, bool open
m_kpd->progressBar()->setValue(project_steps);
// open the project files in the correct order
- QValueVector<KileProjectItem*> givenPositionVector(list->count(), NULL);
- QValueList<KileProjectItem*> notCorrectlyOrderedList;
+ TQValueVector<KileProjectItem*> givenPositionVector(list->count(), NULL);
+ TQValueList<KileProjectItem*> notCorrectlyOrderedList;
for(KileProjectItem *item = list->first(); item; item = list->next())
{
int order = item->order();
@@ -1349,7 +1349,7 @@ KileProject* Manager::projectOpen(const KURL & url, int step, int max, bool open
}
}
- QValueList<KileProjectItem*> orderedList;
+ TQValueList<KileProjectItem*> orderedList;
for(unsigned int i = 0; i < givenPositionVector.size(); ++i)
{
KileProjectItem *item = givenPositionVector[i];
@@ -1358,13 +1358,13 @@ KileProject* Manager::projectOpen(const KURL & url, int step, int max, bool open
orderedList.push_back(item);
}
}
- for(QValueList<KileProjectItem*>::iterator i = notCorrectlyOrderedList.begin(); i != notCorrectlyOrderedList.end(); ++i)
+ for(TQValueList<KileProjectItem*>::iterator i = notCorrectlyOrderedList.begin(); i != notCorrectlyOrderedList.end(); ++i)
{
orderedList.push_back(*i);
}
unsigned int counter = 0;
- for (QValueList<KileProjectItem*>::iterator i = orderedList.begin(); i != orderedList.end(); ++i)
+ for (TQValueList<KileProjectItem*>::iterator i = orderedList.begin(); i != orderedList.end(); ++i)
{
projectOpenItem(*i, openProjectItemViews);
m_kpd->progressBar()->setValue(counter + project_steps);
@@ -1376,7 +1376,7 @@ KileProject* Manager::projectOpen(const KURL & url, int step, int max, bool open
addProject(kp);
emit(updateStructure(false, 0L));
- emit(updateModeStatus());
+ emit(updateModetqStatus());
// update undefined references in all project files
updateProjectReferences(kp);
@@ -1401,7 +1401,7 @@ void Manager::updateProjectReferences(KileProject *project)
KileProject* Manager::projectOpen()
{
KILE_DEBUG() << "==Kile::projectOpen==========================" << endl;
- KURL url = KFileDialog::getOpenURL( KileConfig::defaultProjectLocation(), i18n("*.kilepr|Kile Project Files\n*|All Files"), m_ki->parentWidget(), i18n("Open Project") );
+ KURL url = KFileDialog::getOpenURL( KileConfig::defaultProjectLocation(), i18n("*.kilepr|Kile Project Files\n*|All Files"), m_ki->tqparentWidget(), i18n("Open Project") );
if (!url.isEmpty())
return projectOpen(url);
@@ -1430,7 +1430,7 @@ void Manager::projectSave(KileProject *project /* = 0 */)
TextInfo *docinfo = NULL;
// determine the order in which the project items are opened
- QValueVector<KileProjectItem*> viewPositionVector(m_ki->viewManager()->getTabCount(), NULL);
+ TQValueVector<KileProjectItem*> viewPositionVector(m_ki->viewManager()->getTabCount(), NULL);
for (KileProjectItemList::iterator i = list->begin(); i != list->end(); ++i)
{
docinfo = (*i)->getInfo();
@@ -1477,7 +1477,7 @@ void Manager::projectSave(KileProject *project /* = 0 */)
project->save();
}
else
- KMessageBox::error(m_ki->parentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to save, then choose Save Project again."),i18n( "Could Determine Active Project"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to save, then choose Save Project again."),i18n( "Could Determine Active Project"));
}
void Manager::projectAddFiles(const KURL & url)
@@ -1499,14 +1499,14 @@ void Manager::projectAddFiles(KileProject *project,const KURL & fileUrl)
if (project)
{
- QString currentDir;
+ TQString currentDir;
if(fileUrl.isEmpty())
currentDir=project->url().directory();
else
currentDir=fileUrl.directory();
KILE_DEBUG() << "currentDir is " << currentDir << endl;
- KFileDialog *dlg = new KFileDialog(currentDir, i18n("*|All Files"),m_ki->parentWidget(), 0, true );
+ KFileDialog *dlg = new KFileDialog(currentDir, i18n("*|All Files"),m_ki->tqparentWidget(), 0, true );
KPushButton* okButton = dlg->okButton();
okButton->setText(i18n("Add"));
dlg->setCaption(i18n("Add Files"));
@@ -1528,7 +1528,7 @@ void Manager::projectAddFiles(KileProject *project,const KURL & fileUrl)
//open them
}
else if (m_projects.count() == 0)
- KMessageBox::error(m_ki->parentWidget(), i18n("There are no projects opened. Please open the project you want to add files to, then choose Add Files again."),i18n( "Could Not Determine Active Project"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("There are no projects opened. Please open the project you want to add files to, then choose Add Files again."),i18n( "Could Not Determine Active Project"));
}
void Manager::toggleArchive(KileProjectItem *item)
@@ -1556,11 +1556,11 @@ void Manager::projectOptions(KileProject *project /* = 0*/)
if (project)
{
KILE_DEBUG() << "\t" << project->name() << endl;
- KileProjectOptionsDlg *dlg = new KileProjectOptionsDlg(project, m_ki->extensions(), m_ki->parentWidget());
+ KileProjectOptionsDlg *dlg = new KileProjectOptionsDlg(project, m_ki->extensions(), m_ki->tqparentWidget());
dlg->exec();
}
else if (m_projects.count() == 0)
- KMessageBox::error(m_ki->parentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to modify, then choose Project Options again."),i18n( "Could Not Determine Active Project"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to modify, then choose Project Options again."),i18n( "Could Not Determine Active Project"));
}
bool Manager::projectCloseAll()
@@ -1568,7 +1568,7 @@ bool Manager::projectCloseAll()
KILE_DEBUG() << "==Kile::projectCloseAll==========================" << endl;
bool close = true;
- QPtrListIterator<KileProject> it(m_projects);
+ TQPtrListIterator<KileProject> it(m_projects);
int i = m_projects.count() + 1;
while ( it.current() && close && (i > 0))
{
@@ -1640,14 +1640,14 @@ bool Manager::projectClose(const KURL & url)
m_projects.remove(project);
emit removeFromProjectView(project);
delete project;
- emit(updateModeStatus());
+ emit(updateModetqStatus());
return true;
}
else
return false;
}
else if (m_projects.count() == 0)
- KMessageBox::error(m_ki->parentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to close, then choose Close Project again."),i18n( "Could Not Close Project"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("The current document is not associated to a project. Please activate a document that is associated to the project you want to close, then choose Close Project again."),i18n( "Could Not Close Project"));
return true;
}
@@ -1659,7 +1659,7 @@ void Manager::storeProjectItem(KileProjectItem *item, Kate::Document *doc)
item->setEncoding(doc->encoding());
item->setHighlight(doc->hlModeName(doc->hlMode()));
uint l = 0, c = 0;
- QPtrList<KTextEditor::View> viewList = doc->views();
+ TQPtrList<KTextEditor::View> viewList = doc->views();
if(!viewList.isEmpty()) {
Kate::View *view = static_cast<Kate::View*>(viewList.first());
@@ -1680,12 +1680,12 @@ void Manager::cleanUpTempFiles(const KURL &url, bool silent)
if( url.isEmpty() )
return;
- QStringList extlist;
- QFileInfo fi(url.path());
- const QStringList templist = QStringList::split(" ", KileConfig::cleanUpFileExtensions());
- const QString fileName = fi.fileName();
- const QString dirPath = fi.dirPath(true);
- const QString baseName = fi.baseName(true);
+ TQStringList extlist;
+ TQFileInfo fi(url.path());
+ const TQStringList templist = TQStringList::split(" ", KileConfig::cleanUpFileExtensions());
+ const TQString fileName = fi.fileName();
+ const TQString dirPath = fi.dirPath(true);
+ const TQString baseName = fi.baseName(true);
for (uint i=0; i < templist.count(); ++i)
{
@@ -1700,7 +1700,7 @@ void Manager::cleanUpTempFiles(const KURL &url, bool silent)
if (!silent && extlist.count() > 0 )
{
KILE_DEBUG() << "not silent" << endl;
- KileDialog::Clean *dialog = new KileDialog::Clean(m_ki->parentWidget(), fileName, extlist);
+ KileDialog::Clean *dialog = new KileDialog::Clean(m_ki->tqparentWidget(), fileName, extlist);
if ( dialog->exec() )
extlist = dialog->getCleanlist();
else
@@ -1713,20 +1713,20 @@ void Manager::cleanUpTempFiles(const KURL &url, bool silent)
}
if ( extlist.count() == 0 )
- emit printMsg(KileTool::Warning, i18n("Nothing to clean for %1").arg(fileName), i18n("Clean"));
+ emit printMsg(KileTool::Warning, i18n("Nothing to clean for %1").tqarg(fileName), i18n("Clean"));
else
{
for ( uint i = 0 ; i < extlist.count() ; ++i )
{
- QFile file( dirPath + '/' + baseName + extlist[i] );
+ TQFile file( dirPath + '/' + baseName + extlist[i] );
KILE_DEBUG() << "About to remove file = " << file.name() << endl;
file.remove();
}
- emit printMsg(KileTool::Info, i18n("Cleaning %1 : %2").arg(fileName).arg(extlist.join(" ")), i18n("Clean"));
+ emit printMsg(KileTool::Info, i18n("Cleaning %1 : %2").tqarg(fileName).tqarg(extlist.join(" ")), i18n("Clean"));
}
}
-void Manager::openDroppedURLs(QDropEvent *e) {
+void Manager::openDroppedURLs(TQDropEvent *e) {
KURL::List urls;
Extensions *extensions = m_ki->extensions();
if(KURLDrag::decode(e, urls)) {
@@ -1768,14 +1768,14 @@ void Manager::projectShow()
KileProjectItemList *list = project->items();
for ( KileProjectItem *item=list->first(); item; item=list->next() )
{
- QString itempath = item->path();
+ TQString itempath = item->path();
// called from KAction 'Show projects...': find the first opened
// LaTeX document or, if that fails, any other opened file
- QStringList extlist = QStringList::split(" ",m_ki->extensions()->latexDocuments() + ' ' + m_ki->extensions()->latexPackages());
- for ( QStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
+ TQStringList extlist = TQStringList::split(" ",m_ki->extensions()->latexDocuments() + ' ' + m_ki->extensions()->latexPackages());
+ for ( TQStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
{
- if ( itempath.find( (*it), -(*it).length() ) >= 0 )
+ if ( itempath.tqfind( (*it), -(*it).length() ) >= 0 )
{
if ( m_ki->isOpen(item->url()) )
{
@@ -1876,9 +1876,9 @@ void Manager::projectOpenAllFiles(const KURL & url)
m_ki->viewManager()->switchToTextView(doc->url());
}
-QStringList Manager::getProjectFiles()
+TQStringList Manager::getProjectFiles()
{
- QStringList filelist;
+ TQStringList filelist;
KileProject *project = activeProject();
if ( project )
@@ -1893,12 +1893,12 @@ QStringList Manager::getProjectFiles()
return filelist;
}
-void Manager::dontOpenWarning(KileProjectItem *item, const QString &action, const QString &filetype)
+void Manager::dontOpenWarning(KileProjectItem *item, const TQString &action, const TQString &filetype)
{
- emit printMsg(KileTool::Info, i18n("not opened: %1 (%2)").arg(item->url().path()).arg(filetype), action);
+ emit printMsg(KileTool::Info, i18n("not opened: %1 (%2)").tqarg(item->url().path()).tqarg(filetype), action);
}
-KileProjectItem* Manager::selectProjectFileItem(const QString &label)
+KileProjectItem* Manager::selectProjectFileItem(const TQString &label)
{
// select a project
KileProject *project = selectProject(i18n("Select Project"));
@@ -1906,8 +1906,8 @@ KileProjectItem* Manager::selectProjectFileItem(const QString &label)
return 0L;
// get a list of files
- QStringList filelist;
- QMap<QString,KileProjectItem *> map;
+ TQStringList filelist;
+ TQMap<TQString,KileProjectItem *> map;
KileProjectItemList *list = project->items();
for ( KileProjectItem *item=list->first(); item; item = list->next() ) {
filelist << item->path();
@@ -1916,14 +1916,14 @@ KileProjectItem* Manager::selectProjectFileItem(const QString &label)
// select one of these files
KileProjectItem *item = 0L;
- KileListSelector *dlg = new KileListSelector(filelist,i18n("Project Files"),label, m_ki->parentWidget());
+ KileListSelector *dlg = new KileListSelector(filelist,i18n("Project Files"),label, m_ki->tqparentWidget());
if ( dlg->exec() ) {
if ( dlg->currentItem() >= 0 ) {
- QString name = filelist[dlg->currentItem()];
- if ( map.contains(name) )
+ TQString name = filelist[dlg->currentItem()];
+ if ( map.tqcontains(name) )
item = map[name];
else
- KMessageBox::error(m_ki->parentWidget(), i18n("Could not determine the selected file."),i18n( "Project Error"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("Could not determine the selected file."),i18n( "Project Error"));
}
}
delete dlg;
@@ -1931,14 +1931,14 @@ KileProjectItem* Manager::selectProjectFileItem(const QString &label)
return item;
}
-KileProjectItemList* Manager::selectProjectFileItems(const QString &label)
+KileProjectItemList* Manager::selectProjectFileItems(const TQString &label)
{
KileProject *project = selectProject(i18n("Select Project"));
if ( ! project )
return 0L;
- QStringList filelist, selectedfiles;
- QMap<QString,KileProjectItem *> map;
+ TQStringList filelist, selectedfiles;
+ TQMap<TQString,KileProjectItem *> map;
KileProjectItemList *list = project->items();
for ( KileProjectItem *item=list->first(); item; item = list->next() ) {
@@ -1949,15 +1949,15 @@ KileProjectItemList* Manager::selectProjectFileItems(const QString &label)
KileProjectItemList *items = new KileProjectItemList();
items->setAutoDelete(false);
- KileListSelectorMultiple *dlg = new KileListSelectorMultiple(filelist,i18n("Project Files"),label, m_ki->parentWidget());
+ KileListSelectorMultiple *dlg = new KileListSelectorMultiple(filelist,i18n("Project Files"),label, m_ki->tqparentWidget());
if ( dlg->exec() ) {
if ( dlg->currentItem() >= 0 ) {
selectedfiles = dlg->selected();
- for ( QStringList::Iterator it = selectedfiles.begin(); it != selectedfiles.end(); ++it ){
- if ( map.contains(*it) )
+ for ( TQStringList::Iterator it = selectedfiles.begin(); it != selectedfiles.end(); ++it ){
+ if ( map.tqcontains(*it) )
items->append( map[(*it)] );
else
- KMessageBox::error(m_ki->parentWidget(), i18n("Could not determine the selected file."),i18n( "Project Error"));
+ KMessageBox::error(m_ki->tqparentWidget(), i18n("Could not determine the selected file."),i18n( "Project Error"));
}
}
}
@@ -1970,14 +1970,14 @@ KileProjectItemList* Manager::selectProjectFileItems(const QString &label)
// - only when there is an active project
// - if the file doesn't already belong to it (checked by addToProject)
-void Manager::projectAddFile(QString filename, bool graphics)
+void Manager::projectAddFile(TQString filename, bool graphics)
{
KILE_DEBUG() << "===Kile::projectAddFile==============" << endl;
KileProject *project = activeProject();
if ( ! project )
return;
- QFileInfo fi(filename);
+ TQFileInfo fi(filename);
if ( ! fi.exists() )
{
if ( graphics )
@@ -1986,12 +1986,12 @@ void Manager::projectAddFile(QString filename, bool graphics)
// called from InputDialog after a \input- or \include command:
// - if the chosen file has an extension: accept
// - if not we add the default TeX extension: accept if it exists else reject
- QString ext = fi.extension();
+ TQString ext = fi.extension();
if ( ! ext.isEmpty() )
return;
filename += m_ki->extensions()->latexDocumentDefault();
- if ( QFileInfo(filename).exists() )
+ if ( TQFileInfo(filename).exists() )
return;
}
@@ -2011,8 +2011,8 @@ const KURL Manager::symlinkFreeURL(const KURL& url)
if( !url.isLocalFile() )
return url;
- QDir dir(url.directory());
- QString filename=url.path(); // if the directory does not exist we return the old url (just to be sure)
+ TQDir dir(url.directory());
+ TQString filename=url.path(); // if the directory does not exist we return the old url (just to be sure)
if(dir.exists())
filename= dir.canonicalPath() + '/' + url.filename();
@@ -2025,7 +2025,7 @@ const KURL Manager::symlinkFreeURL(const KURL& url)
void Manager::cleanupDocumentInfoForProjectItems(KileDocument::Info *info)
{
KileProjectItemList *itms = itemsFor(info);
- QPtrListIterator<KileProjectItem> it(*itms);
+ TQPtrListIterator<KileProjectItem> it(*itms);
KileProjectItem *current;
while((current = it.current()) != 0)
{
diff --git a/src/kile/kiledocmanager.h b/src/kile/kiledocmanager.h
index 1b103d0..cc138b1 100644
--- a/src/kile/kiledocmanager.h
+++ b/src/kile/kiledocmanager.h
@@ -22,7 +22,7 @@
#ifndef KILEDOCUMENTKILEDOCMANAGER_H
#define KILEDOCUMENTKILEDOCMANAGER_H
-#include <qobject.h>
+#include <tqobject.h>
#include "kileconstants.h"
#include "kileproject.h"
@@ -46,11 +46,12 @@ class TextInfo;
/**
@author Jeroen Wijnhout
*/
-class Manager : public QObject
+class Manager : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- Manager(KileInfo *info, QObject *parent = 0, const char *name = 0);
+ Manager(KileInfo *info, TQObject *tqparent = 0, const char *name = 0);
~Manager();
public slots:
@@ -58,7 +59,7 @@ public slots:
Kate::View* createNewLaTeXDocument();
//files
- void newDocumentStatus(Kate::Document *doc);
+ void newDocumenttqStatus(Kate::Document *doc);
/**
* Creates a new file on disk.
@@ -71,7 +72,7 @@ public slots:
void fileSelected(const KFileItem *file);
void fileOpen();
- void fileOpen(const KURL& url, const QString & encoding = QString::null, int index = -1);
+ void fileOpen(const KURL& url, const TQString & encoding = TQString(), int index = -1);
void fileSave();
void fileSaveAs(Kate::View* = 0L);
@@ -89,7 +90,7 @@ public slots:
Kate::View* loadTemplate(TemplateItem*);
void createTemplate();
void removeTemplate();
- void replaceTemplateVariables(QString &line);
+ void replaceTemplateVariables(TQString &line);
//projects
void projectNew();
@@ -122,11 +123,11 @@ public slots:
void projectShow();
void projectRemoveFiles();
void projectShowFiles();
- void projectAddFile(QString filename, bool graphics=false);
+ void projectAddFile(TQString filename, bool graphics=false);
void projectOpenAllFiles();
void projectOpenAllFiles(const KURL &);
- KileProject* selectProject(const QString &);
+ KileProject* selectProject(const TQString &);
void addProject(const KileProject *project);
void addToProject(const KURL &);
@@ -136,7 +137,7 @@ public slots:
void cleanUpTempFiles(const KURL &url, bool silent = false);
- void openDroppedURLs(QDropEvent *e);
+ void openDroppedURLs(TQDropEvent *e);
signals:
void projectTreeChanged(const KileProject *);
@@ -144,7 +145,7 @@ signals:
void documentInfoCreated(KileDocument::Info *);
void updateStructure(bool needToParse, KileDocument::Info*);
- void updateModeStatus();
+ void updateModetqStatus();
void updateReferences(KileDocument::Info *);
void documentStatusChanged(Kate::Document *, bool, unsigned char reason);
@@ -155,7 +156,7 @@ signals:
void startWizard();
- void printMsg(int type, const QString & message, const QString &tool = "Kile" );
+ void printMsg(int type, const TQString & message, const TQString &tool = "Kile" );
void removeFromProjectView(const KURL &);
void removeFromProjectView(const KileProject *);
@@ -165,25 +166,25 @@ signals:
void addToProjectView(const KileProject *);
public:
- QPtrList<KileProject>* projects() { return &m_projects; }
- QPtrList<TextInfo>* textDocumentInfos() { return &m_textInfoList; }
+ TQPtrList<KileProject>* projects() { return &m_projects; }
+ TQPtrList<TextInfo>* textDocumentInfos() { return &m_textInfoList; }
Kate::Document* docFor(const KURL &url);
Info* getInfo() const;
// FIXME: "path" should be changed to a URL, i.e. only the next but one function
// should be used
- TextInfo* textInfoFor(const QString &path) const;
+ TextInfo* textInfoFor(const TQString &path) const;
TextInfo* textInfoForURL(const KURL& url);
TextInfo* textInfoFor(Kate::Document* doc) const;
void updateInfos();
KileProject* projectFor(const KURL &projecturl);
- KileProject* projectFor(const QString & name);
+ KileProject* projectFor(const TQString & name);
KileProject* activeProject();
bool isProjectOpen();
void updateProjectReferences(KileProject *project);
- QStringList getProjectFiles();
+ TQStringList getProjectFiles();
KileProjectItem* activeProjectItem();
/**
@@ -192,8 +193,8 @@ public:
**/
KileProjectItem* itemFor(const KURL &url, KileProject *project = 0) const;
KileProjectItem* itemFor(Info *docinfo, KileProject *project = 0) const;
- KileProjectItem* selectProjectFileItem(const QString &label);
- KileProjectItemList* selectProjectFileItems(const QString &label);
+ KileProjectItem* selectProjectFileItem(const TQString &label);
+ KileProjectItemList* selectProjectFileItems(const TQString &label);
KileProjectItemList* itemsFor(Info *docinfo) const;
@@ -215,28 +216,28 @@ protected:
* @warning This method does not close or delete any Kate documents that are associated with the TextInfo object !
**/
bool removeTextDocumentInfo(TextInfo *docinfo, bool closingproject = false);
- Kate::Document* createDocument(const QString& name, const KURL& url, TextInfo *docinfo, const QString & encoding, const QString & highlight);
+ Kate::Document* createDocument(const TQString& name, const KURL& url, TextInfo *docinfo, const TQString & encoding, const TQString & highlight);
/**
* Creates a document with the specified text.
*
* @param extension The extension of the file that should be created without leading "."
**/
- Kate::View* createDocumentWithText(const QString& text, KileDocument::Type type = KileDocument::Text, const QString& extension = QString::null, const KURL& baseDirectory = KURL());
+ Kate::View* createDocumentWithText(const TQString& text, KileDocument::Type type = KileDocument::Text, const TQString& extension = TQString(), const KURL& baseDirectory = KURL());
- Kate::View* loadText(KileDocument::Type type, const QString& name, const KURL &url, const QString & encoding = QString::null, bool create = true, const QString & highlight = QString::null, const QString &text = QString::null, int index = -1, const KURL& baseDirectory = KURL());
- Kate::View* loadItem(KileDocument::Type type, KileProjectItem *item, const QString & text = QString::null, bool openProjectItemViews = true);
+ Kate::View* loadText(KileDocument::Type type, const TQString& name, const KURL &url, const TQString & encoding = TQString(), bool create = true, const TQString & highlight = TQString(), const TQString &text = TQString(), int index = -1, const KURL& baseDirectory = KURL());
+ Kate::View* loadItem(KileDocument::Type type, KileProjectItem *item, const TQString & text = TQString(), bool openProjectItemViews = true);
private:
- QPtrList<TextInfo> m_textInfoList;
+ TQPtrList<TextInfo> m_textInfoList;
KileInfo *m_ki;
- QPtrList<KileProject> m_projects;
+ TQPtrList<KileProject> m_projects;
KProgressDialog *m_kpd;
- void dontOpenWarning(KileProjectItem *item, const QString &action, const QString &filetype);
+ void dontOpenWarning(KileProjectItem *item, const TQString &action, const TQString &filetype);
void cleanupDocumentInfoForProjectItems(KileDocument::Info *info);
- QStringList autosaveWarnings;
+ TQStringList autosaveWarnings;
};
diff --git a/src/kile/kiledocumentinfo.cpp b/src/kile/kiledocumentinfo.cpp
index 79d6b16..e289d45 100644
--- a/src/kile/kiledocumentinfo.cpp
+++ b/src/kile/kiledocumentinfo.cpp
@@ -62,11 +62,11 @@
#include "kiledocumentinfo.h"
-#include <qfileinfo.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qregexp.h>
-#include <qdatetime.h>
+#include <tqfileinfo.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqregexp.h>
+#include <tqdatetime.h>
#include <kio/netaccess.h>
#include <kconfig.h>
@@ -86,8 +86,8 @@ namespace KileDocument
bool Info::containsInvalidCharacters(const KURL& url)
{
- QString filename = url.fileName();
- return filename.contains(" ") || filename.contains("~") || filename.contains("$") || filename.contains("#");
+ TQString filename = url.fileName();
+ return filename.tqcontains(" ") || filename.tqcontains("~") || filename.tqcontains("$") || filename.tqcontains("#");
}
KURL Info::repairInvalidCharacters(const KURL& url, bool checkForFileExistence /* = true */)
@@ -95,7 +95,7 @@ KURL Info::repairInvalidCharacters(const KURL& url, bool checkForFileExistence /
KURL ret(url);
do {
bool isOK;
- QString newURL = KInputDialog::getText(
+ TQString newURL = KInputDialog::getText(
i18n("Invalid Characters"),
i18n("The filename contains invalid characters ($~ #).<br>Please provide \
another one, or click \"Cancel\" to save anyway."),
@@ -115,10 +115,10 @@ KURL Info::renameIfExist(const KURL& url)
while ( KIO::NetAccess::exists(url, true, kapp->mainWidget()) ) // check for writing possibility
{
bool isOK;
- QString newURL = KInputDialog::getText(
+ TQString newURL = KInputDialog::getText(
i18n("File Already Exists"),
i18n("A file with filename '%1' already exists.<br>Please provide \
- another one, or click \"Cancel\" to overwrite it.").arg(ret.fileName()),
+ another one, or click \"Cancel\" to overwrite it.").tqarg(ret.fileName()),
ret.filename(),
&isOK);
if(!isOK)
@@ -132,8 +132,8 @@ KURL Info::repairExtension(const KURL& url, bool checkForFileExistence /* = true
{
KURL ret(url);
- QString filename = url.fileName();
- if(filename.contains(".") && filename[0] != '.') // There already is an extension
+ TQString filename = url.fileName();
+ if(filename.tqcontains(".") && filename[0] != '.') // There already is an extension
return ret;
if(KMessageBox::Yes == KMessageBox::questionYesNo(NULL,
@@ -212,9 +212,9 @@ Type Info::getType()
return Undefined;
}
-QString Info::getFileFilter() const
+TQString Info::getFileFilter() const
{
- return QString::null;
+ return TQString();
}
bool Info::isDocumentTypePromotionAllowed()
@@ -232,9 +232,9 @@ KURL Info::url()
return m_url;
}
-void Info::count(const QString line, long *stat)
+void Info::count(const TQString line, long *stat)
{
- QChar c;
+ TQChar c;
int state = stStandard;
bool word = false; // we are in a word
@@ -343,7 +343,7 @@ void Info::count(const QString line, long *stat)
break;
- case stComment : // if we get a selection the line possibly contains \n and so the comment is only valid till \n and not necessarily till line.length()
+ case stComment : // if we get a selection the line possibly tqcontains \n and so the comment is only valid till \n and not necessarily till line.length()
if ( c == '\n')
{
++stat[2]; // \n was counted as punctuation in the old implementation
@@ -359,12 +359,12 @@ void Info::count(const QString line, long *stat)
}
}
-QString Info::lastModifiedFile(const QStringList *list /* = 0L */)
+TQString Info::lastModifiedFile(const TQStringList *list /* = 0L */)
{
- KILE_DEBUG() << "==QString Info::lastModifiedFile()=====" << endl;
- QFileInfo fileinfo ( url().path() );
- QString basepath = fileinfo.dirPath(true), last = fileinfo.absFilePath();
- QDateTime time ( fileinfo.lastModified() );
+ KILE_DEBUG() << "==TQString Info::lastModifiedFile()=====" << endl;
+ TQFileInfo fileinfo ( url().path() );
+ TQString basepath = fileinfo.dirPath(true), last = fileinfo.absFilePath();
+ TQDateTime time ( fileinfo.lastModified() );
if ( list == 0L ) list = &m_deps;
@@ -395,7 +395,7 @@ void Info::updateStruct()
m_packages.clear();
m_newCommands.clear();
m_bIsRoot = false;
- m_preamble = QString::null;
+ m_preamble = TQString();
}
void Info::updateBibItems()
@@ -408,7 +408,7 @@ void Info::slotCompleted()
}
-TextInfo::TextInfo(Kate::Document *doc, Extensions *extensions, const QString& defaultHighlightMode) : m_doc(0), m_defaultHighlightMode(defaultHighlightMode)
+TextInfo::TextInfo(Kate::Document *doc, Extensions *extensions, const TQString& defaultHighlightMode) : m_doc(0), m_defaultHighlightMode(defaultHighlightMode)
{
setDoc(doc);
if (m_doc)
@@ -458,8 +458,8 @@ void TextInfo::setDoc(Kate::Document *doc)
{
m_doc = doc;
m_url = doc->url();
- connect(m_doc, SIGNAL(fileNameChanged()), this, SLOT(slotFileNameChanged()));
- connect(m_doc, SIGNAL(completed()), this, SLOT(slotCompleted()));
+ connect(m_doc, TQT_SIGNAL(fileNameChanged()), this, TQT_SLOT(slotFileNameChanged()));
+ connect(m_doc, TQT_SIGNAL(completed()), this, TQT_SLOT(slotCompleted()));
setHighlightMode(m_defaultHighlightMode);
installEventFilters();
}
@@ -484,7 +484,7 @@ const long* TextInfo::getStatistics()
return m_arStatistics;
}
-// FIXME for KDE 4.0, rearrange the hole docinfo layout to get rid of this hack
+// FIXME for KDE 4.0, rearrange the hole docinfo tqlayout to get rid of this hack
KURL TextInfo::url()
{
KURL url;
@@ -493,7 +493,7 @@ KURL TextInfo::url()
url = m_doc->url();
else
{
- QFileInfo info(m_url.path());
+ TQFileInfo info(m_url.path());
if(info.exists())
url = m_url;
else
@@ -513,7 +513,7 @@ bool TextInfo::isTextDocument()
return true;
}
-void TextInfo::setHighlightMode(const QString &highlight)
+void TextInfo::setHighlightMode(const TQString &highlight)
{
KILE_DEBUG() << "==Kile::setHighlightMode(" << m_doc->url() << "," << highlight << " )==================" << endl;
@@ -537,21 +537,21 @@ void TextInfo::setHighlightMode(const QString &highlight)
}
}
-void TextInfo::setDefaultHightlightMode(const QString& string)
+void TextInfo::setDefaultHightlightMode(const TQString& string)
{
m_defaultHighlightMode = string;
}
// match a { with the corresponding }
// pos is the position of the {
-QString TextInfo::matchBracket(QChar obracket, uint &l, uint &pos)
+TQString TextInfo::matchBracket(TQChar obracket, uint &l, uint &pos)
{
- QChar cbracket;
+ TQChar cbracket;
if ( obracket == '{' ) cbracket = '}';
if ( obracket == '[' ) cbracket = ']';
if ( obracket == '(' ) cbracket = ')';
- QString line, grab = "";
+ TQString line, grab = "";
int count=0, len;
++pos;
@@ -580,30 +580,30 @@ QString TextInfo::matchBracket(QChar obracket, uint &l, uint &pos)
pos=0;
}
- return QString::null;
+ return TQString();
}
-QString TextInfo::getTextline(uint line, TodoResult &todo)
+TQString TextInfo::getTextline(uint line, TodoResult &todo)
{
- static QRegExp::QRegExp reComments("[^\\\\](%.*$)");
+ static TQRegExp::TQRegExp reComments("[^\\\\](%.*$)");
todo.type = -1;
- QString s = m_doc->textLine(line);
+ TQString s = m_doc->textLine(line);
if ( ! s.isEmpty() )
{
// remove comment lines
if ( s[0] == '%' )
{
searchTodoComment(s,0,todo);
- s = QString::null;
+ s = TQString();
}
else
{
//remove escaped \ characters
- s.replace("\\\\", " ");
+ s.tqreplace("\\\\", " ");
//remove comments
- int pos = s.find(reComments);
+ int pos = s.tqfind(reComments);
if ( pos != -1 )
{
searchTodoComment(s,pos,todo);
@@ -614,11 +614,11 @@ QString TextInfo::getTextline(uint line, TodoResult &todo)
return s;
}
-void TextInfo::searchTodoComment(const QString &s, uint startpos, TodoResult &todo)
+void TextInfo::searchTodoComment(const TQString &s, uint startpos, TodoResult &todo)
{
- static QRegExp::QRegExp reTodoComment("\\b(TODO|FIXME)\\b(:|\\s)?\\s*(.*)");
+ static TQRegExp::TQRegExp reTodoComment("\\b(TODO|FIXME)\\b(:|\\s)?\\s*(.*)");
- if ( s.find(reTodoComment,startpos) != -1 )
+ if ( s.tqfind(reTodoComment,startpos) != -1 )
{
todo.type = ( reTodoComment.cap(1) == "TODO" ) ? KileStruct::ToDo : KileStruct::FixMe;
todo.colTag = reTodoComment.pos(1);
@@ -627,13 +627,13 @@ void TextInfo::searchTodoComment(const QString &s, uint startpos, TodoResult &to
}
}
-KTextEditor::View* TextInfo::createView(QWidget *parent, const char *name)
+KTextEditor::View* TextInfo::createView(TQWidget *tqparent, const char *name)
{
if(!m_doc)
{
return NULL;
}
- KTextEditor::View *view = m_doc->createView(parent, name);
+ KTextEditor::View *view = m_doc->createView(tqparent, name);
installEventFilters(view);
return view;
}
@@ -659,7 +659,7 @@ void TextInfo::installEventFilters()
{
return;
}
- QPtrList<KTextEditor::View> views = m_doc->views();
+ TQPtrList<KTextEditor::View> views = m_doc->views();
KTextEditor::View *view;
for(view = views.first(); view; view = views.next())
{
@@ -673,7 +673,7 @@ void TextInfo::removeInstalledEventFilters()
{
return;
}
- QPtrList<KTextEditor::View> views = m_doc->views();
+ TQPtrList<KTextEditor::View> views = m_doc->views();
KTextEditor::View *view;
for(view = views.first(); view; view = views.next())
{
@@ -682,7 +682,7 @@ void TextInfo::removeInstalledEventFilters()
}
-LaTeXInfo::LaTeXInfo (Kate::Document *doc, Extensions *extensions, LatexCommands *commands, const QObject* eventFilter) : TextInfo(doc, extensions, "LaTeX"), m_commands(commands), m_eventFilter(eventFilter)
+LaTeXInfo::LaTeXInfo (Kate::Document *doc, Extensions *extensions, LatexCommands *commands, const TQObject* eventFilter) : TextInfo(doc, extensions, "LaTeX"), m_commands(commands), m_eventFilter(eventFilter)
{
documentTypePromotionAllowed = false;
updateStructLevelInfo();
@@ -697,7 +697,7 @@ const long* LaTeXInfo::getStatistics()
/* [0] = #c in words, [1] = #c in latex commands and environments,
[2] = #c whitespace, [3] = #words, [4] = # latex_commands, [5] = latex_environments */
m_arStatistics[0]=m_arStatistics[1]=m_arStatistics[2]=m_arStatistics[3]=m_arStatistics[4]=m_arStatistics[5]=0;
- QString line;
+ TQString line;
if ( m_doc && m_doc->hasSelection() )
{
@@ -720,7 +720,7 @@ Type LaTeXInfo::getType()
return LaTeX;
}
-QString LaTeXInfo::getFileFilter() const
+TQString LaTeXInfo::getFileFilter() const
{
return m_extensions->latexDocumentFileFilter() + '\n' + m_extensions->latexPackageFileFilter();
}
@@ -759,7 +759,7 @@ void LaTeXInfo::updateStructLevelInfo() {
// bibitems
if ( m_showStructureBibitems )
{
- m_dictStructLevel["\\bibitem"]= KileStructData(KileStruct::NotSpecified, KileStruct::BibItem, QString::null, "bibs");
+ m_dictStructLevel["\\bibitem"]= KileStructData(KileStruct::NotSpecified, KileStruct::BibItem, TQString(), "bibs");
}
// graphics
@@ -790,13 +790,13 @@ void LaTeXInfo::updateStructLevelInfo() {
// add user defined commands
- QStringList list;
- QStringList::ConstIterator it;
+ TQStringList list;
+ TQStringList::ConstIterator it;
// labels, we also gather them
m_commands->commandList(list,KileDocument::CmdAttrLabel,false);
for ( it=list.begin(); it != list.end(); ++it )
- m_dictStructLevel[*it]= KileStructData(KileStruct::NotSpecified, KileStruct::Label, QString::null, "labels");
+ m_dictStructLevel[*it]= KileStructData(KileStruct::NotSpecified, KileStruct::Label, TQString(), "labels");
// input files
if ( m_showStructureInputFiles )
@@ -817,12 +817,12 @@ void LaTeXInfo::updateStructLevelInfo() {
void LaTeXInfo::installEventFilters(KTextEditor::View *view)
{
- view->focusProxy()->installEventFilter(m_eventFilter);
+ view->focusProxy()->installEventFilter(const_cast<TQObject*>(m_eventFilter));
}
void LaTeXInfo::removeInstalledEventFilters(KTextEditor::View *view)
{
- view->focusProxy()->removeEventFilter(m_eventFilter);
+ view->focusProxy()->removeEventFilter(const_cast<TQObject*>(m_eventFilter));
}
BracketResult LaTeXInfo::matchBracket(uint &l, uint &pos)
@@ -836,7 +836,7 @@ BracketResult LaTeXInfo::matchBracket(uint &l, uint &pos)
int p = 0;
while ( l < m_doc->numLines() )
{
- if ( (p = getTextline(l,todo).find('{', pos)) != -1 )
+ if ( (p = getTextline(l,todo).tqfind('{', pos)) != -1 )
{
pos = p;
break;
@@ -869,19 +869,19 @@ void LaTeXInfo::updateStruct()
Info::updateStruct();
- QMapConstIterator<QString,KileStructData> it;
- static QRegExp::QRegExp reCommand("(\\\\[a-zA-Z]+)\\s*\\*?\\s*(\\{|\\[)");
- static QRegExp::QRegExp reRoot("\\\\documentclass|\\\\documentstyle");
- static QRegExp::QRegExp reBD("\\\\begin\\s*\\{\\s*document\\s*\\}");
- static QRegExp::QRegExp reReNewCommand("\\\\renewcommand.*$");
- static QRegExp::QRegExp reNumOfParams("\\s*\\[([1-9]+)\\]");
- static QRegExp::QRegExp reNumOfOptParams("\\s*\\[([1-9]+)\\]\\s*\\[([^\\{]*)\\]"); // the quantifier * isn't used by mistake, because also emtpy optional brackets are correct.
+ TQMapConstIterator<TQString,KileStructData> it;
+ static TQRegExp::TQRegExp reCommand("(\\\\[a-zA-Z]+)\\s*\\*?\\s*(\\{|\\[)");
+ static TQRegExp::TQRegExp reRoot("\\\\documentclass|\\\\documentstyle");
+ static TQRegExp::TQRegExp reBD("\\\\begin\\s*\\{\\s*document\\s*\\}");
+ static TQRegExp::TQRegExp reReNewCommand("\\\\renewcommand.*$");
+ static TQRegExp::TQRegExp reNumOfParams("\\s*\\[([1-9]+)\\]");
+ static TQRegExp::TQRegExp reNumOfOptParams("\\s*\\[([1-9]+)\\]\\s*\\[([^\\{]*)\\]"); // the quantifier * isn't used by mistake, because also emtpy optional brackets are correct.
int teller=0, tagStart, bd = 0;
uint tagEnd, tagLine = 0, tagCol = 0;
uint tagStartLine = 0, tagStartCol = 0;
BracketResult result;
- QString m, s, shorthand;
+ TQString m, s, shorthand;
bool foundBD = false; // found \begin { document }
bool fire = true; //whether or not we should emit a foundItem signal
bool fireSuspended; // found an item, but it should not be fired (this time)
@@ -902,8 +902,8 @@ void LaTeXInfo::updateStruct()
s = getTextline(i,todo);
if ( todo.type!=-1 && m_showStructureTodo )
{
- QString folder = ( todo.type == KileStruct::ToDo ) ? "todo" : "fixme";
- emit( foundItem(todo.comment, i+1, todo.colComment, todo.type, KileStruct::Object, i+1, todo.colTag, QString::null, folder) );
+ TQString folder = ( todo.type == KileStruct::ToDo ) ? "todo" : "fixme";
+ emit( foundItem(todo.comment, i+1, todo.colComment, todo.type, KileStruct::Object, i+1, todo.colTag, TQString(), folder) );
}
@@ -911,12 +911,12 @@ void LaTeXInfo::updateStruct()
continue;
//ignore renewcommands
- s.replace(reReNewCommand, "");
+ s.tqreplace(reReNewCommand, "");
//find all commands in this line
while (tagStart != -1)
{
- if ( (!foundBD) && ( (bd = s.find(reBD, tagEnd)) != -1))
+ if ( (!foundBD) && ( (bd = s.tqfind(reBD, tagEnd)) != -1))
{
KILE_DEBUG() << "\tfound \\begin{document}" << endl;
foundBD = true;
@@ -924,7 +924,7 @@ void LaTeXInfo::updateStruct()
else m_preamble = m_doc->text(0, 0, i, bd);
}
- if ((!foundBD) && (s.find(reRoot, tagEnd) != -1))
+ if ((!foundBD) && (s.tqfind(reRoot, tagEnd) != -1))
{
KILE_DEBUG() << "\tsetting m_bIsRoot to true" << endl;
tagEnd += reRoot.cap(0).length();
@@ -932,15 +932,15 @@ void LaTeXInfo::updateStruct()
}
tagStart = reCommand.search(s,tagEnd);
- m=QString::null;
- shorthand = QString::null;
+ m=TQString();
+ shorthand = TQString();
if (tagStart != -1)
{
tagEnd = tagStart + reCommand.cap(0).length()-1;
//look up the command in the dictionary
- it = m_dictStructLevel.find(reCommand.cap(1));
+ it = m_dictStructLevel.tqfind(reCommand.cap(1));
//if it is was a structure element, find the title (or label)
if (it != m_dictStructLevel.end())
@@ -987,17 +987,17 @@ void LaTeXInfo::updateStruct()
{
if ( m=="figure" || m=="figure*" || m=="table" )
{
- it = m_dictStructLevel.find("\\begin{" + m +'}');
+ it = m_dictStructLevel.tqfind("\\begin{" + m +'}');
}
else if ( m == "frame" )
{
- it = m_dictStructLevel.find("\\begin{frame}");
+ it = m_dictStructLevel.tqfind("\\begin{frame}");
m = i18n("Frame");
}
else if ( m=="block" || m=="exampleblock" || m=="alertblock")
{
- const QString untitledBlockDisplayName = i18n("Untitled Block");
- it = m_dictStructLevel.find("\\begin{block}");
+ const TQString untitledBlockDisplayName = i18n("Untitled Block");
+ it = m_dictStructLevel.tqfind("\\begin{block}");
if ( s.at(tagEnd+1) == '{' )
{
tagEnd++;
@@ -1019,11 +1019,11 @@ void LaTeXInfo::updateStruct()
{
if ( m=="figure" || m== "figure*" || m=="table")
{
- it = m_dictStructLevel.find("\\end{float}");
+ it = m_dictStructLevel.tqfind("\\end{float}");
}
else if ( m == "frame" )
{
- it = m_dictStructLevel.find("\\end{frame}");
+ it = m_dictStructLevel.tqfind("\\end{frame}");
}
else
fireSuspended = true; // only floats, no other environments
@@ -1062,7 +1062,7 @@ void LaTeXInfo::updateStruct()
// if an extension exists. If not the default extension is added
// ( LaTeX reference says that this is '.tex'). This assures that
// all files, which are listed in the structure view, have an extension.
- QString ext = QFileInfo(m).extension();
+ TQString ext = TQFileInfo(m).extension();
if ( ext.isEmpty() )
m += m_extensions->latexDocumentDefault();
m_deps.append(m);
@@ -1073,11 +1073,11 @@ void LaTeXInfo::updateStruct()
{
KILE_DEBUG() << "===TeXInfo::updateStruct()===appending Bibiliograph file(s) " << m << endl;
- QStringList bibs = QStringList::split(",", m);
- QString biblio;
+ TQStringList bibs = TQStringList::split(",", m);
+ TQString biblio;
// assure that all files have an extension
- QString bibext = m_extensions->bibtexDefault();
+ TQString bibext = m_extensions->bibtexDefault();
int bibextlen = bibext.length();
uint cumlen = 0;
@@ -1113,11 +1113,11 @@ void LaTeXInfo::updateStruct()
// update the package list
else if ( (*it).type == KileStruct::Package )
{
- QStringList pckgs = QStringList::split(",", m);
+ TQStringList pckgs = TQStringList::split(",", m);
uint cumlen = 0;
for (uint p = 0; p < pckgs.count(); ++p)
{
- QString package = pckgs[p].stripWhiteSpace();
+ TQString package = pckgs[p].stripWhiteSpace();
if ( ! package.isEmpty() ) {
m_packages.append(package);
// hidden, so emit is useless
@@ -1131,17 +1131,17 @@ void LaTeXInfo::updateStruct()
// newcommand found, add it to the newCommands list
else if ( (*it).type & ( KileStruct::NewCommand | KileStruct::NewEnvironment ) )
{
- QString optArg, mandArgs;
+ TQString optArg, mandArgs;
//find how many parameters this command takes
- if ( s.find(reNumOfParams, tagEnd + 1) != -1 )
+ if ( s.tqfind(reNumOfParams, tagEnd + 1) != -1 )
{
bool ok;
int noo = reNumOfParams.cap(1).toInt(&ok);
if ( ok )
{
- if(s.find(reNumOfOptParams, tagEnd + 1) != -1)
+ if(s.tqfind(reNumOfOptParams, tagEnd + 1) != -1)
{
KILE_DEBUG() << "Opt param is " << reNumOfOptParams.cap(2) << "%EOL" << endl;
noo--; // if we have an opt argument, we have one mandatory argument less, and noo=0 can't occur because then latex complains (and we don't macht them with reNumOfParams either)
@@ -1158,7 +1158,7 @@ void LaTeXInfo::updateStruct()
{
if( (*it).type == KileStruct::NewEnvironment)
{
- m_newCommands.append(QString("\\begin{%1}%2%3").arg(m).arg(optArg).arg(mandArgs));
+ m_newCommands.append(TQString("\\begin{%1}%2%3").tqarg(m).tqarg(optArg).tqarg(mandArgs));
}
else
m_newCommands.append(m + optArg + mandArgs);
@@ -1166,8 +1166,8 @@ void LaTeXInfo::updateStruct()
}
if( (*it).type == KileStruct::NewEnvironment)
{
- m_newCommands.append(QString("\\begin{%1}%3").arg(m).arg(mandArgs));
- m_newCommands.append(QString("\\end{%1}").arg(m));
+ m_newCommands.append(TQString("\\begin{%1}%3").tqarg(m).tqarg(mandArgs));
+ m_newCommands.append(TQString("\\end{%1}").tqarg(m));
}
else
m_newCommands.append(m + mandArgs);
@@ -1223,16 +1223,16 @@ void BibInfo::updateStruct()
KILE_DEBUG() << "==void BibInfo::updateStruct()========" << endl;
- static QRegExp::QRegExp reItem("^(\\s*)@([a-zA-Z]+)");
- static QRegExp::QRegExp reSpecial("string|preamble|comment");
+ static TQRegExp::TQRegExp reItem("^(\\s*)@([a-zA-Z]+)");
+ static TQRegExp::TQRegExp reSpecial("string|preamble|comment");
- QString s, key;
+ TQString s, key;
int col = 0, startcol, startline = 0;
for(uint i = 0; i < m_doc->numLines(); ++i)
{
s = m_doc->textLine(i);
- if ( (s.find(reItem) != -1) && !reSpecial.exactMatch(reItem.cap(2).lower()) )
+ if ( (s.tqfind(reItem) != -1) && !reSpecial.exactMatch(reItem.cap(2).lower()) )
{
KILE_DEBUG() << "found: " << reItem.cap(2) << endl;
//start looking for key
@@ -1291,7 +1291,7 @@ Type BibInfo::getType()
return BibTeX;
}
-QString BibInfo::getFileFilter() const
+TQString BibInfo::getFileFilter() const
{
return m_extensions->bibtexFileFilter();
}
@@ -1315,7 +1315,7 @@ Type ScriptInfo::getType()
return Script;
}
-QString ScriptInfo::getFileFilter() const
+TQString ScriptInfo::getFileFilter() const
{
return m_extensions->scriptFileFilter();
}
diff --git a/src/kile/kiledocumentinfo.h b/src/kile/kiledocumentinfo.h
index fc534ef..9cc563f 100644
--- a/src/kile/kiledocumentinfo.h
+++ b/src/kile/kiledocumentinfo.h
@@ -52,7 +52,7 @@ namespace KileStruct
ToDo = 0x100000, FixMe = 0x200000, NewEnvironment = 0x400000
};
- //Different levels (in the parent-child hierarchy) in the structure view
+ //Different levels (in the tqparent-child hierarchy) in the structure view
enum
{
Hidden = -4, NotSpecified = -3, Object = -2, File = -1
@@ -61,19 +61,19 @@ namespace KileStruct
/**
* A convenience class to store info about how LaTeX elements should appear in the
- * structure view. A QMap<QString, KileStructData> should be created, so that the
+ * structure view. A TQMap<TQString, KileStructData> should be created, so that the
* actual LaTeX elements can be mapped to this class.
**/
class KileStructData
{
public:
- KileStructData(int lvl = 0, int tp = KileStruct::None, QString px = QString::null, QString fldr = "root" ) : level(lvl), type(tp), pix(px), folder(fldr) {}
+ KileStructData(int lvl = 0, int tp = KileStruct::None, TQString px = TQString(), TQString fldr = "root" ) : level(lvl), type(tp), pix(px), folder(fldr) {}
/** At which level the element should be visible **/
int level;
/** The type of element (see @ref KileStruct) **/
int type;
/** The name of the icon that goes with this element. The icon is located using SmallIcon(pix). **/
- QString pix, folder;
+ TQString pix, folder;
};
/**
@@ -86,8 +86,8 @@ namespace KileDocument
struct BracketResult
{
- BracketResult() : option(QString::null), value(QString::null), line(0), col(0) {}
- QString option, value;
+ BracketResult() : option(TQString()), value(TQString()), line(0), col(0) {}
+ TQString option, value;
int line, col;
};
@@ -96,12 +96,13 @@ struct TodoResult
int type;
uint colTag;
uint colComment;
- QString comment;
+ TQString comment;
};
-class Info : public QObject
+class Info : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
static bool containsInvalidCharacters(const KURL&);
@@ -114,14 +115,14 @@ public:
Info();
~Info();
- const QStringList* labels() const{ return &m_labels; }
- const QStringList* bibItems() const { return &m_bibItems; }
- const QStringList* dependencies() const {return &m_deps; }
- const QStringList* bibliographies() const { return &m_bibliography; }
- const QStringList* packages() const { return &m_packages; }
- const QStringList* newCommands() const { return &m_newCommands; }
+ const TQStringList* labels() const{ return &m_labels; }
+ const TQStringList* bibItems() const { return &m_bibItems; }
+ const TQStringList* dependencies() const {return &m_deps; }
+ const TQStringList* bibliographies() const { return &m_bibliography; }
+ const TQStringList* packages() const { return &m_packages; }
+ const TQStringList* newCommands() const { return &m_newCommands; }
- QString lastModifiedFile(const QStringList *list = 0L);
+ TQString lastModifiedFile(const TQStringList *list = 0L);
bool openStructureLabels() { return m_openStructureLabels; }
bool openStructureReferences() { return m_openStructureReferences; }
@@ -131,7 +132,7 @@ public:
bool showStructureLabels() { return m_showStructureLabels; }
- const QString & preamble() const { return m_preamble; }
+ const TQString & preamble() const { return m_preamble; }
virtual bool isLaTeXRoot() { return m_bIsRoot; }
@@ -148,7 +149,7 @@ public:
/**
* Returns a file filter suitable for loading and saving files of this class' type.
**/
- virtual QString getFileFilter() const;
+ virtual TQString getFileFilter() const;
virtual bool isDocumentTypePromotionAllowed();
void setDocumentTypePromotionAllowed(bool b);
@@ -164,8 +165,8 @@ signals:
void urlChanged(KileDocument::Info* info, const KURL& url);
void isrootChanged(bool);
- void foundItem(const QString &title, uint line, uint column, int type, int level, uint startline, uint startcol,
- const QString & pix, const QString & folder);
+ void foundItem(const TQString &title, uint line, uint column, int type, int level, uint startline, uint startcol,
+ const TQString & pix, const TQString & folder);
void doneUpdating();
void depChanged();
void completed(KileDocument::Info* info);
@@ -174,7 +175,7 @@ protected slots:
void slotCompleted();
protected:
- void count(const QString line, long *stat);
+ void count(const TQString line, long *stat);
protected:
enum State
@@ -185,14 +186,14 @@ protected:
protected:
bool m_bIsRoot;
- QStringList m_labels;
- QStringList m_bibItems;
- QStringList m_deps, m_depsPrev;
- QStringList m_bibliography;
- QStringList m_packages;
- QStringList m_newCommands;
- QString m_preamble;
- QMap<QString,KileStructData> m_dictStructLevel;
+ TQStringList m_labels;
+ TQStringList m_bibItems;
+ TQStringList m_deps, m_depsPrev;
+ TQStringList m_bibliography;
+ TQStringList m_packages;
+ TQStringList m_newCommands;
+ TQString m_preamble;
+ TQMap<TQString,KileStructData> m_dictStructLevel;
KURL m_url;
KConfig *m_config;
bool m_showStructureLabels;
@@ -219,12 +220,13 @@ protected:
class TextInfo : public Info
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* @param defaultHighlightMode the highlight mode that will be set automatically
* once a new document is installed
**/
- TextInfo(Kate::Document *doc, Extensions *extensions, const QString& defaultHighlightMode = QString::null);
+ TextInfo(Kate::Document *doc, Extensions *extensions, const TQString& defaultHighlightMode = TQString());
virtual ~TextInfo();
/**
@@ -252,9 +254,9 @@ public:
bool isTextDocument();
- void setHighlightMode(const QString & highlight = QString::null);
+ void setHighlightMode(const TQString & highlight = TQString());
- void setDefaultHightlightMode(const QString& string);
+ void setDefaultHightlightMode(const TQString& string);
/**
* "Overridden" method that installs custom event filters by using the "installEventFilters"
@@ -262,7 +264,7 @@ public:
* @warning Only this method should be used to create new views for text documents !
* @return NULL if no document is set (m_doc == NULL)
**/
- KTextEditor::View* createView(QWidget *parent, const char *name=0);
+ KTextEditor::View* createView(TQWidget *tqparent, const char *name=0);
protected slots:
void slotFileNameChanged();
@@ -270,11 +272,11 @@ protected slots:
protected:
Kate::Document *m_doc;
long *m_arStatistics;
- QString m_defaultHighlightMode;
+ TQString m_defaultHighlightMode;
- QString matchBracket(QChar c, uint &, uint &);
- QString getTextline(uint line, TodoResult &todo);
- void searchTodoComment(const QString &s, uint startpos, TodoResult &todo);
+ TQString matchBracket(TQChar c, uint &, uint &);
+ TQString getTextline(uint line, TodoResult &todo);
+ void searchTodoComment(const TQString &s, uint startpos, TodoResult &todo);
/**
* Installs an event filter on a view. Subclasses can override this method to
@@ -312,26 +314,27 @@ protected:
class LaTeXInfo : public TextInfo
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* @param eventFilter the event filter that will be installed on managed documents
**/
- LaTeXInfo(Kate::Document *doc, Extensions *extensions, LatexCommands *commands, const QObject* eventFilter);
+ LaTeXInfo(Kate::Document *doc, Extensions *extensions, LatexCommands *commands, const TQObject* eventFilter);
virtual ~LaTeXInfo();
const long* getStatistics();
virtual Type getType();
- virtual QString getFileFilter() const;
+ virtual TQString getFileFilter() const;
public slots:
virtual void updateStruct();
protected:
LatexCommands *m_commands;
- const QObject *m_eventFilter;
+ const TQObject *m_eventFilter;
virtual void updateStructLevelInfo();
virtual void checkChangedDeps();
@@ -354,6 +357,7 @@ private:
class BibInfo : public TextInfo
{
Q_OBJECT
+ TQ_OBJECT
public:
BibInfo (Kate::Document *doc, Extensions *extensions, LatexCommands* commands);
@@ -363,7 +367,7 @@ public:
virtual Type getType();
- virtual QString getFileFilter() const;
+ virtual TQString getFileFilter() const;
public slots:
virtual void updateStruct();
@@ -372,6 +376,7 @@ public slots:
class ScriptInfo : public TextInfo
{
Q_OBJECT
+ TQ_OBJECT
public:
ScriptInfo(Kate::Document *doc, Extensions *extensions);
@@ -381,7 +386,7 @@ public:
virtual Type getType();
- virtual QString getFileFilter() const;
+ virtual TQString getFileFilter() const;
};
}
diff --git a/src/kile/kileedit.cpp b/src/kile/kileedit.cpp
index 44c0ba4..c56d7fb 100644
--- a/src/kile/kileedit.cpp
+++ b/src/kile/kileedit.cpp
@@ -16,10 +16,10 @@
#include "kileedit.h"
-#include <qfileinfo.h>
-#include <qvaluestack.h>
-#include <qclipboard.h>
-#include <qapplication.h>
+#include <tqfileinfo.h>
+#include <tqvaluestack.h>
+#include <tqclipboard.h>
+#include <tqapplication.h>
#include <kate/view.h>
#include <kate/document.h>
@@ -82,7 +82,7 @@ void EditorExtension::readConfig(void)
initDoubleQuotes();
// calculate indent for autoindent of environments
- m_envAutoIndent = QString::null;
+ m_envAutoIndent = TQString();
if ( KileConfig::envIndentation() )
{
if ( KileConfig::envIndentSpaces() )
@@ -108,8 +108,8 @@ void EditorExtension::insertTag(const KileAction::TagData& data, Kate::View *vie
bool wrap = ( (!data.tagEnd.isNull()) && doc->hasSelection());
//%C before or after the selection
- bool before = data.tagBegin.contains("%C");
- bool after = data.tagEnd.contains("%C");
+ bool before = data.tagBegin.tqcontains("%C");
+ bool after = data.tagEnd.tqcontains("%C");
//save current cursor position
int para=view->cursorLine();
@@ -123,8 +123,8 @@ void EditorExtension::insertTag(const KileAction::TagData& data, Kate::View *vie
int dxIndentEnv = 0;
// environment tag
- bool envtag = data.tagBegin.contains("%E") || data.tagEnd.contains("%E");
- QString whitespace = getWhiteSpace( doc->textLine(para).left(index) );
+ bool envtag = data.tagBegin.tqcontains("%E") || data.tagEnd.tqcontains("%E");
+ TQString whitespace = getWhiteSpace( doc->textLine(para).left(index) );
//if there is a selection act as if cursor is at the beginning of selection
if (wrap)
@@ -134,18 +134,18 @@ void EditorExtension::insertTag(const KileAction::TagData& data, Kate::View *vie
para_end = doc->selEndLine();
}
- QString ins = data.tagBegin;
- QString tagEnd = data.tagEnd;
+ TQString ins = data.tagBegin;
+ TQString tagEnd = data.tagEnd;
//start an atomic editing sequence
KTextEditor::EditInterfaceExt *editInterfaceExt = KTextEditor::editInterfaceExt( doc );
if ( editInterfaceExt ) editInterfaceExt->editBegin();
//cut the selected text
- QString trailing;
+ TQString trailing;
if (wrap)
{
- QString sel = doc->selection();
+ TQString sel = doc->selection();
doc->removeSelectedText();
// no autoindentation of environments, when text is selected
@@ -157,7 +157,7 @@ void EditorExtension::insertTag(const KileAction::TagData& data, Kate::View *vie
// strip one of two consecutive line ends
int len = sel.length();
- if ( tagEnd.at(0)=='\n' && len>0 && sel.find('\n',-1)==len-1 )
+ if ( tagEnd.at(0)=='\n' && len>0 && sel.tqfind('\n',-1)==len-1 )
sel.truncate( len-1 );
// now add the selection
@@ -172,19 +172,19 @@ void EditorExtension::insertTag(const KileAction::TagData& data, Kate::View *vie
}
else if ( envtag )
{
- ins.replace("%E",whitespace+m_envAutoIndent);
- tagEnd.replace("%E",whitespace+m_envAutoIndent);
+ ins.tqreplace("%E",whitespace+m_envAutoIndent);
+ tagEnd.tqreplace("%E",whitespace+m_envAutoIndent);
if ( data.dy > 0 )
dxIndentEnv = whitespace.length() + m_envAutoIndent.length();
}
- tagEnd.replace("\\end{",whitespace+"\\end{");
+ tagEnd.tqreplace("\\end{",whitespace+"\\end{");
ins += tagEnd + trailing;
//do some replacements
- QFileInfo fi( doc->url().path());
- ins.replace("%S", fi.baseName(true));
- ins.replace("%B", s_bullet);
+ TQFileInfo fi( doc->url().path());
+ ins.tqreplace("%S", fi.baseName(true));
+ ins.tqreplace("%B", s_bullet);
//insert first part of tag at cursor position
doc->insertText(para,index,ins);
@@ -192,13 +192,13 @@ void EditorExtension::insertTag(const KileAction::TagData& data, Kate::View *vie
//move cursor to the new position
if ( before || after )
{
- int n = data.tagBegin.contains("\n")+ data.tagEnd.contains("\n");
+ int n = data.tagBegin.tqcontains("\n")+ data.tagEnd.tqcontains("\n");
if (wrap) n += para_end > para ? para_end-para : para-para_end;
for (int line = para_begin; line <= para_begin+n; ++line)
{
- if (doc->textLine(line).contains("%C"))
+ if (doc->textLine(line).tqcontains("%C"))
{
- int i=doc->textLine(line).find("%C");
+ int i=doc->textLine(line).tqfind("%C");
para_cursor = line; index_cursor = i;
doc->removeText(line,i,line,i+2);
break;
@@ -303,7 +303,7 @@ void EditorExtension::closeEnvironment(Kate::View *view)
if ( !view ) return;
uint row,col,currentRow,currentCol;
- QString name;
+ TQString name;
view->cursorPositionReal(&currentRow,&currentCol);
if ( findOpenedEnvironment(row,col,name,view) )
@@ -323,7 +323,7 @@ void EditorExtension::closeAllEnvironments(Kate::View *view)
view = determineView(view);
if ( !view ) return;
- QStringList envlist = findOpenedEnvironmentList(view,true);
+ TQStringList envlist = findOpenedEnvironmentList(view,true);
if ( envlist.count() == 0 )
return;
@@ -340,9 +340,9 @@ void EditorExtension::closeAllEnvironments(Kate::View *view)
}
bool ok1,ok2;
- for ( QStringList::Iterator it=envlist.begin(); it!=envlist.end(); ++it )
+ for ( TQStringList::Iterator it=envlist.begin(); it!=envlist.end(); ++it )
{
- QStringList entry = QStringList::split(',',*it);
+ TQStringList entry = TQStringList::split(',',*it);
if ( entry[0] == "document" )
break;
@@ -354,11 +354,11 @@ void EditorExtension::closeAllEnvironments(Kate::View *view)
outputCol = currentCol;
if ( indent )
{
- QString whitespace = getWhiteSpace( doc->textLine(row).left(col) );
+ TQString whitespace = getWhiteSpace( doc->textLine(row).left(col) );
doc->insertText(currentRow,outputCol,whitespace);
outputCol += whitespace.length();
}
- QString endtag = ( entry[0] == "\\[" ) ? "\\]\n" : "\\end{"+entry[0]+"}\n";
+ TQString endtag = ( entry[0] == "\\[" ) ? "\\]\n" : "\\end{"+entry[0]+"}\n";
doc->insertText(currentRow,outputCol,endtag);
currentRow++;
}
@@ -400,7 +400,7 @@ bool EditorExtension::hasMathgroup(Kate::View *view)
return getMathgroup(view,row1,col1,row2,col2);
}
-QString EditorExtension::getMathgroupText(uint &row, uint &col, Kate::View *view)
+TQString EditorExtension::getMathgroupText(uint &row, uint &col, Kate::View *view)
{
uint row1,col1,row2,col2;
@@ -412,13 +412,13 @@ QString EditorExtension::getMathgroupText(uint &row, uint &col, Kate::View *view
return view->getDoc()->text(row1,col1,row2,col2);
}
else
- return QString::null;
+ return TQString();
}
bool EditorExtension::getMathgroup(Kate::View *view, uint &row1, uint &col1, uint &row2, uint &col2)
{
- QRegExp reg( QString("\\$")
+ TQRegExp reg( TQString("\\$")
+ "|\\\\begin\\s*\\{([A-Za-z]+\\*?)\\}"
+ "|\\\\end\\s*\\{([A-Za-z]+\\*?)\\}"
+ "|\\\\\\[|\\\\\\]"
@@ -431,10 +431,10 @@ bool EditorExtension::getMathgroup(Kate::View *view, uint &row1, uint &col1, uin
Kate::Document *doc = view->getDoc();
view->cursorPositionReal(&row,&col);
- QString textline = getTextLineReal(doc,row);
+ TQString textline = getTextLineReal(doc,row);
// check for '\ensuremath{...}'
- QString word;
+ TQString word;
uint x1,x2;
if ( getCurrentWord(doc,row,col,smTex,word,x1,x2) && word=="\\ensuremath" )
view->setCursorPositionReal(row,x2);
@@ -442,7 +442,7 @@ bool EditorExtension::getMathgroup(Kate::View *view, uint &row1, uint &col1, uin
BracketData open,close;
if ( getTexgroup(false,open,close,view) )
{
- QString s = getTextLineReal(doc,open.row);
+ TQString s = getTextLineReal(doc,open.row);
if ( open.col>=11 && s.mid(open.col-11,11)=="\\ensuremath" )
{
view->setCursorPositionReal(row,col);
@@ -578,14 +578,14 @@ bool EditorExtension::checkMathtags(const MathData &begin,const MathData &end)
bool EditorExtension::isOpeningMathTagPosition(Kate::Document *doc, uint row, uint col, MathData &mathdata)
{
- QString textline = getTextLineReal(doc,row);
+ TQString textline = getTextLineReal(doc,row);
- QRegExp reg("\\\\begin\\s*\\{([A-Za-z]+\\*?)\\}|\\\\\\[|\\\\\\(");
+ TQRegExp reg("\\\\begin\\s*\\{([A-Za-z]+\\*?)\\}|\\\\\\[|\\\\\\(");
if ( (int)col != reg.search(textline,col) )
return false;
- QChar id = reg.cap(0)[1];
- QString envname = reg.cap(1);
+ TQChar id = reg.cap(0)[1];
+ TQString envname = reg.cap(1);
mathdata.row = row;
mathdata.col = col;
@@ -609,15 +609,15 @@ bool EditorExtension::isOpeningMathTagPosition(Kate::Document *doc, uint row, ui
bool EditorExtension::isClosingMathTagPosition(Kate::Document *doc, uint row, uint col,MathData &mathdata)
{
- QString textline = doc->textLine(row);
+ TQString textline = doc->textLine(row);
- QRegExp reg("\\\\end\\s*\\{([A-Za-z]+\\*?)\\}|\\\\\\]|\\\\\\)");
+ TQRegExp reg("\\\\end\\s*\\{([A-Za-z]+\\*?)\\}|\\\\\\]|\\\\\\)");
int pos = reg.searchRev(textline,col);
if ( pos<0 || (int)col>pos+reg.matchedLength() )
return false;
- QChar id = reg.cap(0)[1];
- QString envname = reg.cap(1);
+ TQChar id = reg.cap(0)[1];
+ TQString envname = reg.cap(1);
mathdata.row = row;
mathdata.col = pos;
@@ -639,10 +639,10 @@ bool EditorExtension::isClosingMathTagPosition(Kate::Document *doc, uint row, ui
return true;
}
-bool EditorExtension::findOpenMathTag(Kate::Document *doc, uint row, uint col, QRegExp &reg, MathData &mathdata)
+bool EditorExtension::findOpenMathTag(Kate::Document *doc, uint row, uint col, TQRegExp &reg, MathData &mathdata)
{
uint lastrow,lastcol;
- QString mathname;
+ TQString mathname;
bool foundDollar= false;
uint numDollar = 0;
@@ -650,7 +650,7 @@ bool EditorExtension::findOpenMathTag(Kate::Document *doc, uint row, uint col, Q
KTextEditor::SearchInterface *iface;
iface = dynamic_cast<KTextEditor::SearchInterface *>(doc);
- QString textline = getTextLineReal(doc,row);
+ TQString textline = getTextLineReal(doc,row);
int column = (int)col;
bool continueSearch = true;
@@ -703,7 +703,7 @@ bool EditorExtension::findOpenMathTag(Kate::Document *doc, uint row, uint col, Q
else if ( mathname=="\\b" )
{
// save name of environment
- QString envname = reg.cap(1);
+ TQString envname = reg.cap(1);
// if we found the opening tag of a math env
if ( m_latexCommands->isMathEnv(envname) || envname=="math" )
@@ -738,7 +738,7 @@ bool EditorExtension::findOpenMathTag(Kate::Document *doc, uint row, uint col, Q
}
else if ( mathname == "\\e" )
{
- QString envname = reg.cap(2);
+ TQString envname = reg.cap(2);
// if we found the closing tag of a math env
if ( m_latexCommands->isMathEnv(envname) || envname=="math" )
@@ -806,7 +806,7 @@ bool EditorExtension::findOpenMathTag(Kate::Document *doc, uint row, uint col, Q
return true;
}
-bool EditorExtension::findCloseMathTag(Kate::Document *doc, uint row, uint col, QRegExp &reg, MathData &mathdata)
+bool EditorExtension::findCloseMathTag(Kate::Document *doc, uint row, uint col, TQRegExp &reg, MathData &mathdata)
{
KTextEditor::SearchInterface *iface;
iface = dynamic_cast<KTextEditor::SearchInterface *>(doc);
@@ -818,7 +818,7 @@ bool EditorExtension::findCloseMathTag(Kate::Document *doc, uint row, uint col,
// and escaped chars like backslash and dollar in '\\' and '\$'
if ( isValidBackslash(doc,rowFound,colFound) )
{
- QString mathname = reg.cap(0).left(2);
+ TQString mathname = reg.cap(0).left(2);
// always remember behind the last match
mathdata.row = rowFound;
@@ -847,7 +847,7 @@ bool EditorExtension::findCloseMathTag(Kate::Document *doc, uint row, uint col,
}
else if ( mathname=="\\b" )
{
- QString envname = reg.cap(1);
+ TQString envname = reg.cap(1);
if ( ! (m_latexCommands->isMathEnv(envname) || envname=="math") )
{
@@ -864,7 +864,7 @@ bool EditorExtension::findCloseMathTag(Kate::Document *doc, uint row, uint col,
}
else if ( mathname=="\\e" )
{
- QString envname = reg.cap(2);
+ TQString envname = reg.cap(2);
if ( ! (m_latexCommands->isMathEnv(envname) || envname=="math") )
{
//KILE_DEBUG() << "error: only math env are allowed in mathmode (found end tag)" << endl;
@@ -920,7 +920,7 @@ void EditorExtension::insertIntelligentNewline(Kate::View *view)
return;
uint row,col;
- QString name;
+ TQString name;
view->cursorPositionReal(&row,&col);
@@ -951,7 +951,7 @@ void EditorExtension::insertIntelligentNewline(Kate::View *view)
view->keyReturn();
}
-bool EditorExtension::findOpenedEnvironment(uint &row,uint &col, QString &envname, Kate::View *view)
+bool EditorExtension::findOpenedEnvironment(uint &row,uint &col, TQString &envname, Kate::View *view)
{
view = determineView(view);
if ( !view ) return false;
@@ -989,9 +989,9 @@ bool EditorExtension::findOpenedEnvironment(uint &row,uint &col, QString &envnam
return false;
}
-QStringList EditorExtension::findOpenedEnvironmentList(Kate::View *view, bool position)
+TQStringList EditorExtension::findOpenedEnvironmentList(Kate::View *view, bool position)
{
- QStringList envlist;
+ TQStringList envlist;
view = determineView(view);
if ( view )
@@ -1025,7 +1025,7 @@ QStringList EditorExtension::findOpenedEnvironmentList(Kate::View *view, bool po
col = env.col;
if ( position )
- envlist << env.name + QString(",%1,%2").arg(row).arg(col);
+ envlist << env.name + TQString(",%1,%2").tqarg(row).tqarg(col);
else
envlist << env.name;
@@ -1118,10 +1118,10 @@ bool EditorExtension::getEnvironment(bool inside, EnvData &envbegin, EnvData &en
// determine text, startrow and startcol of current environment
-QString EditorExtension::getEnvironmentText(uint &row, uint &col, QString &name, Kate::View *view)
+TQString EditorExtension::getEnvironmentText(uint &row, uint &col, TQString &name, Kate::View *view)
{
view = determineView(view);
- if ( !view ) return QString::null;
+ if ( !view ) return TQString();
EnvData envbegin,envend;
@@ -1134,7 +1134,7 @@ QString EditorExtension::getEnvironmentText(uint &row, uint &col, QString &name,
}
else
{
- return QString::null;
+ return TQString();
}
}
@@ -1332,7 +1332,7 @@ bool EditorExtension::findEnvironmentTag(Kate::Document *doc, uint row, uint col
bool EditorExtension::isEnvironmentPosition(Kate::Document *doc, uint row, uint col, EnvData &env)
{
// get real textline without comments, quoted characters and pairs of backslashes
- QString textline = getTextLineReal(doc,row);
+ TQString textline = getTextLineReal(doc,row);
if ( col > textline.length() )
return false;
@@ -1348,13 +1348,13 @@ bool EditorExtension::isEnvironmentPosition(Kate::Document *doc, uint row, uint
int startcol = ( textline[col] == '\\' ) ? col - 1 : col;
if ( startcol >= 1 )
{
- int pos = textline.findRev(m_reg,startcol);
+ int pos = textline.tqfindRev(m_reg,startcol);
env.len = m_reg.matchedLength();
if ( pos!=-1 && (uint)pos<col && col<=(uint)pos+env.len )
{
env.row = row;
env.col = pos;
- QChar ch = textline.at(pos+1);
+ TQChar ch = textline.at(pos+1);
if ( ch=='b' || ch=='e' )
{
env.tag = ( ch == 'b' ) ? EnvBegin : EnvEnd;
@@ -1370,17 +1370,17 @@ bool EditorExtension::isEnvironmentPosition(Kate::Document *doc, uint row, uint
if ( env.cpos == EnvInside )
return true;
left = true;
- //KILE_DEBUG() << " is - found left: pos=" << pos << " " << env.name << " " << QString(textline.at(pos+1)) << endl;
+ //KILE_DEBUG() << " is - found left: pos=" << pos << " " << env.name << " " << TQString(textline.at(pos+1)) << endl;
}
}
// check if there is a match in this line from the current position to the right
- if ( textline[col]=='\\' && col==(uint)textline.find(m_reg,col) )
+ if ( textline[col]=='\\' && col==(uint)textline.tqfind(m_reg,col) )
{
envright.row = row;
envright.col = col;
envright.len = m_reg.matchedLength();
- QChar ch = textline.at(col+1);
+ TQChar ch = textline.at(col+1);
if ( ch=='b' || ch=='e' ) // found "\begin" or "\end"
{
envright.tag = ( ch == 'b' ) ? EnvBegin : EnvEnd;
@@ -1393,7 +1393,7 @@ bool EditorExtension::isEnvironmentPosition(Kate::Document *doc, uint row, uint
}
envright.cpos = EnvLeft;
right = true;
- //KILE_DEBUG() << " is - found right: pos=" <<col << " " << envright.name << " " << QString(textline.at(col+1)) << endl;
+ //KILE_DEBUG() << " is - found right: pos=" <<col << " " << envright.name << " " << TQString(textline.at(col+1)) << endl;
}
//KILE_DEBUG() << "found left/right: " << left << "/" << right << endl;
@@ -1447,7 +1447,7 @@ bool EditorExtension::isEnvironmentPosition(Kate::Document *doc, uint row, uint
bool EditorExtension::isCommentPosition(Kate::Document *doc, uint row, uint col)
{
- QString textline = doc->textLine(row);
+ TQString textline = doc->textLine(row);
bool backslash = false;
for ( uint i=0; i<col; ++i )
@@ -1474,7 +1474,7 @@ bool EditorExtension::isCommentPosition(Kate::Document *doc, uint row, uint col)
bool EditorExtension::isValidBackslash(Kate::Document *doc, uint row, uint col)
{
- QString textline = doc->textLine(row);
+ TQString textline = doc->textLine(row);
bool backslash = false;
for ( uint i=0; i<col; ++i )
@@ -1789,9 +1789,9 @@ bool EditorExtension::isBracketPosition(Kate::Document *doc, uint row, uint col,
bracket.row = row;
bracket.col = col;
- QString textline = getTextLineReal(doc,row);
- QChar right = textline[col];
- QChar left = ( col > 0 ) ? textline[col-1] : QChar(' ');
+ TQString textline = getTextLineReal(doc,row);
+ TQChar right = textline[col];
+ TQChar left = ( col > 0 ) ? textline[col-1] : TQChar(' ');
if ( m_overwritemode )
{
@@ -1838,7 +1838,7 @@ bool EditorExtension::findCloseBracketTag(Kate::Document *doc, uint row, uint co
for ( uint line=row; line<doc->numLines(); ++line )
{
uint start = ( line == row ) ? col : 0;
- QString textline = getTextLineReal(doc,line);
+ TQString textline = getTextLineReal(doc,line);
for ( uint i=start; i<textline.length(); ++i )
{
if ( textline[i] == '{' )
@@ -1870,7 +1870,7 @@ bool EditorExtension::findOpenBracketTag(Kate::Document *doc, uint row, uint col
uint brackets = 0;
for ( int line=row; line>=0; --line )
{
- QString textline = getTextLineReal(doc,line);
+ TQString textline = getTextLineReal(doc,line);
int start = ( line == (int)row ) ? col : textline.length()-1;
for ( int i=start; i>=0; --i )
{
@@ -1907,12 +1907,12 @@ bool EditorExtension::findOpenBracketTag(Kate::Document *doc, uint row, uint col
// - all comments
// replace these characters one one, which never will be looked for
-QString EditorExtension::getTextLineReal(Kate::Document *doc, uint row)
+TQString EditorExtension::getTextLineReal(Kate::Document *doc, uint row)
{
- QString textline = doc->textLine(row);
+ TQString textline = doc->textLine(row);
uint len = textline.length();
if ( len == 0)
- return QString::null;
+ return TQString();
bool backslash = false;
for (uint i=0; i<len; ++i )
@@ -1969,15 +1969,15 @@ QString EditorExtension::getTextLineReal(Kate::Document *doc, uint row)
// - smWord: letters and digits
// - smNospace: everything except white space
-bool EditorExtension::getCurrentWord(Kate::Document *doc, uint row, uint col, EditorExtension::SelectMode mode, QString &word,uint &x1,uint &x2)
+bool EditorExtension::getCurrentWord(Kate::Document *doc, uint row, uint col, EditorExtension::SelectMode mode, TQString &word,uint &x1,uint &x2)
{
// get real textline without comments, quoted characters and pairs of backslashes
- QString textline = getTextLineReal(doc,row);
+ TQString textline = getTextLineReal(doc,row);
if ( col > textline.length() )
return false;
- QRegExp reg;
- QString pattern1,pattern2;
+ TQRegExp reg;
+ TQString pattern1,pattern2;
switch ( mode )
{
case smLetter :
@@ -2004,7 +2004,7 @@ bool EditorExtension::getCurrentWord(Kate::Document *doc, uint row, uint col, Ed
if ( col > 0 )
{
reg.setPattern(pattern1);
- pos = textline.findRev(reg,col-1);
+ pos = textline.tqfindRev(reg,col-1);
if ( pos != -1 ) { // found an illegal character
x1 = pos + 1;
if ( mode == smTex ) {
@@ -2019,7 +2019,7 @@ bool EditorExtension::getCurrentWord(Kate::Document *doc, uint row, uint col, Ed
// search at the current position
reg.setPattern(pattern2);
- pos = textline.find(reg,col);
+ pos = textline.tqfind(reg,col);
if ( pos!=-1 && (uint)pos==col )
{
x2 = pos + reg.matchedLength();
@@ -2206,7 +2206,7 @@ void EditorExtension::selectLine(Kate::View *view)
// get current position
uint row,col;
- QString word;
+ TQString word;
Kate::Document *doc = view->getDoc();
view->cursorPositionReal(&row,&col);
@@ -2238,7 +2238,7 @@ void EditorExtension::selectWord(EditorExtension::SelectMode mode, Kate::View *v
// get current position
uint row,col,col1,col2;
- QString word;
+ TQString word;
Kate::Document *doc = view->getDoc();
view->cursorPositionReal(&row,&col);
@@ -2255,7 +2255,7 @@ void EditorExtension::deleteWord(EditorExtension::SelectMode mode, Kate::View *v
// get current position
uint row,col,col1,col2;
- QString word;
+ TQString word;
Kate::Document *doc = view->getDoc();
view->cursorPositionReal(&row,&col);
@@ -2312,7 +2312,7 @@ void EditorExtension::initDoubleQuotes()
if ( index<0 && index>=(int)m_quoteList.count() )
index = 0;
- QStringList quotes = QStringList::split(QRegExp("\\s{2,}"), m_quoteList[index] );
+ TQStringList quotes = TQStringList::split(TQRegExp("\\s{2,}"), m_quoteList[index] );
m_leftDblQuote= quotes[1];
m_rightDblQuote = quotes[2];
KILE_DEBUG() << "new quotes: " << m_dblQuotes << " left=" << m_leftDblQuote << " right=" << m_rightDblQuote<< endl;
@@ -2345,31 +2345,31 @@ bool EditorExtension::insertDoubleQuotes()
return false;
// simply insert, if autoinsert mode is not active or the char bevor is \ (typically for \"a useful)
- if ( !m_dblQuotes || ( col > 0 && doc->text(row,col-1,row,col) == QString("\\") ) )
+ if ( !m_dblQuotes || ( col > 0 && doc->text(row,col-1,row,col) == TQString("\\") ) )
return false;
// insert with auto mode
KTextEditor::SearchInterface *iface;
iface = dynamic_cast<KTextEditor::SearchInterface *>(doc);
- QString pattern1 = QRegExp::escape(m_leftDblQuote);
+ TQString pattern1 = TQRegExp::escape(m_leftDblQuote);
if ( m_leftDblQuote.at(m_leftDblQuote.length()-1).isLetter() )
pattern1 += "(\\b|(\\{\\}))";
- QString pattern2 = QRegExp::escape(m_rightDblQuote);
+ TQString pattern2 = TQRegExp::escape(m_rightDblQuote);
if ( m_rightDblQuote.at(m_rightDblQuote.length()-1).isLetter() )
pattern2 += "(\\b|(\\{\\}))";
- QRegExp reg('(' + pattern1 + ")|(" + pattern2 + ')');
+ TQRegExp reg('(' + pattern1 + ")|(" + pattern2 + ')');
uint r,c,l;
bool openfound = false;
if ( iface->searchText(row,col,reg,&r,&c,&l,true) )
{
- openfound = ( doc->textLine(r).find(m_leftDblQuote,c) == (int)c );
+ openfound = ( doc->textLine(r).tqfind(m_leftDblQuote,c) == (int)c );
//KILE_DEBUG() << "pattern=" << reg.pattern() << " " << reg.cap(1) << " r=" << r << " c=" << c << " open=" << openfound<< endl;
}
- QString textline = doc->textLine(row);
+ TQString textline = doc->textLine(row);
//KILE_DEBUG() << "text=" << textline << " open=" << openfound << endl;
if ( openfound )
{
@@ -2378,7 +2378,7 @@ bool EditorExtension::insertDoubleQuotes()
// insert a language specific doublequote close
int startcol = col - m_leftDblQuote.length();
//KILE_DEBUG() << "startcol=" << startcol << " col=" << col << endl;
- if ( startcol>=0 && textline.find(m_leftDblQuote,startcol) == (int)startcol )
+ if ( startcol>=0 && textline.tqfind(m_leftDblQuote,startcol) == (int)startcol )
{
doc->removeText(row,startcol,row,startcol+m_leftDblQuote.length());
doc->insertText(row,startcol,"\"");
@@ -2395,7 +2395,7 @@ bool EditorExtension::insertDoubleQuotes()
// insert a language specific doublequote open
int startcol = col - m_rightDblQuote.length();
//KILE_DEBUG() << "startcol=" << startcol << " col=" << col << endl;
- if ( startcol>=0 && textline.find(m_rightDblQuote,startcol) == (int)startcol )
+ if ( startcol>=0 && textline.tqfind(m_rightDblQuote,startcol) == (int)startcol )
{
doc->removeText(row,startcol,row,startcol+m_rightDblQuote.length());
doc->insertText(row,startcol,"\"");
@@ -2416,8 +2416,8 @@ void EditorExtension::insertIntelligentTabulator()
if ( !view ) return;
uint row,col,currentRow,currentCol;
- QString envname,tab;
- QString prefix = " ";
+ TQString envname,tab;
+ TQString prefix = " ";
view->cursorPositionReal(&currentRow,&currentCol);
if ( findOpenedEnvironment(row,col,envname,view) )
@@ -2428,16 +2428,16 @@ void EditorExtension::insertIntelligentTabulator()
// try to align tabulator with textline above
if ( currentRow >= 1 )
{
- int tabpos = view->getDoc()->textLine(currentRow-1).find('&',currentCol);
+ int tabpos = view->getDoc()->textLine(currentRow-1).tqfind('&',currentCol);
if ( tabpos >= 0 )
{
currentCol = tabpos;
- prefix = QString::null;
+ prefix = TQString();
}
}
}
- if ( tab == QString::null )
+ if ( tab == TQString() )
tab = "&";
tab = prefix + tab + ' ';
@@ -2458,7 +2458,7 @@ bool EditorExtension::eventInsertEnvironment(Kate::View *view)
int row = view->cursorLine();
int col = view->cursorColumnReal();
- QString line = view->getDoc()->textLine(row).left(col);
+ TQString line = view->getDoc()->textLine(row).left(col);
int pos = m_regexpEnter.search(line);
if (pos != -1 )
@@ -2467,7 +2467,7 @@ bool EditorExtension::eventInsertEnvironment(Kate::View *view)
for (uint i=0; i < line.length(); ++i)
if ( ! line[i].isSpace() ) line[i] = ' ';
- QString envname, endenv;
+ TQString envname, endenv;
if ( m_regexpEnter.cap(2) == "\\[" )
{
envname = m_regexpEnter.cap(2);
@@ -2476,12 +2476,12 @@ bool EditorExtension::eventInsertEnvironment(Kate::View *view)
else
{
envname = m_regexpEnter.cap(4);
- endenv = m_regexpEnter.cap(2).replace("\\begin","\\end") + '\n';
+ endenv = m_regexpEnter.cap(2).tqreplace("\\begin","\\end") + '\n';
}
if ( shouldCompleteEnv(envname, view) )
{
- QString item = m_latexCommands->isListEnv(envname) ? "\\item " : QString::null;
+ TQString item = m_latexCommands->isListEnv(envname) ? "\\item " : TQString();
view->getDoc()->insertText(row,col, '\n'+line+m_envAutoIndent+item +'\n'+line+endenv);
view->setCursorPositionReal(row+1, line.length()+m_envAutoIndent.length()+item.length());
return true;
@@ -2490,10 +2490,10 @@ bool EditorExtension::eventInsertEnvironment(Kate::View *view)
return false;
}
-bool EditorExtension::shouldCompleteEnv(const QString &env, Kate::View *view)
+bool EditorExtension::shouldCompleteEnv(const TQString &env, Kate::View *view)
{
KILE_DEBUG() << "===EditorExtension::shouldCompleteEnv( " << env << " )===" << endl;
- QRegExp reTestBegin,reTestEnd;
+ TQRegExp reTestBegin,reTestEnd;
if ( env == "\\[" )
{
KILE_DEBUG() << "display style" << endl;
@@ -2504,8 +2504,8 @@ bool EditorExtension::shouldCompleteEnv(const QString &env, Kate::View *view)
}
else
{
- reTestBegin.setPattern("(?:[^\\\\]|^)\\\\begin\\s*\\{" + QRegExp::escape(env) + "\\}");
- reTestEnd.setPattern("(?:[^\\\\]|^)\\\\end\\s*\\{" + QRegExp::escape(env) + "\\}");
+ reTestBegin.setPattern("(?:[^\\\\]|^)\\\\begin\\s*\\{" + TQRegExp::escape(env) + "\\}");
+ reTestEnd.setPattern("(?:[^\\\\]|^)\\\\end\\s*\\{" + TQRegExp::escape(env) + "\\}");
}
int num = view->getDoc()->numLines();
@@ -2515,8 +2515,8 @@ bool EditorExtension::shouldCompleteEnv(const QString &env, Kate::View *view)
view->cursorPositionReal(&realLine, &realColumn);
for ( int i = realLine; i < num; ++i)
{
- numBeginsFound += view->getDoc()->textLine(i).contains(reTestBegin);
- numEndsFound += view->getDoc()->textLine(i).contains(reTestEnd);
+ numBeginsFound += view->getDoc()->textLine(i).tqcontains(reTestBegin);
+ numEndsFound += view->getDoc()->textLine(i).tqcontains(reTestEnd);
KILE_DEBUG() << "line is " << i << " numBeginsFound = " << numBeginsFound << " , " << "numEndsFound = " << numEndsFound << endl;
if ( numEndsFound >= numBeginsFound )
return false;
@@ -2529,9 +2529,9 @@ bool EditorExtension::shouldCompleteEnv(const QString &env, Kate::View *view)
return true;
}
-QString EditorExtension::getWhiteSpace(const QString &s)
+TQString EditorExtension::getWhiteSpace(const TQString &s)
{
- QString whitespace = s;
+ TQString whitespace = s;
for ( uint i=0; i<whitespace.length(); ++i )
{
if ( ! whitespace[i].isSpace() )
@@ -2545,7 +2545,7 @@ QString EditorExtension::getWhiteSpace(const QString &s)
bool EditorExtension::insideVerbatim(Kate::View *view)
{
uint rowEnv,colEnv;
- QString nameEnv;
+ TQString nameEnv;
if ( findOpenedEnvironment(rowEnv,colEnv,nameEnv,view) )
{
@@ -2566,15 +2566,15 @@ bool EditorExtension::insideVerb(Kate::View *view)
view->cursorPositionReal(&row,&col);
int startpos = 0;
- QString textline = getTextLineReal(view->getDoc(),row);
- QRegExp reg("\\\\verb(\\*?)(.)");
+ TQString textline = getTextLineReal(view->getDoc(),row);
+ TQRegExp reg("\\\\verb(\\*?)(.)");
while ( true )
{
- int pos = textline.find(reg,startpos);
+ int pos = textline.tqfind(reg,startpos);
if ( pos<0 || col<(uint)pos+6+reg.cap(1).length() )
return false;
- pos = textline.find(reg.cap(2),pos+6+reg.cap(1).length());
+ pos = textline.tqfind(reg.cap(2),pos+6+reg.cap(1).length());
if ( pos<0 || col<=(uint)pos )
return true;
@@ -2627,8 +2627,8 @@ void EditorExtension::sectioningCommand(KileListViewItem *item, int id)
// FIXME tbraun make this more clever, introdoce in kiledocinfo a flag which can be easily queried for that, so that we don't have to hardcode the names of the sections here (which is definitly a bad idea)
// check, if the document was changed in the meantime
- QRegExp reg( "\\\\(part|chapter|section|subsection|subsubsection|paragraph|subparagraph)\\*?\\s*(\\{|\\[)" );
- QString textline = getTextLineReal(doc,row1);
+ TQRegExp reg( "\\\\(part|chapter|section|subsection|subsubsection|paragraph|subparagraph)\\*?\\s*(\\{|\\[)" );
+ TQString textline = getTextLineReal(doc,row1);
if ( reg.search(textline,col1) != (int)col1 )
{
m_ki->logWidget()->clear();
@@ -2656,20 +2656,20 @@ void EditorExtension::sectioningCommand(KileListViewItem *item, int id)
doc->clearSelection();
view->setCursorPositionReal(row1,col1);
- QString text;
+ TQString text;
KTextEditor::EditInterfaceExt *iface = KTextEditor::editInterfaceExt( doc );
if ( iface ) iface->editBegin();
switch ( id )
{
case KileWidget::Structure::SectioningCut:
- QApplication::clipboard()->setText( doc->text(row1,col1,row2,col2) ); // copy -> clipboard
+ TQApplication::tqclipboard()->setText( doc->text(row1,col1,row2,col2) ); // copy -> clipboard
doc->removeText(row1,col1,row2,col2); // delete
break;
case KileWidget::Structure::SectioningCopy:
- QApplication::clipboard()->setText( doc->text(row1,col1,row2,col2) ); // copy -> clipboard
+ TQApplication::tqclipboard()->setText( doc->text(row1,col1,row2,col2) ); // copy -> clipboard
break;
case KileWidget::Structure::SectioningPaste:
- text = QApplication::clipboard()->text(); // clipboard -> text
+ text = TQApplication::tqclipboard()->text(); // clipboard -> text
if ( ! text.isEmpty() )
{
view->setCursorPositionReal(row2,col2); // insert
@@ -2707,11 +2707,11 @@ bool EditorExtension::findEndOfDocument(Kate::Document *doc, uint row, uint col,
iface = dynamic_cast<KTextEditor::SearchInterface *>(doc);
uint lenFound;
- QString textline;
+ TQString textline;
while ( iface->searchText(row,col,"\\end{document}",&rowFound,&colFound,&lenFound) )
{
textline = getTextLineReal(doc,rowFound);
- if ( textline.find("\\end{document}",colFound) == (int)colFound )
+ if ( textline.tqfind("\\end{document}",colFound) == (int)colFound )
return true;
row = rowFound;
diff --git a/src/kile/kileedit.h b/src/kile/kileedit.h
index aec503e..7674dbd 100644
--- a/src/kile/kileedit.h
+++ b/src/kile/kileedit.h
@@ -16,11 +16,11 @@
#ifndef KILEEDIT_H
#define KILEEDIT_H
-#include <qobject.h>
-#include <qregexp.h>
-#include <qmap.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqobject.h>
+#include <tqregexp.h>
+#include <tqmap.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <kate/document.h>
@@ -38,9 +38,10 @@ namespace KileAction { class TagData; }
namespace KileDocument
{
-class EditorExtension : public QObject
+class EditorExtension : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
EditorExtension(KileInfo *);
@@ -54,7 +55,7 @@ public:
void insertTag(const KileAction::TagData& data, Kate::View *view);
- QString getTextLineReal(Kate::Document *doc, uint row);
+ TQString getTextLineReal(Kate::Document *doc, uint row);
void gotoBullet(bool backwards, Kate::View *view = 0L);
void gotoEnvironment(bool backwards, Kate::View *view = 0L);
@@ -63,24 +64,24 @@ public:
void closeAllEnvironments(Kate::View *view = 0L);
void selectEnvironment(bool inside, Kate::View *view = 0L);
void deleteEnvironment(bool inside, Kate::View *view = 0L);
- QString autoIndentEnvironment() { return m_envAutoIndent; }
+ TQString autoIndentEnvironment() { return m_envAutoIndent; }
void gotoTexgroup(bool backwards, Kate::View *view = 0L);
void selectTexgroup(bool inside, Kate::View *view = 0L);
void deleteTexgroup(bool inside, Kate::View *view = 0L);
- const QStringList doubleQuotesList() { return m_quoteList; }
+ const TQStringList doubleQuotesList() { return m_quoteList; }
// get current word
- bool getCurrentWord(Kate::Document *doc,uint row,uint col, SelectMode mode,QString &word,uint &x1,uint &x2);
- QString getEnvironmentText(uint &row, uint &col, QString &name, Kate::View *view = 0L);
+ bool getCurrentWord(Kate::Document *doc,uint row,uint col, SelectMode mode,TQString &word,uint &x1,uint &x2);
+ TQString getEnvironmentText(uint &row, uint &col, TQString &name, Kate::View *view = 0L);
bool hasEnvironment(Kate::View *view = 0L);
// complete environment
bool eventInsertEnvironment(Kate::View *view);
// mathgroup
- QString getMathgroupText(uint &row, uint &col, Kate::View *view = 0L);
+ TQString getMathgroupText(uint &row, uint &col, Kate::View *view = 0L);
bool hasMathgroup(Kate::View *view = 0L);
public slots:
@@ -143,7 +144,7 @@ private:
{
uint row;
uint col;
- QString name;
+ TQString name;
uint len;
EnvPos cpos;
EnvTag tag;
@@ -157,7 +158,7 @@ private:
uint len;
uint numdollar;
MathTag tag;
- QString envname;
+ TQString envname;
};
struct BracketData
@@ -167,9 +168,9 @@ private:
bool open;
};
- QRegExp m_reg;
+ TQRegExp m_reg;
bool m_overwritemode;
- QString m_envAutoIndent;
+ TQString m_envAutoIndent;
// change cursor position
bool increaseCursorPosition(Kate::Document *doc, uint &row, uint &col);
@@ -184,8 +185,8 @@ private:
bool findBeginEnvironment(Kate::Document *doc, uint row, uint col,EnvData &env);
bool findEndEnvironment(Kate::Document *doc, uint row, uint col,EnvData &env);
bool findEnvironmentTag(Kate::Document *doc, uint row, uint col,EnvData &env, bool backwards=false);
- bool findOpenedEnvironment(uint &row,uint &col, QString &envname, Kate::View *view);
- QStringList findOpenedEnvironmentList(Kate::View *view, bool position = false);
+ bool findOpenedEnvironment(uint &row,uint &col, TQString &envname, Kate::View *view);
+ TQStringList findOpenedEnvironmentList(Kate::View *view, bool position = false);
// get current environment
bool getEnvironment(bool inside, EnvData &envbegin, EnvData &envend,Kate::View *view);
@@ -201,8 +202,8 @@ private:
// find math tags
bool isOpeningMathTagPosition(Kate::Document *doc, uint row, uint col, MathData &mathdata);
bool isClosingMathTagPosition(Kate::Document *doc, uint row, uint col, MathData &mathdata);
- bool findOpenMathTag(Kate::Document *doc, uint row, uint col, QRegExp &reg, MathData &mathdata);
- bool findCloseMathTag(Kate::Document *doc, uint row, uint col, QRegExp &reg, MathData &mathdata);
+ bool findOpenMathTag(Kate::Document *doc, uint row, uint col, TQRegExp &reg, MathData &mathdata);
+ bool findCloseMathTag(Kate::Document *doc, uint row, uint col, TQRegExp &reg, MathData &mathdata);
bool checkMathtags(const MathData &begin,const MathData &end);
// mathgroup
@@ -220,23 +221,23 @@ private:
// check environment type
KileDocument::LatexCommands *m_latexCommands;
- bool shouldCompleteEnv(const QString &envname, Kate::View *view);
- QString getWhiteSpace(const QString &s);
+ bool shouldCompleteEnv(const TQString &envname, Kate::View *view);
+ TQString getWhiteSpace(const TQString &s);
// verbatim text
bool insideVerb(Kate::View *view);
bool insideVerbatim(Kate::View *view);
// complete environments
- QRegExp m_regexpEnter;
+ TQRegExp m_regexpEnter;
// double Quotes
bool m_dblQuotes;
- QStringList m_quoteList;
- QString m_leftDblQuote, m_rightDblQuote;
+ TQStringList m_quoteList;
+ TQString m_leftDblQuote, m_rightDblQuote;
// help
- void readHelpList(QString const &filename);
+ void readHelpList(TQString const &filename);
Kate::View *determineView(Kate::View *);
diff --git a/src/kile/kileerrorhandler.cpp b/src/kile/kileerrorhandler.cpp
index abfad07..6a5c60b 100644
--- a/src/kile/kileerrorhandler.cpp
+++ b/src/kile/kileerrorhandler.cpp
@@ -16,8 +16,8 @@
#include "kileerrorhandler.h"
#include <ktabwidget.h>
-#include <qfileinfo.h>
-#include <qregexp.h>
+#include <tqfileinfo.h>
+#include <tqregexp.h>
#include <klocale.h>
#include <kurl.h>
@@ -33,8 +33,8 @@
#include "kiledocmanager.h"
#include "kilesidebar.h"
-KileErrorHandler::KileErrorHandler(QObject *parent, KileInfo *info, const char *name)
- : QObject(parent, name), m_ki(info), m_nCurrentError(-1)
+KileErrorHandler::KileErrorHandler(TQObject *tqparent, KileInfo *info, const char *name)
+ : TQObject(tqparent, name), m_ki(info), m_nCurrentError(-1)
{
}
@@ -55,14 +55,14 @@ void KileErrorHandler::ViewLog()
m_ki->outputView()->showPage(m_ki->logWidget());
m_ki->setLogPresent(false);
- QString cn = m_ki->getCompileName();
+ TQString cn = m_ki->getCompileName();
if ( m_ki->outputFilter()->source() != cn )
{
m_ki->outputFilter()->setSource(cn);
- m_ki->outputFilter()->Run(cn.replace(QRegExp("\\..*$"),".log"));
+ m_ki->outputFilter()->Run(cn.tqreplace(TQRegExp("\\..*$"),".log"));
}
- QString log = m_ki->outputFilter()->log();
+ TQString log = m_ki->outputFilter()->log();
if (!log.isNull())
{
@@ -94,7 +94,7 @@ void KileErrorHandler::jumpToFirstError()
void KileErrorHandler::jumpToProblem(OutputInfo *info)
{
- QString file = m_ki->getFullFromPrettyName(info->source());
+ TQString file = m_ki->getFullFromPrettyName(info->source());
if ( !file.isNull() )
{
@@ -110,18 +110,18 @@ void KileErrorHandler::jumpToProblem(OutputInfo *info)
}
}
-void KileErrorHandler::showLogResults(const QString &src)
+void KileErrorHandler::showLogResults(const TQString &src)
{
m_ki->logWidget()->clear();
m_ki->setLogPresent(false);
m_ki->outputFilter()->setSource(src);
- QFileInfo fi(src);
- QString lf = fi.dirPath(true) + '/' + fi.baseName(true) + ".log";
- m_ki->logWidget()->printMsg(KileTool::Info, i18n("Detecting errors (%1), please wait ...").arg(lf), i18n("Log") );
+ TQFileInfo fi(src);
+ TQString lf = fi.dirPath(true) + '/' + fi.baseName(true) + ".log";
+ m_ki->logWidget()->printMsg(KileTool::Info, i18n("Detecting errors (%1), please wait ...").tqarg(lf), i18n("Log") );
if ( ! m_ki->outputFilter()->Run( lf ) )
{
- m_ki->outputFilter()->setSource(QString::null);
+ m_ki->outputFilter()->setSource(TQString());
return;
}
else
@@ -134,7 +134,7 @@ void KileErrorHandler::jumpToProblem(int type, bool forward)
//if the current log file does not belong to the files the user is viewing
//reparse the correct log file
- QString cn = m_ki->getCompileName();
+ TQString cn = m_ki->getCompileName();
bool correctlogfile = (cn == m_ki->outputFilter()->source());
if ( ! correctlogfile ) showLogResults(cn);
diff --git a/src/kile/kileerrorhandler.h b/src/kile/kileerrorhandler.h
index 413d1bf..3a32b64 100644
--- a/src/kile/kileerrorhandler.h
+++ b/src/kile/kileerrorhandler.h
@@ -16,7 +16,7 @@
#ifndef KILEERRORHANDLER_H
#define KILEERRORHANDLER_H
-#include <qobject.h>
+#include <tqobject.h>
/**
@author Jeroen Wijnhout
@@ -25,11 +25,12 @@
class KileInfo;
class OutputInfo;
-class KileErrorHandler : public QObject
+class KileErrorHandler : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileErrorHandler(QObject *parent, KileInfo *info, const char *name = 0);
+ KileErrorHandler(TQObject *tqparent, KileInfo *info, const char *name = 0);
~KileErrorHandler();
@@ -50,7 +51,7 @@ private:
public slots:
void jumpToFirstError();
void reset();
- void showLogResults(const QString &);
+ void showLogResults(const TQString &);
private:
KileInfo *m_ki;
diff --git a/src/kile/kileeventfilter.cpp b/src/kile/kileeventfilter.cpp
index 9879488..286d055 100644
--- a/src/kile/kileeventfilter.cpp
+++ b/src/kile/kileeventfilter.cpp
@@ -17,7 +17,7 @@
#include "kileeventfilter.h"
-#include <qevent.h>
+#include <tqevent.h>
#include <kate/view.h>
#include <kate/document.h>
@@ -39,24 +39,24 @@ void KileEventFilter::readConfig()
// KateViewInternal as a child of Kate::View has the focus
// This was set with Kate::View::setFocusProxy(viewInternal)
-bool KileEventFilter::eventFilter(QObject *o, QEvent *e)
+bool KileEventFilter::eventFilter(TQObject *o, TQEvent *e)
{
- if ( e->type() == QEvent::KeyPress)
+ if ( e->type() == TQEvent::KeyPress)
{
- QKeyEvent *ke = (QKeyEvent*) e;
- if ( ke->key()==Qt::Key_QuoteDbl && ke->ascii()==Qt::Key_QuoteDbl )
+ TQKeyEvent *ke = (TQKeyEvent*) e;
+ if ( ke->key()==TQt::Key_QuoteDbl && ke->ascii()==TQt::Key_QuoteDbl )
{
return m_edit->insertDoubleQuotes();
}
- if ( m_bCompleteEnvironment && ke->key()==Qt::Key_Return && ke->state()==0)
+ if ( m_bCompleteEnvironment && ke->key()==TQt::Key_Return && ke->state()==0)
{
- return m_edit->eventInsertEnvironment( (Kate::View*) o->parent() );
+ return m_edit->eventInsertEnvironment( (Kate::View*) o->tqparent() );
}
}
- else if ( e->type() == QEvent::MouseButtonDblClick)
+ else if ( e->type() == TQEvent::MouseButtonDblClick)
{
- QMouseEvent *me = (QMouseEvent*) e;
- if ( me->button()==LeftButton && ((me->state() & Qt::ControlButton) == Qt::ControlButton) )
+ TQMouseEvent *me = (TQMouseEvent*) e;
+ if ( me->button()==Qt::LeftButton && ((me->state() & TQt::ControlButton) == TQt::ControlButton) )
{
m_edit->selectWord(KileDocument::EditorExtension::smTex);
return true;
diff --git a/src/kile/kileeventfilter.h b/src/kile/kileeventfilter.h
index d9a99eb..43dd1ec 100644
--- a/src/kile/kileeventfilter.h
+++ b/src/kile/kileeventfilter.h
@@ -12,10 +12,10 @@
#ifndef KILEEVENTFILTER_H
#define KILEEVENTFILTER_H
-#include <qobject.h>
-#include <qregexp.h>
+#include <tqobject.h>
+#include <tqregexp.h>
-class QEvent;
+class TQEvent;
namespace Kate {class View; }
namespace KileDocument { class EditorExtension; };
@@ -24,9 +24,10 @@ namespace KileDocument { class EditorExtension; };
* This class is capable of intercepting key-strokes from the editor. It can complete a \begin{env}
* with a \end{env} when enter is pressed.
**/
-class KileEventFilter : public QObject
+class KileEventFilter : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
KileEventFilter(KileDocument::EditorExtension *edit);
@@ -35,7 +36,7 @@ public slots:
void readConfig();
protected:
- bool eventFilter(QObject *o, QEvent *e);
+ bool eventFilter(TQObject *o, TQEvent *e);
private:
bool m_bCompleteEnvironment;
diff --git a/src/kile/kileextensions.cpp b/src/kile/kileextensions.cpp
index 9c01b6c..7010399 100644
--- a/src/kile/kileextensions.cpp
+++ b/src/kile/kileextensions.cpp
@@ -15,9 +15,9 @@
#include "kileextensions.h"
-#include <qstring.h>
-#include <qstringlist.h>
-#include <qfileinfo.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
+#include <tqfileinfo.h>
#include <klocale.h>
#include "kiledebug.h"
@@ -47,9 +47,9 @@ Extensions::Extensions()
//////////////////// file filter ////////////////////
-QString Extensions::fileFilter(uint type)
+TQString Extensions::fileFilter(uint type)
{
- QString ext,text;
+ TQString ext,text;
switch ( type )
{
case LATEX_EXT_DOC:
@@ -77,44 +77,44 @@ QString Extensions::fileFilter(uint type)
text = i18n("Kile Project Files");
break;
default:
- return QString::null;
+ return TQString();
}
- ext.replace(".","*.");
+ ext.tqreplace(".","*.");
return ext + '|' + text;
}
//////////////////// document type ////////////////////
-bool Extensions::isTexFile(const QString &fileName) const
+bool Extensions::isTexFile(const TQString &fileName) const
{
//TODO use mimetype
- QString ext = '.' + QFileInfo(fileName).extension(false);
+ TQString ext = '.' + TQFileInfo(fileName).extension(false);
return isLatexDocument(ext) || isLatexPackage(ext);
}
-bool Extensions::isBibFile(const QString &fileName) const
+bool Extensions::isBibFile(const TQString &fileName) const
{
- QString ext = '.' + QFileInfo(fileName).extension(false);
+ TQString ext = '.' + TQFileInfo(fileName).extension(false);
return isBibtex(ext);
}
-bool Extensions::isScriptFile(const QString &fileName) const
+bool Extensions::isScriptFile(const TQString &fileName) const
{
- QString ext = '.' + QFileInfo(fileName).extension(false);
+ TQString ext = '.' + TQFileInfo(fileName).extension(false);
return isScript(ext);
}
-bool Extensions::isProjectFile(const QString &fileName) const
+bool Extensions::isProjectFile(const TQString &fileName) const
{
- QString ext = '.' + QFileInfo(fileName).extension(false);
+ TQString ext = '.' + TQFileInfo(fileName).extension(false);
return isProject(ext);
}
-bool Extensions::validExtension(const QString &ext, const QString &extensions) const
+bool Extensions::validExtension(const TQString &ext, const TQString &extensions) const
{
- QStringList extlist = QStringList::split(" ",extensions);
- for ( QStringList::ConstIterator it=extlist.begin(); it!=extlist.end(); ++it )
+ TQStringList extlist = TQStringList::split(" ",extensions);
+ for ( TQStringList::ConstIterator it=extlist.begin(); it!=extlist.end(); ++it )
{
if ( (*it) == ext )
return true;
@@ -143,7 +143,7 @@ Type Extensions::determineDocumentType(const KURL& url) const
}
}
-QString Extensions::defaultExtensionForDocumentType(KileDocument::Type type) const
+TQString Extensions::defaultExtensionForDocumentType(KileDocument::Type type) const
{
switch(type) {
case KileDocument::LaTeX:
@@ -161,7 +161,7 @@ QString Extensions::defaultExtensionForDocumentType(KileDocument::Type type) con
/* do nothing */
break;
}
- return QString();
+ return TQString();
}
}
diff --git a/src/kile/kileextensions.h b/src/kile/kileextensions.h
index 1f1807e..7c61adb 100644
--- a/src/kile/kileextensions.h
+++ b/src/kile/kileextensions.h
@@ -18,8 +18,8 @@
#include "kileconstants.h"
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <kurl.h>
@@ -34,57 +34,57 @@ public:
enum { LATEX_EXT_DOC=1, LATEX_EXT_PKG=2, LATEX_EXT_BIB=4, LATEX_EXT_IMG=8, LATEX_EXT_MP=16, LATEX_EXT_JS=32, LATEX_EXT_PROJ=64 };
- QString latexDocuments() { return m_documents; }
- QString latexPackages() { return m_packages; }
- QString bibtex() { return m_bibtex; }
- QString images() { return m_images; }
- QString metapost() { return m_metapost; }
-
- QString latexDocumentDefault() { return m_latexDefault; }
- QString bibtexDefault() { return m_bibtexDefault; }
- QString metapostDefault() { return m_metapostDefault; }
-
- QString latexDocumentFileFilter() { return fileFilter(LATEX_EXT_DOC); }
- QString latexPackageFileFilter() { return fileFilter(LATEX_EXT_PKG); }
- QString bibtexFileFilter() { return fileFilter(LATEX_EXT_BIB); }
- QString imageFileFilter() { return fileFilter(LATEX_EXT_IMG); }
- QString metapostFileFilter() { return fileFilter(LATEX_EXT_MP); }
- QString scriptFileFilter() { return fileFilter(LATEX_EXT_JS); }
- QString projectFileFilter() { return fileFilter(LATEX_EXT_PROJ); }
+ TQString latexDocuments() { return m_documents; }
+ TQString latexPackages() { return m_packages; }
+ TQString bibtex() { return m_bibtex; }
+ TQString images() { return m_images; }
+ TQString metapost() { return m_metapost; }
+
+ TQString latexDocumentDefault() { return m_latexDefault; }
+ TQString bibtexDefault() { return m_bibtexDefault; }
+ TQString metapostDefault() { return m_metapostDefault; }
+
+ TQString latexDocumentFileFilter() { return fileFilter(LATEX_EXT_DOC); }
+ TQString latexPackageFileFilter() { return fileFilter(LATEX_EXT_PKG); }
+ TQString bibtexFileFilter() { return fileFilter(LATEX_EXT_BIB); }
+ TQString imageFileFilter() { return fileFilter(LATEX_EXT_IMG); }
+ TQString metapostFileFilter() { return fileFilter(LATEX_EXT_MP); }
+ TQString scriptFileFilter() { return fileFilter(LATEX_EXT_JS); }
+ TQString projectFileFilter() { return fileFilter(LATEX_EXT_PROJ); }
- bool isTexFile(const QString &fileName) const;
+ bool isTexFile(const TQString &fileName) const;
bool isTexFile(const KURL &url) const { return isTexFile(url.fileName()); }
- bool isBibFile(const QString &fileName) const;
+ bool isBibFile(const TQString &fileName) const;
bool isBibFile(const KURL &url) const { return isBibFile(url.fileName()); }
- bool isScriptFile(const QString &fileName) const;
+ bool isScriptFile(const TQString &fileName) const;
bool isScriptFile(const KURL & url) const { return isScriptFile(url.fileName()); }
- bool isProjectFile(const QString &fileName) const;
+ bool isProjectFile(const TQString &fileName) const;
bool isProjectFile(const KURL &url) const { return isProjectFile(url.fileName()); }
- bool isLatexDocument(const QString &ext) const { return validExtension(ext,m_documents); }
- bool isLatexPackage(const QString &ext) const { return validExtension(ext,m_packages); }
- bool isImage(const QString &ext) const { return validExtension(ext,m_images); }
+ bool isLatexDocument(const TQString &ext) const { return validExtension(ext,m_documents); }
+ bool isLatexPackage(const TQString &ext) const { return validExtension(ext,m_packages); }
+ bool isImage(const TQString &ext) const { return validExtension(ext,m_images); }
KileDocument::Type determineDocumentType(const KURL &url) const;
- QString defaultExtensionForDocumentType(KileDocument::Type type) const;
+ TQString defaultExtensionForDocumentType(KileDocument::Type type) const;
private:
- QString m_documents, m_packages;
- QString m_bibtex, m_metapost;
- QString m_images, m_script;
- QString m_project;
-
- QString m_latexDefault, m_bibtexDefault;
- QString m_metapostDefault, m_scriptDefault;
- QString m_projectDefault;
-
- bool isBibtex(const QString &ext) const { return validExtension(ext,m_bibtex); }
- bool isMetapost(const QString &ext) const { return validExtension(ext,m_metapost); }
- bool isScript(const QString &ext) const { return validExtension(ext,m_script); }
- bool isProject(const QString &ext) const { return validExtension(ext,m_project); }
- bool validExtension(const QString &ext, const QString &extensions) const;
-
- QString fileFilter(uint type);
+ TQString m_documents, m_packages;
+ TQString m_bibtex, m_metapost;
+ TQString m_images, m_script;
+ TQString m_project;
+
+ TQString m_latexDefault, m_bibtexDefault;
+ TQString m_metapostDefault, m_scriptDefault;
+ TQString m_projectDefault;
+
+ bool isBibtex(const TQString &ext) const { return validExtension(ext,m_bibtex); }
+ bool isMetapost(const TQString &ext) const { return validExtension(ext,m_metapost); }
+ bool isScript(const TQString &ext) const { return validExtension(ext,m_script); }
+ bool isProject(const TQString &ext) const { return validExtension(ext,m_project); }
+ bool validExtension(const TQString &ext, const TQString &extensions) const;
+
+ TQString fileFilter(uint type);
};
}
diff --git a/src/kile/kilefileselect.cpp b/src/kile/kilefileselect.cpp
index 1c67980..89c0a41 100644
--- a/src/kile/kilefileselect.cpp
+++ b/src/kile/kilefileselect.cpp
@@ -21,10 +21,10 @@ from Kate (C) 2001 by Matt Newell
#include "kilefileselect.h"
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qstrlist.h>
-#include <qtooltip.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqstrlist.h>
+#include <tqtooltip.h>
#include <ktoolbar.h>
#include <kiconloader.h>
@@ -38,30 +38,30 @@ from Kate (C) 2001 by Matt Newell
#include "kileconfig.h"
-KileFileSelect::KileFileSelect(KileDocument::Extensions *extensions, QWidget *parent, const char *name ) : QWidget(parent,name)
+KileFileSelect::KileFileSelect(KileDocument::Extensions *extensions, TQWidget *tqparent, const char *name ) : TQWidget(tqparent,name)
{
- QVBoxLayout* lo = new QVBoxLayout(this);
+ TQVBoxLayout* lo = new TQVBoxLayout(this);
KToolBar *toolbar = new KToolBar(this, "fileselectortoolbar");
lo->addWidget(toolbar);
cmbPath = new KURLComboBox( KURLComboBox::Directories, true, this, "path combo" );
- cmbPath->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ));
+ cmbPath->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Fixed ));
cmpl = new KURLCompletion(KURLCompletion::DirCompletion);
cmbPath->setCompletionObject( cmpl );
lo->addWidget(cmbPath);
dir = new KDirOperator(KURL(), this, "operator");
- connect(dir, SIGNAL(fileSelected(const KFileItem*)), this, SIGNAL(fileSelected(const KFileItem*)));
+ connect(dir, TQT_SIGNAL(fileSelected(const KFileItem*)), this, TQT_SIGNAL(fileSelected(const KFileItem*)));
dir->setView(KFile::Simple);
dir->setMode(KFile::Files);
// KileFileSelect filter for sidebar
- QString filter = extensions->latexDocuments()
+ TQString filter = extensions->latexDocuments()
+ ' ' + extensions->latexPackages()
+ ' ' + extensions->bibtex()
+ ' ' + extensions->metapost();
- filter.replace(".","*.");
+ filter.tqreplace(".","*.");
dir->setNameFilter(filter);
KActionCollection *coll = dir->actionCollection();
@@ -80,21 +80,21 @@ KileFileSelect::KileFileSelect(KileDocument::Extensions *extensions, QWidget *pa
coll->action("forward")->plug(toolbar);
toolbar->insertButton("fileopen", 0, true , i18n( "Open selected" ));
- connect(toolbar, SIGNAL(clicked(int)), this, SLOT(clickedToolbar(int)));
+ connect(toolbar, TQT_SIGNAL(clicked(int)), this, TQT_SLOT(clickedToolbar(int)));
lo->addWidget(dir);
lo->setStretchFactor(dir, 2);
m_comboEncoding = new KComboBox( false, this, "comboEncoding" );
- QStringList availableEncodingNames(KGlobal::charsets()->availableEncodingNames());
+ TQStringList availableEncodingNames(KGlobal::charsets()->availableEncodingNames());
m_comboEncoding->setEditable( true );
m_comboEncoding->insertStringList( availableEncodingNames );
- QToolTip::add(m_comboEncoding, i18n("Set encoding"));
+ TQToolTip::add(m_comboEncoding, i18n("Set encoding"));
lo->addWidget(m_comboEncoding);
- connect( cmbPath, SIGNAL( urlActivated( const KURL& )),this, SLOT( cmbPathActivated( const KURL& ) ));
- connect( cmbPath, SIGNAL( returnPressed( const QString& )), this, SLOT( cmbPathReturnPressed( const QString& ) ));
- connect(dir, SIGNAL(urlEntered(const KURL&)), this, SLOT(dirUrlEntered(const KURL&)) );
+ connect( cmbPath, TQT_SIGNAL( urlActivated( const KURL& )),this, TQT_SLOT( cmbPathActivated( const KURL& ) ));
+ connect( cmbPath, TQT_SIGNAL( returnPressed( const TQString& )), this, TQT_SLOT( cmbPathReturnPressed( const TQString& ) ));
+ connect(dir, TQT_SIGNAL(urlEntered(const KURL&)), this, TQT_SLOT(dirUrlEntered(const KURL&)) );
}
KileFileSelect::~KileFileSelect()
@@ -104,8 +104,8 @@ KileFileSelect::~KileFileSelect()
void KileFileSelect::readConfig()
{
- QString lastDir = KileConfig::lastDir();
- QFileInfo ldi(lastDir);
+ TQString lastDir = KileConfig::lastDir();
+ TQFileInfo ldi(lastDir);
if ( ! ldi.isReadable() ) dir->home();
else setDir(KURL::fromPathOrURL(lastDir));
}
@@ -125,7 +125,7 @@ void KileFileSelect::cmbPathActivated( const KURL& u )
dir->setURL( u, true );
}
-void KileFileSelect::cmbPathReturnPressed( const QString& u )
+void KileFileSelect::cmbPathReturnPressed( const TQString& u )
{
dir->setFocus();
dir->setURL( KURL(u), true );
@@ -134,14 +134,14 @@ void KileFileSelect::cmbPathReturnPressed( const QString& u )
void KileFileSelect::dirUrlEntered( const KURL& u )
{
cmbPath->removeURL( u );
- QStringList urls = cmbPath->urls();
+ TQStringList urls = cmbPath->urls();
urls.prepend( u.url() );
while ( urls.count() >= (uint)cmbPath->maxItems() )
urls.remove( urls.last() );
cmbPath->setURLs( urls );
}
-void KileFileSelect::focusInEvent(QFocusEvent*)
+void KileFileSelect::focusInEvent(TQFocusEvent*)
{
dir->setFocus();
}
@@ -155,7 +155,7 @@ void KileFileSelect::clickedToolbar(int i)
{
if (i == 0)
{
- QPtrListIterator<KFileItem> it(*dir->selectedItems());
+ TQPtrListIterator<KFileItem> it(*dir->selectedItems());
while ( it.current() != 0 )
{
emit(fileSelected(*it));
diff --git a/src/kile/kilefileselect.h b/src/kile/kilefileselect.h
index ecaed9c..c61c8df 100644
--- a/src/kile/kilefileselect.h
+++ b/src/kile/kilefileselect.h
@@ -19,8 +19,8 @@ from Kate (C) 2001 by Matt Newell
#ifndef KILEFILESELECT_H
#define KILEFILESELECT_H
-#include <qwidget.h>
-#include <qtoolbutton.h>
+#include <tqwidget.h>
+#include <tqtoolbutton.h>
#include <kfile.h>
#include <kdiroperator.h>
#include <kurlcombobox.h>
@@ -36,12 +36,13 @@ from Kate (C) 2001 by Matt Newell
class KFileItem;
class KComboBox;
-class KileFileSelect : public QWidget
+class KileFileSelect : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileFileSelect(KileDocument::Extensions *extensions, QWidget *parent=0, const char *name=0);
+ KileFileSelect(KileDocument::Extensions *extensions, TQWidget *tqparent=0, const char *name=0);
~KileFileSelect();
void setView(KFile::FileView);
@@ -55,13 +56,13 @@ public slots:
private slots:
void cmbPathActivated( const KURL& u );
- void cmbPathReturnPressed( const QString& u );
+ void cmbPathReturnPressed( const TQString& u );
void dirUrlEntered( const KURL& u );
void clickedToolbar(int);
protected:
- void focusInEvent(QFocusEvent*);
+ void focusInEvent(TQFocusEvent*);
signals:
void fileSelected(const KFileItem*);
@@ -70,7 +71,7 @@ private:
KURLComboBox *cmbPath;
KDirOperator * dir;
KComboBox *m_comboEncoding;
- QToolButton *home, *up, *back, *forward;
+ TQToolButton *home, *up, *back, *forward;
KURLCompletion *cmpl;
};
diff --git a/src/kile/kilegrepdialog.cpp b/src/kile/kilegrepdialog.cpp
index 443ff2c..3a73412 100644
--- a/src/kile/kilegrepdialog.cpp
+++ b/src/kile/kilegrepdialog.cpp
@@ -43,16 +43,16 @@
#include "kilegrepdialog.h"
-#include <qobject.h>
-#include <qlayout.h>
-#include <qpushbutton.h>
-#include <qlineedit.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qevent.h>
-#include <qregexp.h>
-#include <qwhatsthis.h>
-#include <qcursor.h>
+#include <tqobject.h>
+#include <tqlayout.h>
+#include <tqpushbutton.h>
+#include <tqlineedit.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqevent.h>
+#include <tqregexp.h>
+#include <tqwhatsthis.h>
+#include <tqcursor.h>
#include <kcombobox.h>
#include <kapplication.h>
@@ -74,64 +74,64 @@
#include "kiledocmanager.h"
#include "kileextensions.h"
-KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mode, const char *name)
- : KDialogBase (parent, name, false, QString::null, 0, Ok, false ),
+KileGrepDialog::KileGrepDialog(TQWidget *tqparent, KileInfo *ki, KileGrep::Mode mode, const char *name)
+ : KDialogBase (tqparent, name, false, TQString(), 0, Ok, false ),
m_ki(ki), m_mode(mode), childproc(0), m_grepJobs(0)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- //setWFlags( Qt::WStyle_StaysOnTop );
+ //setWFlags( TQt::WStyle_StaysOnTop );
// build dialog
- QVBoxLayout *vbox = new QVBoxLayout( page,5,KDialog::spacingHint() );
+ TQVBoxLayout *vbox = new TQVBoxLayout( page,5,KDialog::spacingHint() );
// project groupbox
- QGroupBox *projectgroup = new QGroupBox( i18n("Project"),page);
+ TQGroupBox *projectgroup = new TQGroupBox( i18n("Project"),page);
projectgroup->setColumnLayout(0, Qt::Vertical );
- projectgroup->layout()->setSpacing( 6 );
- projectgroup->layout()->setMargin( 11 );
- QGridLayout *projectgrouplayout = new QGridLayout( projectgroup->layout() );
- projectgrouplayout->setAlignment( Qt::AlignTop );
+ projectgroup->tqlayout()->setSpacing( 6 );
+ projectgroup->tqlayout()->setMargin( 11 );
+ TQGridLayout *projectgrouptqlayout = new TQGridLayout( projectgroup->tqlayout() );
+ projectgrouptqlayout->tqsetAlignment( TQt::AlignTop );
- QLabel *project_label = new QLabel(i18n("Name:"), projectgroup);
- int labelwidth = project_label->sizeHint().width();
+ TQLabel *project_label = new TQLabel(i18n("Name:"), projectgroup);
+ int labelwidth = project_label->tqsizeHint().width();
- QLabel *projectdir_label = new QLabel(i18n("Directory:"), projectgroup);
- if ( projectdir_label->sizeHint().width() > labelwidth )
- labelwidth = projectdir_label->sizeHint().width();
+ TQLabel *projectdir_label = new TQLabel(i18n("Directory:"), projectgroup);
+ if ( projectdir_label->tqsizeHint().width() > labelwidth )
+ labelwidth = projectdir_label->tqsizeHint().width();
- projectname_label = new QLabel(projectgroup);
- projectdirname_label = new QLabel(projectgroup);
+ projectname_label = new TQLabel(projectgroup);
+ projectdirname_label = new TQLabel(projectgroup);
- projectgrouplayout->addWidget(project_label, 0,0, AlignLeft | AlignVCenter);
- projectgrouplayout->addWidget(projectname_label, 0,1, AlignLeft | AlignVCenter);
- projectgrouplayout->addWidget(projectdir_label, 1,0, AlignLeft | AlignVCenter);
- projectgrouplayout->addWidget(projectdirname_label, 1,1, AlignLeft | AlignVCenter);
- projectgrouplayout->setColStretch(1,1);
+ projectgrouptqlayout->addWidget(project_label, 0,0, AlignLeft | AlignVCenter);
+ projectgrouptqlayout->addWidget(projectname_label, 0,1, AlignLeft | AlignVCenter);
+ projectgrouptqlayout->addWidget(projectdir_label, 1,0, AlignLeft | AlignVCenter);
+ projectgrouptqlayout->addWidget(projectdirname_label, 1,1, AlignLeft | AlignVCenter);
+ projectgrouptqlayout->setColStretch(1,1);
// search groupbox
- QGroupBox *searchgroup = new QGroupBox( i18n("Search"),page);
+ TQGroupBox *searchgroup = new TQGroupBox( i18n("Search"),page);
searchgroup->setColumnLayout(0, Qt::Vertical );
- searchgroup->layout()->setSpacing( 6 );
- searchgroup->layout()->setMargin( 11 );
- QGridLayout *searchgrouplayout = new QGridLayout( searchgroup->layout() );
- searchgrouplayout->setAlignment( Qt::AlignTop );
+ searchgroup->tqlayout()->setSpacing( 6 );
+ searchgroup->tqlayout()->setMargin( 11 );
+ TQGridLayout *searchgrouptqlayout = new TQGridLayout( searchgroup->tqlayout() );
+ searchgrouptqlayout->tqsetAlignment( TQt::AlignTop );
- QLabel *pattern_label = new QLabel(i18n("Pattern:"), searchgroup);
- if ( pattern_label->sizeHint().width() > labelwidth )
- labelwidth = pattern_label->sizeHint().width();
+ TQLabel *pattern_label = new TQLabel(i18n("Pattern:"), searchgroup);
+ if ( pattern_label->tqsizeHint().width() > labelwidth )
+ labelwidth = pattern_label->tqsizeHint().width();
pattern_combo = new KComboBox(true, searchgroup);
pattern_combo->setInsertionPolicy(KComboBox::NoInsertion);
pattern_combo->setFocus();
- pattern_combo->setMinimumSize(pattern_combo->sizeHint());
+ pattern_combo->setMinimumSize(pattern_combo->tqsizeHint());
pattern_label->setBuddy(pattern_combo);
- QLabel *template_label = new QLabel(i18n("Template:"), searchgroup);
- if ( template_label->sizeHint().width() > labelwidth )
- labelwidth = template_label->sizeHint().width();
+ TQLabel *template_label = new TQLabel(i18n("Template:"), searchgroup);
+ if ( template_label->tqsizeHint().width() > labelwidth )
+ labelwidth = template_label->tqsizeHint().width();
- QStringList templatemode_list;
+ TQStringList templatemode_list;
templatemode_list << i18n("Normal")
<< i18n("Command")
<< i18n("Command[]")
@@ -142,7 +142,7 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
<< i18n("File")
;
- QBoxLayout *template_layout = new QHBoxLayout(4);
+ TQBoxLayout *template_layout = new TQHBoxLayout(4);
template_combo = new KComboBox(false, searchgroup);
template_combo->insertStringList(templatemode_list);
template_combo->adjustSize();
@@ -152,51 +152,51 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
template_edit = new KLineEdit(searchgroup);
template_edit->setText("%s");
- template_edit->setMinimumSize(template_edit->sizeHint());
+ template_edit->setMinimumSize(template_edit->tqsizeHint());
template_label->setBuddy(template_edit);
template_layout->addWidget(template_edit);
- searchgrouplayout->addWidget(pattern_label, 0,0, AlignLeft | AlignVCenter);
- searchgrouplayout->addWidget(pattern_combo, 0,1);
- searchgrouplayout->addWidget(template_label, 1,0, AlignLeft | AlignVCenter);
- searchgrouplayout->addLayout(template_layout, 1,1);
+ searchgrouptqlayout->addWidget(pattern_label, 0,0, AlignLeft | AlignVCenter);
+ searchgrouptqlayout->addWidget(pattern_combo, 0,1);
+ searchgrouptqlayout->addWidget(template_label, 1,0, AlignLeft | AlignVCenter);
+ searchgrouptqlayout->addLayout(template_layout, 1,1);
// filter groupbox
- QGroupBox *filtergroup = new QGroupBox( i18n("Directory Options"),page);
+ TQGroupBox *filtergroup = new TQGroupBox( i18n("Directory Options"),page);
filtergroup->setColumnLayout(0, Qt::Vertical );
- filtergroup->layout()->setSpacing( 6 );
- filtergroup->layout()->setMargin( 11 );
- QGridLayout *filtergrouplayout = new QGridLayout( filtergroup->layout() );
- filtergrouplayout->setAlignment( Qt::AlignTop );
+ filtergroup->tqlayout()->setSpacing( 6 );
+ filtergroup->tqlayout()->setMargin( 11 );
+ TQGridLayout *filtergrouptqlayout = new TQGridLayout( filtergroup->tqlayout() );
+ filtergrouptqlayout->tqsetAlignment( TQt::AlignTop );
- QLabel *files_label = new QLabel(i18n("Filter:"), filtergroup);
- if ( files_label->sizeHint().width() > labelwidth )
- labelwidth = files_label->sizeHint().width();
+ TQLabel *files_label = new TQLabel(i18n("Filter:"), filtergroup);
+ if ( files_label->tqsizeHint().width() > labelwidth )
+ labelwidth = files_label->tqsizeHint().width();
filter_combo = new KComboBox(true, filtergroup);
- filter_combo->setMinimumSize(filter_combo->sizeHint());
- files_label->setBuddy(filter_combo->focusProxy());
+ filter_combo->setMinimumSize(filter_combo->tqsizeHint());
+ files_label->setBuddy(TQT_TQWIDGET(filter_combo->focusProxy()));
- QLabel *dir_label = new QLabel(i18n("Directory:"), filtergroup);
- if ( dir_label->sizeHint().width() > labelwidth )
- labelwidth = dir_label->sizeHint().width();
+ TQLabel *dir_label = new TQLabel(i18n("Directory:"), filtergroup);
+ if ( dir_label->tqsizeHint().width() > labelwidth )
+ labelwidth = dir_label->tqsizeHint().width();
- QBoxLayout *dir_layout = new QHBoxLayout(3);
+ TQBoxLayout *dir_layout = new TQHBoxLayout(3);
dir_combo = new KURLRequester( new KComboBox(true, filtergroup), filtergroup, "dir combo" );
dir_combo->completionObject()->setMode(KURLCompletion::DirCompletion);
dir_combo->setMode(KFile::Directory|KFile::LocalOnly|KFile::ExistingOnly);
dir_label->setBuddy(dir_combo);
dir_layout->addWidget(dir_combo);
- recursive_box = new QCheckBox(i18n("Scan directories recursively"), filtergroup);
- recursive_box->setMinimumWidth(recursive_box->sizeHint().width());
+ recursive_box = new TQCheckBox(i18n("Scan directories recursively"), filtergroup);
+ recursive_box->setMinimumWidth(recursive_box->tqsizeHint().width());
- filtergrouplayout->addWidget(files_label, 2,0, AlignLeft | AlignVCenter);
- filtergrouplayout->addWidget(filter_combo, 2, 1);
- filtergrouplayout->addWidget(dir_label, 3,0, AlignLeft | AlignVCenter);
- filtergrouplayout->addLayout(dir_layout, 3,1);
- filtergrouplayout->addMultiCellWidget(recursive_box, 4,4, 1,2);
- filtergrouplayout->setColStretch(1,1);
+ filtergrouptqlayout->addWidget(files_label, 2,0, AlignLeft | AlignVCenter);
+ filtergrouptqlayout->addWidget(filter_combo, 2, 1);
+ filtergrouptqlayout->addWidget(dir_label, 3,0, AlignLeft | AlignVCenter);
+ filtergrouptqlayout->addLayout(dir_layout, 3,1);
+ filtergrouptqlayout->addMultiCellWidget(recursive_box, 4,4, 1,2);
+ filtergrouptqlayout->setColStretch(1,1);
// result box
resultbox = new KListBox(page);
@@ -215,7 +215,7 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
#else
close_button = actionbox->addButton(i18n("Cl&ose"));
#endif
- actionbox->layout();
+ actionbox->tqlayout();
// adjust labels
project_label->setFixedWidth(labelwidth);
@@ -241,12 +241,12 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
vbox->addWidget(actionbox);
// Produces error messages like
- // QListBox::property( "text" ) failed:
+ // TQListBox::property( "text" ) failed:
// property invalid or does not exist
// Anyone an idea?
KAcceleratorManager::manage( this );
- QWhatsThis::add(pattern_combo,
+ TQWhatsThis::add(pattern_combo,
i18n("Enter the regular expression you want to search for here.<br>"
"Possible meta characters are:<br>"
"<ul>"
@@ -270,10 +270,10 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
"Furthermore, backreferences to bracketed subexpressions are "
"available via the notation \\\\<i>n</i>."
));
- QWhatsThis::add(filter_combo,
+ TQWhatsThis::add(filter_combo,
i18n("Enter the file name pattern of the files to search here. "
"You may give several patterns separated by commas."));
- QWhatsThis::add(template_combo,
+ TQWhatsThis::add(template_combo,
i18n("Choose one search mode. For the first modes, the search pattern is "
"build from the editable template, where '%s' is replaced by the given pattern.<br><br>"
"There are additional fixed predefined modes for environments, graphics, labels, references "
@@ -281,16 +281,16 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
"If a pattern is given, it will be inserted as a parameter. F.e., in environment mode with "
"pattern 'center', Kile will search for '\\begin{center}' and in graphics mode with "
"pattern '.*\\.png', Kile will search for all png files."));
- QWhatsThis::add(template_edit,
+ TQWhatsThis::add(template_edit,
i18n("For the first three modes you can choose a template for the pattern from the combo box "
"and edit it here. The string %s in the template is replaced "
"by the pattern input field, resulting in the regular expression "
"to search for. In all other modes this template is ignored."));
- QWhatsThis::add(dir_combo,
+ TQWhatsThis::add(dir_combo,
i18n("Enter the directory which contains the files you want to search in."));
- QWhatsThis::add(recursive_box,
+ TQWhatsThis::add(recursive_box,
i18n("Check this box to search in all subdirectories."));
- QWhatsThis::add(resultbox,
+ TQWhatsThis::add(resultbox,
i18n("The results of the grep run are listed here. Select a "
"filename/line number combination with a mouse click on the item "
"or with the cursor to show the respective line in the editor."));
@@ -308,25 +308,25 @@ KileGrepDialog::KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mod
setupProject();
}
- pattern_combo->setEditText(QString::null);
+ pattern_combo->setEditText(TQString());
template_edit->setText(template_list[0]);
- slotPatternTextChanged(QString::null);
+ slotPatternTextChanged(TQString());
- connect( pattern_combo->lineEdit(), SIGNAL(textChanged ( const QString & )),
- SLOT( slotPatternTextChanged( const QString & )));
- connect( template_combo, SIGNAL(activated(int)),
- SLOT(slotTemplateActivated(int)) );
- connect( resultbox, SIGNAL(highlighted(const QString&)),
- SLOT(slotItemSelected(const QString&)) );
+ connect( pattern_combo->lineEdit(), TQT_SIGNAL(textChanged ( const TQString & )),
+ TQT_SLOT( slotPatternTextChanged( const TQString & )));
+ connect( template_combo, TQT_SIGNAL(activated(int)),
+ TQT_SLOT(slotTemplateActivated(int)) );
+ connect( resultbox, TQT_SIGNAL(highlighted(const TQString&)),
+ TQT_SLOT(slotItemSelected(const TQString&)) );
- connect( search_button, SIGNAL(clicked()), SLOT(slotSearch()) );
- connect( clear_button, SIGNAL(clicked()), SLOT(slotClear()) );
- connect( close_button, SIGNAL(clicked()), SIGNAL(closeClicked()) );
+ connect( search_button, TQT_SIGNAL(clicked()), TQT_SLOT(slotSearch()) );
+ connect( clear_button, TQT_SIGNAL(clicked()), TQT_SLOT(slotClear()) );
+ connect( close_button, TQT_SIGNAL(clicked()), TQT_SIGNAL(closeClicked()) );
- connect( this, SIGNAL(closeClicked()), SLOT(slotClose()) );
- connect( this, SIGNAL(finished()), SLOT(slotFinished()) );
+ connect( this, TQT_SIGNAL(closeClicked()), TQT_SLOT(slotClose()) );
+ connect( this, TQT_SIGNAL(finished()), TQT_SLOT(slotFinished()) );
- resize(450,sizeHint().height());
+ resize(450,tqsizeHint().height());
KILE_DEBUG() << "==KileGrepDialog (create dialog)=============================" << endl;
}
@@ -343,8 +343,8 @@ void KileGrepDialog::readConfig()
{
pattern_combo->insertStringList( readList(KileGrep::SearchItems) );
- QString labels = getCommandList(KileDocument::CmdAttrLabel);
- QString references = getCommandList(KileDocument::CmdAttrReference);
+ TQString labels = getCommandList(KileDocument::CmdAttrLabel);
+ TQString references = getCommandList(KileDocument::CmdAttrReference);
template_list = readList(KileGrep::SearchTemplates) ;
if ( template_list.count() != 3 )
{
@@ -369,7 +369,7 @@ void KileGrepDialog::writeConfig()
{
KileConfig::setLastSearchItems( getListItems(pattern_combo) );
- QStringList list;
+ TQStringList list;
list << template_list[0] << template_list[1] << template_list[2];
KileConfig::setLastSearchTemplates( list );
@@ -384,11 +384,11 @@ void KileGrepDialog::writeConfig()
void KileGrepDialog::setupDirectory()
{
- setDirName( QDir::home().absPath() );
+ setDirName( TQDir::home().absPath() );
// use a filter for 'find in files' dialog
KileDocument::Extensions *extensions = m_ki->extensions();
- QString filter = extensions->latexDocumentFileFilter() + '\n'
+ TQString filter = extensions->latexDocumentFileFilter() + '\n'
+ extensions->latexPackageFileFilter() + '\n'
+ extensions->bibtexFileFilter() + '\n'
+ extensions->metapostFileFilter() + '\n'
@@ -413,15 +413,15 @@ void KileGrepDialog::setupProject()
{
m_projectOpened = false;
projectname_label->setText( i18n("no project opened") );
- projectdirname_label->setText( QString::null );
+ projectdirname_label->setText( TQString() );
}
}
///////////////////// read entries /////////////////////
-QStringList KileGrepDialog::readList(KileGrep::List listtype)
+TQStringList KileGrepDialog::readList(KileGrep::List listtype)
{
- QStringList strings,result;
+ TQStringList strings,result;
bool stripSlash = false;
switch ( listtype )
@@ -451,18 +451,18 @@ QStringList KileGrepDialog::readList(KileGrep::List listtype)
///////////////////// item selected /////////////////////
-void KileGrepDialog::slotItemSelected(const QString& item)
+void KileGrepDialog::slotItemSelected(const TQString& item)
{
KILE_DEBUG() << "\tgrep: start item selected" << endl;
int pos;
- QString filename, linenumber;
+ TQString filename, linenumber;
- QString str = item;
- if ( (pos = str.find(':')) != -1)
+ TQString str = item;
+ if ( (pos = str.tqfind(':')) != -1)
{
filename = str.left(pos);
str = str.right(str.length()-1-pos);
- if ( (pos = str.find(':')) != -1)
+ if ( (pos = str.tqfind(':')) != -1)
{
linenumber = str.left(pos);
if ( m_mode == KileGrep::Project )
@@ -483,24 +483,24 @@ void KileGrepDialog::startGrep()
if ( m_mode == KileGrep::Project )
{
- QString command = buildProjectCommand() + ' ' + KProcess::quote(m_projectfiles[m_grepJobs-1]);
+ TQString command = buildProjectCommand() + ' ' + KProcess::quote(m_projectfiles[m_grepJobs-1]);
KILE_DEBUG() << "\tgrep (project): " << command << endl;
- (*childproc) << QStringList::split(' ',command);
+ (*childproc) << TQStringList::split(' ',command);
}
else
{
- QString command = buildFilesCommand();
+ TQString command = buildFilesCommand();
KILE_DEBUG() << "\tgrep (files): " << command << endl;
- (*childproc) << QStringList::split(' ', command);
+ (*childproc) << TQStringList::split(' ', command);
}
m_grepJobs--;
- connect( childproc, SIGNAL(processExited(KProcess *)),
- SLOT(childExited()) );
- connect( childproc, SIGNAL(receivedStdout(KProcess *, char *, int)),
- SLOT(receivedOutput(KProcess *, char *, int)) );
- connect( childproc, SIGNAL(receivedStderr(KProcess *, char *, int)),
- SLOT(receivedErrOutput(KProcess *, char *, int)) );
+ connect( childproc, TQT_SIGNAL(processExited(KProcess *)),
+ TQT_SLOT(childExited()) );
+ connect( childproc, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),
+ TQT_SLOT(receivedOutput(KProcess *, char *, int)) );
+ connect( childproc, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)),
+ TQT_SLOT(receivedErrOutput(KProcess *, char *, int)) );
childproc->start(KProcess::NotifyOnExit, KProcess::AllOutput);
}
@@ -508,14 +508,14 @@ void KileGrepDialog::startGrep()
void KileGrepDialog::processOutput()
{
int pos;
- while ( (pos = buf.find('\n')) != -1)
+ while ( (pos = buf.tqfind('\n')) != -1)
{
- QString item = buf.left(pos);
+ TQString item = buf.left(pos);
if ( ! item.isEmpty() )
{
if ( m_mode == KileGrep::Project )
{
- if ( item.find(m_projectdir + '/') == 0 )
+ if ( item.tqfind(m_projectdir + '/') == 0 )
resultbox->insertItem( item.mid(m_projectdir.length()+1) );
else
resultbox->insertItem(item);
@@ -532,13 +532,13 @@ void KileGrepDialog::processOutput()
void KileGrepDialog::receivedOutput(KProcess */*proc*/, char *buffer, int buflen)
{
- buf += QString::fromLocal8Bit(buffer, buflen);
+ buf += TQString::fromLocal8Bit(buffer, buflen);
processOutput();
}
void KileGrepDialog::receivedErrOutput(KProcess */*proc*/, char *buffer, int buflen)
{
- errbuf += QString::fromLocal8Bit( buffer, buflen );
+ errbuf += TQString::fromLocal8Bit( buffer, buflen );
}
void KileGrepDialog::childExited()
@@ -547,7 +547,7 @@ void KileGrepDialog::childExited()
if ( ! errbuf.isEmpty() )
{
- KMessageBox::information( parentWidget(),
+ KMessageBox::information( tqparentWidget(),
i18n("<strong>Error:</strong><p>") + errbuf,
i18n("Grep Tool Error") );
errbuf.truncate(0);
@@ -592,9 +592,9 @@ void KileGrepDialog::updateLists()
///////////////////// build commands /////////////////////
-QString KileGrepDialog::getPattern()
+TQString KileGrepDialog::getPattern()
{
- QString pattern;
+ TQString pattern;
int template_mode = template_combo->currentItem();
if ( template_mode < KileGrep::tmEnv )
{
@@ -602,7 +602,7 @@ QString KileGrepDialog::getPattern()
if ( pattern.isEmpty() )
pattern = pattern_combo->currentText();
else
- pattern.replace("%s", pattern_combo->currentText());
+ pattern.tqreplace("%s", pattern_combo->currentText());
}
else
{
@@ -614,18 +614,18 @@ QString KileGrepDialog::getPattern()
return pattern;
}
-QString KileGrepDialog::getShellPattern()
+TQString KileGrepDialog::getShellPattern()
{
- QString pattern = getPattern();
- pattern.replace("'", "'\\''");
+ TQString pattern = getPattern();
+ pattern.tqreplace("'", "'\\''");
return '\'' + pattern + '\'';
//return KProcess::quote(pattern);
}
-QString KileGrepDialog::buildFilesCommand()
+TQString KileGrepDialog::buildFilesCommand()
{
- QString files, files_temp;
+ TQString files, files_temp;
if (filter_combo->currentItem() >= 0)
files_temp = filter_list[filter_combo->currentItem()];
@@ -635,8 +635,8 @@ QString KileGrepDialog::buildFilesCommand()
if (files_temp.right(1) != ",")
files_temp = files_temp + ',';
- QStringList tokens = QStringList::split ( ",", files_temp, false );
- QStringList::Iterator it = tokens.begin();
+ TQStringList tokens = TQStringList::split ( ",", files_temp, false );
+ TQStringList::Iterator it = tokens.begin();
if (it != tokens.end())
{
files = " '" + (*it) + '\'';
@@ -646,8 +646,8 @@ QString KileGrepDialog::buildFilesCommand()
for ( ; it != tokens.end(); ++it )
files = files + " -o -name " + '\'' + (*it) + '\'';
- QString shell_command;
- shell_command += "find ";
+ TQString shell_command;
+ shell_command += "tqfind ";
shell_command += KProcess::quote(dir_combo->url());
shell_command += " \\( -name ";
shell_command += files;
@@ -659,7 +659,7 @@ QString KileGrepDialog::buildFilesCommand()
return shell_command;
}
-QString KileGrepDialog::buildProjectCommand()
+TQString KileGrepDialog::buildProjectCommand()
{
return "grep -n -E -I -H -e " + getShellPattern();
}
@@ -681,14 +681,14 @@ void KileGrepDialog::slotSearch()
}
KILE_DEBUG() << "\tgrep: start new search" << endl;
- QRegExp re( getPattern() );
+ TQRegExp re( getPattern() );
if ( ! re.isValid() )
{
- KMessageBox::error( 0, i18n("Invalid regular expression: %1").arg(re.errorString()), i18n("Grep Tool Error") );
+ KMessageBox::error( 0, i18n("Invalid regular expression: %1").tqarg(re.errorString()), i18n("Grep Tool Error") );
return;
}
- resultbox->setCursor( QCursor(Qt::WaitCursor) );
+ resultbox->setCursor( TQCursor(TQt::WaitCursor) );
search_button->setText( i18n("&Cancel") );
if ( template_combo->currentItem() < KileGrep::tmEnv)
template_list[m_lastTemplateIndex] = template_edit->text();
@@ -698,7 +698,7 @@ void KileGrepDialog::slotSearch()
startGrep();
}
-void KileGrepDialog::slotSearchFor(const QString &pattern)
+void KileGrepDialog::slotSearchFor(const TQString &pattern)
{
slotClear();
pattern_combo->setEditText(pattern);
@@ -730,7 +730,7 @@ void KileGrepDialog::slotFinished()
///////////////////// templates /////////////////////
-void KileGrepDialog::slotPatternTextChanged(const QString &)
+void KileGrepDialog::slotPatternTextChanged(const TQString &)
{
updateWidgets();
}
@@ -744,7 +744,7 @@ void KileGrepDialog::slotTemplateActivated(int index)
}
else
{
- template_edit->setText(QString::null);
+ template_edit->setText(TQString());
}
m_lastTemplateIndex = index;
@@ -769,7 +769,7 @@ void KileGrepDialog::updateWidgets()
///////////////////// directory /////////////////////
-void KileGrepDialog::setDirName(const QString &dir)
+void KileGrepDialog::setDirName(const TQString &dir)
{
KComboBox *combo = dir_combo->comboBox();
@@ -781,24 +781,24 @@ void KileGrepDialog::setDirName(const QString &dir)
///////////////////// filter /////////////////////
-void KileGrepDialog::setFilter(const QString &filter)
+void KileGrepDialog::setFilter(const TQString &filter)
{
filter_list.clear();
filter_combo->clear();
if ( !filter.isEmpty() )
{
- QStringList filter_lst = QStringList::split("\n", filter);
- for (QStringList::Iterator it = filter_lst.begin();
+ TQStringList filter_lst = TQStringList::split("\n", filter);
+ for (TQStringList::Iterator it = filter_lst.begin();
it != filter_lst.end(); ++it)
{
- QStringList filter_split = QStringList::split("|", *it);
+ TQStringList filter_split = TQStringList::split("|", *it);
filter_list.append(filter_split[0]);
filter_combo->insertItem(filter_split[1]);
}
}
}
-void KileGrepDialog::appendFilter(const QString &name, const QString &filter)
+void KileGrepDialog::appendFilter(const TQString &name, const TQString &filter)
{
filter_combo->insertItem(name);
filter_list.append(filter);
@@ -806,7 +806,7 @@ void KileGrepDialog::appendFilter(const QString &name, const QString &filter)
///////////////////// template /////////////////////
-void KileGrepDialog::appendTemplate(const QString &name, const QString &regexp)
+void KileGrepDialog::appendTemplate(const TQString &name, const TQString &regexp)
{
template_combo->insertItem(name);
template_list.append(regexp);
@@ -820,15 +820,15 @@ void KileGrepDialog::clearTemplates()
///////////////////// KComboBox /////////////////////
-QStringList KileGrepDialog::getListItems(KComboBox *combo)
+TQStringList KileGrepDialog::getListItems(KComboBox *combo)
{
- QStringList list;
+ TQStringList list;
for ( int i=0; i<combo->count() && i<KILEGREP_MAX; ++i )
list.append( combo->text(i) );
return list;
}
-int KileGrepDialog::findListItem(KComboBox *combo, const QString &s)
+int KileGrepDialog::findListItem(KComboBox *combo, const TQString &s)
{
for ( int i=0; i<combo->count(); ++i )
{
@@ -840,7 +840,7 @@ int KileGrepDialog::findListItem(KComboBox *combo, const QString &s)
void KileGrepDialog::updateListItems(KComboBox *combo)
{
- QString s = combo->currentText();
+ TQString s = combo->currentText();
if ( s.isEmpty() )
return;
@@ -864,17 +864,17 @@ void KileGrepDialog::updateListItems(KComboBox *combo)
///////////////////// template /////////////////////
-QString KileGrepDialog::getCommandList(KileDocument::CmdAttribute attrtype)
+TQString KileGrepDialog::getCommandList(KileDocument::CmdAttribute attrtype)
{
- QStringList cmdlist;
- QStringList::ConstIterator it;
+ TQStringList cmdlist;
+ TQStringList::ConstIterator it;
// get info about user defined references
KileDocument::LatexCommands *cmd = m_ki->latexCommands();
cmd->commandList(cmdlist,attrtype,true);
// build list of references
- QString commands = QString::null;
+ TQString commands = TQString();
for ( it=cmdlist.begin(); it != cmdlist.end(); ++it )
{
commands += '|' + (*it).mid(1);
diff --git a/src/kile/kilegrepdialog.h b/src/kile/kilegrepdialog.h
index 056c712..41f5f5f 100644
--- a/src/kile/kilegrepdialog.h
+++ b/src/kile/kilegrepdialog.h
@@ -25,15 +25,15 @@
#define __KILE_GREP_DIALOG_H_
#include <kdialogbase.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include "kileinfo.h"
#include "latexcmd.h"
-class QCheckBox;
-class QPushButton;
-class QLabel;
-class QEvent;
+class TQCheckBox;
+class TQPushButton;
+class TQLabel;
+class TQEvent;
class KComboBox;
class KLineEdit;
@@ -53,21 +53,22 @@ namespace KileGrep
class KileGrepDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileGrepDialog(QWidget *parent, KileInfo *ki, KileGrep::Mode mode, const char *name = 0);
+ KileGrepDialog(TQWidget *tqparent, KileInfo *ki, KileGrep::Mode mode, const char *name = 0);
~KileGrepDialog();
- void appendFilter(const QString &name, const QString &filter);
+ void appendFilter(const TQString &name, const TQString &filter);
- void appendTemplate(const QString &name, const QString &regexp);
+ void appendTemplate(const TQString &name, const TQString &regexp);
void clearTemplates();
public slots:
- void slotSearchFor(const QString &pattern);
+ void slotSearchFor(const TQString &pattern);
signals:
- void itemSelected(const QString &abs_filename, int line);
+ void itemSelected(const TQString &abs_filename, int line);
private:
KileInfo *m_ki;
@@ -78,8 +79,8 @@ private:
void readConfig();
void writeConfig();
- QStringList getListItems(KComboBox *combo);
- int findListItem(KComboBox *combo, const QString &s);
+ TQStringList getListItems(KComboBox *combo);
+ int findListItem(KComboBox *combo, const TQString &s);
void updateListItems(KComboBox *combo);
void processOutput();
@@ -88,48 +89,48 @@ private:
void startGrep();
bool shouldRestart() { return (m_grepJobs > 0); }
void clearGrepJobs() { m_grepJobs = 0; }
- QString buildFilesCommand();
- QString buildProjectCommand();
- QString getPattern();
- QString getShellPattern();
- QString getCommandList(KileDocument::CmdAttribute attrtype);
+ TQString buildFilesCommand();
+ TQString buildProjectCommand();
+ TQString getPattern();
+ TQString getShellPattern();
+ TQString getCommandList(KileDocument::CmdAttribute attrtype);
void setupDirectory();
void setupProject();
- void setDirName(const QString &dir);
- void setFilter(const QString &filter);
- QStringList readList(KileGrep::List listtype);
+ void setDirName(const TQString &dir);
+ void setFilter(const TQString &filter);
+ TQStringList readList(KileGrep::List listtype);
void updateLists();
void updateWidgets();
- QStringList m_projectfiles;
- QString m_projectdir;
+ TQStringList m_projectfiles;
+ TQString m_projectdir;
bool m_projectOpened;
- QLabel *projectname_label, *projectdirname_label;
+ TQLabel *projectname_label, *projectdirname_label;
KLineEdit *template_edit;
KComboBox *filter_combo, *pattern_combo, *template_combo;
KURLRequester *dir_combo;
- QCheckBox *recursive_box;
+ TQCheckBox *recursive_box;
KListBox *resultbox;
- QPushButton *search_button, *clear_button, *close_button;
- QString buf;
- QString errbuf;
- QStringList lastSearchPaths;
- QStringList filter_list;
- QStringList template_list;
+ TQPushButton *search_button, *clear_button, *close_button;
+ TQString buf;
+ TQString errbuf;
+ TQStringList lastSearchPaths;
+ TQStringList filter_list;
+ TQStringList template_list;
int m_lastTemplateIndex;
private slots:
void childExited();
void receivedOutput(KProcess *proc, char *buffer, int buflen);
void receivedErrOutput(KProcess *proc, char *buffer, int buflen);
- void slotItemSelected(const QString&);
+ void slotItemSelected(const TQString&);
void slotSearch();
void slotClear();
void slotClose();
void slotFinished();
- void slotPatternTextChanged(const QString &);
+ void slotPatternTextChanged(const TQString &);
void slotTemplateActivated(int index);
};
diff --git a/src/kile/kilehelp.cpp b/src/kile/kilehelp.cpp
index 6f5d082..3e89b34 100644
--- a/src/kile/kilehelp.cpp
+++ b/src/kile/kilehelp.cpp
@@ -16,11 +16,11 @@
#include "kilehelp.h"
-#include <qdir.h>
-#include <qfile.h>
-#include <qtextstream.h>
-#include <qregexp.h>
-#include <qfileinfo.h>
+#include <tqdir.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
+#include <tqregexp.h>
+#include <tqfileinfo.h>
#include <kapplication.h>
#include <kglobal.h>
@@ -39,7 +39,7 @@
// tbraun 27.06.2007
-// it _looks_ like texlive 2007 has the same layout than texlive 2005 so don't get confused about the variable names :)
+// it _looks_ like texlive 2007 has the same tqlayout than texlive 2005 so don't get confused about the variable names :)
namespace KileHelp
{
@@ -61,8 +61,8 @@ namespace KileHelp
m_texdocPath = KileConfig::location();
// first check for TexLive2005
- QString texref = m_texdocPath + "/english/tex-refs";
- QDir dir(texref);
+ TQString texref = m_texdocPath + "/english/tex-refs";
+ TQDir dir(texref);
if ( dir.exists() )
{
// we found TexLive2005
@@ -116,7 +116,7 @@ namespace KileHelp
}
////////////////////// show help //////////////////////
- void Help::showHelpFile(const QString &parameter)
+ void Help::showHelpFile(const TQString &parameter)
{
KileTool::ViewHTML *tool = new KileTool::ViewHTML("ViewHTML", m_manager, false);
tool->setFlags(KileTool::NeedSourceExists | KileTool::NeedSourceRead);
@@ -125,7 +125,7 @@ namespace KileHelp
//bad to rely on it
tool->setMsg(KileTool::NeedSourceExists, i18n("Sorry, could not find the teTeX documentation at %1; set the correct path in Settings->Configure Kile->Help."));
tool->setSource(parameter);
- tool->setTargetPath(QFileInfo(parameter).fileName());
+ tool->setTargetPath(TQFileInfo(parameter).fileName());
tool->prepareToRun();
m_manager->run(tool);
}
@@ -149,7 +149,7 @@ namespace KileHelp
void Help::helpTexGuide()
{
- QString filename;
+ TQString filename;
switch ( m_texVersion )
{
@@ -173,7 +173,7 @@ namespace KileHelp
void Help::helpLatex(Type type)
{
- QString link;
+ TQString link;
if ( m_texVersion == TEXLIVE2005)
{
@@ -237,7 +237,7 @@ namespace KileHelp
}
// show help file
- QString texversion;
+ TQString texversion;
if ( m_texVersion == TEXLIVE2005 )
texversion = "TexLive 2005";
else if ( m_texVersion == TETEX3 )
@@ -268,9 +268,9 @@ namespace KileHelp
void Help::helpTexRefsKeyword(Kate::View *view)
{
- QString word = getKeyword(view);
+ TQString word = getKeyword(view);
KILE_DEBUG() << "keyword: " << word << endl;
- if ( !word.isNull() && m_dictHelpTex.contains(word) )
+ if ( !word.isNull() && m_dictHelpTex.tqcontains(word) )
{
KILE_DEBUG() << "about to show help for " << word << " (section " << m_dictHelpTex[word] << " )" << endl;
showHelpFile( m_texdocPath + m_texReference + m_dictHelpTex[word] );
@@ -281,13 +281,13 @@ namespace KileHelp
void Help::helpKileRefsKeyword(Kate::View *view)
{
- QString kilehelp = KGlobal::dirs()->findResource("html","en/kile/latexhelp.html");
+ TQString kilehelp = KGlobal::dirs()->findResource("html","en/kile/latexhelp.html");
KILE_DEBUG() << "kilehelp = " << kilehelp << endl;
if ( ! kilehelp.isEmpty() )
{
- QString word = getKeyword(view);
- KILE_DEBUG() << "word = " << word << " " << m_dictHelpKile.contains(word) << endl;
- if ( !word.isNull() && m_dictHelpKile.contains(word) )
+ TQString word = getKeyword(view);
+ KILE_DEBUG() << "word = " << word << " " << m_dictHelpKile.tqcontains(word) << endl;
+ if ( !word.isNull() && m_dictHelpKile.tqcontains(word) )
{
showHelpFile( kilehelp + '#' + m_dictHelpKile[word] );
}
@@ -296,19 +296,19 @@ namespace KileHelp
}
}
- void Help::noHelpAvailableFor(const QString &word)
+ void Help::noHelpAvailableFor(const TQString &word)
{
- m_manager->info()->logWidget()->printMsg(KileTool::Error, i18n("Sorry, no help available for %1.").arg(word), i18n("Help"));
+ m_manager->info()->logWidget()->printMsg(KileTool::Error, i18n("Sorry, no help available for %1.").tqarg(word), i18n("Help"));
}
- QString Help::getKeyword(Kate::View *view)
+ TQString Help::getKeyword(Kate::View *view)
{
if ( !view )
- return QString::null;
+ return TQString();
// get current position
uint row,col,col1,col2;
- QString word;
+ TQString word;
Kate::Document *doc = view->getDoc();
view->cursorPositionReal(&row,&col);
@@ -320,14 +320,14 @@ namespace KileHelp
else
return word;
else
- return QString::null;
+ return TQString();
}
//////////////////// read help lists ////////////////////
- void Help::readHelpList(const QString &filename,QMap<QString,QString> &map)
+ void Help::readHelpList(const TQString &filename,TQMap<TQString,TQString> &map)
{
- QString file = KGlobal::dirs()->findResource("appdata","help/" + filename);
+ TQString file = KGlobal::dirs()->findResource("appdata","help/" + filename);
if ( file.isEmpty() )
{
KILE_DEBUG() << " file not found: " << filename << endl;
@@ -335,15 +335,15 @@ namespace KileHelp
}
KILE_DEBUG() << " read file: " << filename << endl;
- QRegExp reg("\\s*(\\S+)\\s*=>\\s*(\\S+)");
+ TQRegExp reg("\\s*(\\S+)\\s*=>\\s*(\\S+)");
- QFile f(file);
+ TQFile f(file);
if ( f.open(IO_ReadOnly) )
{ // file opened successfully
- QTextStream t( &f ); // use a text stream
+ TQTextStream t( &f ); // use a text stream
while ( ! t.eof() )
{ // until end of file...
- QString s = t.readLine().stripWhiteSpace(); // line of text excluding '\n'
+ TQString s = t.readLine().stripWhiteSpace(); // line of text excluding '\n'
if ( ! (s.isEmpty() || s.at(0)=='#') )
{
int pos = reg.search(s);
diff --git a/src/kile/kilehelp.h b/src/kile/kilehelp.h
index 1518bc7..af7eb70 100644
--- a/src/kile/kilehelp.h
+++ b/src/kile/kilehelp.h
@@ -17,9 +17,9 @@
#ifndef KILEHELP_H
#define KILEHELP_H
-#include <qobject.h>
-#include <qmap.h>
-#include <qstring.h>
+#include <tqobject.h>
+#include <tqmap.h>
+#include <tqstring.h>
#include <kconfig.h>
#include <kmenubar.h>
@@ -58,9 +58,10 @@ namespace KileHelp
TEXLIVE2005
};
- class Help : public QObject
+ class Help : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
Help(KileDocument::EditorExtension *edit);
@@ -71,7 +72,7 @@ namespace KileHelp
// calls for help
void helpKeyword(Kate::View *view);
- void noHelpAvailableFor(const QString &word);
+ void noHelpAvailableFor(const TQString &word);
void userHelpDialog() { m_userhelp->userHelpDialog(); }
void enableUserhelpEntries(bool state);
public slots:
@@ -89,20 +90,20 @@ namespace KileHelp
UserHelp *m_userhelp;
TexVersion m_texVersion;
- QString m_texReference;
- QString m_texdocPath;
+ TQString m_texReference;
+ TQString m_texdocPath;
- QMap<QString,QString> m_dictHelpKile;
- QMap<QString,QString> m_dictHelpTex;
+ TQMap<TQString,TQString> m_dictHelpKile;
+ TQMap<TQString,TQString> m_dictHelpTex;
void initTexDocumentation();
- void readHelpList(const QString &filename,QMap<QString,QString> &map);
- void showHelpFile(const QString &parameter);
+ void readHelpList(const TQString &filename,TQMap<TQString,TQString> &map);
+ void showHelpFile(const TQString &parameter);
void helpLatex(KileHelp::Type type);
void helpTexRefsKeyword(Kate::View *view);
void helpKileRefsKeyword(Kate::View *view);
- QString getKeyword(Kate::View *view);
+ TQString getKeyword(Kate::View *view);
};
}
diff --git a/src/kile/kileinfo.cpp b/src/kile/kileinfo.cpp
index 21aaca7..fe9d133 100644
--- a/src/kile/kileinfo.cpp
+++ b/src/kile/kileinfo.cpp
@@ -18,9 +18,9 @@
#include "kileinfo.h"
-#include <qwidget.h>
-#include <qfileinfo.h>
-#include <qobject.h>
+#include <tqwidget.h>
+#include <tqfileinfo.h>
+#include <tqobject.h>
#include <kate/document.h>
#include <kate/view.h>
@@ -38,23 +38,23 @@
#include "templates.h"
#include <kstandarddirs.h>
-#include <qstringlist.h>
-#include <qstring.h>
+#include <tqstringlist.h>
+#include <tqstring.h>
-KileInfo::KileInfo(QWidget *parent) :
+KileInfo::KileInfo(TQWidget *tqparent) :
m_manager(0L),
m_jScriptManager(0L),
m_toolFactory(0L),
m_texKonsole(0L),
m_edit(0L),
- m_parentWidget(parent),
- m_currentTarget(QString::null)
+ m_parentWidget(tqparent),
+ m_currentTarget(TQString())
{
- m_docManager = new KileDocument::Manager(this, parent, "KileDocument::Manager");
- m_viewManager= new KileView::Manager(this, parent, "KileView::Manager");
- m_templateManager = new KileTemplate::Manager(this, parent, "KileTemplate::Manager");
- m_editorKeySequenceManager = new KileEditorKeySequence::Manager(this, parent, "KileEditorKeySequence::Manager");
- QObject::connect(m_docManager, SIGNAL(documentStatusChanged(Kate::Document*, bool, unsigned char)), m_viewManager, SLOT(reflectDocumentStatus(Kate::Document*, bool, unsigned char)));
+ m_docManager = new KileDocument::Manager(this, TQT_TQOBJECT(tqparent), "KileDocument::Manager");
+ m_viewManager= new KileView::Manager(this, TQT_TQOBJECT(tqparent), "KileView::Manager");
+ m_templateManager = new KileTemplate::Manager(this, TQT_TQOBJECT(tqparent), "KileTemplate::Manager");
+ m_editorKeySequenceManager = new KileEditorKeySequence::Manager(this, TQT_TQOBJECT(tqparent), "KileEditorKeySequence::Manager");
+ TQObject::connect(m_docManager, TQT_SIGNAL(documentStatusChanged(Kate::Document*, bool, unsigned char)), m_viewManager, TQT_SLOT(reflectDocumenttqStatus(Kate::Document*, bool, unsigned char)));
}
KileInfo::~KileInfo()
@@ -67,10 +67,10 @@ Kate::Document * KileInfo::activeTextDocument() const
if (view) return view->getDoc(); else return 0L;
}
-QString KileInfo::getName(Kate::Document *doc, bool shrt)
+TQString KileInfo::getName(Kate::Document *doc, bool shrt)
{
KILE_DEBUG() << "===KileInfo::getName(Kate::Document *doc, bool " << shrt << ")===" << endl;
- QString title=QString::null;
+ TQString title=TQString();
if (!doc)
doc = activeTextDocument();
@@ -82,13 +82,13 @@ QString KileInfo::getName(Kate::Document *doc, bool shrt)
//reloading the file after is it changed on disc by another application
//cause the URL to be empty for a short while
if ( title.isEmpty() )
- title = shrt ? QFileInfo(doc->docName()).fileName() : doc->docName();
+ title = shrt ? TQFileInfo(doc->docName()).fileName() : doc->docName();
}
return title;
}
-QString KileInfo::getCompileName(bool shrt /* = false */)
+TQString KileInfo::getCompileName(bool shrt /* = false */)
{
KileProject *project = docManager()->activeProject();
@@ -112,7 +112,7 @@ QString KileInfo::getCompileName(bool shrt /* = false */)
else return url.path();
}
else
- return QString::null;
+ return TQString();
}
}
else
@@ -120,7 +120,7 @@ QString KileInfo::getCompileName(bool shrt /* = false */)
}
else
{
- QFileInfo fi(m_masterName);
+ TQFileInfo fi(m_masterName);
if (shrt)
return fi.fileName();
else
@@ -128,34 +128,34 @@ QString KileInfo::getCompileName(bool shrt /* = false */)
}
}
-QString KileInfo::getFullFromPrettyName(const QString & name)
+TQString KileInfo::getFullFromPrettyName(const TQString & name)
{
if(name.isNull())
return name;
- QString file = name;
+ TQString file = name;
if (file.left(2) == "./" )
{
- file = QFileInfo(outputFilter()->source()).dirPath(true) + '/' + file.mid(2);
+ file = TQFileInfo(outputFilter()->source()).dirPath(true) + '/' + file.mid(2);
}
if (file[0] != '/' )
{
- file = QFileInfo(outputFilter()->source()).dirPath(true) + '/' + file;
+ file = TQFileInfo(outputFilter()->source()).dirPath(true) + '/' + file;
}
- QFileInfo fi(file);
+ TQFileInfo fi(file);
if ( file.isNull() || fi.isDir() || (! fi.exists()) || (! fi.isReadable()))
{
// - call from logwidget or error handling, which
// tries to determine the LaTeX source file
bool found = false;
- QStringList extlist = QStringList::split( " ", m_extensions->latexDocuments() );
- for ( QStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
+ TQStringList extlist = TQStringList::split( " ", m_extensions->latexDocuments() );
+ for ( TQStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
{
- QString name = file + (*it);
- if ( QFileInfo(name).exists() )
+ TQString name = file + (*it);
+ if ( TQFileInfo(name).exists() )
{
file = name;
fi.setFile(name);
@@ -164,10 +164,10 @@ QString KileInfo::getFullFromPrettyName(const QString & name)
}
}
if ( ! found )
- file = QString::null;
+ file = TQString();
}
- if ( ! fi.isReadable() ) return QString::null;
+ if ( ! fi.isReadable() ) return TQString();
return file;
}
@@ -177,12 +177,12 @@ KURL::List KileInfo::getParentsFor(KileDocument::Info *info)
KileProjectItemList *items = docManager()->itemsFor(info);
KURL::List list;
for ( uint i = 0; i < items->count(); ++i)
- if (items->at(i)->parent()) list.append(items->at(i)->parent()->url());
+ if (items->at(i)->tqparent()) list.append(items->at(i)->tqparent()->url());
return list;
}
-const QStringList* KileInfo::retrieveList(const QStringList* (KileDocument::Info::*getit)() const, KileDocument::Info * docinfo /* = 0L */)
+const TQStringList* KileInfo::retrieveList(const TQStringList* (KileDocument::Info::*getit)() const, KileDocument::Info * docinfo /* = 0L */)
{
m_listTemp.clear();
@@ -198,16 +198,16 @@ const QStringList* KileInfo::retrieveList(const QStringList* (KileDocument::Info
{
KILE_DEBUG() << "\tusing root item " << root->url().fileName() << endl;
- QPtrList<KileProjectItem> children;
- children.append(root);
- root->allChildren(&children);
+ TQPtrList<KileProjectItem> tqchildren;
+ tqchildren.append(root);
+ root->allChildren(&tqchildren);
- const QStringList *list;
+ const TQStringList *list;
- for (uint i=0; i < children.count(); ++i)
+ for (uint i=0; i < tqchildren.count(); ++i)
{
- KILE_DEBUG() << "\t" << children.at(i)->url().fileName() << endl;
- list = (children.at(i)->getInfo()->*getit)();
+ KILE_DEBUG() << "\t" << tqchildren.at(i)->url().fileName() << endl;
+ list = (tqchildren.at(i)->getInfo()->*getit)();
if (list)
{
for (uint i=0; i < list->count(); ++i)
@@ -229,62 +229,62 @@ const QStringList* KileInfo::retrieveList(const QStringList* (KileDocument::Info
return &m_listTemp;
}
-const QStringList* KileInfo::allLabels(KileDocument::Info * info)
+const TQStringList* KileInfo::allLabels(KileDocument::Info * info)
{
KILE_DEBUG() << "Kile::allLabels()" << endl;
- const QStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::labels;
- const QStringList* list = retrieveList(p, info);
+ const TQStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::labels;
+ const TQStringList* list = retrieveList(p, info);
return list;
}
-const QStringList* KileInfo::allBibItems(KileDocument::Info * info)
+const TQStringList* KileInfo::allBibItems(KileDocument::Info * info)
{
KILE_DEBUG() << "Kile::allBibItems()" << endl;
- const QStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::bibItems;
- const QStringList* list = retrieveList(p, info);
+ const TQStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::bibItems;
+ const TQStringList* list = retrieveList(p, info);
return list;
}
-const QStringList* KileInfo::allBibliographies(KileDocument::Info * info)
+const TQStringList* KileInfo::allBibliographies(KileDocument::Info * info)
{
KILE_DEBUG() << "Kile::bibliographies()" << endl;
- const QStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::bibliographies;
- const QStringList* list = retrieveList(p, info);
+ const TQStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::bibliographies;
+ const TQStringList* list = retrieveList(p, info);
return list;
}
-const QStringList* KileInfo::allDependencies(KileDocument::Info * info)
+const TQStringList* KileInfo::allDependencies(KileDocument::Info * info)
{
KILE_DEBUG() << "Kile::dependencies()" << endl;
- const QStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::dependencies;
- const QStringList* list = retrieveList(p, info);
+ const TQStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::dependencies;
+ const TQStringList* list = retrieveList(p, info);
return list;
}
-const QStringList* KileInfo::allNewCommands(KileDocument::Info * info)
+const TQStringList* KileInfo::allNewCommands(KileDocument::Info * info)
{
KILE_DEBUG() << "Kile::newCommands()" << endl;
- const QStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::newCommands;
- const QStringList* list = retrieveList(p, info);
+ const TQStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::newCommands;
+ const TQStringList* list = retrieveList(p, info);
return list;
}
-const QStringList* KileInfo::allPackages(KileDocument::Info * info)
+const TQStringList* KileInfo::allPackages(KileDocument::Info * info)
{
KILE_DEBUG() << "Kile::allPackages()" << endl;
- const QStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::packages;
- const QStringList* list = retrieveList(p, info);
+ const TQStringList* (KileDocument::Info::*p)() const=&KileDocument::Info::packages;
+ const TQStringList* list = retrieveList(p, info);
return list;
}
-QString KileInfo::lastModifiedFile(KileDocument::Info * info)
+TQString KileInfo::lastModifiedFile(KileDocument::Info * info)
{
if (info == 0) info = docManager()->getInfo();
- const QStringList *list = allDependencies(info);
+ const TQStringList *list = allDependencies(info);
return info->lastModifiedFile(list);
}
-QString KileInfo::documentTypeToString(KileDocument::Type type)
+TQString KileInfo::documentTypeToString(KileDocument::Type type)
{
switch(type) {
case KileDocument::Undefined:
@@ -298,7 +298,7 @@ QString KileInfo::documentTypeToString(KileDocument::Type type)
case KileDocument::Script:
return i18n("Script");
}
- return QString();
+ return TQString();
}
bool KileInfo::similarOrEqualURL(const KURL &validurl, const KURL &testurl)
@@ -333,7 +333,7 @@ bool KileInfo::projectIsOpen(const KURL & url)
return project != 0 ;
}
-QString KileInfo::getSelection() const
+TQString KileInfo::getSelection() const
{
Kate::Document *doc = activeTextDocument();
@@ -342,7 +342,7 @@ QString KileInfo::getSelection() const
return doc->selection();
}
- return QString::null;
+ return TQString();
}
void KileInfo::clearSelection() const
@@ -355,23 +355,23 @@ void KileInfo::clearSelection() const
}
}
-QString KileInfo::expandEnvironmentVars(const QString &str)
+TQString KileInfo::expandEnvironmentVars(const TQString &str)
{
- static QRegExp reEnvVars("\\$(\\w+)");
- QString result = str;
+ static TQRegExp reEnvVars("\\$(\\w+)");
+ TQString result = str;
int index = -1;
- while ( (index = str.find(reEnvVars, index + 1)) != -1 )
- result.replace(reEnvVars.cap(0),getenv(reEnvVars.cap(1).local8Bit()));
+ while ( (index = str.tqfind(reEnvVars, index + 1)) != -1 )
+ result.tqreplace(reEnvVars.cap(0),getenv(reEnvVars.cap(1).local8Bit()));
return result;
}
-QString KileInfo::checkOtherPaths(const QString &path,const QString &file, int type)
+TQString KileInfo::checkOtherPaths(const TQString &path,const TQString &file, int type)
{
- KILE_DEBUG() << "QString KileInfo::checkOtherPaths(const QString &path,const QString &file, int type)" << endl;
- QStringList inputpaths;
- QString configpaths;
- QFileInfo info;
+ KILE_DEBUG() << "TQString KileInfo::checkOtherPaths(const TQString &path,const TQString &file, int type)" << endl;
+ TQStringList inputpaths;
+ TQString configpaths;
+ TQFileInfo info;
switch(type)
{
@@ -386,15 +386,15 @@ QString KileInfo::checkOtherPaths(const QString &path,const QString &file, int t
break;
default:
KILE_DEBUG() << "Unknown type in checkOtherPaths" << endl;
- return QString::null;
+ return TQString();
break;
}
- inputpaths = QStringList::split( ":", expandEnvironmentVars(configpaths));
+ inputpaths = TQStringList::split( ":", expandEnvironmentVars(configpaths));
inputpaths.prepend(path);
// the first match is supposed to be the correct one
- for ( QStringList::Iterator it = inputpaths.begin(); it != inputpaths.end(); ++it )
+ for ( TQStringList::Iterator it = inputpaths.begin(); it != inputpaths.end(); ++it )
{
KILE_DEBUG() << "path is " << *it << "and file is " << file << endl;
info.setFile((*it) + '/' + file);
@@ -404,20 +404,20 @@ QString KileInfo::checkOtherPaths(const QString &path,const QString &file, int t
return info.absFilePath();
}
}
- return QString::null;
+ return TQString();
}
-QString KileInfo::relativePath(const QString basepath, const QString & file)
+TQString KileInfo::relativePath(const TQString basepath, const TQString & file)
{
KURL url = KURL::fromPathOrURL(file);
- QString path = url.directory();
- QString filename = url.fileName();
+ TQString path = url.directory();
+ TQString filename = url.fileName();
KILE_DEBUG() <<"===findRelativeURL==================" << endl;
KILE_DEBUG() << "\tbasepath : " << basepath << " path: " << path << endl;
- QStringList basedirs = QStringList::split("/", basepath, false);
- QStringList dirs = QStringList::split("/", path, false);
+ TQStringList basedirs = TQStringList::split("/", basepath, false);
+ TQStringList dirs = TQStringList::split("/", path, false);
uint nDirs = dirs.count();
//uint nBaseDirs = basedirs.count();
diff --git a/src/kile/kileinfo.h b/src/kile/kileinfo.h
index 7bc4dea..b168daf 100644
--- a/src/kile/kileinfo.h
+++ b/src/kile/kileinfo.h
@@ -16,10 +16,10 @@
#ifndef KILEINFO_H
#define KILEINFO_H
-#include <qstring.h>
-#include <qptrlist.h>
-#include <qmap.h>
-#include <qscrollview.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
+#include <tqmap.h>
+#include <tqscrollview.h>
#include "kiledebug.h"
#include <kurl.h>
@@ -33,7 +33,7 @@
#include "latexcmd.h"
#include "kileconfig.h"
-class QWidget;
+class TQWidget;
namespace KileDocument { class Info; }
class KileProject;
@@ -58,40 +58,40 @@ class KileInfo
{
public:
- KileInfo(QWidget *parent);
+ KileInfo(TQWidget *tqparent);
virtual ~KileInfo();
public:
enum {bibinputs = 0,bstinputs, texinputs};
- QString getName(Kate::Document *doc = 0, bool shrt = false);
- QString getShortName(Kate::Document *doc = 0) { return getName(doc, true); }
- QString getCompileName(bool shrt = false);
- QString getFullFromPrettyName(const QString & name);
+ TQString getName(Kate::Document *doc = 0, bool shrt = false);
+ TQString getShortName(Kate::Document *doc = 0) { return getName(doc, true); }
+ TQString getCompileName(bool shrt = false);
+ TQString getFullFromPrettyName(const TQString & name);
KURL::List getParentsFor(KileDocument::Info *);
bool getSinglemode() { return m_singlemode; }
- QString getCurrentTarget() const { return m_currentTarget; }
- void setTarget(const QString &target) { m_currentTarget=target; }
+ TQString getCurrentTarget() const { return m_currentTarget; }
+ void setTarget(const TQString &target) { m_currentTarget=target; }
virtual Kate::Document* activeTextDocument() const;
- QString getSelection() const;
+ TQString getSelection() const;
void clearSelection() const;
- virtual const QStringList* allLabels(KileDocument::Info * info = 0L);
- virtual const QStringList* allBibItems(KileDocument::Info * info = 0L);
- virtual const QStringList* allBibliographies(KileDocument::Info * info = 0L);
- virtual const QStringList* allDependencies(KileDocument::Info * info = 0L);
- virtual const QStringList* allNewCommands(KileDocument::Info * info = 0L);
- virtual const QStringList* allPackages(KileDocument::Info * info = 0L);
+ virtual const TQStringList* allLabels(KileDocument::Info * info = 0L);
+ virtual const TQStringList* allBibItems(KileDocument::Info * info = 0L);
+ virtual const TQStringList* allBibliographies(KileDocument::Info * info = 0L);
+ virtual const TQStringList* allDependencies(KileDocument::Info * info = 0L);
+ virtual const TQStringList* allNewCommands(KileDocument::Info * info = 0L);
+ virtual const TQStringList* allPackages(KileDocument::Info * info = 0L);
- QString lastModifiedFile(KileDocument::Info * info = 0L);
+ TQString lastModifiedFile(KileDocument::Info * info = 0L);
- static QString documentTypeToString(KileDocument::Type type);
+ static TQString documentTypeToString(KileDocument::Type type);
private:
- const QStringList* retrieveList(const QStringList* (KileDocument::Info::*getit)() const, KileDocument::Info * docinfo = 0L);
- QStringList m_listTemp;
+ const TQStringList* retrieveList(const TQStringList* (KileDocument::Info::*getit)() const, KileDocument::Info * docinfo = 0L);
+ TQStringList m_listTemp;
public:
bool similarOrEqualURL(const KURL &validurl, const KURL &testurl);
@@ -107,7 +107,7 @@ public:
virtual int lineNumber() = 0;
- QString relativePath(const QString basepath, const QString & file);
+ TQString relativePath(const TQString basepath, const TQString & file);
KileWidget::Structure *structureWidget() { return m_kwStructure; }
KileWidget::Konsole *texKonsole() { return m_texKonsole; }
@@ -133,11 +133,11 @@ public:
KileFileSelect* fileSelector() const { return m_fileSelector; }
KileEventFilter* eventFilter() const { return m_eventFilter; }
- QWidget *parentWidget() const { return m_parentWidget; }
+ TQWidget *tqparentWidget() const { return m_parentWidget; }
- static QString expandEnvironmentVars(const QString &variable);
- static QString checkOtherPaths(const QString &path,const QString &file, int type);
- static QString checkOtherPaths(const KURL &url,const QString &file, int type){ return checkOtherPaths(url.path(),file, type); }
+ static TQString expandEnvironmentVars(const TQString &variable);
+ static TQString checkOtherPaths(const TQString &path,const TQString &file, int type);
+ static TQString checkOtherPaths(const KURL &url,const TQString &file, int type){ return checkOtherPaths(url.path(),file, type); }
protected:
KileDocument::Manager *m_docManager;
KileView::Manager *m_viewManager;
@@ -152,7 +152,7 @@ protected:
KileWidget::ScriptsManagement *m_scriptsManagementWidget;
KileBottomBar *m_bottomBar;
KileWidget::PreviewWidget *m_previewWidget;
- QScrollView *m_previewView;
+ TQScrollView *m_previewView;
KileHelp::Help *m_help;
KileDocument::EditorExtension *m_edit;
@@ -160,12 +160,12 @@ protected:
KileDocument::Extensions *m_extensions;
KileTool::QuickPreview *m_quickPreview;
- QWidget *m_parentWidget;
+ TQWidget *m_parentWidget;
bool m_singlemode;
- QString m_masterName;
+ TQString m_masterName;
- QString m_currentTarget;
+ TQString m_currentTarget;
bool m_bWatchFile, m_logPresent;
diff --git a/src/kile/kilejscript.cpp b/src/kile/kilejscript.cpp
index 7d18bf4..6a4656c 100644
--- a/src/kile/kilejscript.cpp
+++ b/src/kile/kilejscript.cpp
@@ -28,12 +28,12 @@
#include <signal.h>
#include <sys/time.h>
-#include <qevent.h>
-#include <qdir.h>
-#include <qfile.h>
-#include <qfileinfo.h>
-#include <qtextstream.h>
-#include <qvaluelist.h>
+#include <tqevent.h>
+#include <tqdir.h>
+#include <tqfile.h>
+#include <tqfileinfo.h>
+#include <tqtextstream.h>
+#include <tqvaluelist.h>
#include "kileconfig.h"
#include "kileedit.h"
@@ -90,19 +90,19 @@ namespace KJS {
// Copyright (C) 1999-2003 Harri Porten (porten@kde.org)
// Copyright (C) 2001-2003 David Faure (faure@kde.org)
// Copyright (C) 2003 Apple Computer, Inc.
- UString::UString(const QString &d) {
+ UString::UString(const TQString &d) {
unsigned int len = d.length();
UChar *dat = new UChar[len];
- memcpy(dat, d.unicode(), len * sizeof(UChar));
+ memcpy(dat, d.tqunicode(), len * sizeof(UChar));
rep = UString::Rep::create(dat, len);
}
- QString UString::qstring() const {
- return QString((QChar*) data(), size());
+ TQString UString::qstring() const {
+ return TQString((TQChar*) data(), size());
}
- QConstString UString::qconststring() const {
- return QConstString((QChar*) data(), size());
+ TQConstString UString::qconststring() const {
+ return TQConstString((TQChar*) data(), size());
}
}
@@ -252,7 +252,7 @@ KJS::Value KJS::KileJSObjectFunc::call(KJS::ExecState *exec, KJS::Object &thisOb
if(!kileInfo) {
return KJS::Undefined();
}
- QString caption, label, value;
+ TQString caption, label, value;
KileTextDocumentJSObject *kileViewJSObject;
Kate::View *kateView;
switch (id) {
@@ -275,7 +275,7 @@ KJS::Value KJS::KileJSObjectFunc::call(KJS::ExecState *exec, KJS::Object &thisOb
if(label.isEmpty()) {
label = i18n("Please enter a value");
}
- value = KInputDialog::getText(caption, label, QString(), 0, 0L);
+ value = KInputDialog::getText(caption, label, TQString(), 0, 0L);
return KJS::String(value);
break;
}
@@ -405,7 +405,7 @@ namespace KileJScript {
* after reloading all the scripts.
*/
- JScript::JScript(unsigned int id, const QString& file) : m_id(id), m_file(file), m_action(NULL) {
+ JScript::JScript(unsigned int id, const TQString& file) : m_id(id), m_file(file), m_action(NULL) {
m_name = KGlobal::dirs()->relativeLocation("appdata", file);
if(m_name.startsWith("scripts")) {
m_name = m_name.mid(8); // remove "scripts" + path separator
@@ -415,25 +415,25 @@ namespace KileJScript {
}
}
- QString JScript::getName() const {
+ TQString JScript::getName() const {
return m_name;
}
- QString JScript::getCode() const {
- QFile qFile(m_file);
+ TQString JScript::getCode() const {
+ TQFile qFile(m_file);
if(qFile.open(IO_ReadOnly)) {
- QTextStream inputStream(&qFile);
-// inputStream.setEncoding(QTextStream::UnicodeUTF8);
- QString code = inputStream.read();
+ TQTextStream inputStream(&qFile);
+// inputStream.setEncoding(TQTextStream::UnicodeUTF8);
+ TQString code = inputStream.read();
qFile.close();
return code;
}
else {
- return QString();
+ return TQString();
}
}
- QString JScript::getFileName() const {
+ TQString JScript::getFileName() const {
return m_file;
}
@@ -457,11 +457,11 @@ namespace KileJScript {
return m_action;
}
- void JScript::setKeySequence(const QString& str) {
+ void JScript::setKeySequence(const TQString& str) {
m_keySequence = str;
}
- QString JScript::getKeySequence() const {
+ TQString JScript::getKeySequence() const {
return m_keySequence;
}
@@ -479,7 +479,7 @@ namespace KileJScript {
delete m_interpreter;
}
- void JScriptEnvironment::execute(const QString& s) {
+ void JScriptEnvironment::execute(const TQString& s) {
bool useGuard = KileConfig::timeLimitEnabled();
uint timeLimit = (uint)KileConfig::timeLimit();
KJSCPUGuard guard;
@@ -497,24 +497,24 @@ namespace KileJScript {
if(o.isValid()) {
Value lineValue = o.get(m_interpreter->globalExec(), "line");
if(lineValue.type() == NumberType) {
- KMessageBox::sorry(0L, i18n("The following exception has occurred at line %1 during execution of the script:\n%2").arg(lineValue.toInt32(m_interpreter->globalExec())).arg(value.toString(m_interpreter->globalExec()).qstring()), i18n("Exception"));
+ KMessageBox::sorry(0L, i18n("The following exception has occurred at line %1 during execution of the script:\n%2").tqarg(lineValue.toInt32(m_interpreter->globalExec())).tqarg(value.toString(m_interpreter->globalExec()).qstring()), i18n("Exception"));
return;
}
}
}
- KMessageBox::sorry(0L, i18n("The following exception has occurred during execution of the script:\n%1").arg(value.toString(m_interpreter->globalExec()).qstring()), i18n("Exception"));
+ KMessageBox::sorry(0L, i18n("The following exception has occurred during execution of the script:\n%1").tqarg(value.toString(m_interpreter->globalExec()).qstring()), i18n("Exception"));
}
}
////////////////////////////// Manager //////////////////////////////
- Manager::Manager(KileInfo *kileInfo, KConfig *config, KActionCollection *actionCollection, QObject *parent, const char *name) : QObject(parent, name), m_jScriptDirWatch(NULL), m_kileInfo(kileInfo), m_config(config), m_actionCollection(actionCollection) {
+ Manager::Manager(KileInfo *kileInfo, KConfig *config, KActionCollection *actionCollection, TQObject *tqparent, const char *name) : TQObject(tqparent, name), m_jScriptDirWatch(NULL), m_kileInfo(kileInfo), m_config(config), m_actionCollection(actionCollection) {
// create a local scripts directory if it doesn't exist yet
m_localJScriptDir = locateLocal("appdata", "scripts/", true);
m_jScriptDirWatch = new KDirWatch(this, "KileJScript::Manager::JScriptDirWatch");
- connect(m_jScriptDirWatch, SIGNAL(dirty(const QString&)), this, SLOT(scanJScriptDirectories()));
- connect(m_jScriptDirWatch, SIGNAL(created(const QString&)), this, SLOT(scanJScriptDirectories()));
- connect(m_jScriptDirWatch, SIGNAL(deleted(const QString&)), this, SLOT(scanJScriptDirectories()));
+ connect(m_jScriptDirWatch, TQT_SIGNAL(dirty(const TQString&)), this, TQT_SLOT(scanJScriptDirectories()));
+ connect(m_jScriptDirWatch, TQT_SIGNAL(created(const TQString&)), this, TQT_SLOT(scanJScriptDirectories()));
+ connect(m_jScriptDirWatch, TQT_SIGNAL(deleted(const TQString&)), this, TQT_SLOT(scanJScriptDirectories()));
m_jScriptDirWatch->startScan();
}
@@ -522,29 +522,29 @@ namespace KileJScript {
delete m_jScriptDirWatch;
//still need to delete the scripts
- for(QValueList<JScript*>::iterator it = m_jScriptList.begin(); it != m_jScriptList.end(); ++it) {
+ for(TQValueList<JScript*>::iterator it = m_jScriptList.begin(); it != m_jScriptList.end(); ++it) {
delete *it;
}
}
void Manager::executeJScript(const JScript *script) {
JScriptEnvironment env(m_kileInfo);
-// demonstrate repainting bug:
+// demonstrate tqrepainting bug:
/*KMessageBox::information(0L, "works!!!");
m_kileInfo->viewManager()->currentView()->down();
m_kileInfo->viewManager()->currentView()->down();
m_kileInfo->viewManager()->currentView()->down();
m_kileInfo->viewManager()->currentView()->down();
m_kileInfo->viewManager()->currentView()->down();*/
- QString code = script->getCode();
- QRegExp endOfLineExp("(\r\n)|\n|\r");
- int i = code.find(endOfLineExp);
- QString firstLine = (i >= 0 ? code.left(i) : code);
- QRegExp requiredVersionTagExp("(kile-version:\\s*)(\\d+\\.\\d+(.\\d+)?)");
+ TQString code = script->getCode();
+ TQRegExp endOfLineExp("(\r\n)|\n|\r");
+ int i = code.tqfind(endOfLineExp);
+ TQString firstLine = (i >= 0 ? code.left(i) : code);
+ TQRegExp requiredVersionTagExp("(kile-version:\\s*)(\\d+\\.\\d+(.\\d+)?)");
if(requiredVersionTagExp.search(firstLine) != -1) {
- QString requiredKileVersion = requiredVersionTagExp.cap(2);
+ TQString requiredKileVersion = requiredVersionTagExp.cap(2);
if(compareVersionStrings(requiredKileVersion, kileFullVersion) > 0) {
- KMessageBox::sorry(0L, i18n("Version %1 of Kile is at least required to execute the script \"%2\". The execution has been aborted.").arg(requiredKileVersion).arg(script->getName()), i18n("Version Error"));
+ KMessageBox::sorry(0L, i18n("Version %1 of Kile is at least required to execute the script \"%2\". The execution has been aborted.").tqarg(requiredKileVersion).tqarg(script->getName()), i18n("Version Error"));
return;
}
}
@@ -552,14 +552,14 @@ m_kileInfo->viewManager()->currentView()->down();*/
}
void Manager::executeJScript(unsigned int id) {
- QMap<unsigned int, JScript*>::iterator i = m_idScriptMap.find(id);
+ TQMap<unsigned int, JScript*>::iterator i = m_idScriptMap.tqfind(id);
if(i != m_idScriptMap.end()) {
executeJScript(*i);
}
}
const JScript* Manager::getScript(unsigned int id) {
- QMap<unsigned int, JScript*>::iterator i = m_idScriptMap.find(id);
+ TQMap<unsigned int, JScript*>::iterator i = m_idScriptMap.tqfind(id);
return ((i != m_idScriptMap.end()) ? (*i) : NULL);
}
@@ -571,23 +571,23 @@ m_kileInfo->viewManager()->currentView()->down();*/
populateDirWatch();
m_config->setGroup("Scripts");
- QValueList<unsigned int> idList = readUnsignedIntListEntry("IDs");
+ TQValueList<unsigned int> idList = readUnsignedIntListEntry("IDs");
unsigned int maxID = 0;
- QMap<QString, unsigned int> pathIDMap;
- QMap<unsigned int, bool> takenIDMap;
- for(QValueList<unsigned int>::iterator i = idList.begin(); i != idList.end(); ++i) {
- QString fileName = m_config->readPathEntry("Script" + QString::number(*i));
+ TQMap<TQString, unsigned int> pathIDMap;
+ TQMap<unsigned int, bool> takenIDMap;
+ for(TQValueList<unsigned int>::iterator i = idList.begin(); i != idList.end(); ++i) {
+ TQString fileName = m_config->readPathEntry("Script" + TQString::number(*i));
if(!fileName.isEmpty()) {
unsigned int id = *i;
pathIDMap[fileName] = id;
takenIDMap[id] = true;
- maxID = QMAX(maxID, id);
+ maxID = TQMAX(maxID, id);
}
}
- m_config->setGroup(QString());
+ m_config->setGroup(TQString());
- QStringList scriptFileNamesList = KGlobal::dirs()->findAllResources("appdata", "scripts/*.js", true, true);
- for(QStringList::iterator i = scriptFileNamesList.begin(); i != scriptFileNamesList.end(); ++i) {
+ TQStringList scriptFileNamesList = KGlobal::dirs()->findAllResources("appdata", "scripts/*.js", true, true);
+ for(TQStringList::iterator i = scriptFileNamesList.begin(); i != scriptFileNamesList.end(); ++i) {
registerScript(*i, pathIDMap, takenIDMap, maxID);
}
//rewrite the IDs that are currently in use
@@ -597,15 +597,15 @@ m_kileInfo->viewManager()->currentView()->down();*/
}
void Manager::deleteJScripts() {
- QValueList<JScript*> scriptList = m_jScriptList;
+ TQValueList<JScript*> scriptList = m_jScriptList;
m_jScriptList.clear(); // pretend that there are no scripts left
- QStringList keySequenceList;
- for(QValueList<JScript*>::iterator it = scriptList.begin(); it != scriptList.end(); ++it) {
+ TQStringList keySequenceList;
+ for(TQValueList<JScript*>::iterator it = scriptList.begin(); it != scriptList.end(); ++it) {
keySequenceList.push_back((*it)->getKeySequence());
}
m_idScriptMap.clear();
m_kileInfo->editorKeySequenceManager()->removeKeySequence(keySequenceList);
- for(QValueList<JScript*>::iterator it = scriptList.begin(); it != scriptList.end(); ++it) {
+ for(TQValueList<JScript*>::iterator it = scriptList.begin(); it != scriptList.end(); ++it) {
KAction *action = (*it)->getActionObject();
if(action) {
action->unplugAll();
@@ -616,13 +616,13 @@ m_kileInfo->viewManager()->currentView()->down();*/
emit jScriptsChanged();
}
- QValueList<JScript*> Manager::getJScripts() {
+ TQValueList<JScript*> Manager::getJScripts() {
return m_jScriptList;
}
- void Manager::registerScript(const QString& fileName, QMap<QString, unsigned int>& pathIDMap, QMap<unsigned int, bool>& takenIDMap, unsigned int &maxID) {
+ void Manager::registerScript(const TQString& fileName, TQMap<TQString, unsigned int>& pathIDMap, TQMap<unsigned int, bool>& takenIDMap, unsigned int &maxID) {
unsigned int id;
- QMap<QString, unsigned int>::iterator it = pathIDMap.find(fileName);
+ TQMap<TQString, unsigned int>::iterator it = pathIDMap.tqfind(fileName);
if(it != pathIDMap.end()) {
id = *it;
}
@@ -630,15 +630,15 @@ m_kileInfo->viewManager()->currentView()->down();*/
id = findFreeID(takenIDMap, maxID);
pathIDMap[fileName] = id;
takenIDMap[id] = true;
- maxID = QMAX(maxID, id);
+ maxID = TQMAX(maxID, id);
}
JScript* script = new JScript(id, fileName);
m_jScriptList.push_back(script);
m_idScriptMap[id] = script;
// start with setting up the key sequence
m_config->setGroup("Scripts");
- QString editorKeySequence = m_config->readEntry("Script" + QString::number(id) + "KeySequence");
- m_config->setGroup(QString());
+ TQString editorKeySequence = m_config->readEntry("Script" + TQString::number(id) + "KeySequence");
+ m_config->setGroup(TQString());
if(!editorKeySequence.isEmpty()) {
script->setKeySequence(editorKeySequence);
m_kileInfo->editorKeySequenceManager()->addAction(editorKeySequence, new KileEditorKeySequence::ExecuteJScriptAction(script, this));
@@ -657,18 +657,18 @@ m_kileInfo->viewManager()->currentView()->down();*/
writeIDs();
// write the key sequences
m_config->setGroup("Scripts");
- for(QValueList<JScript*>::iterator i = m_jScriptList.begin(); i != m_jScriptList.end(); ++i) {
- m_config->writeEntry("Script" + QString::number((*i)->getID()) + "KeySequence", (*i)->getKeySequence());
+ for(TQValueList<JScript*>::iterator i = m_jScriptList.begin(); i != m_jScriptList.end(); ++i) {
+ m_config->writeEntry("Script" + TQString::number((*i)->getID()) + "KeySequence", (*i)->getKeySequence());
}
- m_config->setGroup(QString());
+ m_config->setGroup(TQString());
}
- void Manager::setEditorKeySequence(JScript* script, const QString& keySequence) {
+ void Manager::setEditorKeySequence(JScript* script, const TQString& keySequence) {
if(keySequence.isEmpty()) {
return;
}
if(script) {
- QString oldSequence = script->getKeySequence();
+ TQString oldSequence = script->getKeySequence();
if(oldSequence == keySequence) {
return;
}
@@ -681,28 +681,28 @@ m_kileInfo->viewManager()->currentView()->down();*/
void Manager::removeEditorKeySequence(JScript* script) {
if(script) {
- QString keySequence = script->getKeySequence();
+ TQString keySequence = script->getKeySequence();
if(keySequence.isEmpty()) {
return;
}
- script->setKeySequence(QString());
+ script->setKeySequence(TQString());
m_kileInfo->editorKeySequenceManager()->removeKeySequence(keySequence);
writeConfig();
}
}
void Manager::populateDirWatch() {
- QStringList jScriptDirectories = KGlobal::dirs()->findDirs("appdata", "scripts");
- for(QStringList::iterator i = jScriptDirectories.begin(); i != jScriptDirectories.end(); ++i) {
+ TQStringList jScriptDirectories = KGlobal::dirs()->findDirs("appdata", "scripts");
+ for(TQStringList::iterator i = jScriptDirectories.begin(); i != jScriptDirectories.end(); ++i) {
// FIXME: future KDE versions could support the recursive
// watching of directories out of the box.
addDirectoryToDirWatch(*i);
}
- //we do not remove the directories that were once added as this apparently causes some strange
+ //we do not remove the directories that were once added as this aptqparently causes some strange
//bugs (on KDE 3.5.x)
}
- QString Manager::getLocalJScriptDirectory() const {
+ TQString Manager::getLocalJScriptDirectory() const {
return m_localJScriptDir;
}
@@ -711,30 +711,30 @@ m_kileInfo->viewManager()->currentView()->down();*/
scanJScriptDirectories();
}
- QValueList<unsigned int> Manager::readUnsignedIntListEntry(const QString& key) {
- QValueList<unsigned int> toReturn;
- QStringList stringList = m_config->readListEntry(key);
- for(QStringList::iterator i = stringList.begin(); i != stringList.end(); ++i) {
+ TQValueList<unsigned int> Manager::readUnsignedIntListEntry(const TQString& key) {
+ TQValueList<unsigned int> toReturn;
+ TQStringList stringList = m_config->readListEntry(key);
+ for(TQStringList::iterator i = stringList.begin(); i != stringList.end(); ++i) {
toReturn.push_back((*i).toUInt());
}
return toReturn;
}
- void Manager::writeEntry(const QString& key, const QValueList<unsigned int>& l) {
- QStringList stringList;
- for(QValueList<unsigned int>::const_iterator i = l.begin(); i != l.end(); ++i) {
- stringList.push_back(QString::number(*i));
+ void Manager::writeEntry(const TQString& key, const TQValueList<unsigned int>& l) {
+ TQStringList stringList;
+ for(TQValueList<unsigned int>::const_iterator i = l.begin(); i != l.end(); ++i) {
+ stringList.push_back(TQString::number(*i));
}
m_config->writeEntry(key, stringList);
}
- unsigned int Manager::findFreeID(const QMap<unsigned int, bool>& takenIDMap, unsigned int maxID) {
+ unsigned int Manager::findFreeID(const TQMap<unsigned int, bool>& takenIDMap, unsigned int maxID) {
if(takenIDMap.size() == 0) {
return 0;
}
// maxID should have a real meaning now
for(unsigned int i = 0; i < maxID; ++i) {
- if(takenIDMap.find(i) == takenIDMap.end()) {
+ if(takenIDMap.tqfind(i) == takenIDMap.end()) {
return i;
}
}
@@ -744,31 +744,31 @@ m_kileInfo->viewManager()->currentView()->down();*/
void Manager::writeIDs() {
m_config->setGroup("Scripts");
//delete old entries
- QValueList<unsigned int> idList = readUnsignedIntListEntry("IDs");
- for(QValueList<unsigned int>::iterator i = idList.begin(); i != idList.end(); ++i) {
- m_config->deleteEntry("Script" + QString::number(*i));
+ TQValueList<unsigned int> idList = readUnsignedIntListEntry("IDs");
+ for(TQValueList<unsigned int>::iterator i = idList.begin(); i != idList.end(); ++i) {
+ m_config->deleteEntry("Script" + TQString::number(*i));
}
//write new ones
idList.clear();
- for(QMap<unsigned int, JScript*>::iterator i = m_idScriptMap.begin(); i != m_idScriptMap.end(); ++i) {
+ for(TQMap<unsigned int, JScript*>::iterator i = m_idScriptMap.begin(); i != m_idScriptMap.end(); ++i) {
unsigned int id = i.key();
idList.push_back(id);
- m_config->writePathEntry("Script" + QString::number(id), (*i)->getFileName());
+ m_config->writePathEntry("Script" + TQString::number(id), (*i)->getFileName());
}
writeEntry("IDs", idList);
- m_config->setGroup(QString());
+ m_config->setGroup(TQString());
}
- void Manager::addDirectoryToDirWatch(const QString& dir) {
+ void Manager::addDirectoryToDirWatch(const TQString& dir) {
//FIXME: no recursive watching and no watching of files as it isn't implemented
// yet
if(!m_jScriptDirWatch->contains(dir)) {
m_jScriptDirWatch->addDir(dir, false, false);
}
- QDir qDir(dir);
- QStringList list = qDir.entryList(QDir::Dirs);
- for(QStringList::iterator i = list.begin(); i != list.end(); ++i) {
- QString subdir = *i;
+ TQDir qDir(dir);
+ TQStringList list = qDir.entryList(TQDir::Dirs);
+ for(TQStringList::iterator i = list.begin(); i != list.end(); ++i) {
+ TQString subdir = *i;
if(subdir != "." && subdir != "..") {
addDirectoryToDirWatch(qDir.filePath(subdir));
}
@@ -776,11 +776,11 @@ m_kileInfo->viewManager()->currentView()->down();*/
}
////////////////////////////// ScriptExecutionAction //////////////////////////////
- ScriptExecutionAction::ScriptExecutionAction(unsigned int id, KileJScript::Manager *manager, KActionCollection* parent) : KAction(QString(), KShortcut(), NULL, NULL, parent, QString("script_execution_" + QString::number(id)).ascii()), m_manager(manager), m_id(id) {
+ ScriptExecutionAction::ScriptExecutionAction(unsigned int id, KileJScript::Manager *manager, KActionCollection* tqparent) : KAction(TQString(), KShortcut(), NULL, NULL, tqparent, TQString("script_execution_" + TQString::number(id)).ascii()), m_manager(manager), m_id(id) {
const KileJScript::JScript *script = m_manager->getScript(m_id);
Q_ASSERT(script);
- setText(i18n("Execution of %1").arg(script->getName()));
- connect(this, SIGNAL(activated()), this, SLOT(executeScript()));
+ setText(i18n("Execution of %1").tqarg(script->getName()));
+ connect(this, TQT_SIGNAL(activated()), this, TQT_SLOT(executeScript()));
}
ScriptExecutionAction::~ScriptExecutionAction() {
diff --git a/src/kile/kilejscript.h b/src/kile/kilejscript.h
index 6ac133a..f5082db 100644
--- a/src/kile/kilejscript.h
+++ b/src/kile/kilejscript.h
@@ -14,8 +14,8 @@
#ifndef KILEJSCRIPT_H
#define KILEJSCRIPT_H
-#include <qmap.h>
-#include <qobject.h>
+#include <tqmap.h>
+#include <tqobject.h>
#include <kjs/interpreter.h>
#include <kjs/object.h>
@@ -24,8 +24,8 @@
#include <kconfig.h>
#include <kdirwatch.h>
-#include <qvaluelist.h>
-#include <qvaluevector.h>
+#include <tqvaluelist.h>
+#include <tqvaluevector.h>
class KileInfo;
@@ -40,23 +40,23 @@ class JScript {
* Constructs a new JavaScript script.
* @param file the file that contains the script
**/
- JScript(unsigned int id, const QString& file);
+ JScript(unsigned int id, const TQString& file);
/**
* Returns the code of this script, i.e. the file is read and its contents are
* returned.
**/
- QString getCode() const;
+ TQString getCode() const;
/**
* Returns the name of the script (the base name of the file).
**/
- QString getName() const;
+ TQString getName() const;
/**
* Returns the file of the script (the full path, including the base name).
**/
- QString getFileName() const;
+ TQString getFileName() const;
/**
* Returns the unique identifier of this script.
@@ -78,16 +78,16 @@ class JScript {
KAction* getActionObject();
- void setKeySequence(const QString& str);
- QString getKeySequence() const;
+ void setKeySequence(const TQString& str);
+ TQString getKeySequence() const;
protected:
unsigned int m_id;
- QString m_code;
- QString m_file;
- QString m_name;
+ TQString m_code;
+ TQString m_file;
+ TQString m_name;
KAction *m_action;
- QString m_keySequence;
+ TQString m_keySequence;
};
/**
@@ -106,7 +106,7 @@ class JScriptEnvironment {
* Executes JavaScript code in this environment.
* @param c the code that should be executed
**/
- void execute(const QString& c);
+ void execute(const TQString& c);
protected:
KJS::Interpreter *m_interpreter;
@@ -117,14 +117,15 @@ class JScriptEnvironment {
/**
* This class handles the scripting functionality in Kile.
**/
-class Manager : public QObject {
+class Manager : public TQObject {
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructs a new Manager object.
**/
- Manager(KileInfo *info, KConfig *config, KActionCollection *actionCollection, QObject *parent = 0, const char *name = 0);
+ Manager(KileInfo *info, KConfig *config, KActionCollection *actionCollection, TQObject *tqparent = 0, const char *name = 0);
virtual ~Manager();
/**
@@ -142,7 +143,7 @@ class Manager : public QObject {
/**
* Retrieves a list of all the scripts that are currently available.
**/
- QValueList<JScript*> getJScripts();
+ TQValueList<JScript*> getJScripts();
/**
* Writes the key sequence-to-script bindings to the KConfig object that has
@@ -156,7 +157,7 @@ class Manager : public QObject {
* @param script the script that is considered
* @param keySequence the key sequence that is assigned
**/
- void setEditorKeySequence(JScript* script, const QString& keySequence);
+ void setEditorKeySequence(JScript* script, const TQString& keySequence);
/**
* Removes an assigned key sequence from a script.
@@ -168,7 +169,7 @@ class Manager : public QObject {
* Returns the directory that can be used by the used to store Kile's scripts.
* Usually $HOME/.kde/share/apps/kile/scripts
**/
- QString getLocalJScriptDirectory() const;
+ TQString getLocalJScriptDirectory() const;
/**
* Returns the script object that corresponds to a script id.
@@ -199,9 +200,9 @@ class Manager : public QObject {
void readConfig();
protected:
- QString m_localJScriptDir;
- QValueList<JScript*> m_jScriptList;
- QMap<unsigned int, JScript*> m_idScriptMap;
+ TQString m_localJScriptDir;
+ TQValueList<JScript*> m_jScriptList;
+ TQMap<unsigned int, JScript*> m_idScriptMap;
KDirWatch *m_jScriptDirWatch;
KileInfo *m_kileInfo;
@@ -212,7 +213,7 @@ class Manager : public QObject {
* Registers the script contained in a file.
* @param fileName the file that contains the script
**/
- void registerScript(const QString& fileName, QMap<QString, unsigned int>& pathIDMap, QMap<unsigned int, bool>& takenIDMap, unsigned int &maxID);
+ void registerScript(const TQString& fileName, TQMap<TQString, unsigned int>& pathIDMap, TQMap<unsigned int, bool>& takenIDMap, unsigned int &maxID);
/**
* (Re-)Creates and initialises the KDirWatch object.
@@ -229,7 +230,7 @@ class Manager : public QObject {
* object.
* @param key the considered entry key
**/
- QValueList<unsigned int> readUnsignedIntListEntry(const QString& key);
+ TQValueList<unsigned int> readUnsignedIntListEntry(const TQString& key);
/**
* Writes a key - value pair to the local KConfig object for the case that the
@@ -237,7 +238,7 @@ class Manager : public QObject {
* @param key the considered entry key
* @param l the 'unsigned int' list that is used as value
**/
- void writeEntry(const QString& key, const QValueList<unsigned int>& l);
+ void writeEntry(const TQString& key, const TQValueList<unsigned int>& l);
/**
* Finds the next free ID.
@@ -245,7 +246,7 @@ class Manager : public QObject {
* @param maxID the maximum ID that is currently in use (if there is no ID assigned, then
* any value can be passed here, but typically '0')
**/
- unsigned int findFreeID(const QMap<unsigned int, bool>& takenIDMap, unsigned int maxID);
+ unsigned int findFreeID(const TQMap<unsigned int, bool>& takenIDMap, unsigned int maxID);
/**
* Writes the ID to file name mappings that are currently in use to the local
@@ -258,14 +259,15 @@ class Manager : public QObject {
* Recursively adds a directory to a KDirWatch object.
* @param dir the directory that should be added
**/
- void addDirectoryToDirWatch(const QString& dir);
+ void addDirectoryToDirWatch(const TQString& dir);
};
class ScriptExecutionAction : public KAction {
Q_OBJECT
+ TQ_OBJECT
public:
- ScriptExecutionAction(unsigned int scriptID, Manager *manager, KActionCollection* parent = 0);
+ ScriptExecutionAction(unsigned int scriptID, Manager *manager, KActionCollection* tqparent = 0);
virtual ~ScriptExecutionAction();
diff --git a/src/kile/kilekonsolewidget.cpp b/src/kile/kilekonsolewidget.cpp
index 3a72073..effcc6f 100644
--- a/src/kile/kilekonsolewidget.cpp
+++ b/src/kile/kilekonsolewidget.cpp
@@ -16,8 +16,8 @@
#include "kilekonsolewidget.h"
#include "kileinfo.h"
-#include <qfileinfo.h>
-#include <qframe.h>
+#include <tqfileinfo.h>
+#include <tqframe.h>
#include <klocale.h>
#include <klibloader.h>
@@ -30,8 +30,8 @@
namespace KileWidget
{
- Konsole::Konsole(KileInfo * info, QWidget *parent, const char *name) :
- QVBox(parent, name),
+ Konsole::Konsole(KileInfo * info, TQWidget *tqparent, const char *name) :
+ TQVBox(tqparent, name),
m_bPresent(false),
m_ki(info)
{
@@ -47,15 +47,15 @@ namespace KileWidget
KLibFactory *factory = KLibLoader::self()->factory("libkonsolepart");
if (!factory) return;
- m_part = (KParts::ReadOnlyPart *) factory->create(this);
+ m_part = (KParts::ReadOnlyPart *) factory->create(TQT_TQOBJECT(this));
if (!m_part) return;
- if (m_part->widget()->inherits("QFrame"))
- ((QFrame*)m_part->widget())->setFrameStyle(QFrame::Panel|QFrame::Sunken);
+ if (m_part->widget()->inherits(TQFRAME_OBJECT_NAME_STRING))
+ ((TQFrame*)m_part->widget())->setFrameStyle(TQFrame::Panel|TQFrame::Sunken);
m_bPresent=true;
- connect ( m_part, SIGNAL(destroyed()), this, SLOT(slotDestroyed()) );
+ connect ( m_part, TQT_SIGNAL(destroyed()), this, TQT_SLOT(slotDestroyed()) );
m_part->widget()->show();
show();
@@ -72,12 +72,12 @@ namespace KileWidget
if (view)
{
- QString finame;
+ TQString finame;
KURL url = view->getDoc()->url();
if ( url.path().isEmpty() || KileUntitled::isUntitled(url.path()) ) return;
- QFileInfo fic(url.directory());
+ TQFileInfo fic(url.directory());
if ( fic.isReadable() )
{
setDirectory(url.directory());
@@ -88,7 +88,7 @@ namespace KileWidget
}
}
- void Konsole::setDirectory(const QString &dirname)
+ void Konsole::setDirectory(const TQString &dirname)
{
if (m_bPresent)
{
@@ -98,9 +98,9 @@ namespace KileWidget
}
}
- void Konsole::showEvent(QShowEvent *ev)
+ void Konsole::showEvent(TQShowEvent *ev)
{
- QWidget::showEvent(ev);
+ TQWidget::showEvent(ev);
activate();
}
diff --git a/src/kile/kilekonsolewidget.h b/src/kile/kilekonsolewidget.h
index 05d404e..d673f7b 100644
--- a/src/kile/kilekonsolewidget.h
+++ b/src/kile/kilekonsolewidget.h
@@ -21,23 +21,24 @@
@author Jeroen Wijnhout
*/
-#include <qvbox.h>
+#include <tqvbox.h>
namespace KParts { class ReadOnlyPart; }
class KileInfo;
namespace KileWidget
{
- class Konsole : public QVBox
+ class Konsole : public TQVBox
{
Q_OBJECT
+ TQ_OBJECT
public:
- Konsole(KileInfo *, QWidget* parent, const char* name=0);
+ Konsole(KileInfo *, TQWidget* tqparent, const char* name=0);
~Konsole();
public slots:
- void setDirectory(const QString & dir);
+ void setDirectory(const TQString & dir);
void activate();
void sync();
@@ -45,7 +46,7 @@ namespace KileWidget
void slotDestroyed();
protected:
- void showEvent(QShowEvent *ev);
+ void showEvent(TQShowEvent *ev);
void spawn();
private:
diff --git a/src/kile/kilelauncher.cpp b/src/kile/kilelauncher.cpp
index 91dced5..fec6c92 100644
--- a/src/kile/kilelauncher.cpp
+++ b/src/kile/kilelauncher.cpp
@@ -22,9 +22,9 @@
#include "docpart.h"
#include "kileconfig.h"
-#include <qwidgetstack.h>
-#include <qregexp.h>
-#include <qfileinfo.h>
+#include <tqwidgetstack.h>
+#include <tqregexp.h>
+#include <tqfileinfo.h>
#include "kiledebug.h"
#include <krun.h>
@@ -49,9 +49,9 @@
}
ProcessLauncher::ProcessLauncher(const char * shellname /* =0 */) :
- m_wd(QString::null),
- m_cmd(QString::null),
- m_options(QString::null),
+ m_wd(TQString()),
+ m_cmd(TQString()),
+ m_options(TQString()),
m_texinputs(KileConfig::teXPaths()),
m_bibinputs(KileConfig::bibInputPaths()),
m_bstinputs(KileConfig::bstInputPaths()),
@@ -65,9 +65,9 @@
else
KILE_DEBUG() << "\tNO KShellProcess created" << endl;
- connect(m_proc, SIGNAL( receivedStdout(KProcess*, char*, int) ), this, SLOT(slotProcessOutput(KProcess*, char*, int ) ) );
- connect(m_proc, SIGNAL( receivedStderr(KProcess*, char*, int) ),this, SLOT(slotProcessOutput(KProcess*, char*, int ) ) );
- connect(m_proc, SIGNAL( processExited(KProcess*)), this, SLOT(slotProcessExited(KProcess*)));
+ connect(m_proc, TQT_SIGNAL( receivedStdout(KProcess*, char*, int) ), this, TQT_SLOT(slotProcessOutput(KProcess*, char*, int ) ) );
+ connect(m_proc, TQT_SIGNAL( receivedStderr(KProcess*, char*, int) ),this, TQT_SLOT(slotProcessOutput(KProcess*, char*, int ) ) );
+ connect(m_proc, TQT_SIGNAL( processExited(KProcess*)), this, TQT_SLOT(slotProcessExited(KProcess*)));
}
ProcessLauncher::~ProcessLauncher()
@@ -76,7 +76,7 @@
delete m_proc;
}
- void ProcessLauncher::setWorkingDirectory(const QString &wd)
+ void ProcessLauncher::setWorkingDirectory(const TQString &wd)
{
m_wd = wd;
}
@@ -86,7 +86,7 @@
KILE_DEBUG() << "KileTool::ProcessLauncher::launch()=================" << endl;
KILE_DEBUG() << "\tbelongs to tool " << tool()->name() << endl;
- QString msg, out = "*****\n***** " + tool()->name() + i18n(" output: \n");
+ TQString msg, out = "*****\n***** " + tool()->name() + i18n(" output: \n");
if ( m_cmd.isNull() )
m_cmd = tool()->readEntry("command");
@@ -97,20 +97,20 @@
if ( m_changeTo && (!m_wd.isNull()) )
{
m_proc->setWorkingDirectory(m_wd);
- out += QString("***** cd '")+ m_wd +QString("'\n");
+ out += TQString("***** cd '")+ m_wd +TQString("'\n");
}
- QString str;
+ TQString str;
tool()->translate(m_cmd);
tool()->translate(m_options);
*m_proc << m_cmd << m_options;
if (m_proc)
{
- out += QString("***** ")+ m_cmd+ ' ' + m_options + '\n';
+ out += TQString("***** ")+ m_cmd+ ' ' + m_options + '\n';
- QString src = tool()->source(false);
- QString trgt = tool()->target();
+ TQString src = tool()->source(false);
+ TQString trgt = tool()->target();
if (src == trgt)
msg = src;
else
@@ -167,20 +167,20 @@
{
emit(message(Error, i18n("Launching failed, diagnostics:")));
- QString exe = KRun::binaryName(tool()->readEntry("command"), false);
- QString path = KGlobal::dirs()->findExe(exe, QString::null, true);
+ TQString exe = KRun::binaryName(tool()->readEntry("command"), false);
+ TQString path = KGlobal::dirs()->findExe(exe, TQString(), true);
if ( path.isNull() )
{
- emit(message(Error, i18n("There is no executable named \"%1\" in your path.").arg(exe)));
+ emit(message(Error, i18n("There is no executable named \"%1\" in your path.").tqarg(exe)));
return false;
}
else
{
- QFileInfo fi(path);
+ TQFileInfo fi(path);
if ( ! fi.isExecutable() )
{
- emit(message(Error, i18n("You do not have permission to run %1.").arg(path)));
+ emit(message(Error, i18n("You do not have permission to run %1.").tqarg(path)));
return false;
}
}
@@ -191,7 +191,7 @@
void ProcessLauncher::slotProcessOutput(KProcess*, char* buf, int len)
{
- emit output(QString::fromLocal8Bit(buf, len));
+ emit output(TQString::fromLocal8Bit(buf, len));
}
void ProcessLauncher::slotProcessExited(KProcess*)
@@ -208,7 +208,7 @@
if (m_proc->exitStatus() != 0)
{
type = Error;
- emit(message(type,i18n("finished with exit status %1").arg(m_proc->exitStatus())));
+ emit(message(type,i18n("finished with exit status %1").tqarg(m_proc->exitStatus())));
}
if (type == Info)
@@ -236,8 +236,8 @@
bool KonsoleLauncher::launch()
{
- QString cmd = tool()->readEntry("command");
- QString noclose = (tool()->readEntry("close") == "no") ? "--noclose" : "";
+ TQString cmd = tool()->readEntry("command");
+ TQString noclose = (tool()->readEntry("close") == "no") ? "--noclose" : "";
setCommand("konsole");
setOptions(noclose + " -T \"" + cmd + " (Kile)\" -e " + cmd + ' ' + tool()->readEntry("options"));
@@ -252,7 +252,7 @@
m_name(name),
m_libName(0L),
m_className(0L),
- m_options(QString::null)
+ m_options(TQString())
{
}
@@ -268,13 +268,13 @@
m_options=tool()->readEntry("libOptions");
m_state=tool()->readEntry("state");
- QString msg, out = "*****\n***** " + tool()->name() + i18n(" output: \n");
+ TQString msg, out = "*****\n***** " + tool()->name() + i18n(" output: \n");
- QString shrt = "%target";
+ TQString shrt = "%target";
tool()->translate(shrt);
- QString dir = "%dir_target"; tool()->translate(dir);
+ TQString dir = "%dir_target"; tool()->translate(dir);
- QString name = shrt;
+ TQString name = shrt;
if ( dir[0] == '/' )
name = dir + '/' + shrt;
@@ -282,24 +282,24 @@
KLibFactory *factory = KLibLoader::self()->factory(m_libName);
if (factory == 0)
{
- emit(message(Error, i18n("Could not find the %1 library.").arg(m_libName)));
+ emit(message(Error, i18n("Could not find the %1 library.").tqarg(m_libName)));
return false;
}
- QWidgetStack *stack = tool()->manager()->widgetStack();
+ TQWidgetStack *stack = tool()->manager()->widgetStack();
KParts::PartManager *pm = tool()->manager()->partManager();
- m_part = (KParts::ReadOnlyPart *)factory->create(stack, m_libName, m_className, m_options);
+ m_part = (KParts::ReadOnlyPart *)factory->create(TQT_TQOBJECT(stack), m_libName, m_className, m_options);
if (m_part == 0)
{
- emit(message(Error, i18n("Could not create component %1 from the library %2.").arg(m_className).arg(m_libName)));
+ emit(message(Error, i18n("Could not create component %1 from the library %2.").tqarg(m_className).tqarg(m_libName)));
emit(done(Failed));
return false;
}
else
{
- QString cmd = QString(m_libName) + "->" + QString(m_className) + ' ' + m_options + ' ' + name;
+ TQString cmd = TQString(m_libName) + "->" + TQString(m_className) + ' ' + m_options + ' ' + name;
out += "***** " + cmd + '\n';
msg = shrt+ " (" + tool()->readEntry("libName") + ')';
@@ -332,23 +332,23 @@
{
m_state=tool()->readEntry("state");
- QString shrt = "%target";
+ TQString shrt = "%target";
tool()->translate(shrt);
- QString name="%dir_target/%target";
+ TQString name="%dir_target/%target";
tool()->translate(name);
- QString out = "*****\n***** " + tool()->name() + i18n(" output: \n") + "***** KHTML " + name + "\n*****\n";
- QString msg = shrt+ " (KHTML)";
+ TQString out = "*****\n***** " + tool()->name() + i18n(" output: \n") + "***** KHTML " + name + "\n*****\n";
+ TQString msg = shrt+ " (KHTML)";
emit(message(Info, msg));
emit(output(out));
- QWidgetStack *stack = tool()->manager()->widgetStack();
+ TQWidgetStack *stack = tool()->manager()->widgetStack();
KParts::PartManager *pm = tool()->manager()->partManager();
DocumentationViewer *htmlpart = new DocumentationViewer(stack,"help");
m_part = static_cast<KParts::ReadOnlyPart*>(htmlpart);
- connect(htmlpart, SIGNAL(updateStatus(bool, bool)), tool(), SIGNAL(updateStatus(bool, bool)));
+ connect(htmlpart, TQT_SIGNAL(updatetqStatus(bool, bool)), tool(), TQT_SIGNAL(updatetqStatus(bool, bool)));
tool()->manager()->wantGUIState(m_state);
diff --git a/src/kile/kilelauncher.h b/src/kile/kilelauncher.h
index 866ba2c..e1f2e1d 100644
--- a/src/kile/kilelauncher.h
+++ b/src/kile/kilelauncher.h
@@ -16,11 +16,11 @@
#ifndef KILE_LAUNCHER
#define KILE_LAUNCHER
-#include <qobject.h>
-#include <qdict.h>
-#include <qstringlist.h>
+#include <tqobject.h>
+#include <tqdict.h>
+#include <tqstringlist.h>
-class QWidgetStack;
+class TQWidgetStack;
class KProcess;
@@ -39,9 +39,10 @@ namespace KileTool
*
* @author Jeroen Wijnhout
**/
- class Launcher : public QObject
+ class Launcher : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
Launcher();
@@ -53,14 +54,14 @@ namespace KileTool
virtual bool selfCheck() = 0;
public:
- virtual void setWorkingDirectory(const QString &) {}
+ virtual void setWorkingDirectory(const TQString &) {}
void setTool(Base *tool) { m_tool = tool; }
Base* tool() { return m_tool; }
signals:
- void message(int, const QString & );
- void output(const QString &);
+ void message(int, const TQString & );
+ void output(const TQString &);
void exitedWith(int);
void abnormalExit();
@@ -68,23 +69,24 @@ namespace KileTool
void done(int);
private:
- //QDict<QString> *m_pdictParams;
+ //TQDict<TQString> *m_pdictParams;
Base *m_tool;
};
class ProcessLauncher : public Launcher
{
Q_OBJECT
+ TQ_OBJECT
public:
ProcessLauncher(const char * shellname =0);
~ProcessLauncher();
public:
- void setWorkingDirectory(const QString &wd);
+ void setWorkingDirectory(const TQString &wd);
void changeToWorkingDirectory(bool change) { m_changeTo = change; }
- void setCommand(const QString & cmd) { m_cmd = cmd; }
- void setOptions(const QString & opt) { m_options = opt; }
+ void setCommand(const TQString & cmd) { m_cmd = cmd; }
+ void setOptions(const TQString & opt) { m_options = opt; }
public slots:
bool launch();
@@ -96,7 +98,7 @@ namespace KileTool
void slotProcessExited(KProcess*);
private:
- QString m_wd, m_cmd, m_options, m_texinputs, m_bibinputs, m_bstinputs;
+ TQString m_wd, m_cmd, m_options, m_texinputs, m_bibinputs, m_bstinputs;
KShellProcess *m_proc;
bool m_changeTo;
};
@@ -104,6 +106,7 @@ namespace KileTool
class KonsoleLauncher : public ProcessLauncher
{
Q_OBJECT
+ TQ_OBJECT
public:
KonsoleLauncher(const char * shellname =0);
@@ -115,6 +118,7 @@ namespace KileTool
class PartLauncher : public Launcher
{
Q_OBJECT
+ TQ_OBJECT
public:
PartLauncher(const char * = 0);
@@ -122,7 +126,7 @@ namespace KileTool
void setLibrary(const char *lib) { m_libName = lib; }
void setClass(const char *clas) { m_className = clas; }
- void setOptions(QString & options) { m_options = options; }
+ void setOptions(TQString & options) { m_options = options; }
public slots:
bool launch();
@@ -134,14 +138,15 @@ namespace KileTool
protected:
KParts::ReadOnlyPart *m_part;
- QString m_state;
+ TQString m_state;
const char *m_name, *m_libName, *m_className;
- QString m_options;
+ TQString m_options;
};
class DocPartLauncher : public PartLauncher
{
Q_OBJECT
+ TQ_OBJECT
public:
DocPartLauncher(const char * name = 0) : PartLauncher(name) {}
diff --git a/src/kile/kilelistselector.cpp b/src/kile/kilelistselector.cpp
index 7ab8cc8..42af28d 100644
--- a/src/kile/kilelistselector.cpp
+++ b/src/kile/kilelistselector.cpp
@@ -17,10 +17,10 @@
#include "kilelistselector.h"
-#include <qstringlist.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qheader.h>
+#include <tqstringlist.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqheader.h>
#include <kapplication.h>
#include "kiledebug.h"
@@ -28,13 +28,13 @@
//////////////////// KileListSelectorBase ////////////////////
-KileListSelectorBase::KileListSelectorBase(const QStringList &list, const QString &caption, const QString &select, QWidget *parent, const char *name) :
- KDialogBase( KDialogBase::Plain, caption, Ok|Cancel,Ok, parent, name, true, true )
+KileListSelectorBase::KileListSelectorBase(const TQStringList &list, const TQString &caption, const TQString &select, TQWidget *tqparent, const char *name) :
+ KDialogBase( KDialogBase::Plain, caption, Ok|Cancel,Ok, tqparent, name, true, true )
{
- QVBoxLayout *layout = new QVBoxLayout(plainPage());
+ TQVBoxLayout *tqlayout = new TQVBoxLayout(plainPage());
- layout->addWidget(new QLabel(select, plainPage()));
- layout->addSpacing(8);
+ tqlayout->addWidget(new TQLabel(select, plainPage()));
+ tqlayout->addSpacing(8);
m_listview = new KListView(plainPage());
m_listview->addColumn(i18n("Files"));
@@ -50,7 +50,7 @@ KileListSelectorBase::KileListSelectorBase(const QStringList &list, const QStrin
#if KDE_VERSION >= KDE_MAKE_VERSION(3,4,0)
m_listview->setShadeSortColumn(false);
#endif
- layout->addWidget(m_listview);
+ tqlayout->addWidget(m_listview);
insertStringList(list);
@@ -59,19 +59,19 @@ KileListSelectorBase::KileListSelectorBase(const QStringList &list, const QStrin
int h = ( list.count() > 0 ) ? m_listview->header()->height()+12*m_listview->firstChild()->height() : 224;
m_listview->setMinimumSize(w,h);
- resize(sizeHint().width(),sizeHint().height()+4);
- connect(m_listview, SIGNAL(doubleClicked(QListViewItem*,const QPoint &,int)), this, SLOT(accept()));
+ resize(tqsizeHint().width(),tqsizeHint().height()+4);
+ connect(m_listview, TQT_SIGNAL(doubleClicked(TQListViewItem*,const TQPoint &,int)), this, TQT_SLOT(accept()));
}
int KileListSelectorBase::currentItem()
{
- QListViewItem *item = m_listview->currentItem();
+ TQListViewItem *item = m_listview->currentItem();
return ( item ) ? m_listview->itemIndex(item) : -1;
}
-void KileListSelectorBase::insertStringList(const QStringList &list)
+void KileListSelectorBase::insertStringList(const TQStringList &list)
{
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
KListViewItem *item = 0L;
for ( it=list.begin(); it!=list.end(); ++it )
{
@@ -82,9 +82,9 @@ void KileListSelectorBase::insertStringList(const QStringList &list)
//////////////////// with single selection ////////////////////
-KileListSelector::KileListSelector(const QStringList &list, const QString &caption, const QString &select, QWidget *parent, const char *name) : KileListSelectorBase(list,caption,select,parent,name)
+KileListSelector::KileListSelector(const TQStringList &list, const TQString &caption, const TQString &select, TQWidget *tqparent, const char *name) : KileListSelectorBase(list,caption,select,tqparent,name)
{
- m_listview->setSelectionMode(QListView::Single);
+ m_listview->setSelectionMode(TQListView::Single);
if ( list.count() > 0 )
m_listview->setSelected(m_listview->firstChild(),true);
@@ -92,17 +92,17 @@ KileListSelector::KileListSelector(const QStringList &list, const QString &capti
//////////////////// with multi selection ////////////////////
-KileListSelectorMultiple::KileListSelectorMultiple(const QStringList &list, const QString &caption, const QString &select, QWidget *parent, const char *name) : KileListSelectorBase(list,caption,select,parent,name)
+KileListSelectorMultiple::KileListSelectorMultiple(const TQStringList &list, const TQString &caption, const TQString &select, TQWidget *tqparent, const char *name) : KileListSelectorBase(list,caption,select,tqparent,name)
{
- m_listview->setSelectionMode(QListView::Extended); // default: Single
+ m_listview->setSelectionMode(TQListView::Extended); // default: Single
}
-const QStringList& KileListSelectorMultiple::selected()
+const TQStringList& KileListSelectorMultiple::selected()
{
m_selectedfiles.clear();
- QPtrList<QListViewItem> list = m_listview->selectedItems();
- QPtrListIterator<QListViewItem> it(list);
+ TQPtrList<TQListViewItem> list = m_listview->selectedItems();
+ TQPtrListIterator<TQListViewItem> it(list);
while ( it.current() )
{
m_selectedfiles.append((*it)->text(0));
diff --git a/src/kile/kilelistselector.h b/src/kile/kilelistselector.h
index cf96930..898f927 100644
--- a/src/kile/kilelistselector.h
+++ b/src/kile/kilelistselector.h
@@ -21,38 +21,38 @@
#include <klistview.h>
class KListView;
-class QStringList;
+class TQStringList;
class KileListSelectorBase : public KDialogBase
{
public:
- KileListSelectorBase(const QStringList &list, const QString &caption, const QString &select, QWidget *parent=0, const char *name=0);
+ KileListSelectorBase(const TQStringList &list, const TQString &caption, const TQString &select, TQWidget *tqparent=0, const char *name=0);
~KileListSelectorBase() {}
int currentItem();
protected:
KListView *m_listview;
- void insertStringList(const QStringList &list);
+ void insertStringList(const TQStringList &list);
};
class KileListSelector : public KileListSelectorBase
{
public:
- KileListSelector(const QStringList &list, const QString &caption, const QString &select, QWidget *parent=0, const char *name=0);
+ KileListSelector(const TQStringList &list, const TQString &caption, const TQString &select, TQWidget *tqparent=0, const char *name=0);
~KileListSelector() {}
};
class KileListSelectorMultiple : public KileListSelectorBase
{
public:
- KileListSelectorMultiple(const QStringList & list, const QString &caption, const QString &select, QWidget *parent=0, const char *name=0);
+ KileListSelectorMultiple(const TQStringList & list, const TQString &caption, const TQString &select, TQWidget *tqparent=0, const char *name=0);
~KileListSelectorMultiple() {}
- const QStringList &selected();
+ const TQStringList &selected();
private:
- QStringList m_selectedfiles;
+ TQStringList m_selectedfiles;
};
diff --git a/src/kile/kilelogwidget.cpp b/src/kile/kilelogwidget.cpp
index 9ebcc2d..6a66fee 100644
--- a/src/kile/kilelogwidget.cpp
+++ b/src/kile/kilelogwidget.cpp
@@ -15,9 +15,9 @@
#include "kilelogwidget.h"
-#include <qregexp.h>
-#include <qfileinfo.h>
-#include <qpopupmenu.h>
+#include <tqregexp.h>
+#include <tqfileinfo.h>
+#include <tqpopupmenu.h>
#include "kiledebug.h"
#include <kurl.h>
@@ -29,12 +29,12 @@
namespace KileWidget
{
- LogMsg::LogMsg(KileInfo *info, QWidget *parent, const char *name ) :
- KTextEdit(parent,name),
+ LogMsg::LogMsg(KileInfo *info, TQWidget *tqparent, const char *name ) :
+ KTextEdit(tqparent,name),
m_info(info)
{
setTabStopWidth(10);
- connect(this, SIGNAL(clicked(int, int)), this, SLOT(slotClicked(int, int)));
+ connect(this, TQT_SIGNAL(clicked(int, int)), this, TQT_SLOT(slotClicked(int, int)));
}
LogMsg::~LogMsg(){
@@ -57,9 +57,9 @@ namespace KileWidget
switch ( (*m_info->outputInfo())[i].type() )
{
- case LatexOutputInfo::itmError : setColor(QColor(0xCC, 0x00, 0x00)); break;
- case LatexOutputInfo::itmWarning : setColor(QColor(0x00, 0x00, 0xCC )); break;
- case LatexOutputInfo::itmBadBox : setColor(QColor(0x00, 0x80, 0x00)); break;
+ case LatexOutputInfo::itmError : setColor(TQColor(0xCC, 0x00, 0x00)); break;
+ case LatexOutputInfo::itmWarning : setColor(TQColor(0x00, 0x00, 0xCC )); break;
+ case LatexOutputInfo::itmBadBox : setColor(TQColor(0x00, 0x80, 0x00)); break;
default : break;
}
removeSelection();
@@ -80,7 +80,7 @@ namespace KileWidget
int parags = paragraphs();
int problemsFound = 0;
int targetProblemNumber = size - index;
- static QRegExp reProblem(".*:[0-9]+:.*");
+ static TQRegExp reProblem(".*:[0-9]+:.*");
//start from the bottom (most recent error) because
//there could very well be errors with the same name
@@ -99,9 +99,9 @@ namespace KileWidget
void LogMsg::slotClicked(int parag, int /*index*/)
{
int l = 0;
- QString s = text(parag), file = QString::null;
+ TQString s = text(parag), file = TQString();
- static QRegExp reES = QRegExp("(^.*):([0-9]+):.*");
+ static TQRegExp reES = TQRegExp("(^.*):([0-9]+):.*");
//maybe there is an error summary
if ( reES.search(s) != -1 )
{
@@ -124,18 +124,18 @@ namespace KileWidget
file = m_info->getFullFromPrettyName(file);
- if ( file != QString::null )
+ if ( file != TQString() )
{
- emit(fileOpen(KURL::fromPathOrURL(file), QString::null));
- if ( l > 0 ) emit(setLine(QString::number(l)));
+ emit(fileOpen(KURL::fromPathOrURL(file), TQString()));
+ if ( l > 0 ) emit(setLine(TQString::number(l)));
}
}
- void LogMsg::printMsg(int type, const QString & message, const QString &tool)
+ void LogMsg::printMsg(int type, const TQString & message, const TQString &tool)
{
if ( type == KileTool::Error ) emit showingErrorMessage(this);
- QString ot = "", ct = "</font>";
+ TQString ot = "", ct = "</font>";
switch (type)
{
@@ -164,16 +164,16 @@ namespace KileWidget
scrollToBottom();
}
- void LogMsg::printProblem(int type, const QString & problem)
+ void LogMsg::printProblem(int type, const TQString & problem)
{
KILE_DEBUG() << "\t" << problem << endl;
- printMsg(type, problem, QString::null);
+ printMsg(type, problem, TQString());
}
- QPopupMenu* LogMsg::createPopupMenu (const QPoint & pos)
+ TQPopupMenu* LogMsg::createPopupMenu (const TQPoint & pos)
{
//get standard popup menu
- QPopupMenu * popup = KTextEdit::createPopupMenu(pos);
+ TQPopupMenu * popup = KTextEdit::createPopupMenu(pos);
//add toggle operations for hiding warnings/badboxes
popup->insertSeparator();
@@ -184,8 +184,8 @@ namespace KileWidget
m_idWarning = popup->insertItem(i18n("Hide (La)TeX &Warnings"));
popup->setItemChecked(m_idWarning, KileConfig::hideProblemWarning());
- disconnect ( popup , SIGNAL(activated(int)), this , SLOT(handlePopup(int )));
- connect ( popup , SIGNAL(activated(int)), this , SLOT(handlePopup(int )));
+ disconnect ( popup , TQT_SIGNAL(activated(int)), this , TQT_SLOT(handlePopup(int )));
+ connect ( popup , TQT_SIGNAL(activated(int)), this , TQT_SLOT(handlePopup(int )));
return popup;
}
diff --git a/src/kile/kilelogwidget.h b/src/kile/kilelogwidget.h
index 855ce58..4e9f779 100644
--- a/src/kile/kilelogwidget.h
+++ b/src/kile/kilelogwidget.h
@@ -17,9 +17,9 @@
#include <ktextedit.h>
-class QString;
-class QPopupMenu;
-class QPoint;
+class TQString;
+class TQPopupMenu;
+class TQPoint;
class KileInfo;
class KURL;
@@ -29,30 +29,31 @@ namespace KileWidget
class LogMsg : public KTextEdit
{
Q_OBJECT
+ TQ_OBJECT
public:
- LogMsg(KileInfo *info, QWidget *parent, const char *name=0);
+ LogMsg(KileInfo *info, TQWidget *tqparent, const char *name=0);
~LogMsg();
- void setReadOnly(bool r) { QTextEdit::setReadOnly(r); } //we don't want the greyed background
+ void setReadOnly(bool r) { TQTextEdit::setReadOnly(r); } //we don't want the greyed background
public slots:
void highlight(); //FIXME for compatibility, should remove it asap
void highlight(uint l, int direction = 1);
void highlightByIndex(int index, int size, int direction = 1);
- void printMsg(int type, const QString & message, const QString &tool = "Kile" );
- void printProblem(int type, const QString & problem);
+ void printMsg(int type, const TQString & message, const TQString &tool = "Kile" );
+ void printProblem(int type, const TQString & problem);
void slotClicked(int, int);
signals:
- void fileOpen(const KURL &, const QString &);
- void setLine(const QString &);
- void showingErrorMessage(QWidget *);
+ void fileOpen(const KURL &, const TQString &);
+ void setLine(const TQString &);
+ void showingErrorMessage(TQWidget *);
protected:
- QPopupMenu* createPopupMenu (const QPoint & pos);
+ TQPopupMenu* createPopupMenu (const TQPoint & pos);
protected slots:
void handlePopup(int);
diff --git a/src/kile/kilelyxserver.cpp b/src/kile/kilelyxserver.cpp
index 2fca99e..395ebb0 100644
--- a/src/kile/kilelyxserver.cpp
+++ b/src/kile/kilelyxserver.cpp
@@ -23,11 +23,11 @@
#include "kileactions.h"
-#include <qfile.h>
-#include <qfileinfo.h>
-#include <qsocketnotifier.h>
-#include <qregexp.h>
-#include <qdir.h>
+#include <tqfile.h>
+#include <tqfileinfo.h>
+#include <tqsocketnotifier.h>
+#include <tqregexp.h>
+#include <tqdir.h>
#include "kiledebug.h"
#include <klocale.h>
@@ -52,7 +52,7 @@ KileLyxServer::KileLyxServer(bool startMe) :
for(uint i = 0; i< m_links.count() ; i++)
{
m_pipes.append( m_tempDir->name() + m_links[i] );
- m_links[i].prepend(QDir::homeDirPath() + '/' );
+ m_links[i].prepend(TQDir::homeDirPath() + '/' );
KILE_DEBUG() << "m_pipes[" << i << "]=" << m_pipes[i] << endl;
KILE_DEBUG() << "m_links[" << i << "]=" << m_links[i] << endl;
}
@@ -77,14 +77,14 @@ bool KileLyxServer::start()
if (openPipes())
{
- QSocketNotifier *notifier;
- QPtrListIterator<QFile> it(m_pipeIn);
+ TQSocketNotifier *notifier;
+ TQPtrListIterator<TQFile> it(m_pipeIn);
while (it.current())
{
if ((*it)->name().right(3) == ".in" )
{
- notifier = new QSocketNotifier((*it)->handle(), QSocketNotifier::Read, this);
- connect(notifier, SIGNAL(activated(int)), this, SLOT(receive(int)));
+ notifier = new TQSocketNotifier((*it)->handle(), TQSocketNotifier::Read, this);
+ connect(notifier, TQT_SIGNAL(activated(int)), this, TQT_SLOT(receive(int)));
m_notifier.append(notifier);
KILE_DEBUG() << "Created notifier for " << (*it)->name() << endl;
}
@@ -103,8 +103,8 @@ bool KileLyxServer::openPipes()
KILE_DEBUG() << "===bool KileLyxServer::openPipes()===" << endl;
bool opened = false;
- QFileInfo pipeInfo,linkInfo;
- QFile *file;
+ TQFileInfo pipeInfo,linkInfo;
+ TQFile *file;
struct stat buf;
struct stat *stats = &buf;
@@ -113,14 +113,14 @@ bool KileLyxServer::openPipes()
pipeInfo.setFile(m_pipes[i]);
linkInfo.setFile(m_links[i]);
- QFile::remove(linkInfo.absFilePath());
+ TQFile::remove(linkInfo.absFilePath());
linkInfo.refresh();
if ( !pipeInfo.exists() )
{
//create the dir first
- if ( !QFileInfo(pipeInfo.dirPath(true)).exists() )
- if ( mkdir(QFile::encodeName( pipeInfo.dirPath() ), m_perms | S_IXUSR) == -1 )
+ if ( !TQFileInfo(pipeInfo.dirPath(true)).exists() )
+ if ( mkdir(TQFile::encodeName( pipeInfo.dirPath() ), m_perms | S_IXUSR) == -1 )
{
kdError() << "Could not create directory for pipe" << endl;
continue;
@@ -128,7 +128,7 @@ bool KileLyxServer::openPipes()
else
KILE_DEBUG() << "Created directory " << pipeInfo.dirPath() << endl;
- if ( mkfifo(QFile::encodeName( pipeInfo.absFilePath() ), m_perms) != 0 )
+ if ( mkfifo(TQFile::encodeName( pipeInfo.absFilePath() ), m_perms) != 0 )
{
kdError() << "Could not create pipe: " << pipeInfo.absFilePath() << endl;
continue;
@@ -137,13 +137,13 @@ bool KileLyxServer::openPipes()
KILE_DEBUG() << "Created pipe: " << pipeInfo.absFilePath() << endl;
}
- if ( symlink(QFile::encodeName(pipeInfo.absFilePath()),QFile::encodeName(linkInfo.absFilePath())) != 0 )
+ if ( symlink(TQFile::encodeName(pipeInfo.absFilePath()),TQFile::encodeName(linkInfo.absFilePath())) != 0 )
{
kdError() << "Could not create symlink: " << linkInfo.absFilePath() << " --> " << pipeInfo.absFilePath() << endl;
continue;
}
- file = new QFile(pipeInfo.absFilePath());
+ file = new TQFile(pipeInfo.absFilePath());
pipeInfo.refresh();
if( pipeInfo.exists() && file->open(IO_ReadWrite) ) // in that order we don't create the file if it does not exist
@@ -176,7 +176,7 @@ void KileLyxServer::stop()
{
KILE_DEBUG() << "Stopping the LyX server..." << endl;
- QPtrListIterator<QFile> it(m_pipeIn);
+ TQPtrListIterator<TQFile> it(m_pipeIn);
while (it.current())
{
(*it)->close();
@@ -192,25 +192,25 @@ void KileLyxServer::stop()
void KileLyxServer::removePipes()
{
for ( uint i = 0; i < m_links.count(); ++i)
- QFile::remove(m_links[i]);
+ TQFile::remove(m_links[i]);
for ( uint i = 0; i < m_pipes.count(); ++i)
- QFile::remove(m_pipes[i]);
+ TQFile::remove(m_pipes[i]);
}
-void KileLyxServer::processLine(const QString &line)
+void KileLyxServer::processLine(const TQString &line)
{
- KILE_DEBUG() << "===void KileLyxServer::processLine(const QString " << line << ")===" << endl;
+ KILE_DEBUG() << "===void KileLyxServer::processLine(const TQString " << line << ")===" << endl;
- QRegExp reCite(":citation-insert:(.*)$");
- QRegExp reBibtexdbadd(":bibtex-database-add:(.*)$");
- QRegExp rePaste(":paste:(.*)$");
+ TQRegExp reCite(":citation-insert:(.*)$");
+ TQRegExp reBibtexdbadd(":bibtex-database-add:(.*)$");
+ TQRegExp rePaste(":paste:(.*)$");
- if( line.find(reCite) != -1 )
+ if( line.tqfind(reCite) != -1 )
emit(insert(KileAction::TagData(i18n("Cite"), "\\cite{"+reCite.cap(1)+'}')));
- else if( line.find(reBibtexdbadd) != -1 )
+ else if( line.tqfind(reBibtexdbadd) != -1 )
emit(insert(KileAction::TagData(i18n("BibTeX db add"), "\\bibliography{"+ reBibtexdbadd.cap(1) + '}')));
- else if( line.find(rePaste) != -1)
+ else if( line.tqfind(rePaste) != -1)
emit(insert(KileAction::TagData(i18n("Paste"), rePaste.cap(1))));
}
@@ -224,7 +224,7 @@ void KileLyxServer::receive(int fd)
if ((bytesRead = read(fd, buffer, size - 1)) > 0 )
{
buffer[bytesRead] = '\0'; // turn it into a c string
- QStringList cmds = QStringList::split('\n', QString(buffer).stripWhiteSpace());
+ TQStringList cmds = TQStringList::split('\n', TQString(buffer).stripWhiteSpace());
for ( uint i = 0; i < cmds.count(); ++i )
processLine(cmds[i]);
}
diff --git a/src/kile/kilelyxserver.h b/src/kile/kilelyxserver.h
index 2627af1..eee1749 100644
--- a/src/kile/kilelyxserver.h
+++ b/src/kile/kilelyxserver.h
@@ -20,10 +20,10 @@
#include <config.h>
#endif
-#include <qobject.h>
-#include <qptrlist.h>
-#include <qintdict.h>
-#include <qstringlist.h>
+#include <tqobject.h>
+#include <tqptrlist.h>
+#include <tqintdict.h>
+#include <tqstringlist.h>
#include <ktempdir.h>
#include <sys/types.h>
@@ -35,13 +35,14 @@
* @version 0.2
*/
-class QFile;
-class QSocketNotifier;
+class TQFile;
+class TQSocketNotifier;
namespace KileAction { class TagData; }
-class KileLyxServer : public QObject
+class KileLyxServer : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
KileLyxServer(bool start = true);
@@ -59,7 +60,7 @@ private slots:
private:
bool openPipes();
void removePipes();
- void processLine(const QString &);
+ void processLine(const TQString &);
signals:
void insert(const KileAction::TagData &);
@@ -67,11 +68,11 @@ signals:
private:
mode_t m_perms;
KTempDir *m_tempDir;
- QPtrList<QFile> m_pipeIn;
- QPtrList<QSocketNotifier> m_notifier;
- QIntDict<QFile> m_file;
+ TQPtrList<TQFile> m_pipeIn;
+ TQPtrList<TQSocketNotifier> m_notifier;
+ TQIntDict<TQFile> m_file;
bool m_running;
- QStringList m_links,m_pipes;
+ TQStringList m_links,m_pipes;
};
#endif // _LYXSERVER_H_
diff --git a/src/kile/kilemultitabbar.cpp b/src/kile/kilemultitabbar.cpp
index d15ebc0..09b2ad2 100644
--- a/src/kile/kilemultitabbar.cpp
+++ b/src/kile/kilemultitabbar.cpp
@@ -30,29 +30,29 @@
#include "kilemultitabbar_p.h"
#include "kilemultitabbar.moc"
#include "kilemultitabbar_p.moc"
-#include <qbutton.h>
-#include <qpopupmenu.h>
-#include <qlayout.h>
-#include <qpainter.h>
-#include <qtooltip.h>
-#include <qfontmetrics.h>
-#include <qregexp.h>
-#include <qstyle.h>
+#include <tqbutton.h>
+#include <tqpopupmenu.h>
+#include <tqlayout.h>
+#include <tqpainter.h>
+#include <tqtooltip.h>
+#include <tqfontmetrics.h>
+#include <tqregexp.h>
+#include <tqstyle.h>
#include <kiconloader.h>
#include "kiledebug.h"
-#include <qapplication.h>
+#include <tqapplication.h>
#include <math.h>
#define NEARBYINT(i) ((int(float(i) + 0.5)))
class KileMultiTabBarTabPrivate {
public:
- QPixmap pix;
+ TQPixmap pix;
};
-KileMultiTabBarInternal::KileMultiTabBarInternal(QWidget *parent, KileMultiTabBar::KileMultiTabBarMode bm):QScrollView(parent)
+KileMultiTabBarInternal::KileMultiTabBarInternal(TQWidget *tqparent, KileMultiTabBar::KileMultiTabBarMode bm):TQScrollView(tqparent)
{
m_expandedTabSize=-1;
m_showActiveTabTexts=false;
@@ -62,25 +62,25 @@ KileMultiTabBarInternal::KileMultiTabBarInternal(QWidget *parent, KileMultiTabBa
setVScrollBarMode(AlwaysOff);
if (bm==KileMultiTabBar::Vertical)
{
- box=new QWidget(viewport());
- mainLayout=new QVBoxLayout(box);
+ box=new TQWidget(viewport());
+ mainLayout=new TQVBoxLayout(box);
mainLayout->setAutoAdd(true);
box->setFixedWidth(24);
setFixedWidth(24);
}
else
{
- box=new QWidget(viewport());
- mainLayout=new QHBoxLayout(box);
+ box=new TQWidget(viewport());
+ mainLayout=new TQHBoxLayout(box);
mainLayout->setAutoAdd(true);
box->setFixedHeight(24);
setFixedHeight(24);
}
addChild(box);
setFrameStyle(NoFrame);
- viewport()->setBackgroundMode(Qt::PaletteBackground);
-/* box->setPaletteBackgroundColor(Qt::red);
- setPaletteBackgroundColor(Qt::green);*/
+ viewport()->setBackgroundMode(TQt::PaletteBackground);
+/* box->setPaletteBackgroundColor(TQt::red);
+ setPaletteBackgroundColor(TQt::green);*/
}
void KileMultiTabBarInternal::setStyle(enum KileMultiTabBar::KileMultiTabBarStyle style)
@@ -97,15 +97,15 @@ void KileMultiTabBarInternal::setStyle(enum KileMultiTabBar::KileMultiTabBarStyl
} else if (mainLayout==0) {
if (m_barMode==KileMultiTabBar::Vertical)
{
- box=new QWidget(viewport());
- mainLayout=new QVBoxLayout(box);
+ box=new TQWidget(viewport());
+ mainLayout=new TQVBoxLayout(box);
box->setFixedWidth(24);
setFixedWidth(24);
}
else
{
- box=new QWidget(viewport());
- mainLayout=new QHBoxLayout(box);
+ box=new TQWidget(viewport());
+ mainLayout=new TQHBoxLayout(box);
box->setFixedHeight(24);
setFixedHeight(24);
}
@@ -115,19 +115,19 @@ void KileMultiTabBarInternal::setStyle(enum KileMultiTabBar::KileMultiTabBarStyl
mainLayout->setAutoAdd(true);
}
- viewport()->repaint();
+ viewport()->tqrepaint();
}
-void KileMultiTabBarInternal::drawContents ( QPainter * paint, int clipx, int clipy, int clipw, int cliph )
+void KileMultiTabBarInternal::drawContents ( TQPainter * paint, int clipx, int clipy, int clipw, int cliph )
{
- QScrollView::drawContents (paint , clipx, clipy, clipw, cliph );
+ TQScrollView::drawContents (paint , clipx, clipy, clipw, cliph );
if (m_position==KileMultiTabBar::Right)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,viewport()->height());
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(1,0,1,viewport()->height());
@@ -135,28 +135,28 @@ void KileMultiTabBarInternal::drawContents ( QPainter * paint, int clipx, int cl
else
if (m_position==KileMultiTabBar::Left)
{
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(23,0,23,viewport()->height());
paint->drawLine(22,0,22,viewport()->height());
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,viewport()->height());
}
else
if (m_position==KileMultiTabBar::Bottom)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,viewport()->width(),0);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(0,1,viewport()->width(),1);
}
else
{
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(0,23,viewport()->width(),23);
paint->drawLine(0,22,viewport()->width(),22);
-/* paint->setPen(colorGroup().shadow());
+/* paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,viewport()->height());*/
}
@@ -164,12 +164,12 @@ void KileMultiTabBarInternal::drawContents ( QPainter * paint, int clipx, int cl
}
-void KileMultiTabBarInternal::contentsMousePressEvent(QMouseEvent *ev)
+void KileMultiTabBarInternal::contentsMousePressEvent(TQMouseEvent *ev)
{
ev->ignore();
}
-void KileMultiTabBarInternal::mousePressEvent(QMouseEvent *ev)
+void KileMultiTabBarInternal::mousePressEvent(TQMouseEvent *ev)
{
ev->ignore();
}
@@ -191,12 +191,12 @@ void KileMultiTabBarInternal::mousePressEvent(QMouseEvent *ev)
} else {diff=0; }
-void KileMultiTabBarInternal::resizeEvent(QResizeEvent *ev) {
+void KileMultiTabBarInternal::resizeEvent(TQResizeEvent *ev) {
/* KILE_DEBUG()<<"KileMultiTabBarInternal::resizeEvent"<<endl;
- KILE_DEBUG()<<"KileMultiTabBarInternal::resizeEvent - box geometry"<<box->geometry()<<endl;
- KILE_DEBUG()<<"KileMultiTabBarInternal::resizeEvent - geometry"<<geometry()<<endl;*/
- if (ev) QScrollView::resizeEvent(ev);
- QValueList<KileMultiTabBarTab*> visibleTabList;
+ KILE_DEBUG()<<"KileMultiTabBarInternal::resizeEvent - box tqgeometry"<<box->tqgeometry()<<endl;
+ KILE_DEBUG()<<"KileMultiTabBarInternal::resizeEvent - tqgeometry"<<tqgeometry()<<endl;*/
+ if (ev) TQScrollView::resizeEvent(ev);
+ TQValueList<KileMultiTabBarTab*> visibleTabList;
for(KileMultiTabBarTab *tab = m_tabs.first(); tab; tab = m_tabs.next()) {
if(tab->isVisible()) {
visibleTabList.push_back(tab);
@@ -323,7 +323,7 @@ void KileMultiTabBarInternal::resizeEvent(QResizeEvent *ev) {
} else {
int size=0; /*move the calculation into another function and call it only on add tab and tab click events*/
- for (QValueList<KileMultiTabBarTab*>::iterator i = visibleTabList.begin(); i != visibleTabList.end(); ++i) {
+ for (TQValueList<KileMultiTabBarTab*>::iterator i = visibleTabList.begin(); i != visibleTabList.end(); ++i) {
size += (m_barMode == KileMultiTabBar::Vertical ? (*i)->height() : (*i)->width());
}
if ((m_position==KileMultiTabBar::Bottom) || (m_position==KileMultiTabBar::Top))
@@ -342,25 +342,25 @@ void KileMultiTabBarInternal::showActiveTabTexts(bool show)
KileMultiTabBarTab* KileMultiTabBarInternal::tab(int id) const
{
- for (QPtrListIterator<KileMultiTabBarTab> it(m_tabs);it.current();++it){
+ for (TQPtrListIterator<KileMultiTabBarTab> it(m_tabs);it.current();++it){
if (it.current()->id()==id) return it.current();
}
return 0;
}
-bool KileMultiTabBarInternal::eventFilter(QObject *, QEvent *e) {
- if (e->type()==QEvent::Resize || e->type()==QEvent::Hide || e->type()==QEvent::Show) resizeEvent(0);
+bool KileMultiTabBarInternal::eventFilter(TQObject *, TQEvent *e) {
+ if (e->type()==TQEvent::Resize || e->type()==TQEvent::Hide || e->type()==TQEvent::Show) resizeEvent(0);
return false;
}
-int KileMultiTabBarInternal::appendTab(const QPixmap &pic ,int id,const QString& text)
+int KileMultiTabBarInternal::appendTab(const TQPixmap &pic ,int id,const TQString& text)
{
KileMultiTabBarTab *tab;
m_tabs.append(tab= new KileMultiTabBarTab(pic,text,id,box,m_position,m_style));
tab->installEventFilter(this);
tab->showActiveTabText(m_showActiveTabTexts);
- if (m_style==KileMultiTabBar::KONQSBC)
+ if (m_style==KileMultiTabBar::KONTQSBC)
{
if (m_expandedTabSize<tab->neededSize()) {
m_expandedTabSize=tab->neededSize();
@@ -392,12 +392,12 @@ void KileMultiTabBarInternal::setPosition(enum KileMultiTabBar::KileMultiTabBarP
m_position=pos;
for (uint i=0;i<m_tabs.count();i++)
m_tabs.at(i)->setTabsPosition(m_position);
- viewport()->repaint();
+ viewport()->tqrepaint();
}
-KileMultiTabBarButton::KileMultiTabBarButton(const QPixmap& pic,const QString& text, QPopupMenu *popup,
- int id,QWidget *parent,KileMultiTabBar::KileMultiTabBarPosition pos,KileMultiTabBar::KileMultiTabBarStyle style)
- :QPushButton(QIconSet(),text,parent),m_style(style)
+KileMultiTabBarButton::KileMultiTabBarButton(const TQPixmap& pic,const TQString& text, TQPopupMenu *popup,
+ int id,TQWidget *tqparent,KileMultiTabBar::KileMultiTabBarPosition pos,KileMultiTabBar::KileMultiTabBarStyle style)
+ :TQPushButton(TQIconSet(),text,tqparent),m_style(style)
{
setIconSet(pic);
setText(text);
@@ -407,13 +407,13 @@ KileMultiTabBarButton::KileMultiTabBarButton(const QPixmap& pic,const QString& t
setFixedHeight(24);
setFixedWidth(24);
m_id=id;
- QToolTip::add(this,text);
- connect(this,SIGNAL(clicked()),this,SLOT(slotClicked()));
+ TQToolTip::add(this,text);
+ connect(this,TQT_SIGNAL(clicked()),this,TQT_SLOT(slotClicked()));
}
-KileMultiTabBarButton::KileMultiTabBarButton(const QString& text, QPopupMenu *popup,
- int id,QWidget *parent,KileMultiTabBar::KileMultiTabBarPosition pos,KileMultiTabBar::KileMultiTabBarStyle style)
- :QPushButton(QIconSet(),text,parent),m_style(style)
+KileMultiTabBarButton::KileMultiTabBarButton(const TQString& text, TQPopupMenu *popup,
+ int id,TQWidget *tqparent,KileMultiTabBar::KileMultiTabBarPosition pos,KileMultiTabBar::KileMultiTabBarStyle style)
+ :TQPushButton(TQIconSet(),text,tqparent),m_style(style)
{
setText(text);
m_position=pos;
@@ -422,8 +422,8 @@ KileMultiTabBarButton::KileMultiTabBarButton(const QString& text, QPopupMenu *po
setFixedHeight(24);
setFixedWidth(24);
m_id=id;
- QToolTip::add(this,text);
- connect(this,SIGNAL(clicked()),this,SLOT(slotClicked()));
+ TQToolTip::add(this,text);
+ connect(this,TQT_SIGNAL(clicked()),this,TQT_SLOT(slotClicked()));
}
KileMultiTabBarButton::~KileMultiTabBarButton() {
@@ -433,16 +433,16 @@ int KileMultiTabBarButton::id() const{
return m_id;
}
-void KileMultiTabBarButton::setText(const QString& text)
+void KileMultiTabBarButton::setText(const TQString& text)
{
- QString s = text;
- s = s.replace("&", QString()); // we do not allow accelerators to be set
+ TQString s = text;
+ s = s.tqreplace("&", TQString()); // we do not allow accelerators to be set
// This is a little hack to avoid KAcceleratorManager
// provide us with accelerators as the class name of the
// widget is no longer KMultiTabBar.
- QPushButton::setText(s);
+ TQPushButton::setText(s);
m_text = s;
- QToolTip::add(this,s);
+ TQToolTip::add(this,s);
}
void KileMultiTabBarButton::slotClicked()
@@ -453,72 +453,72 @@ void KileMultiTabBarButton::slotClicked()
void KileMultiTabBarButton::setPosition(KileMultiTabBar::KileMultiTabBarPosition pos)
{
m_position=pos;
- repaint();
+ tqrepaint();
}
void KileMultiTabBarButton::setStyle(KileMultiTabBar::KileMultiTabBarStyle style)
{
m_style=style;
- repaint();
+ tqrepaint();
}
-void KileMultiTabBarButton::hideEvent( QHideEvent* he) {
- QPushButton::hideEvent(he);
- KileMultiTabBar *tb=dynamic_cast<KileMultiTabBar*>(parentWidget());
+void KileMultiTabBarButton::hideEvent( TQHideEvent* he) {
+ TQPushButton::hideEvent(he);
+ KileMultiTabBar *tb=dynamic_cast<KileMultiTabBar*>(tqparentWidget());
if (tb) tb->updateSeparator();
}
-void KileMultiTabBarButton::showEvent( QShowEvent* he) {
- QPushButton::showEvent(he);
- KileMultiTabBar *tb=dynamic_cast<KileMultiTabBar*>(parentWidget());
+void KileMultiTabBarButton::showEvent( TQShowEvent* he) {
+ TQPushButton::showEvent(he);
+ KileMultiTabBar *tb=dynamic_cast<KileMultiTabBar*>(tqparentWidget());
if (tb) tb->updateSeparator();
}
-QSize KileMultiTabBarButton::sizeHint() const
+TQSize KileMultiTabBarButton::tqsizeHint() const
{
constPolish();
int w = 0, h = 0;
// calculate contents size...
-#ifndef QT_NO_ICONSET
+#ifndef TQT_NO_ICONSET
if ( iconSet() && !iconSet()->isNull() ) {
- int iw = iconSet()->pixmap( QIconSet::Small, QIconSet::Normal ).width() + 4;
- int ih = iconSet()->pixmap( QIconSet::Small, QIconSet::Normal ).height();
+ int iw = iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).width() + 4;
+ int ih = iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).height();
w += iw;
- h = QMAX( h, ih );
+ h = TQMAX( h, ih );
}
#endif
if ( isMenuButton() )
- w += style().pixelMetric(QStyle::PM_MenuButtonIndicator, this);
+ w += tqstyle().tqpixelMetric(TQStyle::PM_MenuButtonIndicator, this);
if ( pixmap() ) {
- QPixmap *pm = (QPixmap *)pixmap();
+ TQPixmap *pm = (TQPixmap *)pixmap();
w += pm->width();
h += pm->height();
} else {
- QString s( text() );
+ TQString s( text() );
bool empty = s.isEmpty();
if ( empty )
- s = QString::fromLatin1("XXXX");
- QFontMetrics fm = fontMetrics();
- QSize sz = fm.size( ShowPrefix, s );
+ s = TQString::tqfromLatin1("XXXX");
+ TQFontMetrics fm = fontMetrics();
+ TQSize sz = fm.size( ShowPrefix, s );
if(!empty || !w)
w += sz.width();
if(!empty || !h)
- h = QMAX(h, sz.height());
+ h = TQMAX(h, sz.height());
}
- return (style().sizeFromContents(QStyle::CT_ToolButton, this, QSize(w, h)).
- expandedTo(QApplication::globalStrut()));
+ return (tqstyle().tqsizeFromContents(TQStyle::CT_ToolButton, this, TQSize(w, h)).
+ expandedTo(TQApplication::globalStrut()));
}
-KileMultiTabBarTab::KileMultiTabBarTab(const QPixmap& pic, const QString& text,
- int id,QWidget *parent,KileMultiTabBar::KileMultiTabBarPosition pos,
+KileMultiTabBarTab::KileMultiTabBarTab(const TQPixmap& pic, const TQString& text,
+ int id,TQWidget *tqparent,KileMultiTabBar::KileMultiTabBarPosition pos,
KileMultiTabBar::KileMultiTabBarStyle style)
- :KileMultiTabBarButton(text,0,id,parent,pos,style),
+ :KileMultiTabBarButton(text,0,id,tqparent,pos,style),
m_showActiveTabText(false)
{
d=new KileMultiTabBarTabPrivate();
@@ -536,7 +536,7 @@ void KileMultiTabBarTab::setTabsPosition(KileMultiTabBar::KileMultiTabBarPositio
{
if ((pos!=m_position) && ((pos==KileMultiTabBar::Left) || (pos==KileMultiTabBar::Right))) {
if (!d->pix.isNull()) {
- QWMatrix temp;// (1.0F, 0.0F, 0.0F, -1.0F, 0.0F, 0.0F);
+ TQWMatrix temp;// (1.0F, 0.0F, 0.0F, -1.0F, 0.0F, 0.0F);
temp.rotate(180);
d->pix=d->pix.xForm(temp);
setIconSet(d->pix);
@@ -544,26 +544,26 @@ void KileMultiTabBarTab::setTabsPosition(KileMultiTabBar::KileMultiTabBarPositio
}
setPosition(pos);
-// repaint();
+// tqrepaint();
}
-void KileMultiTabBarTab::setIcon(const QString& icon)
+void KileMultiTabBarTab::setIcon(const TQString& icon)
{
- QPixmap pic=SmallIcon(icon);
+ TQPixmap pic=SmallIcon(icon);
setIcon(pic);
}
-void KileMultiTabBarTab::setIcon(const QPixmap& icon)
+void KileMultiTabBarTab::setIcon(const TQPixmap& icon)
{
if (m_style!=KileMultiTabBar::KDEV3) {
if ((m_position==KileMultiTabBar::Left) || (m_position==KileMultiTabBar::Right)) {
- QWMatrix rotateMatrix;
+ TQWMatrix rotateMatrix;
if (m_position==KileMultiTabBar::Left)
rotateMatrix.rotate(90);
else
rotateMatrix.rotate(-90);
- QPixmap pic=icon.xForm(rotateMatrix); //TODO FIX THIS, THIS SHOWS WINDOW
+ TQPixmap pic=icon.xForm(rotateMatrix); //TODO FIX THIS, THIS SHOWS WINDOW
d->pix=pic;
setIconSet(pic);
} else setIconSet(icon);
@@ -584,23 +584,23 @@ void KileMultiTabBarTab::setState(bool b)
void KileMultiTabBarTab::updateState()
{
- if (m_style!=KileMultiTabBar::KONQSBC) {
+ if (m_style!=KileMultiTabBar::KONTQSBC) {
if ((m_style==KileMultiTabBar::KDEV3) || (m_style==KileMultiTabBar::KDEV3ICON) || (isOn())) {
- QPushButton::setText(m_text);
+ TQPushButton::setText(m_text);
} else {
- KILE_DEBUG()<<"KileMultiTabBarTab::updateState(): setting text to an empty QString***************"<<endl;
- QPushButton::setText(QString::null);
+ KILE_DEBUG()<<"KileMultiTabBarTab::updateState(): setting text to an empty TQString***************"<<endl;
+ TQPushButton::setText(TQString());
}
if ((m_position==KileMultiTabBar::Right || m_position==KileMultiTabBar::Left)) {
setFixedWidth(24);
if ((m_style==KileMultiTabBar::KDEV3) || (m_style==KileMultiTabBar::KDEV3ICON) || (isOn())) {
- setFixedHeight(KileMultiTabBarButton::sizeHint().width());
+ setFixedHeight(KileMultiTabBarButton::tqsizeHint().width());
} else setFixedHeight(36);
} else {
setFixedHeight(24);
if ((m_style==KileMultiTabBar::KDEV3) || (m_style==KileMultiTabBar::KDEV3ICON) || (isOn())) {
- setFixedWidth(KileMultiTabBarButton::sizeHint().width());
+ setFixedWidth(KileMultiTabBarButton::tqsizeHint().width());
} else setFixedWidth(36);
}
} else {
@@ -615,17 +615,17 @@ void KileMultiTabBarTab::updateState()
else
setFixedWidth(m_expandedSize);
}
-// QApplication::sendPostedEvents(0,QEvent::Paint | QEvent::Move | QEvent::Resize | QEvent::LayoutHint);
- QApplication::sendPostedEvents(0,QEvent::Paint);
- QApplication::flush();
+// TQApplication::sendPostedEvents(0,TQEvent::Paint | TQEvent::Move | TQEvent::Resize | TQEvent::LayoutHint);
+ TQApplication::sendPostedEvents(0,TQEvent::Paint);
+ TQApplication::flush();
}
int KileMultiTabBarTab::neededSize()
{
- QString text = m_text;
- text = text.replace(QRegExp("&(?=[^&])"), QString());
- text = text.replace("&&", "&");
- return (((m_style!=KileMultiTabBar::KDEV3)?24:0)+QFontMetrics(QFont()).width(text)+6);
+ TQString text = m_text;
+ text = text.tqreplace(TQRegExp("&(?=[^&])"), TQString());
+ text = text.tqreplace("&&", "&");
+ return (((m_style!=KileMultiTabBar::KDEV3)?24:0)+TQFontMetrics(TQFont()).width(text)+6);
}
void KileMultiTabBarTab::setSize(int size)
@@ -639,41 +639,41 @@ void KileMultiTabBarTab::showActiveTabText(bool show)
m_showActiveTabText=show;
}
-void KileMultiTabBarTab::drawButtonLabel(QPainter *p) {
+void KileMultiTabBarTab::drawButtonLabel(TQPainter *p) {
drawButton(p);
}
-void KileMultiTabBarTab::drawButton(QPainter *paint)
+void KileMultiTabBarTab::drawButton(TQPainter *paint)
{
- if (m_style!=KileMultiTabBar::KONQSBC) drawButtonStyled(paint);
+ if (m_style!=KileMultiTabBar::KONTQSBC) drawButtonStyled(paint);
else drawButtonClassic(paint);
}
-void KileMultiTabBarTab::drawButtonStyled(QPainter *paint) {
+void KileMultiTabBarTab::drawButtonStyled(TQPainter *paint) {
- QSize sh;
+ TQSize sh;
const int width = 36; // rotated
const int height = 24;
if ((m_style==KileMultiTabBar::KDEV3) || (m_style==KileMultiTabBar::KDEV3ICON) || (isOn())) {
if ((m_position==KileMultiTabBar::Left) || (m_position==KileMultiTabBar::Right))
- sh=QSize(this->height(),this->width());//KileMultiTabBarButton::sizeHint();
- else sh=QSize(this->width(),this->height());
+ sh=TQSize(this->height(),this->width());//KileMultiTabBarButton::tqsizeHint();
+ else sh=TQSize(this->width(),this->height());
}
else
- sh=QSize(width,height);
+ sh=TQSize(width,height);
- QPixmap pixmap( sh.width(),height); ///,sh.height());
+ TQPixmap pixmap( sh.width(),height); ///,sh.height());
pixmap.fill(eraseColor());
- QPainter painter(&pixmap);
+ TQPainter painter(&pixmap);
- QStyle::SFlags st=QStyle::Style_Default;
+ TQStyle::SFlags st=TQStyle::Style_Default;
- st|=QStyle::Style_Enabled;
+ st|=TQStyle::Style_Enabled;
- if (isOn()) st|=QStyle::Style_On;
+ if (isOn()) st|=TQStyle::Style_On;
- style().drawControl(QStyle::CE_PushButton,&painter,this, QRect(0,0,pixmap.width(),pixmap.height()), colorGroup(),st);
- style().drawControl(QStyle::CE_PushButtonLabel,&painter,this, QRect(0,0,pixmap.width(),pixmap.height()), colorGroup(),st);
+ tqstyle().tqdrawControl(TQStyle::CE_PushButton,&painter,this, TQRect(0,0,pixmap.width(),pixmap.height()), tqcolorGroup(),st);
+ tqstyle().tqdrawControl(TQStyle::CE_PushButtonLabel,&painter,this, TQRect(0,0,pixmap.width(),pixmap.height()), tqcolorGroup(),st);
switch (m_position) {
case KileMultiTabBar::Left:
@@ -689,69 +689,69 @@ void KileMultiTabBarTab::drawButtonStyled(QPainter *paint) {
paint->drawPixmap(0,0,pixmap);
break;
}
-// style().drawControl(QStyle::CE_PushButtonLabel,painter,this, QRect(0,0,pixmap.width(),pixmap.height()),
-// colorGroup(),QStyle::Style_Enabled);
+// tqstyle().tqdrawControl(TQStyle::CE_PushButtonLabel,painter,this, TQRect(0,0,pixmap.width(),pixmap.height()),
+// tqcolorGroup(),TQStyle::Style_Enabled);
}
-void KileMultiTabBarTab::drawButtonClassic(QPainter *paint)
+void KileMultiTabBarTab::drawButtonClassic(TQPainter *paint)
{
- QPixmap pixmap;
+ TQPixmap pixmap;
if ( iconSet())
- pixmap = iconSet()->pixmap( QIconSet::Small, QIconSet::Normal );
- paint->fillRect(0, 0, 24, 24, colorGroup().background());
+ pixmap = iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal );
+ paint->fillRect(0, 0, 24, 24, tqcolorGroup().background());
if (!isOn())
{
if (m_position==KileMultiTabBar::Right)
{
- paint->fillRect(0,0,21,21,QBrush(colorGroup().background()));
+ paint->fillRect(0,0,21,21,TQBrush(tqcolorGroup().background()));
- paint->setPen(colorGroup().background().dark(150));
+ paint->setPen(tqcolorGroup().background().dark(150));
paint->drawLine(0,22,23,22);
paint->drawPixmap(12-pixmap.width()/2,12-pixmap.height()/2,pixmap);
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,23);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(1,0,1,23);
}
else
if ((m_position==KileMultiTabBar::Bottom) || (m_position==KileMultiTabBar::Top))
{
- paint->fillRect(0,1,23,22,QBrush(colorGroup().background()));
+ paint->fillRect(0,1,23,22,TQBrush(tqcolorGroup().background()));
paint->drawPixmap(12-pixmap.width()/2,12-pixmap.height()/2,pixmap);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(23,0,23,23);
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(0,22,23,22);
paint->drawLine(0,23,23,23);
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,23,0);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(0,1,23,1);
}
else
{
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(0,23,23,23);
- paint->fillRect(0,0,23,21,QBrush(colorGroup().background()));
+ paint->fillRect(0,0,23,21,TQBrush(tqcolorGroup().background()));
paint->drawPixmap(12-pixmap.width()/2,12-pixmap.height()/2,pixmap);
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(23,0,23,23);
paint->drawLine(22,0,22,23);
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,23);
}
@@ -762,25 +762,25 @@ void KileMultiTabBarTab::drawButtonClassic(QPainter *paint)
{
if (m_position==KileMultiTabBar::Right)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,height()-1,23,height()-1);
paint->drawLine(0,height()-2,23,height()-2);
paint->drawLine(23,0,23,height()-1);
paint->drawLine(22,0,22,height()-1);
- paint->fillRect(0,0,21,height()-3,QBrush(colorGroup().light()));
+ paint->fillRect(0,0,21,height()-3,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
if (height()<25+4) return;
- QPixmap tpixmap(height()-25-3, width()-2);
- QPainter painter(&tpixmap);
+ TQPixmap tpixmap(height()-25-3, width()-2);
+ TQPainter painter(&tpixmap);
- painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),QBrush(colorGroup().light()));
+ painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),TQBrush(tqcolorGroup().light()));
- painter.setPen(colorGroup().text());
- painter.drawText(0,+width()/2+QFontMetrics(QFont()).height()/2,m_text);
+ painter.setPen(tqcolorGroup().text());
+ painter.drawText(0,+width()/2+TQFontMetrics(TQFont()).height()/2,m_text);
paint->rotate(90);
KILE_DEBUG()<<"tpixmap.width:"<<tpixmap.width()<<endl;
@@ -791,26 +791,26 @@ void KileMultiTabBarTab::drawButtonClassic(QPainter *paint)
else
if (m_position==KileMultiTabBar::Top)
{
- paint->fillRect(0,0,width()-1,23,QBrush(colorGroup().light()));
+ paint->fillRect(0,0,width()-1,23,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
- paint->setPen(colorGroup().text());
- paint->drawText(25,height()/2+QFontMetrics(QFont()).height()/2,m_text);
+ paint->setPen(tqcolorGroup().text());
+ paint->drawText(25,height()/2+TQFontMetrics(TQFont()).height()/2,m_text);
}
}
else
if (m_position==KileMultiTabBar::Bottom)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,23,width()-1,23);
paint->drawLine(0,22,width()-1,22);
- paint->fillRect(0,0,width()-1,21,QBrush(colorGroup().light()));
+ paint->fillRect(0,0,width()-1,21,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
- paint->setPen(colorGroup().text());
- paint->drawText(25,height()/2+QFontMetrics(QFont()).height()/2,m_text);
+ paint->setPen(tqcolorGroup().text());
+ paint->drawText(25,height()/2+TQFontMetrics(TQFont()).height()/2,m_text);
}
}
@@ -818,23 +818,23 @@ void KileMultiTabBarTab::drawButtonClassic(QPainter *paint)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,height()-1,23,height()-1);
paint->drawLine(0,height()-2,23,height()-2);
- paint->fillRect(0,0,23,height()-3,QBrush(colorGroup().light()));
+ paint->fillRect(0,0,23,height()-3,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
if (height()<25+4) return;
- QPixmap tpixmap(height()-25-3, width()-2);
- QPainter painter(&tpixmap);
+ TQPixmap tpixmap(height()-25-3, width()-2);
+ TQPainter painter(&tpixmap);
- painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),QBrush(colorGroup().light()));
+ painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),TQBrush(tqcolorGroup().light()));
- painter.setPen(colorGroup().text());
- painter.drawText(tpixmap.width()-QFontMetrics(QFont()).width(m_text),+width()/2+QFontMetrics(QFont()).height()/2,m_text);
+ painter.setPen(tqcolorGroup().text());
+ painter.drawText(tpixmap.width()-TQFontMetrics(TQFont()).width(m_text),+width()/2+TQFontMetrics(TQFont()).height()/2,m_text);
paint->rotate(-90);
KILE_DEBUG()<<"tpixmap.width:"<<tpixmap.width()<<endl;
@@ -854,19 +854,19 @@ void KileMultiTabBarTab::drawButtonClassic(QPainter *paint)
-KileMultiTabBar::KileMultiTabBar(KileMultiTabBarMode bm, QWidget *parent,const char *name):QWidget(parent,name)
+KileMultiTabBar::KileMultiTabBar(KileMultiTabBarMode bm, TQWidget *tqparent,const char *name):TQWidget(tqparent,name)
{
m_buttons.setAutoDelete(false);
if (bm==Vertical)
{
- m_l=new QVBoxLayout(this);
- setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Expanding, true);
+ m_l=new TQVBoxLayout(this);
+ tqsetSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Expanding, true);
// setFixedWidth(24);
}
else
{
- m_l=new QHBoxLayout(this);
- setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed, true);
+ m_l=new TQHBoxLayout(this);
+ tqsetSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, true);
// setFixedHeight(24);
}
m_l->setMargin(0);
@@ -876,11 +876,11 @@ KileMultiTabBar::KileMultiTabBar(KileMultiTabBarMode bm, QWidget *parent,const c
setPosition((bm==KileMultiTabBar::Vertical)?KileMultiTabBar::Right:KileMultiTabBar::Bottom);
setStyle(VSNET);
// setStyle(KDEV3);
- //setStyle(KONQSBC);
+ //setStyle(KONTQSBC);
m_l->insertWidget(0,m_internal);
- m_l->insertWidget(0,m_btnTabSep=new QFrame(this));
+ m_l->insertWidget(0,m_btnTabSep=new TQFrame(this));
m_btnTabSep->setFixedHeight(4);
- m_btnTabSep->setFrameStyle(QFrame::Panel | QFrame::Sunken);
+ m_btnTabSep->setFrameStyle(TQFrame::Panel | TQFrame::Sunken);
m_btnTabSep->setLineWidth(2);
m_btnTabSep->hide();
@@ -890,16 +890,16 @@ KileMultiTabBar::KileMultiTabBar(KileMultiTabBarMode bm, QWidget *parent,const c
KileMultiTabBar::~KileMultiTabBar() {
}
-/*int KileMultiTabBar::insertButton(QPixmap pic,int id ,const QString&)
+/*int KileMultiTabBar::insertButton(TQPixmap pic,int id ,const TQString&)
{
(new KToolbarButton(pic,id,m_internal))->show();
return 0;
}*/
-int KileMultiTabBar::appendButton(const QPixmap &pic ,int id,QPopupMenu *popup,const QString&)
+int KileMultiTabBar::appendButton(const TQPixmap &pic ,int id,TQPopupMenu *popup,const TQString&)
{
KileMultiTabBarButton *btn;
- m_buttons.append(btn= new KileMultiTabBarButton(pic,QString::null,
+ m_buttons.append(btn= new KileMultiTabBarButton(pic,TQString(),
popup,id,this,m_position,m_internal->m_style));
m_l->insertWidget(0,btn);
btn->show();
@@ -909,7 +909,7 @@ int KileMultiTabBar::appendButton(const QPixmap &pic ,int id,QPopupMenu *popup,c
void KileMultiTabBar::updateSeparator() {
bool hideSep=true;
- for (QPtrListIterator<KileMultiTabBarButton> it(m_buttons);it.current();++it){
+ for (TQPtrListIterator<KileMultiTabBarButton> it(m_buttons);it.current();++it){
if (it.current()->isVisibleTo(this)) {
hideSep=false;
break;
@@ -920,7 +920,7 @@ void KileMultiTabBar::updateSeparator() {
}
-int KileMultiTabBar::appendTab(const QPixmap &pic ,int id ,const QString& text)
+int KileMultiTabBar::appendTab(const TQPixmap &pic ,int id ,const TQString& text)
{
m_internal->appendTab(pic,id,text);
return 0;
@@ -928,7 +928,7 @@ int KileMultiTabBar::appendTab(const QPixmap &pic ,int id ,const QString& text)
KileMultiTabBarButton* KileMultiTabBar::button(int id) const
{
- for (QPtrListIterator<KileMultiTabBarButton> it(m_buttons);it.current();++it){
+ for (TQPtrListIterator<KileMultiTabBarButton> it(m_buttons);it.current();++it){
if (it.current()->id()==id) return it.current();
}
return 0;
@@ -1007,13 +1007,13 @@ KileMultiTabBar::KileMultiTabBarPosition KileMultiTabBar::position() const
{
return m_position;
}
-void KileMultiTabBar::fontChange(const QFont& /* oldFont */)
+void KileMultiTabBar::fontChange(const TQFont& /* oldFont */)
{
for (uint i=0;i<tabs()->count();i++)
tabs()->at(i)->resize();
- repaint();
+ tqrepaint();
}
-QPtrList<KileMultiTabBarTab>* KileMultiTabBar::tabs() {return m_internal->tabs();}
-QPtrList<KileMultiTabBarButton>* KileMultiTabBar::buttons() {return &m_buttons;}
+TQPtrList<KileMultiTabBarTab>* KileMultiTabBar::tabs() {return m_internal->tabs();}
+TQPtrList<KileMultiTabBarButton>* KileMultiTabBar::buttons() {return &m_buttons;}
diff --git a/src/kile/kilemultitabbar.h b/src/kile/kilemultitabbar.h
index 4487542..356d3ed 100644
--- a/src/kile/kilemultitabbar.h
+++ b/src/kile/kilemultitabbar.h
@@ -27,17 +27,17 @@
#ifndef _KileMultitabbar_h_
#define _KileMultitabbar_h_
-#include <qscrollview.h>
-#include <qvbox.h>
-#include <qhbox.h>
-#include <qlayout.h>
-#include <qstring.h>
-#include <qptrlist.h>
-#include <qpushbutton.h>
+#include <tqscrollview.h>
+#include <tqvbox.h>
+#include <tqhbox.h>
+#include <tqlayout.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
+#include <tqpushbutton.h>
-class QPixmap;
-class QPainter;
-class QFrame;
+class TQPixmap;
+class TQPainter;
+class TQFrame;
class KileMultiTabBarPrivate;
class KileMultiTabBarTabPrivate;
@@ -53,16 +53,17 @@ class KileMultiTabBarInternal;
* should be raisable is left to the "user".
*@author Joseph Wenninger
*/
-class KileMultiTabBar: public QWidget
+class KileMultiTabBar: public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The tab bar's orientation. Also constraints the bar's position.
*/
enum KileMultiTabBarMode {
- Horizontal, ///< Horizontal orientation (i.e. on top or bottom)
- Vertical ///< Vertical orientation (i.e. on the left or right hand side)
+ Horizontal, ///<Qt::Horizontal orientation (i.e. on top or bottom)
+ Vertical ///<Qt::Vertical orientation (i.e. on the left or right hand side)
};
/**
@@ -81,7 +82,7 @@ public:
enum KileMultiTabBarStyle {
VSNET=0, ///< Visual Studio .Net like (only show the text of active tabs)
KDEV3=1, ///< KDevelop 3 like (always show the text)
- KONQSBC=2, ///< Konqueror's classic sidebar style (unthemed) (currently disabled)
+ KONTQSBC=2, ///< Konqueror's classic sidebar style (unthemed) (currently disabled)
KDEV3ICON=3, ///< KDevelop 3 like with icons
STYLELAST=0xffff ///< Last style
};
@@ -89,10 +90,10 @@ public:
/**
* Constructor.
* @param bm The tab bar's orientation
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
* @param name The widget's name
*/
- KileMultiTabBar(KileMultiTabBarMode bm,QWidget *parent=0,const char *name=0);
+ KileMultiTabBar(KileMultiTabBarMode bm,TQWidget *tqparent=0,const char *name=0);
/**
* Destructor.
@@ -108,7 +109,7 @@ public:
* @param popup A popup menu which should be displayed if the button is clicked
* @param not_used_yet will be used for a popup text in the future
*/
- int appendButton(const QPixmap &pic,int id=-1,QPopupMenu* popup=0,const QString& not_used_yet=QString::null);
+ int appendButton(const TQPixmap &pic,int id=-1,TQPopupMenu* popup=0,const TQString& not_used_yet=TQString());
/**
* remove a button with the given ID
*/
@@ -120,7 +121,7 @@ public:
* @param text if a mode with text is used it will be the tab text, otherwise a mouse over hint
* @return Always zero. Can be safely ignored.
*/
- int appendTab(const QPixmap &pic,int id=-1,const QString& text=QString::null);
+ int appendTab(const TQPixmap &pic,int id=-1,const TQString& text=TQString());
/**
* remove a tab with a given ID
* @param id The ID of the tab to remove
@@ -172,13 +173,13 @@ public:
* @return The list of tabs.
* @warning be careful, don't delete tabs yourself and don't delete the list itself
*/
- QPtrList<KileMultiTabBarTab>* tabs();
+ TQPtrList<KileMultiTabBarTab>* tabs();
/**
* Returns the list of pointers to the tab buttons of type KileMultiTabBarButton.
* @return The list of tab buttons.
* @warning be careful, don't delete buttons yourself and don't delete the list itself
*/
- QPtrList<KileMultiTabBarButton>* buttons();
+ TQPtrList<KileMultiTabBarButton>* buttons();
/**
* might vanish, not sure yet
@@ -186,13 +187,13 @@ public:
void showActiveTabTexts(bool show=true);
protected:
friend class KileMultiTabBarButton;
- virtual void fontChange( const QFont& );
+ virtual void fontChange( const TQFont& );
void updateSeparator();
private:
class KileMultiTabBarInternal *m_internal;
- QBoxLayout *m_l;
- QFrame *m_btnTabSep;
- QPtrList<KileMultiTabBarButton> m_buttons;
+ TQBoxLayout *m_l;
+ TQFrame *m_btnTabSep;
+ TQPtrList<KileMultiTabBarButton> m_buttons;
KileMultiTabBarPosition m_position;
KileMultiTabBarPrivate *d;
};
@@ -202,16 +203,17 @@ private:
* This class represents a tab bar button in a KileMultiTabBarWidget.
* This class should never be created except with the appendButton call of KileMultiTabBar
*/
-class KileMultiTabBarButton: public QPushButton
+class KileMultiTabBarButton: public TQPushButton
{
Q_OBJECT
+ TQ_OBJECT
public:
/** @internal */
- KileMultiTabBarButton(const QPixmap& pic,const QString&, QPopupMenu *popup,
- int id,QWidget *parent, KileMultiTabBar::KileMultiTabBarPosition pos, KileMultiTabBar::KileMultiTabBarStyle style);
+ KileMultiTabBarButton(const TQPixmap& pic,const TQString&, TQPopupMenu *popup,
+ int id,TQWidget *tqparent, KileMultiTabBar::KileMultiTabBarPosition pos, KileMultiTabBar::KileMultiTabBarStyle style);
/** @internal */
- KileMultiTabBarButton(const QString&, QPopupMenu *popup,
- int id,QWidget *parent, KileMultiTabBar::KileMultiTabBarPosition pos, KileMultiTabBar::KileMultiTabBarStyle style);
+ KileMultiTabBarButton(const TQString&, TQPopupMenu *popup,
+ int id,TQWidget *tqparent, KileMultiTabBar::KileMultiTabBarPosition pos, KileMultiTabBar::KileMultiTabBarStyle style);
/**
* Destructor
*/
@@ -237,16 +239,16 @@ public slots:
/**
* modify the text of the button
*/
- void setText(const QString &);
+ void setText(const TQString &);
- QSize sizeHint() const;
+ TQSize tqsizeHint() const;
protected:
KileMultiTabBar::KileMultiTabBarPosition m_position;
KileMultiTabBar::KileMultiTabBarStyle m_style;
- QString m_text;
- virtual void hideEvent( class QHideEvent*);
- virtual void showEvent( class QShowEvent*);
+ TQString m_text;
+ virtual void hideEvent( class TQHideEvent*);
+ virtual void showEvent( class TQShowEvent*);
private:
int m_id;
KileMultiTabBarButtonPrivate *d;
@@ -268,9 +270,10 @@ protected slots:
class KileMultiTabBarTab: public KileMultiTabBarButton
{
Q_OBJECT
+ TQ_OBJECT
public:
/** @internal */
- KileMultiTabBarTab(const QPixmap& pic,const QString&,int id,QWidget *parent,
+ KileMultiTabBarTab(const TQPixmap& pic,const TQString&,int id,TQWidget *tqparent,
KileMultiTabBar::KileMultiTabBarPosition pos,KileMultiTabBar::KileMultiTabBarStyle style);
/**
* Destructor.
@@ -300,17 +303,17 @@ protected:
void setSize(int);
int neededSize();
void updateState();
- virtual void drawButton(QPainter *);
- virtual void drawButtonLabel(QPainter *);
- void drawButtonStyled(QPainter *);
- void drawButtonClassic(QPainter *);
+ virtual void drawButton(TQPainter *);
+ virtual void drawButtonLabel(TQPainter *);
+ void drawButtonStyled(TQPainter *);
+ void drawButtonClassic(TQPainter *);
protected slots:
virtual void slotClicked();
void setTabsPosition(KileMultiTabBar::KileMultiTabBarPosition);
public slots:
- virtual void setIcon(const QString&);
- virtual void setIcon(const QPixmap&);
+ virtual void setIcon(const TQString&);
+ virtual void setIcon(const TQPixmap&);
};
#endif
diff --git a/src/kile/kilemultitabbar_p.h b/src/kile/kilemultitabbar_p.h
index 8cefad2..e5dbee3 100644
--- a/src/kile/kilemultitabbar_p.h
+++ b/src/kile/kilemultitabbar_p.h
@@ -26,26 +26,27 @@
#ifndef KILE_MULTI_TAB_BAR_P_H
#define KILE_MULTI_TAB_BAR_P_H
-#include <qscrollview.h>
+#include <tqscrollview.h>
#include <kmultitabbar.h>
-class KileMultiTabBarInternal: public QScrollView
+class KileMultiTabBarInternal: public TQScrollView
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileMultiTabBarInternal(QWidget *parent,KileMultiTabBar::KileMultiTabBarMode bm);
- int appendTab(const QPixmap &,int=-1,const QString& =QString::null);
+ KileMultiTabBarInternal(TQWidget *tqparent,KileMultiTabBar::KileMultiTabBarMode bm);
+ int appendTab(const TQPixmap &,int=-1,const TQString& =TQString());
KileMultiTabBarTab *tab(int) const;
void removeTab(int);
void setPosition(enum KileMultiTabBar::KileMultiTabBarPosition pos);
void setStyle(enum KileMultiTabBar::KileMultiTabBarStyle style);
void showActiveTabTexts(bool show);
- QPtrList<KileMultiTabBarTab>* tabs(){return &m_tabs;}
+ TQPtrList<KileMultiTabBarTab>* tabs(){return &m_tabs;}
private:
friend class KileMultiTabBar;
- QWidget *box;
- QBoxLayout *mainLayout;
- QPtrList<KileMultiTabBarTab> m_tabs;
+ TQWidget *box;
+ TQBoxLayout *mainLayout;
+ TQPtrList<KileMultiTabBarTab> m_tabs;
enum KileMultiTabBar::KileMultiTabBarPosition m_position;
bool m_showActiveTabTexts;
enum KileMultiTabBar::KileMultiTabBarStyle m_style;
@@ -53,17 +54,17 @@ private:
int m_lines;
KileMultiTabBar::KileMultiTabBarMode m_barMode;
protected:
- virtual bool eventFilter(QObject *,QEvent*);
- virtual void drawContents ( QPainter *, int, int, int, int);
+ virtual bool eventFilter(TQObject *,TQEvent*);
+ virtual void drawContents ( TQPainter *, int, int, int, int);
/**
- * [contentsM|m]ousePressEvent are reimplemented from QScrollView
+ * [contentsM|m]ousePressEvent are reimplemented from TQScrollView
* in order to ignore all mouseEvents on the viewport, so that the
- * parent can handle them.
+ * tqparent can handle them.
*/
- virtual void contentsMousePressEvent(QMouseEvent *);
- virtual void mousePressEvent(QMouseEvent *);
- virtual void resizeEvent(QResizeEvent *);
+ virtual void contentsMousePressEvent(TQMouseEvent *);
+ virtual void mousePressEvent(TQMouseEvent *);
+ virtual void resizeEvent(TQResizeEvent *);
};
#endif
diff --git a/src/kile/kileoutputwidget.cpp b/src/kile/kileoutputwidget.cpp
index f30b45e..55cf8e6 100644
--- a/src/kile/kileoutputwidget.cpp
+++ b/src/kile/kileoutputwidget.cpp
@@ -18,27 +18,27 @@
namespace KileWidget
{
- Output::Output(QWidget *parent, const char * name) : KTextEdit(parent, name)
+ Output::Output(TQWidget *tqparent, const char * name) : KTextEdit(tqparent, name)
{
- setTextFormat(Qt::LogText);
+ setTextFormat(TQt::LogText);
}
Output::~Output()
{}
- void Output::receive(const QString & str)
+ void Output::receive(const TQString & str)
{
- static QString line = "";
+ static TQString line = "";
//find newline symbol
//only output if we have receive one or more
//full lines of text
- int newLineAt = str.findRev('\n');
+ int newLineAt = str.tqfindRev('\n');
if ( newLineAt != -1 )
{
line += str.left(newLineAt); //don't copy the newline char
- line.replace('<',"&lt;");
- line.replace('>',"&gt;");
+ line.tqreplace('<',"&lt;");
+ line.tqreplace('>',"&gt;");
append(line);
line = str.mid(newLineAt + 1);
}
diff --git a/src/kile/kileoutputwidget.h b/src/kile/kileoutputwidget.h
index a77a37a..bb2fc0e 100644
--- a/src/kile/kileoutputwidget.h
+++ b/src/kile/kileoutputwidget.h
@@ -22,15 +22,16 @@ namespace KileWidget
class Output : public KTextEdit
{
Q_OBJECT
+ TQ_OBJECT
public:
- Output(QWidget *parent, const char *name=0);
+ Output(TQWidget *tqparent, const char *name=0);
~Output();
- void setReadOnly(bool r) { QTextEdit::setReadOnly(r); } //we don't want the greyed background
+ void setReadOnly(bool r) { TQTextEdit::setReadOnly(r); } //we don't want the greyed background
public slots:
- void receive(const QString &);
+ void receive(const TQString &);
};
}
diff --git a/src/kile/kileproject.cpp b/src/kile/kileproject.cpp
index 2cb2395..87711aa 100644
--- a/src/kile/kileproject.cpp
+++ b/src/kile/kileproject.cpp
@@ -22,9 +22,9 @@
#include "kileproject.h"
#include "kileversion.h"
-#include <qstringlist.h>
-#include <qfileinfo.h>
-#include <qdir.h>
+#include <tqstringlist.h>
+#include <tqfileinfo.h>
+#include <tqdir.h>
#include <ksimpleconfig.h>
#include <klocale.h>
@@ -59,7 +59,7 @@ KileProjectItem::KileProjectItem(KileProject *project, const KURL & url, int typ
m_nLine(0),
m_order(-1)
{
- m_highlight=m_encoding=QString::null;
+ m_highlight=m_encoding=TQString();
m_bOpen = m_archive = true;
if (project)
@@ -75,7 +75,7 @@ void KileProjectItem::setParent(KileProjectItem * item)
{
m_parent = item;
- //update parent info
+ //update tqparent info
if (m_parent)
{
if (m_parent->firstChild())
@@ -99,7 +99,7 @@ void KileProjectItem::setParent(KileProjectItem * item)
void KileProjectItem::print(int level)
{
- QString str;
+ TQString str;
str.fill('\t', level);
KILE_DEBUG() << str << "+" << url().fileName() << endl;
@@ -110,7 +110,7 @@ void KileProjectItem::print(int level)
sibling()->print(level);
}
-void KileProjectItem::allChildren(QPtrList<KileProjectItem> *list) const
+void KileProjectItem::allChildren(TQPtrList<KileProjectItem> *list) const
{
KileProjectItem *item = firstChild();
@@ -129,8 +129,8 @@ void KileProjectItem::setInfo(KileDocument::TextInfo *docinfo)
m_docinfo = docinfo;
if(docinfo)
{
- connect(docinfo,SIGNAL(urlChanged(KileDocument::Info*, const KURL &)), this, SLOT(slotChangeURL(KileDocument::Info*, const KURL &)));
- connect(docinfo,SIGNAL(depChanged()), m_project, SLOT(buildProjectTree()));
+ connect(docinfo,TQT_SIGNAL(urlChanged(KileDocument::Info*, const KURL &)), this, TQT_SLOT(slotChangeURL(KileDocument::Info*, const KURL &)));
+ connect(docinfo,TQT_SIGNAL(depChanged()), m_project, TQT_SLOT(buildProjectTree()));
}
}
@@ -152,12 +152,12 @@ void KileProjectItem::slotChangeURL(KileDocument::Info*, const KURL &url)
/*
* KileProject
*/
-KileProject::KileProject(const QString& name, const KURL& url, KileDocument::Extensions *extensions) : QObject(0,name.ascii()), m_invalid(false), m_masterDocument(QString::null), m_useMakeIndexOptions(false)
+KileProject::KileProject(const TQString& name, const KURL& url, KileDocument::Extensions *extensions) : TQObject(0,name.ascii()), m_invalid(false), m_masterDocument(TQString()), m_useMakeIndexOptions(false)
{
init(name, url, extensions);
}
-KileProject::KileProject(const KURL& url, KileDocument::Extensions *extensions) : QObject(0,url.fileName().ascii()), m_invalid(false), m_masterDocument(QString::null), m_useMakeIndexOptions(false)
+KileProject::KileProject(const KURL& url, KileDocument::Extensions *extensions) : TQObject(0,url.fileName().ascii()), m_invalid(false), m_masterDocument(TQString()), m_useMakeIndexOptions(false)
{
init(url.fileName(), url, extensions);
}
@@ -168,7 +168,7 @@ KileProject::~KileProject()
delete m_config;
}
-void KileProject::init(const QString& name, const KURL& url, KileDocument::Extensions *extensions)
+void KileProject::init(const TQString& name, const KURL& url, KileDocument::Extensions *extensions)
{
m_name = name;
m_projecturl = KileDocument::Manager::symlinkFreeURL( url);;
@@ -183,7 +183,7 @@ void KileProject::init(const QString& name, const KURL& url, KileDocument::Exten
KILE_DEBUG() << "KileProject m_baseurl = " << m_baseurl.path() << endl;
- if (QFileInfo(url.path()).exists())
+ if (TQFileInfo(url.path()).exists())
{
load();
}
@@ -204,7 +204,7 @@ void KileProject::setLastDocument(const KURL &url)
m_lastDocument = KileDocument::Manager::symlinkFreeURL(url);
}
-void KileProject::setExtensions(KileProjectItem::Type type, const QString & ext)
+void KileProject::setExtensions(KileProjectItem::Type type, const TQString & ext)
{
if (type<KileProjectItem::Source || type>KileProjectItem::Image)
{
@@ -213,23 +213,23 @@ void KileProject::setExtensions(KileProjectItem::Type type, const QString & ext)
}
// first we take all standard extensions
- QStringList standardExtList;
+ TQStringList standardExtList;
if ( type == KileProjectItem::Source )
- standardExtList = QStringList::split(" ", m_extmanager->latexDocuments() );
+ standardExtList = TQStringList::split(" ", m_extmanager->latexDocuments() );
else if ( type == KileProjectItem::Package )
- standardExtList = QStringList::split(" ", m_extmanager->latexPackages() );
+ standardExtList = TQStringList::split(" ", m_extmanager->latexPackages() );
else // if ( type == KileProjectItem::Image )
- standardExtList = QStringList::split(" ", m_extmanager->images() );
+ standardExtList = TQStringList::split(" ", m_extmanager->images() );
// now we scan user defined list and accept all extension,
// except standard extensions of course
- QString userExt;
+ TQString userExt;
if ( ! ext.isEmpty() )
{
- QStringList userExtList;
+ TQStringList userExtList;
- QStringList::ConstIterator it;
- QStringList list = QStringList::split(" ", ext);
+ TQStringList::ConstIterator it;
+ TQStringList list = TQStringList::split(" ", ext);
for ( it=list.begin(); it != list.end(); ++it )
{
// some tiny extension checks
@@ -260,8 +260,8 @@ void KileProject::setExtensions(KileProjectItem::Type type, const QString & ext)
// now we build a regular expression for all extensions
// (used to search for a filename with a valid extension)
- QString pattern = standardExtList.join("|");
- pattern.replace(".","\\.");
+ TQString pattern = standardExtList.join("|");
+ pattern.tqreplace(".","\\.");
pattern = '('+ pattern +")$";
// and save it
@@ -301,17 +301,17 @@ void KileProject::setType(KileProjectItem *item)
void KileProject::readMakeIndexOptions()
{
- QString grp = KileTool::groupFor("MakeIndex", m_config);
+ TQString grp = KileTool::groupFor("MakeIndex", m_config);
//get the default value
KConfig *cfg = KGlobal::config();
cfg->setGroup(KileTool::groupFor("MakeIndex", KileTool::configName("MakeIndex", cfg)));
- QString deflt = cfg->readEntry("options", "'%S'.idx");
+ TQString deflt = cfg->readEntry("options", "'%S'.idx");
if ( useMakeIndexOptions() && !grp.isEmpty() )
{
m_config->setGroup(grp);
- QString val = m_config->readEntry("options", deflt);
+ TQString val = m_config->readEntry("options", deflt);
if ( val.isEmpty() ) val = deflt;
setMakeIndexOptions(val);
}
@@ -327,9 +327,9 @@ void KileProject::writeUseMakeIndexOptions()
KileTool::setConfigName("MakeIndex", "", m_config);
}
-QString KileProject::addBaseURL(const QString &path)
+TQString KileProject::addBaseURL(const TQString &path)
{
- KILE_DEBUG() << "===addBaseURL(const QString & " << path << " )" << endl;
+ KILE_DEBUG() << "===addBaseURL(const TQString & " << path << " )" << endl;
if ( path.isEmpty())
return path;
else if ( path.startsWith("/") )
@@ -338,13 +338,13 @@ QString KileProject::addBaseURL(const QString &path)
return KileDocument::Manager::symlinkFreeURL(KURL::fromPathOrURL(m_baseurl.path() + '/' +path)).path();
}
-QString KileProject::removeBaseURL(const QString &path)
+TQString KileProject::removeBaseURL(const TQString &path)
{
if ( path.startsWith("/") )
{
- QFileInfo info(path);
- QString relPath = findRelativePath(path);
+ TQFileInfo info(path);
+ TQString relPath = findRelativePath(path);
KILE_DEBUG() << "removeBaseURL path is" << path << " , relPath is " << relPath << endl;
return relPath;
}
@@ -361,22 +361,22 @@ bool KileProject::load()
//load general settings/options
m_config->setGroup("General");
m_name = m_config->readEntry("name", i18n("Project"));
- m_kileversion = m_config->readEntry("kileversion",QString::null);
- m_kileprversion = m_config->readEntry("kileprversion",QString::null);
+ m_kileversion = m_config->readEntry("kileversion",TQString());
+ m_kileprversion = m_config->readEntry("kileprversion",TQString());
if(!m_kileprversion.isNull() && m_kileprversion.toInt() > kilePrVersion.toInt())
{
if(KMessageBox::warningYesNo(0L,i18n("The project file of %1 was created by a newer version of kile.\
Opening it can lead to unexpected results.\n\
- Do you really want to continue (not recommended)?").arg(m_name),
- QString::null, KStdGuiItem::yes(), KStdGuiItem::no(),QString::null,KMessageBox::Dangerous) == KMessageBox::No)
+ Do you really want to continue (not recommended)?").tqarg(m_name),
+ TQString(), KStdGuiItem::yes(), KStdGuiItem::no(),TQString(),KMessageBox::Dangerous) == KMessageBox::No)
{
m_invalid=true;
return false;
}
}
- QString master = addBaseURL(m_config->readEntry("masterDocument", QString::null));
+ TQString master = addBaseURL(m_config->readEntry("masterDocument", TQString()));
KILE_DEBUG() << "masterDoc == " << master << endl;
setMasterDocument(master);
@@ -395,14 +395,14 @@ bool KileProject::load()
KURL url;
KileProjectItem *item;
- QStringList groups = m_config->groupList();
+ TQStringList groups = m_config->groupList();
//retrieve all the project files and create and initialize project items for them
for (uint i=0; i < groups.count(); ++i)
{
if (groups[i].left(5) == "item:")
{
- QString path = groups[i].mid(5);
+ TQString path = groups[i].mid(5);
if (path[0] == '/' )
{
url = KURL::fromPathOrURL(path);
@@ -418,21 +418,21 @@ bool KileProject::load()
m_config->setGroup(groups[i]);
item->setOpenState(m_config->readBoolEntry("open", true));
- item->setEncoding(m_config->readEntry("encoding", QString::null));
- item->setHighlight(m_config->readEntry("highlight",QString::null));
+ item->setEncoding(m_config->readEntry("encoding", TQString()));
+ item->setHighlight(m_config->readEntry("highlight",TQString()));
item->setArchive(m_config->readBoolEntry("archive", true));
item->setLineNumber(m_config->readNumEntry("line", 0));
item->setColumnNumber(m_config->readNumEntry("column", 0));
item->setOrder(m_config->readNumEntry("order", -1));
item->changePath(groups[i].mid(5));
- connect(item, SIGNAL(urlChanged(KileProjectItem*)), this, SLOT(itemRenamed(KileProjectItem*)) );
+ connect(item, TQT_SIGNAL(urlChanged(KileProjectItem*)), this, TQT_SLOT(itemRenamed(KileProjectItem*)) );
}
}
// only call this after all items are created, otherwise setLastDocument doesn't accept the url
m_config->setGroup("General");
- setLastDocument(KURL::fromPathOrURL(addBaseURL(m_config->readEntry("lastDocument", QString::null))));
+ setLastDocument(KURL::fromPathOrURL(addBaseURL(m_config->readEntry("lastDocument", TQString()))));
// dump();
@@ -481,7 +481,7 @@ bool KileProject::save()
if ( useMakeIndexOptions() )
{
- QString grp = KileTool::groupFor("MakeIndex", m_config);
+ TQString grp = KileTool::groupFor("MakeIndex", m_config);
if ( grp.isEmpty() ) grp = "Default";
m_config->setGroup(grp);
m_config->writeEntry("options", makeIndexOptions() );
@@ -494,9 +494,9 @@ bool KileProject::save()
return true;
}
-void KileProject::writeConfigEntry(const QString &key, const QString &standardExt, KileProjectItem::Type type)
+void KileProject::writeConfigEntry(const TQString &key, const TQString &standardExt, KileProjectItem::Type type)
{
- QString userExt = extensions(type);
+ TQString userExt = extensions(type);
if ( userExt.isEmpty() )
m_config->writeEntry(key,standardExt);
else
@@ -507,13 +507,13 @@ void KileProject::buildProjectTree()
{
KILE_DEBUG() << "==KileProject::buildProjectTree==========================" << endl;
- //determine the parent doc for each item (TODO:an item can only have one parent, not necessarily true for LaTeX docs)
+ //determine the tqparent doc for each item (TODO:an item can only have one tqparent, not necessarily true for LaTeX docs)
- const QStringList *deps;
- QString dep;
+ const TQStringList *deps;
+ TQString dep;
KileProjectItem *itm;
KURL url;
- QPtrListIterator<KileProjectItem> it(m_projectitems);
+ TQPtrListIterator<KileProjectItem> it(m_projectitems);
//clean first
while (it.current())
@@ -522,7 +522,7 @@ void KileProject::buildProjectTree()
++it;
}
- //use the dependencies list of the documentinfo object to determine the parent
+ //use the dependencies list of the documentinfo object to determine the tqparent
it.toFirst();
while (it.current())
{
@@ -542,7 +542,7 @@ void KileProject::buildProjectTree()
url = KileInfo::checkOtherPaths(m_baseurl,dep,KileInfo::bibinputs);
itm = item(url);
- if (itm && (itm->parent() == 0))
+ if (itm && (itm->tqparent() == 0))
itm->setParent(*it);
}
}
@@ -550,12 +550,12 @@ void KileProject::buildProjectTree()
++it;
}
- //make a list of all the root items (items with parent == 0)
+ //make a list of all the root items (items with tqparent == 0)
m_rootItems.clear();
it.toFirst();
while (it.current())
{
- if ((*it)->parent() == 0) m_rootItems.append(*it);
+ if ((*it)->tqparent() == 0) m_rootItems.append(*it);
++it;
}
@@ -564,7 +564,7 @@ void KileProject::buildProjectTree()
KileProjectItem* KileProject::item(const KURL & url)
{
- QPtrListIterator<KileProjectItem> it(m_projectitems);
+ TQPtrListIterator<KileProjectItem> it(m_projectitems);
while (it.current())
{
if ((*it)->url() == url)
@@ -577,7 +577,7 @@ KileProjectItem* KileProject::item(const KURL & url)
KileProjectItem* KileProject::item(const KileDocument::Info *info)
{
- QPtrListIterator<KileProjectItem> it(m_projectitems);
+ TQPtrListIterator<KileProjectItem> it(m_projectitems);
KileProjectItem *current;
while ((current = it.current()) != 0)
{
@@ -597,7 +597,7 @@ void KileProject::add(KileProjectItem* item)
setType(item);
item->changePath(findRelativePath(item->url()));
- connect(item, SIGNAL(urlChanged(KileProjectItem*)), this, SLOT(itemRenamed(KileProjectItem*)) );
+ connect(item, TQT_SIGNAL(urlChanged(KileProjectItem*)), this, TQT_SLOT(itemRenamed(KileProjectItem*)) );
m_projectitems.append(item);
@@ -627,11 +627,11 @@ void KileProject::itemRenamed(KileProjectItem *item)
item->changePath(findRelativePath(item->url()));
}
-QString KileProject::findRelativePath(const KURL &url)
+TQString KileProject::findRelativePath(const KURL &url)
{
- QString basepath = m_baseurl.path();
- QString path = url.directory();
- QString filename = url.fileName();
+ TQString basepath = m_baseurl.path();
+ TQString path = url.directory();
+ TQString filename = url.fileName();
KILE_DEBUG() <<"===findRelativeURL==================" << endl;
KILE_DEBUG() << "\tbasepath : " << basepath << " path: " << path << endl;
@@ -641,8 +641,8 @@ QString KileProject::findRelativePath(const KURL &url)
// return "./";
// }
- QStringList basedirs = QStringList::split("/", basepath, false);
- QStringList dirs = QStringList::split("/", path, false);
+ TQStringList basedirs = TQStringList::split("/", basepath, false);
+ TQStringList dirs = TQStringList::split("/", path, false);
uint nDirs = dirs.count();
//uint nBaseDirs = basedirs.count();
@@ -700,7 +700,7 @@ QString KileProject::findRelativePath(const KURL &url)
return path;
}
-bool KileProject::contains(const KURL &url)
+bool KileProject::tqcontains(const KURL &url)
{
for (uint i=0; i < m_projectitems.count(); ++i)
{
@@ -711,9 +711,9 @@ bool KileProject::contains(const KURL &url)
return false;
}
-bool KileProject::contains(const KileDocument::Info *info)
+bool KileProject::tqcontains(const KileDocument::Info *info)
{
- QPtrListIterator<KileProjectItem> it(m_projectitems);
+ TQPtrListIterator<KileProjectItem> it(m_projectitems);
KileProjectItem *current;
while( (current = it.current()) != 0)
{
@@ -728,10 +728,10 @@ bool KileProject::contains(const KileDocument::Info *info)
KileProjectItem *KileProject::rootItem(KileProjectItem *item) const
{
- //find the root item (i.e. the eldest parent)
+ //find the root item (i.e. the eldest tqparent)
KileProjectItem *root = item;
- while ( root->parent() != 0)
- root = root->parent();
+ while ( root->tqparent() != 0)
+ root = root->tqparent();
//check if this root item is a LaTeX root
if ( root->getInfo() )
@@ -741,7 +741,7 @@ KileProjectItem *KileProject::rootItem(KileProjectItem *item) const
else
{
//if not, see if we can find another root item that is a LaTeX root
- QPtrListIterator<KileProjectItem> it(m_rootItems);
+ TQPtrListIterator<KileProjectItem> it(m_rootItems);
while ( it.current() )
{
if ( it.current()->getInfo() && it.current()->getInfo()->isLaTeXRoot() )
@@ -771,12 +771,12 @@ void KileProject::dump()
}
}
-QString KileProject::archiveFileList() const
+TQString KileProject::archiveFileList() const
{
KILE_DEBUG() << "KileProject::archiveFileList()" << endl;
- QString path,list;
- QPtrListIterator<KileProjectItem> it(m_projectitems);
+ TQString path,list;
+ TQPtrListIterator<KileProjectItem> it(m_projectitems);
while (it.current())
{
@@ -791,21 +791,21 @@ QString KileProject::archiveFileList() const
return list;
}
-void KileProject::setMasterDocument(const QString & master){
+void KileProject::setMasterDocument(const TQString & master){
if(!master.isEmpty()){
- QFileInfo fi(master);
+ TQFileInfo fi(master);
if(fi.exists())
m_masterDocument = master;
else{
- m_masterDocument = QString::null;
+ m_masterDocument = TQString();
KILE_DEBUG() << "setMasterDocument: masterDoc=NULL" << endl;
}
}
else
- m_masterDocument = QString::null;
+ m_masterDocument = TQString();
emit (masterDocumentChanged(m_masterDocument));
}
diff --git a/src/kile/kileproject.h b/src/kile/kileproject.h
index eb936ab..fb3aefe 100644
--- a/src/kile/kileproject.h
+++ b/src/kile/kileproject.h
@@ -15,15 +15,15 @@
#ifndef KILEPROJECT_H
#define KILEPROJECT_H
-#include <qobject.h>
-#include <qptrlist.h>
-#include <qregexp.h>
+#include <tqobject.h>
+#include <tqptrlist.h>
+#include <tqregexp.h>
#include "kiledebug.h"
#include <kurl.h>
-class QString;
-class QStringList;
+class TQString;
+class TQStringList;
class KSimpleConfig;
namespace KileDocument { class Info; class TextInfo; class Extensions; }
@@ -32,9 +32,10 @@ namespace KileDocument { class Info; class TextInfo; class Extensions; }
**/
class KileProject;
class KileProjectItemList;
-class KileProjectItem : public QObject
+class KileProjectItem : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
KileProjectItem(KileProject *project = 0, const KURL &url = KURL(), int type = Source);
@@ -63,16 +64,16 @@ public:
/**
* @returns path of this item relative to the project file
**/
- const QString& path() const { return m_path; }
+ const TQString& path() const { return m_path; }
bool isOpen() const { return m_bOpen; }
void setOpenState(bool state) { m_bOpen = state; }
- const QString& encoding() const { return m_encoding;}
- void setEncoding(const QString& encoding) {m_encoding = encoding;}
+ const TQString& encoding() const { return m_encoding;}
+ void setEncoding(const TQString& encoding) {m_encoding = encoding;}
- const QString& highlight() { return m_highlight;}
- void setHighlight(const QString& highlight) {m_highlight = highlight;}
+ const TQString& highlight() { return m_highlight;}
+ void setHighlight(const TQString& highlight) {m_highlight = highlight;}
uint lineNumber() { return m_nLine; }
void setLineNumber(uint l) { m_nLine = l; }
@@ -91,11 +92,11 @@ protected:
void setSibling(KileProjectItem *item) { m_sibling = item; }
public:
- KileProjectItem* parent() const { return m_parent; }
+ KileProjectItem* tqparent() const { return m_parent; }
KileProjectItem* firstChild() const { return m_child;}
KileProjectItem* sibling() const { return m_sibling; }
- void allChildren(QPtrList<KileProjectItem> *) const;
+ void allChildren(TQPtrList<KileProjectItem> *) const;
void print(int level);
@@ -104,7 +105,7 @@ public slots:
* @warning Does nothing if "url" is empty !
**/
void changeURL(const KURL &url);
- void changePath(const QString& path) { m_path = path;}
+ void changePath(const TQString& path) { m_path = path;}
private slots:
void slotChangeURL(KileDocument::Info* info, const KURL& url);
@@ -115,9 +116,9 @@ signals:
private:
KileProject *m_project;
KURL m_url;
- QString m_path;
- QString m_encoding;
- QString m_highlight;
+ TQString m_path;
+ TQString m_encoding;
+ TQString m_highlight;
bool m_bOpen, m_archive;
int m_type;
KileDocument::TextInfo *m_docinfo;
@@ -126,7 +127,7 @@ private:
int m_order;
};
-class KileProjectItemList : public QPtrList<KileProjectItem>
+class KileProjectItemList : public TQPtrList<KileProjectItem>
{
public:
KileProjectItemList() { setAutoDelete(true); }
@@ -136,33 +137,34 @@ public:
/**
* KileProject
**/
-class KileProject : public QObject
+class KileProject : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileProject(const QString& name, const KURL& url, KileDocument::Extensions *extensions);
+ KileProject(const TQString& name, const KURL& url, KileDocument::Extensions *extensions);
KileProject(const KURL& url, KileDocument::Extensions *extensions);
~KileProject();
- void setName(const QString & name) { m_name = name; emit (nameChanged(name));}
- const QString& name() const { return m_name; }
+ void setName(const TQString & name) { m_name = name; emit (nameChanged(name));}
+ const TQString& name() const { return m_name; }
- void setMasterDocument(const QString & master);
- const QString& masterDocument() const { return m_masterDocument; }
+ void setMasterDocument(const TQString & master);
+ const TQString& masterDocument() const { return m_masterDocument; }
- void setExtensions(KileProjectItem::Type type, const QString & ext);
- const QString & extensions(KileProjectItem::Type type) { return m_extensions[type-1]; }
+ void setExtensions(KileProjectItem::Type type, const TQString & ext);
+ const TQString & extensions(KileProjectItem::Type type) { return m_extensions[type-1]; }
- void setQuickBuildConfig(const QString & cfg) { m_quickBuildConfig = cfg; }
- const QString & quickBuildConfig() { return m_quickBuildConfig; }
+ void setQuickBuildConfig(const TQString & cfg) { m_quickBuildConfig = cfg; }
+ const TQString & quickBuildConfig() { return m_quickBuildConfig; }
void setLastDocument(const KURL &url);
const KURL & lastDocument() const { return m_lastDocument; }
- void setMakeIndexOptions(const QString & opt) { m_makeIndexOptions = opt; }
- const QString & makeIndexOptions() { return m_makeIndexOptions; }
+ void setMakeIndexOptions(const TQString & opt) { m_makeIndexOptions = opt; }
+ const TQString & makeIndexOptions() { return m_makeIndexOptions; }
void readMakeIndexOptions();
void setUseMakeIndexOptions(bool use) { m_useMakeIndexOptions = use; }
void writeUseMakeIndexOptions();
@@ -178,16 +180,16 @@ public:
KSimpleConfig *config() { return m_config; }
- bool contains(const KURL&);
- bool contains(const KileDocument::Info *info);
+ bool tqcontains(const KURL&);
+ bool tqcontains(const KileDocument::Info *info);
KileProjectItem *rootItem(KileProjectItem *) const;
- const QPtrList<KileProjectItem>* rootItems() const {return &m_rootItems;}
+ const TQPtrList<KileProjectItem>* rootItems() const {return &m_rootItems;}
bool isInvalid(){ return m_invalid;}
- QString archiveFileList() const;
+ TQString archiveFileList() const;
signals:
- void nameChanged(const QString &);
- void masterDocumentChanged(const QString &);
+ void nameChanged(const TQString &);
+ void masterDocumentChanged(const TQString &);
void projectTreeChanged(const KileProject *);
public slots:
@@ -205,27 +207,27 @@ public slots:
void dump();
signals:
- void loadFile(const KURL &url , const QString & encoding);
+ void loadFile(const KURL &url , const TQString & encoding);
private:
- void init(const QString& name, const KURL& url, KileDocument::Extensions *extensions);
- QString findRelativePath(const KURL&);
+ void init(const TQString& name, const KURL& url, KileDocument::Extensions *extensions);
+ TQString findRelativePath(const KURL&);
void setType(KileProjectItem *item);
- QString addBaseURL(const QString &path);
- QString removeBaseURL(const QString &path);
- void writeConfigEntry(const QString &key,const QString &standardExt,KileProjectItem::Type type);
+ TQString addBaseURL(const TQString &path);
+ TQString removeBaseURL(const TQString &path);
+ void writeConfigEntry(const TQString &key,const TQString &standardExt,KileProjectItem::Type type);
private:
- QString m_name, m_quickBuildConfig, m_kileversion, m_kileprversion;
+ TQString m_name, m_quickBuildConfig, m_kileversion, m_kileprversion;
KURL m_projecturl, m_baseurl, m_lastDocument;
bool m_invalid;
- QPtrList<KileProjectItem> m_rootItems;
+ TQPtrList<KileProjectItem> m_rootItems;
KileProjectItemList m_projectitems;
- QString m_extensions[3];
- QRegExp m_reExtensions[3];
+ TQString m_extensions[3];
+ TQRegExp m_reExtensions[3];
- QString m_masterDocument, m_makeIndexOptions;
+ TQString m_masterDocument, m_makeIndexOptions;
bool m_useMakeIndexOptions;
KSimpleConfig *m_config;
diff --git a/src/kile/kileprojectdlgs.cpp b/src/kile/kileprojectdlgs.cpp
index 01ff6a4..e906003 100644
--- a/src/kile/kileprojectdlgs.cpp
+++ b/src/kile/kileprojectdlgs.cpp
@@ -25,12 +25,12 @@
#include "kileprojectdlgs.h"
-#include <qlabel.h>
-#include <qwhatsthis.h>
-#include <qfileinfo.h>
-#include <qptrlist.h>
-#include <qregexp.h>
-#include <qvalidator.h>
+#include <tqlabel.h>
+#include <tqwhatsthis.h>
+#include <tqfileinfo.h>
+#include <tqptrlist.h>
+#include <tqregexp.h>
+#include <tqvalidator.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -48,61 +48,61 @@
#include "kileextensions.h"
#include "templates.h"
-const QString whatsthisName = i18n("Insert a short descriptive name of your project here.");
-const QString whatsthisPath = i18n("Insert the path to your project file here. If this file does not yet exists, it will be created. The filename should have the extension: .kilepr. You can also use the browse button to insert a filename.");
-const QString whatsthisExt = i18n("Insert a list (separated by spaces) of file extensions which should be treated also as files of the corresponding type in this project.");
-const QString whatsthisMaster = i18n("Select the default master document. Leave empty for auto detection.");
+const TQString whatsthisName = i18n("Insert a short descriptive name of your project here.");
+const TQString whatsthisPath = i18n("Insert the path to your project file here. If this file does not yet exists, it will be created. The filename should have the extension: .kilepr. You can also use the browse button to insert a filename.");
+const TQString whatsthisExt = i18n("Insert a list (separated by spaces) of file extensions which should be treated also as files of the corresponding type in this project.");
+const TQString whatsthisMaster = i18n("Select the default master document. Leave empty for auto detection.");
-const QString tool_default = i18n("(use global setting)");
+const TQString tool_default = i18n("(use global setting)");
-KileProjectDlgBase::KileProjectDlgBase(const QString &caption, KileDocument::Extensions *extensions, QWidget *parent, const char * name)
- : KDialogBase( KDialogBase::Plain, caption, (Ok | Cancel), Ok, parent, name, true, true),
+KileProjectDlgBase::KileProjectDlgBase(const TQString &caption, KileDocument::Extensions *extensions, TQWidget *tqparent, const char * name)
+ : KDialogBase( KDialogBase::Plain, caption, (Ok | Cancel), Ok, tqparent, name, true, true),
m_extmanager(extensions), m_project(0)
{
// properties groupbox
- m_pgroup = new QVGroupBox(i18n("Project"), plainPage());
+ m_pgroup = new TQVGroupBox(i18n("Project"), plainPage());
m_pgroup->setColumnLayout(0, Qt::Vertical );
- m_pgroup->layout()->setSpacing( 6 );
- m_pgroup->layout()->setMargin( 11 );
- m_pgrid = new QGridLayout( m_pgroup->layout() );
- m_pgrid->setAlignment( Qt::AlignTop );
+ m_pgroup->tqlayout()->setSpacing( 6 );
+ m_pgroup->tqlayout()->setMargin( 11 );
+ m_pgrid = new TQGridLayout( m_pgroup->tqlayout() );
+ m_pgrid->tqsetAlignment( TQt::AlignTop );
m_title = new KLineEdit(m_pgroup, "le_projectname");
- QWhatsThis::add(m_title, whatsthisName);
- m_plabel = new QLabel(i18n("Project &title:"), m_pgroup);
+ TQWhatsThis::add(m_title, whatsthisName);
+ m_plabel = new TQLabel(i18n("Project &title:"), m_pgroup);
m_plabel->setBuddy(m_title);
- QWhatsThis::add(m_plabel, whatsthisName);
+ TQWhatsThis::add(m_plabel, whatsthisName);
// extensions groupbox
- m_egroup= new QVGroupBox(i18n("Extensions"), plainPage());
+ m_egroup= new TQVGroupBox(i18n("Extensions"), plainPage());
m_egroup->setColumnLayout(0, Qt::Vertical );
- m_egroup->layout()->setSpacing( 6 );
- m_egroup->layout()->setMargin( 11 );
- m_egrid = new QGridLayout( m_egroup->layout() );
- m_egrid->setAlignment( Qt::AlignTop );
+ m_egroup->tqlayout()->setSpacing( 6 );
+ m_egroup->tqlayout()->setMargin( 11 );
+ m_egrid = new TQGridLayout( m_egroup->tqlayout() );
+ m_egrid->tqsetAlignment( TQt::AlignTop );
m_extensions = new KLineEdit(m_egroup, "le_ext");
- QRegExp reg("[\\. a-zA-Z0-9]+");
- QRegExpValidator *extValidator = new QRegExpValidator(reg,m_egroup);
+ TQRegExp reg("[\\. a-zA-Z0-9]+");
+ TQRegExpValidator *extValidator = new TQRegExpValidator(reg,TQT_TQOBJECT(m_egroup));
m_extensions->setValidator(extValidator);
m_sel_extensions = new KComboBox(false, m_egroup, "le_sel_ext");
m_sel_extensions->insertItem(i18n("Source Files"));
m_sel_extensions->insertItem(i18n("Package Files"));
m_sel_extensions->insertItem(i18n("Image Files"));
- m_lbPredefinedExtensions = new QLabel(i18n("Predefined:"),m_egroup);
- m_lbStandardExtensions = new QLabel(QString::null,m_egroup);
+ m_lbPredefinedExtensions = new TQLabel(i18n("Predefined:"),m_egroup);
+ m_lbStandardExtensions = new TQLabel(TQString(),m_egroup);
- QWhatsThis::add(m_sel_extensions, whatsthisExt);
- QWhatsThis::add(m_extensions, whatsthisExt);
+ TQWhatsThis::add(m_sel_extensions, whatsthisExt);
+ TQWhatsThis::add(m_extensions, whatsthisExt);
fillProjectDefaults();
- connect(m_sel_extensions, SIGNAL(highlighted(int)),
- this, SLOT(slotExtensionsHighlighted(int)));
+ connect(m_sel_extensions, TQT_SIGNAL(highlighted(int)),
+ this, TQT_SLOT(slotExtensionsHighlighted(int)));
- connect(m_extensions, SIGNAL(textChanged(const QString&)),
- this, SLOT(slotExtensionsTextChanged(const QString&)));
+ connect(m_extensions, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(slotExtensionsTextChanged(const TQString&)));
}
KileProjectDlgBase::~KileProjectDlgBase()
@@ -111,23 +111,23 @@ KileProjectDlgBase::~KileProjectDlgBase()
void KileProjectDlgBase::slotExtensionsHighlighted(int index)
{
- disconnect(m_extensions, SIGNAL(textChanged(const QString&)),
- this, SLOT(slotExtensionsTextChanged(const QString&)));
+ disconnect(m_extensions, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(slotExtensionsTextChanged(const TQString&)));
m_extensions->setText(m_val_extensions[index]);
- connect(m_extensions, SIGNAL(textChanged(const QString&)),
- this, SLOT(slotExtensionsTextChanged(const QString&)));
+ connect(m_extensions, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(slotExtensionsTextChanged(const TQString&)));
m_lbStandardExtensions->setText( m_val_standardExtensions[index] );
}
-void KileProjectDlgBase::slotExtensionsTextChanged(const QString &text)
+void KileProjectDlgBase::slotExtensionsTextChanged(const TQString &text)
{
m_val_extensions[m_sel_extensions->currentItem()] = text;
}
bool KileProjectDlgBase::acceptUserExtensions()
{
- QRegExp reg("\\.\\w+");
+ TQRegExp reg("\\.\\w+");
for (int i=KileProjectItem::Source; i<KileProjectItem::Other; ++i)
{
@@ -135,8 +135,8 @@ bool KileProjectDlgBase::acceptUserExtensions()
if ( ! m_val_extensions[i-1].isEmpty() )
{
// some tiny extension checks
- QStringList::ConstIterator it;
- QStringList list = QStringList::split(" ", m_val_extensions[i-1]);
+ TQStringList::ConstIterator it;
+ TQStringList list = TQStringList::split(" ", m_val_extensions[i-1]);
for ( it=list.begin(); it != list.end(); ++it )
{
if ( ! reg.exactMatch(*it) )
@@ -151,7 +151,7 @@ bool KileProjectDlgBase::acceptUserExtensions()
return true;
}
-void KileProjectDlgBase::setExtensions(KileProjectItem::Type type, const QString & ext)
+void KileProjectDlgBase::setExtensions(KileProjectItem::Type type, const TQString & ext)
{
if (m_sel_extensions->currentItem() == type-1)
m_extensions->setText(ext);
@@ -183,9 +183,9 @@ KileProject* KileProjectDlgBase::project()
void KileProjectDlgBase::fillProjectDefaults()
{
- m_val_extensions[0] = QString::null;
- m_val_extensions[1] = QString::null;
- m_val_extensions[2] = QString::null;
+ m_val_extensions[0] = TQString();
+ m_val_extensions[1] = TQString();
+ m_val_extensions[2] = TQString();
//m_val_extensions[3] = OTHER_EXTENSIONS;
m_val_standardExtensions[0] = m_extmanager->latexDocuments();
@@ -200,24 +200,24 @@ void KileProjectDlgBase::fillProjectDefaults()
/*
* KileNewProjectDlg
*/
-KileNewProjectDlg::KileNewProjectDlg(KileTemplate::Manager *templateManager, KileDocument::Extensions *extensions, QWidget* parent, const char* name)
- : KileProjectDlgBase(i18n("Create New Project"), extensions, parent, name), m_templateManager(templateManager),
- m_filename(QString::null)
+KileNewProjectDlg::KileNewProjectDlg(KileTemplate::Manager *templateManager, KileDocument::Extensions *extensions, TQWidget* tqparent, const char* name)
+ : KileProjectDlgBase(i18n("Create New Project"), extensions, tqparent, name), m_templateManager(templateManager),
+ m_filename(TQString())
{
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(plainPage(), 6,6 );
+ TQVBoxLayout *vbox = new TQVBoxLayout(plainPage(), 6,6 );
// first groupbox
m_pgrid->addWidget(m_plabel, 0,0);
m_pgrid->addWidget(m_title, 0,2);
- connect(m_title, SIGNAL(textChanged(const QString&)), this, SLOT(makeProjectPath()));
+ connect(m_title, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(makeProjectPath()));
m_location = new KLineEdit(m_pgroup, "le_projectlocation");
m_location->setMinimumWidth(200);
- QLabel *lb1 = new QLabel(i18n("Project &file:"), m_pgroup);
- QWhatsThis::add(lb1, whatsthisPath);
- QWhatsThis::add(m_location, whatsthisPath);
+ TQLabel *lb1 = new TQLabel(i18n("Project &file:"), m_pgroup);
+ TQWhatsThis::add(lb1, whatsthisPath);
+ TQWhatsThis::add(m_location, whatsthisPath);
lb1->setBuddy(m_location);
m_pbChooseDir= new KPushButton(i18n("Select Folder..."), m_pgroup, "dirchooser_button" );
m_pbChooseDir->setPixmap( SmallIcon("fileopen") );
@@ -232,29 +232,29 @@ KileNewProjectDlg::KileNewProjectDlg(KileTemplate::Manager *templateManager, Kil
m_pgrid->setColSpacing(4,8);
m_pgrid->setColStretch(3,1);
- connect(m_pbChooseDir, SIGNAL(clicked()), this, SLOT(browseLocation()));
+ connect(m_pbChooseDir, TQT_SIGNAL(clicked()), this, TQT_SLOT(browseLocation()));
// second groupbox
- QVGroupBox* group2= new QVGroupBox(i18n("File"), plainPage());
- QWidget *widget2 = new QWidget(group2);
- QGridLayout *grid2 = new QGridLayout(widget2, 3,2, 6,6);
- m_cb = new QCheckBox(i18n("Create a new file and add it to this project"),widget2);
+ TQVGroupBox* group2= new TQVGroupBox(i18n("File"), plainPage());
+ TQWidget *widget2 = new TQWidget(group2);
+ TQGridLayout *grid2 = new TQGridLayout(widget2, 3,2, 6,6);
+ m_cb = new TQCheckBox(i18n("Create a new file and add it to this project"),widget2);
m_cb->setChecked(true);
- m_lb = new QLabel(i18n("File&name (relative to where the project file is):"),widget2);
+ m_lb = new TQLabel(i18n("File&name (relative to where the project file is):"),widget2);
m_file = new KLineEdit(widget2);
m_lb->setBuddy(m_file);
m_templateIconView = new TemplateIconView(widget2);
m_templateIconView->setTemplateManager(m_templateManager);
m_templateManager->scanForTemplates();
m_templateIconView->fillWithTemplates(KileDocument::LaTeX);
- QWhatsThis::add(m_cb, i18n("If you want Kile to create a new file and add it to the project, then check this option and select a template from the list that will appear below."));
+ TQWhatsThis::add(m_cb, i18n("If you want Kile to create a new file and add it to the project, then check this option and select a template from the list that will appear below."));
grid2->addMultiCellWidget(m_cb, 0,0, 0,1);
grid2->addWidget(m_lb, 1,0);
grid2->addWidget(m_file, 1,1);
grid2->addMultiCellWidget(m_templateIconView, 2,2, 0,1);
grid2->setColStretch(1,1);
- connect(m_cb, SIGNAL(clicked()), this, SLOT(clickedCreateNewFileCb()));
+ connect(m_cb, TQT_SIGNAL(clicked()), this, TQT_SLOT(clickedCreateNewFileCb()));
// third groupbox
m_egrid->addWidget(m_sel_extensions, 6,0);
@@ -262,7 +262,7 @@ KileNewProjectDlg::KileNewProjectDlg(KileTemplate::Manager *templateManager, Kil
m_egrid->addWidget(m_lbPredefinedExtensions, 7,0);
m_egrid->addMultiCellWidget(m_lbStandardExtensions, 7,7, 1,3);
- // add to layout
+ // add to tqlayout
vbox->addWidget(m_pgroup);
vbox->addWidget(group2);
vbox->addWidget(m_egroup);
@@ -307,16 +307,16 @@ void KileNewProjectDlg::clickedCreateNewFileCb()
}
}
-QString KileNewProjectDlg::bare()
+TQString KileNewProjectDlg::bare()
{
- return projectTitle().lower().stripWhiteSpace().replace(QRegExp("\\s*"),"")+".kilepr";
+ return projectTitle().lower().stripWhiteSpace().tqreplace(TQRegExp("\\s*"),"")+".kilepr";
}
void KileNewProjectDlg::browseLocation()
{
- QString dir = m_dir;
- if (!QFileInfo(m_dir).exists())
- dir = QString::null;
+ TQString dir = m_dir;
+ if (!TQFileInfo(m_dir).exists())
+ dir = TQString();
dir = KFileDialog::getExistingDirectory(dir, this);
@@ -331,8 +331,8 @@ void KileNewProjectDlg::browseLocation()
void KileNewProjectDlg::makeProjectPath()
{
m_filename=bare();
- KILE_DEBUG() << "BEFORE " << QFileInfo(location()).absFilePath() << " " << QFileInfo(location()).dirPath() << endl;
- m_dir = QFileInfo(location()).dirPath();
+ KILE_DEBUG() << "BEFORE " << TQFileInfo(location()).absFilePath() << " " << TQFileInfo(location()).dirPath() << endl;
+ m_dir = TQFileInfo(location()).dirPath();
if (m_dir.right(1) != "/") m_dir = m_dir + '/';
KILE_DEBUG() << "LOCATION " << location() << " AND " << m_dir << endl;
@@ -344,7 +344,7 @@ void KileNewProjectDlg::slotOk()
if ( ! acceptUserExtensions() )
return;
- //replace ~ and environment variables in the paths
+ //tqreplace ~ and environment variables in the paths
KURLCompletion uc;
uc.setReplaceEnv(true);
uc.setReplaceHome(true);
@@ -365,9 +365,9 @@ void KileNewProjectDlg::slotOk()
return;
}
- QFileInfo fi(location().stripWhiteSpace());
- QFileInfo dr(fi.dirPath());
- QDir dir = dr.dir();
+ TQFileInfo fi(location().stripWhiteSpace());
+ TQFileInfo dr(fi.dirPath());
+ TQDir dir = dr.dir();
if ( location().stripWhiteSpace().right(7) != ".kilepr")
{
@@ -388,8 +388,8 @@ void KileNewProjectDlg::slotOk()
if (! dr.exists())
{
bool suc = true;
- QStringList dirs = QStringList::split("/", fi.dirPath());
- QString path;
+ TQStringList dirs = TQStringList::split("/", fi.dirPath());
+ TQString path;
for (uint i=0; i < dirs.count(); ++i)
{
@@ -433,15 +433,15 @@ void KileNewProjectDlg::slotOk()
if ( validURL != fileURL )
m_file->setText(validURL.fileName());
- if ( QFileInfo( QDir(fi.dirPath()) , file().stripWhiteSpace()).exists() )
+ if ( TQFileInfo( TQDir(fi.dirPath()) , file().stripWhiteSpace()).exists() )
{
- if (KMessageBox::warningYesNo(this, i18n("The file \"%1\" already exists, overwrite it?").arg(file()),
+ if (KMessageBox::warningYesNo(this, i18n("The file \"%1\" already exists, overwrite it?").tqarg(file()),
i18n("File Already Exists")) == KMessageBox::No)
return;
}
}
- if (QFileInfo(location()).exists())
+ if (TQFileInfo(location()).exists())
{
KMessageBox::error(this, i18n("The project file already exists, please select another name. Delete the existing project file if your intention was to overwrite it."),i18n("Project File Already Exists"));
return;
@@ -470,11 +470,11 @@ TemplateItem* KileNewProjectDlg::getSelection() const
/*
* KileProjectOptionsDlg
*/
-KileProjectOptionsDlg::KileProjectOptionsDlg(KileProject *project, KileDocument::Extensions *extensions, QWidget *parent, const char * name) :
- KileProjectDlgBase(i18n("Project Options"), extensions, parent, name )
+KileProjectOptionsDlg::KileProjectOptionsDlg(KileProject *project, KileDocument::Extensions *extensions, TQWidget *tqparent, const char * name) :
+ KileProjectDlgBase(i18n("Project Options"), extensions, tqparent, name )
{
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(plainPage(), 6,6 );
+ TQVBoxLayout *vbox = new TQVBoxLayout(plainPage(), 6,6 );
m_pgrid->addWidget(m_plabel, 0,0);
m_pgrid->addWidget(m_title, 0,2);
@@ -490,23 +490,23 @@ KileProjectOptionsDlg::KileProjectOptionsDlg(KileProject *project, KileDocument:
m_egrid->addMultiCellWidget(m_lbStandardExtensions, 7,7, 1,3);
// third groupbox
- QVGroupBox* group3 = new QVGroupBox(i18n("Properties"), plainPage());
+ TQVGroupBox* group3 = new TQVGroupBox(i18n("Properties"), plainPage());
group3->setColumnLayout(0, Qt::Vertical );
- group3->layout()->setSpacing( 6 );
- group3->layout()->setMargin( 11 );
- QGridLayout *grid3 = new QGridLayout( group3->layout() );
- grid3->setAlignment( Qt::AlignTop );
+ group3->tqlayout()->setSpacing( 6 );
+ group3->tqlayout()->setMargin( 11 );
+ TQGridLayout *grid3 = new TQGridLayout( group3->tqlayout() );
+ grid3->tqsetAlignment( TQt::AlignTop );
m_master = new KComboBox(false, group3, "master");
//m_master->setDisabled(true);
- QLabel *lb1 = new QLabel(i18n("&Master document:"), group3);
+ TQLabel *lb1 = new TQLabel(i18n("&Master document:"), group3);
lb1->setBuddy(m_master);
- lb1->setMinimumWidth( m_sel_extensions->sizeHint().width() );
- QWhatsThis::add(m_master, whatsthisMaster);
- QWhatsThis::add(lb1,whatsthisMaster);
+ lb1->setMinimumWidth( m_sel_extensions->tqsizeHint().width() );
+ TQWhatsThis::add(m_master, whatsthisMaster);
+ TQWhatsThis::add(lb1,whatsthisMaster);
m_master->insertItem(i18n("(auto-detect)"));
- QPtrListIterator<KileProjectItem> rit(*(project->rootItems()));
+ TQPtrListIterator<KileProjectItem> rit(*(project->rootItems()));
int index = 0;
while (rit.current())
{
@@ -523,7 +523,7 @@ KileProjectOptionsDlg::KileProjectOptionsDlg(KileProject *project, KileDocument:
if (project->masterDocument().isNull())
m_master->setCurrentItem(0);
- QLabel *lb2 = new QLabel(i18n("&QuickBuild configuration:"), group3);
+ TQLabel *lb2 = new TQLabel(i18n("&QuickBuild configuration:"), group3);
m_cbQuick = new KComboBox(group3);
lb2->setBuddy(m_cbQuick);
m_cbQuick->insertItem(tool_default);
@@ -533,8 +533,8 @@ KileProjectOptionsDlg::KileProjectOptionsDlg(KileProject *project, KileDocument:
//don't put this after the call to toggleMakeIndex
setProject(project, true);
- m_ckMakeIndex = new QCheckBox(i18n("&MakeIndex options"), group3);
- connect(m_ckMakeIndex, SIGNAL(toggled(bool)), this, SLOT(toggleMakeIndex(bool)));
+ m_ckMakeIndex = new TQCheckBox(i18n("&MakeIndex options"), group3);
+ connect(m_ckMakeIndex, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(toggleMakeIndex(bool)));
m_leMakeIndex = new KLineEdit(group3);
m_ckMakeIndex->setChecked(project->useMakeIndexOptions());
toggleMakeIndex(m_ckMakeIndex->isChecked());
@@ -547,7 +547,7 @@ KileProjectOptionsDlg::KileProjectOptionsDlg(KileProject *project, KileDocument:
grid3->addMultiCellWidget(m_leMakeIndex,2,2,1,2);
grid3->setColStretch(2,1);
- // add to layout
+ // add to tqlayout
vbox->addWidget(m_pgroup);
vbox->addWidget(m_egroup);
vbox->addWidget(group3);
@@ -575,14 +575,14 @@ void KileProjectOptionsDlg::slotOk()
this->m_project->setName(m_title->text());
- QPtrListIterator<KileProjectItem> rit(*(m_project->rootItems()));
+ TQPtrListIterator<KileProjectItem> rit(*(m_project->rootItems()));
while (rit.current())
{
if ((*rit)->url().fileName() == m_master->currentText() )
m_project->setMasterDocument((*rit)->url().path());
++rit;
}
- if (m_master->currentItem() == 0) m_project->setMasterDocument(QString::null);
+ if (m_master->currentItem() == 0) m_project->setMasterDocument(TQString());
m_val_extensions[m_sel_extensions->currentItem()] = m_extensions->text();
diff --git a/src/kile/kileprojectdlgs.h b/src/kile/kileprojectdlgs.h
index a9cb85a..63d620e 100644
--- a/src/kile/kileprojectdlgs.h
+++ b/src/kile/kileprojectdlgs.h
@@ -16,9 +16,9 @@
#ifndef KILEPROJECTDLGS_H
#define KILEPROJECTDLGS_H
-#include <qcheckbox.h>
-#include <qlayout.h>
-#include <qvgroupbox.h>
+#include <tqcheckbox.h>
+#include <tqlayout.h>
+#include <tqvgroupbox.h>
#include <kdialogbase.h>
#include <klineedit.h>
@@ -28,10 +28,10 @@
#include "templates.h"
class TemplateIconView;
-class QLabel;
+class TQLabel;
class KileProject;
class KComboBox;
-class QVGroupBox;
+class TQVGroupBox;
class TemplateItem;
namespace KileDocument { class Extensions; }
@@ -40,19 +40,20 @@ namespace KileTemplate { class Manager; }
class KileProjectDlgBase : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileProjectDlgBase(const QString &caption, KileDocument::Extensions *extensions, QWidget *parent = 0, const char * name = 0);
+ KileProjectDlgBase(const TQString &caption, KileDocument::Extensions *extensions, TQWidget *tqparent = 0, const char * name = 0);
virtual ~KileProjectDlgBase();
void setProject(KileProject *project, bool override);
virtual KileProject* project();
- void setProjectTitle(const QString &title) { m_title->setText(title); }
- const QString projectTitle() { return m_title->text(); }
+ void setProjectTitle(const TQString &title) { m_title->setText(title); }
+ const TQString projectTitle() { return m_title->text(); }
- void setExtensions(KileProjectItem::Type type, const QString & ext);
- const QString extensions(KileProjectItem::Type type)
+ void setExtensions(KileProjectItem::Type type, const TQString & ext);
+ const TQString extensions(KileProjectItem::Type type)
{ return m_val_extensions[type-1]; }
protected slots:
@@ -61,22 +62,22 @@ protected slots:
private slots:
void slotExtensionsHighlighted(int index);
- void slotExtensionsTextChanged(const QString &text);
+ void slotExtensionsTextChanged(const TQString &text);
protected:
KileDocument::Extensions *m_extmanager;
- QVGroupBox *m_pgroup, *m_egroup;
- QGridLayout *m_pgrid, *m_egrid;
- QLabel *m_plabel;
+ TQVGroupBox *m_pgroup, *m_egroup;
+ TQGridLayout *m_pgrid, *m_egrid;
+ TQLabel *m_plabel;
KLineEdit *m_title, *m_extensions;
- QLabel *m_lbPredefinedExtensions, *m_lbStandardExtensions;
+ TQLabel *m_lbPredefinedExtensions, *m_lbStandardExtensions;
KileProject *m_project;
KComboBox *m_sel_extensions;
- QString m_val_extensions[KileProjectItem::Other - 1];
- QString m_val_standardExtensions[KileProjectItem::Other - 1];
+ TQString m_val_extensions[KileProjectItem::Other - 1];
+ TQString m_val_standardExtensions[KileProjectItem::Other - 1];
bool acceptUserExtensions();
@@ -85,18 +86,19 @@ protected:
class KileNewProjectDlg : public KileProjectDlgBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileNewProjectDlg(KileTemplate::Manager *templateManager, KileDocument::Extensions *extensions, QWidget* parent = 0, const char* name = 0);
+ KileNewProjectDlg(KileTemplate::Manager *templateManager, KileDocument::Extensions *extensions, TQWidget* tqparent = 0, const char* name = 0);
~KileNewProjectDlg();
KileProject* project();
- QString bare();
- QString location() { return m_location->text(); }
+ TQString bare();
+ TQString location() { return m_location->text(); }
TemplateItem* getSelection() const;
- QString file() { return m_file->text();}
+ TQString file() { return m_file->text();}
bool createNewFile() { return m_cb->isChecked(); }
private slots:
@@ -110,19 +112,20 @@ private:
KileTemplate::Manager *m_templateManager;
KLineEdit *m_location, *m_file, *m_name;
TemplateIconView *m_templateIconView;
- QCheckBox *m_cb;
- QLabel *m_lb;
+ TQCheckBox *m_cb;
+ TQLabel *m_lb;
KPushButton *m_pbChooseDir;
- QString m_dir, m_filename;
+ TQString m_dir, m_filename;
};
class KileProjectOptionsDlg : public KileProjectDlgBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileProjectOptionsDlg(KileProject *project, KileDocument::Extensions *extensions, QWidget *parent = 0, const char * name = 0);
+ KileProjectOptionsDlg(KileProject *project, KileDocument::Extensions *extensions, TQWidget *tqparent = 0, const char * name = 0);
~KileProjectOptionsDlg();
private slots:
@@ -132,7 +135,7 @@ private slots:
private:
KComboBox *m_master, *m_cbQuick;
KLineEdit *m_leMakeIndex;
- QCheckBox *m_ckMakeIndex;
+ TQCheckBox *m_ckMakeIndex;
};
#endif
diff --git a/src/kile/kileprojectview.cpp b/src/kile/kileprojectview.cpp
index aa8a3b2..44d4b5a 100644
--- a/src/kile/kileprojectview.cpp
+++ b/src/kile/kileprojectview.cpp
@@ -17,7 +17,7 @@
#include "kileprojectview.h"
-#include <qheader.h>
+#include <tqheader.h>
#include <klocale.h>
#include <kstandarddirs.h>
@@ -50,14 +50,14 @@ void KileProjectViewItem::urlChanged(const KURL &url)
}
}
-void KileProjectViewItem::nameChanged(const QString & name)
+void KileProjectViewItem::nameChanged(const TQString & name)
{
setText(0,name);
}
void KileProjectViewItem::isrootChanged(bool isroot)
{
- KILE_DEBUG() << "SLOT isrootChanged " << text(0) << " to " << isroot << endl;
+ KILE_DEBUG() << "TQT_SLOT isrootChanged " << text(0) << " to " << isroot << endl;
if (isroot)
{
setPixmap(0,SmallIcon("masteritem"));
@@ -78,7 +78,7 @@ void KileProjectViewItem::slotURLChanged(KileDocument::Info*, const KURL & url)
urlChanged(url);
}
-int KileProjectViewItem::compare(QListViewItem * i, int col, bool ascending) const
+int KileProjectViewItem::compare(TQListViewItem * i, int col, bool ascending) const
{
KileProjectViewItem *item = dynamic_cast<KileProjectViewItem*>(i);
@@ -95,18 +95,18 @@ int KileProjectViewItem::compare(QListViewItem * i, int col, bool ascending) con
else if ( type() == KileType::Folder )
return -1;
else
- return QListViewItem::compare(i, col, ascending);
+ return TQListViewItem::compare(i, col, ascending);
}
/*
* KileProjectView
*/
-KileProjectView::KileProjectView(QWidget *parent, KileInfo *ki) : KListView(parent), m_ki(ki), m_nProjects(0), m_toggle(0)
+KileProjectView::KileProjectView(TQWidget *tqparent, KileInfo *ki) : KListView(tqparent), m_ki(ki), m_nProjects(0), m_toggle(0)
{
addColumn(i18n("Files & Projects"),-1);
addColumn(i18n("Include in Archive"),10);
setSorting(-1);
- setFocusPolicy(QWidget::ClickFocus);
+ setFocusPolicy(TQ_ClickFocus);
header()->hide();
setRootIsDecorated(true);
setAllColumnsShowFocus(true);
@@ -115,14 +115,14 @@ KileProjectView::KileProjectView(QWidget *parent, KileInfo *ki) : KListView(pare
m_popup = new KPopupMenu(this, "projectview_popup");
- connect(this, SIGNAL(contextMenu(KListView *, QListViewItem *, const QPoint & )), this,SLOT(popup(KListView *, QListViewItem * , const QPoint & )));
+ connect(this, TQT_SIGNAL(contextMenu(KListView *, TQListViewItem *, const TQPoint & )), this,TQT_SLOT(popup(KListView *, TQListViewItem * , const TQPoint & )));
- connect(this, SIGNAL(executed(QListViewItem*)), this, SLOT(slotClicked(QListViewItem*)));
+ connect(this, TQT_SIGNAL(executed(TQListViewItem*)), this, TQT_SLOT(slotClicked(TQListViewItem*)));
setAcceptDrops(true);
- connect(this, SIGNAL(dropped(QDropEvent *, QListViewItem *)), m_ki->docManager(), SLOT(openDroppedURLs(QDropEvent *)));
+ connect(this, TQT_SIGNAL(dropped(TQDropEvent *, TQListViewItem *)), m_ki->docManager(), TQT_SLOT(openDroppedURLs(TQDropEvent *)));
}
-void KileProjectView::slotClicked(QListViewItem *item)
+void KileProjectView::slotClicked(TQListViewItem *item)
{
if (item == 0)
item = currentItem();
@@ -233,7 +233,7 @@ void KileProjectView::slotRun(int id)
}
//FIXME clean this mess up
-void KileProjectView::popup(KListView *, QListViewItem * item, const QPoint & point)
+void KileProjectView::popup(KListView *, TQListViewItem * item, const TQPoint & point)
{
if (item != 0)
{
@@ -260,7 +260,7 @@ void KileProjectView::popup(KListView *, QListViewItem * item, const QPoint &
apps->insertSeparator();
apps->insertItem(i18n("Other..."), 0);
- connect(apps, SIGNAL(activated(int)), this, SLOT(slotRun(int)));
+ connect(apps, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotRun(int)));
m_popup->insertItem(SmallIcon("fork"), i18n("&Open With"),apps);
insertsep = true;
}
@@ -284,7 +284,7 @@ void KileProjectView::popup(KListView *, QListViewItem * item, const QPoint &
m_popup->insertItem(SmallIcon("project_add"),i18n("&Add to Project"), KPV_ID_ADD);
insertsep = true;
}
- connect(m_popup, SIGNAL(activated(int)), this, SLOT(slotFile(int)));
+ connect(m_popup, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotFile(int)));
}
else if (itm->type() == KileType::ProjectItem || itm->type() == KileType::ProjectExtra)
{
@@ -304,7 +304,7 @@ void KileProjectView::popup(KListView *, QListViewItem * item, const QPoint &
m_popup->insertItem(SmallIcon("project_remove"),i18n("&Remove From Project"), KPV_ID_REMOVE);
insertsep = true;
}
- connect(m_popup, SIGNAL(activated(int)), this, SLOT(slotProjectItem(int)));
+ connect(m_popup, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotProjectItem(int)));
}
else if (itm->type() == KileType::Project)
{
@@ -317,7 +317,7 @@ void KileProjectView::popup(KListView *, QListViewItem * item, const QPoint &
m_popup->insertItem(SmallIcon("relation"),i18n("Refresh Project &Tree"), KPV_ID_BUILDTREE);
m_popup->insertItem(SmallIcon("configure"),i18n("Project &Options"), KPV_ID_OPTIONS);
m_popup->insertItem(SmallIcon("package"),i18n("&Archive"), KPV_ID_ARCHIVE);
- connect(m_popup, SIGNAL(activated(int)), this, SLOT(slotProject(int)));
+ connect(m_popup, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotProject(int)));
insertsep = true;
}
@@ -342,15 +342,15 @@ void KileProjectView::makeTheConnection(KileProjectViewItem *item)
if (project==0)
kdWarning() << "makeTheConnection COULD NOT FIND AN PROJECT OBJECT FOR " << item->url().path() << endl;
else
- connect(project, SIGNAL(nameChanged(const QString &)), item, SLOT(nameChanged(const QString &)));
+ connect(project, TQT_SIGNAL(nameChanged(const TQString &)), item, TQT_SLOT(nameChanged(const TQString &)));
}
else
{
KileDocument::TextInfo *docinfo = m_ki->docManager()->textInfoFor(item->url().path());
item->setInfo(docinfo);
if (docinfo ==0 ) {KILE_DEBUG() << "\tmakeTheConnection COULD NOT FIND A DOCINFO" << endl; return;}
- connect(docinfo, SIGNAL(urlChanged(KileDocument::Info*, const KURL&)), item, SLOT(slotURLChanged(KileDocument::Info*, const KURL&)));
- connect(docinfo, SIGNAL(isrootChanged(bool)), item, SLOT(isrootChanged(bool)));
+ connect(docinfo, TQT_SIGNAL(urlChanged(KileDocument::Info*, const KURL&)), item, TQT_SLOT(slotURLChanged(KileDocument::Info*, const KURL&)));
+ connect(docinfo, TQT_SIGNAL(isrootChanged(bool)), item, TQT_SLOT(isrootChanged(bool)));
//set the pixmap
item->isrootChanged(docinfo->isLaTeXRoot());
}
@@ -358,23 +358,23 @@ void KileProjectView::makeTheConnection(KileProjectViewItem *item)
KileProjectViewItem* KileProjectView::folder(const KileProjectItem *pi, KileProjectViewItem *item)
{
- KileProjectViewItem *parent = parentFor(pi, item);
+ KileProjectViewItem *tqparent = tqparentFor(pi, item);
- if (parent == 0)
+ if (tqparent == 0)
{
- kdError() << "no parent for " << pi->url().path() << endl;
+ kdError() << "no tqparent for " << pi->url().path() << endl;
return 0;
}
- // we have already found the parent folder
- if ( parent->type() == KileType::Folder )
- return parent;
+ // we have already found the tqparent folder
+ if ( tqparent->type() == KileType::Folder )
+ return tqparent;
- // we are looking at the children, if there is an existing folder for this type
+ // we are looking at the tqchildren, if there is an existing folder for this type
KileProjectViewItem *folder;
// determine the foldername for this type
- QString foldername;
+ TQString foldername;
switch ( pi->type() )
{
case (KileProjectItem::ProjectFile):
@@ -394,7 +394,7 @@ KileProjectViewItem* KileProjectView::folder(const KileProjectItem *pi, KileProj
// if there already a folder for this type on this level?
bool found = false;
- folder = parent->firstChild();
+ folder = tqparent->firstChild();
while ( folder )
{
if ( folder->text(0) == foldername )
@@ -408,8 +408,8 @@ KileProjectViewItem* KileProjectView::folder(const KileProjectItem *pi, KileProj
// if no folder was found, we must create a new one
if ( ! found )
{
- folder = new KileProjectViewItem(parent,foldername);
- KILE_DEBUG() << "new folder: " << parent->url().url() << endl;
+ folder = new KileProjectViewItem(tqparent,foldername);
+ KILE_DEBUG() << "new folder: " << tqparent->url().url() << endl;
folder->setFolder(pi->type());
folder->setType(KileType::Folder);
@@ -420,16 +420,16 @@ KileProjectViewItem* KileProjectView::folder(const KileProjectItem *pi, KileProj
void KileProjectView::add(const KileProject *project)
{
- KileProjectViewItem *parent = new KileProjectViewItem(this, project);
+ KileProjectViewItem *tqparent = new KileProjectViewItem(this, project);
- parent->setType(KileType::Project);
- parent->setURL(project->url());
- parent->setOpen(true);
- parent->setPixmap(0,SmallIcon("relation"));
- makeTheConnection(parent);
+ tqparent->setType(KileType::Project);
+ tqparent->setURL(project->url());
+ tqparent->setOpen(true);
+ tqparent->setPixmap(0,SmallIcon("relation"));
+ makeTheConnection(tqparent);
- //KileProjectViewItem *nonsrc = new KileProjectViewItem(parent, i18n("non-source"));
- //parent->setNonSrc(nonsrc);
+ //KileProjectViewItem *nonsrc = new KileProjectViewItem(tqparent, i18n("non-source"));
+ //tqparent->setNonSrc(nonsrc);
refreshProjectTree(project);
@@ -457,7 +457,7 @@ KileProjectViewItem * KileProjectView::itemFor(const KURL & url)
{
KileProjectViewItem *item=0;
- QListViewItemIterator it(this);
+ TQListViewItemIterator it(this);
while (it.current())
{
item = static_cast<KileProjectViewItem*>(*it);
@@ -469,15 +469,15 @@ KileProjectViewItem * KileProjectView::itemFor(const KURL & url)
return item;
}
-KileProjectViewItem* KileProjectView::parentFor(const KileProjectItem *projitem, KileProjectViewItem *projvi)
+KileProjectViewItem* KileProjectView::tqparentFor(const KileProjectItem *projitem, KileProjectViewItem *projvi)
{
- //find parent projectviewitem of projitem
- KileProjectItem *parpi = projitem->parent();
+ //find tqparent projectviewitem of projitem
+ KileProjectItem *parpi = projitem->tqparent();
KileProjectViewItem *parpvi = projvi, *vi;
if (parpi) {
- //find parent viewitem that has an URL parpi->url()
- QListViewItemIterator it( projvi );
+ //find tqparent viewitem that has an URL parpi->url()
+ TQListViewItemIterator it( projvi );
KILE_DEBUG() << "\tlooking for " << parpi->url().path() << endl;
while (it.current())
{
@@ -520,9 +520,9 @@ KileProjectViewItem* KileProjectView::add(KileProjectItem *projitem, KileProject
projvi= projectViewItemFor(project->url());
}
- KILE_DEBUG() << "\tparent projectviewitem " << projvi->url().fileName() << endl;
+ KILE_DEBUG() << "\ttqparent projectviewitem " << projvi->url().fileName() << endl;
- KileProjectViewItem *item, *parent;
+ KileProjectViewItem *item, *tqparent;
switch (projitem->type()) {
case (KileProjectItem::Source):
@@ -531,15 +531,15 @@ KileProjectViewItem* KileProjectView::add(KileProjectItem *projitem, KileProject
item->setPixmap(0,SmallIcon("projectitem"));
break;
case (KileProjectItem::Package):
- parent = folder(projitem, projvi);
- item = new KileProjectViewItem(parent, projitem);
+ tqparent = folder(projitem, projvi);
+ item = new KileProjectViewItem(tqparent, projitem);
item->setType(KileType::ProjectItem);
item->setPixmap(0,SmallIcon("projectitem"));
break;
case (KileProjectItem::ProjectFile):
default:
- parent = folder(projitem, projvi);
- item = new KileProjectViewItem(parent, projitem);
+ tqparent = folder(projitem, projvi);
+ item = new KileProjectViewItem(tqparent, projitem);
item->setType(KileType::ProjectExtra);
item->setPixmap(0,SmallIcon( (projitem->type()==KileProjectItem::ProjectFile) ? "kile" : "file" ));
break;
@@ -568,14 +568,14 @@ void KileProjectView::addTree(KileProjectItem *projitem, KileProjectViewItem * p
void KileProjectView::refreshProjectTree(const KileProject *project)
{
KILE_DEBUG() << "\tKileProjectView::refreshProjectTree(" << project->name() << ")" << endl;
- KileProjectViewItem *parent= projectViewItemFor(project->url());
+ KileProjectViewItem *tqparent= projectViewItemFor(project->url());
//clean the tree
- if (parent)
+ if (tqparent)
{
- KILE_DEBUG() << "\tusing parent projectviewitem " << parent->url().fileName() << endl;
- parent->setFolder(-1);
- QListViewItem *vi = parent->firstChild(), *next;
+ KILE_DEBUG() << "\tusing tqparent projectviewitem " << tqparent->url().fileName() << endl;
+ tqparent->setFolder(-1);
+ TQListViewItem *vi = tqparent->firstChild(), *next;
while (vi)
{
next = vi->nextSibling();
@@ -587,25 +587,25 @@ void KileProjectView::refreshProjectTree(const KileProject *project)
return;
//create the non-sources dir
- //KileProjectViewItem *nonsrc = new KileProjectViewItem(parent, i18n("non-sources"));
- //parent->setNonSrc(nonsrc);
+ //KileProjectViewItem *nonsrc = new KileProjectViewItem(tqparent, i18n("non-sources"));
+ //tqparent->setNonSrc(nonsrc);
- QPtrList<KileProjectItem> list = *(project->rootItems());
- QPtrListIterator<KileProjectItem> it(list);
+ TQPtrList<KileProjectItem> list = *(project->rootItems());
+ TQPtrListIterator<KileProjectItem> it(list);
while (it.current())
{
- addTree(*it, parent);
+ addTree(*it, tqparent);
++it;
}
- parent->sortChildItems(0, true);
+ tqparent->sortChildItems(0, true);
}
void KileProjectView::add(const KURL & url)
{
KILE_DEBUG() << "\tKileProjectView::adding item " << url.path() << endl;
//check if file is already present
- QListViewItemIterator it( this );
+ TQListViewItemIterator it( this );
KileProjectViewItem *item;
while ( it.current())
{
@@ -659,7 +659,7 @@ void KileProjectView::remove(const KURL &url)
void KileProjectView::removeItem(const KileProjectItem *projitem, bool open)
{
- QListViewItemIterator it( this );
+ TQListViewItemIterator it( this );
KileProjectViewItem *item;
while ( it.current())
{
@@ -667,7 +667,7 @@ void KileProjectView::removeItem(const KileProjectItem *projitem, bool open)
if ( (item->type() == KileType::ProjectItem) && (item->projectItem() == projitem) )
{
KILE_DEBUG() << "removing projectviewitem" << endl;
- item->parent()->takeItem(item);
+ item->tqparent()->takeItem(item);
delete item;
}
++it;
@@ -683,7 +683,7 @@ void KileProjectView::removeItem(const KileProjectItem *projitem, bool open)
}
-bool KileProjectView::acceptDrag(QDropEvent *e) const
+bool KileProjectView::acceptDrag(TQDropEvent *e) const
{
return KURLDrag::canDecode(e); // only accept URL drops
}
diff --git a/src/kile/kileprojectview.h b/src/kile/kileprojectview.h
index 6761428..315e2db 100644
--- a/src/kile/kileprojectview.h
+++ b/src/kile/kileprojectview.h
@@ -30,29 +30,30 @@ class KileInfo;
namespace KileType {enum ProjectView { Project=0, ProjectItem, ProjectExtra, File, Folder};}
-class KileProjectViewItem : public QObject, public KListViewItem
+class KileProjectViewItem : public TQObject, public KListViewItem
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileProjectViewItem (QListView *parent, KileProjectItem *item, bool ar = false) : KListViewItem(parent, item->url().fileName()), m_folder(-1), m_projectItem(item) { setArchiveState(ar);}
- KileProjectViewItem (QListView *parent, QListViewItem *after, KileProjectItem *item, bool ar = false) : KListViewItem(parent, after, item->url().fileName()), m_folder(-1), m_projectItem(item) { setArchiveState(ar);}
- KileProjectViewItem (QListViewItem *parent, KileProjectItem *item, bool ar = false) : KListViewItem(parent, item->url().fileName()), m_folder(-1), m_projectItem(item) { setArchiveState(ar);}
+ KileProjectViewItem (TQListView *tqparent, KileProjectItem *item, bool ar = false) : KListViewItem(tqparent, item->url().fileName()), m_folder(-1), m_projectItem(item) { setArchiveState(ar);}
+ KileProjectViewItem (TQListView *tqparent, TQListViewItem *after, KileProjectItem *item, bool ar = false) : KListViewItem(tqparent, after, item->url().fileName()), m_folder(-1), m_projectItem(item) { setArchiveState(ar);}
+ KileProjectViewItem (TQListViewItem *tqparent, KileProjectItem *item, bool ar = false) : KListViewItem(tqparent, item->url().fileName()), m_folder(-1), m_projectItem(item) { setArchiveState(ar);}
//use this to create folders
- KileProjectViewItem (QListViewItem *parent, const QString & name) : KListViewItem(parent, name), m_folder(-1), m_projectItem(0L) {}
+ KileProjectViewItem (TQListViewItem *tqparent, const TQString & name) : KListViewItem(tqparent, name), m_folder(-1), m_projectItem(0L) {}
//use this to create non-project files
- KileProjectViewItem (QListView *parent, const QString & name) : KListViewItem(parent, name), m_folder(-1), m_projectItem(0L) {}
+ KileProjectViewItem (TQListView *tqparent, const TQString & name) : KListViewItem(tqparent, name), m_folder(-1), m_projectItem(0L) {}
- KileProjectViewItem (QListView *parent, const KileProject *project) : KListViewItem(parent, project->name()), m_folder(-1), m_projectItem(0L) {}
+ KileProjectViewItem (TQListView *tqparent, const KileProject *project) : KListViewItem(tqparent, project->name()), m_folder(-1), m_projectItem(0L) {}
~KileProjectViewItem() {KILE_DEBUG() << "DELETING PROJVIEWITEM " << m_url.fileName() << endl;}
KileProjectItem* projectItem() { return m_projectItem; }
- KileProjectViewItem* parent() { return dynamic_cast<KileProjectViewItem*>(KListViewItem::parent()); }
+ KileProjectViewItem* tqparent() { return dynamic_cast<KileProjectViewItem*>(KListViewItem::tqparent()); }
KileProjectViewItem* firstChild() { return dynamic_cast<KileProjectViewItem*>(KListViewItem::firstChild()); }
KileProjectViewItem* nextSibling() { return dynamic_cast<KileProjectViewItem*>(KListViewItem::nextSibling()); }
@@ -62,7 +63,7 @@ public:
void setType(KileType::ProjectView type) {m_type = type;}
KileType::ProjectView type() const { return m_type;}
- int compare(QListViewItem * i, int col, bool ascending) const;
+ int compare(TQListViewItem * i, int col, bool ascending) const;
void setURL(const KURL & url) { m_url=url;}
const KURL& url() { return m_url;}
@@ -77,7 +78,7 @@ public slots:
* @warning Does nothing if "url" is empty !
**/
void urlChanged(const KURL & url);
- void nameChanged(const QString & name);
+ void nameChanged(const TQString & name);
void isrootChanged(bool isroot);
private slots:
@@ -98,9 +99,10 @@ private:
class KileProjectView : public KListView
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileProjectView(QWidget *parent, KileInfo *ki);
+ KileProjectView(TQWidget *tqparent, KileInfo *ki);
signals:
void fileSelected(const KileProjectItem *);
@@ -118,7 +120,7 @@ signals:
void buildProjectTree(const KURL &);
public slots:
- void slotClicked(QListViewItem * item = 0);
+ void slotClicked(TQListViewItem * item = 0);
void slotFile(int id);
void slotProjectItem(int id);
@@ -139,13 +141,13 @@ public:
KileProjectViewItem* projectViewItemFor(const KURL &);
KileProjectViewItem* itemFor(const KURL &);
- KileProjectViewItem* parentFor(const KileProjectItem *projitem, KileProjectViewItem *projvi);
+ KileProjectViewItem* tqparentFor(const KileProjectItem *projitem, KileProjectViewItem *projvi);
protected:
- virtual bool acceptDrag(QDropEvent *e) const;
+ virtual bool acceptDrag(TQDropEvent *e) const;
private slots:
- void popup(KListView *, QListViewItem *, const QPoint &);
+ void popup(KListView *, TQListViewItem *, const TQPoint &);
private:
void makeTheConnection(KileProjectViewItem *);
diff --git a/src/kile/kilesidebar.cpp b/src/kile/kilesidebar.cpp
index abeda90..3bb6f72 100644
--- a/src/kile/kilesidebar.cpp
+++ b/src/kile/kilesidebar.cpp
@@ -17,8 +17,8 @@
#include "kilesidebar.h"
-#include <qwidgetstack.h>
-#include <qlayout.h>
+#include <tqwidgetstack.h>
+#include <tqlayout.h>
#include <kdeversion.h>
#include "kiledebug.h"
@@ -26,8 +26,8 @@
#include "symbolview.h"
-KileSideBar::KileSideBar(int size, QWidget *parent, const char *name, Qt::Orientation orientation /*= Vertical*/) :
- QFrame(parent, name),
+KileSideBar::KileSideBar(int size, TQWidget *tqparent, const char *name, Qt::Orientation orientation /*=Qt::Vertical*/) :
+ TQFrame(tqparent, name),
m_nTabs(0),
m_nCurrent(0),
m_bMinimized(false),
@@ -36,24 +36,24 @@ KileSideBar::KileSideBar(int size, QWidget *parent, const char *name, Qt::Orient
m_nSize(size)
{
setLineWidth(0);
- setSizePolicy(QSizePolicy::Ignored, QSizePolicy::Ignored);
+ tqsetSizePolicy(TQSizePolicy::Ignored, TQSizePolicy::Ignored);
- QLayout *layout;
+ TQLayout *tqlayout;
- m_tabStack = new QWidgetStack(this);
- m_tabStack->setSizePolicy(QSizePolicy::Ignored, QSizePolicy::Ignored);
+ m_tabStack = new TQWidgetStack(this);
+ m_tabStack->tqsetSizePolicy(TQSizePolicy::Ignored, TQSizePolicy::Ignored);
KileMultiTabBar::KileMultiTabBarMode tabbarori = KileMultiTabBar::Horizontal;
KileMultiTabBar::KileMultiTabBarPosition tabbarpos = KileMultiTabBar::Top;
if ( orientation == Qt::Horizontal )
{
- layout = new QVBoxLayout(this);
+ tqlayout = new TQVBoxLayout(this);
tabbarori = KileMultiTabBar::Horizontal;
tabbarpos = KileMultiTabBar::Top;
}
else if ( orientation == Qt::Vertical )
{
- layout = new QHBoxLayout(this);
+ tqlayout = new TQHBoxLayout(this);
tabbarori = KileMultiTabBar::Vertical;
tabbarpos = KileMultiTabBar::Right;
}
@@ -72,16 +72,16 @@ KileSideBar::KileSideBar(int size, QWidget *parent, const char *name, Qt::Orient
setMinimumHeight(m_tabBar->height());
m_nMinSize = m_tabBar->height();
m_nMaxSize = m_tabBar->maximumHeight();
- layout->add(m_tabBar);
- layout->add(m_tabStack);
+ tqlayout->add(m_tabBar);
+ tqlayout->add(m_tabStack);
}
else if ( orientation == Qt::Vertical )
{
setMinimumWidth(m_tabBar->width());
m_nMinSize = m_tabBar->width();
m_nMaxSize = m_tabBar->maximumWidth();
- layout->add(m_tabStack);
- layout->add(m_tabBar);
+ tqlayout->add(m_tabStack);
+ tqlayout->add(m_tabBar);
}
}
@@ -89,13 +89,13 @@ KileSideBar::~KileSideBar()
{
}
-int KileSideBar::addTab(QWidget *tab, const QPixmap &pic, const QString &text /* = QString::null*/)
+int KileSideBar::addTab(TQWidget *tab, const TQPixmap &pic, const TQString &text /* = TQString()*/)
{
m_widgetToIndex[tab] = m_nTabs;
m_tabBar->appendTab(pic, m_nTabs, text);
m_tabStack->addWidget(tab, m_nTabs);
- connect(m_tabBar->tab(m_nTabs), SIGNAL(clicked(int)), this, SLOT(showTab(int)));
+ connect(m_tabBar->tab(m_nTabs), TQT_SIGNAL(clicked(int)), this, TQT_SLOT(showTab(int)));
return m_nTabs++;
}
@@ -139,7 +139,7 @@ void KileSideBar::expand()
emit visibilityChanged(true);
}
-QWidget* KileSideBar::currentPage()
+TQWidget* KileSideBar::currentPage()
{
return m_tabStack->visibleWidget();
}
@@ -161,16 +161,16 @@ int KileSideBar::findNextShownTab(int i)
return -1;
}
-void KileSideBar::removePage(QWidget *w)
+void KileSideBar::removePage(TQWidget *w)
{
- QMap<QWidget*,int>::iterator it = m_widgetToIndex.find(w);
+ TQMap<TQWidget*,int>::iterator it = m_widgetToIndex.tqfind(w);
if(it == m_widgetToIndex.end())
{
return;
}
int index = *it;
m_tabStack->removeWidget(w);
- disconnect(m_tabBar->tab(index), SIGNAL(clicked(int)), this, SLOT(showTab(int)));
+ disconnect(m_tabBar->tab(index), TQT_SIGNAL(clicked(int)), this, TQT_SLOT(showTab(int)));
m_tabBar->removeTab(index);
m_widgetToIndex.remove(it);
if(index == m_nCurrent && m_nTabs >= 2)
@@ -180,8 +180,8 @@ void KileSideBar::removePage(QWidget *w)
--m_nTabs;
}
-void KileSideBar::setPageVisible(QWidget *w, bool b) {
- QMap<QWidget*,int>::iterator it = m_widgetToIndex.find(w);
+void KileSideBar::setPageVisible(TQWidget *w, bool b) {
+ TQMap<TQWidget*,int>::iterator it = m_widgetToIndex.tqfind(w);
if(it == m_widgetToIndex.end())
{
return;
@@ -198,9 +198,9 @@ void KileSideBar::setPageVisible(QWidget *w, bool b) {
}
}
-void KileSideBar::showPage(QWidget *widget)
+void KileSideBar::showPage(TQWidget *widget)
{
- if ( m_widgetToIndex.contains(widget) )
+ if ( m_widgetToIndex.tqcontains(widget) )
switchToTab(m_widgetToIndex[widget]);
}
@@ -238,8 +238,8 @@ void KileSideBar::switchToTab(int id)
m_nCurrent = id;
}
-KileBottomBar::KileBottomBar(int size, QWidget *parent, const char *name) :
- KileSideBar(size, parent, name, Qt::Horizontal)
+KileBottomBar::KileBottomBar(int size, TQWidget *tqparent, const char *name) :
+ KileSideBar(size, tqparent, name, Qt::Horizontal)
{}
void KileBottomBar::shrink()
diff --git a/src/kile/kilesidebar.h b/src/kile/kilesidebar.h
index 8a713d1..f53c0bf 100644
--- a/src/kile/kilesidebar.h
+++ b/src/kile/kilesidebar.h
@@ -18,25 +18,26 @@
#ifndef KILESIDEBAR_H
#define KILESIDEBAR_H
-#include <qframe.h>
-#include <qmap.h>
+#include <tqframe.h>
+#include <tqmap.h>
-class QWidgetStack;
+class TQWidgetStack;
class KileMultiTabBar;
class SymbolView;
/**
@author Jeroen Wijnhout
*/
-class KileSideBar : public QFrame
+class KileSideBar : public TQFrame
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileSideBar(int size, QWidget *parent = 0, const char *name = 0, Qt::Orientation orientation = Qt::Vertical);
+ KileSideBar(int size, TQWidget *tqparent = 0, const char *name = 0, Qt::Orientation orientation = Qt::Vertical);
~KileSideBar();
- int addTab(QWidget *tab, const QPixmap &pic, const QString &text = QString::null);
+ int addTab(TQWidget *tab, const TQPixmap &pic, const TQString &text = TQString());
int currentTab() { return m_nCurrent; }
@@ -45,8 +46,8 @@ public:
void setSize(int sz) { m_nSize = sz; }
int size() { return m_nSize; }
- QWidget* currentPage();
- void removePage(QWidget *w);
+ TQWidget* currentPage();
+ void removePage(TQWidget *w);
/**
* Shows or hides the tab connected to the widget "w". If the tab to be hidden is
@@ -55,7 +56,7 @@ public:
* @param b set to "true" to show the tab connected to the widget "w", "false" to
* hide it
**/
- void setPageVisible(QWidget *w, bool b);
+ void setPageVisible(TQWidget *w, bool b);
signals:
void visibilityChanged(bool );
@@ -67,7 +68,7 @@ public slots:
virtual void expand();
void showTab(int);
- void showPage(QWidget *);
+ void showPage(TQWidget *);
void toggleTab();
void switchToTab(int id);
@@ -75,12 +76,12 @@ private:
int findNextShownTab(int i);
protected:
- QWidgetStack *m_tabStack;
+ TQWidgetStack *m_tabStack;
KileMultiTabBar *m_tabBar;
int m_nTabs;
int m_nCurrent;
- QMap<int,int> m_indexToPage;
- QMap<QWidget*,int> m_widgetToIndex;
+ TQMap<int,int> m_indexToPage;
+ TQMap<TQWidget*,int> m_widgetToIndex;
bool m_bMinimized;
int m_nMinSize, m_nMaxSize, m_nSize;
};
@@ -88,9 +89,10 @@ protected:
class KileBottomBar : public KileSideBar
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileBottomBar(int size, QWidget *parent = 0, const char *name = 0);
+ KileBottomBar(int size, TQWidget *tqparent = 0, const char *name = 0);
void shrink();
void expand();
diff --git a/src/kile/kilestatsdlg.cpp b/src/kile/kilestatsdlg.cpp
index a351469..e02a427 100644
--- a/src/kile/kilestatsdlg.cpp
+++ b/src/kile/kilestatsdlg.cpp
@@ -17,8 +17,8 @@
// A dialog that displays statistical information about the active project/file
-KileStatsDlg::KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo, QWidget* parent, const char* name, const QString &caption)
- : KDialogBase(KDialogBase::Tabbed,0,parent,name,true,caption, KDialogBase::Help | KDialogBase::Ok | KDialogBase::User1 | KDialogBase::User2 , KDialogBase::Ok, false),
+KileStatsDlg::KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo, TQWidget* tqparent, const char* name, const TQString &caption)
+ : KDialogBase(KDialogBase::Tabbed,0,tqparent,name,true,caption, KDialogBase::Help | KDialogBase::Ok | KDialogBase::User1 | KDialogBase::User2 , KDialogBase::Ok, false),
m_project(project),
m_docinfo(docinfo)
{
@@ -30,7 +30,7 @@ KileStatsDlg::KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo
m_summarystats[0]=m_summarystats[1]=m_summarystats[2]=m_summarystats[3]=m_summarystats[4]=m_summarystats[5]=0;
const long* stats;
- QString tempName;
+ TQString tempName;
uint index=0;
KileWidgetStatistics* tempWidget;
KileWidgetStatistics* summary;
@@ -51,13 +51,13 @@ KileStatsDlg::KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo
if(!m_project) // the active doc doesn't belong to a project
{
- setCaption(i18n("Statistics for %1").arg(m_docinfo->getDoc()->url().fileName()));
+ setCaption(i18n("Statistics for %1").tqarg(m_docinfo->getDoc()->url().fileName()));
stats = m_docinfo->getStatistics();
fillWidget(stats,summary);
}
else // active doc belongs to a project
{
- setCaption(i18n("Statistics for the Project %1").arg(m_project->name()));
+ setCaption(i18n("Statistics for the Project %1").tqarg(m_project->name()));
KILE_DEBUG() << "Project file is " << project->baseURL() << endl;
KileProjectItemList *items = project->items();
@@ -104,7 +104,7 @@ KileStatsDlg::KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo
#endif
}
}
-// setInitialSize( QSize(550,560), true);
+// setInitialSize( TQSize(550,560), true);
}
KileStatsDlg::~KileStatsDlg()
@@ -123,15 +123,15 @@ if (!stats || !widget)
if(m_hasSelection)
widget->m_warning->setText(i18n("WARNING: These are the statistics for the selected text only."));
-widget->m_wordChar->setText(QString::number(stats[0]));
-widget->m_commandChar->setText(QString::number(stats[1]));
-widget->m_whitespaceChar->setText(QString::number(stats[2]));
-widget->m_totalChar->setText(QString::number(stats[0]+stats[1]+stats[2]));
+widget->m_wordChar->setText(TQString::number(stats[0]));
+widget->m_commandChar->setText(TQString::number(stats[1]));
+widget->m_whitespaceChar->setText(TQString::number(stats[2]));
+widget->m_totalChar->setText(TQString::number(stats[0]+stats[1]+stats[2]));
-widget->m_wordString->setText(QString::number(stats[3]));
-widget->m_commandString->setText(QString::number(stats[4]));
-widget->m_environmentString->setText(QString::number(stats[5]));
-widget->m_totalString->setText(QString::number(stats[3]+stats[4]+stats[5]));
+widget->m_wordString->setText(TQString::number(stats[3]));
+widget->m_commandString->setText(TQString::number(stats[4]));
+widget->m_environmentString->setText(TQString::number(stats[5]));
+widget->m_totalString->setText(TQString::number(stats[3]+stats[4]+stats[5]));
widget->updateColumns();
}
@@ -139,41 +139,41 @@ widget->updateColumns();
void KileStatsDlg::slotUser1() // Copy
{
KILE_DEBUG() << "Copy Button was clicked" << endl;
- KILE_DEBUG() << "Open tab is " << activePageIndex() << ' ' + ( m_pagetoname.contains(activePageIndex()) ? m_pagetoname[activePageIndex()] : "No such entry" )<< endl;
+ KILE_DEBUG() << "Open tab is " << activePageIndex() << ' ' + ( m_pagetoname.tqcontains(activePageIndex()) ? m_pagetoname[activePageIndex()] : "No such entry" )<< endl;
- QClipboard *clip = KApplication::clipboard();
- QString text;
+ TQClipboard *clip = KApplication::tqclipboard();
+ TQString text;
convertText(&text,false);
- clip->setText(text,QClipboard::Selection); // the text will be available with the middle mouse button
+ clip->setText(text,TQClipboard::Selection); // the text will be available with the middle mouse button
}
void KileStatsDlg::slotUser2() // CopyAsLaTeX
{
KILE_DEBUG() << "CopyAsLateX Button was clicked" << endl;
- KILE_DEBUG() << "Open tab is " << activePageIndex() << ' ' + ( m_pagetoname.contains(activePageIndex()) ? m_pagetoname[activePageIndex()] : "No such entry" )<< endl;
+ KILE_DEBUG() << "Open tab is " << activePageIndex() << ' ' + ( m_pagetoname.tqcontains(activePageIndex()) ? m_pagetoname[activePageIndex()] : "No such entry" )<< endl;
- QClipboard *clip = KApplication::clipboard();
- QString text;
+ TQClipboard *clip = KApplication::tqclipboard();
+ TQString text;
convertText(&text,true);
- clip->setText(text,QClipboard::Selection);
+ clip->setText(text,TQClipboard::Selection);
}
-void KileStatsDlg::convertText(QString* text, bool forLaTeX) // the bool determines if we want plainText or LaTeXCode
+void KileStatsDlg::convertText(TQString* text, bool forLaTeX) // the bool determines if we want plainText or LaTeXCode
{
KileWidgetStatistics* widget = m_pagetowidget[activePageIndex()];
- QString name = m_pagetoname[activePageIndex()];
- QString charGroupName = i18n("Characters"); // always ensure that these are the same than in kilestatswidget.ui, there is no way to get the label of a button group, so this ugly hack is needed
- QString stringGroupName = i18n("Strings");
+ TQString name = m_pagetoname[activePageIndex()];
+ TQString charGroupName = i18n("Characters"); // always ensure that these are the same than in kilestatswidget.ui, there is no way to get the label of a button group, so this ugly hack is needed
+ TQString stringGroupName = i18n("Strings");
if (forLaTeX)
text->append("\\begin{tabular}{ll}\n");
if(m_project && activePageIndex())
- text->append(i18n("Statistics for project %1, file %2").arg(m_project->name()).arg(name));
+ text->append(i18n("Statistics for project %1, file %2").tqarg(m_project->name()).tqarg(name));
else if(m_project)
- text->append(i18n("Statistics for project %1").arg(m_project->name()));
+ text->append(i18n("Statistics for project %1").tqarg(m_project->name()));
else if(m_docinfo->getDoc()->url().isValid())
- text->append(i18n("Statistics for %1").arg(m_docinfo->getDoc()->url().fileName()));
+ text->append(i18n("Statistics for %1").tqarg(m_docinfo->getDoc()->url().fileName()));
else
text->append(i18n("Statistics for Untitled"));
diff --git a/src/kile/kilestatsdlg.h b/src/kile/kilestatsdlg.h
index e1aeb50..ef98267 100644
--- a/src/kile/kilestatsdlg.h
+++ b/src/kile/kilestatsdlg.h
@@ -20,8 +20,8 @@
#include <kdialogbase.h>
#include <klocale.h>
#include <kapplication.h>
-#include <qclipboard.h>
-#include <qlabel.h>
+#include <tqclipboard.h>
+#include <tqlabel.h>
#include "kileproject.h"
#include "kiledocumentinfo.h"
@@ -30,14 +30,14 @@
class KileStatsDlg : public KDialogBase
{
public:
- KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo, QWidget* parent = 0, const char* name = 0, const QString &caption = QString::null);
+ KileStatsDlg(KileProject *project, KileDocument::TextInfo* docinfo, TQWidget* tqparent = 0, const char* name = 0, const TQString &caption = TQString());
~KileStatsDlg();
private:
void fillWidget (const long* stats, KileWidgetStatistics* widget);
void slotUser1();
void slotUser2();
- void convertText(QString* text, bool forLaTeX);
+ void convertText(TQString* text, bool forLaTeX);
protected:
KileProject *m_project;
@@ -45,8 +45,8 @@ protected:
long *m_summarystats;
bool m_hasSelection;
bool m_notAllFilesOpenWarning;
- QMap<int, KileWidgetStatistics*> m_pagetowidget;
- QMap<int, QString> m_pagetoname;
+ TQMap<int, KileWidgetStatistics*> m_pagetowidget;
+ TQMap<int, TQString> m_pagetoname;
};
#endif
diff --git a/src/kile/kilestatswidget.cpp b/src/kile/kilestatswidget.cpp
index 63ac7e6..3dc0d71 100644
--- a/src/kile/kilestatswidget.cpp
+++ b/src/kile/kilestatswidget.cpp
@@ -18,89 +18,89 @@
#include <kdialog.h>
#include <klocale.h>
-#include <qvariant.h>
-#include <qlabel.h>
-#include <qbuttongroup.h>
-#include <qlayout.h>
-#include <qtooltip.h>
-#include <qwhatsthis.h>
+#include <tqvariant.h>
+#include <tqlabel.h>
+#include <tqbuttongroup.h>
+#include <tqlayout.h>
+#include <tqtooltip.h>
+#include <tqwhatsthis.h>
#include "kiledebug.h"
-KileWidgetStatistics::KileWidgetStatistics( QWidget* parent, const char* name, WFlags fl )
- : QWidget( parent, name, fl )
+KileWidgetStatistics::KileWidgetStatistics( TQWidget* tqparent, const char* name, WFlags fl )
+ : TQWidget( tqparent, name, fl )
{
- QVBoxLayout *vbox = new QVBoxLayout(parent, 5,KDialog::spacingHint() );
+ TQVBoxLayout *vbox = new TQVBoxLayout(tqparent, 5,KDialog::spacingHint() );
// characters groupbox
- QGroupBox *chargroup = new QGroupBox( i18n("Characters"),parent);
+ TQGroupBox *chargroup = new TQGroupBox( i18n("Characters"),tqparent);
chargroup->setColumnLayout(0, Qt::Vertical );
- chargroup->layout()->setSpacing( 6 );
- chargroup->layout()->setMargin( 11 );
- chargrouplayout = new QGridLayout( chargroup->layout() );
- chargrouplayout->setAlignment( Qt::AlignTop );
-
- m_wordCharText = new QLabel(i18n("Words and numbers:"), chargroup);
- m_commandCharText = new QLabel(i18n("LaTeX commands and environments:"), chargroup);
- m_whitespaceCharText = new QLabel(i18n("Punctuation, delimiter and whitespaces:"), chargroup);
- m_totalCharText = new QLabel(i18n("Total characters:"), chargroup);
- m_wordChar = new QLabel( chargroup, "m_wordChar" );
- m_commandChar = new QLabel( chargroup, "m_commandChar" );
- m_whitespaceChar = new QLabel( chargroup, "m_whitespaceChar" );
- m_totalChar = new QLabel( chargroup, "m_totalChar" );
-
- QFrame *charframe = new QFrame(chargroup);
- charframe->setFrameStyle(QFrame::HLine | QFrame::Sunken);
+ chargroup->tqlayout()->setSpacing( 6 );
+ chargroup->tqlayout()->setMargin( 11 );
+ chargrouptqlayout = new TQGridLayout( chargroup->tqlayout() );
+ chargrouptqlayout->tqsetAlignment( TQt::AlignTop );
+
+ m_wordCharText = new TQLabel(i18n("Words and numbers:"), chargroup);
+ m_commandCharText = new TQLabel(i18n("LaTeX commands and environments:"), chargroup);
+ m_whitespaceCharText = new TQLabel(i18n("Punctuation, delimiter and whitespaces:"), chargroup);
+ m_totalCharText = new TQLabel(i18n("Total characters:"), chargroup);
+ m_wordChar = new TQLabel( chargroup, "m_wordChar" );
+ m_commandChar = new TQLabel( chargroup, "m_commandChar" );
+ m_whitespaceChar = new TQLabel( chargroup, "m_whitespaceChar" );
+ m_totalChar = new TQLabel( chargroup, "m_totalChar" );
+
+ TQFrame *charframe = new TQFrame(chargroup);
+ charframe->setFrameStyle(TQFrame::HLine | TQFrame::Sunken);
charframe->setLineWidth(1);
- chargrouplayout->addWidget( m_wordCharText, 0,0 );
- chargrouplayout->addWidget( m_commandCharText, 1,0 );
- chargrouplayout->addWidget( m_whitespaceCharText, 2,0 );
- chargrouplayout->addWidget( m_totalCharText, 4,0 );
- chargrouplayout->addWidget( m_wordChar, 0,2,Qt::AlignRight );
- chargrouplayout->addWidget( m_commandChar, 1,2,Qt::AlignRight );
- chargrouplayout->addWidget( m_whitespaceChar, 2,2,Qt::AlignRight );
- chargrouplayout->addMultiCellWidget( charframe, 3,3,1,2 );
- chargrouplayout->addWidget( m_totalChar, 4,2,Qt::AlignRight );
- chargrouplayout->setColSpacing(1,16);
- chargrouplayout->setColSpacing(3,1);
- chargrouplayout->setColStretch(3,1);
+ chargrouptqlayout->addWidget( m_wordCharText, 0,0 );
+ chargrouptqlayout->addWidget( m_commandCharText, 1,0 );
+ chargrouptqlayout->addWidget( m_whitespaceCharText, 2,0 );
+ chargrouptqlayout->addWidget( m_totalCharText, 4,0 );
+ chargrouptqlayout->addWidget( m_wordChar, 0,2,TQt::AlignRight );
+ chargrouptqlayout->addWidget( m_commandChar, 1,2,TQt::AlignRight );
+ chargrouptqlayout->addWidget( m_whitespaceChar, 2,2,TQt::AlignRight );
+ chargrouptqlayout->addMultiCellWidget( charframe, 3,3,1,2 );
+ chargrouptqlayout->addWidget( m_totalChar, 4,2,TQt::AlignRight );
+ chargrouptqlayout->setColSpacing(1,16);
+ chargrouptqlayout->setColSpacing(3,1);
+ chargrouptqlayout->setColStretch(3,1);
// string groupbox
- QGroupBox *stringgroup = new QGroupBox( i18n("Strings"),parent);
+ TQGroupBox *stringgroup = new TQGroupBox( i18n("Strings"),tqparent);
stringgroup->setColumnLayout(0, Qt::Vertical );
- stringgroup->layout()->setSpacing( 6 );
- stringgroup->layout()->setMargin( 11 );
- stringgrouplayout = new QGridLayout( stringgroup->layout() );
- stringgrouplayout->setAlignment( Qt::AlignTop );
-
- m_wordStringText = new QLabel(i18n("Words:"), stringgroup);
- m_commandStringText = new QLabel(i18n("LaTeX commands:"), stringgroup);
- m_environmentStringText = new QLabel(i18n("LaTeX environments:"), stringgroup);
- m_totalStringText = new QLabel(i18n("Total strings:"), stringgroup);
- m_wordString = new QLabel( stringgroup, "m_wordString" );
- m_commandString = new QLabel( stringgroup, "m_commandStringText" );
- m_environmentString = new QLabel( stringgroup, "m_environmentStringText" );
- m_totalString = new QLabel( stringgroup, "m_totalStringText" );
-
- QFrame *stringframe = new QFrame(stringgroup);
- stringframe->setFrameStyle(QFrame::HLine | QFrame::Sunken);
+ stringgroup->tqlayout()->setSpacing( 6 );
+ stringgroup->tqlayout()->setMargin( 11 );
+ stringgrouptqlayout = new TQGridLayout( stringgroup->tqlayout() );
+ stringgrouptqlayout->tqsetAlignment( TQt::AlignTop );
+
+ m_wordStringText = new TQLabel(i18n("Words:"), stringgroup);
+ m_commandStringText = new TQLabel(i18n("LaTeX commands:"), stringgroup);
+ m_environmentStringText = new TQLabel(i18n("LaTeX environments:"), stringgroup);
+ m_totalStringText = new TQLabel(i18n("Total strings:"), stringgroup);
+ m_wordString = new TQLabel( stringgroup, "m_wordString" );
+ m_commandString = new TQLabel( stringgroup, "m_commandStringText" );
+ m_environmentString = new TQLabel( stringgroup, "m_environmentStringText" );
+ m_totalString = new TQLabel( stringgroup, "m_totalStringText" );
+
+ TQFrame *stringframe = new TQFrame(stringgroup);
+ stringframe->setFrameStyle(TQFrame::HLine | TQFrame::Sunken);
stringframe->setLineWidth(1);
- stringgrouplayout->addWidget( m_wordStringText, 0,0 );
- stringgrouplayout->addWidget( m_commandStringText, 1,0 );
- stringgrouplayout->addWidget( m_environmentStringText, 2,0 );
- stringgrouplayout->addWidget( m_totalStringText, 4,0 );
- stringgrouplayout->addWidget( m_wordString, 0,2,Qt::AlignRight );
- stringgrouplayout->addWidget( m_commandString, 1,2,Qt::AlignRight );
- stringgrouplayout->addWidget( m_environmentString, 2,2,Qt::AlignRight );
- stringgrouplayout->addMultiCellWidget( stringframe, 3,3,1,2 );
- stringgrouplayout->addWidget( m_totalString, 4,2,Qt::AlignRight );
- stringgrouplayout->setColSpacing(1,16);
- stringgrouplayout->setColSpacing(3,1);
- stringgrouplayout->setColStretch(3,1);
-
- m_commentAboutHelp = new QLabel(parent);
- m_warning = new QLabel(parent);
+ stringgrouptqlayout->addWidget( m_wordStringText, 0,0 );
+ stringgrouptqlayout->addWidget( m_commandStringText, 1,0 );
+ stringgrouptqlayout->addWidget( m_environmentStringText, 2,0 );
+ stringgrouptqlayout->addWidget( m_totalStringText, 4,0 );
+ stringgrouptqlayout->addWidget( m_wordString, 0,2,TQt::AlignRight );
+ stringgrouptqlayout->addWidget( m_commandString, 1,2,TQt::AlignRight );
+ stringgrouptqlayout->addWidget( m_environmentString, 2,2,TQt::AlignRight );
+ stringgrouptqlayout->addMultiCellWidget( stringframe, 3,3,1,2 );
+ stringgrouptqlayout->addWidget( m_totalString, 4,2,TQt::AlignRight );
+ stringgrouptqlayout->setColSpacing(1,16);
+ stringgrouptqlayout->setColSpacing(3,1);
+ stringgrouptqlayout->setColStretch(3,1);
+
+ m_commentAboutHelp = new TQLabel(tqparent);
+ m_warning = new TQLabel(tqparent);
vbox->addWidget(chargroup);
vbox->addWidget(stringgroup);
@@ -109,10 +109,10 @@ KileWidgetStatistics::KileWidgetStatistics( QWidget* parent, const char* name, W
vbox->addWidget(m_warning);
vbox->addStretch(1);
- int w = m_commandCharText->sizeHint().width();
- if ( m_whitespaceCharText->sizeHint().width() > w )
- w = m_whitespaceCharText->sizeHint().width();
- stringgrouplayout->setColSpacing(0,w);
+ int w = m_commandCharText->tqsizeHint().width();
+ if ( m_whitespaceCharText->tqsizeHint().width() > w )
+ w = m_whitespaceCharText->tqsizeHint().width();
+ stringgrouptqlayout->setColSpacing(0,w);
}
@@ -122,11 +122,11 @@ KileWidgetStatistics::~KileWidgetStatistics()
void KileWidgetStatistics::updateColumns()
{
- int w = m_totalChar->sizeHint().width();
- if ( m_totalString->sizeHint().width() > w )
- w = m_totalString->sizeHint().width();
- chargrouplayout->setColSpacing(2,w);
- stringgrouplayout->setColSpacing(2,w);
+ int w = m_totalChar->tqsizeHint().width();
+ if ( m_totalString->tqsizeHint().width() > w )
+ w = m_totalString->tqsizeHint().width();
+ chargrouptqlayout->setColSpacing(2,w);
+ stringgrouptqlayout->setColSpacing(2,w);
}
diff --git a/src/kile/kilestatswidget.h b/src/kile/kilestatswidget.h
index d30ee64..20754b5 100644
--- a/src/kile/kilestatswidget.h
+++ b/src/kile/kilestatswidget.h
@@ -17,48 +17,49 @@
#ifndef KILEWIDGETSTATISTICS_H
#define KILEWIDGETSTATISTICS_H
-#include <qvariant.h>
-#include <qwidget.h>
+#include <tqvariant.h>
+#include <tqwidget.h>
-class QVBoxLayout;
-class QGridLayout;
-class QLabel;
-class QGroupBox;
+class TQVBoxLayout;
+class TQGridLayout;
+class TQLabel;
+class TQGroupBox;
-class KileWidgetStatistics : public QWidget
+class KileWidgetStatistics : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileWidgetStatistics( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
+ KileWidgetStatistics( TQWidget* tqparent = 0, const char* name = 0, WFlags fl = 0 );
~KileWidgetStatistics();
- QLabel* m_commentAboutHelp;
- QLabel* m_warning;
+ TQLabel* m_commentAboutHelp;
+ TQLabel* m_warning;
- QLabel* m_wordChar;
- QLabel* m_commandChar;
- QLabel* m_whitespaceChar;
- QLabel* m_totalChar;
- QLabel* m_wordCharText;
- QLabel* m_commandCharText;
- QLabel* m_whitespaceCharText;
- QLabel* m_totalCharText;
+ TQLabel* m_wordChar;
+ TQLabel* m_commandChar;
+ TQLabel* m_whitespaceChar;
+ TQLabel* m_totalChar;
+ TQLabel* m_wordCharText;
+ TQLabel* m_commandCharText;
+ TQLabel* m_whitespaceCharText;
+ TQLabel* m_totalCharText;
- QLabel* m_wordString;
- QLabel* m_environmentString;
- QLabel* m_commandString;
- QLabel* m_totalString;
- QLabel* m_wordStringText;
- QLabel* m_environmentStringText;
- QLabel* m_commandStringText;
- QLabel* m_totalStringText;
+ TQLabel* m_wordString;
+ TQLabel* m_environmentString;
+ TQLabel* m_commandString;
+ TQLabel* m_totalString;
+ TQLabel* m_wordStringText;
+ TQLabel* m_environmentStringText;
+ TQLabel* m_commandStringText;
+ TQLabel* m_totalStringText;
void updateColumns();
private:
- QGridLayout *chargrouplayout;
- QGridLayout *stringgrouplayout;
+ TQGridLayout *chargrouptqlayout;
+ TQGridLayout *stringgrouptqlayout;
};
diff --git a/src/kile/kilestdactions.cpp b/src/kile/kilestdactions.cpp
index 1c17cf2..336613a 100644
--- a/src/kile/kilestdactions.cpp
+++ b/src/kile/kilestdactions.cpp
@@ -7,7 +7,7 @@
//
// Author: Jeroen Wijnhout <Jeroen.Wijnhout@kdemail.net>, (C) 2003
//
-// Copyright: See COPYING file that comes with parent distribution
+// Copyright: See COPYING file that comes with tqparent distribution
//
/***************************************************************************
@@ -30,344 +30,344 @@
namespace KileStdActions
{
-void setupStdTags(KileInfo *ki, KMainWindow *parent)
+void setupStdTags(KileInfo *ki, KMainWindow *tqparent)
{
- (void) new KileAction::Tag(i18n("Document Class Selection - \\documentclass{}"),0,parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(), "tag_documentclass",
+ (void) new KileAction::Tag(i18n("Document Class Selection - \\documentclass{}"),0,TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(), "tag_documentclass",
"\\documentclass[10pt]{","}", 21,0,i18n("\\documentclass[options]{class}\nclass : article,report,book,letter\nsize options : 10pt, 11pt, 12pt\npaper size options: a4paper, a5paper, b5paper, letterpaper, legalpaper, executivepaper\n"
"other options: \nlandscape -- selects landscape format; default is portrait. \ntitlepage, notitlepage -- selects if there should be a separate title page.\nleqno -- display equation number on left side of equations; default is right side.\n"
- "fleqn -- display formulae flush left; default is centered.\nonecolumn, twocolumn -- one or two columns; defaults to one column\noneside, twoside -- selects one- or two-sided layout.\n" ));
+ "fleqn -- display formulae flush left; default is centered.\nonecolumn, twocolumn -- one or two columns; defaults to one column\noneside, twoside -- selects one- or two-sided tqlayout.\n" ));
- (void) new KileAction::Tag(i18n("Package Import - \\usepackage{}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_usepackage",
+ (void) new KileAction::Tag(i18n("Package Import - \\usepackage{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_usepackage",
"\\usepackage{","}",12,0,i18n("Any options given in the \\documentclass command that are unknown by the selected document class\n"
"are passed on to the packages loaded with \\usepackage."));
- (void) new KileAction::Tag(i18n("AMS Packages"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_amspackages","\\usepackage{amsmath}\n\\usepackage{amsfonts}\n\\usepackage{amssymb}\n",QString::null,0,3,i18n("The principal American Mathematical Society packages"));
- (void) new KileAction::Tag(i18n("Start Document Body - \\begin{document}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_document","\\begin{document}\n", "\n\\end{document}", 0,1,i18n("Text is allowed only between \\begin{document} and \\end{document}.\nThe 'preamble' (before \\begin{document} ) may contain declarations only."));
- (void) new KileAction::Tag(i18n("Generate Title - \\maketitle"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_maketitle","\\maketitle",QString::null,10,0,i18n("This command generates a title on a separate title page\n- except in the article class, where the title normally goes at the top of the first page."));
- (void) new KileAction::Tag(i18n("Table of Contents - \\tableofcontents"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_tableofcontents","\\tableofcontents",QString::null,16,0,i18n("Put this command where you want the table of contents to go"));
- (void) new KileAction::Tag(i18n("Title Definition - \\title{}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_title","\\title{","}",7,0,i18n( "\\title{text}\nThe \\title command declares text to be the title.\nUse \\\\ to tell LaTeX where to start a new line in a long title."));
- (void) new KileAction::Tag(i18n("Author Definition - \\author{}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_author","\\author{","}",8,0,i18n( "\\author{names}\nThe \\author command declares the author(s), where names is a list of authors separated by \\and commands."));
-
- (void) new KileAction::Tag(i18n("Center - \\begin{center}"),"text_center",0, parent,
- SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_center", "\\begin{center}\n","%E\n\\end{center}", 0,1, i18n("Each line must be terminated with the string \\\\."));
- (void) new KileAction::Tag(i18n("Align Left - \\begin{flushleft}"),"text_left",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_flushleft", "\\begin{flushleft}\n","%E\n\\end{flushleft}", 0,1, i18n("Each line must be terminated with the string \\\\.") );
- (void) new KileAction::Tag(i18n("Align Right - \\begin{flushright}"),"text_right",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_flushright", "\\begin{flushright}\n","%E\n\\end{flushright}", 0,1, i18n("Each line must be terminated with the string \\\\.") );
- (void) new KileAction::Tag(i18n("Quote - \\begin{quote}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_quote","\\begin{quote}\n","%E\n\\end{quote} ",0,1,i18n("The text is justified at both margins.\nLeaving a blank line between text produces a new paragraph.") );
- (void) new KileAction::Tag(i18n("Quotation - \\begin{quotation}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_quotation","\\begin{quotation}\n","%E\n\\end{quotation} ",0,1, i18n("The text is justified at both margins and there is paragraph indentation.\nLeaving a blank line between text produces a new paragraph.") );
- (void) new KileAction::Tag(i18n("Verse - \\begin{verse}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_verse", "\\begin{verse}\n","%E\n\\end{verse} ",0,1,i18n("The verse environment is designed for poetry.\nSeparate the lines of each stanza with \\\\, and use one or more blank lines to separate the stanzas.") );
-
- (void) new KileAction::Tag(i18n("Verbatim - \\begin{verbatim}"),"verbatim",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_verbatim","\\begin{verbatim}\n","%E\n\\end{verbatim} ",0,1,i18n("Environment that gets LaTeX to print exactly what you type in."));
- (void) new KileAction::Tag(i18n("Bulleted List - \\begin{itemize}"),"itemize",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_itemize","\\begin{itemize}\n%E\\item \n", "\\end{itemize}\n", 6,1,i18n("The itemize environment produces a 'bulleted' list.\nEach item of an itemized list begins with an \\item command."));
- (void) new KileAction::Tag(i18n("Enumeration - \\begin{enumerate}"),"enumerate",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_enumerate","\\begin{enumerate}\n%E\\item \n","\\end{enumerate}\n", 6,1,i18n("The enumerate environment produces a numbered list.\nEach item of an enumerated list begins with an \\item command."));
- (void) new KileAction::Tag(i18n("Description - \\begin{description}"),"description",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_description","\\begin{description}\n%E\\item[]\n ", "\\end{description}",6,1,i18n("The description environment is used to make labeled lists.\nEach item of the list begins with an \\item[label] command.\nThe 'label' is bold face and flushed right."));
-
- (void) new KileAction::Tag(i18n("Table - \\begin{table}"),"frame_spreadsheet",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_table","\\begin{table}\n","%E\n\\caption{}\n\\end{table} ",0,1,
+ (void) new KileAction::Tag(i18n("AMS Packages"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_amspackages","\\usepackage{amsmath}\n\\usepackage{amsfonts}\n\\usepackage{amssymb}\n",TQString(),0,3,i18n("The principal American Mathematical Society packages"));
+ (void) new KileAction::Tag(i18n("Start Document Body - \\begin{document}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_document","\\begin{document}\n", "\n\\end{document}", 0,1,i18n("Text is allowed only between \\begin{document} and \\end{document}.\nThe 'preamble' (before \\begin{document} ) may contain declarations only."));
+ (void) new KileAction::Tag(i18n("Generate Title - \\maketitle"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_maketitle","\\maketitle",TQString(),10,0,i18n("This command generates a title on a separate title page\n- except in the article class, where the title normally goes at the top of the first page."));
+ (void) new KileAction::Tag(i18n("Table of Contents - \\tableofcontents"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_tableofcontents","\\tableofcontents",TQString(),16,0,i18n("Put this command where you want the table of contents to go"));
+ (void) new KileAction::Tag(i18n("Title Definition - \\title{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_title","\\title{","}",7,0,i18n( "\\title{text}\nThe \\title command declares text to be the title.\nUse \\\\ to tell LaTeX where to start a new line in a long title."));
+ (void) new KileAction::Tag(i18n("Author Definition - \\author{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_author","\\author{","}",8,0,i18n( "\\author{names}\nThe \\author command declares the author(s), where names is a list of authors separated by \\and commands."));
+
+ (void) new KileAction::Tag(i18n("Center - \\begin{center}"),"text_center",0, TQT_TQOBJECT(tqparent),
+ TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_center", "\\begin{center}\n","%E\n\\end{center}", 0,1, i18n("Each line must be terminated with the string \\\\."));
+ (void) new KileAction::Tag(i18n("Align Left - \\begin{flushleft}"),"text_left",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_flushleft", "\\begin{flushleft}\n","%E\n\\end{flushleft}", 0,1, i18n("Each line must be terminated with the string \\\\.") );
+ (void) new KileAction::Tag(i18n("Align Right - \\begin{flushright}"),"text_right",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_flushright", "\\begin{flushright}\n","%E\n\\end{flushright}", 0,1, i18n("Each line must be terminated with the string \\\\.") );
+ (void) new KileAction::Tag(i18n("Quote - \\begin{quote}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_quote","\\begin{quote}\n","%E\n\\end{quote} ",0,1,i18n("The text is justified at both margins.\nLeaving a blank line between text produces a new paragraph.") );
+ (void) new KileAction::Tag(i18n("Quotation - \\begin{quotation}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_quotation","\\begin{quotation}\n","%E\n\\end{quotation} ",0,1, i18n("The text is justified at both margins and there is paragraph indentation.\nLeaving a blank line between text produces a new paragraph.") );
+ (void) new KileAction::Tag(i18n("Verse - \\begin{verse}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_verse", "\\begin{verse}\n","%E\n\\end{verse} ",0,1,i18n("The verse environment is designed for poetry.\nSeparate the lines of each stanza with \\\\, and use one or more blank lines to separate the stanzas.") );
+
+ (void) new KileAction::Tag(i18n("Verbatim - \\begin{verbatim}"),"verbatim",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_verbatim","\\begin{verbatim}\n","%E\n\\end{verbatim} ",0,1,i18n("Environment that gets LaTeX to print exactly what you type in."));
+ (void) new KileAction::Tag(i18n("Bulleted List - \\begin{itemize}"),"itemize",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_itemize","\\begin{itemize}\n%E\\item \n", "\\end{itemize}\n", 6,1,i18n("The itemize environment produces a 'bulleted' list.\nEach item of an itemized list begins with an \\item command."));
+ (void) new KileAction::Tag(i18n("Enumeration - \\begin{enumerate}"),"enumerate",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_enumerate","\\begin{enumerate}\n%E\\item \n","\\end{enumerate}\n", 6,1,i18n("The enumerate environment produces a numbered list.\nEach item of an enumerated list begins with an \\item command."));
+ (void) new KileAction::Tag(i18n("Description - \\begin{description}"),"description",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_description","\\begin{description}\n%E\\item[]\n ", "\\end{description}",6,1,i18n("The description environment is used to make labeled lists.\nEach item of the list begins with an \\item[label] command.\nThe 'label' is bold face and flushed right."));
+
+ (void) new KileAction::Tag(i18n("Table - \\begin{table}"),"frame_spreadsheet",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_table","\\begin{table}\n","%E\n\\caption{}\n\\end{table} ",0,1,
i18n("\\begin{table}[placement]\nbody of the table\n\\caption{table title}\n\\end{table}\nTables are objects that are not part of the normal text, and are usually floated to a convenient place\n"
"The optional argument [placement] determines where LaTeX will try to place your table\nh : Here - at the position in the text where the table environment appear\nt : Top - at the top of a text page\nb : Bottom - at the bottom of a text page\n"
"p : Page of floats - on a separate float page, which is a page containing no text, only floats\nThe body of the table is made up of whatever text, LaTeX commands, etc., you wish.\nThe \\caption command allows you to title your table."));
- (void) new KileAction::Tag(i18n("Figure - \\begin{figure}"),"frame_image",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_figure" ,"\\begin{figure}\n","%E\n\\caption{}\n\\end{figure} ",0,1,
+ (void) new KileAction::Tag(i18n("Figure - \\begin{figure}"),"frame_image",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_figure" ,"\\begin{figure}\n","%E\n\\caption{}\n\\end{figure} ",0,1,
i18n("\\begin{figure}[placement]\nbody of the figure\n\\caption{figure title}\n\\end{figure}\nFigures are objects that are not part of the normal text, and are usually floated to a convenient place\n"
"The optional argument [placement] determines where LaTeX will try to place your figure\nh : Here - at the position in the text where the figure environment appear\nt : Top - at the top of a text page\n"
"b : Bottom - at the bottom of a text page\np : Page of floats - on a separate float page, which is a page containing no text, only floats\nThe body of the figure is made up of whatever text, LaTeX commands, etc., you wish.\nThe \\caption command allows you to title your figure."));
- (void) new KileAction::Tag(i18n("Title Page - \\begin{titlepage}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_titlepage" ,"\\begin{titlepage}\n","%E\n\\end{titlepage} ",0,1,
+ (void) new KileAction::Tag(i18n("Title Page - \\begin{titlepage}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_titlepage" ,"\\begin{titlepage}\n","%E\n\\end{titlepage} ",0,1,
i18n("\\begin{titlepage}\ntext\n\\end{titlepage}\nThe titlepage environment creates a title page, i.e. a page with no printed page number or heading."));
- new KileAction::Tag(i18n("Italics - \\textit{}"),"text_italic",Qt::ALT+Qt::SHIFT+Qt::Key_I, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_textit","\\textit{","}",8,0,i18n("\\textit{italic text}"));
- new KileAction::Tag(i18n("Slanted - \\textsl{}"),"slanted",Qt::ALT+Qt::SHIFT+Qt::Key_A, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_textsl","\\textsl{","}",8,0,i18n("\\textsl{slanted text}"));
- new KileAction::Tag(i18n("Boldface - \\textbf{}"),"text_bold",Qt::ALT+Qt::SHIFT+Qt::Key_B, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_textbf","\\textbf{","}",8,0,i18n("\\textbf{boldface text}"));
- new KileAction::Tag(i18n("Typewriter - \\texttt{}"),"typewriter",Qt::ALT+Qt::SHIFT+Qt::Key_T, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_texttt","\\texttt{","}",8,0,i18n("\\texttt{typewriter text}"));
- new KileAction::Tag(i18n("Small Caps - \\textsc{}"),Qt::ALT+Qt::SHIFT+Qt::Key_C, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_textsc","\\textsc{","}",8,0,i18n("\\textsc{small caps text}"));
- new KileAction::Tag("\\item","item",Qt::ALT+Qt::SHIFT+Qt::Key_H, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_item","\\item ",QString::null,6,0, i18n("\\item[label] Hello!"));
-
- (void) new KileAction::Tag(i18n("Tabbing - \\begin{tabbing}"),"tabbing",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_tabbing" ,"\\begin{tabbing}\n","%E\n\\end{tabbing} ",0,1,i18n("The tabbing environment provides a way to align text in columns.\n\\begin{tabbing}\ntext \\= more text \\= still more text \\= last text \\\\\nsecond row \\> \\> more \\\\\n\\end{tabbing}\nCommands :\n\\= Sets a tab stop at the current position.\n\\> Advances to the next tab stop.\n\\< Allows you to put something to the left of the local margin without changing the margin. Can only be used at the start of the line.\n\\+ Moves the left margin of the next and all the following commands one tab stop to the right\n\\- Moves the left margin of the next and all the following commands one tab stop to the left\n\\' Moves everything that you have typed so far in the current column to the right of the previous column, flush against the current column's tab stop. \n\\` Allows you to put text flush right against any tab stop, including tab stop 0\n\\kill Sets tab stops without producing text.\n\\a In a tabbing environment, the commands \\=, \\' and \\` do not produce accents as normal. Instead, the commands \\a=, \\a' and \\a` are used."));
- (void) new KileAction::Tag("Tabular - \\begin{tabular}","tabular",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_tabular" ,"\\begin{tabular}{","}\n%E\n\\end{tabular} ",16,0,i18n("\\begin{tabular}[pos]{cols}\ncolumn 1 entry & column 2 entry ... & column n entry \\\\\n...\n\\end{tabular}\npos : Specifies the vertical position; default is alignment on the center of the environment.\n t - align on top row\n b - align on bottom row\ncols : Specifies the column formatting.\n l - A column of left-aligned items.\n r - A column of right-aligned items.\n c - A column of centered items.\n | - A vertical line the full height and depth of the environment.\n @{text} - this inserts text in every row.\nThe \\hline command draws a horizontal line the width of the table.\nThe \\cline{i-j} command draws horizontal lines across the columns specified, beginning in column i and ending in column j,\nThe \\vline command draws a vertical line extending the full height and depth of its row."));
- (void) new KileAction::Tag("Multicolumn Cells - \\multicolumn","multicolumn",0, parent, SLOT(insertTag(const KileAction::TagData&)),parent->actionCollection(),"tag_multicolumn","\\multicolumn{","}{}{} ",13,0,i18n("\\multicolumn{cols}{pos}{text}\ncol, specifies the number of columns to span.\npos specifies the formatting of the entry: c for centered, l for flushleft, r for flushright.\ntext specifies what text is to make up the entry."));
- (void) new KileAction::Tag(i18n("Horizontal Line - \\hline"),"hline",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_hline" ,"\\hline ",QString::null,7,0,i18n("The \\hline command draws a horizontal line the width of the table."));
- (void) new KileAction::Tag(i18n("Vertical Line - \\vline"),"vline",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_vline" ,"\\vline ",QString::null,7,0,i18n("The \\vline command draws a vertical line extending the full height and depth of its row."));
- (void) new KileAction::Tag(i18n("Horizontal Line Across Columns - \\cline{m-n}"),"cline",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_cline" ,"\\cline{-} ",QString::null,7,0,i18n("The \\cline{i-j} command draws horizontal lines across the columns specified, beginning in column i and ending in column j,"));
-
- (void) new KileAction::Tag(i18n("Newpage - \\newpage"), 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_newpage","\\newpage ",QString::null,9,0,i18n("The \\newpage command ends the current page"));
- (void) new KileAction::Tag(i18n("Line Break - \\linebreak"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_linebreak","\\linebreak ",QString::null,11,0,i18n("The \\linebreak command tells LaTeX to break the current line at the point of the command."));
- (void) new KileAction::Tag(i18n("Page Break - \\pagebreak"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_pagebreak","\\pagebreak ",QString::null,11,0,i18n("The \\pagebreak command tells LaTeX to break the current page at the point of the command."));
- (void) new KileAction::Tag(i18n("\"Big\" Vertical Space - \\bigskip"), 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bigskip","\\bigskip ",QString::null,9,0,i18n("The \\bigskip command adds a 'big' vertical space."));
- (void) new KileAction::Tag(i18n("\"Medium\" vertical Space - \\medskip"), 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_medskip","\\medskip ",QString::null,9,0,i18n("The \\medskip command adds a 'medium' vertical space."));
+ new KileAction::Tag(i18n("Italics - \\textit{}"),"text_italic",TQt::ALT+TQt::SHIFT+TQt::Key_I, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_textit","\\textit{","}",8,0,i18n("\\textit{italic text}"));
+ new KileAction::Tag(i18n("Slanted - \\textsl{}"),"slanted",TQt::ALT+TQt::SHIFT+TQt::Key_A, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_textsl","\\textsl{","}",8,0,i18n("\\textsl{slanted text}"));
+ new KileAction::Tag(i18n("Boldface - \\textbf{}"),"text_bold",TQt::ALT+TQt::SHIFT+TQt::Key_B, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_textbf","\\textbf{","}",8,0,i18n("\\textbf{boldface text}"));
+ new KileAction::Tag(i18n("Typewriter - \\texttt{}"),"typewriter",TQt::ALT+TQt::SHIFT+TQt::Key_T, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_texttt","\\texttt{","}",8,0,i18n("\\texttt{typewriter text}"));
+ new KileAction::Tag(i18n("Small Caps - \\textsc{}"),TQt::ALT+TQt::SHIFT+TQt::Key_C, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_textsc","\\textsc{","}",8,0,i18n("\\textsc{small caps text}"));
+ new KileAction::Tag("\\item","item",TQt::ALT+TQt::SHIFT+TQt::Key_H, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_item","\\item ",TQString(),6,0, i18n("\\item[label] Hello!"));
+
+ (void) new KileAction::Tag(i18n("Tabbing - \\begin{tabbing}"),"tabbing",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_tabbing" ,"\\begin{tabbing}\n","%E\n\\end{tabbing} ",0,1,i18n("The tabbing environment provides a way to align text in columns.\n\\begin{tabbing}\ntext \\= more text \\= still more text \\= last text \\\\\nsecond row \\> \\> more \\\\\n\\end{tabbing}\nCommands :\n\\= Sets a tab stop at the current position.\n\\> Advances to the next tab stop.\n\\< Allows you to put something to the left of the local margin without changing the margin. Can only be used at the start of the line.\n\\+ Moves the left margin of the next and all the following commands one tab stop to the right\n\\- Moves the left margin of the next and all the following commands one tab stop to the left\n\\' Moves everything that you have typed so far in the current column to the right of the previous column, flush against the current column's tab stop. \n\\` Allows you to put text flush right against any tab stop, including tab stop 0\n\\kill Sets tab stops without producing text.\n\\a In a tabbing environment, the commands \\=, \\' and \\` do not produce accents as normal. Instead, the commands \\a=, \\a' and \\a` are used."));
+ (void) new KileAction::Tag("Tabular - \\begin{tabular}","tabular",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_tabular" ,"\\begin{tabular}{","}\n%E\n\\end{tabular} ",16,0,i18n("\\begin{tabular}[pos]{cols}\ncolumn 1 entry & column 2 entry ... & column n entry \\\\\n...\n\\end{tabular}\npos : Specifies the vertical position; default is tqalignment on the center of the environment.\n t - align on top row\n b - align on bottom row\ncols : Specifies the column formatting.\n l - A column of left-aligned items.\n r - A column of right-aligned items.\n c - A column of centered items.\n | - A vertical line the full height and depth of the environment.\n @{text} - this inserts text in every row.\nThe \\hline command draws a horizontal line the width of the table.\nThe \\cline{i-j} command draws horizontal lines across the columns specified, beginning in column i and ending in column j,\nThe \\vline command draws a vertical line extending the full height and depth of its row."));
+ (void) new KileAction::Tag("Multicolumn Cells - \\multicolumn","multicolumn",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),tqparent->actionCollection(),"tag_multicolumn","\\multicolumn{","}{}{} ",13,0,i18n("\\multicolumn{cols}{pos}{text}\ncol, specifies the number of columns to span.\npos specifies the formatting of the entry: c for centered, l for flushleft, r for flushright.\ntext specifies what text is to make up the entry."));
+ (void) new KileAction::Tag(i18n("Horizontal Line - \\hline"),"hline",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_hline" ,"\\hline ",TQString(),7,0,i18n("The \\hline command draws a horizontal line the width of the table."));
+ (void) new KileAction::Tag(i18n("Vertical Line - \\vline"),"vline",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_vline" ,"\\vline ",TQString(),7,0,i18n("The \\vline command draws a vertical line extending the full height and depth of its row."));
+ (void) new KileAction::Tag(i18n("Horizontal Line Across Columns - \\cline{m-n}"),"cline",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_cline" ,"\\cline{-} ",TQString(),7,0,i18n("The \\cline{i-j} command draws horizontal lines across the columns specified, beginning in column i and ending in column j,"));
+
+ (void) new KileAction::Tag(i18n("Newpage - \\newpage"), 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_newpage","\\newpage ",TQString(),9,0,i18n("The \\newpage command ends the current page"));
+ (void) new KileAction::Tag(i18n("Line Break - \\linebreak"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_linebreak","\\linebreak ",TQString(),11,0,i18n("The \\linebreak command tells LaTeX to break the current line at the point of the command."));
+ (void) new KileAction::Tag(i18n("Page Break - \\pagebreak"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_pagebreak","\\pagebreak ",TQString(),11,0,i18n("The \\pagebreak command tells LaTeX to break the current page at the point of the command."));
+ (void) new KileAction::Tag(i18n("\"Big\"Qt::Vertical Space - \\bigskip"), 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bigskip","\\bigskip ",TQString(),9,0,i18n("The \\bigskip command adds a 'big' vertical space."));
+ (void) new KileAction::Tag(i18n("\"Medium\" vertical Space - \\medskip"), 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_medskip","\\medskip ",TQString(),9,0,i18n("The \\medskip command adds a 'medium' vertical space."));
// includegraphics (dani)
- (void) new KileAction::Tag(i18n("Image Insertion - \\includegraphics{file}"), "graphics", KShortcut("Alt+I,G"),parent,SLOT(includeGraphics()), parent->actionCollection(),"tag_includegraphics",0L);
+ (void) new KileAction::Tag(i18n("Image Insertion - \\includegraphics{file}"), "graphics", KShortcut("Alt+I,G"),TQT_TQOBJECT(tqparent), TQT_SLOT(includeGraphics()), tqparent->actionCollection(),"tag_includegraphics",0L);
// two new shortcuts (dani)
- (void) new KileAction::InputTag(ki,i18n("Customizable File Inclusion - \\include{file}"),"include",KShortcut("Alt+I,F"), parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_include",parent, KileAction::KeepHistory | KileAction::ShowBrowseButton | KileAction::AddProjectFile, "\\include{%R","}",9,0, i18n("\\include{file}\nThe \\include command is used in conjunction with the \\includeonly command for selective inclusion of files."),i18n("Type or select a filename: "));
- (void) new KileAction::InputTag(ki,i18n("File Inclusion - \\input{file}"),"include",KShortcut("Alt+I,P"), parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_input", parent, KileAction::KeepHistory | KileAction::ShowBrowseButton | KileAction::AddProjectFile, "\\input{%R","}",7,0,i18n("\\input{file}\nThe \\input command causes the indicated file to be read and processed, exactly as if its contents had been inserted in the current file at that point."),i18n("Type or select a filename: "));
- (void) new KileAction::Tag(i18n("Bibliography Style Selection - \\bibliographystyle{}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bibliographystyle", "\\bibliographystyle{","} ",19,0,i18n("The argument to \\bibliographystyle refers to a file style.bst, which defines how your citations will look\nThe standard styles distributed with BibTeX are:\nalpha : sorted alphabetically. Labels are formed from name of author and year of publication.\nplain : sorted alphabetically. Labels are numeric.\nunsrt : like plain, but entries are in order of citation.\nabbrv : like plain, but more compact labels."));
- (void) new KileAction::Tag(i18n("Bibliography Generation - \\bibliography{}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bibliography","\\bibliography{%S", "}\n",14, 0,i18n("The argument to \\bibliography refers to the bib file (without extension)\nwhich should contain your database in BibTeX format.\nKile inserts automatically the base name of the TeX file"));
-
- KileAction::Select *actionstructure_list = new KileAction::Select(i18n("Sectioning"), 0, parent->actionCollection(), "structure_list");
- QPtrList<KAction> alist;
- alist.append(new KileAction::InputTag(ki,"&part","part",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_part", parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\part%A{%R}","\n", 0,1,i18n("\\part{title}\n\\part*{title} : do not include a number and do not make an entry in the table of contents\n"), i18n("&Part"),i18n("No &numbering")));
- alist.append(new KileAction::InputTag(ki,"&chapter","chapter",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_chapter" ,parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\chapter%A{%R}","\n", 0,1,i18n("\\chapter{title}\n\\chapter*{title} : do not include a number and do not make an entry in the table of contents\nOnly for 'report' and 'book' class document."), i18n("C&hapter"),i18n("No &numbering")));
- alist.append(new KileAction::InputTag(ki,"&section","section",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_section",parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\section%A{%R}","\n", 0,1,i18n("\\section{title}\n\\section*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Section"),i18n("No &numbering")));
- alist.append(new KileAction::InputTag(ki,"s&ubsection","subsection",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_subsection" ,parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\subsection%A{%R}","\n", 0,1,i18n("\\subsection{title}\n\\subsection*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Subsection"),i18n("No &numbering")));
- alist.append(new KileAction::InputTag(ki,"su&bsubsection","subsubsection",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_subsubsection",parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\subsubsection%A{%R}","\n", 0,1,i18n("\\subsubsection{title}\n\\subsubsection*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Subsubsection"),i18n("No &numbering")));
- alist.append(new KileAction::InputTag(ki,"p&aragraph",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_paragraph",parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\paragraph%A{%R}","\n", 0,1,i18n("\\paragraph{title}\n\\paragraph*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Paragraph"),i18n("No &numbering")));
- alist.append(new KileAction::InputTag(ki,"subpa&ragraph",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_subparagraph",parent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\subparagraph%A{%R}","\n", 0,1,i18n("\\subparagraph{title}\n\\subparagraph*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Subparagraph"),i18n("No &numbering")));
+ (void) new KileAction::InputTag(ki,i18n("Customizable File Inclusion - \\include{file}"),"include",KShortcut("Alt+I,F"), TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_include",tqparent, KileAction::KeepHistory | KileAction::ShowBrowseButton | KileAction::AddProjectFile, "\\include{%R","}",9,0, i18n("\\include{file}\nThe \\include command is used in conjunction with the \\includeonly command for selective inclusion of files."),i18n("Type or select a filename: "));
+ (void) new KileAction::InputTag(ki,i18n("File Inclusion - \\input{file}"),"include",KShortcut("Alt+I,P"), TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_input", tqparent, KileAction::KeepHistory | KileAction::ShowBrowseButton | KileAction::AddProjectFile, "\\input{%R","}",7,0,i18n("\\input{file}\nThe \\input command causes the indicated file to be read and processed, exactly as if its contents had been inserted in the current file at that point."),i18n("Type or select a filename: "));
+ (void) new KileAction::Tag(i18n("Bibliography Style Selection - \\bibliographystyle{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bibliographystyle", "\\bibliographystyle{","} ",19,0,i18n("The argument to \\bibliographystyle refers to a file style.bst, which defines how your citations will look\nThe standard styles distributed with BibTeX are:\nalpha : sorted alphabetically. Labels are formed from name of author and year of publication.\nplain : sorted alphabetically. Labels are numeric.\nunsrt : like plain, but entries are in order of citation.\nabbrv : like plain, but more compact labels."));
+ (void) new KileAction::Tag(i18n("Bibliography Generation - \\bibliography{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bibliography","\\bibliography{%S", "}\n",14, 0,i18n("The argument to \\bibliography refers to the bib file (without extension)\nwhich should contain your database in BibTeX format.\nKile inserts automatically the base name of the TeX file"));
+
+ KileAction::Select *actionstructure_list = new KileAction::Select(i18n("Sectioning"), 0, tqparent->actionCollection(), "structure_list");
+ TQPtrList<KAction> alist;
+ alist.append(new KileAction::InputTag(ki,"&part","part",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_part", tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\part%A{%R}","\n", 0,1,i18n("\\part{title}\n\\part*{title} : do not include a number and do not make an entry in the table of contents\n"), i18n("&Part"),i18n("No &numbering")));
+ alist.append(new KileAction::InputTag(ki,"&chapter","chapter",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_chapter" ,tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\chapter%A{%R}","\n", 0,1,i18n("\\chapter{title}\n\\chapter*{title} : do not include a number and do not make an entry in the table of contents\nOnly for 'report' and 'book' class document."), i18n("C&hapter"),i18n("No &numbering")));
+ alist.append(new KileAction::InputTag(ki,"&section","section",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_section",tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\section%A{%R}","\n", 0,1,i18n("\\section{title}\n\\section*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Section"),i18n("No &numbering")));
+ alist.append(new KileAction::InputTag(ki,"s&ubsection","subsection",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_subsection" ,tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\subsection%A{%R}","\n", 0,1,i18n("\\subsection{title}\n\\subsection*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Subsection"),i18n("No &numbering")));
+ alist.append(new KileAction::InputTag(ki,"su&bsubsection","subsubsection",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_subsubsection",tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\subsubsection%A{%R}","\n", 0,1,i18n("\\subsubsection{title}\n\\subsubsection*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Subsubsection"),i18n("No &numbering")));
+ alist.append(new KileAction::InputTag(ki,"p&aragraph",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_paragraph",tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\paragraph%A{%R}","\n", 0,1,i18n("\\paragraph{title}\n\\paragraph*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Paragraph"),i18n("No &numbering")));
+ alist.append(new KileAction::InputTag(ki,"subpa&ragraph",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_subparagraph",tqparent, KileAction::ShowAlternative|KileAction::ShowLabel , "\\subparagraph%A{%R}","\n", 0,1,i18n("\\subparagraph{title}\n\\subparagraph*{title} : do not include a number and do not make an entry in the table of contents"), i18n("&Subparagraph"),i18n("No &numbering")));
actionstructure_list->setItems(alist);
actionstructure_list->setCurrentItem(2);
- KileAction::Select *actionsize_list = new KileAction::Select(i18n("Size"), 0, parent->actionCollection(), "size_list");
+ KileAction::Select *actionsize_list = new KileAction::Select(i18n("Size"), 0, tqparent->actionCollection(), "size_list");
alist.clear();
- alist.append(new KileAction::Tag(i18n("tiny"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{tiny}","\\end{tiny}",12,0));
- alist.append(new KileAction::Tag(i18n("scriptsize"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{scriptsize}","\\end{scriptsize}",18,0));
- alist.append(new KileAction::Tag(i18n("footnotesize"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{footnotesize}","\\end{footnotesize}",20,0));
- alist.append(new KileAction::Tag(i18n("small"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{small}","\\end{small}",13,0));
- alist.append(new KileAction::Tag(i18n("normalsize"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{normalsize}","\\end{normalsize}",18,0));
- alist.append(new KileAction::Tag(i18n("large"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{large}","\\end{large}",13,0));
- alist.append(new KileAction::Tag(i18n("Large"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{Large}","\\end{Large}",13,0));
- alist.append(new KileAction::Tag(i18n("LARGE"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\begin{LARGE}","\\end{LARGE}",13,0));
- alist.append(new KileAction::Tag(i18n("huge"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(), "","\\begin{huge}","\\end{huge}", 12,0));
- alist.append(new KileAction::Tag(i18n("Huge"),0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(), "","\\begin{Huge}","\\end{Huge}", 12,0));
+ alist.append(new KileAction::Tag(i18n("tiny"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{tiny}","\\end{tiny}",12,0));
+ alist.append(new KileAction::Tag(i18n("scriptsize"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{scriptsize}","\\end{scriptsize}",18,0));
+ alist.append(new KileAction::Tag(i18n("footnotesize"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{footnotesize}","\\end{footnotesize}",20,0));
+ alist.append(new KileAction::Tag(i18n("small"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{small}","\\end{small}",13,0));
+ alist.append(new KileAction::Tag(i18n("normalsize"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{normalsize}","\\end{normalsize}",18,0));
+ alist.append(new KileAction::Tag(i18n("large"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{large}","\\end{large}",13,0));
+ alist.append(new KileAction::Tag(i18n("Large"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{Large}","\\end{Large}",13,0));
+ alist.append(new KileAction::Tag(i18n("LARGE"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\begin{LARGE}","\\end{LARGE}",13,0));
+ alist.append(new KileAction::Tag(i18n("huge"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(), "","\\begin{huge}","\\end{huge}", 12,0));
+ alist.append(new KileAction::Tag(i18n("Huge"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(), "","\\begin{Huge}","\\end{Huge}", 12,0));
actionsize_list->setItems(alist);
actionsize_list->setCurrentItem(4);
- KileAction::Select *actionother_list = new KileAction::Select(i18n("Other"), 0, parent->actionCollection(), "other_list");
+ KileAction::Select *actionother_list = new KileAction::Select(i18n("Other"), 0, tqparent->actionCollection(), "other_list");
alist.clear();
- alist.append(new KileAction::Tag("label", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_label", "\\label{","} ",7,0,i18n("\\label{key}")));
- alist.append(new KileAction::Tag("index", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_index","\\index{","}",7,0,i18n( "\\index{word}")));
- alist.append(new KileAction::Tag("footnote",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_footnote", "\\footnote{","}",10,0,i18n( "\\footnote{text}")));
- alist.append(new KileAction::InputTag(ki,"ref",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_ref", parent, KileAction::FromLabelList, "\\ref{%R", "}", 5,0, QString::null, i18n("Label") ));
- alist.append(new KileAction::InputTag(ki,"pageref",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_pageref", parent, KileAction::FromLabelList, "\\pageref{%R", "}", 9,0, QString::null, i18n("Label") ));
- alist.append(new KileAction::InputTag(ki,"cite",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_cite", parent, KileAction::FromBibItemList, "\\cite{%R", "}", 6,0, i18n("This command generates an in-text citation to the reference associated with the ref entry in the bib file\nYou can open the bib file with Kile to see all the available references"), i18n("Reference")));
- alist.append(new KAction(i18n("cite from ViewBib"),0, parent, SLOT(citeViewBib()), parent->actionCollection(),"citeViewBib" ));
+ alist.append(new KileAction::Tag("label", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_label", "\\label{","} ",7,0,i18n("\\label{key}")));
+ alist.append(new KileAction::Tag("index", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_index","\\index{","}",7,0,i18n( "\\index{word}")));
+ alist.append(new KileAction::Tag("footnote",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_footnote", "\\footnote{","}",10,0,i18n( "\\footnote{text}")));
+ alist.append(new KileAction::InputTag(ki,"ref",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_ref", tqparent, KileAction::FromLabelList, "\\ref{%R", "}", 5,0, TQString(), i18n("Label") ));
+ alist.append(new KileAction::InputTag(ki,"pageref",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_pageref", tqparent, KileAction::FromLabelList, "\\pageref{%R", "}", 9,0, TQString(), i18n("Label") ));
+ alist.append(new KileAction::InputTag(ki,"cite",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_cite", tqparent, KileAction::FromBibItemList, "\\cite{%R", "}", 6,0, i18n("This command generates an in-text citation to the reference associated with the ref entry in the bib file\nYou can open the bib file with Kile to see all the available references"), i18n("Reference")));
+ alist.append(new KAction(i18n("cite from ViewBib"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(citeViewBib()), tqparent->actionCollection(),"citeViewBib" ));
actionother_list->setItems(alist);
- (void) new KileAction::Tag(i18n("Underline - \\underline{}"),"text_under",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_underline", "\\underline{","}",11);
+ (void) new KileAction::Tag(i18n("Underline - \\underline{}"),"text_under",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_underline", "\\underline{","}",11);
- QString icon = ( locate("icon","default.kde/22x22/actions/key_enter.png").isEmpty() ) ? "newline" : "key_enter";
- (void) new KAction(i18n("Smart New Line"), icon, Qt::SHIFT+Qt::Key_Return , ki->editorExtension(), SLOT(insertIntelligentNewline()), parent->actionCollection(),"tag_newline");
- (void) new KAction(i18n("Smart Tabulator"), Qt::ALT+Qt::Key_Ampersand, ki->editorExtension(), SLOT(insertIntelligentTabulator()), parent->actionCollection(),"tag_tabulator" );
+ TQString icon = ( locate("icon","default.kde/22x22/actions/key_enter.png").isEmpty() ) ? "newline" : "key_enter";
+ (void) new KAction(i18n("Smart New Line"), icon, TQt::SHIFT+TQt::Key_Return , ki->editorExtension(), TQT_SLOT(insertIntelligentNewline()), tqparent->actionCollection(),"tag_newline");
+ (void) new KAction(i18n("Smart Tabulator"), TQt::ALT+TQt::Key_Ampersand, ki->editorExtension(), TQT_SLOT(insertIntelligentTabulator()), tqparent->actionCollection(),"tag_tabulator" );
// new tags (dani 29.01.2005)
- KActionCollection* ac = parent->actionCollection();
+ KActionCollection* ac = tqparent->actionCollection();
// environments
- (void) new KileAction::Tag(i18n("Abstract - \\begin{abstract}"),0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_abstract","\\begin{abstract}\n","%E\n\\end{abstract} ",0,1, i18n("\\begin{abstract}\ntext\n\\end{abstract}\nThe abstract environment creates a title page, i.e. a page with no printed page number or heading."));
+ (void) new KileAction::Tag(i18n("Abstract - \\begin{abstract}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_abstract","\\begin{abstract}\n","%E\n\\end{abstract} ",0,1, i18n("\\begin{abstract}\ntext\n\\end{abstract}\nThe abstract environment creates a title page, i.e. a page with no printed page number or heading."));
- (void) new KileAction::Tag("Tabular* - \\begin{tabular*}",0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_tabular*","\\begin{tabular*}{}{","}\n%E\n\\end{tabular*}\n",17,0, i18n("\\begin{tabular*}{width}[pos]{cols}\ncolumn 1 entry & column 2 entry ... & column n entry \\\\\n...\n\\end{tabular*}\nThis is an extended version of the tabular environment with an extra parameter for the width. There must be rubber space between columns that can stretch to fill out the specified width."));
+ (void) new KileAction::Tag("Tabular* - \\begin{tabular*}",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_tabular*","\\begin{tabular*}{}{","}\n%E\n\\end{tabular*}\n",17,0, i18n("\\begin{tabular*}{width}[pos]{cols}\ncolumn 1 entry & column 2 entry ... & column n entry \\\\\n...\n\\end{tabular*}\nThis is an extended version of the tabular environment with an extra parameter for the width. There must be rubber space between columns that can stretch to fill out the specified width."));
- (void) new KileAction::Tag(i18n("Minipage - \\begin{minipage}"),"minipage",0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_env_minipage","\\begin{minipage}[","]{}\n%E\n\\end{minipage} ",17,0, i18n("The minipage environment is similar to a \\parbox command. It takes the same optional position argument and mandatory width argument. You may use other paragraph-making environments inside a minipage."));
+ (void) new KileAction::Tag(i18n("Minipage - \\begin{minipage}"),"minipage",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_env_minipage","\\begin{minipage}[","]{}\n%E\n\\end{minipage} ",17,0, i18n("The minipage environment is similar to a \\parbox command. It takes the same optional position argument and mandatory width argument. You may use other paragraph-making environments inside a minipage."));
// lists
- (void) new KileAction::Tag(i18n("Table of Figures - \\listoffigures"),0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_listoffigures","\\listoffigures",QString::null,14,0, i18n("Put this command where you want the list of figures to go."));
+ (void) new KileAction::Tag(i18n("Table of Figures - \\listoffigures"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_listoffigures","\\listoffigures",TQString(),14,0, i18n("Put this command where you want the list of figures to go."));
- (void) new KileAction::Tag(i18n("Table of Tables - \\listoftables"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_listoftables","\\listoftables",QString::null,14,0, i18n("Put this command where you want the list of tables to go."));
+ (void) new KileAction::Tag(i18n("Table of Tables - \\listoftables"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_listoftables","\\listoftables",TQString(),14,0, i18n("Put this command where you want the list of tables to go."));
- (void) new KileAction::Tag(i18n("Generate Index - \\makeindex"),0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_makeindex","\\makeindex",QString::null,10,0, i18n("Put this command when you want to generate the raw index."));
+ (void) new KileAction::Tag(i18n("Generate Index - \\makeindex"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_makeindex","\\makeindex",TQString(),10,0, i18n("Put this command when you want to generate the raw index."));
- (void) new KileAction::Tag(i18n("Print Index - \\printindex"),0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_printindex","\\printindex",QString::null,11,0, i18n("Put this command when you want to print the formatted index."));
+ (void) new KileAction::Tag(i18n("Print Index - \\printindex"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_printindex","\\printindex",TQString(),11,0, i18n("Put this command when you want to print the formatted index."));
- (void) new KileAction::Tag(i18n("Glossary - \\makeglossary"),0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_makeglossary","\\makeglossary",QString::null,13,0, i18n("Put this command when you want to print a glossary."));
+ (void) new KileAction::Tag(i18n("Glossary - \\makeglossary"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_makeglossary","\\makeglossary",TQString(),13,0, i18n("Put this command when you want to print a glossary."));
- (void) new KileAction::Tag("Bibliography - \\begin{thebibliography}",0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_thebibliography" ,"\\begin{thebibliography}{","}\n\n\\end{thebibliography} ",24,0, i18n("\\begin{thebibliography}{widest-label}\n\\bibitem[label]{cite_key}\n...\n\\end{thebibliography}\n\nwidest-label : Text that, when printed, is approximately as wide as the widest item label produces by the \\bibitem commands\n\\bibitem : Specify a bibliography item"));
+ (void) new KileAction::Tag("Bibliography - \\begin{thebibliography}",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_thebibliography" ,"\\begin{thebibliography}{","}\n\n\\end{thebibliography} ",24,0, i18n("\\begin{thebibliography}{widest-label}\n\\bibitem[label]{cite_key}\n...\n\\end{thebibliography}\n\nwidest-label : Text that, when printed, is approximately as wide as the widest item label produces by the \\bibitem commands\n\\bibitem : Specify a bibliography item"));
// verbatim code
- (void) new KileAction::Tag(i18n("Verbatim (show spaces) - \\begin{verbatim*}"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_env_verbatim*","\\begin{verbatim*}\n","%E\n\\end{verbatim*}\n",0,1, i18n("Environment that gets LaTeX to print exactly what you type in. In this variant, spaces are printed in a special manner."));
+ (void) new KileAction::Tag(i18n("Verbatim (show spaces) - \\begin{verbatim*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_env_verbatim*","\\begin{verbatim*}\n","%E\n\\end{verbatim*}\n",0,1, i18n("Environment that gets LaTeX to print exactly what you type in. In this variant, spaces are printed in a special manner."));
- (void) new KileAction::Tag(i18n("Embedded Code - \\verb||"),"verb",0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_verb","\\verb|","|",6,0, i18n("Macro form of the verbatim environment."));
+ (void) new KileAction::Tag(i18n("Embedded Code - \\verb||"),"verb",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_verb","\\verb|","|",6,0, i18n("Macro form of the verbatim environment."));
- (void) new KileAction::Tag(i18n("Embedded Code (show spaces) - \\verb*||"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_verb*","\\verb*|","|",7,0, i18n("Macro form of the verbatim* environment."));
+ (void) new KileAction::Tag(i18n("Embedded Code (show spaces) - \\verb*||"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_verb*","\\verb*|","|",7,0, i18n("Macro form of the verbatim* environment."));
// horizontal/vertical space
- (void) new KileAction::Tag(i18n("\"Small\" Vertical Space - \\smallskip"),0, parent,SLOT(insertTag(const KileAction::TagData&)), ac,"tag_smallskip","\\smallskip ",QString::null,10,0, i18n("The \\smallskip command adds a 'small' vertical space."));
+ (void) new KileAction::Tag(i18n("\"Small\"Qt::Vertical Space - \\smallskip"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_smallskip","\\smallskip ",TQString(),10,0, i18n("The \\smallskip command adds a 'small' vertical space."));
- (void) new KileAction::Tag("\\enskip",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_enskip", "\\enskip ", QString::null, 8);
+ (void) new KileAction::Tag("\\enskip",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_enskip", "\\enskip ", TQString(), 8);
- (void) new KileAction::Tag(i18n("Horizontal Variable Space - \\hfill"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hfill","\\hfill",QString::null,6,0, i18n("The \\hfill fill command produces a \"rubber length\" which can stretch or shrink horizontally. It will be filled with spaces."));
+ (void) new KileAction::Tag(i18n("Horizontal Variable Space - \\hfill"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hfill","\\hfill",TQString(),6,0, i18n("The \\hfill fill command produces a \"rubber length\" which can stretch or shrink horizontally. It will be filled with spaces."));
- (void) new KileAction::Tag(i18n("Horizontal Dots - \\dotfill"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_dotfill","\\dotfill",QString::null,8,0, i18n("The \\dotfill command produces a \"rubber length\" that produces dots instead of just spaces."));
+ (void) new KileAction::Tag(i18n("Horizontal Dots - \\dotfill"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_dotfill","\\dotfill",TQString(),8,0, i18n("The \\dotfill command produces a \"rubber length\" that produces dots instead of just spaces."));
- (void) new KileAction::Tag(i18n("Horizontal Rule - \\hrulefill"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hrulefill","\\hrulefill",QString::null,10,0, i18n("The \\hrulefill fill command produces a \"rubber length\" which can stretch or shrink horizontally. It will be filled with a horizontal rule."));
+ (void) new KileAction::Tag(i18n("Horizontal Rule - \\hrulefill"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hrulefill","\\hrulefill",TQString(),10,0, i18n("The \\hrulefill fill command produces a \"rubber length\" which can stretch or shrink horizontally. It will be filled with a horizontal rule."));
- (void) new KileAction::Tag(i18n("Vertical Variable Space - \\vfill"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_vfill","\\vfill",QString::null,6,0, i18n("The \\vfill fill command produces a \"rubber length\" which can stretch or shrink vertically."));
+ (void) new KileAction::Tag(i18n("Vertical Variable Space - \\vfill"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_vfill","\\vfill",TQString(),6,0, i18n("The \\vfill fill command produces a \"rubber length\" which can stretch or shrink vertically."));
- (void) new KileAction::Tag(i18n("Horizontal Space - \\hspace{}"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hspace","\\hspace{","}",8,0, i18n("The \\hspace command adds horizontal space. The length of the space can be expressed in any terms that LaTeX understands, i.e., points, inches, etc. You can add negative as well as positive space with an \\hspace command. Adding negative space is like backspacing."));
+ (void) new KileAction::Tag(i18n("Horizontal Space - \\hspace{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hspace","\\hspace{","}",8,0, i18n("The \\hspace command adds horizontal space. The length of the space can be expressed in any terms that LaTeX understands, i.e., points, inches, etc. You can add negative as well as positive space with an \\hspace command. Adding negative space is like backspacing."));
- (void) new KileAction::Tag(i18n("Horizontal Space (forced) - \\hspace*{}"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hspace*","\\hspace*{","}",9,0, i18n("The \\hspace* command adds horizontal space like the \\hspace command. LaTeX removes horizontal space that comes at the end of a line. If you do not want LaTeX to remove this space, include the optional * argument. Then the space is never removed."));
+ (void) new KileAction::Tag(i18n("Horizontal Space (forced) - \\hspace*{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_hspace*","\\hspace*{","}",9,0, i18n("The \\hspace* command adds horizontal space like the \\hspace command. LaTeX removes horizontal space that comes at the end of a line. If you do not want LaTeX to remove this space, include the optional * argument. Then the space is never removed."));
- (void) new KileAction::Tag(i18n("Vertical Space - \\vspace{}"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_vspace","\\vspace{","}",8,0, i18n("The \\vspace command adds vertical space. The length of the space can be expressed in any terms that LaTeX understands, i.e., points, inches, etc. You can add negative as well as positive space with an \\vspace command."));
+ (void) new KileAction::Tag(i18n("Vertical Space - \\vspace{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_vspace","\\vspace{","}",8,0, i18n("The \\vspace command adds vertical space. The length of the space can be expressed in any terms that LaTeX understands, i.e., points, inches, etc. You can add negative as well as positive space with an \\vspace command."));
- (void) new KileAction::Tag(i18n("Vertical Space (forced) - \\vspace*{}"),0, parent,SLOT(insertTag(const KileAction::TagData&)),ac,"tag_vspace*","\\vspace*{","}",9,0, i18n("The \\vspace* command adds vertical space like the \\vspace command. LaTeX removes vertical space that comes at the end of a page. If you do not want LaTeX to remove this space, include the optional * argument. Then the space is never removed."));
+ (void) new KileAction::Tag(i18n("Vertical Space (forced) - \\vspace*{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)),ac,"tag_vspace*","\\vspace*{","}",9,0, i18n("The \\vspace* command adds vertical space like the \\vspace command. LaTeX removes vertical space that comes at the end of a page. If you do not want LaTeX to remove this space, include the optional * argument. Then the space is never removed."));
// fonts
- new KileAction::Tag(i18n("Emphasized - \\emph{}"),"emph",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_emph","\\emph{","}",6,0,i18n("\\emph{emphasized text}"));
- new KileAction::Tag(i18n("Strong - \\strong{}"),"strong",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_strong","\\strong{","}",8,0,i18n("\\strong{text}"));
+ new KileAction::Tag(i18n("Emphasized - \\emph{}"),"emph",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_emph","\\emph{","}",6,0,i18n("\\emph{emphasized text}"));
+ new KileAction::Tag(i18n("Strong - \\strong{}"),"strong",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_strong","\\strong{","}",8,0,i18n("\\strong{text}"));
- (void) new KileAction::Tag("Roman - \\rmfamily",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_rmfamily", "\\rmfamily", QString::null, 9);
- (void) new KileAction::Tag("Sansserif - \\sffamily",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_sffamily", "\\sffamily", QString::null, 9);
- (void) new KileAction::Tag("Monospace - \\ttfamily",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_ttfamily", "\\ttfamily", QString::null, 9);
+ (void) new KileAction::Tag("Roman - \\rmfamily",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_rmfamily", "\\rmfamily", TQString(), 9);
+ (void) new KileAction::Tag("Sansserif - \\sffamily",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_sffamily", "\\sffamily", TQString(), 9);
+ (void) new KileAction::Tag("Monospace - \\ttfamily",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_ttfamily", "\\ttfamily", TQString(), 9);
- (void) new KileAction::Tag("Medium - \\mdseries",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_mdseries", "\\mdseries", QString::null, 9);
- (void) new KileAction::Tag("Bold - \\bfseries",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_bfseries", "\\bfseries", QString::null, 9);
+ (void) new KileAction::Tag("Medium - \\mdseries",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_mdseries", "\\mdseries", TQString(), 9);
+ (void) new KileAction::Tag("Bold - \\bfseries",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_bfseries", "\\bfseries", TQString(), 9);
- (void) new KileAction::Tag("Upright - \\upshape",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_upshape", "\\upshape", QString::null, 8);
- (void) new KileAction::Tag("Italic - \\itshape",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_itshape", "\\itshape", QString::null, 8);
- (void) new KileAction::Tag("Slanted - \\slshape",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_slshape", "\\slshape", QString::null, 8);
- (void) new KileAction::Tag("Smallcaps - \\scshape",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_scshape", "\\scshape", QString::null, 8);
+ (void) new KileAction::Tag("Upright - \\uptqshape",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_uptqshape", "\\uptqshape", TQString(), 8);
+ (void) new KileAction::Tag("Italic - \\ittqshape",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_ittqshape", "\\ittqshape", TQString(), 8);
+ (void) new KileAction::Tag("Slanted - \\sltqshape",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_sltqshape", "\\sltqshape", TQString(), 8);
+ (void) new KileAction::Tag("Smallcaps - \\sctqshape",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_sctqshape", "\\sctqshape", TQString(), 8);
}
-void setupBibTags(KMainWindow *parent)
+void setupBibTags(KMainWindow *tqparent)
{
- (void) new KileAction::Tag(i18n("Article in Journal"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_article","@Article{,\nauthor = {},\ntitle = {},\njournal = {},\nyear = {},\nOPTkey = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTpages = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,9,0,i18n("Bib fields - Article in Journal\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Article in Conference Proceedings"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_inproc","@InProceedings{,\nauthor = {},\ntitle = {},\nbooktitle = {},\nOPTcrossref = {},\nOPTkey = {},\nOPTpages = {},\nOPTyear = {},\nOPTeditor = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTorganization = {},\nOPTpublisher = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,15,0,i18n("Bib fields - Article in Conference Proceedings\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Article in Collection"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_incol","@InCollection{,\nauthor = {},\ntitle = {},\nbooktitle = {},\nOPTcrossref = {},\nOPTkey = {},\nOPTpages = {},\nOPTpublisher = {},\nOPTyear = {},\nOPTeditor = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTtype = {},\nOPTchapter = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,14,0,i18n("Bib fields - Article in a Collection\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Chapter or Pages in Book"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_inbook","@InBook{,\nALTauthor = {},\nALTeditor = {},\ntitle = {},\nchapter = {},\npublisher = {},\nyear = {},\nOPTkey = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTtype = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTpages = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,8,0,i18n("Bib fields - Chapter or Pages in a Book\nALT.... : you have the choice between these two fields\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Conference Proceedings"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_proceedings","@Proceedings{,\ntitle = {},\nyear = {},\nOPTkey = {},\nOPTeditor = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTorganization = {},\nOPTpublisher = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,13,0,i18n("Bib Fields - Conference Proceedings\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Book"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_book","@Book{,\nALTauthor = {},\nALTeditor = {},\ntitle = {},\npublisher = {},\nyear = {},\nOPTkey = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,6,0,i18n("Bib Fields - Book\nALT.... : you have the choice between these two fields\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Booklet"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_booklet","@Booklet{,\ntitle = {},\nOPTkey = {},\nOPTauthor = {},\nOPThowpublished = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTyear = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,9,0,i18n("Bib fields - Booklet\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("PhD. Thesis"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_phdthesis","@PhdThesis{,\nauthor = {},\ntitle = {},\nschool = {},\nyear = {},\nOPTkey = {},\nOPTtype = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,11,0,i18n("Bib fields - PhD. Thesis\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Master's Thesis"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_masterthesis","@MastersThesis{,\nauthor = {},\ntitle = {},\nschool = {},\nyear = {},\nOPTkey = {},\nOPTtype = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,15,0,i18n("Bib fields - Master's Thesis\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Technical Report"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_techreport","@TechReport{,\nauthor = {},\ntitle = {},\ninstitution = {},\nyear = {},\nOPTkey = {},\nOPTtype = {},\nOPTnumber = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,12,0,i18n("Bib fields - Technical Report\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Technical Manual"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_manual","@Manual{,\ntitle = {},\nOPTkey = {},\nOPTauthor = {},\nOPTorganization = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTyear = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,8,0,i18n("Bib fields - Technical Manual\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Unpublished"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_unpublished","@Unpublished{,\nauthor = {},\ntitle = {},\nnote = {},\nOPTkey = {},\nOPTmonth = {},\nOPTyear = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,13,0,i18n("Bib fields - Unpublished\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
- (void) new KileAction::Tag(i18n("Miscellaneous"),0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bib_misc","@Misc{,\nOPTkey = {},\nOPTauthor = {},\nOPTtitle = {},\nOPThowpublished = {},\nOPTmonth = {},\nOPTyear = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",QString::null,6,0,i18n("Bib fields - Miscellaneous\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Article in Journal"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_article","@Article{,\nauthor = {},\ntitle = {},\njournal = {},\nyear = {},\nOPTkey = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTpages = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),9,0,i18n("Bib fields - Article in Journal\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Article in Conference Proceedings"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_inproc","@InProceedings{,\nauthor = {},\ntitle = {},\nbooktitle = {},\nOPTcrossref = {},\nOPTkey = {},\nOPTpages = {},\nOPTyear = {},\nOPTeditor = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTorganization = {},\nOPTpublisher = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),15,0,i18n("Bib fields - Article in Conference Proceedings\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Article in Collection"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_incol","@InCollection{,\nauthor = {},\ntitle = {},\nbooktitle = {},\nOPTcrossref = {},\nOPTkey = {},\nOPTpages = {},\nOPTpublisher = {},\nOPTyear = {},\nOPTeditor = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTtype = {},\nOPTchapter = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),14,0,i18n("Bib fields - Article in a Collection\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Chapter or Pages in Book"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_inbook","@InBook{,\nALTauthor = {},\nALTeditor = {},\ntitle = {},\nchapter = {},\npublisher = {},\nyear = {},\nOPTkey = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTtype = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTpages = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),8,0,i18n("Bib fields - Chapter or Pages in a Book\nALT.... : you have the choice between these two fields\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Conference Proceedings"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_proceedings","@Proceedings{,\ntitle = {},\nyear = {},\nOPTkey = {},\nOPTeditor = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTorganization = {},\nOPTpublisher = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),13,0,i18n("Bib Fields - Conference Proceedings\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Book"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_book","@Book{,\nALTauthor = {},\nALTeditor = {},\ntitle = {},\npublisher = {},\nyear = {},\nOPTkey = {},\nOPTvolume = {},\nOPTnumber = {},\nOPTseries = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),6,0,i18n("Bib Fields - Book\nALT.... : you have the choice between these two fields\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Booklet"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_booklet","@Booklet{,\ntitle = {},\nOPTkey = {},\nOPTauthor = {},\nOPThowpublished = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTyear = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),9,0,i18n("Bib fields - Booklet\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("PhD. Thesis"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_phdthesis","@PhdThesis{,\nauthor = {},\ntitle = {},\nschool = {},\nyear = {},\nOPTkey = {},\nOPTtype = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),11,0,i18n("Bib fields - PhD. Thesis\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Master's Thesis"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_masterthesis","@MastersThesis{,\nauthor = {},\ntitle = {},\nschool = {},\nyear = {},\nOPTkey = {},\nOPTtype = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),15,0,i18n("Bib fields - Master's Thesis\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Technical Report"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_techreport","@TechReport{,\nauthor = {},\ntitle = {},\ninstitution = {},\nyear = {},\nOPTkey = {},\nOPTtype = {},\nOPTnumber = {},\nOPTaddress = {},\nOPTmonth = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),12,0,i18n("Bib fields - Technical Report\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Technical Manual"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_manual","@Manual{,\ntitle = {},\nOPTkey = {},\nOPTauthor = {},\nOPTorganization = {},\nOPTaddress = {},\nOPTedition = {},\nOPTmonth = {},\nOPTyear = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),8,0,i18n("Bib fields - Technical Manual\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Unpublished"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_unpublished","@Unpublished{,\nauthor = {},\ntitle = {},\nnote = {},\nOPTkey = {},\nOPTmonth = {},\nOPTyear = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),13,0,i18n("Bib fields - Unpublished\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
+ (void) new KileAction::Tag(i18n("Miscellaneous"),0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bib_misc","@Misc{,\nOPTkey = {},\nOPTauthor = {},\nOPTtitle = {},\nOPThowpublished = {},\nOPTmonth = {},\nOPTyear = {},\nOPTnote = {},\nOPTannote = {},\nOPTurl = {},\nOPTdoi = {},\nOPTissn = {},\nOPTlocalfile = {},\nOPTabstract = {}\n}\n",TQString(),6,0,i18n("Bib fields - Miscellaneous\nOPT.... : optional fields (use the 'Clean' command to remove them)"));
}
-void setupMathTags(KMainWindow *parent)
+void setupMathTags(KMainWindow *tqparent)
{
- (void) new KileAction::Tag("\\mathrm{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathrm","\\mathrm{","}",8);
- (void) new KileAction::Tag("\\mathit{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathit" ,"\\mathit{","}",8);
- (void) new KileAction::Tag("\\mathbf{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathbf" ,"\\mathbf{","}",8);
- (void) new KileAction::Tag("\\mathsf{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathsf" ,"\\mathsf{","}",8);
- (void) new KileAction::Tag("\\mathtt{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathtt" ,"\\mathtt{","}",8);
- (void) new KileAction::Tag("\\mathcal{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathcal" ,"\\mathcal{","}",9);
- (void) new KileAction::Tag("\\mathbb{}", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathbb" ,"\\mathbb{","}",8);
- (void) new KileAction::Tag("\\mathfrak{}",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathfrak" ,"\\mathfrak{","}",10);
-
- (void) new KileAction::Tag("\\acute{}","acute",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_acute", "\\acute{","}",7);
- (void) new KileAction::Tag("\\grave{}","grave",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_grave", "\\grave{","}", 7);
- (void) new KileAction::Tag("\\tilde{}","tilde",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_tilde", "\\tilde{","}", 7);
- (void) new KileAction::Tag("\\bar{}","bar", 0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_bar", "\\bar{","}", 5);
- (void) new KileAction::Tag("\\vec{}","vec", 0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_vec", "\\vec{","}", 5);
- (void) new KileAction::Tag("\\hat{}","hat", 0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_hat", "\\hat{","}", 5);
- (void) new KileAction::Tag("\\check{}","check",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_check", "\\check{","}", 7);
- (void) new KileAction::Tag("\\breve{}","breve",0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_breve", "\\breve{","}", 7);
- (void) new KileAction::Tag("\\dot{}","dot", 0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_dot", "\\dot{","}", 5);
- (void) new KileAction::Tag("\\ddot{}","ddot", 0 , parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_ddot", "\\ddot{","}", 6);
-
- (void) new KileAction::Tag(i18n("small"), 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_space_small", "\\,", QString::null, 2);
- (void) new KileAction::Tag(i18n("medium"), 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_space_medium", "\\:", QString::null,2);
- (void) new KileAction::Tag(i18n("large"), 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_space_large", "\\;", QString::null,2);
- (void) new KileAction::Tag("\\quad", 0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_quad", "\\quad ", QString::null, 6);
- (void) new KileAction::Tag("\\qquad",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_qquad", "\\qquad ", QString::null, 7);
-
- (void) new KileAction::Tag(i18n("Math Mode - $...$"),"mathmode",Qt::ALT+Qt::SHIFT+Qt::Key_M, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_mathmode","$","$",1);
- (void) new KileAction::Tag("Displaymath Mode - \\[...\\]", "displaymathmode",Qt::ALT+Qt::SHIFT+Qt::Key_E, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_equation", "\\[","\\]", 2);
- (void) new KileAction::Tag(i18n("Equation - \\begin{equation}"),"equation",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_equation","\\begin{equation}\n","%E\n\\end{equation} ",0,1);
- (void) new KileAction::Tag(i18n("Subscript - _{}"),"math_lsup",Qt::ALT+Qt::SHIFT+Qt::Key_D, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_subscript","_{","}",2);
- (void) new KileAction::Tag(i18n("Superscript - ^{}"),"math_lsub",Qt::ALT+Qt::SHIFT+Qt::Key_U, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_superscript","^{","}",2);
- (void) new KileAction::Tag(i18n("Normal - \\frac{}{}"),"smallfrac",Qt::ALT+Qt::SHIFT+Qt::Key_F, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_frac", "\\frac{","}{}",6);
- (void) new KileAction::Tag(i18n("Displaystyle - \\dfrac{}{}"),"dfrac",Qt::ALT+Qt::SHIFT+Qt::Key_Q, parent, SLOT(insertAmsTag(const KileAction::TagData&)), parent->actionCollection(),"tag_dfrac", "\\dfrac{","}{}", 7);
- (void) new KileAction::Tag(i18n("Square Root - \\sqrt{}"),"math_sqrt",Qt::ALT+Qt::SHIFT+Qt::Key_S, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_sqrt", "\\sqrt{","}", 6);
- (void) new KileAction::Tag("\\left",Qt::ALT+Qt::SHIFT+Qt::Key_L, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_left", "\\left", QString::null, 5);
- (void) new KileAction::Tag("\\right",Qt::ALT+Qt::SHIFT+Qt::Key_R, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_right", "\\right", QString::null, 6);
- (void) new KileAction::Tag(i18n("Array - \\begin{array}"),"array",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"tag_env_array", "\\begin{array}{}\n", "%E\n\\end{array}", 14, 0,
+ (void) new KileAction::Tag("\\mathrm{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathrm","\\mathrm{","}",8);
+ (void) new KileAction::Tag("\\mathit{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathit" ,"\\mathit{","}",8);
+ (void) new KileAction::Tag("\\mathbf{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathbf" ,"\\mathbf{","}",8);
+ (void) new KileAction::Tag("\\mathsf{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathsf" ,"\\mathsf{","}",8);
+ (void) new KileAction::Tag("\\mathtt{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathtt" ,"\\mathtt{","}",8);
+ (void) new KileAction::Tag("\\mathcal{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathcal" ,"\\mathcal{","}",9);
+ (void) new KileAction::Tag("\\mathbb{}", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathbb" ,"\\mathbb{","}",8);
+ (void) new KileAction::Tag("\\mathfrak{}",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathfrak" ,"\\mathfrak{","}",10);
+
+ (void) new KileAction::Tag("\\acute{}","acute",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_acute", "\\acute{","}",7);
+ (void) new KileAction::Tag("\\grave{}","grave",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_grave", "\\grave{","}", 7);
+ (void) new KileAction::Tag("\\tilde{}","tilde",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_tilde", "\\tilde{","}", 7);
+ (void) new KileAction::Tag("\\bar{}","bar", 0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_bar", "\\bar{","}", 5);
+ (void) new KileAction::Tag("\\vec{}","vec", 0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_vec", "\\vec{","}", 5);
+ (void) new KileAction::Tag("\\hat{}","hat", 0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_hat", "\\hat{","}", 5);
+ (void) new KileAction::Tag("\\check{}","check",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_check", "\\check{","}", 7);
+ (void) new KileAction::Tag("\\breve{}","breve",0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_breve", "\\breve{","}", 7);
+ (void) new KileAction::Tag("\\dot{}","dot", 0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_dot", "\\dot{","}", 5);
+ (void) new KileAction::Tag("\\ddot{}","ddot", 0 , TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_ddot", "\\ddot{","}", 6);
+
+ (void) new KileAction::Tag(i18n("small"), 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_space_small", "\\,", TQString(), 2);
+ (void) new KileAction::Tag(i18n("medium"), 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_space_medium", "\\:", TQString(),2);
+ (void) new KileAction::Tag(i18n("large"), 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_space_large", "\\;", TQString(),2);
+ (void) new KileAction::Tag("\\quad", 0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_quad", "\\quad ", TQString(), 6);
+ (void) new KileAction::Tag("\\qquad",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_qquad", "\\qquad ", TQString(), 7);
+
+ (void) new KileAction::Tag(i18n("Math Mode - $...$"),"mathmode",TQt::ALT+TQt::SHIFT+TQt::Key_M, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_mathmode","$","$",1);
+ (void) new KileAction::Tag("Displaymath Mode - \\[...\\]", "displaymathmode",TQt::ALT+TQt::SHIFT+TQt::Key_E, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_equation", "\\[","\\]", 2);
+ (void) new KileAction::Tag(i18n("Equation - \\begin{equation}"),"equation",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_equation","\\begin{equation}\n","%E\n\\end{equation} ",0,1);
+ (void) new KileAction::Tag(i18n("Subscript - _{}"),"math_lsup",TQt::ALT+TQt::SHIFT+TQt::Key_D, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_subscript","_{","}",2);
+ (void) new KileAction::Tag(i18n("Superscript - ^{}"),"math_lsub",TQt::ALT+TQt::SHIFT+TQt::Key_U, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_superscript","^{","}",2);
+ (void) new KileAction::Tag(i18n("Normal - \\frac{}{}"),"smallfrac",TQt::ALT+TQt::SHIFT+TQt::Key_F, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_frac", "\\frac{","}{}",6);
+ (void) new KileAction::Tag(i18n("Displaystyle - \\dfrac{}{}"),"dfrac",TQt::ALT+TQt::SHIFT+TQt::Key_Q, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_dfrac", "\\dfrac{","}{}", 7);
+ (void) new KileAction::Tag(i18n("Square Root - \\sqrt{}"),"math_sqrt",TQt::ALT+TQt::SHIFT+TQt::Key_S, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_sqrt", "\\sqrt{","}", 6);
+ (void) new KileAction::Tag("\\left",TQt::ALT+TQt::SHIFT+TQt::Key_L, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_left", "\\left", TQString(), 5);
+ (void) new KileAction::Tag("\\right",TQt::ALT+TQt::SHIFT+TQt::Key_R, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_right", "\\right", TQString(), 6);
+ (void) new KileAction::Tag(i18n("Array - \\begin{array}"),"array",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"tag_env_array", "\\begin{array}{}\n", "%E\n\\end{array}", 14, 0,
i18n("\\begin{array}{col1col2...coln}\ncolumn 1 entry & column 2 entry ... & column n entry \\\\ \n...\n\\end{array}\nEach column, coln, is specified by a single letter that tells how items in that column should be formatted.\n"
" c -- for centered \n l -- for flush left \n r -- for flush right\n"));
- QPtrList<KAction> alist;
- KileAction::Select *actionleft_list = new KileAction::Select(i18n("Left Delimiter"), 0, parent->actionCollection(), "left_list");
+ TQPtrList<KAction> alist;
+ KileAction::Select *actionleft_list = new KileAction::Select(i18n("Left Delimiter"), 0, tqparent->actionCollection(), "left_list");
alist.clear();
- alist.append(new KileAction::Tag("left (",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left( ",QString::null,7,0));
- alist.append(new KileAction::Tag("left [",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left[ ",QString::null,7,0));
- alist.append(new KileAction::Tag("left {",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left\\lbrace ",QString::null,14,0));
- alist.append(new KileAction::Tag("left <",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left\\langle ",QString::null,14,0));
- alist.append(new KileAction::Tag("left )",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left) ",QString::null,7,0));
- alist.append(new KileAction::Tag("left ]",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left] ",QString::null,7,0));
- alist.append(new KileAction::Tag("left }",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left\\rbrace ",QString::null,14,0));
- alist.append(new KileAction::Tag("left >",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left\\rangle ",QString::null,14,0));
- alist.append(new KileAction::Tag("left .",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\left. ",QString::null,7,0));
+ alist.append(new KileAction::Tag("left (",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left( ",TQString(),7,0));
+ alist.append(new KileAction::Tag("left [",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left[ ",TQString(),7,0));
+ alist.append(new KileAction::Tag("left {",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left\\lbrace ",TQString(),14,0));
+ alist.append(new KileAction::Tag("left <",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left\\langle ",TQString(),14,0));
+ alist.append(new KileAction::Tag("left )",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left) ",TQString(),7,0));
+ alist.append(new KileAction::Tag("left ]",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left] ",TQString(),7,0));
+ alist.append(new KileAction::Tag("left }",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left\\rbrace ",TQString(),14,0));
+ alist.append(new KileAction::Tag("left >",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left\\rangle ",TQString(),14,0));
+ alist.append(new KileAction::Tag("left .",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\left. ",TQString(),7,0));
actionleft_list->setItems(alist);
- KileAction::Select *actionright_list = new KileAction::Select(i18n("Right Delimiter"), 0, parent->actionCollection(), "right_list");
+ KileAction::Select *actionright_list = new KileAction::Select(i18n("Right Delimiter"), 0, tqparent->actionCollection(), "right_list");
alist.clear();
- alist.append(new KileAction::Tag("right )",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right) ",QString::null,8,0));
- alist.append(new KileAction::Tag("right ]",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right] ",QString::null,8,0));
- alist.append(new KileAction::Tag("right }",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right\\rbrace ",QString::null,14,0));
- alist.append(new KileAction::Tag("right >",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right\\rangle ",QString::null,14,0));
- alist.append(new KileAction::Tag("right (",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right( ",QString::null,8,0));
- alist.append(new KileAction::Tag("right [",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right[ ",QString::null,8,0));
- alist.append(new KileAction::Tag("right {",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right\\lbrace ",QString::null,14,0));
- alist.append(new KileAction::Tag("right <",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right\\langle ",QString::null,14,0));
- alist.append(new KileAction::Tag("right.",0, parent, SLOT(insertTag(const KileAction::TagData&)), parent->actionCollection(),"","\\right. ",QString::null,8,0));
+ alist.append(new KileAction::Tag("right )",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right) ",TQString(),8,0));
+ alist.append(new KileAction::Tag("right ]",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right] ",TQString(),8,0));
+ alist.append(new KileAction::Tag("right }",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right\\rbrace ",TQString(),14,0));
+ alist.append(new KileAction::Tag("right >",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right\\rangle ",TQString(),14,0));
+ alist.append(new KileAction::Tag("right (",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right( ",TQString(),8,0));
+ alist.append(new KileAction::Tag("right [",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right[ ",TQString(),8,0));
+ alist.append(new KileAction::Tag("right {",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right\\lbrace ",TQString(),14,0));
+ alist.append(new KileAction::Tag("right <",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right\\langle ",TQString(),14,0));
+ alist.append(new KileAction::Tag("right.",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), tqparent->actionCollection(),"","\\right. ",TQString(),8,0));
actionright_list->setItems(alist);
// new math tags (dani 29.01.2005)
- KActionCollection* ac = parent->actionCollection();
+ KActionCollection* ac = tqparent->actionCollection();
- (void) new KileAction::Tag(i18n("Textstyle - \\tfrac{}{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_tfrac", "\\tfrac{","}{}", 7);
+ (void) new KileAction::Tag(i18n("Textstyle - \\tfrac{}{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_tfrac", "\\tfrac{","}{}", 7);
- (void) new KileAction::Tag(i18n("Normal - \\binom{}{}"),"binom",0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_binom", "\\binom{","}{}", 7);
+ (void) new KileAction::Tag(i18n("Normal - \\binom{}{}"),"binom",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_binom", "\\binom{","}{}", 7);
- (void) new KileAction::Tag(i18n("Displaystyle - \\dbinom{}{}"),0, parent,SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_dbinom", "\\dbinom{","}{}", 8);
+ (void) new KileAction::Tag(i18n("Displaystyle - \\dbinom{}{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_dbinom", "\\dbinom{","}{}", 8);
- (void) new KileAction::Tag(i18n("Textstyle - \\tbinom{}{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_tbinom", "\\tbinom{","}{}", 8);
+ (void) new KileAction::Tag(i18n("Textstyle - \\tbinom{}{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_tbinom", "\\tbinom{","}{}", 8);
- (void) new KileAction::Tag(i18n("n-th root - \\sqrt[]{}"),"nroot",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_nroot", "\\sqrt[]{","}", 6);
+ (void) new KileAction::Tag(i18n("n-th root - \\sqrt[]{}"),"nroot",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_nroot", "\\sqrt[]{","}", 6);
- (void) new KileAction::Tag("Left-Right - \\left(..\\right)",0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_leftright", "\\left( \\right)", QString::null, 7);
+ (void) new KileAction::Tag("Left-Right - \\left(..\\right)",0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_leftright", "\\left( \\right)", TQString(), 7);
- (void) new KileAction::Tag(i18n("Extendable Left Arrow - \\xleftarrow{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_xleftarrow", "\\xleftarrow{","}", 12);
+ (void) new KileAction::Tag(i18n("Extendable Left Arrow - \\xleftarrow{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_xleftarrow", "\\xleftarrow{","}", 12);
- (void) new KileAction::Tag(i18n("Extendable Right Arrow - \\xrightarrow{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_xrightarrow", "\\xrightarrow{","}", 13);
+ (void) new KileAction::Tag(i18n("Extendable Right Arrow - \\xrightarrow{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_xrightarrow", "\\xrightarrow{","}", 13);
- (void) new KileAction::Tag(i18n("Boxed Formula - \\boxed{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_boxed", "\\boxed{","}", 7);
+ (void) new KileAction::Tag(i18n("Boxed Formula - \\boxed{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_boxed", "\\boxed{","}", 7);
- (void) new KileAction::Tag(i18n("bigl - \\bigl"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_bigl", "\\bigl",QString::null, 5);
- (void) new KileAction::Tag(i18n("Bigl - \\Bigl"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Bigl", "\\Bigl",QString::null, 5);
- (void) new KileAction::Tag(i18n("biggl - \\biggl"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_biggl", "\\biggl",QString::null, 6);
- (void) new KileAction::Tag(i18n("Biggl - \\Biggl"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Biggl", "\\Biggl",QString::null, 6);
+ (void) new KileAction::Tag(i18n("bigl - \\bigl"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_bigl", "\\bigl",TQString(), 5);
+ (void) new KileAction::Tag(i18n("Bigl - \\Bigl"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Bigl", "\\Bigl",TQString(), 5);
+ (void) new KileAction::Tag(i18n("biggl - \\biggl"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_biggl", "\\biggl",TQString(), 6);
+ (void) new KileAction::Tag(i18n("Biggl - \\Biggl"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Biggl", "\\Biggl",TQString(), 6);
- (void) new KileAction::Tag(i18n("bigr - \\bigr"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_bigr", "\\bigr",QString::null, 5);
- (void) new KileAction::Tag(i18n("Bigr - \\Bigr"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Bigr", "\\Bigr",QString::null, 5);
- (void) new KileAction::Tag(i18n("biggr - \\biggr"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_biggr", "\\biggr",QString::null, 6);
- (void) new KileAction::Tag(i18n("Biggr - \\Biggr"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Biggr", "\\Biggr",QString::null, 6);
+ (void) new KileAction::Tag(i18n("bigr - \\bigr"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_bigr", "\\bigr",TQString(), 5);
+ (void) new KileAction::Tag(i18n("Bigr - \\Bigr"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Bigr", "\\Bigr",TQString(), 5);
+ (void) new KileAction::Tag(i18n("biggr - \\biggr"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_biggr", "\\biggr",TQString(), 6);
+ (void) new KileAction::Tag(i18n("Biggr - \\Biggr"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_Biggr", "\\Biggr",TQString(), 6);
// text in mathmode
- (void) new KileAction::Tag(i18n("Text in Mathmode - \\text{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_text", "\\text{","}", 6);
+ (void) new KileAction::Tag(i18n("Text in Mathmode - \\text{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_text", "\\text{","}", 6);
- (void) new KileAction::Tag(i18n("Intertext - \\intertext{}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_intertext", "\\intertext{","}\n", 11);
+ (void) new KileAction::Tag(i18n("Intertext - \\intertext{}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)), ac,"tag_intertext", "\\intertext{","}\n", 11);
// math environments
- (void) new KileAction::Tag(i18n("Displaymath - \\begin{displaymath}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_displaymath","\\begin{displaymath}\n","%E\n\\end{displaymath}\n",0,1);
+ (void) new KileAction::Tag(i18n("Displaymath - \\begin{displaymath}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_displaymath","\\begin{displaymath}\n","%E\n\\end{displaymath}\n",0,1);
- (void) new KileAction::Tag(i18n("Equation (not numbered) - \\begin{equation*}"),0, parent, SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_equation*","\\begin{equation*}\n","%E\n\\end{equation*}\n",0,1);
+ (void) new KileAction::Tag(i18n("Equation (not numbered) - \\begin{equation*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertTag(const KileAction::TagData&)), ac,"tag_env_equation*","\\begin{equation*}\n","%E\n\\end{equation*}\n",0,1);
// AMS environments
- (void) new KileAction::Tag(i18n("Multline - \\begin{multline}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_multline","\\begin{multline}\n","%E\n\\end{multline}\n", 0,1);
- (void) new KileAction::Tag(i18n("Multline* - \\begin{multline*}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_multline*","\\begin{multline*}\n","%E\n\\end{multline*}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Multline - \\begin{multline}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_multline","\\begin{multline}\n","%E\n\\end{multline}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Multline* - \\begin{multline*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_multline*","\\begin{multline*}\n","%E\n\\end{multline*}\n", 0,1);
- (void) new KileAction::Tag(i18n("Split - \\begin{split}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_split","\\begin{split}\n","%E\n\\end{split}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Split - \\begin{split}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_split","\\begin{split}\n","%E\n\\end{split}\n", 0,1);
- (void) new KileAction::Tag(i18n("Gather - \\begin{gather}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_gather","\\begin{gather}\n","%E\n\\end{gather}\n", 0,1);
- (void) new KileAction::Tag(i18n("Gather* - \\begin{gather*}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_gather*","\\begin{gather*}\n","%E\n\\end{gather*}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Gather - \\begin{gather}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_gather","\\begin{gather}\n","%E\n\\end{gather}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Gather* - \\begin{gather*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_gather*","\\begin{gather*}\n","%E\n\\end{gather*}\n", 0,1);
- (void) new KileAction::Tag(i18n("Align - \\begin{align}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_align","\\begin{align}\n","%E\n\\end{align}\n", 0,1);
- (void) new KileAction::Tag(i18n("Align* - \\begin{align*}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_align*","\\begin{align*}\n","%E\n\\end{align*}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Align - \\begin{align}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_align","\\begin{align}\n","%E\n\\end{align}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Align* - \\begin{align*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_align*","\\begin{align*}\n","%E\n\\end{align*}\n", 0,1);
- (void) new KileAction::Tag(i18n("Flalign - \\begin{flalign}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_flalign","\\begin{flalign}\n","%E\n\\end{flalign}\n", 0,1);
- (void) new KileAction::Tag(i18n("Flalign* - \\begin{flalign*}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_flalign*","\\begin{flalign*}\n","%E\n\\end{flalign*}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Flalign - \\begin{flalign}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_flalign","\\begin{flalign}\n","%E\n\\end{flalign}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Flalign* - \\begin{flalign*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_flalign*","\\begin{flalign*}\n","%E\n\\end{flalign*}\n", 0,1);
- (void) new KileAction::Tag(i18n("Alignat - \\begin{alignat}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_alignat","\\begin{alignat}{","}\n%E\n\\end{alignat}\n", 16,0);
- (void) new KileAction::Tag(i18n("Alignat* - \\begin{alignat*}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_alignat*","\\begin{alignat*}{","}\n%E\n\\end{alignat*}\n", 17,0);
+ (void) new KileAction::Tag(i18n("Alignat - \\begin{alignat}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_alignat","\\begin{alignat}{","}\n%E\n\\end{alignat}\n", 16,0);
+ (void) new KileAction::Tag(i18n("Alignat* - \\begin{alignat*}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_alignat*","\\begin{alignat*}{","}\n%E\n\\end{alignat*}\n", 17,0);
- (void) new KileAction::Tag(i18n("Aligned - \\begin{aligned}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_aligned","\\begin{aligned}\n","%E\n\\end{aligned}\n", 0,1);
- (void) new KileAction::Tag(i18n("Gathered - \\begin{gathered}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_gathered","\\begin{gathered}\n","%E\n\\end{gathered}\n", 0,1);
- (void) new KileAction::Tag(i18n("Alignedat - \\begin{alignedat}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_alignedat","\\begin{alignedat}\n","%E\n\\end{alignedat}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Aligned - \\begin{aligned}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_aligned","\\begin{aligned}\n","%E\n\\end{aligned}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Gathered - \\begin{gathered}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_gathered","\\begin{gathered}\n","%E\n\\end{gathered}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Alignedat - \\begin{alignedat}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_alignedat","\\begin{alignedat}\n","%E\n\\end{alignedat}\n", 0,1);
- (void) new KileAction::Tag(i18n("Cases - \\begin{cases}"),0, parent, SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_cases","\\begin{cases}\n","%E\n\\end{cases}\n", 0,1);
+ (void) new KileAction::Tag(i18n("Cases - \\begin{cases}"),0, TQT_TQOBJECT(tqparent), TQT_SLOT(insertAmsTag(const KileAction::TagData&)),ac,"tag_env_cases","\\begin{cases}\n","%E\n\\end{cases}\n", 0,1);
}
diff --git a/src/kile/kilestdactions.h b/src/kile/kilestdactions.h
index bc86577..51b2de0 100644
--- a/src/kile/kilestdactions.h
+++ b/src/kile/kilestdactions.h
@@ -23,9 +23,9 @@ class KMainWindow;
namespace KileStdActions
{
- void setupStdTags(KileInfo *ki, KMainWindow *parent);
- void setupBibTags(KMainWindow *parent);
- void setupMathTags(KMainWindow *parent);
+ void setupStdTags(KileInfo *ki, KMainWindow *tqparent);
+ void setupBibTags(KMainWindow *tqparent);
+ void setupMathTags(KMainWindow *tqparent);
}
#endif
diff --git a/src/kile/kilestdtools.cpp b/src/kile/kilestdtools.cpp
index 57f4530..5dfa9e6 100644
--- a/src/kile/kilestdtools.cpp
+++ b/src/kile/kilestdtools.cpp
@@ -15,8 +15,8 @@
#include "kilestdtools.h"
-#include <qfileinfo.h>
-#include <qregexp.h>
+#include <tqfileinfo.h>
+#include <tqregexp.h>
#include <kconfig.h>
#include <klocale.h>
@@ -35,13 +35,13 @@
namespace KileTool
{
- Base* Factory::create(const QString & tool, bool prepare /* = true */)
+ Base* Factory::create(const TQString & tool, bool prepare /* = true */)
{
//perhaps we can find the tool in the config file
if (m_config->hasGroup(groupFor(tool, m_config)))
{
m_config->setGroup(groupFor(tool, m_config));
- QString toolClass = m_config->readEntry("class", "");
+ TQString toolClass = m_config->readEntry("class", "");
if ( toolClass == "LaTeX")
return new LaTeX(tool, m_manager, prepare);
@@ -83,8 +83,8 @@ namespace KileTool
void Factory::writeStdConfig()
{
- QString from_cfg = KGlobal::dirs()->findResource("appdata", "kilestdtools.rc");
- QString to_cfg = KGlobal::dirs()->saveLocation("config") + "/kilerc";
+ TQString from_cfg = KGlobal::dirs()->findResource("appdata", "kilestdtools.rc");
+ TQString to_cfg = KGlobal::dirs()->saveLocation("config") + "/kilerc";
KConfig *pCfg = new KConfig(from_cfg, false, false);
pCfg->copyTo(to_cfg, m_config);
}
@@ -110,8 +110,8 @@ namespace KileTool
KileDocument::TextInfo *docinfo = manager()->info()->docManager()->textInfoFor(source());
if ( docinfo )
{
- const QStringList *pckgs = manager()->info()->allPackages();
- if ( pckgs->contains("makeidx") )
+ const TQStringList *pckgs = manager()->info()->allPackages();
+ if ( pckgs->tqcontains("makeidx") )
return needsUpdate ( baseDir() + '/' + S() + ".ind", manager()->info()->lastModifiedFile(docinfo) );
}
@@ -124,14 +124,14 @@ namespace KileTool
if ( docinfo)
{
- const QStringList *pckgs = manager()->info()->allPackages();
- if ( pckgs->contains("asymptote") )
+ const TQStringList *pckgs = manager()->info()->allPackages();
+ if ( pckgs->tqcontains("asymptote") )
{
- static QRegExp msg("File " + QRegExp::escape(S()) + "_?\\d+_?.(?:eps|pdf|tex) does not exist");
+ static TQRegExp msg("File " + TQRegExp::escape(S()) + "_?\\d+_?.(?:eps|pdf|tex) does not exist");
int sz = manager()->info()->outputInfo()->size();
for (int i = 0; i < sz; ++i )
{
- if( (*manager()->info()->outputInfo())[i].message().contains(msg) )
+ if( (*manager()->info()->outputInfo())[i].message().tqcontains(msg) )
return true;
}
}
@@ -157,7 +157,7 @@ namespace KileTool
bool LaTeX::filterLogfile()
{
manager()->info()->outputFilter()->setSource(source());
- QString log = baseDir() + '/' + S() + ".log";
+ TQString log = baseDir() + '/' + S() + ".log";
return manager()->info()->outputFilter()->Run(log);
}
@@ -168,15 +168,15 @@ namespace KileTool
manager()->info()->outputFilter()->sendProblems();
manager()->info()->outputFilter()->getErrorCount(&nErrors, &nWarnings, &nBadBoxes);
- QString es = i18n("%n error", "%n errors", nErrors);
- QString ws = i18n("%n warning", "%n warnings", nWarnings);
- QString bs = i18n("%n badbox", "%n badboxes", nBadBoxes);
+ TQString es = i18n("%n error", "%n errors", nErrors);
+ TQString ws = i18n("%n warning", "%n warnings", nWarnings);
+ TQString bs = i18n("%n badbox", "%n badboxes", nBadBoxes);
sendMessage(Info, es +", " + ws + ", " + bs);
//jump to first error
if ( nErrors > 0 && (readEntry("jumpToFirstError") == "yes") ) {
- connect(this, SIGNAL(jumpToFirstError()), manager(), SIGNAL(jumpToFirstError()));
+ connect(this, TQT_SIGNAL(jumpToFirstError()), manager(), TQT_SIGNAL(jumpToFirstError()));
emit(jumpToFirstError());
}
}
@@ -192,7 +192,7 @@ namespace KileTool
for (int i = 0; i < sz; ++i )
{
if ( (*manager()->info()->outputInfo())[i].type() == LatexOutputInfo::itmWarning
- && (*manager()->info()->outputInfo())[i].message().contains("Rerun") )
+ && (*manager()->info()->outputInfo())[i].message().tqcontains("Rerun") )
{
reRan = true;
break;
@@ -271,7 +271,7 @@ namespace KileTool
return Compile::finish(r);
}
- void PreviewLaTeX::setPreviewInfo(const QString &filename, int selrow,int docrow)
+ void PreviewLaTeX::setPreviewInfo(const TQString &filename, int selrow,int docrow)
{
m_filename = filename;
m_selrow = selrow;
@@ -285,16 +285,16 @@ namespace KileTool
int para = manager()->info()->lineNumber();
Kate::Document *doc = manager()->info()->activeTextDocument();
- QString filepath;
+ TQString filepath;
if (doc)
filepath = doc->url().path();
else
return false;
- QString texfile = manager()->info()->relativePath(baseDir(),filepath);
- m_urlstr = "file:" + targetDir() + '/' + target() + "#src:" + QString::number(para+1) + ' ' + texfile; // space added, for files starting with numbers
- addDict("%dir_target", QString::null);
+ TQString texfile = manager()->info()->relativePath(baseDir(),filepath);
+ m_urlstr = "file:" + targetDir() + '/' + target() + "#src:" + TQString::number(para+1) + ' ' + texfile; // space added, for files starting with numbers
+ addDict("%dir_target", TQString());
addDict("%target", m_urlstr);
KILE_DEBUG() << "==KileTool::ForwardDVI::determineTarget()=============\n" << endl;
KILE_DEBUG() << "\tusing " << m_urlstr << endl;
@@ -308,15 +308,15 @@ namespace KileTool
if (!View::determineSource())
return false;
- QString path = source(true);
- QFileInfo info(path);
+ TQString path = source(true);
+ TQFileInfo info(path);
//get the bibliographies for this source
- const QStringList *bibs = manager()->info()->allBibliographies(manager()->info()->docManager()->textInfoFor(path));
+ const TQStringList *bibs = manager()->info()->allBibliographies(manager()->info()->docManager()->textInfoFor(path));
KILE_DEBUG() << "\tfound " << bibs->count() << " bibs" << endl;
if (bibs->count() > 0)
{
- QString bib = bibs->front();
+ TQString bib = bibs->front();
if (bibs->count() > 1)
{
//show dialog
@@ -356,8 +356,8 @@ namespace KileTool
if (target().isNull())
{
//setRelativeBaseDir(S());
- QString dir = readEntry("relDir");
- QString trg = readEntry("target");
+ TQString dir = readEntry("relDir");
+ TQString trg = readEntry("target");
if ( !dir.isEmpty() )
{
@@ -374,15 +374,15 @@ namespace KileTool
//auto-detect the file to view
if ( dir.isEmpty() && trg.isEmpty() )
{
- QFileInfo file1 = QFileInfo(baseDir() + '/' + S() + "/index.html");
- QFileInfo file2 = QFileInfo(baseDir() + '/' + S() + ".html");
+ TQFileInfo file1 = TQFileInfo(baseDir() + '/' + S() + "/index.html");
+ TQFileInfo file2 = TQFileInfo(baseDir() + '/' + S() + ".html");
bool read1 = file1.isReadable();
bool read2 = file2.isReadable();
if ( !read1 && !read2 )
{
- sendMessage(Error, i18n("Unable to find %1 or %2; if you are trying to view some other HTML file, go to Settings->Configure Kile->Tools->ViewHTML->Advanced.").arg(file1.absFilePath()).arg(file2.absFilePath()));
+ sendMessage(Error, i18n("Unable to tqfind %1 or %2; if you are trying to view some other HTML file, go to Settings->Configure Kile->Tools->ViewHTML->Advanced.").tqarg(file1.absFilePath()).tqarg(file2.absFilePath()));
return false;
}
diff --git a/src/kile/kilestdtools.h b/src/kile/kilestdtools.h
index 2e89c59..ca5e6b2 100644
--- a/src/kile/kilestdtools.h
+++ b/src/kile/kilestdtools.h
@@ -17,7 +17,7 @@
#define KILESTDTOOLS_H
#include "kiledebug.h"
-#include <qstring.h>
+#include <tqstring.h>
#include "kiletool.h"
@@ -35,7 +35,7 @@ namespace KileTool
Factory(Manager *mngr, KConfig *config) : m_manager(mngr), m_config(config) {}
~Factory() {}
- Base* create(const QString & tool, bool prepare = true);
+ Base* create(const TQString & tool, bool prepare = true);
void writeStdConfig();
@@ -47,9 +47,10 @@ namespace KileTool
class LaTeX : public Compile
{
Q_OBJECT
+ TQ_OBJECT
public:
- LaTeX(const QString & tool, Manager *mngr, bool prepare) : Compile(tool, mngr, prepare) {}
+ LaTeX(const TQString & tool, Manager *mngr, bool prepare) : Compile(tool, mngr, prepare) {}
signals:
void jumpToFirstError();
@@ -74,17 +75,18 @@ namespace KileTool
class PreviewLaTeX : public LaTeX
{
Q_OBJECT
+ TQ_OBJECT
public:
- PreviewLaTeX(const QString & tool, Manager *mngr, bool prepare) : LaTeX(tool, mngr, prepare) {}
+ PreviewLaTeX(const TQString & tool, Manager *mngr, bool prepare) : LaTeX(tool, mngr, prepare) {}
- void setPreviewInfo(const QString &filename, int selrow,int docrow);
+ void setPreviewInfo(const TQString &filename, int selrow,int docrow);
public slots:
bool finish(int);
private:
- QString m_filename;
+ TQString m_filename;
int m_selrow;
int m_docrow;
@@ -93,19 +95,19 @@ namespace KileTool
class ForwardDVI : public View
{
public:
- ForwardDVI(const QString & tool, Manager *mngr, bool prepare = true) : View(tool, mngr, prepare) {}
+ ForwardDVI(const TQString & tool, Manager *mngr, bool prepare = true) : View(tool, mngr, prepare) {}
protected:
bool determineTarget();
private:
- QString m_urlstr;
+ TQString m_urlstr;
};
class ViewBib : public View
{
public:
- ViewBib(const QString & tool, Manager *mngr, bool prepare = true) : View(tool, mngr, prepare) {}
+ ViewBib(const TQString & tool, Manager *mngr, bool prepare = true) : View(tool, mngr, prepare) {}
protected:
bool determineSource();
@@ -114,15 +116,16 @@ namespace KileTool
class ViewHTML : public View
{
Q_OBJECT
+ TQ_OBJECT
public:
- ViewHTML(const QString & tool, Manager *mngr, bool prepare = true) : View(tool, mngr, prepare) {}
+ ViewHTML(const TQString & tool, Manager *mngr, bool prepare = true) : View(tool, mngr, prepare) {}
protected:
bool determineTarget();
signals:
- void updateStatus(bool, bool);
+ void updatetqStatus(bool, bool);
};
}
diff --git a/src/kile/kilestructurewidget.cpp b/src/kile/kilestructurewidget.cpp
index 3735f23..b3205a6 100644
--- a/src/kile/kilestructurewidget.cpp
+++ b/src/kile/kilestructurewidget.cpp
@@ -17,10 +17,10 @@
// 2005-11-02: dani
// - cleaning up source (local variables etc.)
-// - added different QToolTips for each item
+// - added different TQToolTips for each item
// - add more types of KilelistViewItems
// - KileStruct::Sect and KileStruct::BeginFloat will remember assigned labels,
-// which are displayed as QToolTips, if these labels are defined in the
+// which are displayed as TQToolTips, if these labels are defined in the
// same or the next line
// - Caption for type KileStruct::BeginFloat are displayed in the title
// of this item
@@ -59,10 +59,10 @@
#include "kilestructurewidget.h"
-#include <qfileinfo.h>
-#include <qheader.h>
-#include <qregexp.h>
-#include <qclipboard.h>
+#include <tqfileinfo.h>
+#include <tqheader.h>
+#include <tqregexp.h>
+#include <tqclipboard.h>
#include <kapplication.h>
#include "kiledebug.h"
@@ -81,25 +81,25 @@
////////////////////// KileListViewItem with all info //////////////////////
-KileListViewItem::KileListViewItem(QListViewItem * parent, QListViewItem * after, const QString &title, const KURL &url, uint line, uint column, int type, int level, uint startline, uint startcol) :
- KListViewItem(parent,after),
+KileListViewItem::KileListViewItem(TQListViewItem * tqparent, TQListViewItem * after, const TQString &title, const KURL &url, uint line, uint column, int type, int level, uint startline, uint startcol) :
+ KListViewItem(tqparent,after),
m_title(title), m_url(url), m_line(line), m_column(column), m_type(type), m_level(level),
m_startline(startline), m_startcol(startcol)
{
setItemEntry();
}
-KileListViewItem::KileListViewItem(QListView * parent, const QString & label) :
- KListViewItem(parent,label),
+KileListViewItem::KileListViewItem(TQListView * tqparent, const TQString & label) :
+ KListViewItem(tqparent,label),
m_title(label), m_url(KURL()), m_line(0), m_column(0), m_type(KileStruct::None), m_level(0)
{}
-KileListViewItem::KileListViewItem(QListViewItem * parent, const QString & label) :
- KListViewItem(parent,label),
+KileListViewItem::KileListViewItem(TQListViewItem * tqparent, const TQString & label) :
+ KListViewItem(tqparent,label),
m_title(label), m_url(KURL()), m_line(0), m_column(0), m_type(KileStruct::None), m_level(0)
{}
-void KileListViewItem::setTitle(const QString &title)
+void KileListViewItem::setTitle(const TQString &title)
{
m_title = title;
setItemEntry();
@@ -107,15 +107,15 @@ void KileListViewItem::setTitle(const QString &title)
void KileListViewItem::setItemEntry()
{
- setText(0, m_title + " (" + i18n("line") + ' ' + QString::number(m_line) + ')');
+ setText(0, m_title + " (" + i18n("line") + ' ' + TQString::number(m_line) + ')');
}
////////////////////// introduce a new ToolTip //////////////////////
-KileListViewToolTip::KileListViewToolTip(KListView *listview) : QToolTip(listview->viewport()), m_listview(listview)
+KileListViewToolTip::KileListViewToolTip(KListView *listview) : TQToolTip(listview->viewport()), m_listview(listview)
{}
-void KileListViewToolTip::maybeTip(const QPoint &p)
+void KileListViewToolTip::maybeTip(const TQPoint &p)
{
if ( ! m_listview )
return;
@@ -125,7 +125,7 @@ void KileListViewToolTip::maybeTip(const QPoint &p)
if ( !item )
return;
- const QRect rect = m_listview->itemRect(item);
+ const TQRect rect = m_listview->tqitemRect(item);
if ( ! rect.isValid() )
return;
@@ -133,7 +133,7 @@ void KileListViewToolTip::maybeTip(const QPoint &p)
{
tip(rect,i18n("Label: ") + item->label());
}
- else if ( item->line()==0 && item->column()==0 && item->parent()==0L ) // only root
+ else if ( item->line()==0 && item->column()==0 && item->tqparent()==0L ) // only root
{
tip(rect,i18n("Click left to jump to the line. A double click will open\n a text file or a graphics file. When a label is assigned\nto this item, it will be shown when the mouse is over\nthis item. Items for a graphics file or an assigned label\nalso offer a context menu (right mouse button)."));
}
@@ -154,17 +154,17 @@ namespace KileWidget
setSorting(-1,true);
setAllColumnsShowFocus(true);
setFullWidth(true);
- setSizePolicy(QSizePolicy::Ignored,QSizePolicy::Ignored);
+ tqsetSizePolicy(TQSizePolicy::Ignored,TQSizePolicy::Ignored);
- QToolTip::remove(this);
+ TQToolTip::remove(this);
new KileListViewToolTip(this);
- //connect(this, SIGNAL(clicked(QListViewItem *)), m_stack, SLOT(slotClicked(QListViewItem *)));
- connect(this, SIGNAL(doubleClicked(QListViewItem *)), m_stack, SLOT(slotDoubleClicked(QListViewItem *)));
- connect(this, SIGNAL(contextMenu(KListView *, QListViewItem *, const QPoint & )), m_stack, SLOT(slotPopup(KListView *, QListViewItem * , const QPoint & )));
+ //connect(this, TQT_SIGNAL(clicked(TQListViewItem *)), m_stack, TQT_SLOT(slotClicked(TQListViewItem *)));
+ connect(this, TQT_SIGNAL(doubleClicked(TQListViewItem *)), m_stack, TQT_SLOT(slotDoubleClicked(TQListViewItem *)));
+ connect(this, TQT_SIGNAL(contextMenu(KListView *, TQListViewItem *, const TQPoint & )), m_stack, TQT_SLOT(slotPopup(KListView *, TQListViewItem * , const TQPoint & )));
- connect(this, SIGNAL(executed(QListViewItem*)), m_stack, SLOT(slotClicked(QListViewItem*)));
- connect(m_stack, SIGNAL(configChanged()), this, SLOT(slotConfigChanged()));
+ connect(this, TQT_SIGNAL(executed(TQListViewItem*)), m_stack, TQT_SLOT(slotClicked(TQListViewItem*)));
+ connect(m_stack, TQT_SIGNAL(configChanged()), this, TQT_SLOT(slotConfigChanged()));
init();
}
@@ -173,16 +173,16 @@ namespace KileWidget
void StructureList::init()
{
- QString title = (m_docinfo == 0L ) ? i18n("No \"structure data\" to display.") : m_docinfo->url().fileName();
+ TQString title = (m_docinfo == 0L ) ? i18n("No \"structure data\" to display.") : m_docinfo->url().fileName();
m_root = new KileListViewItem(this, title);
if ( m_docinfo != 0L )
{
m_root->setURL(m_docinfo->url());
m_root->setOpen(true);
m_root->setPixmap(0, SmallIcon("contents"));
- connect(m_docinfo, SIGNAL(foundItem(const QString&, uint, uint, int, int, uint, uint, const QString &, const QString &)),
- this, SLOT(addItem(const QString&, uint, uint, int, int, uint, uint, const QString &, const QString &)));
-// connect(m_docinfo, SIGNAL(doneUpdating()), this, SLOT(insertInMasterList()));
+ connect(m_docinfo, TQT_SIGNAL(foundItem(const TQString&, uint, uint, int, int, uint, uint, const TQString &, const TQString &)),
+ this, TQT_SLOT(addItem(const TQString&, uint, uint, int, int, uint, uint, const TQString &, const TQString &)));
+// connect(m_docinfo, TQT_SIGNAL(doneUpdating()), this, TQT_SLOT(insertInMasterList()));
}
m_parent[0]=m_parent[1]=m_parent[2]=m_parent[3]=m_parent[4]=m_parent[5]=m_parent[6]=m_root;
@@ -232,7 +232,7 @@ namespace KileWidget
}
void StructureList::slotConfigChanged(){
- QWidget *current = m_stack->visibleWidget();
+ TQWidget *current = m_stack->visibleWidget();
if(!current)
return;
cleanUp(false);
@@ -247,7 +247,7 @@ namespace KileWidget
m_openByLine.clear();
m_openByFolders.clear();
- QListViewItemIterator it(this);
+ TQListViewItemIterator it(this);
KileListViewItem *item = 0L;
while ( it.current() )
{
@@ -256,7 +256,7 @@ namespace KileWidget
{
//we don't accept duplicate entries in the map, remove this item alltogether
//and rely on the openByLine map instead
- if ( m_openByTitle.contains ( item->title() ) )
+ if ( m_openByTitle.tqcontains ( item->title() ) )
m_openByTitle.remove ( item->title() );
else
m_openByTitle [ item->title() ] = item->isOpen();
@@ -266,60 +266,60 @@ namespace KileWidget
++it;
}
- if ( m_folders.contains("labels") )
+ if ( m_folders.tqcontains("labels") )
m_openByFolders["labels"] = m_folders["labels"]->isOpen();
- if ( m_folders.contains("refs") )
+ if ( m_folders.tqcontains("refs") )
m_openByFolders["refs"] = m_folders["refs"]->isOpen();
- if ( m_folders.contains("bibs") )
+ if ( m_folders.tqcontains("bibs") )
m_openByFolders["bibs"] = m_folders["bibs"]->isOpen();
- if ( m_folders.contains("todo") )
+ if ( m_folders.tqcontains("todo") )
m_openByFolders["todo"] = m_folders["todo"]->isOpen();
- if ( m_folders.contains("fixme") )
+ if ( m_folders.tqcontains("fixme") )
m_openByFolders["fixme"] = m_folders["fixme"]->isOpen();
}
- bool StructureList::shouldBeOpen(KileListViewItem *item, const QString & folder, int level)
+ bool StructureList::shouldBeOpen(KileListViewItem *item, const TQString & folder, int level)
{
- if ( item->parent() == 0L )
+ if ( item->tqparent() == 0L )
return true;
if ( folder == "labels" )
{
- if ( m_openByFolders.contains("labels") )
+ if ( m_openByFolders.tqcontains("labels") )
return m_openByFolders["labels"];
else
return m_openStructureLabels;
}
else if ( folder == "refs" )
{
- if ( m_openByFolders.contains("refs") )
+ if ( m_openByFolders.tqcontains("refs") )
return m_openByFolders["refs"];
else
return m_openStructureReferences;
}
else if ( folder == "bibs" )
{
- if ( m_openByFolders.contains("bibs") )
+ if ( m_openByFolders.tqcontains("bibs") )
return m_openByFolders["bibs"];
else
return m_openStructureBibitems;
}
else if ( folder=="todo" || folder=="fixme" )
{
- if ( m_openByFolders.contains(folder) )
+ if ( m_openByFolders.tqcontains(folder) )
return m_openByFolders[folder];
else
return m_openStructureTodo;
}
- if ( m_openByTitle.contains(item->title()) )
+ if ( m_openByTitle.tqcontains(item->title()) )
return m_openByTitle [ item->title() ];
- else if ( m_openByLine.contains(item->line()) )
+ else if ( m_openByLine.tqcontains(item->line()) )
return m_openByLine [ item->line() ]; //TODO check surrounding lines as well
else
return ((folder == "root") && level <= m_stack->level());
}
- KileListViewItem* StructureList::createFolder(const QString &folder)
+ KileListViewItem* StructureList::createFolder(const TQString &folder)
{
KileListViewItem *fldr= new KileListViewItem(m_root, folder);
fldr->setOpen(false);
@@ -354,7 +354,7 @@ namespace KileWidget
return m_folders[folder];
}
- KileListViewItem* StructureList::folder(const QString &folder)
+ KileListViewItem* StructureList::folder(const TQString &folder)
{
KileListViewItem *item = m_folders[folder];
if ( item == 0L ) item = createFolder(folder);
@@ -366,7 +366,7 @@ namespace KileWidget
m_stack->raiseWidget(this);
}
- KileListViewItem *StructureList::parentFor(int lev, const QString & fldr)
+ KileListViewItem *StructureList::tqparentFor(int lev, const TQString & fldr)
{
KileListViewItem *par = 0L;
@@ -402,8 +402,8 @@ namespace KileWidget
/* some items have a special action:
- KileStruct::Sect:
The new item is saved in m_lastSectioning, so that all following entries
- can be inserted as children. \part will drop back to level 0 of the Listview,
- all other sectioning commands will be children of the last sectioning item.
+ can be inserted as tqchildren. \part will drop back to level 0 of the Listview,
+ all other sectioning commands will be tqchildren of the last sectioning item.
If a \label command follows in the same or the next line, it is assigned
to this item.
- KileStruct::BeginFloat:
@@ -436,9 +436,9 @@ namespace KileWidget
immediately as next command, it is inserted into the title of this item.
*/
- void StructureList::addItem(const QString &title, uint line, uint column, int type, int lev,
+ void StructureList::addItem(const TQString &title, uint line, uint column, int type, int lev,
uint startline, uint startcol,
- const QString & pix, const QString &fldr /* = "root" */)
+ const TQString & pix, const TQString &fldr /* = "root" */)
{
// KILE_DEBUG() << "\t\taddItem: " << title << ", with type " << type << endl;
if ( m_stop ) return;
@@ -450,7 +450,7 @@ namespace KileWidget
}
else if ( type==KileStruct::Caption && m_lastFloat )
{
- QString floattitle = m_lastFloat->title();
+ TQString floattitle = m_lastFloat->title();
if ( floattitle=="figure" || floattitle=="table" )
m_lastFloat->setTitle(floattitle+": "+title);
}
@@ -504,17 +504,17 @@ namespace KileWidget
m_lastType = type;
m_lastLine = line;
- //find the parent for the new element
- KileListViewItem *parentItem = ( type==KileStruct::BeamerBeginBlock && m_lastFrameEnv ) ? m_lastFrameEnv : parentFor(lev, fldr);
- if ( parentItem == 0L )
+ //find the tqparent for the new element
+ KileListViewItem *tqparentItem = ( type==KileStruct::BeamerBeginBlock && m_lastFrameEnv ) ? m_lastFrameEnv : tqparentFor(lev, fldr);
+ if ( tqparentItem == 0L )
{
- KMessageBox::error(0,i18n("Can't create ListviewItem: no parent found."));
+ KMessageBox::error(0,i18n("Can't create ListviewItem: no tqparent found."));
return;
}
//find the last element at this level
KileListViewItem *lastChild = 0L;
- KileListViewItem *nextChild = (KileListViewItem *)parentItem->firstChild();
+ KileListViewItem *nextChild = (KileListViewItem *)tqparentItem->firstChild();
while ( nextChild )
{
lastChild = nextChild;
@@ -522,14 +522,14 @@ namespace KileWidget
}
// create a new item
- KileListViewItem *newChild = new KileListViewItem(parentItem, lastChild, title, m_docinfo->url(), line, column, type, lev, startline, startcol);
+ KileListViewItem *newChild = new KileListViewItem(tqparentItem, lastChild, title, m_docinfo->url(), line, column, type, lev, startline, startcol);
if ( ! pix.isNull() )
newChild->setPixmap(0,SmallIcon(pix));
//m_stop = true;
//if the level is not greater than the defaultLevel
- //open the parentItem to make this item visible
- parentItem->setOpen( shouldBeOpen(parentItem,fldr,lev) );
+ //open the tqparentItem to make this item visible
+ tqparentItem->setOpen( shouldBeOpen(tqparentItem,fldr,lev) );
//update the m_parent levels, such that section etc. get inserted at the correct level
//m_current = newChild;
@@ -559,7 +559,7 @@ namespace KileWidget
void StructureList::showReferences(KileInfo *ki)
{
// remove old listview item for references, if it exists
- if ( m_folders.contains("refs") )
+ if ( m_folders.tqcontains("refs") )
{
KileListViewItem *refitem = m_folders["refs"];
m_root->takeItem(refitem);
@@ -574,19 +574,19 @@ namespace KileWidget
return;
// read list with all labels
- const QStringList *list = ki->allLabels();
+ const TQStringList *list = ki->allLabels();
//KILE_DEBUG() << "\tfound " << list->count() << " labels" << endl;
- QMap<QString,bool> labelmap;
- for ( QStringList::ConstIterator itmap=list->begin(); itmap!=list->end(); ++itmap )
+ TQMap<TQString,bool> labelmap;
+ for ( TQStringList::ConstIterator itmap=list->begin(); itmap!=list->end(); ++itmap )
{
labelmap[(*itmap)] = true;
}
// now check if there are unsolved references
- QValueListConstIterator<KileReferenceData> it;
+ TQValueListConstIterator<KileReferenceData> it;
for ( it=m_references.begin(); it!=m_references.end(); ++it )
{
- if ( ! labelmap.contains((*it).name()) )
+ if ( ! labelmap.tqcontains((*it).name()) )
{
KileListViewItem *refitem = folder("refs");
refitem->setOpen( shouldBeOpen(refitem,"refs",0) );
@@ -595,10 +595,10 @@ namespace KileWidget
}
}
- ////////////////////// Structure: QWidgetStack //////////////////////
+ ////////////////////// Structure: TQWidgetStack //////////////////////
- Structure::Structure(KileInfo *ki, QWidget * parent, const char * name) :
- QWidgetStack(parent,name),
+ Structure::Structure(KileInfo *ki, TQWidget * tqparent, const char * name) :
+ TQWidgetStack(tqparent,name),
m_ki(ki),
m_docinfo(0L)
{
@@ -606,7 +606,7 @@ namespace KileWidget
setLineWidth(0);
setMidLineWidth(0);
setMargin(0);
- setSizePolicy(QSizePolicy::Ignored,QSizePolicy::Ignored);
+ tqsetSizePolicy(TQSizePolicy::Ignored,TQSizePolicy::Ignored);
m_default = new StructureList(this, 0L);
m_default->activate();
@@ -630,7 +630,7 @@ namespace KileWidget
m_map.insert(docinfo, view, true);
}
- void Structure::slotClicked(QListViewItem * itm)
+ void Structure::slotClicked(TQListViewItem * itm)
{
KILE_DEBUG() << "\tStructure::slotClicked" << endl;
@@ -640,15 +640,15 @@ namespace KileWidget
if (! (item->type() & KileStruct::None ))
emit(setCursor(item->url(), item->line()-1, item->column()));
- else if ( item->parent() == 0L ) //root item
+ else if ( item->tqparent() == 0L ) //root item
emit(setCursor(item->url(), 0, 0));
}
- void Structure::slotDoubleClicked(QListViewItem * itm)
+ void Structure::slotDoubleClicked(TQListViewItem * itm)
{
KILE_DEBUG() << "\tStructure::slotDoubleClicked" << endl;
KileListViewItem *item = (KileListViewItem*)(itm);
- static QRegExp::QRegExp suffix("\\.[\\d\\w]*$");
+ static TQRegExp::TQRegExp suffix("\\.[\\d\\w]*$");
if (!item)
return;
@@ -657,9 +657,9 @@ namespace KileWidget
if ( item->type() & (KileStruct::Input | KileStruct::Bibliography | KileStruct::Graphics) )
{
- QString fname = item->title();
+ TQString fname = item->title();
- if(fname.find(suffix) != -1) // check if we have a suffix, if not add standard suffixes
+ if(fname.tqfind(suffix) != -1) // check if we have a suffix, if not add standard suffixes
{
KILE_DEBUG() << "Suffix found: " << suffix.cap(0) << endl;
}
@@ -679,11 +679,11 @@ namespace KileWidget
if(fname.left(1) != "/") // no absolute path
{
- QString fn = m_ki->getCompileName();
- fname= QFileInfo(fn).dirPath() + '/' + fname;
+ TQString fn = m_ki->getCompileName();
+ fname= TQFileInfo(fn).dirPath() + '/' + fname;
}
- QFileInfo fi(fname);
+ TQFileInfo fi(fname);
KURL url;
url.setPath(fname);
@@ -695,14 +695,14 @@ namespace KileWidget
KRun::runURL(url,pMime->name());
}
else
- emit(fileOpen(url, QString::null));
+ emit(fileOpen(url, TQString()));
}
else if( item->type() == KileStruct::Bibliography ){
fname = m_ki->checkOtherPaths(fi.dirPath(),fi.fileName(),KileInfo::bibinputs);
fi.setFile(fname);
url.setPath(fname);
if(fi.isReadable()){
- emit(fileOpen(url, QString::null));
+ emit(fileOpen(url, TQString()));
}
}
else if( item->type() == KileStruct::Input ){
@@ -710,11 +710,11 @@ namespace KileWidget
fi.setFile(fname);
url.setPath(fname);
if(fi.isReadable()){
- emit(fileOpen(url, QString::null));
+ emit(fileOpen(url, TQString()));
}
}
else{
- if ( KMessageBox::warningYesNo(this, i18n("Cannot find the included file. The file does not exist, is not readable or Kile is unable to determine the correct path to it. The filename causing this error was: %1.\nDo you want to create this file?").arg(fname), i18n("Cannot Find File"))
+ if ( KMessageBox::warningYesNo(this, i18n("Cannot find the included file. The file does not exist, is not readable or Kile is unable to determine the correct path to it. The filename causing this error was: %1.\nDo you want to create this file?").tqarg(fname), i18n("Cannot Find File"))
== KMessageBox::Yes)
{
emit(fileNew(url));
@@ -728,7 +728,7 @@ namespace KileWidget
// - sectioning: 10 - 16
// - graphics: 100ff
- void Structure::slotPopup(KListView *, QListViewItem *itm, const QPoint &point)
+ void Structure::slotPopup(KListView *, TQListViewItem *itm, const TQPoint &point)
{
KILE_DEBUG() << "\tStructure::slotPopup" << endl;
@@ -761,11 +761,11 @@ namespace KileWidget
if(m_popupInfo.left(1) != "/") // no absolute path
{
- QString fn = m_ki->getCompileName();
- m_popupInfo = QFileInfo(fn).dirPath() + '/' + m_popupInfo;
+ TQString fn = m_ki->getCompileName();
+ m_popupInfo = TQFileInfo(fn).dirPath() + '/' + m_popupInfo;
}
- QFileInfo fi(m_popupInfo);
+ TQFileInfo fi(m_popupInfo);
if ( fi.isReadable() )
{
KURL url;
@@ -796,7 +796,7 @@ namespace KileWidget
if ( m_popup->count() > 0 )
{
- connect(m_popup,SIGNAL(activated(int)),this,SLOT(slotPopupActivated(int)));
+ connect(m_popup,TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotPopupActivated(int)));
m_popup->exec(point);
}
}
@@ -816,7 +816,7 @@ namespace KileWidget
{
KILE_DEBUG() << "\tStructure::slotPopupLabel (" << id << ")"<< endl;
- QString s = m_popupItem->label();
+ TQString s = m_popupItem->label();
if ( id==1 || id==4 )
s = "\\ref{" + s + '}';
else if ( id==2 || id==5 )
@@ -825,7 +825,7 @@ namespace KileWidget
if ( id <= 3 )
emit( sendText(s) );
else
- QApplication::clipboard()->setText(s);
+ TQApplication::tqclipboard()->setText(s);
}
// id's 10..16 (already checked)
@@ -864,13 +864,13 @@ namespace KileWidget
{
if ( info == 0L ) return false;
else
- return m_map.contains(info);
+ return m_map.tqcontains(info);
}
void Structure::closeDocumentInfo(KileDocument::Info *docinfo)
{
m_docinfo = 0L;
- if ( m_map.contains(docinfo) )
+ if ( m_map.tqcontains(docinfo) )
{
StructureList *data = m_map[docinfo];
m_map.remove(docinfo);
@@ -882,8 +882,8 @@ namespace KileWidget
void Structure::clear()
{
- QMapIterator<KileDocument::Info *, StructureList *> it;
- QMapIterator<KileDocument::Info *, StructureList *> itend(m_map.end());
+ TQMapIterator<KileDocument::Info *, StructureList *> it;
+ TQMapIterator<KileDocument::Info *, StructureList *> itend(m_map.end());
for ( it = m_map.begin(); it != itend; ++it)
if ( it.data() != 0L ) delete it.data();
@@ -974,7 +974,7 @@ namespace KileWidget
bool found = false;
uint foundRow,foundCol;
StructureList *structurelist = viewFor(docinfo);
- QListViewItemIterator it( structurelist );
+ TQListViewItemIterator it( structurelist );
while ( it.current() )
{
KileListViewItem *item = (KileListViewItem *)(it.current());
diff --git a/src/kile/kilestructurewidget.h b/src/kile/kilestructurewidget.h
index 6e596c3..dc8f53c 100644
--- a/src/kile/kilestructurewidget.h
+++ b/src/kile/kilestructurewidget.h
@@ -22,9 +22,9 @@
* @author Jeroen Wijnhout, Holger Danielsson
**/
-#include <qwidgetstack.h>
-#include <qvbox.h>
-#include <qtooltip.h>
+#include <tqwidgetstack.h>
+#include <tqvbox.h>
+#include <tqtooltip.h>
#include <klistview.h>
#include <kpopupmenu.h>
@@ -36,10 +36,10 @@
// - class KileListViewItem not only saves the cursor position of the parameter,
// but also the real cursor position of the command
-class QString;
+class TQString;
class KURL;
class KileInfo;
-class QListViewItem;
+class TQListViewItem;
/**
* ListView items that can hold some additional information appropriate for the Structure View. The
@@ -49,12 +49,12 @@ class QListViewItem;
class KileListViewItem : public KListViewItem
{
public:
- KileListViewItem(QListViewItem * parent, QListViewItem * after, const QString &title, const KURL &url, uint line, uint m_column, int type, int level, uint startline, uint startcol);
- KileListViewItem(QListView * parent, const QString & label);
- KileListViewItem(QListViewItem * parent, const QString & label);
+ KileListViewItem(TQListViewItem * tqparent, TQListViewItem * after, const TQString &title, const KURL &url, uint line, uint m_column, int type, int level, uint startline, uint startcol);
+ KileListViewItem(TQListView * tqparent, const TQString & label);
+ KileListViewItem(TQListViewItem * tqparent, const TQString & label);
/** @returns the title of this element (for a label it return the label), without the (line ...) part **/
- const QString& title() const { return m_title; }
+ const TQString& title() const { return m_title; }
/** @returns the line number of the structure element. **/
const uint line() const { return m_line; }
/** @returns the column number of the structure element, right after the { **/
@@ -68,30 +68,30 @@ public:
void setURL(const KURL & url) { m_url = url; }
const int level() const { return m_level; }
- const QString &label() const { return m_label; }
+ const TQString &label() const { return m_label; }
- void setTitle(const QString &title);
- void setLabel(const QString &label) { m_label = label; }
+ void setTitle(const TQString &title);
+ void setLabel(const TQString &label) { m_label = label; }
private:
- QString m_title;
+ TQString m_title;
KURL m_url;
uint m_line;
uint m_column;
int m_type, m_level;
uint m_startline;
uint m_startcol;
- QString m_label;
+ TQString m_label;
void setItemEntry();
};
-class KileListViewToolTip : public QToolTip
+class KileListViewToolTip : public TQToolTip
{
public:
KileListViewToolTip(KListView *listview);
protected:
- void maybeTip(const QPoint &p);
+ void maybeTip(const TQPoint &p);
private:
KListView *m_listview;
};
@@ -100,15 +100,15 @@ class KileReferenceData
{
public:
KileReferenceData() {}
- KileReferenceData(const QString &name,uint line,uint column) : m_name(name), m_line(line), m_column(column) {}
+ KileReferenceData(const TQString &name,uint line,uint column) : m_name(name), m_line(line), m_column(column) {}
~KileReferenceData() {}
- const QString &name() const { return m_name; }
+ const TQString &name() const { return m_name; }
const uint line() const { return m_line; }
const uint column() const { return m_column; }
private:
- QString m_name;
+ TQString m_name;
uint m_line;
uint m_column;
};
@@ -120,6 +120,7 @@ namespace KileWidget
class StructureList : public KListView
{
Q_OBJECT
+ TQ_OBJECT
public:
StructureList(Structure *stack, KileDocument::Info *docinfo);
@@ -133,29 +134,29 @@ namespace KileWidget
void updateRoot();
public slots:
- void addItem(const QString &title, uint line, uint column, int type, int level, uint startline, uint startcol,
- const QString & pix, const QString &folder = "root" );
+ void addItem(const TQString &title, uint line, uint column, int type, int level, uint startline, uint startcol,
+ const TQString & pix, const TQString &folder = "root" );
void slotConfigChanged();
private:
- KileListViewItem *parentFor(int lev, const QString & fldr);
+ KileListViewItem *tqparentFor(int lev, const TQString & fldr);
void init();
- KileListViewItem* createFolder(const QString &folder);
- KileListViewItem* folder(const QString &folder);
+ KileListViewItem* createFolder(const TQString &folder);
+ KileListViewItem* folder(const TQString &folder);
void saveState();
- bool shouldBeOpen(KileListViewItem *item, const QString & folder, int level);
+ bool shouldBeOpen(KileListViewItem *item, const TQString & folder, int level);
private:
Structure *m_stack;
KileDocument::Info *m_docinfo;
- QMap<QString, KileListViewItem *> m_folders;
- QMap<QString, bool> m_openByTitle;
- QMap<uint, bool> m_openByLine;
- QMap<QString, bool> m_openByFolders;
+ TQMap<TQString, KileListViewItem *> m_folders;
+ TQMap<TQString, bool> m_openByTitle;
+ TQMap<uint, bool> m_openByLine;
+ TQMap<TQString, bool> m_openByFolders;
KileListViewItem *m_parent[7], *m_root;
- QValueList<KileReferenceData> m_references;
+ TQValueList<KileReferenceData> m_references;
bool m_openStructureLabels;
bool m_openStructureReferences;
bool m_openStructureBibitems;
@@ -172,12 +173,13 @@ namespace KileWidget
bool m_stop;
};
- class Structure : public QWidgetStack
+ class Structure : public TQWidgetStack
{
Q_OBJECT
+ TQ_OBJECT
public:
- Structure(KileInfo *, QWidget * parent, const char * name = 0);
+ Structure(KileInfo *, TQWidget * tqparent, const char * name = 0);
~Structure();
int level();
@@ -194,9 +196,9 @@ namespace KileWidget
};
public slots:
- void slotClicked(QListViewItem *);
- void slotDoubleClicked(QListViewItem *);
- void slotPopup(KListView *, QListViewItem *itm, const QPoint &point);
+ void slotClicked(TQListViewItem *);
+ void slotDoubleClicked(TQListViewItem *);
+ void slotPopup(KListView *, TQListViewItem *itm, const TQPoint &point);
void slotPopupActivated(int id);
void addDocumentInfo(KileDocument::Info *);
@@ -207,14 +209,14 @@ namespace KileWidget
void updateReferences(KileDocument::Info *);
/**
- * Clears the structure widget and empties the map between KileDocument::Info objects and their structure trees (QListViewItem).
+ * Clears the structure widget and empties the map between KileDocument::Info objects and their structure trees (TQListViewItem).
**/
void clear();
signals:
- void sendText(const QString &);
+ void sendText(const TQString &);
void setCursor(const KURL &, int, int);
- void fileOpen(const KURL &, const QString &);
+ void fileOpen(const KURL &, const TQString &);
void fileNew(const KURL &);
void configChanged();
void sectioningPopup(KileListViewItem *item, int id);
@@ -230,12 +232,12 @@ namespace KileWidget
private:
KileInfo *m_ki;
KileDocument::Info *m_docinfo;
- QMap<KileDocument::Info *, StructureList *> m_map;
+ TQMap<KileDocument::Info *, StructureList *> m_map;
StructureList *m_default;
KPopupMenu *m_popup;
KileListViewItem *m_popupItem;
- QString m_popupInfo;
+ TQString m_popupInfo;
KTrader::OfferList m_offerList;
};
diff --git a/src/kile/kiletool.cpp b/src/kile/kiletool.cpp
index ab5faca..e7eb843 100644
--- a/src/kile/kiletool.cpp
+++ b/src/kile/kiletool.cpp
@@ -15,11 +15,11 @@
#include "kiletool.h"
-#include <qdir.h>
-#include <qfileinfo.h>
-#include <qmetaobject.h>
-#include <qregexp.h>
-#include <qtimer.h>
+#include <tqdir.h>
+#include <tqfileinfo.h>
+#include <tqmetaobject.h>
+#include <tqregexp.h>
+#include <tqtimer.h>
#include <klocale.h>
#include <kconfig.h>
@@ -37,19 +37,19 @@
namespace KileTool
{
- Base::Base(const QString &name, Manager * manager, bool prepare /* = true */) :
+ Base::Base(const TQString &name, Manager * manager, bool prepare /* = true */) :
m_manager(manager),
m_name(name),
- m_from(QString::null),
- m_to(QString::null),
- m_target(QString::null),
- m_basedir(QString::null),
- m_relativedir(QString::null),
- m_targetdir(QString::null),
- m_source(QString::null),
- m_S(QString::null),
- m_options(QString::null),
- m_resolution(QString::null),
+ m_from(TQString()),
+ m_to(TQString()),
+ m_target(TQString()),
+ m_basedir(TQString()),
+ m_relativedir(TQString()),
+ m_targetdir(TQString()),
+ m_source(TQString()),
+ m_S(TQString()),
+ m_options(TQString()),
+ m_resolution(TQString()),
m_launcher(0L),
m_quickie(false),
m_bPrepareToRun(prepare)
@@ -77,34 +77,34 @@ namespace KileTool
delete m_launcher;
}
- const QString Base::source(bool absolute /* = true */) const
+ const TQString Base::source(bool absolute /* = true */) const
{
if (m_source.isNull())
- return QString::null;
+ return TQString();
- QString src = m_source;
+ TQString src = m_source;
if (absolute)
src = m_basedir + '/' + src;
return src;
}
- void Base::setMsg(long n, const QString & msg)
+ void Base::setMsg(long n, const TQString & msg)
{
m_messages[n] = msg;
}
- void Base::translate(QString &str)
+ void Base::translate(TQString &str)
{
- QDictIterator<QString> it(*paramDict());
+ TQDictIterator<TQString> it(*paramDict());
for( it.toFirst() ; it.current(); ++it )
{
// KILE_DEBUG() << "translate " << str << " /// key=" << it.currentKey() << " value=" << *(it.current()) << endl;
- str.replace(it.currentKey(), *( it.current() ) );
+ str.tqreplace(it.currentKey(), *( it.current() ) );
}
}
- void Base::prepareToRun(const QString &cfg)
+ void Base::prepareToRun(const TQString &cfg)
{
KILE_DEBUG() << "==Base::prepareToRun()=======" << endl;
@@ -194,7 +194,7 @@ namespace KileTool
bool Base::determineSource()
{
- QString src = source();
+ TQString src = source();
//the basedir is determined from the current compile target
//determined by getCompileName()
@@ -211,7 +211,7 @@ namespace KileTool
//Is there an active document? Only check if the source file is not explicitly set.
if ( (m_source.isNull()) && (m_manager->info()->activeTextDocument() == 0L) )
{
- sendMessage(Error, msg(NeedActiveDoc).arg(name()));
+ sendMessage(Error, msg(NeedActiveDoc).tqarg(name()));
return false;
}
@@ -231,33 +231,33 @@ namespace KileTool
return false;
}
- QFileInfo fi(source());
+ TQFileInfo fi(source());
if ( (flags() & NeedSourceExists) && !fi.exists() )
{
- sendMessage(Error, msg(NeedSourceExists).arg(fi.absFilePath()));
+ sendMessage(Error, msg(NeedSourceExists).tqarg(fi.absFilePath()));
return false;
}
if ( (flags() & NeedSourceRead) && !fi.isReadable() )
{
- sendMessage(Error, msg(NeedSourceRead).arg(fi.absFilePath()));
+ sendMessage(Error, msg(NeedSourceRead).tqarg(fi.absFilePath()));
return false;
}
return true;
}
- void Base::setSource(const QString &source)
+ void Base::setSource(const TQString &source)
{
m_from = readEntry("from");
- QFileInfo info(source);
+ TQFileInfo info(source);
if (!m_from.isNull())
{
- QString src = source;
+ TQString src = source;
if ( (m_from.length() > 0) && (info.extension(false).length() > 0) )
- src.replace(QRegExp(info.extension(false) + '$'), m_from);
+ src.tqreplace(TQRegExp(info.extension(false) + '$'), m_from);
info.setFile(src);
}
@@ -278,7 +278,7 @@ namespace KileTool
bool Base::determineTarget()
{
- QFileInfo info(source());
+ TQFileInfo info(source());
m_to = readEntry("to");
@@ -320,17 +320,17 @@ namespace KileTool
bool Base::checkTarget()
{
//check if the target directory is accessible
- QFileInfo info(m_targetdir);
+ TQFileInfo info(m_targetdir);
if ( (flags() & NeedTargetDirExec ) && (! info.isExecutable()) )
{
- sendMessage(Error, msg(NeedTargetDirExec).arg(m_targetdir));
+ sendMessage(Error, msg(NeedTargetDirExec).tqarg(m_targetdir));
return false;
}
if ((flags() & NeedTargetDirWrite) && (! info.isWritable()) )
{
- sendMessage(Error, msg(NeedTargetDirWrite).arg(m_targetdir).arg(m_name));
+ sendMessage(Error, msg(NeedTargetDirWrite).tqarg(m_targetdir).tqarg(m_name));
return false;
}
@@ -338,34 +338,34 @@ namespace KileTool
if ( (flags() & NeedTargetExists) && ( ! info.exists() ))
{
- sendMessage(Error, msg(NeedTargetExists).arg(m_targetdir).arg(m_target));
+ sendMessage(Error, msg(NeedTargetExists).tqarg(m_targetdir).tqarg(m_target));
return false;
}
if ( (flags() & NeedTargetRead) && ( ! info.isReadable() ))
{
- sendMessage(Error, msg(NeedTargetRead).arg(m_targetdir).arg(m_target));
+ sendMessage(Error, msg(NeedTargetRead).tqarg(m_targetdir).tqarg(m_target));
return false;
}
return true;
}
- void Base::setTarget(const QString &target)
+ void Base::setTarget(const TQString &target)
{
m_target = target;
addDict("%target", m_target);
}
- void Base::setTargetDir(const QString &target)
+ void Base::setTargetDir(const TQString &target)
{
m_targetdir = target;
addDict("%dir_target", m_targetdir);
}
- void Base::setTargetPath(const QString &target)
+ void Base::setTargetPath(const TQString &target)
{
- QFileInfo fi(target);
+ TQFileInfo fi(target);
setTarget(fi.fileName());
setTargetDir(fi.dirPath(true));
}
@@ -375,7 +375,7 @@ namespace KileTool
return true;
}
- bool Base::configure(const QString &cfg)
+ bool Base::configure(const TQString &cfg)
{
return m_manager->configure(this, cfg);
}
@@ -391,9 +391,9 @@ namespace KileTool
bool Base::finish(int result)
{
KILE_DEBUG() << "==KileTool::Base::finish()==============" << endl;
- if (sender())
+ if (TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender())))
{
- KILE_DEBUG() << "\tcalled by " << sender()->name() << " " << sender()->className() << endl;
+ KILE_DEBUG() << "\tcalled by " << TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->name() << " " << TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->className() << endl;
}
if ( result == Aborted )
@@ -421,9 +421,9 @@ namespace KileTool
//lr->setParamDict(paramDict());
lr->setTool(this);
- connect(lr, SIGNAL(message(int, const QString &)), this, SLOT(sendMessage(int, const QString &)));
- connect(lr, SIGNAL(output(const QString &)), this, SLOT(filterOutput(const QString &)));
- connect(lr, SIGNAL(done(int)), this, SLOT(finish(int)));
+ connect(lr, TQT_SIGNAL(message(int, const TQString &)), this, TQT_SLOT(sendMessage(int, const TQString &)));
+ connect(lr, TQT_SIGNAL(output(const TQString &)), this, TQT_SLOT(filterOutput(const TQString &)));
+ connect(lr, TQT_SIGNAL(done(int)), this, TQT_SLOT(finish(int)));
}
bool Base::installLauncher()
@@ -431,7 +431,7 @@ namespace KileTool
if (m_launcher)
return true;
- QString type = readEntry("type");
+ TQString type = readEntry("type");
KILE_DEBUG() << "installing launcher of type " << type << endl;
Launcher *lr = 0;
@@ -464,12 +464,12 @@ namespace KileTool
}
}
- void Base::sendMessage(int type, const QString &msg)
+ void Base::sendMessage(int type, const TQString &msg)
{
emit(message(type, msg, name()));
}
- void Base::filterOutput(const QString & str)
+ void Base::filterOutput(const TQString & str)
{
//here you have the change to filter the output and do some error extraction for example
//this should be done by a OutputFilter class
@@ -480,19 +480,19 @@ namespace KileTool
emit(output(str));
}
- bool Base::addDict(const QString & key, const QString & value)
+ bool Base::addDict(const TQString & key, const TQString & value)
{
- bool e = (paramDict()->find(key) == 0);
- paramDict()->replace(key, &value);
+ bool e = (paramDict()->tqfind(key) == 0);
+ paramDict()->tqreplace(key, &value);
return e;
}
- bool Base::needsUpdate(const QString &target, const QString &source)
+ bool Base::needsUpdate(const TQString &target, const TQString &source)
{
KILE_DEBUG() << "==Base::needsUpdate(" << target << "," << source << endl;
- QFileInfo targetinfo(target);
- QFileInfo sourceinfo(source);
- QDateTime currDateTime = QDateTime::currentDateTime();
+ TQFileInfo targetinfo(target);
+ TQFileInfo sourceinfo(source);
+ TQDateTime currDateTime = TQDateTime::tqcurrentDateTime();
if ( !(sourceinfo.exists() && sourceinfo.isReadable()) )
{
@@ -524,7 +524,7 @@ namespace KileTool
return targetinfo.lastModified() < sourceinfo.lastModified();
}
- Compile::Compile(const QString &name, Manager * manager, bool prepare /*= true*/)
+ Compile::Compile(const TQString &name, Manager * manager, bool prepare /*= true*/)
: Base(name, manager, prepare)
{
setFlags( flags() | NeedTargetDirExec | NeedTargetDirWrite);
@@ -543,13 +543,13 @@ namespace KileTool
if (!isRoot)
{
- return manager()->queryContinue(i18n("The document %1 is not a LaTeX root document; continue anyway?").arg(source()), i18n("Continue?"));
+ return manager()->queryContinue(i18n("The document %1 is not a LaTeX root document; continue anyway?").tqarg(source()), i18n("Continue?"));
}
return true;
}
- View::View(const QString &name, Manager * manager, bool prepare /*= true*/)
+ View::View(const TQString &name, Manager * manager, bool prepare /*= true*/)
: Base(name, manager, prepare)
{
setFlags( NeedTargetDirExec | NeedTargetExists | NeedTargetRead);
@@ -563,7 +563,7 @@ namespace KileTool
}
- Archive::Archive(const QString &name, Manager * manager, bool prepare /* = true*/)
+ Archive::Archive(const TQString &name, Manager * manager, bool prepare /* = true*/)
: Base(name, manager,prepare)
{
setFlags( NeedTargetDirExec | NeedTargetDirWrite );
@@ -588,7 +588,7 @@ namespace KileTool
return true;
}
- void Archive::setSource(const QString &source)
+ void Archive::setSource(const TQString &source)
{
KURL url = KURL::fromPathOrURL(source);
m_project = manager()->info()->docManager()->projectFor(url);
@@ -611,7 +611,7 @@ namespace KileTool
KILE_DEBUG() << "m_fileList="<<m_fileList<<endl;
}
- Convert::Convert(const QString &name, Manager * manager, bool prepare /*= true*/)
+ Convert::Convert(const TQString &name, Manager * manager, bool prepare /*= true*/)
: Base(name, manager,prepare)
{
setFlags( flags() | NeedTargetDirExec | NeedTargetDirWrite );
@@ -628,7 +628,7 @@ namespace KileTool
return br;
}
- Sequence::Sequence(const QString &name, Manager * manager, bool prepare /*= true*/) :
+ Sequence::Sequence(const TQString &name, Manager * manager, bool prepare /*= true*/) :
Base(name, manager, prepare)
{
}
@@ -641,8 +641,8 @@ namespace KileTool
determineSource();
if (!checkSource()) return NoValidSource;
- QStringList tools = QStringList::split(',',readEntry("sequence"));
- QString tl, cfg;
+ TQStringList tools = TQStringList::split(',',readEntry("sequence"));
+ TQString tl, cfg;
Base *tool;
for (uint i=0; i < tools.count(); ++i)
{
@@ -662,7 +662,7 @@ namespace KileTool
}
else
{
- sendMessage(Error, i18n("Unknown tool %1.").arg(tools[i]));
+ sendMessage(Error, i18n("Unknown tool %1.").tqarg(tools[i]));
emit(done(this, Failed));
return ConfigureFailed;
}
diff --git a/src/kile/kiletool.h b/src/kile/kiletool.h
index 8f516c3..d4ff5a8 100644
--- a/src/kile/kiletool.h
+++ b/src/kile/kiletool.h
@@ -18,11 +18,11 @@
#include "kilelauncher.h"
-#include <qobject.h>
-#include <qmap.h>
-#include <qstring.h>
-#include <qdict.h>
-#include <qstringlist.h>
+#include <tqobject.h>
+#include <tqmap.h>
+#include <tqstring.h>
+#include <tqdict.h>
+#include <tqstringlist.h>
class KConfig;
class KileInfo;
@@ -31,7 +31,7 @@ class KileProject;
namespace KileTool
{
- typedef QMap<QString,QString> Config;
+ typedef TQMap<TQString,TQString> Config;
class Manager;
@@ -42,12 +42,13 @@ namespace KileTool
* @author Jeroen Wijnhout
**/
- class Base : public QObject
+ class Base : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- Base(const QString &name, Manager *manager, bool prepare = true);
+ Base(const TQString &name, Manager *manager, bool prepare = true);
~Base();
/**
@@ -68,28 +69,28 @@ namespace KileTool
/**
* @returns a short descriptive name for this tool.
**/
- const QString& name() const { return m_name; }
+ const TQString& name() const { return m_name; }
/**
* Allows you to set the source file explicitly (absolute path).
**/
- virtual void setSource(const QString & source);
+ virtual void setSource(const TQString & source);
/**
* @returns the source file that is used to run the tool on.
**/
- const QString source(bool absolute = true) const;
+ const TQString source(bool absolute = true) const;
- const QString S() const { return m_S; }
- const QString baseDir() const { return m_basedir; }
- const QString relativeDir() const { return m_relativedir; }
- const QString targetDir() const { return m_targetdir; }
- const QString from() const { return m_from; }
- const QString to() const { return m_to; }
- const QString target() const { return m_target; }
- const QString options() const { return m_options; }
+ const TQString S() const { return m_S; }
+ const TQString baseDir() const { return m_basedir; }
+ const TQString relativeDir() const { return m_relativedir; }
+ const TQString targetDir() const { return m_targetdir; }
+ const TQString from() const { return m_from; }
+ const TQString to() const { return m_to; }
+ const TQString target() const { return m_target; }
+ const TQString options() const { return m_options; }
- void setOptions(const QString &opt) { m_options = opt; }
+ void setOptions(const TQString &opt) { m_options = opt; }
virtual bool isViewer() { return false; }
@@ -99,14 +100,14 @@ namespace KileTool
/**
* Allows you to set the target file explicitly (filename only).
**/
- virtual void setTarget(const QString & target);
- virtual void setTargetDir(const QString & target);
- virtual void setTargetPath(const QString & target);
+ virtual void setTarget(const TQString & target);
+ virtual void setTargetDir(const TQString & target);
+ virtual void setTargetPath(const TQString & target);
/**
* Sets the target directory relative to the source directory.
**/
- void setRelativeBaseDir(const QString & dir) { m_relativedir = dir; }
+ void setRelativeBaseDir(const TQString & dir) { m_relativedir = dir; }
/**
* Installs a launcher object that will be responsible for actually starting the tool. The
@@ -128,7 +129,7 @@ namespace KileTool
/**
* @returns the working dir for this tool.
**/
- const QString &workingDir() const { return m_basedir; }
+ const TQString &workingDir() const { return m_basedir; }
/**
* @returns the dictionary that translates the following keys
@@ -137,28 +138,28 @@ namespace KileTool
* %source : the source file (no path)
* %S : the source filename without an extension (no path)
**/
- QDict<QString>* paramDict() { return &m_dictParams; }
+ TQDict<TQString>* paramDict() { return &m_dictParams; }
- bool addDict(const QString & key, const QString & value);
+ bool addDict(const TQString & key, const TQString & value);
- void translate(QString &str);
+ void translate(TQString &str);
void setFlags(uint flags) { m_flags = flags; }
uint flags() { return m_flags; }
- void setMsg(long n, const QString & msg);
- QString msg(long n) const { return m_messages[n]; }
+ void setMsg(long n, const TQString & msg);
+ TQString msg(long n) const { return m_messages[n]; }
protected:
- bool needsUpdate(const QString &target, const QString &source);
+ bool needsUpdate(const TQString &target, const TQString &source);
public slots:
- void sendMessage(int, const QString &);
- virtual void filterOutput(const QString &);
+ void sendMessage(int, const TQString &);
+ virtual void filterOutput(const TQString &);
signals:
- void message(int, const QString &, const QString &);
- void output(const QString &);
+ void message(int, const TQString &, const TQString &);
+ void output(const TQString &);
void start(Base*);
void done(Base*, int);
@@ -167,10 +168,10 @@ namespace KileTool
public:
void setEntryMap(Config map) { m_entryMap = map; }
- const QString readEntry(const QString & key) { return m_entryMap[key]; }
+ const TQString readEntry(const TQString & key) { return m_entryMap[key]; }
public:
- virtual void prepareToRun(const QString &cfg = QString::null);
+ virtual void prepareToRun(const TQString &cfg = TQString());
bool isPrepared() { return m_bPrepared; }
bool needsToBePrepared() { return m_bPrepareToRun; }
@@ -203,7 +204,7 @@ namespace KileTool
/**
* Configures the tool object.
**/
- virtual bool configure(const QString & cfg = QString::null);
+ virtual bool configure(const TQString & cfg = TQString());
public slots:
/**
@@ -229,11 +230,11 @@ namespace KileTool
KileInfo *m_ki;
KConfig *m_config;
- QString m_name, m_from, m_to;
- QString m_target, m_basedir, m_relativedir, m_targetdir, m_source, m_S, m_options;
- QString m_resolution;
+ TQString m_name, m_from, m_to;
+ TQString m_target, m_basedir, m_relativedir, m_targetdir, m_source, m_S, m_options;
+ TQString m_resolution;
- QString m_message;
+ TQString m_message;
bool m_buildPrereqs;
@@ -242,7 +243,7 @@ namespace KileTool
bool m_quickie;
private:
- QDict<QString> m_dictParams;
+ TQDict<TQString> m_dictParams;
Config m_entryMap;
uint m_flags;
@@ -251,7 +252,7 @@ namespace KileTool
bool m_bPrepareToRun;
//messages
- QMap<long,QString> m_messages;
+ TQMap<long,TQString> m_messages;
};
/**
@@ -260,7 +261,7 @@ namespace KileTool
class Compile : public Base
{
public:
- Compile(const QString &name, Manager * manager, bool prepare = true);
+ Compile(const TQString &name, Manager * manager, bool prepare = true);
~Compile();
protected:
@@ -273,7 +274,7 @@ namespace KileTool
class View : public Base
{
public:
- View(const QString &name, Manager * manager, bool prepare = true);
+ View(const TQString &name, Manager * manager, bool prepare = true);
~View();
bool isViewer() { return true; }
@@ -285,7 +286,7 @@ namespace KileTool
class Convert : public Base
{
public:
- Convert(const QString &name, Manager * manager, bool prepare = true);
+ Convert(const TQString &name, Manager * manager, bool prepare = true);
~Convert();
bool determineSource();
@@ -297,23 +298,25 @@ namespace KileTool
class Archive: public Base
{
Q_OBJECT
+ TQ_OBJECT
public:
- Archive(const QString &name, Manager * manager, bool prepare = true);
+ Archive(const TQString &name, Manager * manager, bool prepare = true);
~Archive();
bool checkPrereqs();
- void setSource(const QString & source);
+ void setSource(const TQString & source);
private:
KileProject *m_project;
- QString m_fileList;
+ TQString m_fileList;
};
class Sequence : public Base
{
Q_OBJECT
+ TQ_OBJECT
public:
- Sequence(const QString &name, Manager * manager, bool prepare = true);
+ Sequence(const TQString &name, Manager * manager, bool prepare = true);
public slots:
int run();
diff --git a/src/kile/kiletoolconfigwidget.cpp b/src/kile/kiletoolconfigwidget.cpp
index d4f43a1..46324f5 100644
--- a/src/kile/kiletoolconfigwidget.cpp
+++ b/src/kile/kiletoolconfigwidget.cpp
@@ -15,15 +15,15 @@
#include "kiletoolconfigwidget.h"
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qgroupbox.h>
-#include <qspinbox.h>
-#include <qvbox.h>
-#include <qregexp.h>
-#include <qtabwidget.h>
-#include <qwidgetstack.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqgroupbox.h>
+#include <tqspinbox.h>
+#include <tqvbox.h>
+#include <tqregexp.h>
+#include <tqtabwidget.h>
+#include <tqwidgetstack.h>
#include "kiledebug.h"
#include <klistbox.h>
@@ -49,12 +49,12 @@
namespace KileWidget
{
- ToolConfig::ToolConfig(KileTool::Manager *mngr, QWidget *parent, const char *name) :
- QWidget(parent, name),
+ ToolConfig::ToolConfig(KileTool::Manager *mngr, TQWidget *tqparent, const char *name) :
+ TQWidget(tqparent, name),
m_manager(mngr)
{
m_config = m_manager->config();
- m_layout = new QGridLayout(this, 1, 1, 0, 0);
+ m_layout = new TQGridLayout(this, 1, 1, 0, 0);
m_configWidget = new ToolConfigWidget(this);
m_layout->addWidget(m_configWidget, 0, 0);
@@ -65,23 +65,23 @@ namespace KileWidget
updateToollist();
// --->m_configWidget->m_lstbTools->setSelected(0, true);
m_configWidget->m_lstbTools->setSelected(indexQuickBuild(), true);
- connect(m_configWidget->m_cbConfig, SIGNAL(activated(int)), this, SLOT(switchConfig(int)));
+ connect(m_configWidget->m_cbConfig, TQT_SIGNAL(activated(int)), this, TQT_SLOT(switchConfig(int)));
- QStringList lst; lst << i18n( "Quick" ) << i18n( "Compile" ) << i18n( "Convert" ) << i18n( "View" ) << i18n( "Other" );
+ TQStringList lst; lst << i18n( "Quick" ) << i18n( "Compile" ) << i18n( "Convert" ) << i18n( "View" ) << i18n( "Other" );
m_configWidget->m_cbMenu->insertStringList(lst);
- connect(m_configWidget->m_cbMenu, SIGNAL(activated(const QString &)), this, SLOT(setMenu(const QString &)));
- connect(m_configWidget->m_pshbIcon, SIGNAL(clicked()), this, SLOT(selectIcon()));
+ connect(m_configWidget->m_cbMenu, TQT_SIGNAL(activated(const TQString &)), this, TQT_SLOT(setMenu(const TQString &)));
+ connect(m_configWidget->m_pshbIcon, TQT_SIGNAL(clicked()), this, TQT_SLOT(selectIcon()));
- connect(m_configWidget->m_pshbRemoveTool, SIGNAL(clicked()), this, SLOT(removeTool()));
- connect(m_configWidget->m_pshbNewTool, SIGNAL(clicked()), this, SLOT(newTool()));
- connect(m_configWidget->m_pshbRemoveConfig, SIGNAL(clicked()), this, SLOT(removeConfig()));
- connect(m_configWidget->m_pshbNewConfig, SIGNAL(clicked()), this, SLOT(newConfig()));
- connect(m_configWidget->m_pshbDefault, SIGNAL(clicked()), this, SLOT(writeDefaults()));
+ connect(m_configWidget->m_pshbRemoveTool, TQT_SIGNAL(clicked()), this, TQT_SLOT(removeTool()));
+ connect(m_configWidget->m_pshbNewTool, TQT_SIGNAL(clicked()), this, TQT_SLOT(newTool()));
+ connect(m_configWidget->m_pshbRemoveConfig, TQT_SIGNAL(clicked()), this, TQT_SLOT(removeConfig()));
+ connect(m_configWidget->m_pshbNewConfig, TQT_SIGNAL(clicked()), this, TQT_SLOT(newConfig()));
+ connect(m_configWidget->m_pshbDefault, TQT_SIGNAL(clicked()), this, TQT_SLOT(writeDefaults()));
//--->m_current = m_configWidget->m_lstbTools->text(0);
m_current = m_configWidget->m_lstbTools->currentText();
m_manager->retrieveEntryMap(m_current, m_map, false, false);
- QString cfg = KileTool::configName(m_current, m_config);
+ TQString cfg = KileTool::configName(m_current, m_config);
m_configWidget->m_cbConfig->insertItem(cfg);
setupGeneral();
@@ -89,10 +89,10 @@ namespace KileWidget
switchConfig(cfg);
switchTo(m_current, false);
- connect(m_configWidget->m_lstbTools, SIGNAL(highlighted(const QString &)), this, SLOT(switchTo(const QString &)));
+ connect(m_configWidget->m_lstbTools, TQT_SIGNAL(highlighted(const TQString &)), this, TQT_SLOT(switchTo(const TQString &)));
- connect(this, SIGNAL(changed()), this, SLOT(updateAdvanced()));
- connect(this, SIGNAL(changed()), this, SLOT(updateGeneral()));
+ connect(this, TQT_SIGNAL(changed()), this, TQT_SLOT(updateAdvanced()));
+ connect(this, TQT_SIGNAL(changed()), this, TQT_SLOT(updateGeneral()));
}
void ToolConfig::setupAdvanced()
@@ -102,28 +102,28 @@ namespace KileWidget
m_configWidget->m_cbType->insertItem(i18n("Run Embedded in Kile"));
m_configWidget->m_cbType->insertItem(i18n("Use HTML Viewer"));
m_configWidget->m_cbType->insertItem(i18n("Run Sequence of Tools"));
- connect(m_configWidget->m_cbType, SIGNAL(activated(int)), this, SLOT(switchType(int)));
- connect(m_configWidget->m_ckClose, SIGNAL(toggled(bool)), this, SLOT(setClose(bool)));
+ connect(m_configWidget->m_cbType, TQT_SIGNAL(activated(int)), this, TQT_SLOT(switchType(int)));
+ connect(m_configWidget->m_ckClose, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(setClose(bool)));
m_classes << "Compile" << "Convert" << "Archive" << "View" << "Sequence" << "LaTeX" << "ViewHTML" << "ViewBib" << "ForwardDVI" << "Base";
m_configWidget->m_cbClass->insertStringList(m_classes);
- connect(m_configWidget->m_cbClass, SIGNAL(activated(const QString &)), this, SLOT(switchClass(const QString &)));
+ connect(m_configWidget->m_cbClass, TQT_SIGNAL(activated(const TQString &)), this, TQT_SLOT(switchClass(const TQString &)));
- connect(m_configWidget->m_leSource, SIGNAL(textChanged(const QString &)), this, SLOT(setFrom(const QString &)));
- connect(m_configWidget->m_leTarget, SIGNAL(textChanged(const QString &)), this, SLOT(setTo(const QString &)));
- connect(m_configWidget->m_leFile, SIGNAL(textChanged(const QString &)), this, SLOT(setTarget(const QString &)));
- connect(m_configWidget->m_leRelDir, SIGNAL(textChanged(const QString &)), this, SLOT(setRelDir(const QString &)));
+ connect(m_configWidget->m_leSource, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setFrom(const TQString &)));
+ connect(m_configWidget->m_leTarget, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setTo(const TQString &)));
+ connect(m_configWidget->m_leFile, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setTarget(const TQString &)));
+ connect(m_configWidget->m_leRelDir, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setRelDir(const TQString &)));
m_configWidget->m_cbState->insertItem("Editor");
m_configWidget->m_cbState->insertItem("Viewer");
m_configWidget->m_cbState->insertItem("HTMLpreview");
- connect(m_configWidget->m_cbState, SIGNAL(activated(const QString &)), this, SLOT(setState(const QString &)));
+ connect(m_configWidget->m_cbState, TQT_SIGNAL(activated(const TQString &)), this, TQT_SLOT(setState(const TQString &)));
}
void ToolConfig::updateAdvanced()
{
bool enablekonsoleclose = false;
- QString type = m_map["type"];
+ TQString type = m_map["type"];
if ( type == "Process" ) m_configWidget->m_cbType->setCurrentItem(0);
else if ( type == "Konsole" )
{
@@ -135,11 +135,11 @@ namespace KileWidget
else if ( type == "Sequence" ) m_configWidget->m_cbType->setCurrentItem(4);
m_configWidget->m_ckClose->setEnabled(enablekonsoleclose);
- QString state = m_map["state"];
+ TQString state = m_map["state"];
if ( state.isEmpty() ) state = "Editor";
m_configWidget->m_cbState->setCurrentText(state);
- int index = m_classes.findIndex(m_map["class"]);
+ int index = m_classes.tqfindIndex(m_map["class"]);
if ( index == -1 ) index = m_classes.count()-1;
m_configWidget->m_cbClass->setCurrentItem(index);
m_configWidget->m_ckClose->setChecked(m_map["close"] == "yes");
@@ -151,41 +151,41 @@ namespace KileWidget
void ToolConfig::setupGeneral()
{
- m_configWidget->m_stackBasic->addWidget(new QLabel(i18n("Use the \"Advanced\" tab to configure this tool."), this), GBS_None);
+ m_configWidget->m_stackBasic->addWidget(new TQLabel(i18n("Use the \"Advanced\" tab to configure this tool."), this), GBS_None);
m_ptcw = new ProcessToolConfigWidget(m_configWidget->m_stackBasic);
m_configWidget->m_stackBasic->addWidget(m_ptcw, GBS_Process);
- connect(m_ptcw->m_leCommand, SIGNAL(textChanged(const QString &)), this, SLOT(setCommand(const QString &)));
- connect(m_ptcw->m_leOptions, SIGNAL(textChanged(const QString &)), this, SLOT(setOptions(const QString &)));
+ connect(m_ptcw->m_leCommand, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setCommand(const TQString &)));
+ connect(m_ptcw->m_leOptions, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setOptions(const TQString &)));
m_ltcw = new LibraryToolConfigWidget(m_configWidget->m_stackBasic);
m_configWidget->m_stackBasic->addWidget(m_ltcw, GBS_Library);
- connect(m_ltcw->m_leLibrary, SIGNAL(textChanged(const QString &)), this, SLOT(setLibrary(const QString &)));
- connect(m_ltcw->m_leLibClass, SIGNAL(textChanged(const QString &)), this, SLOT(setClassName(const QString &)));
- connect(m_ltcw->m_leOptions, SIGNAL(textChanged(const QString &)), this, SLOT(setLibOptions(const QString &)));
+ connect(m_ltcw->m_leLibrary, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setLibrary(const TQString &)));
+ connect(m_ltcw->m_leLibClass, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setClassName(const TQString &)));
+ connect(m_ltcw->m_leOptions, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(setLibOptions(const TQString &)));
m_qtcw = new QuickToolConfigWidget(m_configWidget->m_stackBasic);
m_configWidget->m_stackBasic->addWidget(m_qtcw, GBS_Sequence);
- connect(m_qtcw, SIGNAL(sequenceChanged(const QString &)), this, SLOT(setSequence(const QString &)));
+ connect(m_qtcw, TQT_SIGNAL(sequenceChanged(const TQString &)), this, TQT_SLOT(setSequence(const TQString &)));
- m_configWidget->m_stackBasic->addWidget(new QLabel(i18n("Unknown tool type; your configuration data is malformed.\nPerhaps it is a good idea to restore the default settings."), this), GBS_Error);
+ m_configWidget->m_stackBasic->addWidget(new TQLabel(i18n("Unknown tool type; your configuration data is malformed.\nPerhaps it is a good idea to restore the default settings."), this), GBS_Error);
- m_configWidget->m_stackExtra->addWidget(new QWidget(this), GES_None);
+ m_configWidget->m_stackExtra->addWidget(new TQWidget(this), GES_None);
m_LaTeXtcw = new LaTeXToolConfigWidget(m_configWidget->m_stackExtra);
m_configWidget->m_stackExtra->addWidget(m_LaTeXtcw, GES_LaTeX);
- connect(m_LaTeXtcw->m_ckRootDoc, SIGNAL(toggled(bool)), this, SLOT(setLaTeXCheckRoot(bool)));
- connect(m_LaTeXtcw->m_ckJump, SIGNAL(toggled(bool)), this, SLOT(setLaTeXJump(bool)));
- connect(m_LaTeXtcw->m_ckAutoRun, SIGNAL(toggled(bool)), this, SLOT(setLaTeXAuto(bool)));
+ connect(m_LaTeXtcw->m_ckRootDoc, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(setLaTeXCheckRoot(bool)));
+ connect(m_LaTeXtcw->m_ckJump, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(setLaTeXJump(bool)));
+ connect(m_LaTeXtcw->m_ckAutoRun, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(setLaTeXAuto(bool)));
// m_ViewBibtcw = new ViewBibToolConfigWidget(m_configWidget->m_stackExtra);
// m_configWidget->m_stackExtra->addWidget(m_ViewBibtcw, GES_ViewBib);
-// connect(m_ViewBibtcw->m_ckRunLyxServer, SIGNAL(toggled(bool)), this, SLOT(setRunLyxServer(bool)));
+// connect(m_ViewBibtcw->m_ckRunLyxServer, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(setRunLyxServer(bool)));
}
void ToolConfig::updateGeneral()
{
- QString type = m_map["type"];
+ TQString type = m_map["type"];
int basicPage = GBS_None;
int extraPage = GES_None;
@@ -200,7 +200,7 @@ namespace KileWidget
}
else basicPage = GBS_Error;
- QString cls = m_map["class"];
+ TQString cls = m_map["class"];
if ( cls == "LaTeX" )
extraPage = GES_LaTeX;
// else if ( cls == "ViewBib" )
@@ -226,25 +226,25 @@ namespace KileWidget
if ( m_configWidget->m_stackBasic->widget(basicPage) )
{
- QSize szHint = m_configWidget->m_stackBasic->widget(basicPage)->sizeHint();
+ TQSize szHint = m_configWidget->m_stackBasic->widget(basicPage)->tqsizeHint();
if (szHint.height() > 0)
m_configWidget->m_stackBasic->setMaximumHeight(szHint.height());
}
if ( m_configWidget->m_stackExtra->widget(extraPage) )
{
- QSize szHint = m_configWidget->m_stackExtra->widget(extraPage)->sizeHint();
+ TQSize szHint = m_configWidget->m_stackExtra->widget(extraPage)->tqsizeHint();
if (szHint.height() > 0)
m_configWidget->m_stackExtra->setMaximumHeight(szHint.height());
}
- m_configWidget->layout()->invalidate();
+ m_configWidget->tqlayout()->tqinvalidate();
}
void ToolConfig::writeDefaults()
{
if ( KMessageBox::warningContinueCancel(this, i18n("All your tool settings will be overwritten with the default settings, are you sure you want to continue?")) == KMessageBox::Continue )
{
- QStringList groups = m_config->groupList();
- QRegExp re = QRegExp("Tool/(.+)/.+");
+ TQStringList groups = m_config->groupList();
+ TQRegExp re = TQRegExp("Tool/(.+)/.+");
for ( uint i = 0; i < groups.count(); ++i )
if ( re.exactMatch(groups[i]) )
m_config->deleteGroup(groups[i],true);
@@ -252,7 +252,7 @@ namespace KileWidget
m_manager->factory()->writeStdConfig();
m_config->sync();
updateToollist();
- QStringList tools = KileTool::toolList(m_config, true);
+ TQStringList tools = KileTool::toolList(m_config, true);
for ( uint i = 0; i < tools.count(); ++i){
switchTo(tools[i], false);// needed to retrieve the new map
switchTo(tools[i],true); // this writes the newly retrieved entry map (and not an perhaps changed old one)
@@ -271,9 +271,9 @@ namespace KileWidget
m_configWidget->m_lstbTools->sort();
}
- void ToolConfig::setMenu(const QString & menu)
+ void ToolConfig::setMenu(const TQString & menu)
{
- //KILE_DEBUG() << "==ToolConfig::setMenu(const QString & menu)====================" << endl;
+ //KILE_DEBUG() << "==ToolConfig::setMenu(const TQString & menu)====================" << endl;
m_map["menu"] = menu;
}
@@ -287,7 +287,7 @@ namespace KileWidget
int ToolConfig::indexQuickBuild()
{
- int index = m_configWidget->m_lstbTools->index( m_configWidget->m_lstbTools->findItem("QuickBuild",Qt::ExactMatch) );
+ int index = m_configWidget->m_lstbTools->index( m_configWidget->m_lstbTools->tqfindItem("QuickBuild",TQt::ExactMatch) );
return ( index >= 0 ) ? index : 0;
}
@@ -298,9 +298,9 @@ namespace KileWidget
switchTo(m_current);
}
- void ToolConfig::switchConfig(const QString & cfg)
+ void ToolConfig::switchConfig(const TQString & cfg)
{
- //KILE_DEBUG() << "==ToolConfig::switchConfig(const QString & cfg)==========" << endl;
+ //KILE_DEBUG() << "==ToolConfig::switchConfig(const TQString & cfg)==========" << endl;
for ( int i = 0; i < m_configWidget->m_cbConfig->count(); ++i)
{
if ( m_configWidget->m_cbConfig->text(i) == cfg )
@@ -308,16 +308,16 @@ namespace KileWidget
}
}
- void ToolConfig::switchTo(const QString & tool, bool save /* = true */)
+ void ToolConfig::switchTo(const TQString & tool, bool save /* = true */)
{
- //KILE_DEBUG() << "==ToolConfig::switchTo(const QString & tool, bool save /* = true */)====================" << endl;
+ //KILE_DEBUG() << "==ToolConfig::switchTo(const TQString & tool, bool save /* = true */)====================" << endl;
//save config
if (save)
{
writeConfig();
//update the config number
- QString cf = m_configWidget->m_cbConfig->currentText();
+ TQString cf = m_configWidget->m_cbConfig->currentText();
KileTool::setConfigName(m_current, cf, m_config);
}
@@ -335,7 +335,7 @@ namespace KileWidget
m_configWidget->m_cbMenu->setCurrentText(KileTool::menuFor(m_current, m_config));
m_icon=KileTool::iconFor(m_current, m_config);
if ( m_icon.isEmpty() )
- m_configWidget->m_pshbIcon->setPixmap(QString::null);
+ m_configWidget->m_pshbIcon->setPixmap(TQString());
else
m_configWidget->m_pshbIcon->setPixmap(SmallIcon(m_icon));
}
@@ -345,7 +345,7 @@ namespace KileWidget
//KILE_DEBUG() << "==ToolConfig::updateConfiglist()=====================" << endl;
m_configWidget->m_cbConfig->clear();
m_configWidget->m_cbConfig->insertStringList(KileTool::configNames(m_current, m_config));
- QString cfg = KileTool::configName(m_current, m_config);
+ TQString cfg = KileTool::configName(m_current, m_config);
switchConfig(cfg);
m_configWidget->m_cbConfig->setEnabled(m_configWidget->m_cbConfig->count() > 1);
}
@@ -355,14 +355,14 @@ namespace KileWidget
KILE_DEBUG() << "icon ---> " << m_icon << endl;
//KILE_DEBUG() << "==ToolConfig::selectIcon()=====================" << endl;
KIconDialog *dlg = new KIconDialog(this);
- QString res = dlg->openDialog();
+ TQString res = dlg->openDialog();
if ( m_icon != res ) {
if ( res.isEmpty() ) return;
m_icon = res;
writeConfig();
if ( m_icon.isEmpty() )
- m_configWidget->m_pshbIcon->setPixmap(QString::null);
+ m_configWidget->m_pshbIcon->setPixmap(TQString());
else
m_configWidget->m_pshbIcon->setPixmap(SmallIcon(m_icon));
}
@@ -374,15 +374,15 @@ namespace KileWidget
NewToolWizard *ntw = new NewToolWizard(this);
if (ntw->exec())
{
- QString toolName = ntw->toolName();
- QString parentTool = ntw->parentTool();
+ TQString toolName = ntw->toolName();
+ TQString tqparentTool = ntw->tqparentTool();
writeStdConfig(toolName, "Default");
- if ( parentTool != ntw->customTool() )
+ if ( tqparentTool != ntw->customTool() )
{
//copy tool info
KileTool::Config tempMap;
- m_manager->retrieveEntryMap(parentTool, tempMap, false, false);
+ m_manager->retrieveEntryMap(tqparentTool, tempMap, false, false);
m_config->setGroup(KileTool::groupFor(toolName, "Default"));
m_config->writeEntry("class", tempMap["class"]);
m_config->writeEntry("type", tempMap["type"]);
@@ -411,12 +411,12 @@ namespace KileWidget
//KILE_DEBUG() << "==ToolConfig::newConfig()=====================" << endl;
writeConfig();
bool ok;
- QString cfg = KInputDialog::getText(i18n("New Configuration"), i18n("Enter new configuration name:"), "", &ok, this);
+ TQString cfg = KInputDialog::getText(i18n("New Configuration"), i18n("Enter new configuration name:"), "", &ok, this);
if (ok && (!cfg.isEmpty()))
{
//copy config
m_config->setGroup(KileTool::groupFor(m_current, cfg));
- for (QMap<QString,QString>::Iterator it = m_map.begin(); it != m_map.end(); ++it)
+ for (TQMap<TQString,TQString>::Iterator it = m_map.begin(); it != m_map.end(); ++it)
{
m_config->writeEntry(it.key(), it.data());
}
@@ -426,7 +426,7 @@ namespace KileWidget
}
}
- void ToolConfig::writeStdConfig(const QString & tool, const QString & cfg)
+ void ToolConfig::writeStdConfig(const TQString & tool, const TQString & cfg)
{
m_config->setGroup(KileTool::groupFor(tool, cfg));
m_config->writeEntry("class", "Compile");
@@ -442,10 +442,10 @@ namespace KileWidget
void ToolConfig::removeTool()
{
//KILE_DEBUG() << "==ToolConfig::removeTool()=====================" << endl;
- if ( KMessageBox::warningContinueCancel(this, i18n("Are you sure you want to remove the tool %1?").arg(m_current)) == KMessageBox::Continue )
+ if ( KMessageBox::warningContinueCancel(this, i18n("Are you sure you want to remove the tool %1?").tqarg(m_current)) == KMessageBox::Continue )
{
KConfig *config = m_config;
- QStringList cfgs = KileTool::configNames(m_current, config);
+ TQStringList cfgs = KileTool::configNames(m_current, config);
for ( uint i = 0; i < cfgs.count(); ++i)
{
config->deleteGroup(KileTool::groupFor(m_current, cfgs[i]));
@@ -454,7 +454,7 @@ namespace KileWidget
config->deleteEntry(m_current);
int index = m_configWidget->m_lstbTools->currentItem()-1;
if ( index < 0 ) index=0;
- QString tool = m_configWidget->m_lstbTools->text(index);
+ TQString tool = m_configWidget->m_lstbTools->text(index);
m_configWidget->m_lstbTools->blockSignals(true);
updateToollist();
m_configWidget->m_lstbTools->setCurrentItem(index);
@@ -481,7 +481,7 @@ namespace KileWidget
KMessageBox::error(this, i18n("You need at least one configuration for each tool."), i18n("Cannot Remove Configuration"));
}
- void ToolConfig::switchClass(const QString & cls)
+ void ToolConfig::switchClass(const TQString & cls)
{
if ( m_map["class"] != cls )
{
@@ -504,21 +504,21 @@ namespace KileWidget
emit(changed());
}
- void ToolConfig::setCommand(const QString & command) { m_map["command"] = command.stripWhiteSpace(); }
- void ToolConfig::setOptions(const QString & options) { m_map["options"] = options.stripWhiteSpace(); }
- void ToolConfig::setLibrary(const QString & lib) { m_map["libName"] = lib.stripWhiteSpace(); }
- void ToolConfig::setLibOptions(const QString & options) { m_map["libOptions"] = options.stripWhiteSpace(); }
- void ToolConfig::setClassName(const QString & name) { m_map["className"] = name.stripWhiteSpace(); }
- void ToolConfig::setState(const QString & state)
+ void ToolConfig::setCommand(const TQString & command) { m_map["command"] = command.stripWhiteSpace(); }
+ void ToolConfig::setOptions(const TQString & options) { m_map["options"] = options.stripWhiteSpace(); }
+ void ToolConfig::setLibrary(const TQString & lib) { m_map["libName"] = lib.stripWhiteSpace(); }
+ void ToolConfig::setLibOptions(const TQString & options) { m_map["libOptions"] = options.stripWhiteSpace(); }
+ void ToolConfig::setClassName(const TQString & name) { m_map["className"] = name.stripWhiteSpace(); }
+ void ToolConfig::setState(const TQString & state)
{
- QString str = state.stripWhiteSpace();
+ TQString str = state.stripWhiteSpace();
if ( str .isEmpty() ) str = "Editor";
m_map["state"] = str;
}
- void ToolConfig::setSequence(const QString & sequence) { m_map["sequence"] = sequence.stripWhiteSpace(); }
+ void ToolConfig::setSequence(const TQString & sequence) { m_map["sequence"] = sequence.stripWhiteSpace(); }
void ToolConfig::setClose(bool on) { m_map["close"] = on ? "yes" : "no"; }
- void ToolConfig::setTarget(const QString & trg) { m_map["target"] = trg.stripWhiteSpace(); }
- void ToolConfig::setRelDir(const QString & rd) { m_map["relDir"] = rd.stripWhiteSpace(); }
+ void ToolConfig::setTarget(const TQString & trg) { m_map["target"] = trg.stripWhiteSpace(); }
+ void ToolConfig::setRelDir(const TQString & rd) { m_map["relDir"] = rd.stripWhiteSpace(); }
void ToolConfig::setLaTeXCheckRoot(bool ck) { m_map["checkForRoot"] = ck ? "yes" : "no"; }
void ToolConfig::setLaTeXJump(bool ck) { m_map["jumpToFirstError"] = ck ? "yes" : "no"; }
void ToolConfig::setLaTeXAuto(bool ck) { m_map["autoRun"] = ck ? "yes" : "no"; }
@@ -528,9 +528,9 @@ namespace KileWidget
m_config->setGroup("Tools");
m_config->writeEntry("RunLyxServer", ck);
}
- void ToolConfig::setFrom(const QString & from) { m_map["from"] = from.stripWhiteSpace(); }
- void ToolConfig::setTo(const QString & to) { m_map["to"] = to.stripWhiteSpace(); }
- void ToolConfig::setClass(const QString & cls) { m_map["class"] = cls.stripWhiteSpace(); }
+ void ToolConfig::setFrom(const TQString & from) { m_map["from"] = from.stripWhiteSpace(); }
+ void ToolConfig::setTo(const TQString & to) { m_map["to"] = to.stripWhiteSpace(); }
+ void ToolConfig::setClass(const TQString & cls) { m_map["class"] = cls.stripWhiteSpace(); }
}
#include "kiletoolconfigwidget.moc"
diff --git a/src/kile/kiletoolconfigwidget.h b/src/kile/kiletoolconfigwidget.h
index c4fb339..b2fa0c7 100644
--- a/src/kile/kiletoolconfigwidget.h
+++ b/src/kile/kiletoolconfigwidget.h
@@ -16,13 +16,13 @@
#ifndef KILETOOLCONFIGWIDGET_H
#define KILETOOLCONFIGWIDGET_H
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include <keditlistbox.h>
#include "kiletool.h"
-class QGridLayout;
+class TQGridLayout;
namespace KileTool { class Manager; }
class ToolConfigWidget;
@@ -34,15 +34,16 @@ class ViewBibToolConfigWidget;
namespace KileWidget
{
- class ToolConfig : public QWidget
+ class ToolConfig : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
enum GeneralBasicStack { GBS_None = 1, GBS_Process, GBS_Library, GBS_DocPart, GBS_Sequence, GBS_Error };
enum GeneralExtraStack { GES_None = 1, GES_LaTeX/*, GES_ViewBib*/ };
public:
- ToolConfig(KileTool::Manager *mngr, QWidget *parent, const char * name = 0);
+ ToolConfig(KileTool::Manager *mngr, TQWidget *tqparent, const char * name = 0);
public slots:
void writeConfig();
@@ -55,39 +56,39 @@ namespace KileWidget
private slots:
void updateGeneral();
void updateAdvanced();
- void switchTo(const QString & tool, bool save = true);
+ void switchTo(const TQString & tool, bool save = true);
void updateToollist();
void updateConfiglist();
void selectIcon();
- void setMenu(const QString &);
+ void setMenu(const TQString &);
void switchConfig(int index = -1);
- void switchConfig(const QString &);
+ void switchConfig(const TQString &);
void newTool();
void newConfig();
void removeTool();
void removeConfig();
- void writeStdConfig(const QString &, const QString &);
+ void writeStdConfig(const TQString &, const TQString &);
void writeDefaults();
- void setCommand(const QString &);
- void setOptions(const QString &);
- void setLibrary(const QString &);
- void setLibOptions(const QString &);
- void setClassName(const QString &);
- void setState(const QString &);
- void setSequence(const QString &);
+ void setCommand(const TQString &);
+ void setOptions(const TQString &);
+ void setLibrary(const TQString &);
+ void setLibOptions(const TQString &);
+ void setClassName(const TQString &);
+ void setState(const TQString &);
+ void setSequence(const TQString &);
void setClose(bool);
- void setTarget(const QString &);
- void setRelDir(const QString &);
+ void setTarget(const TQString &);
+ void setRelDir(const TQString &);
void setLaTeXCheckRoot(bool);
void setLaTeXJump(bool);
void setLaTeXAuto(bool);
void setRunLyxServer(bool);
- void setFrom(const QString &);
- void setTo(const QString &);
- void setClass(const QString &);
- void switchClass(const QString &);
+ void setFrom(const TQString &);
+ void setTo(const TQString &);
+ void setClass(const TQString &);
+ void switchClass(const TQString &);
void switchType(int);
signals:
@@ -98,10 +99,10 @@ namespace KileWidget
KileTool::Manager *m_manager;
KConfig *m_config;
KileTool::Config m_map;
- QGridLayout *m_layout;
- QString m_current, m_icon;
- QStringList m_classes;
- QWidget *m_tabGeneral, *m_tabAdvanced, *m_tabMenu;
+ TQGridLayout *m_layout;
+ TQString m_current, m_icon;
+ TQStringList m_classes;
+ TQWidget *m_tabGeneral, *m_tabAdvanced, *m_tabMenu;
ProcessToolConfigWidget *m_ptcw;
LibraryToolConfigWidget *m_ltcw;
QuickToolConfigWidget *m_qtcw;
diff --git a/src/kile/kiletoolmanager.cpp b/src/kile/kiletoolmanager.cpp
index f7fe631..089c06b 100644
--- a/src/kile/kiletoolmanager.cpp
+++ b/src/kile/kiletoolmanager.cpp
@@ -17,12 +17,12 @@
#include <stdlib.h> //for getenv()
-#include <qstring.h>
-#include <qfileinfo.h>
-#include <qwidgetstack.h>
-#include <qtimer.h>
-#include <qregexp.h>
-#include <qthread.h>
+#include <tqstring.h>
+#include <tqfileinfo.h>
+#include <tqwidgetstack.h>
+#include <tqtimer.h>
+#include <tqregexp.h>
+#include <tqthread.h>
#include <kaction.h>
#include <ktextedit.h>
@@ -46,7 +46,7 @@
namespace KileTool
{
- QueueItem::QueueItem(Base *tool, const QString & cfg, bool block) : m_tool(tool), m_cfg(cfg), m_bBlock(block)
+ QueueItem::QueueItem(Base *tool, const TQString & cfg, bool block) : m_tool(tool), m_cfg(cfg), m_bBlock(block)
{
}
@@ -63,12 +63,12 @@ namespace KileTool
return 0;
}
- const QString Queue::cfg() const
+ const TQString Queue::cfg() const
{
if ( head() )
return head()->cfg();
else
- return QString::null;
+ return TQString();
}
bool Queue::shouldBlock() const
@@ -101,7 +101,7 @@ namespace KileTool
}
}
- Manager::Manager(KileInfo *ki, KConfig *config, KileWidget::LogMsg *log, KileWidget::Output *output, KParts::PartManager *manager, QWidgetStack *stack, KAction *stop, uint to) :
+ Manager::Manager(KileInfo *ki, KConfig *config, KileWidget::LogMsg *log, KileWidget::Output *output, KParts::PartManager *manager, TQWidgetStack *stack, KAction *stop, uint to) :
m_ki(ki),
m_config(config),
m_log(log),
@@ -113,9 +113,9 @@ namespace KileTool
m_nLastResult(Success),
m_nTimeout(to)
{
- m_timer = new QTimer(this);
- connect(m_timer, SIGNAL(timeout()), this, SLOT(enableClear()));
- connect(stop, SIGNAL(activated()), this, SLOT(stop()));
+ m_timer = new TQTimer(this);
+ connect(m_timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(enableClear()));
+ connect(stop, TQT_SIGNAL(activated()), this, TQT_SLOT(stop()));
}
Manager::~Manager() {}
@@ -130,12 +130,12 @@ namespace KileTool
m_bClear = true;
}
- bool Manager::queryContinue(const QString & question, const QString & caption /*= QString::null*/)
+ bool Manager::queryContinue(const TQString & question, const TQString & caption /*= TQString()*/)
{
return (KMessageBox::warningContinueCancel(m_stack, question, caption, KStdGuiItem::cont(), "showNotALaTeXRootDocumentWarning") == KMessageBox::Continue);
}
- int Manager::run(const QString &tool, const QString & cfg, bool insertNext /*= false*/, bool block /*= false*/)
+ int Manager::run(const TQString &tool, const TQString & cfg, bool insertNext /*= false*/, bool block /*= false*/)
{
if (!m_factory)
{
@@ -146,14 +146,14 @@ namespace KileTool
Base* pTool = m_factory->create(tool);
if (!pTool)
{
- m_log->printMsg(Error, i18n("Unknown tool %1.").arg(tool));
+ m_log->printMsg(Error, i18n("Unknown tool %1.").tqarg(tool));
return ConfigureFailed;
}
return run(pTool, cfg, insertNext, block);
}
- int Manager::run(Base *tool, const QString & cfg, bool insertNext /*= false*/, bool block /*= false*/)
+ int Manager::run(Base *tool, const TQString & cfg, bool insertNext /*= false*/, bool block /*= false*/)
{
KILE_DEBUG() << "==KileTool::Manager::run(Base *)============" << endl;
if (m_bClear && (m_queue.count() == 0) )
@@ -187,17 +187,17 @@ namespace KileTool
return ConfigureFailed;
}
- int Manager::runNext(const QString &tool , const QString &config, bool block /*= false*/)
+ int Manager::runNext(const TQString &tool , const TQString &config, bool block /*= false*/)
{
return run(tool, config, true, block);
}
- int Manager::runNext(Base *tool, const QString &config, bool block /*= false*/)
+ int Manager::runNext(Base *tool, const TQString &config, bool block /*= false*/)
{
return run(tool, config, true, block);
}
- int Manager::runBlocking(const QString &tool, const QString &config /*= QString::null*/, bool insertAtTop /*= false*/)
+ int Manager::runBlocking(const TQString &tool, const TQString &config /*= TQString()*/, bool insertAtTop /*= false*/)
{
if ( run(tool, config, insertAtTop, true) == Running )
return lastResult();
@@ -205,7 +205,7 @@ namespace KileTool
return Failed;
}
- int Manager::runNextBlocking(const QString &tool, const QString &config)
+ int Manager::runNextBlocking(const TQString &tool, const TQString &config)
{
return runBlocking(tool, config, true);
}
@@ -242,11 +242,11 @@ namespace KileTool
tool->setInfo(m_ki);
tool->setConfig(m_config);
- connect(tool, SIGNAL(message(int, const QString &, const QString &)), m_log, SLOT(printMsg(int, const QString &, const QString &)));
- connect(tool, SIGNAL(output(const QString &)), m_output, SLOT(receive(const QString &)));
- connect(tool, SIGNAL(done(Base*,int)), this, SLOT(done(Base*, int)));
- connect(tool, SIGNAL(start(Base* )), this, SLOT(started(Base*)));
- connect(tool, SIGNAL(requestSaveAll(bool, bool)), this, SIGNAL(requestSaveAll(bool, bool)));
+ connect(tool, TQT_SIGNAL(message(int, const TQString &, const TQString &)), m_log, TQT_SLOT(printMsg(int, const TQString &, const TQString &)));
+ connect(tool, TQT_SIGNAL(output(const TQString &)), m_output, TQT_SLOT(receive(const TQString &)));
+ connect(tool, TQT_SIGNAL(done(Base*,int)), this, TQT_SLOT(done(Base*, int)));
+ connect(tool, TQT_SIGNAL(start(Base* )), this, TQT_SLOT(started(Base*)));
+ connect(tool, TQT_SIGNAL(requestSaveAll(bool, bool)), this, TQT_SIGNAL(requestSaveAll(bool, bool)));
}
void Manager::started(Base *tool)
@@ -258,7 +258,7 @@ namespace KileTool
{
if ( tool == m_queue.tool() ) m_queue.dequeue();
m_stop->setEnabled(false);
- QTimer::singleShot(100, this, SLOT(runNextInQueue()));
+ TQTimer::singleShot(100, this, TQT_SLOT(runNextInQueue()));
}
}
@@ -294,14 +294,14 @@ namespace KileTool
runNextInQueue();
}
- QString Manager::currentGroup(const QString &name, bool usequeue, bool useproject)
+ TQString Manager::currentGroup(const TQString &name, bool usequeue, bool useproject)
{
if (useproject)
{
KileProject *project = m_ki->docManager()->activeProject();
if (project)
{
- QString cfg = configName(name, dynamic_cast<KConfig*>(project->config()));
+ TQString cfg = configName(name, dynamic_cast<KConfig*>(project->config()));
if ( cfg.length() > 0 ) return groupFor(name, cfg);
}
}
@@ -312,9 +312,9 @@ namespace KileTool
return groupFor(name, m_config);
}
- bool Manager::retrieveEntryMap(const QString & name, Config & map, bool usequeue, bool useproject, const QString & cfg /*= QString::null*/)
+ bool Manager::retrieveEntryMap(const TQString & name, Config & map, bool usequeue, bool useproject, const TQString & cfg /*= TQString()*/)
{
- QString group = (cfg == QString::null )
+ TQString group = (cfg == TQString() )
? currentGroup(name, usequeue, useproject) : groupFor(name, cfg);
KILE_DEBUG() << "==KileTool::Manager::retrieveEntryMap=============" << endl;
@@ -330,7 +330,7 @@ namespace KileTool
KConfig *prjcfg = dynamic_cast<KConfig*>(project->config());
if ( prjcfg )
{
- QString grp = groupFor(name, prjcfg);
+ TQString grp = groupFor(name, prjcfg);
Config prjmap = prjcfg->entryMap(grp);
for (Config::Iterator it = prjmap.begin(); it != prjmap.end(); ++it)
{
@@ -345,10 +345,10 @@ namespace KileTool
return true;
}
- void Manager::saveEntryMap(const QString & name, Config & map, bool usequeue, bool useproject)
+ void Manager::saveEntryMap(const TQString & name, Config & map, bool usequeue, bool useproject)
{
KILE_DEBUG() << "==KileTool::Manager::saveEntryMap=============" << endl;
- QString group = currentGroup(name, usequeue, useproject);
+ TQString group = currentGroup(name, usequeue, useproject);
KILE_DEBUG() << "\t" << name << " => " << group << endl;
m_config->setGroup(group);
@@ -360,7 +360,7 @@ namespace KileTool
}
}
- bool Manager::configure(Base *tool, const QString & cfg /*=QString::null*/)
+ bool Manager::configure(Base *tool, const TQString & cfg /*=TQString()*/)
{
KILE_DEBUG() << "==KileTool::Manager::configure()===============" << endl;
//configure the tool
@@ -369,7 +369,7 @@ namespace KileTool
if ( ! retrieveEntryMap(tool->name(), map, true, true, cfg) )
{
- m_log->printMsg(Error, i18n("Cannot find the tool %1 in the configuration database.").arg(tool->name()));
+ m_log->printMsg(Error, i18n("Cannot find the tool %1 in the configuration database.").tqarg(tool->name()));
return false;
}
@@ -378,18 +378,18 @@ namespace KileTool
return true;
}
- void Manager::wantGUIState(const QString & state)
+ void Manager::wantGUIState(const TQString & state)
{
KILE_DEBUG() << "REQUESTED state: " << state << endl;
emit(requestGUIState(state));
}
- QStringList toolList(KConfig *config, bool menuOnly)
+ TQStringList toolList(KConfig *config, bool menuOnly)
{
KILE_DEBUG() << "==KileTool::toolList()==================" << endl;
- QStringList groups = config->groupList(), tools;
- QRegExp re = QRegExp("Tool/(.+)/.+");
+ TQStringList groups = config->groupList(), tools;
+ TQRegExp re = TQRegExp("Tool/(.+)/.+");
for ( uint i = 0; i < groups.count(); ++i )
{
@@ -409,35 +409,35 @@ namespace KileTool
return tools;
}
- QString configName(const QString & tool, KConfig *config)
+ TQString configName(const TQString & tool, KConfig *config)
{
config->setGroup("Tools");
return config->readEntry(tool, "");
}
- void setConfigName(const QString & tool, const QString & name, KConfig *config)
+ void setConfigName(const TQString & tool, const TQString & name, KConfig *config)
{
KILE_DEBUG() << "==KileTool::Manager::setConfigName(" << tool << "," << name << ")===============" << endl;
config->setGroup("Tools");
config->writeEntry(tool, name);
}
- QString groupFor(const QString &tool, KConfig *config)
+ TQString groupFor(const TQString &tool, KConfig *config)
{
return groupFor(tool, configName(tool, config));
}
- QString groupFor(const QString & tool, const QString & cfg /* = Default */ )
+ TQString groupFor(const TQString & tool, const TQString & cfg /* = Default */ )
{
return "Tool/" + tool + '/' + cfg;
}
- void extract(const QString &str, QString &tool, QString &cfg)
+ void extract(const TQString &str, TQString &tool, TQString &cfg)
{
- static QRegExp re("([^\\(]*)\\((.*)\\)");
- QString lcl = str;
+ static TQRegExp re("([^\\(]*)\\((.*)\\)");
+ TQString lcl = str;
lcl.stripWhiteSpace();
- cfg = QString::null;
+ cfg = TQString();
if ( re.exactMatch(lcl) )
{
tool = re.cap(1).stripWhiteSpace();
@@ -445,10 +445,10 @@ namespace KileTool
}
else
tool = lcl;
- KILE_DEBUG() << "===void extract(const QString &str = " << str << " , QString &tool = " << tool << ", QString &cfg = " << cfg << " )===" << endl;
+ KILE_DEBUG() << "===void extract(const TQString &str = " << str << " , TQString &tool = " << tool << ", TQString &cfg = " << cfg << " )===" << endl;
}
- QString format(const QString & tool, const QString &cfg)
+ TQString format(const TQString & tool, const TQString &cfg)
{
if (!cfg.isNull())
return tool + '(' + cfg + ')';
@@ -456,10 +456,10 @@ namespace KileTool
return tool;
}
- QStringList configNames(const QString &tool, KConfig *config)
+ TQStringList configNames(const TQString &tool, KConfig *config)
{
- QStringList groups = config->groupList(), configs;
- QRegExp re = QRegExp("Tool/"+ tool +"/(.+)");
+ TQStringList groups = config->groupList(), configs;
+ TQRegExp re = TQRegExp("Tool/"+ tool +"/(.+)");
for ( uint i = 0; i < groups.count(); ++i )
{
@@ -472,27 +472,27 @@ namespace KileTool
return configs;
}
- QString menuFor(const QString &tool, KConfig *config)
+ TQString menuFor(const TQString &tool, KConfig *config)
{
config->setGroup("ToolsGUI");
return config->readEntry(tool, "Other,gear").section(',',0,0);
}
- QString iconFor(const QString &tool, KConfig *config)
+ TQString iconFor(const TQString &tool, KConfig *config)
{
config->setGroup("ToolsGUI");
return config->readEntry(tool, "Other,gear").section(',',1,1);
}
- void setGUIOptions(const QString &tool, const QString &menu, const QString &icon, KConfig *config)
+ void setGUIOptions(const TQString &tool, const TQString &menu, const TQString &icon, KConfig *config)
{
- QString entry = menu + ',' + icon;
+ TQString entry = menu + ',' + icon;
config->setGroup("ToolsGUI");
config->writeEntry(tool, entry);
}
- QString categoryFor(const QString &clss)
+ TQString categoryFor(const TQString &clss)
{
if ( clss == "Compile" || clss == "LaTeX" )
return "Compile";
diff --git a/src/kile/kiletoolmanager.h b/src/kile/kiletoolmanager.h
index 095342a..9de4333 100644
--- a/src/kile/kiletoolmanager.h
+++ b/src/kile/kiletoolmanager.h
@@ -16,14 +16,14 @@
#ifndef KILETOOLMANAGER_H
#define KILETOOLMANAGER_H
-#include <qobject.h>
-#include <qstringlist.h>
-#include <qptrqueue.h>
+#include <tqobject.h>
+#include <tqstringlist.h>
+#include <tqptrqueue.h>
#include "kiletool.h"
-class QTimer;
-class QWidgetStack;
+class TQTimer;
+class TQWidgetStack;
class KConfig;
class KTextEdit;
@@ -40,48 +40,49 @@ namespace KileTool
class QueueItem
{
public:
- QueueItem(Base *tool, const QString & cfg = QString::null, bool block = false);
+ QueueItem(Base *tool, const TQString & cfg = TQString(), bool block = false);
~QueueItem();
Base* tool() const { return m_tool; }
- const QString cfg() const { return m_cfg; }
+ const TQString cfg() const { return m_cfg; }
bool shouldBlock() { return m_bBlock; }
private:
Base *m_tool;
- QString m_cfg;
+ TQString m_cfg;
bool m_bBlock;
};
- class Queue : public QPtrQueue<QueueItem>
+ class Queue : public TQPtrQueue<QueueItem>
{
public:
Base* tool() const;
- const QString cfg() const;
+ const TQString cfg() const;
bool shouldBlock() const;
void enqueueNext(QueueItem *);
};
- class Manager : public QObject
+ class Manager : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- Manager(KileInfo *ki, KConfig *config, KileWidget::LogMsg *log, KileWidget::Output *output, KParts::PartManager *, QWidgetStack *, KAction *, uint to);
+ Manager(KileInfo *ki, KConfig *config, KileWidget::LogMsg *log, KileWidget::Output *output, KParts::PartManager *, TQWidgetStack *, KAction *, uint to);
~Manager();
public:
void initTool(Base*);
- bool configure(Base*, const QString & cfg = QString::null);
- bool retrieveEntryMap(const QString & name, Config & map, bool usequeue = true, bool useproject = true, const QString & cfg = QString::null);
- void saveEntryMap(const QString & name, Config & map, bool usequeue = true, bool useproject = true);
- QString currentGroup(const QString &name, bool usequeue = true, bool useproject = true);
+ bool configure(Base*, const TQString & cfg = TQString());
+ bool retrieveEntryMap(const TQString & name, Config & map, bool usequeue = true, bool useproject = true, const TQString & cfg = TQString());
+ void saveEntryMap(const TQString & name, Config & map, bool usequeue = true, bool useproject = true);
+ TQString currentGroup(const TQString &name, bool usequeue = true, bool useproject = true);
- void wantGUIState(const QString &);
+ void wantGUIState(const TQString &);
KParts::PartManager * partManager() { return m_pm; }
- QWidgetStack * widgetStack() { return m_stack; }
+ TQWidgetStack * widgetStack() { return m_stack; }
KileInfo * info() { return m_ki; }
KConfig * config() { return m_config; }
@@ -89,7 +90,7 @@ namespace KileTool
void setFactory(Factory* fac) { m_factory = fac; }
Factory* factory() { return m_factory; }
- bool queryContinue(const QString & question, const QString & caption = QString::null);
+ bool queryContinue(const TQString & question, const TQString & caption = TQString());
bool shouldBlock();
int lastResult() { return m_nLastResult; }
@@ -98,14 +99,14 @@ namespace KileTool
void started(Base*);
void done(Base *, int);
- int run(const QString &, const QString & = QString::null, bool insertAtTop = false, bool block = false);
- int run(Base *, const QString & = QString::null, bool insertAtTop = false, bool block = false);
+ int run(const TQString &, const TQString & = TQString(), bool insertAtTop = false, bool block = false);
+ int run(Base *, const TQString & = TQString(), bool insertAtTop = false, bool block = false);
- int runNext(const QString &, const QString & = QString::null, bool block = false);
- int runNext(Base *, const QString & = QString::null, bool block = false);
+ int runNext(const TQString &, const TQString & = TQString(), bool block = false);
+ int runNext(Base *, const TQString & = TQString(), bool block = false);
- int runBlocking(const QString &, const QString & = QString::null, bool = false);
- int runNextBlocking(const QString &, const QString & = QString::null);
+ int runBlocking(const TQString &, const TQString & = TQString(), bool = false);
+ int runNextBlocking(const TQString &, const TQString & = TQString());
void stop(); //should be a slot that stops the active tool and clears the queue
@@ -114,7 +115,7 @@ namespace KileTool
void enableClear();
signals:
- void requestGUIState(const QString &);
+ void requestGUIState(const TQString &);
void requestSaveAll(bool, bool);
void jumpToFirstError();
void toolStarted();
@@ -126,34 +127,34 @@ namespace KileTool
KileWidget::LogMsg *m_log;
KileWidget::Output *m_output;
KParts::PartManager *m_pm;
- QWidgetStack *m_stack;
+ TQWidgetStack *m_stack;
KAction *m_stop;
Factory *m_factory;
Queue m_queue;
- QTimer *m_timer;
+ TQTimer *m_timer;
bool m_bClear;
int m_nLastResult;
uint m_nTimeout;
};
- QStringList toolList(KConfig *config, bool menuOnly = false);
- QStringList configNames(const QString &tool, KConfig *config);
+ TQStringList toolList(KConfig *config, bool menuOnly = false);
+ TQStringList configNames(const TQString &tool, KConfig *config);
- QString configName(const QString & tool, KConfig *);
- void setConfigName(const QString & tool, const QString & name, KConfig *);
+ TQString configName(const TQString & tool, KConfig *);
+ void setConfigName(const TQString & tool, const TQString & name, KConfig *);
- QString groupFor(const QString & tool, KConfig *);
- QString groupFor(const QString & tool, const QString & cfg = "Default" );
+ TQString groupFor(const TQString & tool, KConfig *);
+ TQString groupFor(const TQString & tool, const TQString & cfg = "Default" );
- void extract(const QString &str, QString &tool, QString &cfg);
- QString format(const QString & tool, const QString &cfg);
+ void extract(const TQString &str, TQString &tool, TQString &cfg);
+ TQString format(const TQString & tool, const TQString &cfg);
- QString menuFor(const QString &tool, KConfig *config);
- QString iconFor(const QString &tool, KConfig *config);
+ TQString menuFor(const TQString &tool, KConfig *config);
+ TQString iconFor(const TQString &tool, KConfig *config);
- QString categoryFor(const QString &clss);
+ TQString categoryFor(const TQString &clss);
- void setGUIOptions(const QString &tool, const QString &menu, const QString &icon, KConfig *config);
+ void setGUIOptions(const TQString &tool, const TQString &menu, const TQString &icon, KConfig *config);
}
#endif
diff --git a/src/kile/kileuntitled.cpp b/src/kile/kileuntitled.cpp
index 508d00b..9a9d2b4 100644
--- a/src/kile/kileuntitled.cpp
+++ b/src/kile/kileuntitled.cpp
@@ -12,26 +12,26 @@
#include "kileuntitled.h"
-#include <qregexp.h>
+#include <tqregexp.h>
#include <klocale.h>
-QString KileUntitled::m_untitled = i18n("Untitled");
+TQString KileUntitled::m_untitled = i18n("Untitled");
int KileUntitled::m_last = -1;
-bool KileUntitled::isUntitled(const QString &str)
+bool KileUntitled::isUntitled(const TQString &str)
{
- static QRegExp reUntitled(m_untitled + " [0-9]+.*");
+ static TQRegExp reUntitled(m_untitled + " [0-9]+.*");
return reUntitled.exactMatch(str);
}
-QString KileUntitled::next()
+TQString KileUntitled::next()
{
++m_last;
return current();
}
-QString KileUntitled::current()
+TQString KileUntitled::current()
{
- return m_untitled + ' ' + QString::number(m_last);
+ return m_untitled + ' ' + TQString::number(m_last);
}
diff --git a/src/kile/kileuntitled.h b/src/kile/kileuntitled.h
index 6121298..44eeb55 100644
--- a/src/kile/kileuntitled.h
+++ b/src/kile/kileuntitled.h
@@ -13,17 +13,17 @@
#ifndef KILEUNTITLED_H
#define KILEUNTITLED_H
-#include <qstring.h>
+#include <tqstring.h>
class KileUntitled
{
public:
- static bool isUntitled(const QString &str);
- static QString next();
- static QString current();
+ static bool isUntitled(const TQString &str);
+ static TQString next();
+ static TQString current();
private:
- static QString m_untitled;
+ static TQString m_untitled;
static int m_last;
};
diff --git a/src/kile/kileversion.cpp b/src/kile/kileversion.cpp
index cc45df1..d2b5670 100644
--- a/src/kile/kileversion.cpp
+++ b/src/kile/kileversion.cpp
@@ -13,19 +13,19 @@
#include "kileversion.h"
-#include <qstringlist.h>
+#include <tqstringlist.h>
-int compareVersionStrings(const QString& s1, const QString& s2) {
- QStringList l1 = QStringList::split(".", s1);
- QStringList l2 = QStringList::split(".", s2);
+int compareVersionStrings(const TQString& s1, const TQString& s2) {
+ TQStringList l1 = TQStringList::split(".", s1);
+ TQStringList l2 = TQStringList::split(".", s2);
while(l1.size() < 3) {
l1.push_back("0");
}
while(l2.size() < 3) {
l2.push_back("0");
}
- QStringList::iterator i1 = l1.begin();
- QStringList::iterator i2 = l2.begin();
+ TQStringList::iterator i1 = l1.begin();
+ TQStringList::iterator i2 = l2.begin();
for(unsigned int i = 0; i < 3; ++i) {
unsigned int c1 = (*i1).toUInt();
unsigned int c2 = (*i2).toUInt();
diff --git a/src/kile/kileversion.h b/src/kile/kileversion.h
index 5a3b340..e46101b 100644
--- a/src/kile/kileversion.h
+++ b/src/kile/kileversion.h
@@ -17,17 +17,17 @@
#ifndef KILEVERSION_H
#define KILEVERSION_H
-#include <qstring.h>
+#include <tqstring.h>
-const QString kileVersion="2.0";
-const QString kileFullVersion="2.0.1";
-const QString kilePrVersion="2";
+const TQString kileVersion="2.0";
+const TQString kileFullVersion="2.0.1";
+const TQString kilePrVersion="2";
/**
* Compares two strings of the form "a.b(.c)" and "d.e(.f)" lexicographically,
* where a, b, c, d, e and f are natural numbers.
* @return 1 if s1 is bigger than s2, 0 if s1 == s2, -1 if s1 is smaller than s2
**/
-int compareVersionStrings(const QString& s1, const QString& s2);
+int compareVersionStrings(const TQString& s1, const TQString& s2);
#endif
diff --git a/src/kile/kileviewmanager.cpp b/src/kile/kileviewmanager.cpp
index cf78294..173efc2 100644
--- a/src/kile/kileviewmanager.cpp
+++ b/src/kile/kileviewmanager.cpp
@@ -18,10 +18,10 @@
#include "kileviewmanager.h"
-#include <qpopupmenu.h>
-#include <qtimer.h> //for QTimer::singleShot trick
-#include <qpixmap.h>
-#include <qclipboard.h>
+#include <tqpopupmenu.h>
+#include <tqtimer.h> //for TQTimer::singleShot trick
+#include <tqpixmap.h>
+#include <tqclipboard.h>
#include <kdeversion.h>
#include <kglobal.h>
@@ -53,8 +53,8 @@
namespace KileView
{
-Manager::Manager(KileInfo *info, QObject *parent, const char *name) :
- QObject(parent, name),
+Manager::Manager(KileInfo *info, TQObject *tqparent, const char *name) :
+ TQObject(tqparent, name),
m_ki(info),
m_activeTextView(0L),
// m_projectview(0L),
@@ -69,46 +69,46 @@ Manager::~Manager()
{
}
-void Manager::setClient(QObject *receiver, KXMLGUIClient *client)
+void Manager::setClient(TQObject *receiver, KXMLGUIClient *client)
{
m_receiver = receiver;
m_client = client;
if(NULL == m_client->actionCollection()->action("popup_pasteaslatex"))
new KAction(i18n("Paste as LaTe&X"), 0, this,
- SLOT(pasteAsLaTeX()), m_client->actionCollection(), "popup_pasteaslatex");
+ TQT_SLOT(pasteAsLaTeX()), m_client->actionCollection(), "popup_pasteaslatex");
if(NULL == m_client->actionCollection()->action("popup_converttolatex"))
new KAction(i18n("Convert Selection to &LaTeX"), 0, this,
- SLOT(convertSelectionToLaTeX()), m_client->actionCollection(), "popup_converttolatex");
+ TQT_SLOT(convertSelectionToLaTeX()), m_client->actionCollection(), "popup_converttolatex");
if(NULL == m_client->actionCollection()->action("popup_quickpreview"))
new KAction(i18n("&QuickPreview Selection"), 0, this,
- SLOT(quickPreviewPopup()), m_client->actionCollection(), "popup_quickpreview");
+ TQT_SLOT(quickPreviewPopup()), m_client->actionCollection(), "popup_quickpreview");
}
-void Manager::createTabs(QWidget *parent)
+void Manager::createTabs(TQWidget *tqparent)
{
- m_widgetStack = new QWidgetStack(parent);
- m_emptyDropWidget = new DropWidget(parent);
+ m_widgetStack = new TQWidgetStack(tqparent);
+ m_emptyDropWidget = new DropWidget(tqparent);
m_widgetStack->addWidget(m_emptyDropWidget);
- connect(m_emptyDropWidget, SIGNAL(testCanDecode(const QDragMoveEvent *, bool &)), this, SLOT(testCanDecodeURLs(const QDragMoveEvent *, bool &)));
- connect(m_emptyDropWidget, SIGNAL(receivedDropEvent(QDropEvent *)), m_ki->docManager(), SLOT(openDroppedURLs(QDropEvent *)));
- m_tabs = new KTabWidget(parent);
+ connect(m_emptyDropWidget, TQT_SIGNAL(testCanDecode(const TQDragMoveEvent *, bool &)), this, TQT_SLOT(testCanDecodeURLs(const TQDragMoveEvent *, bool &)));
+ connect(m_emptyDropWidget, TQT_SIGNAL(receivedDropEvent(TQDropEvent *)), m_ki->docManager(), TQT_SLOT(openDroppedURLs(TQDropEvent *)));
+ m_tabs = new KTabWidget(tqparent);
m_widgetStack->addWidget(m_tabs);
- m_tabs->setFocusPolicy(QWidget::ClickFocus);
+ m_tabs->setFocusPolicy(TQ_ClickFocus);
m_tabs->setTabReorderingEnabled(true);
m_tabs->setHoverCloseButton(true);
m_tabs->setHoverCloseButtonDelayed(true);
m_tabs->setFocus();
- connect( m_tabs, SIGNAL( currentChanged( QWidget * ) ), m_receiver, SLOT(newCaption()) );
- connect( m_tabs, SIGNAL( currentChanged( QWidget * ) ), m_receiver, SLOT(activateView( QWidget * )) );
- connect( m_tabs, SIGNAL( currentChanged( QWidget * ) ), m_receiver, SLOT(updateModeStatus()) );
- connect( m_tabs, SIGNAL( closeRequest(QWidget *) ), this, SLOT(closeWidget(QWidget *)));
- connect( m_tabs, SIGNAL( testCanDecode( const QDragMoveEvent *, bool & ) ), this, SLOT(testCanDecodeURLs( const QDragMoveEvent *, bool & )) );
- connect( m_tabs, SIGNAL( receivedDropEvent( QDropEvent * ) ), m_ki->docManager(), SLOT(openDroppedURLs( QDropEvent * )) );
- connect( m_tabs, SIGNAL( receivedDropEvent( QWidget*, QDropEvent * ) ), this, SLOT(replaceLoadedURL( QWidget *, QDropEvent * )) );
+ connect( m_tabs, TQT_SIGNAL( currentChanged( TQWidget * ) ), m_receiver, TQT_SLOT(newCaption()) );
+ connect( m_tabs, TQT_SIGNAL( currentChanged( TQWidget * ) ), m_receiver, TQT_SLOT(activateView( TQWidget * )) );
+ connect( m_tabs, TQT_SIGNAL( currentChanged( TQWidget * ) ), m_receiver, TQT_SLOT(updateModetqStatus()) );
+ connect( m_tabs, TQT_SIGNAL( closeRequest(TQWidget *) ), this, TQT_SLOT(closeWidget(TQWidget *)));
+ connect( m_tabs, TQT_SIGNAL( testCanDecode( const TQDragMoveEvent *, bool & ) ), this, TQT_SLOT(testCanDecodeURLs( const TQDragMoveEvent *, bool & )) );
+ connect( m_tabs, TQT_SIGNAL( receivedDropEvent( TQDropEvent * ) ), m_ki->docManager(), TQT_SLOT(openDroppedURLs( TQDropEvent * )) );
+ connect( m_tabs, TQT_SIGNAL( receivedDropEvent( TQWidget*, TQDropEvent * ) ), this, TQT_SLOT(replaceLoadedURL( TQWidget *, TQDropEvent * )) );
m_widgetStack->raiseWidget(m_emptyDropWidget); // there are no tabs, so show the DropWidget
}
-void Manager::closeWidget(QWidget *widget)
+void Manager::closeWidget(TQWidget *widget)
{
if (widget->inherits( "Kate::View" ))
{
@@ -142,30 +142,30 @@ Kate::View* Manager::createTextView(KileDocument::TextInfo *info, int index)
m_tabs->showPage( view );
m_textViewList.insert((index < 0 || (uint)index >= m_textViewList.count()) ? m_textViewList.count() : index, view);
- connect(view, SIGNAL(viewStatusMsg(const QString&)), m_receiver, SLOT(newStatus(const QString&)));
- connect(view, SIGNAL(newStatus()), m_receiver, SLOT(newCaption()));
- connect(view, SIGNAL(dropEventPass(QDropEvent *)), m_ki->docManager(), SLOT(openDroppedURLs(QDropEvent *)));
- connect(info, SIGNAL(urlChanged(KileDocument::Info*, const KURL&)), this, SLOT(urlChanged(KileDocument::Info*, const KURL&)));
+ connect(view, TQT_SIGNAL(viewStatusMsg(const TQString&)), m_receiver, TQT_SLOT(newtqStatus(const TQString&)));
+ connect(view, TQT_SIGNAL(newtqStatus()), m_receiver, TQT_SLOT(newCaption()));
+ connect(view, TQT_SIGNAL(dropEventPass(TQDropEvent *)), m_ki->docManager(), TQT_SLOT(openDroppedURLs(TQDropEvent *)));
+ connect(info, TQT_SIGNAL(urlChanged(KileDocument::Info*, const KURL&)), this, TQT_SLOT(urlChanged(KileDocument::Info*, const KURL&)));
- connect( doc, SIGNAL(charactersInteractivelyInserted (int,int,const QString&)), m_ki->editorExtension()->complete(), SLOT(slotCharactersInserted(int,int,const QString&)) );
- connect( view, SIGNAL(completionDone(KTextEditor::CompletionEntry)), m_ki->editorExtension()->complete(), SLOT( slotCompletionDone(KTextEditor::CompletionEntry)) );
- connect( view, SIGNAL(completionAborted()), m_ki->editorExtension()->complete(), SLOT( slotCompletionAborted()) );
- connect( view, SIGNAL(filterInsertString(KTextEditor::CompletionEntry*,QString *)), m_ki->editorExtension()->complete(), SLOT(slotFilterCompletion(KTextEditor::CompletionEntry*,QString *)) );
+ connect( doc, TQT_SIGNAL(charactersInteractivelyInserted (int,int,const TQString&)), m_ki->editorExtension()->complete(), TQT_SLOT(slotCharactersInserted(int,int,const TQString&)) );
+ connect( view, TQT_SIGNAL(completionDone(KTextEditor::CompletionEntry)), m_ki->editorExtension()->complete(), TQT_SLOT( slotCompletionDone(KTextEditor::CompletionEntry)) );
+ connect( view, TQT_SIGNAL(completionAborted()), m_ki->editorExtension()->complete(), TQT_SLOT( slotCompletionAborted()) );
+ connect( view, TQT_SIGNAL(filterInsertString(KTextEditor::CompletionEntry*,TQString *)), m_ki->editorExtension()->complete(), TQT_SLOT(slotFilterCompletion(KTextEditor::CompletionEntry*,TQString *)) );
// install a working kate part popup dialog thingy
- QPopupMenu *viewPopupMenu = (QPopupMenu*)(m_client->factory()->container("ktexteditor_popup", m_client));
+ TQPopupMenu *viewPopupMenu = (TQPopupMenu*)(m_client->factory()->container("ktexteditor_popup", m_client));
if((NULL != view) && (NULL != viewPopupMenu))
view->installPopup(viewPopupMenu);
if(NULL != viewPopupMenu)
- connect(viewPopupMenu, SIGNAL(aboutToShow()), this, SLOT(onKatePopupMenuRequest()));
+ connect(viewPopupMenu, TQT_SIGNAL(aboutToShow()), this, TQT_SLOT(onKatePopupMenuRequest()));
//activate the newly created view
emit(activateView(view, false));
- QTimer::singleShot(0, m_receiver, SLOT(newCaption())); //make sure the caption gets updated
+ TQTimer::singleShot(0, m_receiver, TQT_SLOT(newCaption())); //make sure the caption gets updated
- reflectDocumentStatus(view->getDoc(), false, 0);
+ reflectDocumenttqStatus(view->getDoc(), false, 0);
- view->setFocusPolicy(QWidget::StrongFocus);
+ view->setFocusPolicy(TQ_StrongFocus);
view->setFocus();
emit(prepareForPart("Editor"));
@@ -176,15 +176,15 @@ Kate::View* Manager::createTextView(KileDocument::TextInfo *info, int index)
if ( action )
{
KILE_DEBUG() << " reconnect action 'file_save'..." << endl;
- action->disconnect(SIGNAL(activated()));
- connect(action, SIGNAL(activated()), m_ki->docManager(), SLOT(fileSave()));
+ action->disconnect(TQT_SIGNAL(activated()));
+ connect(action, TQT_SIGNAL(activated()), m_ki->docManager(), TQT_SLOT(fileSave()));
}
action = view->actionCollection()->action(KStdAction::stdName(KStdAction::SaveAs));
if ( action )
{
KILE_DEBUG() << " reconnect action 'file_save_as'..." << endl;
- action->disconnect(SIGNAL(activated()));
- connect(action, SIGNAL(activated()), m_ki->docManager(), SLOT(fileSaveAs()));
+ action->disconnect(TQT_SIGNAL(activated()));
+ connect(action, TQT_SIGNAL(activated()), m_ki->docManager(), TQT_SLOT(fileSaveAs()));
}
m_widgetStack->raiseWidget(m_tabs); // there is at least one tab, so show the KTabWidget now
@@ -201,7 +201,7 @@ void Manager::removeView(Kate::View *view)
m_textViewList.remove(view);
delete view;
- QTimer::singleShot(0, m_receiver, SLOT(newCaption())); //make sure the caption gets updated
+ TQTimer::singleShot(0, m_receiver, TQT_SLOT(newCaption())); //make sure the caption gets updated
if (textViews().isEmpty()) {
m_ki->structureWidget()->clear();
m_widgetStack->raiseWidget(m_emptyDropWidget); // there are no tabs left, so show
@@ -304,9 +304,9 @@ void Manager::gotoPrevView()
m_tabs->setCurrentPage( cPage );
}
-void Manager::reflectDocumentStatus(Kate::Document *doc, bool isModified, unsigned char reason)
+void Manager::reflectDocumenttqStatus(Kate::Document *doc, bool isModified, unsigned char reason)
{
- QPixmap icon;
+ TQPixmap icon;
if ( reason == 0 && isModified ) //nothing
icon = SmallIcon("filesave");
else if ( reason == 1 || reason == 2 ) //dirty file
@@ -330,7 +330,7 @@ void Manager::onKatePopupMenuRequest(void)
if(NULL == view)
return;
- QPopupMenu *viewPopupMenu = (QPopupMenu*)(m_client->factory()->container("ktexteditor_popup", m_client));
+ TQPopupMenu *viewPopupMenu = (TQPopupMenu*)(m_client->factory()->container("ktexteditor_popup", m_client));
if(NULL == viewPopupMenu)
return;
@@ -361,7 +361,7 @@ void Manager::onKatePopupMenuRequest(void)
if(!pasteAsLaTeXAction->isPlugged())
pasteAsLaTeXAction->plug(viewPopupMenu);
- QClipboard *clip = KApplication::clipboard();
+ TQClipboard *clip = KApplication::tqclipboard();
if(NULL != clip)
pasteAsLaTeXAction->setEnabled(!clip->text().isNull());
}
@@ -400,24 +400,24 @@ void Manager::convertSelectionToLaTeX(void)
firstLineLength = doc->lineLength(selStartLine);
else
firstLineLength = selEndCol;
- QString firstLine = doc->text(selStartLine, selStartCol, selStartLine, firstLineLength);
- QString firstLineCvt = cvt.ConvertToLaTeX(firstLine);
+ TQString firstLine = doc->text(selStartLine, selStartCol, selStartLine, firstLineLength);
+ TQString firstLineCvt = cvt.ConvertToLaTeX(firstLine);
doc->removeText(selStartLine, selStartCol, selStartLine, firstLineLength);
doc->insertText(selStartLine, selStartCol, firstLineCvt);
newSelEndCol = selStartCol + firstLineCvt.length();
// Processing the intermediate lines
for(uint nLine = selStartLine + 1 ; nLine < selEndLine ; ++nLine) {
- QString line = doc->textLine(nLine);
- QString newLine = cvt.ConvertToLaTeX(line);
+ TQString line = doc->textLine(nLine);
+ TQString newLine = cvt.ConvertToLaTeX(line);
doc->removeLine(nLine);
doc->insertLine(nLine, newLine);
}
// Processing the final line
if(selStartLine != selEndLine) {
- QString lastLine = doc->text(selEndLine, 0, selEndLine, selEndCol);
- QString lastLineCvt = cvt.ConvertToLaTeX(lastLine);
+ TQString lastLine = doc->text(selEndLine, 0, selEndLine, selEndCol);
+ TQString lastLineCvt = cvt.ConvertToLaTeX(lastLine);
doc->removeText(selEndLine, 0, selEndLine, selEndCol);
doc->insertText(selEndLine, 0, lastLineCvt);
newSelEndCol = lastLineCvt.length();
@@ -464,7 +464,7 @@ void Manager::pasteAsLaTeX(void)
doc->removeSelectedText();
PlainToLaTeXConverter cvt;
- QString toPaste = cvt.ConvertToLaTeX(KApplication::clipboard()->text());
+ TQString toPaste = cvt.ConvertToLaTeX(KApplication::tqclipboard()->text());
doc->insertText(cursorLine, cursorCol, toPaste);
// End of the "atomic edit operation"
@@ -490,12 +490,12 @@ void Manager::quickPreviewPopup()
}
}
-void Manager::testCanDecodeURLs(const QDragMoveEvent *e, bool &accept)
+void Manager::testCanDecodeURLs(const TQDragMoveEvent *e, bool &accept)
{
accept = KURLDrag::canDecode(e); // only accept URL drops
}
-void Manager::replaceLoadedURL(QWidget *w, QDropEvent *e)
+void Manager::replaceLoadedURL(TQWidget *w, TQDropEvent *e)
{
KURL::List urls;
if(!KURLDrag::decode(e, urls)) {
@@ -511,7 +511,7 @@ void Manager::replaceLoadedURL(QWidget *w, QDropEvent *e)
}
else if(!hasReplacedTab) {
closeWidget(w);
- m_ki->docManager()->fileOpen(url, QString::null, index);
+ m_ki->docManager()->fileOpen(url, TQString(), index);
hasReplacedTab = true;
}
else {
@@ -534,7 +534,7 @@ void Manager::urlChanged(KileDocument::Info* info, const KURL& /*url*/)
}
}
-DropWidget::DropWidget(QWidget * parent, const char * name, WFlags f) : QWidget(parent, name, f)
+DropWidget::DropWidget(TQWidget * tqparent, const char * name, WFlags f) : TQWidget(tqparent, name, f)
{
setAcceptDrops(true);
}
@@ -543,14 +543,14 @@ DropWidget::~DropWidget()
{
}
-void DropWidget::dragMoveEvent(QDragMoveEvent *e)
+void DropWidget::dragMoveEvent(TQDragMoveEvent *e)
{
bool b;
emit testCanDecode(e, b);
e->accept(b);
}
-void DropWidget::dropEvent(QDropEvent *e)
+void DropWidget::dropEvent(TQDropEvent *e)
{
emit receivedDropEvent(e);
}
@@ -564,7 +564,7 @@ void Manager::unplugKatePartMenu(Kate::View* view)
{
if ( view )
{
- QStringList actionlist;
+ TQStringList actionlist;
actionlist << "set_confdlg" << "go_goto_line"; // action names from katepartui.rc
for ( uint i=0; i < actionlist.count(); ++i )
diff --git a/src/kile/kileviewmanager.h b/src/kile/kileviewmanager.h
index cbe443d..dbecd6e 100644
--- a/src/kile/kileviewmanager.h
+++ b/src/kile/kileviewmanager.h
@@ -20,12 +20,12 @@
#ifndef KILEVIEWKILEVIEWMANAGER_H
#define KILEVIEWKILEVIEWMANAGER_H
-#include <qobject.h>
-#include <qwidgetstack.h>
+#include <tqobject.h>
+#include <tqwidgetstack.h>
#include <ktabwidget.h>
-class QPixmap;
+class TQPixmap;
class KURL;
class KXMLGUIClient;
@@ -48,26 +48,27 @@ namespace KileView
{
//TODO inherit from KParts::Manager
-class Manager : public QObject
+class Manager : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- Manager(KileInfo *ki, QObject *parent = 0, const char *name = 0);
+ Manager(KileInfo *ki, TQObject *tqparent = 0, const char *name = 0);
~Manager();
public:
- void setClient(QObject *receiver, KXMLGUIClient *client);
+ void setClient(TQObject *receiver, KXMLGUIClient *client);
Kate::View* currentTextView() const;
- QPtrList<Kate::View>& textViews() {return m_textViewList;}
+ TQPtrList<Kate::View>& textViews() {return m_textViewList;}
Kate::View* textView(int i) { return m_textViewList.at(i); }
Kate::View* textView(KileDocument::TextInfo *info);
int getIndexOf(Kate::View* view) const;
unsigned int getTabCount() const;
- void createTabs(QWidget *);
+ void createTabs(TQWidget *);
Kate::View* createTextView(KileDocument::TextInfo *info, int index = -1);
KTabWidget* tabs() { return m_tabs; }
@@ -79,18 +80,18 @@ public:
public slots:
Kate::View* switchToTextView(const KURL & url, bool requestFocus = false);
- void closeWidget(QWidget *);
+ void closeWidget(TQWidget *);
void removeView(Kate::View *view);
- void setTabLabel(QWidget *view, const QString & name) { m_tabs->setTabLabel(view, name); }
- void changeTab(QWidget *view, const QPixmap & icon, const QString & name) { m_tabs->changeTab(view, icon, name); }
+ void setTabLabel(TQWidget *view, const TQString & name) { m_tabs->setTabLabel(view, name); }
+ void changeTab(TQWidget *view, const TQPixmap & icon, const TQString & name) { m_tabs->changeTab(view, icon, name); }
void updateStructure(bool parse = false, KileDocument::Info *docinfo = 0L);
void gotoNextView();
void gotoPrevView();
- void reflectDocumentStatus(Kate::Document*, bool, unsigned char);
+ void reflectDocumenttqStatus(Kate::Document*, bool, unsigned char);
void onKatePopupMenuRequest(void);
void convertSelectionToLaTeX(void);
@@ -98,8 +99,8 @@ public slots:
void quickPreviewPopup();
protected slots:
- void testCanDecodeURLs(const QDragMoveEvent *e, bool &accept);
- void replaceLoadedURL(QWidget *w, QDropEvent *e);
+ void testCanDecodeURLs(const TQDragMoveEvent *e, bool &accept);
+ void replaceLoadedURL(TQWidget *w, TQDropEvent *e);
/**
*
@@ -107,20 +108,20 @@ protected slots:
void urlChanged(KileDocument::Info* info, const KURL& url);
signals:
- void activateView(QWidget *, bool);
- void prepareForPart(const QString &);
+ void activateView(TQWidget *, bool);
+ void prepareForPart(const TQString &);
void startQuickPreview(int);
private:
KileInfo *m_ki;
Kate::View *m_activeTextView;
// KileProjectView *m_projectview;
- QPtrList<Kate::View> m_textViewList;
+ TQPtrList<Kate::View> m_textViewList;
KTabWidget *m_tabs;
- QObject *m_receiver;
+ TQObject *m_receiver;
KXMLGUIClient *m_client;
- QWidgetStack *m_widgetStack;
- QWidget *m_emptyDropWidget;
+ TQWidgetStack *m_widgetStack;
+ TQWidget *m_emptyDropWidget;
};
@@ -128,20 +129,21 @@ private:
* Little helper widget to overcome the limitation that KTabWidget doesn't honour drop events when
* there are no tabs: the DropWidget is shown instead of KTabWidget when there are no tabs.
*/
-class DropWidget : public QWidget {
+class DropWidget : public TQWidget {
Q_OBJECT
+ TQ_OBJECT
public:
- DropWidget(QWidget * parent = 0, const char * name = 0, WFlags f = 0);
+ DropWidget(TQWidget * tqparent = 0, const char * name = 0, WFlags f = 0);
virtual ~DropWidget();
- virtual void dragMoveEvent(QDragMoveEvent *e);
+ virtual void dragMoveEvent(TQDragMoveEvent *e);
- virtual void dropEvent(QDropEvent *e);
+ virtual void dropEvent(TQDropEvent *e);
signals:
- void testCanDecode(const QDragMoveEvent *, bool &);
- void receivedDropEvent(QDropEvent *);
+ void testCanDecode(const TQDragMoveEvent *, bool &);
+ void receivedDropEvent(TQDropEvent *);
};
}
diff --git a/src/kile/kilewizard.cpp b/src/kile/kilewizard.cpp
index 6f26ad3..94fb216 100644
--- a/src/kile/kilewizard.cpp
+++ b/src/kile/kilewizard.cpp
@@ -17,9 +17,9 @@
namespace KileDialog
{
- Wizard::Wizard(KConfig *config, QWidget *parent, const char *name, const QString &caption) :
- KDialogBase(parent,name,true,caption,KDialogBase::Ok | KDialogBase::Cancel, KDialogBase::Ok, true),
- m_td(QString::null, QString::null, QString::null, 0, 0, QString::null),
+ Wizard::Wizard(KConfig *config, TQWidget *tqparent, const char *name, const TQString &caption) :
+ KDialogBase(tqparent,name,true,caption,KDialogBase::Ok | KDialogBase::Cancel, KDialogBase::Ok, true),
+ m_td(TQString(), TQString(), TQString(), 0, 0, TQString()),
m_config(config)
{
}
diff --git a/src/kile/kilewizard.h b/src/kile/kilewizard.h
index 0798123..9269e50 100644
--- a/src/kile/kilewizard.h
+++ b/src/kile/kilewizard.h
@@ -27,7 +27,7 @@ namespace KileDialog
class Wizard : public KDialogBase
{
public:
- Wizard(KConfig *, QWidget *parent=0, const char *name=0, const QString &caption = QString::null);
+ Wizard(KConfig *, TQWidget *tqparent=0, const char *name=0, const TQString &caption = TQString());
~Wizard();
public:
diff --git a/src/kile/latexcmd.cpp b/src/kile/latexcmd.cpp
index f097d5d..928234f 100644
--- a/src/kile/latexcmd.cpp
+++ b/src/kile/latexcmd.cpp
@@ -46,7 +46,7 @@ void LatexCommands::resetCommands()
// 6: optional parameter
// 7: parameter group(s)
- QStringList envlist;
+ TQStringList envlist;
envlist
// list environments
<< "itemize,+,l,*,,,,,"
@@ -105,7 +105,7 @@ void LatexCommands::resetCommands()
// 3: optional parameter
// 4: parameter
- QStringList cmdlist;
+ TQStringList cmdlist;
cmdlist
// Labels
<< "\\label,+,L,,,{ }"
@@ -141,15 +141,15 @@ void LatexCommands::resetCommands()
// add user defined environments/commands
-void LatexCommands::addUserCommands(const QString &name, QStringList &list)
+void LatexCommands::addUserCommands(const TQString &name, TQStringList &list)
{
if ( m_config->hasGroup(name) )
{
KILE_DEBUG() << name << endl;
- QMap<QString,QString> map = m_config->entryMap(name);
+ TQMap<TQString,TQString> map = m_config->entryMap(name);
if ( ! map.empty() )
{
- QMapConstIterator<QString,QString> it;
+ TQMapConstIterator<TQString,TQString> it;
for ( it=map.begin(); it!=map.end(); ++it)
{
list << it.key() + ",-," + it.data();
@@ -161,18 +161,18 @@ void LatexCommands::addUserCommands(const QString &name, QStringList &list)
// insert all entries into the dictionary
-void LatexCommands::insert(const QStringList &list)
+void LatexCommands::insert(const TQStringList &list)
{
// now insert new entries, if they have the right number of attributes
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it=list.begin(); it!=list.end(); ++it )
{
- int pos = (*it).find(',');
+ int pos = (*it).tqfind(',');
if ( pos >= 0 )
{
- QString key = (*it).left(pos);
- QString value = (*it).right( (*it).length()-pos-1 );
- QStringList valuelist = QStringList::split(',',value,true);
+ TQString key = (*it).left(pos);
+ TQString value = (*it).right( (*it).length()-pos-1 );
+ TQStringList valuelist = TQStringList::split(',',value,true);
uint attributes = ( key.at(0)=='\\' ) ? MaxCmdAttr : MaxEnvAttr;
if ( valuelist.count() == attributes )
m_latexCommands[key] = value;
@@ -190,37 +190,37 @@ void LatexCommands::insert(const QStringList &list)
// Get value of a key. A star at the end is stripped.
-QString LatexCommands::getValue(const QString &name)
+TQString LatexCommands::getValue(const TQString &name)
{
- QString key = ( name.find('*',-1) >= 0 ) ? name.left(name.length()-1) : name;
- return ( m_latexCommands.contains(key) ) ? m_latexCommands[key] : QString::null;
+ TQString key = ( name.tqfind('*',-1) >= 0 ) ? name.left(name.length()-1) : name;
+ return ( m_latexCommands.tqcontains(key) ) ? m_latexCommands[key] : TQString();
}
//////////////////// internal functions ////////////////////
// get parameter at index
-QString LatexCommands::getAttrAt(const QString &name, uint index)
+TQString LatexCommands::getAttrAt(const TQString &name, uint index)
{
uint attributes = ( name.at(0)=='\\' ) ? MaxCmdAttr : MaxEnvAttr;
- QStringList list = QStringList::split(',',getValue(name),true);
- return ( index<attributes && list.count()==attributes ) ? list[index] : QString::null;
+ TQStringList list = TQStringList::split(',',getValue(name),true);
+ return ( index<attributes && list.count()==attributes ) ? list[index] : TQString();
}
// check for a standard environment
-bool LatexCommands::isUserDefined(const QString &name)
+bool LatexCommands::isUserDefined(const TQString &name)
{
return ( getValue(name).at(0) == '-' );
}
// check for a special environment type
-bool LatexCommands::isType(const QString &name, QChar ch)
+bool LatexCommands::isType(const TQString &name, TQChar ch)
{
- if ( name.find('*',-1) >= 0 )
+ if ( name.tqfind('*',-1) >= 0 )
{
- QString envname = name.left( name.length()-1 );
+ TQString envname = name.left( name.length()-1 );
return ( getValue(envname).at(2)==ch && isStarredEnv(envname) );
}
else
@@ -233,9 +233,9 @@ bool LatexCommands::isType(const QString &name, QChar ch)
// convert attribute to character
-QChar LatexCommands::getAttrChar(CmdAttribute attr)
+TQChar LatexCommands::getAttrChar(CmdAttribute attr)
{
- QChar ch;
+ TQChar ch;
switch ( attr )
{
case CmdAttrAmsmath: ch = 'a'; break;
@@ -257,7 +257,7 @@ QChar LatexCommands::getAttrChar(CmdAttribute attr)
// convert character to attribute
-CmdAttribute LatexCommands::getCharAttr(QChar ch)
+CmdAttribute LatexCommands::getCharAttr(TQChar ch)
{
CmdAttribute attr;
switch ( ch )
@@ -283,43 +283,43 @@ CmdAttribute LatexCommands::getCharAttr(QChar ch)
// check for environment types
-bool LatexCommands::isMathEnv(const QString &name)
+bool LatexCommands::isMathEnv(const TQString &name)
{
- QChar ch = getValue(name).at(2);
+ TQChar ch = getValue(name).at(2);
return ( ch=='m' || ch=='a' );
}
// check for some special attributes
-bool LatexCommands::isStarredEnv(const QString &name)
+bool LatexCommands::isStarredEnv(const TQString &name)
{
return ( getAttrAt(name,2) == "*" );
}
-bool LatexCommands::isCrEnv(const QString &name)
+bool LatexCommands::isCrEnv(const TQString &name)
{
return ( getAttrAt(name,3) == "\\\\" );
}
-bool LatexCommands::isMathModeEnv(const QString &name)
+bool LatexCommands::isMathModeEnv(const TQString &name)
{
return ( getAttrAt(name,4) == "$" );
}
-bool LatexCommands::isDisplaymathModeEnv(const QString &name)
+bool LatexCommands::isDisplaymathModeEnv(const TQString &name)
{
return ( getAttrAt(name,4) == "$$" );
}
-bool LatexCommands::needsMathMode(const QString &name)
+bool LatexCommands::needsMathMode(const TQString &name)
{
return ( isMathModeEnv(name) || isDisplaymathModeEnv(name) );
}
-QString LatexCommands::getTabulator(const QString &name)
+TQString LatexCommands::getTabulator(const TQString &name)
{
- QString tab = getAttrAt(name,5);
- return ( tab.find('&') >= 0 ) ? tab : QString::null;
+ TQString tab = getAttrAt(name,5);
+ return ( tab.tqfind('&') >= 0 ) ? tab : TQString();
}
//////////////////// environments and commands ////////////////////
@@ -327,11 +327,11 @@ QString LatexCommands::getTabulator(const QString &name)
// get a list of environments and commands. The search can be restricted
// to given attributes and userdefined environments and commands
-void LatexCommands::commandList(QStringList &list, uint attr, bool userdefined)
+void LatexCommands::commandList(TQStringList &list, uint attr, bool userdefined)
{
list.clear();
- QMapConstIterator<QString,QString> it;
+ TQMapConstIterator<TQString,TQString> it;
for ( it=m_latexCommands.begin(); it!=m_latexCommands.end(); ++it)
{
// first check, if we need really need all environments and commands
@@ -352,12 +352,12 @@ void LatexCommands::commandList(QStringList &list, uint attr, bool userdefined)
// get all attributes for a given environment and command
-bool LatexCommands::commandAttributes(const QString &name, LatexCmdAttributes &attr)
+bool LatexCommands::commandAttributes(const TQString &name, LatexCmdAttributes &attr)
{
uint attributes = ( name.at(0)=='\\' ) ? MaxCmdAttr : MaxEnvAttr;
// split attribute list
- QStringList list = QStringList::split(',',getValue(name),true);
+ TQStringList list = TQStringList::split(',',getValue(name),true);
// check number of attributes
if ( list.count() != attributes )
@@ -389,7 +389,7 @@ bool LatexCommands::commandAttributes(const QString &name, LatexCmdAttributes &a
attr.cr = false;
attr.mathmode = false;
attr.displaymathmode = false;
- attr.tabulator = QString::null;
+ attr.tabulator = TQString();
attr.option = list[3];
attr.parameter = list[4];
}
@@ -399,13 +399,13 @@ bool LatexCommands::commandAttributes(const QString &name, LatexCmdAttributes &a
//////////////////// determine config string ////////////////////
-QString LatexCommands::configString(LatexCmdAttributes &attr,bool env)
+TQString LatexCommands::configString(LatexCmdAttributes &attr,bool env)
{
// most important: type of environment or command
- QChar ch = getAttrChar( attr.type );
+ TQChar ch = getAttrChar( attr.type );
if ( ch == '?' )
- return QString::null;
- QString s = QString("%1,").arg(ch);
+ return TQString();
+ TQString s = TQString("%1,").tqarg(ch);
// all environments/commands have starred attribute
if ( attr.starred )
diff --git a/src/kile/latexcmd.h b/src/kile/latexcmd.h
index 095a65a..579a0bd 100644
--- a/src/kile/latexcmd.h
+++ b/src/kile/latexcmd.h
@@ -21,9 +21,9 @@
#ifndef LATEXCMD_H
#define LATEXCMD_H
-#include <qobject.h>
-#include <qstringlist.h>
-#include <qmap.h>
+#include <tqobject.h>
+#include <tqstringlist.h>
+#include <tqmap.h>
#include <kconfig.h>
@@ -50,42 +50,43 @@ public:
bool cr;
bool mathmode;
bool displaymathmode;
- QString tabulator;
- QString option;
- QString parameter;
+ TQString tabulator;
+ TQString option;
+ TQString parameter;
};
-class LatexCommands : public QObject
+class LatexCommands : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
LatexCommands(KConfig *config, KileInfo *info);
~LatexCommands() {};
- QString envGroupName() { return m_envGroupName; }
- QString cmdGroupName() { return m_cmdGroupName; }
- QString configString(LatexCmdAttributes &attr,bool env);
+ TQString envGroupName() { return m_envGroupName; }
+ TQString cmdGroupName() { return m_cmdGroupName; }
+ TQString configString(LatexCmdAttributes &attr,bool env);
- bool isMathEnv(const QString &name);
- bool isListEnv(const QString &name) { return isType(name,'l'); }
- bool isTabularEnv(const QString &name) { return isType(name,'t'); }
- bool isVerbatimEnv(const QString &name) { return isType(name,'v'); }
+ bool isMathEnv(const TQString &name);
+ bool isListEnv(const TQString &name) { return isType(name,'l'); }
+ bool isTabularEnv(const TQString &name) { return isType(name,'t'); }
+ bool isVerbatimEnv(const TQString &name) { return isType(name,'v'); }
- bool isLabelCmd(const QString &name) { return isType(name,'L'); }
- bool isReferenceCmd(const QString &name) { return isType(name,'R'); }
- bool isCitationCmd(const QString &name) { return isType(name,'C'); }
- bool isInputCmd(const QString &name) { return isType(name,'I'); }
-
- bool isStarredEnv(const QString &name);
- bool isCrEnv(const QString &name);
- bool isMathModeEnv(const QString &name);
- bool isDisplaymathModeEnv(const QString &name);
- bool needsMathMode(const QString &name);
- QString getTabulator(const QString &name);
+ bool isLabelCmd(const TQString &name) { return isType(name,'L'); }
+ bool isReferenceCmd(const TQString &name) { return isType(name,'R'); }
+ bool isCitationCmd(const TQString &name) { return isType(name,'C'); }
+ bool isInputCmd(const TQString &name) { return isType(name,'I'); }
+
+ bool isStarredEnv(const TQString &name);
+ bool isCrEnv(const TQString &name);
+ bool isMathModeEnv(const TQString &name);
+ bool isDisplaymathModeEnv(const TQString &name);
+ bool needsMathMode(const TQString &name);
+ TQString getTabulator(const TQString &name);
- void commandList(QStringList &list, uint attr, bool userdefined);
- bool commandAttributes(const QString &name, LatexCmdAttributes &attr);
+ void commandList(TQStringList &list, uint attr, bool userdefined);
+ bool commandAttributes(const TQString &name, LatexCmdAttributes &attr);
void resetCommands();
@@ -94,20 +95,20 @@ private:
KConfig *m_config;
KileInfo *m_ki;
- QString m_envGroupName, m_cmdGroupName;
- QMap<QString,QString> m_latexCommands;
+ TQString m_envGroupName, m_cmdGroupName;
+ TQMap<TQString,TQString> m_latexCommands;
- void addUserCommands(const QString &name, QStringList &list);
- void insert(const QStringList &list);
+ void addUserCommands(const TQString &name, TQStringList &list);
+ void insert(const TQStringList &list);
- QString getValue(const QString &name);
+ TQString getValue(const TQString &name);
- bool isUserDefined(const QString &name);
- bool isType(const QString &name, QChar ch);
- QString getAttrAt(const QString &name, uint index);
- QChar getAttrChar(CmdAttribute attr);
- CmdAttribute getCharAttr(QChar ch);
+ bool isUserDefined(const TQString &name);
+ bool isType(const TQString &name, TQChar ch);
+ TQString getAttrAt(const TQString &name, uint index);
+ TQChar getAttrChar(CmdAttribute attr);
+ CmdAttribute getCharAttr(TQChar ch);
};
diff --git a/src/kile/latexcmddialog.cpp b/src/kile/latexcmddialog.cpp
index d1ff7ff..b56dda9 100644
--- a/src/kile/latexcmddialog.cpp
+++ b/src/kile/latexcmddialog.cpp
@@ -21,11 +21,11 @@
#include "latexcmddialog.h"
#include "latexcmd.h"
-#include <qlayout.h>
-#include <qvgroupbox.h>
-#include <qvalidator.h>
-#include <qregexp.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqvgroupbox.h>
+#include <tqvalidator.h>
+#include <tqregexp.h>
+#include <tqwhatsthis.h>
#include <kmessagebox.h>
#include <klocale.h>
@@ -38,11 +38,11 @@ namespace KileDialog
// BEGIN NewLatexCommand
-NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
- const QString &groupname, KListViewItem *lvitem,
+NewLatexCommand::NewLatexCommand(TQWidget *tqparent, const TQString &caption,
+ const TQString &groupname, KListViewItem *lvitem,
KileDocument::CmdAttribute cmdtype,
- QMap<QString,bool> *dict)
- : KDialogBase( parent,0, true, caption, Ok | Cancel, Ok, true ),
+ TQMap<TQString,bool> *dict)
+ : KDialogBase( tqparent,0, true, caption, Ok | Cancel, Ok, true ),
m_dict(dict)
{
// 'add' is only allowed, if the KListViewItem is defined
@@ -63,23 +63,23 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
else if ( cmdtype==KileDocument::CmdAttrVerbatim )
m_useParameter = false;
- QWidget *page = new QWidget( this );
+ TQWidget *page = new TQWidget( this );
setMainWidget(page);
- // layout
- QVBoxLayout *vbox = new QVBoxLayout(page, 6,6 );
- QLabel *label1 = new QLabel(page);
+ // tqlayout
+ TQVBoxLayout *vbox = new TQVBoxLayout(page, 6,6 );
+ TQLabel *label1 = new TQLabel(page);
- QVGroupBox* group= new QVGroupBox(i18n("Attributes"),page );
- QWidget *widget = new QWidget(group);
- QGridLayout *grid = new QGridLayout(widget, 8,3, marginHint(),spacingHint());
+ TQVGroupBox* group= new TQVGroupBox(i18n("Attributes"),page );
+ TQWidget *widget = new TQWidget(group);
+ TQGridLayout *grid = new TQGridLayout(widget, 8,3, marginHint(),spacingHint());
- QLabel *label2 = new QLabel(i18n("Group:"), widget);
- QLabel *label3 = new QLabel(i18n("&Name:"), widget);
- QLabel *grouplabel = new QLabel(groupname, widget);
- QLabel *label4 = new QLabel(i18n("Include *-&version:"), widget);
+ TQLabel *label2 = new TQLabel(i18n("Group:"), widget);
+ TQLabel *label3 = new TQLabel(i18n("&Name:"), widget);
+ TQLabel *grouplabel = new TQLabel(groupname, widget);
+ TQLabel *label4 = new TQLabel(i18n("Include *-&version:"), widget);
m_edName = new KLineEdit(widget);
- m_chStarred = new QCheckBox(widget);
+ m_chStarred = new TQCheckBox(widget);
grid->addWidget(label2,0,0);
grid->addWidget(grouplabel,0,2);
@@ -90,22 +90,22 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
label3->setBuddy(m_edName);
label4->setBuddy(m_chStarred);
- QWhatsThis::add(grouplabel,i18n("Name of the group, to which this environment or command belongs."));
+ TQWhatsThis::add(grouplabel,i18n("Name of the group, to which this environment or command belongs."));
if ( m_addmode )
- QWhatsThis::add(m_edName,i18n("Name of the new environment or command."));
+ TQWhatsThis::add(m_edName,i18n("Name of the new environment or command."));
else
- QWhatsThis::add(m_edName,i18n("Name of the environment or command to edit."));
- QWhatsThis::add(m_chStarred,i18n("Does this environment or command also exist in a starred version?"));
+ TQWhatsThis::add(m_edName,i18n("Name of the environment or command to edit."));
+ TQWhatsThis::add(m_chStarred,i18n("Does this environment or command also exist in a starred version?"));
int currentRow = 3;
if ( m_useMathOrTab )
{
- QLabel *label5 = new QLabel(i18n("\\\\ is end of &line:"), widget);
- QLabel *label6 = new QLabel(i18n("Needs &math mode:"), widget);
- QLabel *label7 = new QLabel(i18n("&Tabulator:"), widget);
- m_chEndofline = new QCheckBox(widget);
- m_chMath = new QCheckBox(widget);
- m_coTab = new QComboBox(widget);
+ TQLabel *label5 = new TQLabel(i18n("\\\\ is end of &line:"), widget);
+ TQLabel *label6 = new TQLabel(i18n("Needs &math mode:"), widget);
+ TQLabel *label7 = new TQLabel(i18n("&Tabulator:"), widget);
+ m_chEndofline = new TQCheckBox(widget);
+ m_chMath = new TQCheckBox(widget);
+ m_coTab = new TQComboBox(widget);
grid->addWidget(label5,3,0);
grid->addWidget(m_chEndofline,3,2);
@@ -117,11 +117,11 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
label5->setBuddy(m_chEndofline);
label6->setBuddy(m_chMath);
label7->setBuddy(m_coTab);
- QWhatsThis::add(m_chEndofline,i18n("Shall 'Smart New Line' insert \\\\?"));
- QWhatsThis::add(m_chMath,i18n("Does this environment need math mode?"));
- QWhatsThis::add(m_coTab,i18n("Define the standard tabulator of this environment."));
+ TQWhatsThis::add(m_chEndofline,i18n("Shall 'Smart New Line' insert \\\\?"));
+ TQWhatsThis::add(m_chMath,i18n("Does this environment need math mode?"));
+ TQWhatsThis::add(m_coTab,i18n("Define the standard tabulator of this environment."));
- m_coTab->insertItem(QString::null);
+ m_coTab->insertItem(TQString());
m_coTab->insertItem("&");
m_coTab->insertItem("&=");
m_coTab->insertItem("&=&");
@@ -131,23 +131,23 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
if ( m_useOption )
{
- QLabel *label8 = new QLabel(i18n("Opt&ion:"), widget);
- m_coOption = new QComboBox(widget);
+ TQLabel *label8 = new TQLabel(i18n("Opt&ion:"), widget);
+ m_coOption = new TQComboBox(widget);
grid->addWidget(label8,currentRow,0);
grid->addWidget(m_coOption,currentRow,2);
label8->setBuddy(m_coOption);
- m_coOption->insertItem(QString::null);
+ m_coOption->insertItem(TQString());
if ( m_envmode )
{
m_coOption->insertItem("[tcb]");
m_coOption->insertItem("[lcr]");
- QWhatsThis::add(m_coOption,i18n("Define an optional alignment parameter."));
+ TQWhatsThis::add(m_coOption,i18n("Define an optional tqalignment parameter."));
}
else
{
- QWhatsThis::add(m_coOption,i18n("Does this command need an optional parameter."));
+ TQWhatsThis::add(m_coOption,i18n("Does this command need an optional parameter."));
}
m_coOption->insertItem("[ ]");
@@ -156,8 +156,8 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
if ( m_useParameter )
{
- QLabel *label9 = new QLabel(i18n("&Parameter:"), widget);
- m_coParameter = new QComboBox(widget);
+ TQLabel *label9 = new TQLabel(i18n("&Parameter:"), widget);
+ m_coParameter = new TQComboBox(widget);
grid->addWidget(label9,currentRow,0);
grid->addWidget(m_coParameter,currentRow,2);
@@ -165,17 +165,17 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
if ( m_envmode )
{
- m_coParameter->insertItem(QString::null);
+ m_coParameter->insertItem(TQString());
m_coParameter->insertItem("{n}");
m_coParameter->insertItem("{w}");
m_coParameter->insertItem("{ }");
- QWhatsThis::add(m_coParameter,i18n("Does this environment need an additional parameter like {n} for an integer number, {w} for a width or { } for any other parameter?"));
+ TQWhatsThis::add(m_coParameter,i18n("Does this environment need an additional parameter like {n} for an integer number, {w} for a width or { } for any other parameter?"));
}
else
{
m_coParameter->insertItem("{ }");
- // m_coParameter->insertItem(QString::null);
- QWhatsThis::add(m_coParameter,i18n("Does this command need an argument?"));
+ // m_coParameter->insertItem(TQString());
+ TQWhatsThis::add(m_coParameter,i18n("Does this command need an argument?"));
}
currentRow++;
@@ -187,7 +187,7 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
// add or edit mode
if ( m_addmode ) // add mode
{
- QString pattern;
+ TQString pattern;
if ( m_envmode )
{
label1->setText( i18n("Define a new LaTeX environment:") );
@@ -198,8 +198,8 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
label1->setText( i18n("Define a new LaTeX command:") );
pattern = "\\\\?[A-Za-z]+";
}
- QRegExp reg(pattern);
- m_edName->setValidator( new QRegExpValidator(reg,m_edName) );
+ TQRegExp reg(pattern);
+ m_edName->setValidator( new TQRegExpValidator(reg,TQT_TQOBJECT(m_edName)) );
m_edName->setFocus();
}
else // edit mode
@@ -234,14 +234,14 @@ NewLatexCommand::NewLatexCommand(QWidget *parent, const QString &caption,
}
// fill vbox
- vbox->addWidget(label1,0,Qt::AlignHCenter);
+ vbox->addWidget(label1,0,TQt::AlignHCenter);
vbox->addWidget(group);
vbox->addStretch();
}
// get all attributes of this command
-void NewLatexCommand::getParameter(QString &name, KileDocument::LatexCmdAttributes &attr)
+void NewLatexCommand::getParameter(TQString &name, KileDocument::LatexCmdAttributes &attr)
{
name = m_edName->text();
if ( m_envmode==false && name.at(0)!='\\' )
@@ -265,11 +265,11 @@ void NewLatexCommand::getParameter(QString &name, KileDocument::LatexCmdAttribut
attr.cr = false;
attr.mathmode = false;
attr.displaymathmode = false;
- attr.tabulator = QString::null;
+ attr.tabulator = TQString();
}
- attr.option = ( m_useOption ) ? m_coOption->currentText() : QString::null;
- attr.parameter = ( m_useParameter ) ? m_coParameter->currentText() : QString::null;
+ attr.option = ( m_useOption ) ? m_coOption->currentText() : TQString();
+ attr.parameter = ( m_useParameter ) ? m_coParameter->currentText() : TQString();
}
void NewLatexCommand::slotOk()
@@ -281,12 +281,12 @@ void NewLatexCommand::slotOk()
return;
}
- QString name = m_edName->text();
+ TQString name = m_edName->text();
if ( m_envmode==false && name.at(0)!='\\' )
name.prepend('\\');
- if ( m_addmode && m_dict->contains(name) ) {
- QString msg = ( m_envmode ) ? i18n("This environment already exists.")
+ if ( m_addmode && m_dict->tqcontains(name) ) {
+ TQString msg = ( m_envmode ) ? i18n("This environment already exists.")
: i18n("This command already exists.");
KMessageBox::error( this,msg );
return;
@@ -300,22 +300,22 @@ void NewLatexCommand::slotOk()
//BEGIN LatexCommandsDialog
-LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCommands *commands, QWidget *parent, const char *name)
- : KDialogBase( parent,name, true, i18n("LaTeX Configuration"), Ok | Cancel | Help, Ok, true ),
+LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCommands *commands, TQWidget *tqparent, const char *name)
+ : KDialogBase( tqparent,name, true, i18n("LaTeX Configuration"), Ok | Cancel | Help, Ok, true ),
m_config(config), m_commands(commands)
{
- QWidget *page = new QWidget( this );
+ TQWidget *page = new TQWidget( this );
setMainWidget(page);
- QGridLayout *grid = new QGridLayout(page, 7,3, 6,spacingHint());
- QLabel *label = new QLabel(i18n("Define LaTeX Environments and Commands for Kile"), page);
+ TQGridLayout *grid = new TQGridLayout(page, 7,3, 6,spacingHint());
+ TQLabel *label = new TQLabel(i18n("Define LaTeX Environments and Commands for Kile"), page);
// create TabWidget
- m_tab = new QTabWidget(page);
- m_cbUserDefined = new QCheckBox(i18n("&Show only user defined environments and commands"),page);
+ m_tab = new TQTabWidget(page);
+ m_cbUserDefined = new TQCheckBox(i18n("&Show only user defined environments and commands"),page);
// page 1: environment listview
- QWidget *page1 = new QWidget(m_tab);
+ TQWidget *page1 = new TQWidget(m_tab);
m_lvEnvironments = new KListView(page1);
m_lvEnvironments->setRootIsDecorated(true);
m_lvEnvironments->addColumn(i18n("Environment"));
@@ -326,16 +326,16 @@ LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCom
m_lvEnvironments->addColumn(i18n("Option"));
m_lvEnvironments->addColumn(i18n("Parameter"));
m_lvEnvironments->setAllColumnsShowFocus(true);
- m_lvEnvironments->setSelectionMode(QListView::Single);
+ m_lvEnvironments->setSelectionMode(TQListView::Single);
- QGridLayout *grid1 = new QGridLayout(page1, 1,1, 10,10);
+ TQGridLayout *grid1 = new TQGridLayout(page1, 1,1, 10,10);
grid1->addWidget(m_lvEnvironments,0,0);
for ( int col=1; col<=6; col++ )
- m_lvEnvironments->setColumnAlignment(col,Qt::AlignHCenter);
+ m_lvEnvironments->setColumnAlignment(col,TQt::AlignHCenter);
// page 2: command listview
- QWidget *page2 = new QWidget(m_tab);
+ TQWidget *page2 = new TQWidget(m_tab);
m_lvCommands = new KListView(page2);
m_lvCommands->setRootIsDecorated(true);
m_lvCommands->addColumn(i18n("Command"));
@@ -343,13 +343,13 @@ LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCom
m_lvCommands->addColumn(i18n("Option"));
m_lvCommands->addColumn(i18n("Parameter"));
m_lvCommands->setAllColumnsShowFocus(true);
- m_lvCommands->setSelectionMode(QListView::Single);
+ m_lvCommands->setSelectionMode(TQListView::Single);
- QGridLayout *grid2 = new QGridLayout(page2, 1,1, 10,10);
+ TQGridLayout *grid2 = new TQGridLayout(page2, 1,1, 10,10);
grid2->addWidget(m_lvCommands,0,0);
for ( int col=1; col<=3; col++ )
- m_lvCommands->setColumnAlignment(col,Qt::AlignHCenter);
+ m_lvCommands->setColumnAlignment(col,TQt::AlignHCenter);
// add all pages to TabWidget
m_tab->addTab(page1,i18n("&Environments"));
@@ -362,7 +362,7 @@ LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCom
m_btnEdit = new KPushButton(i18n("&Edit..."), page);
// add to grid
- grid->addMultiCellWidget(label,0,0,0,2, Qt::AlignHCenter);
+ grid->addMultiCellWidget(label,0,0,0,2, TQt::AlignHCenter);
grid->addMultiCellWidget(m_tab,1,5,0,0);
grid->addWidget(m_cbUserDefined,6,0); // grid --> 7
grid->addWidget(m_btnAdd,2,2);
@@ -377,18 +377,18 @@ LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCom
setButtonText(Help,"Default Settings");
slotEnableButtons();
- QWhatsThis::add(m_lvEnvironments,i18n("List of known environments with a lot of additional information, which Kile could perhaps use. You can add your own environments, which will be recognized by autocompletion of environments, 'Smart Newline' and 'Smart Tabulator' for example. Of course you can only edit and delete user defined environments."));
- QWhatsThis::add(m_btnAdd,i18n("Add a new environment."));
- QWhatsThis::add(m_btnDelete,i18n("Delete an user defined environment."));
- QWhatsThis::add(m_btnEdit,i18n("Edit an user defined environment."));
+ TQWhatsThis::add(m_lvEnvironments,i18n("List of known environments with a lot of additional information, which Kile could perhaps use. You can add your own environments, which will be recognized by autocompletion of environments, 'Smart Newline' and 'Smart Tabulator' for example. Of course you can only edit and delete user defined environments."));
+ TQWhatsThis::add(m_btnAdd,i18n("Add a new environment."));
+ TQWhatsThis::add(m_btnDelete,i18n("Delete an user defined environment."));
+ TQWhatsThis::add(m_btnEdit,i18n("Edit an user defined environment."));
- connect(m_tab,SIGNAL(currentChanged(QWidget*)),this,SLOT(slotPageChanged(QWidget*)));
- connect(m_lvEnvironments, SIGNAL(selectionChanged()),this, SLOT(slotEnableButtons()));
- connect(m_lvCommands, SIGNAL(selectionChanged()),this, SLOT(slotEnableButtons()));
- connect(m_btnAdd, SIGNAL(clicked()),this, SLOT(slotAddClicked()));
- connect(m_btnDelete, SIGNAL(clicked()),this, SLOT(slotDeleteClicked()));
- connect(m_btnEdit, SIGNAL(clicked()),this, SLOT(slotEditClicked()));
- connect(m_cbUserDefined, SIGNAL(clicked()),this, SLOT(slotUserDefinedClicked()));
+ connect(m_tab,TQT_SIGNAL(currentChanged(TQWidget*)),this,TQT_SLOT(slotPageChanged(TQWidget*)));
+ connect(m_lvEnvironments, TQT_SIGNAL(selectionChanged()),this, TQT_SLOT(slotEnableButtons()));
+ connect(m_lvCommands, TQT_SIGNAL(selectionChanged()),this, TQT_SLOT(slotEnableButtons()));
+ connect(m_btnAdd, TQT_SIGNAL(clicked()),this, TQT_SLOT(slotAddClicked()));
+ connect(m_btnDelete, TQT_SIGNAL(clicked()),this, TQT_SLOT(slotDeleteClicked()));
+ connect(m_btnEdit, TQT_SIGNAL(clicked()),this, TQT_SLOT(slotEditClicked()));
+ connect(m_cbUserDefined, TQT_SIGNAL(clicked()),this, TQT_SLOT(slotUserDefinedClicked()));
// read config and initialize changes (add, edit or delete an entry)
readConfig();
@@ -398,7 +398,7 @@ LatexCommandsDialog::LatexCommandsDialog(KConfig *config, KileDocument::LatexCom
resetListviews();
slotEnableButtons();
- resize(sizeHint().width()+20,sizeHint().height()+50);
+ resize(tqsizeHint().width()+20,tqsizeHint().height()+50);
}
////////////////////////////// listview //////////////////////////////
@@ -420,8 +420,8 @@ void LatexCommandsDialog::resetListviews()
m_lviCitations = new KListViewItem(m_lvCommands,i18n("Citations"));
m_lviInputs = new KListViewItem(m_lvCommands,i18n("Includes"));
- QStringList list;
- QStringList::ConstIterator it;
+ TQStringList list;
+ TQStringList::ConstIterator it;
KileDocument::LatexCmdAttributes attr;
m_commands->commandList(list,KileDocument::CmdAttrNone,m_cbUserDefined->isChecked());
@@ -429,20 +429,20 @@ void LatexCommandsDialog::resetListviews()
{
if ( m_commands->commandAttributes(*it,attr) )
{
- KListViewItem *parent;
+ KListViewItem *tqparent;
switch ( attr.type ) {
- case KileDocument::CmdAttrAmsmath: parent = m_lviAmsmath; break;
- case KileDocument::CmdAttrMath: parent = m_lviMath; break;
- case KileDocument::CmdAttrList: parent = m_lviList; break;
- case KileDocument::CmdAttrTabular: parent = m_lviTabular; break;
- case KileDocument::CmdAttrVerbatim: parent = m_lviVerbatim; break;
- case KileDocument::CmdAttrLabel: parent = m_lviLabels; break;
- case KileDocument::CmdAttrReference: parent = m_lviReferences; break;
- case KileDocument::CmdAttrCitations: parent = m_lviCitations; break;
- case KileDocument::CmdAttrIncludes: parent = m_lviInputs; break;
+ case KileDocument::CmdAttrAmsmath: tqparent = m_lviAmsmath; break;
+ case KileDocument::CmdAttrMath: tqparent = m_lviMath; break;
+ case KileDocument::CmdAttrList: tqparent = m_lviList; break;
+ case KileDocument::CmdAttrTabular: tqparent = m_lviTabular; break;
+ case KileDocument::CmdAttrVerbatim: tqparent = m_lviVerbatim; break;
+ case KileDocument::CmdAttrLabel: tqparent = m_lviLabels; break;
+ case KileDocument::CmdAttrReference: tqparent = m_lviReferences; break;
+ case KileDocument::CmdAttrCitations: tqparent = m_lviCitations; break;
+ case KileDocument::CmdAttrIncludes: tqparent = m_lviInputs; break;
default: continue;
}
- setEntry(parent,*it,attr);
+ setEntry(tqparent,*it,attr);
}
}
}
@@ -495,14 +495,14 @@ bool LatexCommandsDialog::isParentItem(KListViewItem *item)
////////////////////////////// entries //////////////////////////////
-void LatexCommandsDialog::setEntry(KListViewItem *parent,const QString &name,
+void LatexCommandsDialog::setEntry(KListViewItem *tqparent,const TQString &name,
KileDocument::LatexCmdAttributes &attr)
{
// set dictionary
m_dictCommands[name] = attr.standard;
// create an item
- KListViewItem *item = new KListViewItem(parent,name);
+ KListViewItem *item = new KListViewItem(tqparent,name);
// always set the starred entry
if ( attr.starred )
@@ -548,7 +548,7 @@ void LatexCommandsDialog::getEntry(KListViewItem *item,KileDocument::LatexCmdAtt
attr.cr = false;
attr.mathmode = false;
attr.displaymathmode = false;
- attr.tabulator = QString::null;
+ attr.tabulator = TQString();
attr.option = item->text(2);
attr.parameter = item->text(3);
}
@@ -556,18 +556,18 @@ void LatexCommandsDialog::getEntry(KListViewItem *item,KileDocument::LatexCmdAtt
////////////////////////////// type of environment or command //////////////////////////////
-bool LatexCommandsDialog::isUserDefined(const QString &name)
+bool LatexCommandsDialog::isUserDefined(const TQString &name)
{
- return ( m_dictCommands.contains(name) && m_dictCommands[name]==false );
+ return ( m_dictCommands.tqcontains(name) && m_dictCommands[name]==false );
}
// look for user defined environment or commands in this listview
bool LatexCommandsDialog::hasUserDefined(KListView *listview)
{
- for ( QListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() )
+ for ( TQListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() )
{
- for ( QListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling() )
+ for ( TQListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling() )
{
if ( isUserDefined(curchild->text(0)) )
return true;
@@ -578,7 +578,7 @@ bool LatexCommandsDialog::hasUserDefined(KListView *listview)
////////////////////////////// slots //////////////////////////////
-void LatexCommandsDialog::slotPageChanged(QWidget *)
+void LatexCommandsDialog::slotPageChanged(TQWidget *)
{
slotEnableButtons();
}
@@ -614,7 +614,7 @@ void LatexCommandsDialog::slotEnableButtons()
void LatexCommandsDialog::slotAddClicked()
{
KListView *listview;
- QString caption;
+ TQString caption;
bool envmode;
if ( getListviewMode() == lvEnvMode )
@@ -643,16 +643,16 @@ void LatexCommandsDialog::slotAddClicked()
// add a new environment or command
NewLatexCommand *dialog = new NewLatexCommand(this,caption,item->text(0),0L,type,&m_dictCommands);
- if ( dialog->exec() == QDialog::Accepted )
+ if ( dialog->exec() == TQDialog::Accepted )
{
m_commandChanged = true;
// insert new item with attributes
- QString name;
+ TQString name;
KileDocument::LatexCmdAttributes attr;
dialog->getParameter(name,attr);
setEntry((KListViewItem *)item,name,attr);
- // open this parent item
+ // open this tqparent item
if ( !item->isOpen() )
{
item->setOpen(true);
@@ -666,7 +666,7 @@ void LatexCommandsDialog::slotAddClicked()
void LatexCommandsDialog::slotDeleteClicked()
{
KListView *listview;
- QString message;
+ TQString message;
if ( getListviewMode() == lvEnvMode )
{
@@ -697,7 +697,7 @@ void LatexCommandsDialog::slotDeleteClicked()
void LatexCommandsDialog::slotEditClicked()
{
KListView *listview;
- QString caption;
+ TQString caption;
if ( getListviewMode() == lvEnvMode )
{
@@ -713,11 +713,11 @@ void LatexCommandsDialog::slotEditClicked()
KListViewItem *item = (KListViewItem *)listview->selectedItem();
if ( item && !isParentItem(item) )
{
- KListViewItem *parentitem = (KListViewItem *)item->parent();
- if ( parentitem )
+ KListViewItem *tqparentitem = (KListViewItem *)item->tqparent();
+ if ( tqparentitem )
{
// get current command type
- KileDocument::CmdAttribute type = getCommandMode(parentitem);
+ KileDocument::CmdAttribute type = getCommandMode(tqparentitem);
if ( type == KileDocument::CmdAttrNone )
{
KILE_DEBUG() << "\tLatexCommandsDialog error: no item in slotAddClicked() (" << item->text(0) << ")" << endl;
@@ -725,18 +725,18 @@ void LatexCommandsDialog::slotEditClicked()
}
// edit a new environment or command
- NewLatexCommand *dialog = new NewLatexCommand(this,caption,parentitem->text(0),item,type, &m_dictCommands);
- if ( dialog->exec() == QDialog::Accepted )
+ NewLatexCommand *dialog = new NewLatexCommand(this,caption,tqparentitem->text(0),item,type, &m_dictCommands);
+ if ( dialog->exec() == TQDialog::Accepted )
{
m_commandChanged = true;
// delete old item
delete item;
// insert new item with changed attributes
- QString name;
+ TQString name;
KileDocument::LatexCmdAttributes attr;
dialog->getParameter(name,attr);
- setEntry(parentitem,name,attr);
+ setEntry(tqparentitem,name,attr);
}
delete dialog;
}
@@ -756,8 +756,8 @@ void LatexCommandsDialog::slotUserDefinedClicked()
void LatexCommandsDialog::slotHelp()
{
- QString mode = ( getListviewMode() == lvEnvMode ) ? i18n("'environment'") : i18n("'command'");
- if ( KMessageBox::warningContinueCancel(this, i18n("All your %1 settings will be overwritten with the default settings, are you sure you want to continue?").arg(mode)) == KMessageBox::Continue )
+ TQString mode = ( getListviewMode() == lvEnvMode ) ? i18n("'environment'") : i18n("'command'");
+ if ( KMessageBox::warningContinueCancel(this, i18n("All your %1 settings will be overwritten with the default settings, are you sure you want to continue?").tqarg(mode)) == KMessageBox::Continue )
{
if ( getListviewMode() == lvEnvMode )
resetEnvironments();
@@ -796,7 +796,7 @@ void LatexCommandsDialog::readConfig()
m_cbUserDefined->setChecked( KileConfig::showUserCommands() );
}
-void LatexCommandsDialog::writeConfig(KListView *listview, const QString &groupname, bool env)
+void LatexCommandsDialog::writeConfig(KListView *listview, const TQString &groupname, bool env)
{
// first delete old entries
if ( m_config->hasGroup(groupname) )
@@ -810,24 +810,24 @@ void LatexCommandsDialog::writeConfig(KListView *listview, const QString &groupn
attr.standard = false;
// scan the listview for non standard entries
- for ( QListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() )
+ for ( TQListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() )
{
- // get the type of the parent entry
+ // get the type of the tqparent entry
attr.type = getCommandMode((KListViewItem *)cur);
if ( attr.type == KileDocument::CmdAttrNone )
{
- KILE_DEBUG() << "\tLatexCommandsDialog error: no parent item (" << cur->text(0) << ")" << endl;
+ KILE_DEBUG() << "\tLatexCommandsDialog error: no tqparent item (" << cur->text(0) << ")" << endl;
continue;
}
- // look for children
- for ( QListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling() )
+ // look for tqchildren
+ for ( TQListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling() )
{
- QString key = curchild->text(0);
+ TQString key = curchild->text(0);
if ( isUserDefined(key) )
{
getEntry((KListViewItem *)curchild,attr);
- QString value = m_commands->configString(attr,env);
+ TQString value = m_commands->configString(attr,env);
KILE_DEBUG() << "\tLatexCommandsDialog write config: " << key << " --> " << value << endl;
if ( ! value.isEmpty() )
m_config->writeEntry(key,value);
@@ -874,7 +874,7 @@ void LatexCommandsDialog::resetCommands()
setListviewStates(states);
}
-// states of all parent items
+// states of all tqparent items
void LatexCommandsDialog::getListviewStates(bool states[])
{
diff --git a/src/kile/latexcmddialog.h b/src/kile/latexcmddialog.h
index 345a1cd..4258c31 100644
--- a/src/kile/latexcmddialog.h
+++ b/src/kile/latexcmddialog.h
@@ -26,13 +26,13 @@
#include <klistview.h>
#include <kconfig.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qcombobox.h>
-#include <qlistview.h>
-#include <qstringlist.h>
-#include <qtabwidget.h>
-#include <qmap.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqcombobox.h>
+#include <tqlistview.h>
+#include <tqstringlist.h>
+#include <tqtabwidget.h>
+#include <tqmap.h>
#include "latexcmd.h"
@@ -42,23 +42,24 @@ namespace KileDialog
class NewLatexCommand : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- NewLatexCommand(QWidget *parent, const QString &caption,
- const QString &groupname, KListViewItem *lvitem,
- KileDocument::CmdAttribute cmdtype, QMap<QString,bool> *dict);
+ NewLatexCommand(TQWidget *tqparent, const TQString &caption,
+ const TQString &groupname, KListViewItem *lvitem,
+ KileDocument::CmdAttribute cmdtype, TQMap<TQString,bool> *dict);
~NewLatexCommand() {}
- void getParameter(QString &name, KileDocument::LatexCmdAttributes &attr);
+ void getParameter(TQString &name, KileDocument::LatexCmdAttributes &attr);
private:
KLineEdit *m_edName;
- QCheckBox *m_chStarred, *m_chEndofline, *m_chMath;
- QComboBox *m_coTab, *m_coOption, *m_coParameter;
+ TQCheckBox *m_chStarred, *m_chEndofline, *m_chMath;
+ TQComboBox *m_coTab, *m_coOption, *m_coParameter;
bool m_addmode, m_envmode;
bool m_useMathOrTab, m_useOption, m_useParameter;
KileDocument::CmdAttribute m_cmdType;
- QMap<QString,bool> *m_dict;
+ TQMap<TQString,bool> *m_dict;
private slots:
void slotOk();
@@ -68,9 +69,10 @@ private slots:
class LatexCommandsDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- LatexCommandsDialog(KConfig *config, KileDocument::LatexCommands *commands, QWidget *parent=0, const char *name=0);
+ LatexCommandsDialog(KConfig *config, KileDocument::LatexCommands *commands, TQWidget *tqparent=0, const char *name=0);
~LatexCommandsDialog() {}
//enum EnvParameter { envName,envStarred,envEOL,envMath,envTab,envOption };
@@ -80,26 +82,26 @@ private:
KConfig *m_config;
KileDocument::LatexCommands *m_commands;
- QMap<QString,bool> m_dictCommands;
+ TQMap<TQString,bool> m_dictCommands;
bool m_commandChanged;
KListView *m_lvEnvironments, *m_lvCommands;
KListViewItem *m_lviList,*m_lviTabular,*m_lviMath,*m_lviAmsmath,*m_lviVerbatim;
KListViewItem *m_lviLabels,*m_lviReferences,*m_lviCitations;
KListViewItem *m_lviInputs;
- QTabWidget *m_tab;
+ TQTabWidget *m_tab;
KPushButton *m_btnAdd, *m_btnDelete, *m_btnEdit;
- QCheckBox *m_cbUserDefined;
+ TQCheckBox *m_cbUserDefined;
void resetListviews();
LVmode getListviewMode();
KileDocument::CmdAttribute getCommandMode(KListViewItem *item);
bool isParentItem(KListViewItem *item);
- void setEntry(KListViewItem *parent,const QString &name,KileDocument::LatexCmdAttributes &attr);
+ void setEntry(KListViewItem *tqparent,const TQString &name,KileDocument::LatexCmdAttributes &attr);
void getEntry(KListViewItem *item,KileDocument::LatexCmdAttributes &attr);
- bool isUserDefined(const QString &name);
+ bool isUserDefined(const TQString &name);
bool hasUserDefined(KListView *listview);
void resetEnvironments();
@@ -108,10 +110,10 @@ private:
void setListviewStates(bool states[]);
void readConfig();
- void writeConfig(KListView *listview, const QString &groupname, bool env);
+ void writeConfig(KListView *listview, const TQString &groupname, bool env);
private slots:
- void slotPageChanged(QWidget *);
+ void slotPageChanged(TQWidget *);
void slotEnableButtons();
void slotAddClicked();
void slotDeleteClicked();
diff --git a/src/kile/latexconfigwidget.ui b/src/kile/latexconfigwidget.ui
index 28ec181..836a835 100644
--- a/src/kile/latexconfigwidget.ui
+++ b/src/kile/latexconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetLatexConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetLatexConfig</cstring>
</property>
@@ -19,7 +19,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_bgCommands</cstring>
</property>
@@ -30,7 +30,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QPushButton" row="0" column="0">
+ <widget class="TQPushButton" row="0" column="0">
<property name="name">
<cstring>m_pbCommands</cstring>
</property>
@@ -38,7 +38,7 @@
<string>Configure...</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="1">
+ <widget class="TQLabel" row="0" column="1">
<property name="name">
<cstring>m_tlCommands</cstring>
</property>
@@ -56,7 +56,7 @@
</widget>
</grid>
</widget>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_bgQuotes</cstring>
</property>
@@ -75,7 +75,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>m_tlType</cstring>
</property>
@@ -86,7 +86,7 @@
<cstring>kcfg_DoubleQuotes</cstring>
</property>
</widget>
- <widget class="QCheckBox" row="0" column="0" rowspan="1" colspan="3">
+ <widget class="TQCheckBox" row="0" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>kcfg_InsertDoubleQuotes</cstring>
</property>
@@ -94,7 +94,7 @@
<string>Automatically insert opening and closing double &amp;quotes for LaTeX</string>
</property>
</widget>
- <widget class="QComboBox" row="1" column="1">
+ <widget class="TQComboBox" row="1" column="1">
<property name="name">
<cstring>kcfg_DoubleQuotes</cstring>
</property>
@@ -117,7 +117,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>280</width>
<height>20</height>
@@ -126,7 +126,7 @@
</spacer>
</grid>
</widget>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_bgMathmode</cstring>
</property>
@@ -137,7 +137,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_autoInsertDollar</cstring>
</property>
@@ -150,7 +150,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox5</cstring>
</property>
@@ -161,7 +161,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_tlPath</cstring>
</property>
@@ -190,7 +190,7 @@
<cstring>kcfg_BstInputPaths</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>m_bibinputpath</cstring>
</property>
@@ -204,7 +204,7 @@
<string></string>
</property>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>m_bstinputpath</cstring>
</property>
@@ -242,14 +242,14 @@
<variable access="private">KConfig *m_config;</variable>
<variable access="private">KileDocument::LatexCommands *m_commands;</variable>
</variables>
-<slots>
+<Q_SLOTS>
<slot access="private" specifier="non virtual">slotConfigure()</slot>
-</slots>
+</Q_SLOTS>
<functions>
<function access="private" specifier="non virtual">init()</function>
<function specifier="non virtual">setLatexCommands( KConfig * config, KileDocument::LatexCommands * commands )</function>
</functions>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
<includehint>klineedit.h</includehint>
diff --git a/src/kile/latexconfigwidget.ui.h b/src/kile/latexconfigwidget.ui.h
index 6fd456d..d152918 100644
--- a/src/kile/latexconfigwidget.ui.h
+++ b/src/kile/latexconfigwidget.ui.h
@@ -2,7 +2,7 @@
** ui.h extension file, included from the uic-generated form implementation.
**
** If you want to add, delete, or rename functions or slots, use
-** Qt Designer to update this file, preserving your code.
+** TQt Designer to update this file, preserving your code.
**
** You should not define a constructor or destructor in this file.
** Instead, write your code in functions called init() and destroy().
@@ -13,12 +13,12 @@
void KileWidgetLatexConfig::init()
{
- int w = m_tlType->sizeHint().width();
+ int w = m_tlType->tqsizeHint().width();
- int wi = m_tlPath->sizeHint().width();
+ int wi = m_tlPath->tqsizeHint().width();
if ( wi > w ) w = wi;
- wi = m_pbCommands->sizeHint().width();
+ wi = m_pbCommands->tqsizeHint().width();
if ( wi > w ) w = wi;
w += 8;
diff --git a/src/kile/latexoutputfilter.cpp b/src/kile/latexoutputfilter.cpp
index 8bec577..17f2008 100644
--- a/src/kile/latexoutputfilter.cpp
+++ b/src/kile/latexoutputfilter.cpp
@@ -18,9 +18,9 @@
#include "latexoutputfilter.h"
-#include <qfile.h>
-#include <qregexp.h>
-#include <qfileinfo.h>
+#include <tqfile.h>
+#include <tqregexp.h>
+#include <tqfileinfo.h>
#include "kiledebug.h"
#include <ktextedit.h>
@@ -53,9 +53,9 @@ bool LatexOutputFilter::OnPreCreate()
}
-bool LatexOutputFilter::fileExists(const QString & name)
+bool LatexOutputFilter::fileExists(const TQString & name)
{
- static QFileInfo::QFileInfo fi;
+ static TQFileInfo::TQFileInfo fi;
if (name[0] == '/' )
{
@@ -71,8 +71,8 @@ bool LatexOutputFilter::fileExists(const QString & name)
if ( fi.exists() && !fi.isDir() ) return true;
// try to determine the LaTeX source file
- QStringList extlist = QStringList::split(" ", m_extensions->latexDocuments() );
- for ( QStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
+ TQStringList extlist = TQStringList::split(" ", m_extensions->latexDocuments() );
+ for ( TQStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
{
fi.setFile( path() + '/' + name + (*it) );
if ( fi.exists() && !fi.isDir() )
@@ -91,17 +91,17 @@ bool LatexOutputFilter::fileExists(const QString & name)
// 2) Since people will probably also use the \input command, we also have to be
// to detect the old-fashioned way. TeX prints '(filename' when opening a file and a ')'
// when closing one. It is impossible to detect this with 100% certainty (TeX prints many messages
-// and even text (a context) from the TeX source file, there could be unbalanced parentheses),
+// and even text (a context) from the TeX source file, there could be unbalanced tqparentheses),
// so we use a heuristic algorithm. In heuristic mode a ')' will only be considered as a signal that
// TeX is closing a file if the top of the stack is not marked as "reliable".
// Also, when scanning for a TeX error linenumber (which sometimes causes a context to be printed
-// to the log-file), updateFileStack is not called, helping not to pick up unbalanced parentheses
+// to the log-file), updateFileStack is not called, helping not to pick up unbalanced tqparentheses
// from the context.
-void LatexOutputFilter::updateFileStack(const QString &strLine, short & dwCookie)
+void LatexOutputFilter::updateFileStack(const TQString &strLine, short & dwCookie)
{
//KILE_DEBUG() << "==LatexOutputFilter::updateFileStack()================" << endl;
- static QString::QString strPartialFileName;
+ static TQString::TQString strPartialFileName;
switch (dwCookie)
{
@@ -138,7 +138,7 @@ void LatexOutputFilter::updateFileStack(const QString &strLine, short & dwCookie
//push the filename on the stack and mark it as 'reliable'
m_stackFile.push(LOFStackItem(strPartialFileName, true));
// KILE_DEBUG() << "\tpushed : " << strPartialFileName << endl;
- strPartialFileName = QString::null;
+ strPartialFileName = TQString();
dwCookie = Start;
}
//The partial filename was followed by an TeX error, meaning the file doesn't exist.
@@ -147,14 +147,14 @@ void LatexOutputFilter::updateFileStack(const QString &strLine, short & dwCookie
{
// KILE_DEBUG() << "oops!" << endl;
dwCookie = Start;
- strPartialFileName = QString::null;
+ strPartialFileName = TQString();
detectError(strLine, dwCookie);
}
else if ( strLine.startsWith("No file") )
{
// KILE_DEBUG() << "No file: " << strLine << endl;
dwCookie = Start;
- strPartialFileName = QString::null;
+ strPartialFileName = TQString();
detectWarning(strLine, dwCookie);
}
//Partial filename still isn't complete.
@@ -169,10 +169,10 @@ void LatexOutputFilter::updateFileStack(const QString &strLine, short & dwCookie
}
}
-void LatexOutputFilter::updateFileStackHeuristic(const QString &strLine, short & dwCookie)
+void LatexOutputFilter::updateFileStackHeuristic(const TQString &strLine, short & dwCookie)
{
//KILE_DEBUG() << "==LatexOutputFilter::updateFileStackHeuristic()================" << endl;
- static QString::QString strPartialFileName;
+ static TQString::TQString strPartialFileName;
bool expectFileName = (dwCookie == FileNameHeuristic);
int index = 0;
@@ -183,7 +183,7 @@ void LatexOutputFilter::updateFileStackHeuristic(const QString &strLine, short &
dwCookie = Start;
}
- //scan for parentheses and grab filenames
+ //scan for tqparentheses and grab filenames
for (unsigned int i = 0; i < strLine.length(); ++i) {
//We're expecting a filename. If a filename really ends at this position one of the following must be true:
// 1) Next character is a space (indicating the end of a filename (yes, there can't spaces in the
@@ -212,7 +212,7 @@ void LatexOutputFilter::updateFileStackHeuristic(const QString &strLine, short &
//bail out
else {
dwCookie = Start;
- strPartialFileName = QString::null;
+ strPartialFileName = TQString();
expectFileName = false;
}
}
@@ -220,7 +220,7 @@ void LatexOutputFilter::updateFileStackHeuristic(const QString &strLine, short &
else if(strLine[i] == '(') {
//we need to extract the filename
expectFileName = true;
- strPartialFileName = QString::null;
+ strPartialFileName = TQString();
dwCookie = Start;
//this is were the filename is supposed to start
@@ -276,16 +276,16 @@ void LatexOutputFilter::flushCurrentItem()
m_currentItem.Clear();
}
-bool LatexOutputFilter::detectError(const QString & strLine, short &dwCookie)
+bool LatexOutputFilter::detectError(const TQString & strLine, short &dwCookie)
{
//KILE_DEBUG() << "==LatexOutputFilter::detectError(" << strLine.length() << ")================" << endl;
bool found = false, flush = false;
- static QRegExp::QRegExp reLaTeXError("^! LaTeX Error: (.*)$", false);
- static QRegExp::QRegExp rePDFLaTeXError("^Error: pdflatex (.*)$", false);
- static QRegExp::QRegExp reTeXError("^! (.*)");
- static QRegExp::QRegExp reLineNumber("^l\\.([0-9]+)(.*)");
+ static TQRegExp::TQRegExp reLaTeXError("^! LaTeX Error: (.*)$", false);
+ static TQRegExp::TQRegExp rePDFLaTeXError("^Error: pdflatex (.*)$", false);
+ static TQRegExp::TQRegExp reTeXError("^! (.*)");
+ static TQRegExp::TQRegExp reLineNumber("^l\\.([0-9]+)(.*)");
switch (dwCookie)
{
@@ -363,16 +363,16 @@ bool LatexOutputFilter::detectError(const QString & strLine, short &dwCookie)
return found;
}
-bool LatexOutputFilter::detectWarning(const QString & strLine, short &dwCookie)
+bool LatexOutputFilter::detectWarning(const TQString & strLine, short &dwCookie)
{
//KILE_DEBUG() << "==LatexOutputFilter::detectWarning(" << strLine.length() << ")================" << endl;
bool found = false, flush = false;
- QString warning;
+ TQString warning;
- static QRegExp::QRegExp reLaTeXWarning("^(((! )?(La|pdf)TeX)|Package) .*Warning.*:(.*)", false);
- static QRegExp::QRegExp reNoFile("No file (.*)");
- static QRegExp::QRegExp reNoAsyFile("File .* does not exist."); // FIXME can be removed when http://sourceforge.net/tracker/index.php?func=detail&aid=1772022&group_id=120000&atid=685683 has promoted to the users
+ static TQRegExp::TQRegExp reLaTeXWarning("^(((! )?(La|pdf)TeX)|Package) .*Warning.*:(.*)", false);
+ static TQRegExp::TQRegExp reNoFile("No file (.*)");
+ static TQRegExp::TQRegExp reNoAsyFile("File .* does not exist."); // FIXME can be removed when http://sourceforge.net/tracker/index.php?func=detail&aid=1772022&group_id=120000&atid=685683 has promoted to the users
switch (dwCookie)
{
@@ -433,12 +433,12 @@ bool LatexOutputFilter::detectWarning(const QString & strLine, short &dwCookie)
return found;
}
-bool LatexOutputFilter::detectLaTeXLineNumber(QString & warning, short & dwCookie, int len)
+bool LatexOutputFilter::detectLaTeXLineNumber(TQString & warning, short & dwCookie, int len)
{
//KILE_DEBUG() << "==LatexOutputFilter::detectLaTeXLineNumber(" << warning.length() << ")================" << endl;
- static QRegExp::QRegExp reLaTeXLineNumber("(.*) on input line ([0-9]+)\\.$", false);
- static QRegExp::QRegExp reInternationalLaTeXLineNumber("(.*)([0-9]+)\\.$", false);
+ static TQRegExp::TQRegExp reLaTeXLineNumber("(.*) on input line ([0-9]+)\\.$", false);
+ static TQRegExp::TQRegExp reInternationalLaTeXLineNumber("(.*)([0-9]+)\\.$", false);
if ( (reLaTeXLineNumber.search(warning) != -1) || (reInternationalLaTeXLineNumber.search(warning) != -1) )
{
//KILE_DEBUG() << "een" << endl;
@@ -471,14 +471,14 @@ bool LatexOutputFilter::detectLaTeXLineNumber(QString & warning, short & dwCooki
}
}
-bool LatexOutputFilter::detectBadBox(const QString & strLine, short & dwCookie)
+bool LatexOutputFilter::detectBadBox(const TQString & strLine, short & dwCookie)
{
//KILE_DEBUG() << "==LatexOutputFilter::detectBadBox(" << strLine.length() << ")================" << endl;
bool found = false, flush = false;
- QString badbox;
+ TQString badbox;
- static QRegExp::QRegExp reBadBox("^(Over|Under)(full \\\\[hv]box .*)", false);
+ static TQRegExp::TQRegExp reBadBox("^(Over|Under)(full \\\\[hv]box .*)", false);
switch (dwCookie)
{
@@ -513,15 +513,15 @@ bool LatexOutputFilter::detectBadBox(const QString & strLine, short & dwCookie)
return found;
}
-bool LatexOutputFilter::detectBadBoxLineNumber(QString & strLine, short & dwCookie, int len)
+bool LatexOutputFilter::detectBadBoxLineNumber(TQString & strLine, short & dwCookie, int len)
{
//KILE_DEBUG() << "==LatexOutputFilter::detectBadBoxLineNumber(" << strLine.length() << ")================" << endl;
- static QRegExp::QRegExp reBadBoxLines("(.*) at lines ([0-9]+)--([0-9]+)", false);
- static QRegExp::QRegExp reBadBoxLine("(.*) at line ([0-9]+)", false);
+ static TQRegExp::TQRegExp reBadBoxLines("(.*) at lines ([0-9]+)--([0-9]+)", false);
+ static TQRegExp::TQRegExp reBadBoxLine("(.*) at line ([0-9]+)", false);
//Use the following only, if you know how to get the source line for it.
// This is not simple, as TeX is not reporting it.
- static QRegExp::QRegExp reBadBoxOutput("(.*)has occurred while \\output is active^", false);
+ static TQRegExp::TQRegExp reBadBoxOutput("(.*)has occurred while \\output is active^", false);
if ( reBadBoxLines.search(strLine) != -1)
{
@@ -562,7 +562,7 @@ bool LatexOutputFilter::detectBadBoxLineNumber(QString & strLine, short & dwCook
return false;
}
-short LatexOutputFilter::parseLine(const QString & strLine, short dwCookie)
+short LatexOutputFilter::parseLine(const TQString & strLine, short dwCookie)
{
//KILE_DEBUG() << "==LatexOutputFilter::parseLine(" << strLine.length() << ")================" << endl;
@@ -602,20 +602,20 @@ short LatexOutputFilter::parseLine(const QString & strLine, short dwCookie)
//
// dani 18.02.2005
-bool LatexOutputFilter::Run(const QString & logfile)
+bool LatexOutputFilter::Run(const TQString & logfile)
{
m_InfoList->clear();
m_nErrors = m_nWarnings = m_nBadBoxes = m_nParens = 0;
m_stackFile.clear();
- m_stackFile.push(LOFStackItem(QFileInfo(source()).fileName(), true));
+ m_stackFile.push(LOFStackItem(TQFileInfo(source()).fileName(), true));
return OutputFilter::Run(logfile);
}
-void LatexOutputFilter::updateInfoLists(const QString &texfilename, int selrow, int docrow)
+void LatexOutputFilter::updateInfoLists(const TQString &texfilename, int selrow, int docrow)
{
// get a short name for the original tex file
- QString filename = "./" + QFileInfo(texfilename).fileName();
+ TQString filename = "./" + TQFileInfo(texfilename).fileName();
setSource(texfilename);
//print detailed error info
@@ -633,12 +633,12 @@ void LatexOutputFilter::updateInfoLists(const QString &texfilename, int selrow,
void LatexOutputFilter::sendProblems()
{
- QString Message;
+ TQString Message;
int type;
//print detailed error info
for(unsigned int i=0; i < m_InfoList->count(); ++i) {
- Message = QString("%1:%2:%3").arg((*m_InfoList)[i].source()).arg((*m_InfoList)[i].sourceLine()).arg((*m_InfoList)[i].message());
+ Message = TQString("%1:%2:%3").tqarg((*m_InfoList)[i].source()).tqarg((*m_InfoList)[i].sourceLine()).tqarg((*m_InfoList)[i].message());
switch ( (*m_InfoList)[i].type() )
{
case LatexOutputInfo::itmBadBox : type = KileTool::ProblemBadBox; break;
diff --git a/src/kile/latexoutputfilter.h b/src/kile/latexoutputfilter.h
index dd0097c..0f33952 100644
--- a/src/kile/latexoutputfilter.h
+++ b/src/kile/latexoutputfilter.h
@@ -16,8 +16,8 @@
#ifndef LATEXOUTPUTFILTER_H
#define LATEXOUTPUTFILTER_H
-#include <qvaluestack.h>
-#include <qstring.h>
+#include <tqvaluestack.h>
+#include <tqstring.h>
#include "outputfilter.h"
#include "latexoutputinfo.h"
@@ -35,16 +35,16 @@ class KTextEdit;
class LOFStackItem
{
public:
- LOFStackItem(const QString & file = QString::null, bool sure = false) : m_file(file), m_reliable(sure) {}
+ LOFStackItem(const TQString & file = TQString(), bool sure = false) : m_file(file), m_reliable(sure) {}
- const QString & file() const { return m_file; }
- void setFile(const QString & file) { m_file = file; }
+ const TQString & file() const { return m_file; }
+ void setFile(const TQString & file) { m_file = file; }
bool reliable() const { return m_reliable; }
void setReliable(bool sure) { m_reliable = sure; }
private:
- QString m_file;
+ TQString m_file;
bool m_reliable;
};
@@ -54,9 +54,9 @@ class LatexOutputFilter : public OutputFilter
LatexOutputFilter(LatexOutputInfoArray* LatexOutputInfoArray, KileDocument::Extensions *extensions);
~LatexOutputFilter();
- virtual bool Run(const QString & logfile);
+ virtual bool Run(const TQString & logfile);
void sendProblems();
- void updateInfoLists(const QString &texfilename, int selrow, int docrow);
+ void updateInfoLists(const TQString &texfilename, int selrow, int docrow);
enum {Start = 0, FileName, FileNameHeuristic, Error, Warning, BadBox, LineNumber};
@@ -65,8 +65,8 @@ class LatexOutputFilter : public OutputFilter
Parses the given line for the start of new files or the end of
old files.
*/
- void updateFileStack(const QString &strLine, short & dwCookie);
- void updateFileStackHeuristic(const QString &strLine, short & dwCookie);
+ void updateFileStack(const TQString &strLine, short & dwCookie);
+ void updateFileStackHeuristic(const TQString &strLine, short & dwCookie);
/**
Forwards the currently parsed item to the item list.
@@ -81,15 +81,15 @@ class LatexOutputFilter : public OutputFilter
protected:
virtual bool OnPreCreate();
- virtual short parseLine(const QString & strLine, short dwCookie);
+ virtual short parseLine(const TQString & strLine, short dwCookie);
- bool detectError(const QString & strLine, short &dwCookie);
- bool detectWarning(const QString & strLine, short &dwCookie);
- bool detectBadBox(const QString & strLine, short &dwCookie);
- bool detectLaTeXLineNumber(QString & warning, short & dwCookie, int len);
- bool detectBadBoxLineNumber(QString & strLine, short & dwCookie, int len);
+ bool detectError(const TQString & strLine, short &dwCookie);
+ bool detectWarning(const TQString & strLine, short &dwCookie);
+ bool detectBadBox(const TQString & strLine, short &dwCookie);
+ bool detectLaTeXLineNumber(TQString & warning, short & dwCookie, int len);
+ bool detectBadBoxLineNumber(TQString & strLine, short & dwCookie, int len);
- bool fileExists(const QString & name);
+ bool fileExists(const TQString & name);
private:
@@ -124,7 +124,7 @@ class LatexOutputFilter : public OutputFilter
Stack containing the files parsed by the compiler. The top-most
element is the currently parsed file.
*/
- QValueStack<LOFStackItem> m_stackFile;
+ TQValueStack<LOFStackItem> m_stackFile;
/** The item currently parsed. */
LatexOutputInfo m_currentItem;
diff --git a/src/kile/latexoutputinfo.cpp b/src/kile/latexoutputinfo.cpp
index a32e2d1..7b037b2 100644
--- a/src/kile/latexoutputinfo.cpp
+++ b/src/kile/latexoutputinfo.cpp
@@ -20,8 +20,8 @@ LatexOutputInfo::LatexOutputInfo()
}
-LatexOutputInfo::LatexOutputInfo(const QString & strSrcFile, int nSrcLine, int nOutputLine,
-const QString & strError, int nErrorID)
+LatexOutputInfo::LatexOutputInfo(const TQString & strSrcFile, int nSrcLine, int nOutputLine,
+const TQString & strError, int nErrorID)
{
setSource(strSrcFile);
setSourceLine(nSrcLine);
diff --git a/src/kile/latexoutputinfo.h b/src/kile/latexoutputinfo.h
index bf65a56..6ab09ae 100644
--- a/src/kile/latexoutputinfo.h
+++ b/src/kile/latexoutputinfo.h
@@ -26,7 +26,7 @@ class LatexOutputInfo : public OutputInfo
{
public:
LatexOutputInfo();
- LatexOutputInfo(const QString & strSrcFile, int nSrcLine, int nOutputLine, const QString & strError="", int nErrorID=-1);
+ LatexOutputInfo(const TQString & strSrcFile, int nSrcLine, int nOutputLine, const TQString & strError="", int nErrorID=-1);
/** No descriptions */
LatexOutputInfo operator=(const LatexOutputInfo &a) ;
@@ -48,5 +48,5 @@ class LatexOutputInfo : public OutputInfo
@author Thorsten Lck
*/
-typedef QValueList<LatexOutputInfo> LatexOutputInfoArray;
+typedef TQValueList<LatexOutputInfo> LatexOutputInfoArray;
#endif
diff --git a/src/kile/latextoolconfigwidget.ui b/src/kile/latextoolconfigwidget.ui
index 60ee6ad..296d649 100644
--- a/src/kile/latextoolconfigwidget.ui
+++ b/src/kile/latextoolconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>LaTeXToolConfigWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>LaTeXToolConfigWidget</cstring>
</property>
@@ -27,7 +27,7 @@
<property name="margin">
<number>0</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>m_ckRootDoc</cstring>
</property>
@@ -35,7 +35,7 @@
<string>Check if &amp;root document is a LaTeX root before running LaTeX on it</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>m_ckJump</cstring>
</property>
@@ -43,7 +43,7 @@
<string>&amp;Jump to first error in case running LaTeX failed</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>m_ckAutoRun</cstring>
</property>
@@ -53,5 +53,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/src/kile/librarytoolconfigwidget.ui b/src/kile/librarytoolconfigwidget.ui
index e7a84d9..13d8c14 100644
--- a/src/kile/librarytoolconfigwidget.ui
+++ b/src/kile/librarytoolconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>LibraryToolConfigWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>LibraryToolConfigWidget</cstring>
</property>
@@ -20,7 +20,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -33,7 +33,7 @@
<property name="margin">
<number>0</number>
</property>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>m_lbOptions</cstring>
</property>
@@ -59,7 +59,7 @@
<cstring>m_leOptions</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>m_lbLibClass</cstring>
</property>
@@ -70,7 +70,7 @@
<cstring>m_leLibClass</cstring>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbLibrary</cstring>
</property>
@@ -91,7 +91,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -100,5 +100,5 @@
</spacer>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/src/kile/main.cpp b/src/kile/main.cpp
index b73325c..4b73474 100644
--- a/src/kile/main.cpp
+++ b/src/kile/main.cpp
@@ -13,8 +13,8 @@
* *
***************************************************************************/
-#include <qdir.h>
-#include <qfile.h>
+#include <tqdir.h>
+#include <tqfile.h>
#include <kcmdlineargs.h>
#include <kaboutdata.h>
@@ -41,7 +41,7 @@ static KCmdLineOptions options[] =
KCmdLineLastOption
};
-bool isProject(const QString &path)
+bool isProject(const TQString &path)
{
return path.right(7) == ".kilepr";
}
@@ -50,9 +50,9 @@ bool isProject(const QString &path)
* Complete a relative paths to absolute ones.
* Also accepts URLs of the form file:relativepath.
**/
-QString completePath(const QString &path)
+TQString completePath(const TQString &path)
{
- QString fullpath(path);
+ TQString fullpath(path);
KILE_DEBUG() << "==complete path is " << path << endl;
if ( path.left(1) != "/" )
@@ -63,8 +63,8 @@ QString completePath(const QString &path)
url.setFileName(completePath(url.path()));
fullpath = url.url();
}
- else if ( path.find(QRegExp("^[a-z]+:")) == -1 )
- fullpath = QDir::currentDirPath() + '/' + path;
+ else if ( path.tqfind(TQRegExp("^[a-z]+:")) == -1 )
+ fullpath = TQDir::currentDirPath() + '/' + path;
}
KILE_DEBUG() << "\t" << fullpath << endl;
@@ -97,14 +97,14 @@ int main( int argc, char ** argv )
bool running = false;
DCOPClient *client=0L;
- QCString appID = "";
+ TQCString appID = "";
client = new DCOPClient ();
client->attach();
QCStringList apps = client->registeredApplications();
for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it )
{
- if ((*it).contains ("kile") > 0)
+ if ((*it).tqcontains ("kile") > 0)
{
appID = (*it);
running = true;
@@ -123,12 +123,12 @@ int main( int argc, char ** argv )
for ( int i = 0; i < args->count(); ++i)
{
if ( isProject(args->arg(i)) )
- mw->openProject(completePath(QFile::decodeName(args->arg(i))));
+ mw->openProject(completePath(TQFile::decodeName(args->arg(i))));
else
- mw->openDocument(completePath(QFile::decodeName(args->arg(i))));
+ mw->openDocument(completePath(TQFile::decodeName(args->arg(i))));
}
- QString line = args->getOption("line");
+ TQString line = args->getOption("line");
if (line != "0") mw->setLine(line);
args->clear();
@@ -139,16 +139,16 @@ int main( int argc, char ** argv )
for ( int i = 0; i < args->count(); ++i )
{
if ( isProject(args->arg(i)) )
- client->send (appID, "Kile", "openProject(QString)", completePath(QFile::decodeName(args->arg(i))));
+ client->send (appID, "Kile", "openProject(TQString)", completePath(TQFile::decodeName(args->arg(i))));
else
- client->send (appID, "Kile", "openDocument(QString)", completePath(QFile::decodeName(args->arg(i))));
+ client->send (appID, "Kile", "openDocument(TQString)", completePath(TQFile::decodeName(args->arg(i))));
}
- QString line = args->getOption("line");
- if (line != "0") client->send (appID, "Kile", "setLine(QString)", line);
+ TQString line = args->getOption("line");
+ if (line != "0") client->send (appID, "Kile", "setLine(TQString)", line);
KStartupInfo::appStarted();
- QByteArray empty;
+ TQByteArray empty;
client->send (appID, "Kile", "setActive()", empty);
}
diff --git a/src/kile/managetemplatesdialog.cpp b/src/kile/managetemplatesdialog.cpp
index c6b4502..d73a435 100644
--- a/src/kile/managetemplatesdialog.cpp
+++ b/src/kile/managetemplatesdialog.cpp
@@ -15,9 +15,9 @@
#include "managetemplatesdialog.h"
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qtooltip.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqtooltip.h>
#include <kapp.h>
#include <klocale.h>
@@ -34,9 +34,9 @@
#include "kileinfo.h"
#include "templates.h"
-class TemplateListViewItem : public QListViewItem {
+class TemplateListViewItem : public TQListViewItem {
public:
- TemplateListViewItem(QListView* listView, QListViewItem* previousItem, const QString& mode, const KileTemplate::Info& info) : QListViewItem(listView, previousItem, mode, info.name, KileInfo::documentTypeToString(info.type)), m_info(info) {
+ TemplateListViewItem(TQListView* listView, TQListViewItem* previousItem, const TQString& mode, const KileTemplate::Info& info) : TQListViewItem(listView, previousItem, mode, info.name, KileInfo::documentTypeToString(info.type)), m_info(info) {
}
virtual ~TemplateListViewItem() {
@@ -51,30 +51,30 @@ class TemplateListViewItem : public QListViewItem {
};
// dialog to create a template
-ManageTemplatesDialog::ManageTemplatesDialog(KileTemplate::Manager *templateManager, const KURL& sourceURL, const QString &caption, QWidget *parent, const char *name ) : KDialogBase(parent,name,true,caption,KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true), m_templateManager(templateManager), m_sourceURL(sourceURL) {
+ManageTemplatesDialog::ManageTemplatesDialog(KileTemplate::Manager *templateManager, const KURL& sourceURL, const TQString &caption, TQWidget *tqparent, const char *name ) : KDialogBase(tqparent,name,true,caption,KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true), m_templateManager(templateManager), m_sourceURL(sourceURL) {
m_templateType = KileDocument::Extensions().determineDocumentType(sourceURL);
- QWidget *page = new QWidget(this , "managetemplates_mainwidget");
+ TQWidget *page = new TQWidget(this , "managetemplates_mainwidget");
setMainWidget(page);
- QVBoxLayout *topLayout = new QVBoxLayout(page, 0, spacingHint());
+ TQVBoxLayout *topLayout = new TQVBoxLayout(page, 0, spacingHint());
- QHBoxLayout *nameLayout = new QHBoxLayout(topLayout, spacingHint());
- nameLayout->addWidget(new QLabel(i18n("Name:"),page));
+ TQHBoxLayout *nameLayout = new TQHBoxLayout(topLayout, spacingHint());
+ nameLayout->addWidget(new TQLabel(i18n("Name:"),page));
- QString fileName = m_sourceURL.fileName();
+ TQString fileName = m_sourceURL.fileName();
//remove the extension
- int dotPos = fileName.findRev('.');
+ int dotPos = fileName.tqfindRev('.');
if(dotPos >= 0) {
fileName = fileName.mid(0, dotPos);
}
m_nameEdit = new KLineEdit(fileName, page);
nameLayout->addWidget(m_nameEdit);
- nameLayout->addWidget(new QLabel(i18n("Type: %1").arg(KileInfo::documentTypeToString(m_templateType)), page));
+ nameLayout->addWidget(new TQLabel(i18n("Type: %1").tqarg(KileInfo::documentTypeToString(m_templateType)), page));
- QHBoxLayout *iconLayout = new QHBoxLayout(topLayout, spacingHint());
- iconLayout->addWidget(new QLabel(i18n("Icon:"), page));
+ TQHBoxLayout *iconLayout = new TQHBoxLayout(topLayout, spacingHint());
+ iconLayout->addWidget(new TQLabel(i18n("Icon:"), page));
m_iconEdit = new KLineEdit(KGlobal::dirs()->findResource("appdata", "pics/type_Default.png"), page);
iconLayout->addWidget(m_iconEdit);
@@ -87,7 +87,7 @@ ManageTemplatesDialog::ManageTemplatesDialog(KileTemplate::Manager *templateMana
m_templateList->addColumn(i18n("marked", "M"));
m_templateList->addColumn(i18n("Existing Templates"));
m_templateList->addColumn(i18n("Document Type"));
- m_templateList->setColumnWidthMode(0, QListView::Manual);
+ m_templateList->setColumnWidthMode(0, TQListView::Manual);
m_templateList->setFullWidth(true);
m_templateList->setAllColumnsShowFocus(true);
@@ -95,49 +95,49 @@ ManageTemplatesDialog::ManageTemplatesDialog(KileTemplate::Manager *templateMana
topLayout->addWidget(m_templateList);
- QHBoxLayout *controlLayout = new QHBoxLayout(topLayout, spacingHint());
- m_showAllTypesCheckBox = new QCheckBox(i18n("Show all the templates"), page);
+ TQHBoxLayout *controlLayout = new TQHBoxLayout(topLayout, spacingHint());
+ m_showAllTypesCheckBox = new TQCheckBox(i18n("Show all the templates"), page);
m_showAllTypesCheckBox->setChecked(false);
- connect(m_showAllTypesCheckBox, SIGNAL(toggled(bool)), this, SLOT(updateTemplateListView(bool)));
+ connect(m_showAllTypesCheckBox, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(updateTemplateListView(bool)));
controlLayout->addWidget(m_showAllTypesCheckBox);
controlLayout->addStretch();
KPushButton *clearSelectionButton = new KPushButton(page);
clearSelectionButton->setPixmap(SmallIcon("clear_left.png"));
- QToolTip::add(clearSelectionButton, i18n("Clear Selection"));
- connect(clearSelectionButton, SIGNAL(clicked()),this, SLOT(clearSelection()));
+ TQToolTip::add(clearSelectionButton, i18n("Clear Selection"));
+ connect(clearSelectionButton, TQT_SIGNAL(clicked()),this, TQT_SLOT(clearSelection()));
controlLayout->addWidget(clearSelectionButton);
- topLayout->addWidget( new QLabel(i18n("Select an existing template if you want to overwrite it with your new template.\nNote that you cannot overwrite templates marked with an asterisk:\nif you do select such a template, a new template with the same name\nwill be created in a location you have write access to."),page));
+ topLayout->addWidget( new TQLabel(i18n("Select an existing template if you want to overwrite it with your new template.\nNote that you cannot overwrite templates marked with an asterisk:\nif you do select such a template, a new template with the same name\nwill be created in a location you have write access to."),page));
- connect(m_templateList, SIGNAL(selectionChanged(QListViewItem*)), this, SLOT(slotSelectedTemplate(QListViewItem*)));
- connect(iconbut, SIGNAL(clicked()),this, SLOT(slotSelectIcon()));
- connect(this, SIGNAL(aboutToClose()), this, SLOT(addTemplate()));
+ connect(m_templateList, TQT_SIGNAL(selectionChanged(TQListViewItem*)), this, TQT_SLOT(slotSelectedTemplate(TQListViewItem*)));
+ connect(iconbut, TQT_SIGNAL(clicked()),this, TQT_SLOT(slotSelectIcon()));
+ connect(this, TQT_SIGNAL(aboutToClose()), this, TQT_SLOT(addTemplate()));
}
// dialog to remove a template
-ManageTemplatesDialog::ManageTemplatesDialog(KileTemplate::Manager *templateManager, const QString &caption, QWidget *parent, const char *name ) : KDialogBase(parent,name,true,caption,KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true), m_templateManager(templateManager), m_templateType(KileDocument::Undefined), m_showAllTypesCheckBox(NULL)
+ManageTemplatesDialog::ManageTemplatesDialog(KileTemplate::Manager *templateManager, const TQString &caption, TQWidget *tqparent, const char *name ) : KDialogBase(tqparent,name,true,caption,KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true), m_templateManager(templateManager), m_templateType(KileDocument::Undefined), m_showAllTypesCheckBox(NULL)
{
- QWidget *page = new QWidget(this, "managetemplates_mainwidget");
+ TQWidget *page = new TQWidget(this, "managetemplates_mainwidget");
setMainWidget(page);
- QVBoxLayout *topLayout = new QVBoxLayout(page, 0, spacingHint());
+ TQVBoxLayout *topLayout = new TQVBoxLayout(page, 0, spacingHint());
m_templateList = new KListView(page);
m_templateList->setSorting(-1);
m_templateList->addColumn(i18n("marked", "M"));
m_templateList->addColumn(i18n("Existing Templates"));
m_templateList->addColumn(i18n("Document Type"));
- m_templateList->setColumnWidthMode(0, QListView::Manual);
+ m_templateList->setColumnWidthMode(0, TQListView::Manual);
m_templateList->setFullWidth(true);
m_templateList->setAllColumnsShowFocus(true);
populateTemplateListView(KileDocument::Undefined);
topLayout->addWidget(m_templateList);
- topLayout->addWidget( new QLabel(i18n("Please select the template that you want to remove.\nNote that you cannot delete templates marked with an asterisk (for which you lack the necessary deletion permissions)."),page));
+ topLayout->addWidget( new TQLabel(i18n("Please select the template that you want to remove.\nNote that you cannot delete templates marked with an asterisk (for which you lack the necessary deletion permissions)."),page));
- connect(this, SIGNAL(aboutToClose()), this, SLOT(removeTemplate()));
+ connect(this, TQT_SIGNAL(aboutToClose()), this, TQT_SLOT(removeTemplate()));
}
ManageTemplatesDialog::~ManageTemplatesDialog(){
@@ -158,22 +158,22 @@ void ManageTemplatesDialog::slotOk() {
void ManageTemplatesDialog::populateTemplateListView(KileDocument::Type type) {
m_templateManager->scanForTemplates();
KileTemplate::TemplateList templateList = m_templateManager->getTemplates(type);
- QString mode;
- QListViewItem* previousItem = NULL;
+ TQString mode;
+ TQListViewItem* previousItem = NULL;
m_templateList->clear();
for (KileTemplate::TemplateListIterator i = templateList.begin(); i != templateList.end(); ++i)
{
KileTemplate::Info info = *i;
- QFileInfo iconFileInfo(info.icon);
- mode = (QFileInfo(info.path).isWritable() && (!iconFileInfo.exists() || iconFileInfo.isWritable())) ? " " : "*";
+ TQFileInfo iconFileInfo(info.icon);
+ mode = (TQFileInfo(info.path).isWritable() && (!iconFileInfo.exists() || iconFileInfo.isWritable())) ? " " : "*";
if((type == KileDocument::Undefined) || (info.type == type)) {
previousItem = new TemplateListViewItem(m_templateList, previousItem, mode, info);
}
}
}
-void ManageTemplatesDialog::slotSelectedTemplate(QListViewItem *item) {
+void ManageTemplatesDialog::slotSelectedTemplate(TQListViewItem *item) {
TemplateListViewItem *templateItem = dynamic_cast<TemplateListViewItem*>(item);
if(templateItem) {
KileTemplate::Info info = templateItem->getTemplateInfo();
@@ -184,7 +184,7 @@ void ManageTemplatesDialog::slotSelectedTemplate(QListViewItem *item) {
void ManageTemplatesDialog::slotSelectIcon() {
KIconDialog *dlg = new KIconDialog();
- QString res = dlg->openDialog();
+ TQString res = dlg->openDialog();
KIconLoader kil;
if (!res.isNull() ) {
@@ -194,14 +194,14 @@ void ManageTemplatesDialog::slotSelectIcon() {
void ManageTemplatesDialog::addTemplate() {
- QString templateName = (m_nameEdit->text()).stripWhiteSpace();
+ TQString templateName = (m_nameEdit->text()).stripWhiteSpace();
if(templateName.isEmpty()) {
KMessageBox::error(this, i18n("Sorry, but the template name that you have entered is invalid.\nPlease enter a new name."));
return;
}
- QString icon = (m_iconEdit->text()).stripWhiteSpace();
+ TQString icon = (m_iconEdit->text()).stripWhiteSpace();
KURL iconURL = KURL::fromPathOrURL(icon);
if (icon.isEmpty()) {
@@ -210,19 +210,19 @@ void ManageTemplatesDialog::addTemplate() {
}
if (!KIO::NetAccess::exists(iconURL, true, kapp->mainWidget())) {
- KMessageBox::error(this, i18n("Sorry, but the icon file: %1\ndoes not seem to exist. Please choose a new icon.").arg(icon));
+ KMessageBox::error(this, i18n("Sorry, but the icon file: %1\ndoes not seem to exist. Please choose a new icon.").tqarg(icon));
return;
}
if (!KIO::NetAccess::exists(m_sourceURL, true, kapp->mainWidget())) {
- KMessageBox::error(this, i18n("Sorry, but the file: %1\ndoes not seem to exist. Maybe you forgot to save the file?").arg(m_sourceURL.prettyURL()));
+ KMessageBox::error(this, i18n("Sorry, but the file: %1\ndoes not seem to exist. Maybe you forgot to save the file?").tqarg(m_sourceURL.prettyURL()));
return;
}
- QListViewItem* item = m_templateList->selectedItem();
+ TQListViewItem* item = m_templateList->selectedItem();
if(!item && m_templateManager->searchForTemplate(templateName, m_templateType)) {
- KMessageBox::error(this, i18n("Sorry, but a template named \"%1\" already exists.\nPlease remove it first.").arg(templateName));
+ KMessageBox::error(this, i18n("Sorry, but a template named \"%1\" already exists.\nPlease remove it first.").tqarg(templateName));
return;
}
@@ -231,11 +231,11 @@ void ManageTemplatesDialog::addTemplate() {
TemplateListViewItem *templateItem = dynamic_cast<TemplateListViewItem*>(item);
Q_ASSERT(templateItem);
KileTemplate::Info templateInfo = templateItem->getTemplateInfo();
- if (KMessageBox::warningYesNo(this, i18n("You are about to replace the template \"%1\"; are you sure?").arg(templateInfo.name)) == KMessageBox::No) {
+ if (KMessageBox::warningYesNo(this, i18n("You are about to replace the template \"%1\"; are you sure?").tqarg(templateInfo.name)) == KMessageBox::No) {
reject();
return;
}
- returnValue = m_templateManager->replace(templateInfo, m_sourceURL, templateName, iconURL);
+ returnValue = m_templateManager->tqreplace(templateInfo, m_sourceURL, templateName, iconURL);
}
else {
returnValue = m_templateManager->add(m_sourceURL, templateName, iconURL);
@@ -250,7 +250,7 @@ void ManageTemplatesDialog::addTemplate() {
bool ManageTemplatesDialog::removeTemplate()
{
- QListViewItem* item = m_templateList->selectedItem();
+ TQListViewItem* item = m_templateList->selectedItem();
if(!item) {
KMessageBox::information(this, i18n("Please select a template that should be removed."));
return true;
@@ -261,12 +261,12 @@ bool ManageTemplatesDialog::removeTemplate()
KileTemplate::Info templateInfo = templateItem->getTemplateInfo();
- if (!(KIO::NetAccess::exists(KURL::fromPathOrURL(templateInfo.path), false, kapp->mainWidget()) && (KIO::NetAccess::exists(KURL::fromPathOrURL(templateInfo.icon), false, kapp->mainWidget()) || !QFileInfo(templateInfo.icon).exists()))) {
+ if (!(KIO::NetAccess::exists(KURL::fromPathOrURL(templateInfo.path), false, kapp->mainWidget()) && (KIO::NetAccess::exists(KURL::fromPathOrURL(templateInfo.icon), false, kapp->mainWidget()) || !TQFileInfo(templateInfo.icon).exists()))) {
KMessageBox::error(this, i18n("Sorry, but you do not have the necessary permissions to remove the selected template."));
return false;
}
- if (KMessageBox::warningYesNo(this, i18n("You are about to remove the template \"%1\"; are you sure?").arg(templateInfo.name)) == KMessageBox::No) {
+ if (KMessageBox::warningYesNo(this, i18n("You are about to remove the template \"%1\"; are you sure?").tqarg(templateInfo.name)) == KMessageBox::No) {
return false;
}
diff --git a/src/kile/managetemplatesdialog.h b/src/kile/managetemplatesdialog.h
index c3c8f81..1700394 100644
--- a/src/kile/managetemplatesdialog.h
+++ b/src/kile/managetemplatesdialog.h
@@ -16,9 +16,9 @@
#ifndef MANAGETEMPLATESDIALOG_H
#define MANAGETEMPLATESDIALOG_H
-#include <qcheckbox.h>
-#include <qfileinfo.h>
-#include <qstring.h>
+#include <tqcheckbox.h>
+#include <tqfileinfo.h>
+#include <tqstring.h>
#include <klistview.h>
#include <kdialogbase.h>
@@ -37,13 +37,14 @@ namespace KileTemplate { class Manager; class Info; }
class ManageTemplatesDialog : public KDialogBase {
Q_OBJECT
+ TQ_OBJECT
public:
- ManageTemplatesDialog(KileTemplate::Manager *templateManager, const KURL& sourceURL, const QString &caption,QWidget *parent=0, const char *name=0);
- ManageTemplatesDialog(KileTemplate::Manager *templateManager, const QString &caption,QWidget *parent=0, const char *name=0);
+ ManageTemplatesDialog(KileTemplate::Manager *templateManager, const KURL& sourceURL, const TQString &caption,TQWidget *tqparent=0, const char *name=0);
+ ManageTemplatesDialog(KileTemplate::Manager *templateManager, const TQString &caption,TQWidget *tqparent=0, const char *name=0);
virtual ~ManageTemplatesDialog();
public slots:
- void slotSelectedTemplate(QListViewItem *item);
+ void slotSelectedTemplate(TQListViewItem *item);
void slotSelectIcon();
void addTemplate();
bool removeTemplate();
@@ -61,7 +62,7 @@ protected:
KLineEdit *m_nameEdit, *m_iconEdit;
KListView *m_templateList;
KileDocument::Type m_templateType;
- QCheckBox *m_showAllTypesCheckBox;
+ TQCheckBox *m_showAllTypesCheckBox;
KURL m_sourceURL;
/**
diff --git a/src/kile/mathenvdialog.cpp b/src/kile/mathenvdialog.cpp
index 4e52bca..a6df529 100644
--- a/src/kile/mathenvdialog.cpp
+++ b/src/kile/mathenvdialog.cpp
@@ -20,10 +20,10 @@
#include "codecompletion.h"
#include "kileedit.h"
-#include <qlayout.h>
-#include <qstringlist.h>
-#include <qvaluelist.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqstringlist.h>
+#include <tqvaluelist.h>
+#include <tqwhatsthis.h>
#include <klocale.h>
#include "kiledebug.h"
@@ -31,67 +31,67 @@
namespace KileDialog
{
-MathEnvironmentDialog::MathEnvironmentDialog(QWidget *parent, KConfig *config, KileInfo *ki, KileDocument::LatexCommands *commands)
- : Wizard(config,parent), m_ki(ki), m_latexCommands(commands)
+MathEnvironmentDialog::MathEnvironmentDialog(TQWidget *tqparent, KConfig *config, KileInfo *ki, KileDocument::LatexCommands *commands)
+ : Wizard(config,tqparent), m_ki(ki), m_latexCommands(commands)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
setCaption(i18n("Math Environments"));
- QVBoxLayout *vbox = new QVBoxLayout(page,8,8);
+ TQVBoxLayout *vbox = new TQVBoxLayout(page,8,8);
// environment groupbox
- QButtonGroup *envgroup = new QButtonGroup( i18n("Environment"),page);
+ TQButtonGroup *envgroup = new TQButtonGroup( i18n("Environment"),page);
envgroup->setColumnLayout(0, Qt::Vertical );
- envgroup->layout()->setSpacing( 6 );
- envgroup->layout()->setMargin( 11 );
+ envgroup->tqlayout()->setSpacing( 6 );
+ envgroup->tqlayout()->setMargin( 11 );
- m_lbEnvironment = new QLabel(i18n("&Name:"),envgroup);
- m_lbStarred = new QLabel(i18n("Without n&umbering:"),envgroup);
- m_lbRows = new QLabel(i18n("Number of &rows:"),envgroup);
- m_lbCols = new QLabel(i18n("Number of c&ols:"),envgroup);
- m_lbSpace = new QLabel(i18n("Space command\nto &separate groups:"), envgroup);
- m_lbTabulator = new QLabel(i18n("Standard &tabulator:"), envgroup);
- m_lbDisplaymath = new QLabel(i18n("Display&math mode:"), envgroup);
- m_lbBullets = new QLabel(i18n("Use &bullets:"), envgroup);
+ m_lbEnvironment = new TQLabel(i18n("&Name:"),envgroup);
+ m_lbStarred = new TQLabel(i18n("Without n&umbering:"),envgroup);
+ m_lbRows = new TQLabel(i18n("Number of &rows:"),envgroup);
+ m_lbCols = new TQLabel(i18n("Number of c&ols:"),envgroup);
+ m_lbSpace = new TQLabel(i18n("Space command\nto &separate groups:"), envgroup);
+ m_lbTabulator = new TQLabel(i18n("Standard &tabulator:"), envgroup);
+ m_lbDisplaymath = new TQLabel(i18n("Display&math mode:"), envgroup);
+ m_lbBullets = new TQLabel(i18n("Use &bullets:"), envgroup);
- QFrame *frame = new QFrame(envgroup);
- frame->setFrameStyle(QFrame::HLine | QFrame::Sunken);
+ TQFrame *frame = new TQFrame(envgroup);
+ frame->setFrameStyle(TQFrame::HLine | TQFrame::Sunken);
frame->setLineWidth(1);
- m_coEnvironment = new QComboBox(envgroup);
- m_cbStarred = new QCheckBox(envgroup);
- m_spRows = new QSpinBox(1,99,1,envgroup);
+ m_coEnvironment = new TQComboBox(envgroup);
+ m_cbStarred = new TQCheckBox(envgroup);
+ m_spRows = new TQSpinBox(1,99,1,envgroup);
m_spRows->setValue(3);
- m_spCols = new QSpinBox(1,49,1,envgroup);
+ m_spCols = new TQSpinBox(1,49,1,envgroup);
m_spCols->setValue(3);
m_edSpace = new KLineEdit("",envgroup);
- m_coTabulator = new QComboBox(envgroup);
- m_coDisplaymath = new QComboBox(envgroup);
- m_cbBullets = new QCheckBox(envgroup);
+ m_coTabulator = new TQComboBox(envgroup);
+ m_coDisplaymath = new TQComboBox(envgroup);
+ m_cbBullets = new TQCheckBox(envgroup);
- QGridLayout *envlayout = new QGridLayout( envgroup->layout() );
- envlayout->setAlignment( Qt::AlignTop );
- envlayout->addWidget( m_lbEnvironment, 0,0 );
- envlayout->addWidget( m_lbStarred, 1,0 );
- envlayout->addWidget( m_lbRows, 2,0 );
- envlayout->addWidget( m_lbCols, 3,0 );
- envlayout->addWidget( m_lbTabulator, 5,0 );
- envlayout->addWidget( m_lbDisplaymath, 6,0 );
- envlayout->addWidget( m_coEnvironment, 0,1 );
- envlayout->addWidget( m_cbStarred, 1,1 );
- envlayout->addWidget( m_spRows, 2,1 );
- envlayout->addWidget( m_spCols, 3,1 );
- envlayout->addWidget( m_coTabulator, 5,1 );
- envlayout->addWidget( m_coDisplaymath, 6,1 );
- envlayout->addWidget( m_lbSpace, 3,3 );
- envlayout->addWidget( m_lbBullets, 5,3 );
- envlayout->addWidget( m_edSpace, 3,4 );
- envlayout->addWidget( m_cbBullets, 5,4 );
- envlayout->addMultiCellWidget(frame,4,4,0,4);
- envlayout->setRowSpacing(4,30);
- envlayout->setColSpacing(2,20);
- envlayout->setColStretch(4,1);
+ TQGridLayout *envtqlayout = new TQGridLayout( envgroup->tqlayout() );
+ envtqlayout->tqsetAlignment( TQt::AlignTop );
+ envtqlayout->addWidget( m_lbEnvironment, 0,0 );
+ envtqlayout->addWidget( m_lbStarred, 1,0 );
+ envtqlayout->addWidget( m_lbRows, 2,0 );
+ envtqlayout->addWidget( m_lbCols, 3,0 );
+ envtqlayout->addWidget( m_lbTabulator, 5,0 );
+ envtqlayout->addWidget( m_lbDisplaymath, 6,0 );
+ envtqlayout->addWidget( m_coEnvironment, 0,1 );
+ envtqlayout->addWidget( m_cbStarred, 1,1 );
+ envtqlayout->addWidget( m_spRows, 2,1 );
+ envtqlayout->addWidget( m_spCols, 3,1 );
+ envtqlayout->addWidget( m_coTabulator, 5,1 );
+ envtqlayout->addWidget( m_coDisplaymath, 6,1 );
+ envtqlayout->addWidget( m_lbSpace, 3,3 );
+ envtqlayout->addWidget( m_lbBullets, 5,3 );
+ envtqlayout->addWidget( m_edSpace, 3,4 );
+ envtqlayout->addWidget( m_cbBullets, 5,4 );
+ envtqlayout->addMultiCellWidget(frame,4,4,0,4);
+ envtqlayout->setRowSpacing(4,30);
+ envtqlayout->setColSpacing(2,20);
+ envtqlayout->setColStretch(4,1);
// add widgets
vbox->addWidget( envgroup);
@@ -107,7 +107,7 @@ MathEnvironmentDialog::MathEnvironmentDialog(QWidget *parent, KConfig *config, K
m_lbBullets->setBuddy(m_cbBullets);
// initialize dialog
- m_coDisplaymath->insertItem(QString::null);
+ m_coDisplaymath->insertItem(TQString());
m_coDisplaymath->insertItem("displaymath");
m_coDisplaymath->insertItem("\\[");
m_coDisplaymath->insertItem("equation");
@@ -119,24 +119,24 @@ MathEnvironmentDialog::MathEnvironmentDialog(QWidget *parent, KConfig *config, K
slotEnvironmentChanged( m_coEnvironment->currentItem() );
// signals and slots
- connect(m_coEnvironment, SIGNAL(activated(int)), this, SLOT(slotEnvironmentChanged(int)));
- connect(m_spCols, SIGNAL(valueChanged(int)), this, SLOT(slotSpinboxValueChanged(int)));
+ connect(m_coEnvironment, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotEnvironmentChanged(int)));
+ connect(m_spCols, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotSpinboxValueChanged(int)));
- QWhatsThis::add(m_coEnvironment,i18n("Choose an environment."));
- QWhatsThis::add(m_cbStarred,i18n("Use the starred version of this environment."));
- QWhatsThis::add(m_spRows,i18n("Choose the number of table rows."));
- QWhatsThis::add(m_spCols,i18n("Choose the number of table columns or alignment groups."));
- QWhatsThis::add(m_edSpace,i18n("Define an extra LaTeX command to separate alignment groups."));
- QWhatsThis::add(m_coTabulator,i18n("Choose one of some predefined tabulators."));
- QWhatsThis::add(m_coDisplaymath,i18n("Some environments are only valid in math mode. You can surround them with one of these display math modes."));
- QWhatsThis::add(m_cbBullets,i18n("Insert bullets in each cell. Alt+Ctrl+Right and Alt+Ctrl+Left will move very quick from one cell to another."));
+ TQWhatsThis::add(m_coEnvironment,i18n("Choose an environment."));
+ TQWhatsThis::add(m_cbStarred,i18n("Use the starred version of this environment."));
+ TQWhatsThis::add(m_spRows,i18n("Choose the number of table rows."));
+ TQWhatsThis::add(m_spCols,i18n("Choose the number of table columns or tqalignment groups."));
+ TQWhatsThis::add(m_edSpace,i18n("Define an extra LaTeX command to separate tqalignment groups."));
+ TQWhatsThis::add(m_coTabulator,i18n("Choose one of some predefined tabulators."));
+ TQWhatsThis::add(m_coDisplaymath,i18n("Some environments are only valid in math mode. You can surround them with one of these display math modes."));
+ TQWhatsThis::add(m_cbBullets,i18n("Insert bullets in each cell. Alt+Ctrl+Right and Alt+Ctrl+Left will move very quick from one cell to another."));
}
void MathEnvironmentDialog::initEnvironments()
{
// read all math environments and insert them into the combobox
- QStringList list;
- QStringList::ConstIterator it;
+ TQStringList list;
+ TQStringList::ConstIterator it;
m_latexCommands->commandList(list,(uint)(KileDocument::CmdAttrAmsmath|KileDocument::CmdAttrMath),false);
for ( it=list.begin(); it != list.end(); ++it )
{
@@ -151,7 +151,7 @@ bool MathEnvironmentDialog::isGroupsParameterEnv()
bool MathEnvironmentDialog::isParameterEnv()
{
- return ( m_parameter.find("{") >= 0 );
+ return ( m_parameter.tqfind("{") >= 0 );
}
////////////////////////////// determine the whole tag //////////////////////////////
@@ -180,7 +180,7 @@ void MathEnvironmentDialog::slotEnvironmentChanged(int index)
m_cbStarred->setEnabled(m_starred);
// determine column/group entries
- QString labeltext = i18n("Number of cols:");
+ TQString labeltext = i18n("Number of cols:");
bool spinstate = false;
int minvalue = 1;
int maxvalue = 1;
@@ -229,7 +229,7 @@ void MathEnvironmentDialog::slotEnvironmentChanged(int index)
// set tabulator entries
m_coTabulator->clear();
- QStringList tablist;
+ TQStringList tablist;
if ( m_tabulator == "&=&" )
tablist << "&=&" << "& &" << "&<&" << "&<=&" << "&>&" << "&>=&"
<< "&\\ne&" << "&\\approx&" << "&\\equiv&" << "&\\conq&" ;
@@ -259,23 +259,23 @@ void MathEnvironmentDialog::slotSpinboxValueChanged(int index)
void MathEnvironmentDialog::slotOk()
{
// environment
- QString envname = ( m_cbStarred->isChecked() ) ? m_envname + '*' : m_envname;
- QString indent = m_ki->editorExtension()->autoIndentEnvironment();
+ TQString envname = ( m_cbStarred->isChecked() ) ? m_envname + '*' : m_envname;
+ TQString indent = m_ki->editorExtension()->autoIndentEnvironment();
// use bullets?
- QString bullet = ( m_cbBullets->isChecked() ) ? s_bullet : QString::null;
+ TQString bullet = ( m_cbBullets->isChecked() ) ? s_bullet : TQString();
// normal tabulator
- QString tab = m_coTabulator->currentText();
- tab.replace("<=","\\le");
- tab.replace(">=","\\ge");
- QString tabulator = bullet + ' ' + tab + ' ';
+ TQString tab = m_coTabulator->currentText();
+ tab.tqreplace("<=","\\le");
+ tab.tqreplace(">=","\\ge");
+ TQString tabulator = bullet + ' ' + tab + ' ';
// number of rows
int numrows = m_spRows->value();
// get number of groups/columns and tabulator to separate these
- QString topgrouptabulator,grouptabulator;
+ TQString topgrouptabulator,grouptabulator;
int numgroups;
bool aligngroups;
if ( m_groups )
@@ -284,7 +284,7 @@ void MathEnvironmentDialog::slotOk()
numgroups = ( m_tabulator != "&" ) ? m_spCols->value() : 1;
if ( m_edSpace->isEnabled() )
{
- QString spaces;
+ TQString spaces;
topgrouptabulator = " &" + m_edSpace->text() + " ";
grouptabulator = " & " + spaces.fill(' ', m_edSpace->text().length());
}
@@ -304,11 +304,11 @@ void MathEnvironmentDialog::slotOk()
}
// get displaymath mode
- QString displaymathbegin = QString::null;
- QString displaymathend = QString::null;
+ TQString displaymathbegin = TQString();
+ TQString displaymathend = TQString();
if ( m_coDisplaymath->isEnabled() )
{
- QString mathmode = m_coDisplaymath->currentText();
+ TQString mathmode = m_coDisplaymath->currentText();
if ( ! mathmode.isEmpty() )
{
if ( mathmode == "\\[" )
@@ -318,8 +318,8 @@ void MathEnvironmentDialog::slotOk()
}
else
{
- displaymathbegin = QString("\\begin{%1}\n").arg(mathmode);
- displaymathend = QString("\\end{%1}\n").arg(mathmode);
+ displaymathbegin = TQString("\\begin{%1}\n").tqarg(mathmode);
+ displaymathend = TQString("\\end{%1}\n").tqarg(mathmode);
}
}
}
@@ -327,14 +327,14 @@ void MathEnvironmentDialog::slotOk()
// build tag
m_td.tagBegin = displaymathbegin;
- QString parameter;
+ TQString parameter;
if ( isGroupsParameterEnv() )
- parameter = QString("{%2}").arg(numgroups);
+ parameter = TQString("{%2}").tqarg(numgroups);
else if ( isParameterEnv() )
parameter = '{' + bullet + '}';
// open environment
- m_td.tagBegin += QString("\\begin{%1}").arg(envname) + parameter + '\n';
+ m_td.tagBegin += TQString("\\begin{%1}").tqarg(envname) + parameter + '\n';
for ( int row=0; row<numrows; ++row )
{
@@ -359,7 +359,7 @@ void MathEnvironmentDialog::slotOk()
}
// close environment
- m_td.tagEnd = QString("\n\\end{%1}\n").arg(envname);
+ m_td.tagEnd = TQString("\n\\end{%1}\n").tqarg(envname);
m_td.tagEnd += displaymathend;
m_td.dy = ( displaymathbegin.isEmpty() ) ? 1 : 2;
diff --git a/src/kile/mathenvdialog.h b/src/kile/mathenvdialog.h
index 23611d3..6578ba2 100644
--- a/src/kile/mathenvdialog.h
+++ b/src/kile/mathenvdialog.h
@@ -25,13 +25,13 @@
#include <klineedit.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qcombobox.h>
-#include <qspinbox.h>
-#include <qbuttongroup.h>
-#include <qmap.h>
-#include <qvaluelist.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqcombobox.h>
+#include <tqspinbox.h>
+#include <tqbuttongroup.h>
+#include <tqmap.h>
+#include <tqvaluelist.h>
namespace KileDialog
{
@@ -39,9 +39,10 @@ namespace KileDialog
class MathEnvironmentDialog : public Wizard
{
Q_OBJECT
+ TQ_OBJECT
public:
- MathEnvironmentDialog(QWidget *parent, KConfig *config, KileInfo *ki, KileDocument::LatexCommands *commands);
+ MathEnvironmentDialog(TQWidget *tqparent, KConfig *config, KileInfo *ki, KileDocument::LatexCommands *commands);
~MathEnvironmentDialog() {}
public slots:
@@ -55,22 +56,22 @@ private:
KileInfo *m_ki;
KileDocument::LatexCommands *m_latexCommands;
- QComboBox *m_coEnvironment, *m_coTabulator, *m_coDisplaymath;
- QCheckBox *m_cbStarred, *m_cbBullets;
- QSpinBox *m_spRows, *m_spCols;
- QLabel *m_lbRows, *m_lbCols, *m_lbSpace ;
- QLabel *m_lbTabulator, *m_lbDisplaymath, *m_lbStarred;
- QLabel *m_lbEnvironment, *m_lbBullets;
+ TQComboBox *m_coEnvironment, *m_coTabulator, *m_coDisplaymath;
+ TQCheckBox *m_cbStarred, *m_cbBullets;
+ TQSpinBox *m_spRows, *m_spCols;
+ TQLabel *m_lbRows, *m_lbCols, *m_lbSpace ;
+ TQLabel *m_lbTabulator, *m_lbDisplaymath, *m_lbStarred;
+ TQLabel *m_lbEnvironment, *m_lbBullets;
KLineEdit *m_edSpace;
- QString m_envname;
+ TQString m_envname;
bool m_starred;
bool m_groups;
bool m_columns;
bool m_fixedcolumns;
bool m_mathmode;
- QString m_tabulator;
- QString m_parameter;
+ TQString m_tabulator;
+ TQString m_parameter;
void initEnvironments();
bool isParameterEnv();
diff --git a/src/kile/newdocumentwidget.ui b/src/kile/newdocumentwidget.ui
index 14832b2..290ecb6 100644
--- a/src/kile/newdocumentwidget.ui
+++ b/src/kile/newdocumentwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>NewDocumentWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>NewDocumentWidget</cstring>
</property>
@@ -16,7 +16,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox2</cstring>
</property>
@@ -27,7 +27,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -35,15 +35,15 @@
<string>Please select the type of document you want to create:</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout2</cstring>
+ <cstring>tqlayout2</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<property name="name">
<cstring>documentTypeComboBox</cstring>
</property>
@@ -58,7 +58,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -69,7 +69,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -80,7 +80,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1_2</cstring>
</property>
@@ -93,7 +93,7 @@
<cstring>templateIconView</cstring>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quickStartWizardCheckBox</cstring>
</property>
@@ -122,5 +122,5 @@
</sizepolicy>
</customwidget>
</customwidgets>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/src/kile/newfilewizard.cpp b/src/kile/newfilewizard.cpp
index 656cdff..ac62ef8 100644
--- a/src/kile/newfilewizard.cpp
+++ b/src/kile/newfilewizard.cpp
@@ -16,12 +16,12 @@
#include "newfilewizard.h"
-#include <qcombobox.h>
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qdir.h>
-#include <qfileinfo.h>
-#include <qmap.h>
+#include <tqcombobox.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqdir.h>
+#include <tqfileinfo.h>
+#include <tqmap.h>
#include <klocale.h>
#include "kiledebug.h"
@@ -36,8 +36,8 @@
#define BIBTEX_TYPE 1
#define SCRIPT_TYPE 2
-NewFileWizard::NewFileWizard(KileTemplate::Manager *templateManager, QWidget *parent, const char *name )
- : KDialogBase(parent,name,true,i18n("New File"),KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true), m_templateManager(templateManager), m_currentlyDisplayedType(-1)
+NewFileWizard::NewFileWizard(KileTemplate::Manager *templateManager, TQWidget *tqparent, const char *name )
+ : KDialogBase(tqparent,name,true,i18n("New File"),KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true), m_templateManager(templateManager), m_currentlyDisplayedType(-1)
{
// first read config
m_config = kapp->config();
@@ -49,13 +49,13 @@ NewFileWizard::NewFileWizard(KileTemplate::Manager *templateManager, QWidget *pa
if ( h == -1 ) h = height();
m_newDocumentWidget = new NewDocumentWidget(this);
- connect(m_newDocumentWidget->templateIconView, SIGNAL(doubleClicked(QIconViewItem *)), SLOT(slotOk()));
+ connect(m_newDocumentWidget->templateIconView, TQT_SIGNAL(doubleClicked(TQIconViewItem *)), TQT_SLOT(slotOk()));
m_templateManager->scanForTemplates();
m_newDocumentWidget->templateIconView->setTemplateManager(m_templateManager);
m_newDocumentWidget->templateIconView->fillWithTemplates(KileDocument::LaTeX);
- connect(m_newDocumentWidget->documentTypeComboBox, SIGNAL(activated(int)), this, SLOT(slotActivated(int)));
- connect(m_newDocumentWidget->templateIconView, SIGNAL(classFileSearchFinished()), this, SLOT(restoreSelectedIcon()));
+ connect(m_newDocumentWidget->documentTypeComboBox, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotActivated(int)));
+ connect(m_newDocumentWidget->templateIconView, TQT_SIGNAL(classFileSearchFinished()), this, TQT_SLOT(restoreSelectedIcon()));
setMainWidget(m_newDocumentWidget);
@@ -79,7 +79,7 @@ NewFileWizard::~NewFileWizard()
TemplateItem* NewFileWizard::getSelection()const
{
- for(QIconViewItem *item = m_newDocumentWidget->templateIconView->firstItem(); item; item = item->nextItem()) {
+ for(TQIconViewItem *item = m_newDocumentWidget->templateIconView->firstItem(); item; item = item->nextItem()) {
if(item->isSelected()) {
return static_cast<TemplateItem*>(item);
}
@@ -93,9 +93,9 @@ bool NewFileWizard::useWizard()
return ( (m_newDocumentWidget->documentTypeComboBox->currentItem() == 0) && getSelection() && (getSelection()->name() == DEFAULT_EMPTY_CAPTION || getSelection()->name() == DEFAULT_EMPTY_LATEX_CAPTION) && m_newDocumentWidget->quickStartWizardCheckBox->isChecked() );
}
-QString NewFileWizard::getConfigKey(int index)
+TQString NewFileWizard::getConfigKey(int index)
{
- QString configKey = "NewFileWizardSelectedIcon";
+ TQString configKey = "NewFileWizardSelectedIcon";
switch(index) {
case LATEX_TYPE:
configKey += "LaTeX";
@@ -125,8 +125,8 @@ void NewFileWizard::storeSelectedIcon()
void NewFileWizard::restoreSelectedIcon()
{
- QString selectedIconName = m_config->readEntry(getConfigKey(m_currentlyDisplayedType), DEFAULT_EMPTY_CAPTION);
- QIconViewItem *item = m_newDocumentWidget->templateIconView->findItem(selectedIconName);
+ TQString selectedIconName = m_config->readEntry(getConfigKey(m_currentlyDisplayedType), DEFAULT_EMPTY_CAPTION);
+ TQIconViewItem *item = m_newDocumentWidget->templateIconView->tqfindItem(selectedIconName);
if(item) {
m_newDocumentWidget->templateIconView->setSelected(item, true);
}
diff --git a/src/kile/newfilewizard.h b/src/kile/newfilewizard.h
index 006eead..d8b4b7b 100644
--- a/src/kile/newfilewizard.h
+++ b/src/kile/newfilewizard.h
@@ -16,8 +16,8 @@
#ifndef NEWFILEWIZARD_H
#define NEWFILEWIZARD_H
-#include <qstring.h>
-#include <qcheckbox.h>
+#include <tqstring.h>
+#include <tqcheckbox.h>
#include <kstandarddirs.h>
#include <kiconview.h>
@@ -33,8 +33,9 @@ class NewDocumentWidget;
class NewFileWizard : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- NewFileWizard(KileTemplate::Manager *manager, QWidget *parent=0, const char *name=0);
+ NewFileWizard(KileTemplate::Manager *manager, TQWidget *tqparent=0, const char *name=0);
~NewFileWizard();
public:
@@ -53,7 +54,7 @@ protected:
NewDocumentWidget* m_newDocumentWidget;
int m_currentlyDisplayedType; // not a document type, only a local type!
- QString getConfigKey(int index);
+ TQString getConfigKey(int index);
void storeSelectedIcon();
diff --git a/src/kile/newtoolwizard.ui b/src/kile/newtoolwizard.ui
index 97e8a39..2f30ab6 100644
--- a/src/kile/newtoolwizard.ui
+++ b/src/kile/newtoolwizard.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>NewToolWizard</class>
-<widget class="QWizard">
+<widget class="TQWizard">
<property name="name">
<cstring>NewToolWizard</cstring>
</property>
@@ -15,7 +15,7 @@
<property name="caption">
<string>New Tool</string>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>NamePage</cstring>
</property>
@@ -26,7 +26,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbName</cstring>
</property>
@@ -49,7 +49,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>100</width>
<height>0</height>
@@ -69,14 +69,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>70</height>
</size>
</property>
</spacer>
- <widget class="QLabel" row="2" column="0" rowspan="1" colspan="2">
+ <widget class="TQLabel" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>m_lbWarning</cstring>
</property>
@@ -86,7 +86,7 @@
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>WizardPage</cstring>
</property>
@@ -112,14 +112,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>111</height>
</size>
</property>
</spacer>
- <widget class="QLabel" row="0" column="0" rowspan="2" colspan="1">
+ <widget class="TQLabel" row="0" column="0" rowspan="2" colspan="1">
<property name="name">
<cstring>m_lbBehavior</cstring>
</property>
@@ -146,7 +146,7 @@ the standard "LaTeX" tool.</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>71</height>
@@ -161,27 +161,27 @@ the standard "LaTeX" tool.</string>
<tabstop>m_cbTools</tabstop>
</tabstops>
<includes>
- <include location="global" impldecl="in implementation">qstringlist.h</include>
- <include location="global" impldecl="in implementation">qregexp.h</include>
+ <include location="global" impldecl="in implementation">tqstringlist.h</include>
+ <include location="global" impldecl="in implementation">tqregexp.h</include>
<include location="global" impldecl="in implementation">kglobal.h</include>
<include location="local" impldecl="in implementation">kiletoolmanager.h</include>
<include location="global" impldecl="in implementation">klocale.h</include>
<include location="local" impldecl="in implementation">newtoolwizard.ui.h</include>
</includes>
<variables>
- <variable access="private">QStringList m_toolList;</variable>
+ <variable access="private">TQStringList m_toolList;</variable>
</variables>
-<slots>
- <slot>showPage( QWidget * pg )</slot>
- <slot>nameChanged( const QString &amp; name )</slot>
-</slots>
+<Q_SLOTS>
+ <slot>showPage( TQWidget * pg )</slot>
+ <slot>nameChanged( const TQString &amp; name )</slot>
+</Q_SLOTS>
<functions>
<function access="private" specifier="non virtual">init()</function>
- <function returnType="QString">customTool()</function>
- <function returnType="QString">toolName()</function>
- <function returnType="QString">parentTool()</function>
+ <function returnType="TQString">customTool()</function>
+ <function returnType="TQString">toolName()</function>
+ <function returnType="TQString">tqparentTool()</function>
</functions>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
<includehint>kcombobox.h</includehint>
diff --git a/src/kile/newtoolwizard.ui.h b/src/kile/newtoolwizard.ui.h
index f89b26a..72f5c00 100644
--- a/src/kile/newtoolwizard.ui.h
+++ b/src/kile/newtoolwizard.ui.h
@@ -2,7 +2,7 @@
** ui.h extension file, included from the uic-generated form implementation.
**
** If you wish to add, delete or rename functions or slots use
-** Qt Designer which will update this file, preserving your code. Create an
+** TQt Designer which will update this file, preserving your code. Create an
** init() function in place of a constructor, and a destroy() function in
** place of a destructor.
*****************************************************************************/
@@ -12,7 +12,7 @@ void NewToolWizard::init()
m_toolList = KileTool::toolList(KGlobal::config(), false);
//setup the Name page (page 0)
- connect(m_leName, SIGNAL(textChanged(const QString &)), this, SLOT(nameChanged(const QString &)));
+ connect(m_leName, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(nameChanged(const TQString &)));
setNextEnabled(page(0), false);
setFinishEnabled(page(0), false);
setHelpEnabled(page(0), false);
@@ -24,9 +24,9 @@ void NewToolWizard::init()
setHelpEnabled(page(1), false);
}
-void NewToolWizard::showPage(QWidget *pg)
+void NewToolWizard::showPage(TQWidget *pg)
{
- QWizard::showPage(pg);
+ TQWizard::showPage(pg);
if ( pg == page(0) )
m_leName->setFocus();
@@ -34,37 +34,37 @@ void NewToolWizard::showPage(QWidget *pg)
m_cbTools->setFocus();
}
-QString NewToolWizard::customTool()
+TQString NewToolWizard::customTool()
{
return i18n("<Custom>");
}
-QString NewToolWizard::toolName()
+TQString NewToolWizard::toolName()
{
return m_leName->text();
}
-QString NewToolWizard::parentTool()
+TQString NewToolWizard::tqparentTool()
{
return m_cbTools->currentText();
}
-void NewToolWizard::nameChanged(const QString &name)
+void NewToolWizard::nameChanged(const TQString &name)
{
- static QRegExp reBracket = QRegExp("\\(|\\)|\\[|\\]");
+ static TQRegExp reBracket = TQRegExp("\\(|\\)|\\[|\\]");
bool ok = true;
- if (m_toolList.contains(name))
+ if (m_toolList.tqcontains(name))
{
m_lbWarning->setText(i18n( "Error: A tool by this name already exists." ));
ok = false;
}
- else if (name.find("/") != -1)
+ else if (name.tqfind("/") != -1)
{
m_lbWarning->setText(i18n( "Error: The name may not contain a slash '/'." ));
ok = false;
}
- else if ( name.find(reBracket) != -1 )
+ else if ( name.tqfind(reBracket) != -1 )
{
m_lbWarning->setText(i18n("Error: The name may not contain a (,),[ or ]."));
ok = false;
diff --git a/src/kile/outputfilter.cpp b/src/kile/outputfilter.cpp
index 6c2108c..a64e00d 100644
--- a/src/kile/outputfilter.cpp
+++ b/src/kile/outputfilter.cpp
@@ -15,9 +15,9 @@
#include "outputfilter.h"
-#include <qfile.h>
-#include <qregexp.h>
-#include <qfileinfo.h>
+#include <tqfile.h>
+#include <tqregexp.h>
+#include <tqfileinfo.h>
#include "kiledebug.h"
#include <ktextedit.h>
@@ -28,7 +28,7 @@
using namespace std;
OutputFilter::OutputFilter() :
- m_log(QString::null)
+ m_log(TQString())
{
}
@@ -36,7 +36,7 @@ OutputFilter::~ OutputFilter()
{
}
-short OutputFilter::parseLine(const QString & /*strLine*/, short /*dwCookie*/)
+short OutputFilter::parseLine(const TQString & /*strLine*/, short /*dwCookie*/)
{
return 0;
}
@@ -47,24 +47,24 @@ bool OutputFilter::OnTerminate()
return true;
}
-void OutputFilter::setSource(const QString &src)
+void OutputFilter::setSource(const TQString &src)
{
m_source = src;
- m_srcPath = QFileInfo(src).dirPath();
+ m_srcPath = TQFileInfo(src).dirPath();
}
-bool OutputFilter::Run(const QString & logfile)
+bool OutputFilter::Run(const TQString & logfile)
{
short sCookie = 0;
- QString s;
- QFile f(logfile);
+ TQString s;
+ TQFile f(logfile);
- m_log = QString::null;
+ m_log = TQString();
m_nOutputLines = 0;
if ( f.open(IO_ReadOnly) )
{
- QTextStream t( &f );
+ TQTextStream t( &f );
while ( !t.eof() )
{
// KILE_DEBUG() << "line " << m_nOutputLines << endl;
diff --git a/src/kile/outputfilter.h b/src/kile/outputfilter.h
index 6b4c5d9..6df171d 100644
--- a/src/kile/outputfilter.h
+++ b/src/kile/outputfilter.h
@@ -16,9 +16,9 @@
#ifndef OUTPUTFILTER_H
#define OUTPUTFILTER_H
-#include <qvaluestack.h>
-#include <qstring.h>
-#include <qwidget.h>
+#include <tqvaluestack.h>
+#include <tqstring.h>
+#include <tqwidget.h>
#include "outputinfo.h"
@@ -31,9 +31,10 @@ of any third-party tool.
class KTextEdit;
-class OutputFilter : public QObject
+class OutputFilter : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
OutputFilter();
@@ -42,21 +43,21 @@ public:
protected:
public:
- virtual bool Run(const QString & logfile);
+ virtual bool Run(const TQString & logfile);
- //void setLog(const QString &log) { m_log = log; }
- const QString & log() const { return m_log; }
+ //void setLog(const TQString &log) { m_log = log; }
+ const TQString & log() const { return m_log; }
- void setSource(const QString &src);
- const QString & source() const { return m_source; }
- const QString & path() const { return m_srcPath; }
+ void setSource(const TQString &src);
+ const TQString & source() const { return m_source; }
+ const TQString & path() const { return m_srcPath; }
signals:
- void problem(int, const QString &);
- void output(const QString &);
+ void problem(int, const TQString &);
+ void output(const TQString &);
protected:
- virtual short parseLine(const QString & strLine, short dwCookie);
+ virtual short parseLine(const TQString & strLine, short dwCookie);
virtual bool OnTerminate();
/**
Returns the zero based index of the currently parsed line in the
@@ -67,6 +68,6 @@ protected:
private:
/** Number of current line in output file */
unsigned int m_nOutputLines;
- QString m_log, m_source, m_srcPath;
+ TQString m_log, m_source, m_srcPath;
};
#endif
diff --git a/src/kile/outputinfo.cpp b/src/kile/outputinfo.cpp
index e4c72e9..aaa6475 100644
--- a/src/kile/outputinfo.cpp
+++ b/src/kile/outputinfo.cpp
@@ -21,8 +21,8 @@ OutputInfo::OutputInfo()
}
-OutputInfo::OutputInfo(const QString & strSrcFile, int nSrcLine, int nOutputLine,
-const QString & strError , int nErrorID /*=-1*/) :
+OutputInfo::OutputInfo(const TQString & strSrcFile, int nSrcLine, int nOutputLine,
+const TQString & strError , int nErrorID /*=-1*/) :
m_strSrcFile(strSrcFile),
m_nSrcLine(nSrcLine),
m_strError(strError),
diff --git a/src/kile/outputinfo.h b/src/kile/outputinfo.h
index 6950cb7..15ee8fb 100644
--- a/src/kile/outputinfo.h
+++ b/src/kile/outputinfo.h
@@ -16,8 +16,8 @@
#ifndef OUTPUTINFO_H
#define OUTPUTINFO_H
-#include <qvaluelist.h>
-#include <qstring.h>
+#include <tqvaluelist.h>
+#include <tqstring.h>
/**Class for output-information of third program (e.g. Latex-Output, C-Compiler output)
@@ -31,13 +31,13 @@ class OutputInfo
{
public:
OutputInfo();
- OutputInfo(const QString & strSrcFile, int nSrcLine, int nOutputLine, const QString & strError ="", int nErrorID=-1);
+ OutputInfo(const TQString & strSrcFile, int nSrcLine, int nOutputLine, const TQString & strError ="", int nErrorID=-1);
public:
/** Source file where error occurred. */
- QString source() const { return m_strSrcFile; }
+ TQString source() const { return m_strSrcFile; }
/** Source file where error occurred. */
- void setSource(const QString & src) { m_strSrcFile = src; }
+ void setSource(const TQString & src) { m_strSrcFile = src; }
/** Line number in source file of the current message */
int sourceLine() const { return m_nSrcLine; }
@@ -45,9 +45,9 @@ class OutputInfo
void setSourceLine(int line) { m_nSrcLine = line; }
/** Error message */
- QString message() const { return m_strError; }
+ TQString message() const { return m_strError; }
/** Error message */
- void setMessage(const QString & message) { m_strError = message; }
+ void setMessage(const TQString & message) { m_strError = message; }
/** Error code */
int type() const { return m_nErrorID; }
@@ -63,9 +63,9 @@ class OutputInfo
void Clear();
private:
- QString m_strSrcFile, m_file;
+ TQString m_strSrcFile, m_file;
int m_nSrcLine;
- QString m_strError;
+ TQString m_strError;
int m_nOutputLine;
int m_nErrorID;
};
@@ -74,5 +74,5 @@ private:
@author Thorsten Lck
*/
-typedef QValueList<OutputInfo> OutputInfoArray;
+typedef TQValueList<OutputInfo> OutputInfoArray;
#endif
diff --git a/src/kile/plaintolatexconverter.cpp b/src/kile/plaintolatexconverter.cpp
index 2072201..489438b 100644
--- a/src/kile/plaintolatexconverter.cpp
+++ b/src/kile/plaintolatexconverter.cpp
@@ -40,19 +40,19 @@ PlainToLaTeXConverter::~PlainToLaTeXConverter(void) {}
* @param toConv The string to convert
* @return The conversion's result
*/
-QString PlainToLaTeXConverter::ConvertToLaTeX(const QString& toConv) const
+TQString PlainToLaTeXConverter::ConvertToLaTeX(const TQString& toConv) const
{
- QString result(toConv);
+ TQString result(toConv);
// Replacing what must be...
uint sSize = result.length();
- QMapConstIterator<QChar, QString> mapEnd = m_replaceMap.end();
+ TQMapConstIterator<TQChar, TQString> mapEnd = m_replaceMap.end();
for(uint i = 0 ; i < sSize ; ++i)
{
- QMapConstIterator<QChar, QString> it = m_replaceMap.find(result.at(i));
+ TQMapConstIterator<TQChar, TQString> it = m_replaceMap.tqfind(result.at(i));
if(it != mapEnd) { // The character must be replaced
- result.replace(i, 1, *it);
+ result.tqreplace(i, 1, *it);
uint len = (*it).length();
if(1 < len) {
i += len - 1;
diff --git a/src/kile/plaintolatexconverter.h b/src/kile/plaintolatexconverter.h
index b5e4619..af896b5 100644
--- a/src/kile/plaintolatexconverter.h
+++ b/src/kile/plaintolatexconverter.h
@@ -19,8 +19,8 @@
#ifndef _PLAINTOLATEXCONVERTER_H_
#define _PLAINTOLATEXCONVERTER_H_
-#include <qmap.h>
-#include <qstring.h>
+#include <tqmap.h>
+#include <tqstring.h>
/**
* A class that replaces the selection in the document (plain text) by its
@@ -32,10 +32,10 @@ public:
PlainToLaTeXConverter(void);
~PlainToLaTeXConverter(void);
- QString ConvertToLaTeX(const QString&) const;
+ TQString ConvertToLaTeX(const TQString&) const;
private:
- QMap<QChar, QString> m_replaceMap;
+ TQMap<TQChar, TQString> m_replaceMap;
};
#endif /* _PLAINTOLATEXCONVERTER_H_ */
diff --git a/src/kile/postscriptdialog.cpp b/src/kile/postscriptdialog.cpp
index 05d780d..e9d3608 100644
--- a/src/kile/postscriptdialog.cpp
+++ b/src/kile/postscriptdialog.cpp
@@ -19,16 +19,16 @@
#include "postscriptdialog.h"
-#include <qlabel.h>
-#include <qlineedit.h>
-#include <qcheckbox.h>
-#include <qpushbutton.h>
-#include <qgroupbox.h>
-#include "qvgroupbox.h"
-#include <qlayout.h>
-#include <qpixmap.h>
-#include <qwhatsthis.h>
-#include <qstringlist.h>
+#include <tqlabel.h>
+#include <tqlineedit.h>
+#include <tqcheckbox.h>
+#include <tqpushbutton.h>
+#include <tqgroupbox.h>
+#include "tqvgroupbox.h"
+#include <tqlayout.h>
+#include <tqpixmap.h>
+#include <tqwhatsthis.h>
+#include <tqstringlist.h>
#include <klocale.h>
#include <kfiledialog.h>
#include <kiconloader.h>
@@ -42,55 +42,55 @@
namespace KileDialog
{
-PostscriptDialog::PostscriptDialog(QWidget *parent,
- const QString &texfilename,const QString &startdir,
- const QString &latexextensions,
+PostscriptDialog::PostscriptDialog(TQWidget *tqparent,
+ const TQString &texfilename,const TQString &startdir,
+ const TQString &latexextensions,
KileWidget::LogMsg *log,KileWidget::Output *output) :
- KDialogBase( parent,0, true, i18n("Rearrange Postscript File"), User1 | Ok, User1, true ),
+ KDialogBase( tqparent,0, true, i18n("Rearrange Postscript File"), User1 | Ok, User1, true ),
m_startdir(startdir),
m_log(log),
m_output(output),
m_proc(0)
{
// determine if a psfile already exists
- QString psfilename;
+ TQString psfilename;
if ( ! texfilename.isEmpty() )
{
// working with a postscript document, so we try to determine the LaTeX source file
- QStringList extlist = QStringList::split( " ", latexextensions );
- for ( QStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
+ TQStringList extlist = TQStringList::split( " ", latexextensions );
+ for ( TQStringList::Iterator it=extlist.begin(); it!=extlist.end(); ++it )
{
- if ( texfilename.find( (*it), -(*it).length() ) >= 0 )
+ if ( texfilename.tqfind( (*it), -(*it).length() ) >= 0 )
{
psfilename = texfilename.left(texfilename.length()-(*it).length()) + ".ps";
- if ( ! QFileInfo(psfilename).exists() )
- psfilename = QString::null;
+ if ( ! TQFileInfo(psfilename).exists() )
+ psfilename = TQString();
break;
}
}
}
// prepare dialog
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(page, 6,6 );
+ TQVBoxLayout *vbox = new TQVBoxLayout(page, 6,6 );
// groupbox with file selection
- QVGroupBox* group= new QVGroupBox(i18n("Parameter"),page );
- QWidget *widget = new QWidget(group);
- QGridLayout *grid = new QGridLayout( widget, 7,3, 6,6, "");
+ TQVGroupBox* group= new TQVGroupBox(i18n("Parameter"),page );
+ TQWidget *widget = new TQWidget(group);
+ TQGridLayout *grid = new TQGridLayout( widget, 7,3, 6,6, "");
grid->setColStretch(1,1);
- // line 0: QLabel
+ // line 0: TQLabel
bool pstops = ! KStandardDirs::findExe("pstops").isNull();
bool psselect = ! KStandardDirs::findExe("psselect").isNull();
- QString title = i18n("Conversion of ps files is made by 'pstops' and 'psselect'.\nBe sure to call 'dvips' with option '-t a4' and\nhyperref package (if needed) with option 'a4paper'.");
+ TQString title = i18n("Conversion of ps files is made by 'pstops' and 'psselect'.\nBe sure to call 'dvips' with option '-t a4' and\nhyperref package (if needed) with option 'a4paper'.");
if ( !pstops || !psselect ) {
- QString msg = QString::null;
+ TQString msg = TQString();
if ( ! pstops ) {
msg = "'pstops'";
if ( ! psselect )
@@ -102,50 +102,50 @@ PostscriptDialog::PostscriptDialog(QWidget *parent,
title += "\n(Error: " + msg + " not found.)";
}
- QLabel *label1 = new QLabel(title,widget);
- label1->setAlignment(Qt::AlignHCenter);
- grid->addMultiCellWidget( label1, 0,0, 0,2, Qt::AlignCenter );
+ TQLabel *label1 = new TQLabel(title,widget);
+ label1->tqsetAlignment(TQt::AlignHCenter);
+ grid->addMultiCellWidget( label1, 0,0, 0,2, TQt::AlignCenter );
// empty line
grid->setRowSpacing(1,10);
- // line 1: QLabel
- QLabel *label2 = new QLabel(i18n("Input file:"), widget);
+ // line 1: TQLabel
+ TQLabel *label2 = new TQLabel(i18n("Input file:"), widget);
grid->addWidget( label2, 2,0 );
- // line 1: QLineEdit
- m_edInfile = new QLineEdit("",widget);
+ // line 1: TQLineEdit
+ m_edInfile = new TQLineEdit("",widget);
m_edInfile->setMinimumWidth(300);
m_edInfile->setText(psfilename);
grid->addWidget( m_edInfile, 2,1 );
// line 1: Choose-Box
- QPushButton *choose_in = new QPushButton("", widget, "infilechooser" );
+ TQPushButton *choose_in = new TQPushButton("", widget, "infilechooser" );
choose_in->setPixmap( SmallIcon("fileopen") );
- choose_in->setFixedWidth(choose_in->sizeHint().width());
+ choose_in->setFixedWidth(choose_in->tqsizeHint().width());
grid->addWidget(choose_in,2,2);
- // line 2: QLabel
- QLabel *label3 = new QLabel(i18n("Output file:"), widget);
+ // line 2: TQLabel
+ TQLabel *label3 = new TQLabel(i18n("Output file:"), widget);
grid->addWidget( label3, 3,0 );
- // line 2: QLineEdit
- m_edOutfile = new QLineEdit("",widget);
+ // line 2: TQLineEdit
+ m_edOutfile = new TQLineEdit("",widget);
m_edOutfile->setMinimumWidth(300);
grid->addWidget( m_edOutfile, 3,1 );
// line 3: choose box
- QPushButton *choose_out = new QPushButton("", widget, "outfilechooser" );
+ TQPushButton *choose_out = new TQPushButton("", widget, "outfilechooser" );
choose_out->setPixmap( SmallIcon("fileopen") );
- choose_out->setFixedWidth(choose_out->sizeHint().width());
+ choose_out->setFixedWidth(choose_out->tqsizeHint().width());
grid->addWidget(choose_out,3,2);
// line 3: task selection
- QLabel *label4 = new QLabel(i18n("Task:"), widget);
+ TQLabel *label4 = new TQLabel(i18n("Task:"), widget);
grid->addWidget( label4, 4,0 );
// line 3: predefined tasks
- m_cbTask = new QComboBox( false,widget );
+ m_cbTask = new TQComboBox( false,widget );
if ( pstops ) {
m_cbTask->insertItem(i18n("1 DIN A5 Page + Empty Page --> DIN A4")); // 0 PS_A5_EMPTY
m_cbTask->insertItem(i18n("1 DIN A5 Page + Duplicate --> DIN A4")); // 1 PS_A5_DUPLICATE
@@ -175,15 +175,15 @@ PostscriptDialog::PostscriptDialog(QWidget *parent,
m_cbTask->setMinimumWidth(300+6+choose_out->width());
grid->addMultiCellWidget( m_cbTask, 4,4,1,2 );
- // line 4: QLabel (parameter or copies)
- m_lbParameter = new QLabel(i18n("Parameter:"), widget);
+ // line 4: TQLabel (parameter or copies)
+ m_lbParameter = new TQLabel(i18n("Parameter:"), widget);
grid->addWidget( m_lbParameter, 5,0 );
- // line 4: QLineEdit or QSoinBox
- m_edParameter = new QLineEdit("",widget);
+ // line 4: TQLineEdit or TQSoinBox
+ m_edParameter = new TQLineEdit("",widget);
m_edParameter->setMinimumWidth(300);
grid->addMultiCellWidget( m_edParameter, 5,5,1,2 );
- m_spCopies = new QSpinBox(widget);
+ m_spCopies = new TQSpinBox(widget);
m_spCopies->setValue(1);
m_spCopies->setRange(1,99);
grid->addMultiCellWidget( m_spCopies, 5,5,1,2 );
@@ -192,12 +192,12 @@ PostscriptDialog::PostscriptDialog(QWidget *parent,
m_cbTask->setCurrentItem(PS_2xA4);
comboboxChanged(PS_2xA4);
- // line 5: QLabel
- QLabel *label6 = new QLabel(i18n("Viewer:"), widget);
+ // line 5: TQLabel
+ TQLabel *label6 = new TQLabel(i18n("Viewer:"), widget);
grid->addWidget( label6, 6,0 );
- // line 5: QCheckBox
- m_cbView = new QCheckBox(i18n("Show ps file with 'kghostview'"),widget);
+ // line 5: TQCheckBox
+ m_cbView = new TQCheckBox(i18n("Show ps file with 'kghostview'"),widget);
m_cbView->setChecked(true);
grid->addWidget( m_cbView, 6,1 );
@@ -211,20 +211,20 @@ PostscriptDialog::PostscriptDialog(QWidget *parent,
if ( !pstops && !psselect )
enableButton(User1,false);
- QWhatsThis::add(m_cbTask,i18n("Choose one of the 18 operations to convert a postscript file. The last four operations need specific parameters."));
- QWhatsThis::add(choose_in,i18n("Choose the input file."));
- QWhatsThis::add(choose_out,i18n("Choose the output file."));
- QWhatsThis::add(m_edInfile,i18n("Input file, which should be converted."));
- QWhatsThis::add(m_edOutfile,i18n("The name of the output file. This entry may also be empty, if you only want to view the result without saving it. In this case the viewer checkbox must be checked."));
- QWhatsThis::add(m_edParameter,i18n("'Select pages' and 'Free Parameter' need some specific parameter, which you can enter here"));
- QWhatsThis::add(m_spCopies,i18n("When you want to copy pages, you must enter the number of copies"));
- QWhatsThis::add(m_cbView,i18n("View the result of the conversion process. KGhostview is always taken as an external viewer."));
+ TQWhatsThis::add(m_cbTask,i18n("Choose one of the 18 operations to convert a postscript file. The last four operations need specific parameters."));
+ TQWhatsThis::add(choose_in,i18n("Choose the input file."));
+ TQWhatsThis::add(choose_out,i18n("Choose the output file."));
+ TQWhatsThis::add(m_edInfile,i18n("Input file, which should be converted."));
+ TQWhatsThis::add(m_edOutfile,i18n("The name of the output file. This entry may also be empty, if you only want to view the result without saving it. In this case the viewer checkbox must be checked."));
+ TQWhatsThis::add(m_edParameter,i18n("'Select pages' and 'Free Parameter' need some specific parameter, which you can enter here"));
+ TQWhatsThis::add(m_spCopies,i18n("When you want to copy pages, you must enter the number of copies"));
+ TQWhatsThis::add(m_cbView,i18n("View the result of the conversion process. KGhostview is always taken as an external viewer."));
// some connections
- connect( choose_in, SIGNAL( clicked() ), this, SLOT( chooseInfile() ) );
- connect( choose_out, SIGNAL( clicked() ), this, SLOT( chooseOutfile() ) );
- connect( m_cbTask,SIGNAL( activated(int) ),this, SLOT( comboboxChanged(int) ) );
- connect( this, SIGNAL(output(const QString &)), m_output, SLOT(receive(const QString &)) );
+ connect( choose_in, TQT_SIGNAL( clicked() ), this, TQT_SLOT( chooseInfile() ) );
+ connect( choose_out, TQT_SIGNAL( clicked() ), this, TQT_SLOT( chooseOutfile() ) );
+ connect( m_cbTask,TQT_SIGNAL( activated(int) ),this, TQT_SLOT( comboboxChanged(int) ) );
+ connect( this, TQT_SIGNAL(output(const TQString &)), m_output, TQT_SLOT(receive(const TQString &)) );
setFocusProxy( m_edInfile );
@@ -246,20 +246,20 @@ void PostscriptDialog::slotUser1()
void PostscriptDialog::execute()
{
m_tempfile = buildTempfile();
- if ( m_tempfile != QString::null ) {
+ if ( m_tempfile != TQString() ) {
m_log->clear();
- QFileInfo from(m_edInfile->text());
- QFileInfo to(m_edOutfile->text());
+ TQFileInfo from(m_edInfile->text());
+ TQFileInfo to(m_edOutfile->text());
// output for log window
- QString msg = i18n("rearrange ps file: ") + from.fileName();
+ TQString msg = i18n("rearrange ps file: ") + from.fileName();
if ( ! to.fileName().isEmpty() )
msg += " ---> " + to.fileName();
m_log->printMsg(KileTool::Info,msg,m_program);
// some output logs
m_output->clear();
- QString s = QString("*****\n")
+ TQString s = TQString("*****\n")
+ i18n("***** tool: ") + m_program + ' ' + m_param + '\n'
+ i18n("***** input file: ") + from.fileName()+ '\n'
+ i18n("***** output file: ") + to.fileName()+ '\n'
@@ -273,14 +273,14 @@ void PostscriptDialog::execute()
m_proc = new KShellProcess();
m_proc->clearArguments();
- (*m_proc) << QStringList::split(' ',"sh " + m_tempfile);
+ (*m_proc) << TQStringList::split(' ',"sh " + m_tempfile);
- connect(m_proc, SIGNAL(receivedStdout(KProcess *,char *,int)),
- this, SLOT(slotProcessOutput(KProcess *,char *,int)));
- connect(m_proc, SIGNAL(receivedStderr(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(processExited(KProcess *)),
- this, SLOT(slotProcessExited(KProcess *)));
+ connect(m_proc, TQT_SIGNAL(receivedStdout(KProcess *,char *,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess *,char *,int)));
+ connect(m_proc, TQT_SIGNAL(receivedStderr(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(processExited(KProcess *)),
+ this, TQT_SLOT(slotProcessExited(KProcess *)));
KILE_DEBUG() << "=== PostscriptDialog::runPsutils() ====================" << endl;
KILE_DEBUG() << " execute '" << m_tempfile << "'" << endl;
@@ -293,7 +293,7 @@ void PostscriptDialog::execute()
void PostscriptDialog::slotProcessOutput(KProcess*,char* buf,int len)
{
- emit( output(QCString(buf,len+1)) );
+ emit( output(TQCString(buf,len+1)) );
}
@@ -302,10 +302,10 @@ void PostscriptDialog::slotProcessExited (KProcess *proc)
if ( ! proc->normalExit() )
showError(i18n("An error occurred, while rearranging the file."));
- QFile::remove(m_tempfile);
+ TQFile::remove(m_tempfile);
}
-QString PostscriptDialog::buildTempfile()
+TQString PostscriptDialog::buildTempfile()
{
// build command
m_program = "pstops"; // default
@@ -360,14 +360,14 @@ QString PostscriptDialog::buildTempfile()
}
// create a temporary file
- KTempFile temp(QString::null,".sh");
- QString tempname = temp.name();
+ KTempFile temp(TQString(),".sh");
+ TQString tempname = temp.name();
- QTextStream *stream = temp.textStream();
+ TQTextStream *stream = temp.textStream();
*stream << "#! /bin/sh" << endl;
// accept only ".ps" or ".ps.gz" as an input file
- QFileInfo fi( m_edInfile->text() );
+ TQFileInfo fi( m_edInfile->text() );
bool zipped_psfile = ( fi.extension() == "ps.gz" ) ? true : false;
// there are four possible cases
@@ -378,9 +378,9 @@ QString PostscriptDialog::buildTempfile()
// 4) - - error (already detected by checkParameter())
// some files, which are used
- QString command = m_program + " \"" + m_param + "\"";
- QString inputfile = "\"" + m_edInfile->text() + "\"";
- QString outputfile = "\"" + m_edOutfile->text() + "\"";
+ TQString command = m_program + " \"" + m_param + "\"";
+ TQString inputfile = "\"" + m_edInfile->text() + "\"";
+ TQString outputfile = "\"" + m_edOutfile->text() + "\"";
bool viewer = m_cbView->isChecked();
bool equalfiles = false;
@@ -437,7 +437,7 @@ QString PostscriptDialog::buildTempfile()
void PostscriptDialog::chooseInfile()
{
- QString fn = KFileDialog::getOpenFileName(
+ TQString fn = KFileDialog::getOpenFileName(
m_startdir,
i18n("*.ps|PS Files\n*.ps.gz|Zipped PS Files"),
this,i18n("Select Input File") );
@@ -449,7 +449,7 @@ void PostscriptDialog::chooseInfile()
void PostscriptDialog::chooseOutfile()
{
- QString fn = KFileDialog::getOpenFileName(
+ TQString fn = KFileDialog::getOpenFileName(
m_startdir,
i18n("*.ps|PS Files"),
this,i18n("Select Name of Output File") );
@@ -459,9 +459,9 @@ void PostscriptDialog::chooseOutfile()
}
}
-QString PostscriptDialog::duplicateParameter(const QString &param)
+TQString PostscriptDialog::duplicateParameter(const TQString &param)
{
- QString s = QString::null;
+ TQString s = TQString();
for (int i=0; i<m_spCopies->value(); ++i) {
if ( i == 0 )
s += param;
@@ -475,13 +475,13 @@ QString PostscriptDialog::duplicateParameter(const QString &param)
bool PostscriptDialog::checkParameter()
{
- QString infile = m_edInfile->text();
+ TQString infile = m_edInfile->text();
if ( infile.isEmpty() ) {
showError( i18n("No input file is given.") );
return false;
}
- QFileInfo fi( infile );
+ TQFileInfo fi( infile );
if ( fi.extension()!="ps" && fi.extension()!="ps.gz" ) {
showError( i18n("Unknown file format: only '.ps' and '.ps.gz' are accepted for input files.") );
return false;
@@ -504,21 +504,21 @@ bool PostscriptDialog::checkParameter()
}
}
- QString outfile = m_edOutfile->text();
+ TQString outfile = m_edOutfile->text();
if ( outfile.isEmpty() && !m_cbView->isChecked() ) {
showError( i18n("You need to define an output file or select the viewer.") );
return false;
}
if ( ! outfile.isEmpty() ) {
- QFileInfo fo( outfile );
+ TQFileInfo fo( outfile );
if ( fo.extension() != "ps" ) {
showError( i18n("Unknown file format: only '.ps' is accepted as output file.") );
return false;
}
if ( infile!=outfile && fo.exists() ) {
- QString s = i18n("A file named \"%1\" already exists. Are you sure you want to overwrite it?").arg(fo.fileName());
+ TQString s = i18n("A file named \"%1\" already exists. Are you sure you want to overwrite it?").tqarg(fo.fileName());
if ( KMessageBox::questionYesNo( this,
"<center>" + s + "</center>",
"Postscript tools" ) == KMessageBox::No ) {
@@ -552,7 +552,7 @@ void PostscriptDialog::comboboxChanged(int index)
}
}
-void PostscriptDialog::showError(const QString &text)
+void PostscriptDialog::showError(const TQString &text)
{
KMessageBox::error( this,i18n("<center>") + text + i18n("</center>"),i18n("Postscript Tools") );
}
diff --git a/src/kile/postscriptdialog.h b/src/kile/postscriptdialog.h
index 05cc68e..b71a5f7 100644
--- a/src/kile/postscriptdialog.h
+++ b/src/kile/postscriptdialog.h
@@ -18,11 +18,11 @@
#define POSTSCRIPTDIALOG_H
#include <kdialogbase.h>
-#include <qcombobox.h>
-#include <qcheckbox.h>
-#include <qspinbox.h>
-#include <qlineedit.h>
-#include <qstring.h>
+#include <tqcombobox.h>
+#include <tqcheckbox.h>
+#include <tqspinbox.h>
+#include <tqlineedit.h>
+#include <tqstring.h>
#include <kprocess.h>
#include "kilelogwidget.h"
@@ -55,16 +55,17 @@ namespace KileDialog
class PostscriptDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- PostscriptDialog(QWidget *parent,
- const QString &texfilename,const QString &startdir,
- const QString &latexextensions,
+ PostscriptDialog(TQWidget *tqparent,
+ const TQString &texfilename,const TQString &startdir,
+ const TQString &latexextensions,
KileWidget::LogMsg *log, KileWidget::Output *output);
~PostscriptDialog();
signals:
- void output(const QString &);
+ void output(const TQString &);
private slots:
void chooseInfile();
@@ -76,24 +77,24 @@ private slots:
private:
bool checkParameter();
- QString buildTempfile();
- QString duplicateParameter(const QString &param);
- void showError(const QString &text);
+ TQString buildTempfile();
+ TQString duplicateParameter(const TQString &param);
+ void showError(const TQString &text);
void execute();
- QLineEdit *m_edInfile, *m_edOutfile, *m_edParameter;
- QComboBox *m_cbTask;
- QCheckBox *m_cbView;
- QSpinBox *m_spCopies;
- QLabel *m_lbParameter;
+ TQLineEdit *m_edInfile, *m_edOutfile, *m_edParameter;
+ TQComboBox *m_cbTask;
+ TQCheckBox *m_cbView;
+ TQSpinBox *m_spCopies;
+ TQLabel *m_lbParameter;
- QString m_startdir;
+ TQString m_startdir;
KileWidget::LogMsg *m_log;
KileWidget::Output *m_output;
- QString m_tempfile;
- QString m_program;
- QString m_param;
+ TQString m_tempfile;
+ TQString m_program;
+ TQString m_param;
KShellProcess* m_proc;
diff --git a/src/kile/previewconfigwidget.cpp b/src/kile/previewconfigwidget.cpp
index 3611364..65e6ffc 100644
--- a/src/kile/previewconfigwidget.cpp
+++ b/src/kile/previewconfigwidget.cpp
@@ -20,31 +20,31 @@
#include <klocale.h>
#include "kiledebug.h"
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qstringlist.h>
-#include <qmap.h>
-#include <qvalidator.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqstringlist.h>
+#include <tqmap.h>
+#include <tqvalidator.h>
#include "kileconfig.h"
-KileWidgetPreviewConfig::KileWidgetPreviewConfig(KConfig *config, KileTool::QuickPreview *preview, QWidget *parent, const char *name )
- : QWidget(parent,name),
+KileWidgetPreviewConfig::KileWidgetPreviewConfig(KConfig *config, KileTool::QuickPreview *preview, TQWidget *tqparent, const char *name )
+ : TQWidget(tqparent,name),
m_config(config),
m_preview(preview)
{
// Layout
- QVBoxLayout *vbox = new QVBoxLayout(this, 5,5 );
+ TQVBoxLayout *vbox = new TQVBoxLayout(this, 5,5 );
- QGroupBox *groupbox = new QGroupBox( i18n("Quick Preview in a separate window"), this, "groupbox" );
- groupbox->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5, (QSizePolicy::SizeType)1, 0, 0, groupbox->sizePolicy().hasHeightForWidth() ) );
+ TQGroupBox *groupbox = new TQGroupBox( i18n("Quick Preview in a separate window"), this, "groupbox" );
+ groupbox->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)1, 0, 0, groupbox->sizePolicy().hasHeightForWidth() ) );
groupbox->setColumnLayout(0, Qt::Vertical );
- groupbox->layout()->setSpacing( 6 );
- groupbox->layout()->setMargin( 11 );
- QGridLayout *groupboxLayout = new QGridLayout( groupbox->layout() );
- groupboxLayout->setAlignment( Qt::AlignTop );
+ groupbox->tqlayout()->setSpacing( 6 );
+ groupbox->tqlayout()->setMargin( 11 );
+ TQGridLayout *groupboxLayout = new TQGridLayout( groupbox->tqlayout() );
+ groupboxLayout->tqsetAlignment( TQt::AlignTop );
- QLabel *label = new QLabel( i18n("Select a configuration:"), groupbox, "label");
+ TQLabel *label = new TQLabel( i18n("Select a configuration:"), groupbox, "label");
m_combobox = new KComboBox(false,groupbox,"combobox" );
groupboxLayout->addWidget(label,0,0);
@@ -52,40 +52,40 @@ KileWidgetPreviewConfig::KileWidgetPreviewConfig(KConfig *config, KileTool::Quic
groupboxLayout->setColSpacing(1,8);
groupboxLayout->setColStretch(3,1);
- QGroupBox *gbResolution = new QGroupBox( i18n("Quick Preview in bottom bar"), this, "gbresolution" );
+ TQGroupBox *gbResolution = new TQGroupBox( i18n("Quick Preview in bottom bar"), this, "gbresolution" );
gbResolution->setColumnLayout(0, Qt::Vertical );
- gbResolution->layout()->setSpacing( 6 );
- gbResolution->layout()->setMargin( 11 );
- QGridLayout *resLayout = new QGridLayout( gbResolution->layout() );
- resLayout->setAlignment( Qt::AlignTop );
+ gbResolution->tqlayout()->setSpacing( 6 );
+ gbResolution->tqlayout()->setMargin( 11 );
+ TQGridLayout *resLayout = new TQGridLayout( gbResolution->tqlayout() );
+ resLayout->tqsetAlignment( TQt::AlignTop );
- QLabel *resLabel = new QLabel( i18n("&Resolution:"), gbResolution );
+ TQLabel *resLabel = new TQLabel( i18n("&Resolution:"), gbResolution );
m_leDvipngResolution = new KLineEdit( gbResolution, "DvipngResolution" );
- QLabel *resDpi = new QLabel( i18n("dpi"), gbResolution );
- QLabel *resAllowed = new QLabel( i18n("(allowed values: 30-1000 dpi)"), gbResolution );
+ TQLabel *resDpi = new TQLabel( i18n("dpi"), gbResolution );
+ TQLabel *resAllowed = new TQLabel( i18n("(allowed values: 30-1000 dpi)"), gbResolution );
// set validator
- QValidator* validator = new QIntValidator(30,1000,this);
+ TQValidator* validator = new TQIntValidator(30,1000,TQT_TQOBJECT(this));
m_leDvipngResolution->setValidator(validator);
resLabel->setBuddy(m_leDvipngResolution);
- QString sep = "&nbsp;&nbsp;&nbsp;&nbsp;";
- QString title = i18n("Kile supports three kinds of conversion to png images");
- QString tool1 = i18n("dvi --> png") + sep + i18n("(uses dvipng)");
- QString tool2 = i18n("dvi --> ps --> png") + sep + i18n("(uses dvips/convert)");
- QString tool3 = i18n("pdf --> png") + sep + i18n("(uses convert)");
- QString description = QString("%1:<ul><li>%2<li>%3<li>%4</ul>").arg(title).arg(tool1).arg(tool2).arg(tool3);
-
- QLabel *labelDescription = new QLabel(description, gbResolution);
- QLabel *labelDvipng = new QLabel(i18n("dvipng:"), gbResolution);
- QLabel *labelConvert = new QLabel(i18n("convert:"), gbResolution);
- m_lbDvipng = new QLabel(gbResolution);
- m_lbConvert = new QLabel(gbResolution);
+ TQString sep = "&nbsp;&nbsp;&nbsp;&nbsp;";
+ TQString title = i18n("Kile supports three kinds of conversion to png images");
+ TQString tool1 = i18n("dvi --> png") + sep + i18n("(uses dvipng)");
+ TQString tool2 = i18n("dvi --> ps --> png") + sep + i18n("(uses dvips/convert)");
+ TQString tool3 = i18n("pdf --> png") + sep + i18n("(uses convert)");
+ TQString description = TQString("%1:<ul><li>%2<li>%3<li>%4</ul>").tqarg(title).tqarg(tool1).tqarg(tool2).tqarg(tool3);
+
+ TQLabel *labelDescription = new TQLabel(description, gbResolution);
+ TQLabel *labelDvipng = new TQLabel(i18n("dvipng:"), gbResolution);
+ TQLabel *labelConvert = new TQLabel(i18n("convert:"), gbResolution);
+ m_lbDvipng = new TQLabel(gbResolution);
+ m_lbConvert = new TQLabel(gbResolution);
resLayout->addWidget(resLabel,0,0);
resLayout->addWidget(m_leDvipngResolution,0,2);
resLayout->addWidget(resDpi,0,3);
- resLayout->addWidget(resAllowed,0,5,Qt::AlignLeft);
+ resLayout->addWidget(resAllowed,0,5,TQt::AlignLeft);
resLayout->addMultiCellWidget(labelDescription,1,1,0,5);
resLayout->addWidget(labelDvipng,2,0);
resLayout->addWidget(m_lbDvipng,2,2);
@@ -95,26 +95,26 @@ KileWidgetPreviewConfig::KileWidgetPreviewConfig(KConfig *config, KileTool::Quic
resLayout->setColSpacing(4,24);
resLayout->setColStretch(5,1);
- m_gbPreview = new QGroupBox( i18n("Properties"), this, "gbpreview" );
+ m_gbPreview = new TQGroupBox( i18n("Properties"), this, "gbpreview" );
m_gbPreview->setColumnLayout(0, Qt::Vertical );
- m_gbPreview->layout()->setSpacing( 6 );
- m_gbPreview->layout()->setMargin( 11 );
- QGridLayout *previewLayout = new QGridLayout( m_gbPreview->layout() );
- previewLayout->setAlignment( Qt::AlignTop );
-
- QLabel *labelPreviewWidget = new QLabel(i18n("Show preview in bottom bar:"), m_gbPreview);
- QLabel *labelPreviewType = new QLabel(i18n("Conversion to image:"), m_gbPreview);
- QLabel *labelSelection = new QLabel(i18n("Selection:"), m_gbPreview);
- QLabel *labelEnvironment = new QLabel(i18n("Environment:"), m_gbPreview);
- QLabel *labelMathgroup = new QLabel(i18n("Mathgroup:"), m_gbPreview);
- QLabel *labelSubdocument1 = new QLabel(i18n("Subdocument:"), m_gbPreview);
- QLabel *labelSubdocument2 = new QLabel(i18n("Not available, opens always in a separate window."), m_gbPreview);
- m_cbSelection = new QCheckBox(m_gbPreview);
- m_cbEnvironment = new QCheckBox(m_gbPreview);
- m_cbMathgroup = new QCheckBox(m_gbPreview);
+ m_gbPreview->tqlayout()->setSpacing( 6 );
+ m_gbPreview->tqlayout()->setMargin( 11 );
+ TQGridLayout *previewLayout = new TQGridLayout( m_gbPreview->tqlayout() );
+ previewLayout->tqsetAlignment( TQt::AlignTop );
+
+ TQLabel *labelPreviewWidget = new TQLabel(i18n("Show preview in bottom bar:"), m_gbPreview);
+ TQLabel *labelPreviewType = new TQLabel(i18n("Conversion to image:"), m_gbPreview);
+ TQLabel *labelSelection = new TQLabel(i18n("Selection:"), m_gbPreview);
+ TQLabel *labelEnvironment = new TQLabel(i18n("Environment:"), m_gbPreview);
+ TQLabel *labelMathgroup = new TQLabel(i18n("Mathgroup:"), m_gbPreview);
+ TQLabel *labelSubdocument1 = new TQLabel(i18n("Subdocument:"), m_gbPreview);
+ TQLabel *labelSubdocument2 = new TQLabel(i18n("Not available, opens always in a separate window."), m_gbPreview);
+ m_cbSelection = new TQCheckBox(m_gbPreview);
+ m_cbEnvironment = new TQCheckBox(m_gbPreview);
+ m_cbMathgroup = new TQCheckBox(m_gbPreview);
m_coSelection = new KComboBox(false,m_gbPreview);
m_coEnvironment = new KComboBox(false,m_gbPreview);
- m_lbMathgroup = new QLabel(i18n("Preview uses always 'dvipng'."), m_gbPreview);
+ m_lbMathgroup = new TQLabel(i18n("Preview uses always 'dvipng'."), m_gbPreview);
previewLayout->addMultiCellWidget(labelPreviewWidget,0,0,0,2);
previewLayout->addWidget(labelPreviewType,0,4);
@@ -126,11 +126,11 @@ KileWidgetPreviewConfig::KileWidgetPreviewConfig(KConfig *config, KileTool::Quic
previewLayout->addWidget(m_coEnvironment,2,4);
previewLayout->addWidget(labelMathgroup,3,0);
previewLayout->addWidget(m_cbMathgroup,3,2);
- previewLayout->addMultiCellWidget(m_lbMathgroup,3,3,4,5,Qt::AlignLeft);
+ previewLayout->addMultiCellWidget(m_lbMathgroup,3,3,4,5,TQt::AlignLeft);
previewLayout->addWidget(labelSubdocument1,4,0);
- previewLayout->addMultiCellWidget(labelSubdocument2,4,4,2,5,Qt::AlignLeft);
- previewLayout->setRowSpacing(0,3*labelPreviewWidget->sizeHint().height()/2);
- previewLayout->setRowSpacing(3,m_coEnvironment->sizeHint().height());
+ previewLayout->addMultiCellWidget(labelSubdocument2,4,4,2,5,TQt::AlignLeft);
+ previewLayout->setRowSpacing(0,3*labelPreviewWidget->tqsizeHint().height()/2);
+ previewLayout->setRowSpacing(3,m_coEnvironment->tqsizeHint().height());
previewLayout->setColSpacing(1,12);
previewLayout->setColSpacing(3,40);
previewLayout->setColStretch(5,1);
@@ -140,9 +140,9 @@ KileWidgetPreviewConfig::KileWidgetPreviewConfig(KConfig *config, KileTool::Quic
vbox->addWidget(m_gbPreview);
vbox->addStretch();
- connect(m_cbEnvironment,SIGNAL(clicked()),this,SLOT(updateConversionTools()));
- connect(m_cbSelection,SIGNAL(clicked()),this,SLOT(updateConversionTools()));
- connect(m_cbMathgroup,SIGNAL(clicked()),this,SLOT(updateConversionTools()));
+ connect(m_cbEnvironment,TQT_SIGNAL(clicked()),this,TQT_SLOT(updateConversionTools()));
+ connect(m_cbSelection,TQT_SIGNAL(clicked()),this,TQT_SLOT(updateConversionTools()));
+ connect(m_cbMathgroup,TQT_SIGNAL(clicked()),this,TQT_SLOT(updateConversionTools()));
}
//////////////////// read/write configuration ////////////////////
@@ -161,7 +161,7 @@ void KileWidgetPreviewConfig::writeConfig(void)
KileConfig::setPreviewTask( m_combobox->currentText() );
bool ok;
- QString resolution = m_leDvipngResolution->text();
+ TQString resolution = m_leDvipngResolution->text();
int dpi = resolution.toInt(&ok);
if ( ok )
{
@@ -191,14 +191,14 @@ void KileWidgetPreviewConfig::writeConfig(void)
void KileWidgetPreviewConfig::setupSeparateWindow()
{
// get all possible tasks for QuickPreview in a separate window
- QStringList tasklist;
+ TQStringList tasklist;
m_preview->getTaskList(tasklist);
// split them into group and combobox entry
m_combobox->clear();
for ( uint i=0; i<tasklist.count(); ++i )
{
- QStringList list = QStringList::split("=",tasklist[i]);
+ TQStringList list = TQStringList::split("=",tasklist[i]);
if ( m_config->hasGroup( list[0] ) )
{
m_combobox->insertItem( list[1] );
@@ -230,7 +230,7 @@ void KileWidgetPreviewConfig::setupProperties()
m_cbMathgroup->setChecked( KileConfig::mathgroupPreviewInWidget() );
// setup conversion tools
- QStringList toollist;
+ TQStringList toollist;
if ( m_dvipngInstalled )
{
toollist << i18n("dvi --> png");
diff --git a/src/kile/previewconfigwidget.h b/src/kile/previewconfigwidget.h
index 0bf907c..b2b942e 100644
--- a/src/kile/previewconfigwidget.h
+++ b/src/kile/previewconfigwidget.h
@@ -19,9 +19,9 @@
#include "quickpreview.h"
-#include <qwidget.h>
-#include <qcheckbox.h>
-#include <qgroupbox.h>
+#include <tqwidget.h>
+#include <tqcheckbox.h>
+#include <tqgroupbox.h>
#include <kcombobox.h>
#include <klineedit.h>
#include <kconfig.h>
@@ -30,11 +30,12 @@
*@author Holger Danielsson
*/
-class KileWidgetPreviewConfig : public QWidget
+class KileWidgetPreviewConfig : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- KileWidgetPreviewConfig(KConfig *config, KileTool::QuickPreview *preview, QWidget *parent=0, const char *name=0);
+ KileWidgetPreviewConfig(KConfig *config, KileTool::QuickPreview *preview, TQWidget *tqparent=0, const char *name=0);
~KileWidgetPreviewConfig() {}
void readConfig(void);
@@ -45,10 +46,10 @@ private:
KComboBox *m_combobox;
KileTool::QuickPreview *m_preview;
KLineEdit *m_leDvipngResolution;
- QLabel *m_lbDvipng, *m_lbConvert, *m_lbMathgroup;
- QCheckBox *m_cbEnvironment, *m_cbSelection, *m_cbMathgroup;
+ TQLabel *m_lbDvipng, *m_lbConvert, *m_lbMathgroup;
+ TQCheckBox *m_cbEnvironment, *m_cbSelection, *m_cbMathgroup;
KComboBox *m_coSelection, *m_coEnvironment;
- QGroupBox *m_gbPreview;
+ TQGroupBox *m_gbPreview;
bool m_dvipngInstalled, m_convertInstalled;
diff --git a/src/kile/previewwidget.cpp b/src/kile/previewwidget.cpp
index a3b41ed..5fff79d 100644
--- a/src/kile/previewwidget.cpp
+++ b/src/kile/previewwidget.cpp
@@ -20,10 +20,10 @@
#include "previewwidget.h"
-#include <qimage.h>
-#include <qpainter.h>
-#include <qpalette.h>
-#include <qwidget.h>
+#include <tqimage.h>
+#include <tqpainter.h>
+#include <tqpalette.h>
+#include <tqwidget.h>
#include <klocale.h>
#include <kate/view.h>
@@ -41,10 +41,10 @@
namespace KileWidget
{
-PreviewWidget::PreviewWidget(KileInfo *info, QWidget *parent, const char *name)
- : QWidget(parent,name), m_info(info), m_previewImage(0L), m_running(false)
+PreviewWidget::PreviewWidget(KileInfo *info, TQWidget *tqparent, const char *name)
+ : TQWidget(tqparent,name), m_info(info), m_previewImage(0L), m_running(false)
{
- setPalette( QPalette(QColor(0xff,0xff,0xff)) );
+ setPalette( TQPalette(TQColor(0xff,0xff,0xff)) );
}
@@ -53,14 +53,14 @@ PreviewWidget::~PreviewWidget()
delete m_previewImage;
}
-void PreviewWidget::paintEvent(QPaintEvent*)
+void PreviewWidget::paintEvent(TQPaintEvent*)
{
- QPainter p(this);
+ TQPainter p(this);
if ( m_previewImage )
p.drawImage(3,3,*m_previewImage);
}
-void PreviewWidget::showActivePreview(const QString &text,const QString &textfilename,int startrow,int previewtype)
+void PreviewWidget::showActivePreview(const TQString &text,const TQString &textfilename,int startrow,int previewtype)
{
KILE_DEBUG() << "==PreviewWidget::showActivePreview()==========================" << endl;
m_info->logWidget()->clear();
@@ -81,7 +81,7 @@ void PreviewWidget::showActivePreview(const QString &text,const QString &textfil
// set parameter for these tools
- QString tasklist,tool,toolcfg,extension;
+ TQString tasklist,tool,toolcfg,extension;
if (conversiontype == pwConvert )
{
m_conversionTool = "convert";
@@ -103,7 +103,7 @@ void PreviewWidget::showActivePreview(const QString &text,const QString &textfil
m_conversionTool = "dvipng";
tasklist = "PreviewLaTeX,,,,,png";
tool = "DVItoPNG";
- toolcfg = QString::null;
+ toolcfg = TQString();
extension = "dvi";
}
@@ -113,7 +113,7 @@ void PreviewWidget::showActivePreview(const QString &text,const QString &textfil
KileTool::Base *pngConverter = m_info->toolFactory()->create(tool);
if ( ! pngConverter )
{
- showError( QString(i18n("Could not run '%1' for QuickPreview.").arg(tool)) );
+ showError( TQString(i18n("Could not run '%1' for QuickPreview.").tqarg(tool)) );
return;
}
pngConverter->setSource(m_info->quickPreview()->getPreviewFile(extension));
@@ -121,14 +121,14 @@ void PreviewWidget::showActivePreview(const QString &text,const QString &textfil
// First, we have to disconnect the old done() signal, because this is
// passed immediately to the toolmanager, whichs destroys the tool. This
// means, that all connections, which are done later, will never been called.
- disconnect(pngConverter, SIGNAL(done(Base*,int)), m_info->toolManager(), SLOT(done(Base*,int)));
+ disconnect(pngConverter, TQT_SIGNAL(done(Base*,int)), m_info->toolManager(), TQT_SLOT(done(Base*,int)));
// Now we make some new connections, which are called in this sequence:
// 1) when the tool is finished, the preview will be shown
// 2) then the done() signal can be passed to the toolmanager,
// which destroys the tool
- connect(pngConverter, SIGNAL(done (Base*,int)), this, SLOT(drawImage()));
- connect(pngConverter, SIGNAL(done(Base*,int)), m_info->toolManager(), SLOT(done(Base*,int)));
+ connect(pngConverter, TQT_SIGNAL(done (Base*,int)), this, TQT_SLOT(drawImage()));
+ connect(pngConverter, TQT_SIGNAL(done(Base*,int)), m_info->toolManager(), TQT_SLOT(done(Base*,int)));
// Finally we will send a signal, which will pass the focus from the log window
// to the formula preview (dvipng --> toolmanager --> kile)
@@ -143,8 +143,8 @@ void PreviewWidget::showActivePreview(const QString &text,const QString &textfil
// - we can distinguish between drawImage() and focusPreview(), which may be
// important some time
// - it is more complicated
- connect(pngConverter, SIGNAL(destroyed()), m_info->toolManager(), SIGNAL(previewDone()));
- connect(pngConverter, SIGNAL(destroyed()), this, SLOT(toolDestroyed()));
+ connect(pngConverter, TQT_SIGNAL(destroyed()), m_info->toolManager(), TQT_SIGNAL(previewDone()));
+ connect(pngConverter, TQT_SIGNAL(destroyed()), this, TQT_SLOT(toolDestroyed()));
// Now we are ready to start the process...
if ( m_info->toolManager()->run(pngConverter,toolcfg) == KileTool::Running )
@@ -157,10 +157,10 @@ void PreviewWidget::drawImage()
if ( ! m_previewImage )
delete m_previewImage;
- m_previewImage = new QImage (m_info->quickPreview()->getPreviewFile ("png"));
+ m_previewImage = new TQImage (m_info->quickPreview()->getPreviewFile ("png"));
setFixedSize( m_previewImage->width()+6,m_previewImage->height()+6 );
- repaint ();
+ tqrepaint ();
}
void PreviewWidget::toolDestroyed()
@@ -169,7 +169,7 @@ void PreviewWidget::toolDestroyed()
m_running = false;
}
-void PreviewWidget::showError(const QString &text)
+void PreviewWidget::showError(const TQString &text)
{
m_info->logWidget()->printMsg( KileTool::Error, text, i18n("QuickPreview") );
}
diff --git a/src/kile/previewwidget.h b/src/kile/previewwidget.h
index 5eeb1b0..313d611 100644
--- a/src/kile/previewwidget.h
+++ b/src/kile/previewwidget.h
@@ -12,10 +12,10 @@
#ifndef PREVIEWWIDGET_H
#define PREVIEWWIDGET_H
-#include <qwidget.h>
+#include <tqwidget.h>
-class QImage;
-class QPaintEvent;
+class TQImage;
+class TQPaintEvent;
class KileInfo;
@@ -46,12 +46,13 @@ namespace KileWidget
* @author Mathias Soeken <msoeken@informatik.uni-bremen.de>
*/
-class PreviewWidget : public QWidget
+class PreviewWidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- PreviewWidget(KileInfo *info, QWidget *parent = 0, const char *name = 0);
+ PreviewWidget(KileInfo *info, TQWidget *tqparent = 0, const char *name = 0);
~PreviewWidget();
/**
@@ -65,19 +66,19 @@ public:
* This PNG image is then displayed on the
* widget.
*/
- void showActivePreview(const QString &text,const QString &textfilename,int startrow,int previewtype);
+ void showActivePreview(const TQString &text,const TQString &textfilename,int startrow,int previewtype);
private:
enum { pwDvipng=0, pwDvipsConvert, pwConvert };
KileInfo *m_info;
- QImage *m_previewImage;
+ TQImage *m_previewImage;
bool m_running;
- QString m_conversionTool;
+ TQString m_conversionTool;
protected:
- void paintEvent (QPaintEvent*);
- void showError(const QString &text);
+ void paintEvent (TQPaintEvent*);
+ void showError(const TQString &text);
public slots:
/**
diff --git a/src/kile/processtoolconfigwidget.ui b/src/kile/processtoolconfigwidget.ui
index 840a444..6502764 100644
--- a/src/kile/processtoolconfigwidget.ui
+++ b/src/kile/processtoolconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>ProcessToolConfigWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>ProcessToolConfigWidget</cstring>
</property>
@@ -53,7 +53,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>m_lbOptions</cstring>
</property>
@@ -64,7 +64,7 @@
<cstring>m_leOptions</cstring>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbCommand</cstring>
</property>
@@ -85,7 +85,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>16</height>
@@ -94,5 +94,5 @@
</spacer>
</grid>
</widget>
-<layoutdefaults spacing="11" margin="11"/>
+<tqlayoutdefaults spacing="11" margin="11"/>
</UI>
diff --git a/src/kile/quickdocumentdialog.cpp b/src/kile/quickdocumentdialog.cpp
index caff295..e23dd0d 100644
--- a/src/kile/quickdocumentdialog.cpp
+++ b/src/kile/quickdocumentdialog.cpp
@@ -18,19 +18,19 @@ email : holger.danielsson@t-online.de
#include "quickdocumentdialog.h"
-#include <qstringlist.h>
-#include <qtabwidget.h>
-#include <qlayout.h>
-#include <qwidget.h>
-#include <qcheckbox.h>
-#include <qlabel.h>
-#include <qlistbox.h>
-#include <qpainter.h>
-#include <qpalette.h>
-#include <qstyle.h>
-#include <qlistview.h>
-#include <qwhatsthis.h>
-#include <qregexp.h>
+#include <tqstringlist.h>
+#include <tqtabwidget.h>
+#include <tqlayout.h>
+#include <tqwidget.h>
+#include <tqcheckbox.h>
+#include <tqlabel.h>
+#include <tqlistbox.h>
+#include <tqpainter.h>
+#include <tqpalette.h>
+#include <tqstyle.h>
+#include <tqlistview.h>
+#include <tqwhatsthis.h>
+#include <tqregexp.h>
#include <kcombobox.h>
#include <klocale.h>
@@ -68,71 +68,71 @@ enum {
//////////////////// ListBoxSeparator ////////////////////
-class ListBoxSeparator : public QListBoxItem
+class ListBoxSeparator : public TQListBoxItem
{
public:
ListBoxSeparator(int h);
protected:
- virtual void paint( QPainter * );
- virtual int width( const QListBox* ) const { return listBox()->width(); }
- virtual int height( const QListBox* ) const { return m_height; }
+ virtual void paint( TQPainter * );
+ virtual int width( const TQListBox* ) const { return listBox()->width(); }
+ virtual int height( const TQListBox* ) const { return m_height; }
private:
int m_height;
};
-ListBoxSeparator::ListBoxSeparator(int h) : QListBoxItem(), m_height(h)
+ListBoxSeparator::ListBoxSeparator(int h) : TQListBoxItem(), m_height(h)
{
- // setText("-"); // not necessary, use QString::null
+ // setText("-"); // not necessary, use TQString()
setCustomHighlighting( true );
setSelectable(false); // doesn't work here, so set it again after creating item
}
-void ListBoxSeparator::paint(QPainter *painter)
+void ListBoxSeparator::paint(TQPainter *painter)
{
-// QRect r( 0, 0, width(listBox()), height(listBox()) );
- painter->setPen(Qt::gray);
+// TQRect r( 0, 0, width(listBox()), height(listBox()) );
+ painter->setPen(TQt::gray);
painter->drawLine(0,m_height/2+1,listBox()->width()-10,m_height/2+1);
}
//////////////////// EditableCheckListItem ////////////////////
-class EditableCheckListItem : public QCheckListItem
+class EditableCheckListItem : public TQCheckListItem
{
public:
- EditableCheckListItem(QCheckListItem *parent, const QString &text);
+ EditableCheckListItem(TQCheckListItem *tqparent, const TQString &text);
- virtual void paintCell(QPainter *p, const QColorGroup &cg,
- int column, int width, int alignment );
+ virtual void paintCell(TQPainter *p, const TQColorGroup &cg,
+ int column, int width, int tqalignment );
};
-EditableCheckListItem::EditableCheckListItem(QCheckListItem *parent, const QString &text)
- : QCheckListItem(parent,text,QCheckListItem::CheckBox)
+EditableCheckListItem::EditableCheckListItem(TQCheckListItem *tqparent, const TQString &text)
+ : TQCheckListItem(tqparent,text,TQCheckListItem::CheckBox)
{
}
-void EditableCheckListItem::paintCell( QPainter *p, const QColorGroup &cg,
- int column, int width, int alignment )
+void EditableCheckListItem::paintCell( TQPainter *p, const TQColorGroup &cg,
+ int column, int width, int tqalignment )
{
if ( column == 1) {
- QColorGroup colorgroup( cg );
+ TQColorGroup colorgroup( cg );
- QListViewItem *item = dynamic_cast<QListViewItem*>(this);
+ TQListViewItem *item = dynamic_cast<TQListViewItem*>(this);
if ( item && (item->text(1)==i18n("<default>") || item->text(1)==i18n("<empty>")) ) {
- colorgroup.setColor( QColorGroup::Text, Qt::gray );
- colorgroup.setColor( QColorGroup::HighlightedText, Qt::gray );
+ colorgroup.setColor( TQColorGroup::Text, TQt::gray );
+ colorgroup.setColor( TQColorGroup::HighlightedText, TQt::gray );
}
- QCheckListItem::paintCell( p, colorgroup, column, width, Qt::AlignHCenter );
+ TQCheckListItem::paintCell( p, colorgroup, column, width, TQt::AlignHCenter );
} else {
- QCheckListItem::paintCell( p, cg, column, width, alignment );
+ TQCheckListItem::paintCell( p, cg, column, width, tqalignment );
}
}
//////////////////// QuickDocument class ////////////////////
-QuickDocument::QuickDocument(KConfig *config, QWidget *parent, const char *name, const QString &caption) : Wizard(config, parent,name,caption)
+QuickDocument::QuickDocument(KConfig *config, TQWidget *tqparent, const char *name, const TQString &caption) : Wizard(config, tqparent,name,caption)
{
KILE_DEBUG() << "==QuickDocument::setupGUI()============" << endl;
- QTabWidget *tabWidget = new QTabWidget( this );
+ TQTabWidget *tabWidget = new TQTabWidget( this );
setMainWidget(tabWidget);
tabWidget->addTab( setupClassOptions(tabWidget), i18n("Cla&ss Options"));
@@ -149,140 +149,140 @@ QuickDocument::~QuickDocument()
//////////////////// GUI ////////////////////
-QWidget *QuickDocument::setupClassOptions(QTabWidget *tab)
+TQWidget *QuickDocument::setupClassOptions(TQTabWidget *tab)
{
KILE_DEBUG() << "\tsetupClassOptions" << endl;
- QLabel *label;
+ TQLabel *label;
- QWidget *classOptions = new QWidget( tab );
- QGridLayout *gl = new QGridLayout(classOptions, 6,4, marginHint(), spacingHint());
+ TQWidget *classOptions = new TQWidget( tab );
+ TQGridLayout *gl = new TQGridLayout(classOptions, 6,4, marginHint(), spacingHint());
gl->setColStretch(1,1);
// Document classes
m_cbDocumentClass = new KComboBox(classOptions);
- m_cbDocumentClass->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Minimum);
+ m_cbDocumentClass->tqsetSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::Minimum);
m_cbDocumentClass->setDuplicatesEnabled(false);
// m_cbDocumentClass->listBox()->setVariableHeight(true);
gl->addWidget(m_cbDocumentClass,0,1);
- connect(m_cbDocumentClass, SIGNAL(activated(int)), this, SLOT(slotDocumentClassChanged(int)));
+ connect(m_cbDocumentClass, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotDocumentClassChanged(int)));
- label = new QLabel(i18n("Doc&ument class:"), classOptions);
+ label = new TQLabel(i18n("Doc&ument class:"), classOptions);
gl->addWidget(label,0,0);
- label->setBuddy(m_cbDocumentClass); label->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
+ label->setBuddy(m_cbDocumentClass); label->tqsetSizePolicy(TQSizePolicy::Maximum, TQSizePolicy::Maximum);
m_btnDocumentClassAdd = new KPushButton(SmallIcon("edit_add"), "", classOptions);
- QWhatsThis::add(m_btnDocumentClassAdd, i18n("Add current text to this list"));
+ TQWhatsThis::add(m_btnDocumentClassAdd, i18n("Add current text to this list"));
gl->addWidget(m_btnDocumentClassAdd,0,2);
- connect(m_btnDocumentClassAdd, SIGNAL(clicked()), this, SLOT(slotDocumentClassAdd()));
+ connect(m_btnDocumentClassAdd, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDocumentClassAdd()));
m_btnDocumentClassDelete = new KPushButton(SmallIcon("eraser"), "", classOptions);
- QWhatsThis::add(m_btnDocumentClassDelete, i18n("Remove current element from this list"));
+ TQWhatsThis::add(m_btnDocumentClassDelete, i18n("Remove current element from this list"));
gl->addWidget(m_btnDocumentClassDelete,0,3);
- connect(m_btnDocumentClassDelete, SIGNAL(clicked()), this, SLOT(slotDocumentClassDelete()));
+ connect(m_btnDocumentClassDelete, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDocumentClassDelete()));
// Fontsize
m_cbTypefaceSize = new KComboBox(classOptions);
m_cbTypefaceSize->setDuplicatesEnabled(false);
gl->addWidget(m_cbTypefaceSize,1,1);
- label = new QLabel(i18n("&Typeface size:"), classOptions);
+ label = new TQLabel(i18n("&Typeface size:"), classOptions);
label->setBuddy(m_cbTypefaceSize);
- label->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
+ label->tqsetSizePolicy(TQSizePolicy::Maximum, TQSizePolicy::Maximum);
gl->addWidget(label,1,0);
m_btnTypefaceSizeAdd = new KPushButton(SmallIcon("edit_add"), "", classOptions);
- QWhatsThis::add(m_btnTypefaceSizeAdd, i18n("Add current text to this list"));
+ TQWhatsThis::add(m_btnTypefaceSizeAdd, i18n("Add current text to this list"));
gl->addWidget(m_btnTypefaceSizeAdd,1,2);
- connect(m_btnTypefaceSizeAdd, SIGNAL(clicked()), this, SLOT(slotTypefaceSizeAdd()));
+ connect(m_btnTypefaceSizeAdd, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotTypefaceSizeAdd()));
m_btnTypefaceSizeDelete = new KPushButton(SmallIcon("eraser"), "", classOptions);
- QWhatsThis::add(m_btnTypefaceSizeDelete, i18n("Remove current element from this list"));
+ TQWhatsThis::add(m_btnTypefaceSizeDelete, i18n("Remove current element from this list"));
gl->addWidget(m_btnTypefaceSizeDelete,1,3);
- connect(m_btnTypefaceSizeDelete, SIGNAL(clicked()), this, SLOT(slotTypefaceSizeDelete()));
+ connect(m_btnTypefaceSizeDelete, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotTypefaceSizeDelete()));
// Papersize
m_cbPaperSize = new KComboBox(classOptions);
- m_cbPaperSize->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Minimum);
+ m_cbPaperSize->tqsetSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::Minimum);
m_cbPaperSize->setDuplicatesEnabled(false);
gl->addWidget(m_cbPaperSize,2,1);
- m_lbPaperSize = new QLabel(i18n("Paper si&ze:"), classOptions);
+ m_lbPaperSize = new TQLabel(i18n("Paper si&ze:"), classOptions);
m_lbPaperSize->setBuddy(m_cbPaperSize);
- m_lbPaperSize->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
+ m_lbPaperSize->tqsetSizePolicy(TQSizePolicy::Maximum, TQSizePolicy::Maximum);
gl->addWidget(m_lbPaperSize,2,0);
m_btnPaperSizeAdd = new KPushButton(SmallIcon("edit_add"), "", classOptions);
- QWhatsThis::add(m_btnPaperSizeAdd, i18n("Add current text to this list"));
+ TQWhatsThis::add(m_btnPaperSizeAdd, i18n("Add current text to this list"));
gl->addWidget(m_btnPaperSizeAdd,2,2);
- connect(m_btnPaperSizeAdd, SIGNAL(clicked()), this, SLOT(slotPaperSizeAdd()));
+ connect(m_btnPaperSizeAdd, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPaperSizeAdd()));
m_btnPaperSizeDelete = new KPushButton(SmallIcon("eraser"), "", classOptions);
- QWhatsThis::add(m_btnPaperSizeDelete, i18n("Remove current element from this list"));
+ TQWhatsThis::add(m_btnPaperSizeDelete, i18n("Remove current element from this list"));
gl->addWidget(m_btnPaperSizeDelete,2,3);
- connect(m_btnPaperSizeDelete, SIGNAL(clicked()), this, SLOT(slotPaperSizeDelete()));
+ connect(m_btnPaperSizeDelete, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPaperSizeDelete()));
// Encoding
m_cbEncoding = new KComboBox(classOptions);
- m_cbEncoding->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Minimum);
+ m_cbEncoding->tqsetSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::Minimum);
m_cbEncoding->setDuplicatesEnabled(false);
gl->addWidget(m_cbEncoding,3,1);
- label = new QLabel(i18n("E&ncoding:"), classOptions);
+ label = new TQLabel(i18n("E&ncoding:"), classOptions);
label->setBuddy(m_cbEncoding);
- label->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Maximum);
+ label->tqsetSizePolicy(TQSizePolicy::Maximum, TQSizePolicy::Maximum);
gl->addWidget(label,3,0);
// Class Options
- m_lvClassOptions = new QListView(classOptions);
+ m_lvClassOptions = new TQListView(classOptions);
m_lvClassOptions->addColumn(i18n("Option"));
m_lvClassOptions->addColumn(i18n("Description"));
m_lvClassOptions->setAllColumnsShowFocus(true);
gl->addMultiCellWidget(m_lvClassOptions, 4,4, 1,3);
- connect(m_lvClassOptions, SIGNAL(selectionChanged()),
- this, SLOT(slotEnableButtons()));
- connect(m_lvClassOptions, SIGNAL(doubleClicked(QListViewItem *,const QPoint &,int)),
- this, SLOT(slotOptionDoubleClicked(QListViewItem *,const QPoint &,int)));
+ connect(m_lvClassOptions, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(slotEnableButtons()));
+ connect(m_lvClassOptions, TQT_SIGNAL(doubleClicked(TQListViewItem *,const TQPoint &,int)),
+ this, TQT_SLOT(slotOptionDoubleClicked(TQListViewItem *,const TQPoint &,int)));
- label = new QLabel(i18n("Cl&ass options:"), classOptions);
+ label = new TQLabel(i18n("Cl&ass options:"), classOptions);
label->setBuddy(m_lvClassOptions);
- label->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::MinimumExpanding);
- label->setAlignment(Qt::AlignTop);
+ label->tqsetSizePolicy(TQSizePolicy::Maximum, TQSizePolicy::MinimumExpanding);
+ label->tqsetAlignment(TQt::AlignTop);
gl->addWidget(label,4,0);
// button
- QWidget *frame = new QWidget(classOptions);
- QHBoxLayout *hl = new QHBoxLayout(frame, 0, spacingHint());
+ TQWidget *frame = new TQWidget(classOptions);
+ TQHBoxLayout *hl = new TQHBoxLayout(frame, 0, spacingHint());
//hl->addStretch(1);
- gl->addMultiCellWidget(frame, 5,5, 1,3, Qt::AlignCenter);
+ gl->addMultiCellWidget(frame, 5,5, 1,3, TQt::AlignCenter);
m_btnClassOptionsAdd = new KPushButton(SmallIcon("edit_add"), i18n("&Add..."), frame);
- QWhatsThis::add(m_btnClassOptionsAdd, i18n("Add a new class option"));
+ TQWhatsThis::add(m_btnClassOptionsAdd, i18n("Add a new class option"));
hl->addWidget(m_btnClassOptionsAdd);
- connect(m_btnClassOptionsAdd, SIGNAL(clicked()), this, SLOT(slotClassOptionAdd()));
+ connect(m_btnClassOptionsAdd, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotClassOptionAdd()));
m_btnClassOptionsEdit = new KPushButton(SmallIcon("edit"), i18n("Ed&it..."), frame);
- QWhatsThis::add(m_btnClassOptionsEdit, i18n("Edit the current class option"));
+ TQWhatsThis::add(m_btnClassOptionsEdit, i18n("Edit the current class option"));
hl->addWidget(m_btnClassOptionsEdit);
- connect(m_btnClassOptionsEdit, SIGNAL(clicked()), this, SLOT(slotClassOptionEdit()));
+ connect(m_btnClassOptionsEdit, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotClassOptionEdit()));
m_btnClassOptionsDelete = new KPushButton(SmallIcon("eraser"), i18n("De&lete"), frame);
- QWhatsThis::add(m_btnClassOptionsDelete, i18n("Remove the current class option"));
+ TQWhatsThis::add(m_btnClassOptionsDelete, i18n("Remove the current class option"));
hl->addWidget(m_btnClassOptionsDelete);
- connect(m_btnClassOptionsDelete, SIGNAL(clicked()), this, SLOT(slotClassOptionDelete()));
+ connect(m_btnClassOptionsDelete, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotClassOptionDelete()));
return classOptions;
}
-QWidget *QuickDocument::setupPackages(QTabWidget *tab)
+TQWidget *QuickDocument::setupPackages(TQTabWidget *tab)
{
KILE_DEBUG() << "\tsetupPackages" << endl;
- QWidget *packages = new QWidget( tab );
- QVBoxLayout *vl = new QVBoxLayout(packages, marginHint(), spacingHint());
+ TQWidget *packages = new TQWidget( tab );
+ TQVBoxLayout *vl = new TQVBoxLayout(packages, marginHint(), spacingHint());
- QLabel *label = new QLabel(i18n("LaTe&X packages:"), packages);
+ TQLabel *label = new TQLabel(i18n("LaTe&X packages:"), packages);
vl->addWidget(label);
- m_lvPackages = new QListView(packages);
+ m_lvPackages = new TQListView(packages);
vl->addWidget(m_lvPackages);
m_lvPackages->setRootIsDecorated(true);
m_lvPackages->addColumn(i18n("Package"));
@@ -290,76 +290,76 @@ QWidget *QuickDocument::setupPackages(QTabWidget *tab)
m_lvPackages->addColumn(i18n("Description"));
m_lvPackages->setAllColumnsShowFocus(true);
label->setBuddy(m_lvPackages);
- connect(m_lvPackages, SIGNAL(clicked(QListViewItem *)),
- this, SLOT(slotCheckParent(QListViewItem *)));
- connect(m_lvPackages, SIGNAL(spacePressed(QListViewItem *)),
- this, SLOT(slotCheckParent(QListViewItem *)));
- connect(m_lvPackages, SIGNAL(selectionChanged()),
- this, SLOT(slotEnableButtons()));
- connect(m_lvPackages, SIGNAL(doubleClicked(QListViewItem *,const QPoint &,int)),
- this, SLOT(slotPackageDoubleClicked(QListViewItem *,const QPoint &,int)));
-
- QWidget *frame = new QWidget(packages);
+ connect(m_lvPackages, TQT_SIGNAL(clicked(TQListViewItem *)),
+ this, TQT_SLOT(slotCheckParent(TQListViewItem *)));
+ connect(m_lvPackages, TQT_SIGNAL(spacePressed(TQListViewItem *)),
+ this, TQT_SLOT(slotCheckParent(TQListViewItem *)));
+ connect(m_lvPackages, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(slotEnableButtons()));
+ connect(m_lvPackages, TQT_SIGNAL(doubleClicked(TQListViewItem *,const TQPoint &,int)),
+ this, TQT_SLOT(slotPackageDoubleClicked(TQListViewItem *,const TQPoint &,int)));
+
+ TQWidget *frame = new TQWidget(packages);
vl->addWidget(frame);
- QHBoxLayout *hl = new QHBoxLayout(frame, 0, spacingHint());
+ TQHBoxLayout *hl = new TQHBoxLayout(frame, 0, spacingHint());
hl->addStretch(1);
m_btnPackagesAdd = new KPushButton(SmallIcon("edit_add"), "&Add Package...", frame);
- QWhatsThis::add(m_btnPackagesAdd, i18n("Add a new package"));
- connect(m_btnPackagesAdd, SIGNAL(clicked()), this, SLOT(slotPackageAdd()));
+ TQWhatsThis::add(m_btnPackagesAdd, i18n("Add a new package"));
+ connect(m_btnPackagesAdd, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPackageAdd()));
hl->addWidget(m_btnPackagesAdd);
m_btnPackagesAddOption = new KPushButton(SmallIcon("edit_add"), i18n("Add Op&tion..."), frame);
- QWhatsThis::add(m_btnPackagesAddOption, i18n("Add a new package option"));
- connect(m_btnPackagesAddOption, SIGNAL(clicked()), this, SLOT(slotPackageAddOption()));
+ TQWhatsThis::add(m_btnPackagesAddOption, i18n("Add a new package option"));
+ connect(m_btnPackagesAddOption, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPackageAddOption()));
hl->addWidget(m_btnPackagesAddOption);
m_btnPackagesEdit = new KPushButton(SmallIcon("edit"), "Ed&it...", frame);
- QWhatsThis::add(m_btnPackagesEdit, i18n("Edit the current package option"));
- connect(m_btnPackagesEdit, SIGNAL(clicked()), this, SLOT(slotPackageEdit()));
+ TQWhatsThis::add(m_btnPackagesEdit, i18n("Edit the current package option"));
+ connect(m_btnPackagesEdit, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPackageEdit()));
hl->addWidget(m_btnPackagesEdit);
m_btnPackagesDelete = new KPushButton(SmallIcon("eraser"), i18n("De&lete"), frame);
- QWhatsThis::add(m_btnPackagesDelete, i18n("Remove the current package option"));
- connect(m_btnPackagesDelete, SIGNAL(clicked()), this, SLOT(slotPackageDelete()));
+ TQWhatsThis::add(m_btnPackagesDelete, i18n("Remove the current package option"));
+ connect(m_btnPackagesDelete, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPackageDelete()));
hl->addWidget(m_btnPackagesDelete);
m_btnPackagesReset = new KPushButton(SmallIcon("reload"), i18n("&Reset to Defaults"), frame);
- QWhatsThis::add(m_btnPackagesReset, i18n("Reset to the default list of packages"));
- connect(m_btnPackagesReset, SIGNAL(clicked()), this, SLOT(slotPackageReset()));
+ TQWhatsThis::add(m_btnPackagesReset, i18n("Reset to the default list of packages"));
+ connect(m_btnPackagesReset, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPackageReset()));
hl->addWidget(m_btnPackagesReset);
hl->addStretch(1);
return packages;
}
-QWidget *QuickDocument::setupProperties(QTabWidget *tab)
+TQWidget *QuickDocument::setupProperties(TQTabWidget *tab)
{
KILE_DEBUG() << "\tsetupProperties" << endl;
- QLabel *label;
+ TQLabel *label;
- QWidget *personalInfo = new QWidget( tab );
- QGridLayout *gl = new QGridLayout(personalInfo, 4,2, marginHint(),spacingHint());
+ TQWidget *personalInfo = new TQWidget( tab );
+ TQGridLayout *gl = new TQGridLayout(personalInfo, 4,2, marginHint(),spacingHint());
gl->setRowStretch(gl->numRows()-1, 1);
m_leAuthor = new KLineEdit(personalInfo);
gl->addWidget(m_leAuthor, 0, 1);
- label = new QLabel(i18n("&Author:"), personalInfo);
+ label = new TQLabel(i18n("&Author:"), personalInfo);
gl->addWidget(label, 0, 0);
label->setBuddy(m_leAuthor);
m_leTitle = new KLineEdit(personalInfo);
gl->addWidget(m_leTitle, 1, 1);
- label = new QLabel(i18n("&Title:"), personalInfo);
+ label = new TQLabel(i18n("&Title:"), personalInfo);
gl->addWidget(label, 1, 0);
label->setBuddy(m_leTitle);
m_leDate = new KLineEdit(personalInfo);
gl->addWidget(m_leDate, 2, 1);
- label = new QLabel(i18n("Dat&e:"), personalInfo);
+ label = new TQLabel(i18n("Dat&e:"), personalInfo);
gl->addWidget(label, 2, 0);
label->setBuddy(m_leDate);
// set current date
- m_leDate->setText( KGlobal::locale()->formatDate(QDate::currentDate(), true) );
+ m_leDate->setText( KGlobal::locale()->formatDate(TQDate::tqcurrentDate(), true) );
// For KDE4:
- //m_leDate->setText( KGlobal::locale()->formatDate(QDate::currentDate(), KLocale::ShortDate) );
+ //m_leDate->setText( KGlobal::locale()->formatDate(TQDate::tqcurrentDate(), KLocale::ShortDate) );
return personalInfo;
}
@@ -412,9 +412,9 @@ void QuickDocument::readDocumentClassConfig()
m_currentEncoding = KileConfig::encoding();
// init standard classes
- QString stdFontsize = "10pt,11pt,12pt";
- QString stdPapersize = "a4paper,a5paper,b5paper,executivepaper,legalpaper,letterpaper";
- QString beamerThemes = "bars;boxes;classic;lined;plain;sidebar;sidebar (dark);sidebar (tab);"
+ TQString stdFontsize = "10pt,11pt,12pt";
+ TQString stdPapersize = "a4paper,a5paper,b5paper,executivepaper,legalpaper,letterpaper";
+ TQString beamerThemes = "bars;boxes;classic;lined;plain;sidebar;sidebar (dark);sidebar (tab);"
"sidebar (dark,tab);shadow;split;tree;tree (bar)";
initStandardClass( "article",stdFontsize,stdPapersize,
@@ -444,7 +444,7 @@ void QuickDocument::readDocumentClassConfig()
"footnosepline,listsindent,nochapterprefix,onelinecaption,onecolumn,"
"oneside,openany,parindent,tablecaptionbelow,titlepage,tocindent",
KileConfig::optionsScrreprt() );
- initStandardClass( "prosper",QString::null,QString::null,
+ initStandardClass( "prosper",TQString(),TQString(),
"final,slideBW,total,nocolorBG,ps,noaccumulate,ps2pdf",
KileConfig::optionsProsper() );
initStandardClass( "beamer","8pt,9pt,10pt,11pt,12pt,14pt,17pt,20pt",beamerThemes,
@@ -455,15 +455,15 @@ void QuickDocument::readDocumentClassConfig()
for ( uint i=0; i<m_userClasslist.count(); ++i )
{
KILE_DEBUG() << "\tinit user class: " << m_userClasslist[i] << endl;
- QStringList list;
+ TQStringList list;
// read dour default entries for this user class
- m_config->setGroup( QString("QuickDocument/")+m_userClasslist[i] );
+ m_config->setGroup( TQString("QuickDocument/")+m_userClasslist[i] );
list.append( m_config->readEntry("fontsizesList") );
list.append( m_config->readEntry("pagesizesList") );
list.append( m_config->readEntry("defaultOptions") );
list.append( m_config->readEntry("selectedOptions") );
// now read all user defined options
- QStringList options = QStringList::split(",", m_config->readEntry("options") );
+ TQStringList options = TQStringList::split(",", m_config->readEntry("options") );
for ( uint j=0; j<options.count(); ++j ) {
list.append( options[j] + " => " + m_config->readEntry(options[j]) );
}
@@ -484,11 +484,11 @@ void QuickDocument::readDocumentClassConfig()
void QuickDocument::fillDocumentClassCombobox()
{
- QString stdClasses = "article,book,letter,report,-,scrartcl,scrbook,scrreprt,-";
- QString stdUserClasses = "beamer,prosper";
+ TQString stdClasses = "article,book,letter,report,-,scrartcl,scrbook,scrreprt,-";
+ TQString stdUserClasses = "beamer,prosper";
// set classes combobox (standard and user defined classes)
- QStringList classlist = QStringList::split(",",stdUserClasses);
+ TQStringList classlist = TQStringList::split(",",stdUserClasses);
for ( uint i=0; i< m_userClasslist.count(); ++i )
classlist.append( m_userClasslist[i] );
classlist.sort();
@@ -502,11 +502,11 @@ void QuickDocument::writeDocumentClassConfig()
// first delete all marked document classes
for ( uint i=0; i<m_deleteDocumentClasses.count(); ++i ) {
KILE_DEBUG() << "\tdelete class: " << m_deleteDocumentClasses[i] << endl;
- m_config->deleteGroup( QString("QuickDocument/")+m_deleteDocumentClasses[i] );
+ m_config->deleteGroup( TQString("QuickDocument/")+m_deleteDocumentClasses[i] );
}
// write document classes and encoding
- QStringList userclasses;
+ TQStringList userclasses;
for ( int i=0; i<m_cbDocumentClass->count(); ++i) {
if ( !m_cbDocumentClass->text(i).isEmpty() && !isStandardClass(m_cbDocumentClass->text(i)) ) {
userclasses.append( m_cbDocumentClass->text(i) );
@@ -529,21 +529,21 @@ void QuickDocument::writeDocumentClassConfig()
KileConfig::setOptionsBeamer( m_dictDocumentClasses["beamer"][qd_SelectedOptions] );
// write config of user packages
- QRegExp reg("(\\S+)\\s+=>\\s+(.*)");
+ TQRegExp reg("(\\S+)\\s+=>\\s+(.*)");
for ( uint i=0; i< userclasses.count(); ++i ) {
// get the stringlist with all information
KILE_DEBUG() << "\twrite user class: " << userclasses[i] << endl;
- QStringList list = m_dictDocumentClasses[ userclasses[i] ];
+ TQStringList list = m_dictDocumentClasses[ userclasses[i] ];
// write the config group and the default entries
- m_config->setGroup( QString("QuickDocument/")+userclasses[i] );
+ m_config->setGroup( TQString("QuickDocument/")+userclasses[i] );
m_config->writeEntry("fontsizesList",list[qd_Fontsizes]);
m_config->writeEntry("pagesizesList",list[qd_Papersizes]);
m_config->writeEntry("defaultOptions",list[qd_DefaultOptions]);
m_config->writeEntry("selectedOptions",list[qd_SelectedOptions]);
// write user defined options
- QString options;
+ TQString options;
for ( uint j=qd_OptionsStart; j<list.count(); ++j ) {
int pos = reg.search( list[j] );
if ( pos != -1 ) {
@@ -563,7 +563,7 @@ void QuickDocument::initDocumentClass()
KILE_DEBUG() << "\tset class: " << m_currentClass << endl;
// get the stringlist of this class with all information
- QStringList classlist = m_dictDocumentClasses[m_currentClass];
+ TQStringList classlist = m_dictDocumentClasses[m_currentClass];
// First of all, we have to set the defaultOptions-dictionary and the
// selectedOptions-dictionary for this class, before inserting options
@@ -578,7 +578,7 @@ void QuickDocument::initDocumentClass()
// now we are ready to set the class options
if ( isStandardClass(m_currentClass) ) {
- QStringList optionlist;
+ TQStringList optionlist;
initStandardOptions(m_currentClass,optionlist);
setClassOptions(optionlist,0);
} else {
@@ -595,9 +595,9 @@ void QuickDocument::initDocumentClass()
slotEnableButtons();
}
-void QuickDocument::initStandardClass(const QString &classname,
- const QString &fontsize, const QString &papersize,
- const QString &defaultoptions, const QString &selectedoptions)
+void QuickDocument::initStandardClass(const TQString &classname,
+ const TQString &fontsize, const TQString &papersize,
+ const TQString &defaultoptions, const TQString &selectedoptions)
{
KILE_DEBUG() << "\tinit standard class: " << classname << endl;
@@ -605,7 +605,7 @@ void QuickDocument::initStandardClass(const QString &classname,
m_dictStandardClasses[ classname ] = true;
// save all entries
- QStringList list;
+ TQStringList list;
list << fontsize << papersize << defaultoptions << selectedoptions;
// save in documentClass-dictionary
@@ -613,7 +613,7 @@ void QuickDocument::initStandardClass(const QString &classname,
}
// build all option for the current standard class
-void QuickDocument::initStandardOptions(const QString &classname,QStringList &optionlist)
+void QuickDocument::initStandardOptions(const TQString &classname,TQStringList &optionlist)
{
// build the bitcode for all options of this class
int options;
@@ -641,170 +641,170 @@ void QuickDocument::initStandardOptions(const QString &classname,QStringList &op
// insert all options into the list
if ( options & qd_Base ) {
optionlist
- << QString("landscape => ") + i18n("Sets the document's orientation to landscape")
- << QString("oneside => ") + i18n("Margins are set for single side output")
- << QString("twoside => ") + i18n("Left and right pages differ in page margins")
- << QString("draft => ") + i18n("Marks \"overfull hboxes\" on the output with black boxes")
- << QString("final => ") + i18n("No special marks for \"overfull hboxes\" on the output")
- << QString("leqno => ") + i18n("Puts formula numbers on the left side")
- << QString("fleqn => ") + i18n("Aligns formulas on the left side")
+ << TQString("landscape => ") + i18n("Sets the document's orientation to landscape")
+ << TQString("oneside => ") + i18n("Margins are set for single side output")
+ << TQString("twoside => ") + i18n("Left and right pages differ in page margins")
+ << TQString("draft => ") + i18n("Marks \"overfull hboxes\" on the output with black boxes")
+ << TQString("final => ") + i18n("No special marks for \"overfull hboxes\" on the output")
+ << TQString("leqno => ") + i18n("Puts formula numbers on the left side")
+ << TQString("fleqn => ") + i18n("Aligns formulas on the left side")
;
}
if ( options & qd_Article ) {
optionlist
- << QString("titlepage => ") + i18n("Puts title and abstract on an extra page")
- << QString("notitlepage => ") + i18n("Puts title and abstract on the same page as the text")
- << QString("onecolumn => ") + i18n("Puts the text in one column")
- << QString("twocolumn => ") + i18n("Puts the text in two columns")
- << QString("openbib => ") + i18n("Formats the bibliography in open style")
+ << TQString("titlepage => ") + i18n("Puts title and abstract on an extra page")
+ << TQString("notitlepage => ") + i18n("Puts title and abstract on the same page as the text")
+ << TQString("onecolumn => ") + i18n("Puts the text in one column")
+ << TQString("twocolumn => ") + i18n("Puts the text in two columns")
+ << TQString("openbib => ") + i18n("Formats the bibliography in open style")
;
}
if ( options & qd_BookReport ) {
optionlist
- << QString("openany => ") + i18n("Chapters may start on top of every page")
- << QString("openright => ") + i18n("Chapters may only start on top of right pages")
+ << TQString("openany => ") + i18n("Chapters may start on top of every page")
+ << TQString("openright => ") + i18n("Chapters may only start on top of right pages")
;
}
if ( options & qd_KomaArticle ) {
optionlist
- << QString("headinclude => ") + i18n("Cause the header to be counted as text")
- << QString("headexclude => ") + i18n("Cause the header to be counted as border")
- << QString("footinclude => ") + i18n("Cause the footer to be counted as text")
- << QString("footexclude => ") + i18n("Cause the footer to be counted as border")
- << QString("mpinclude => ") + i18n("Cause the margin-note to be counted to the text body")
- << QString("mpexclude => ") + i18n("The normal margin is used for the margin-note area")
- << QString("dvips => ") + i18n("Writes the paper size as a special into the DVI-file")
- << QString("pdftex => ") + i18n("Writes the paper size into the pdftex page register")
- << QString("pagesize => ") + i18n("Uses the correct mechanism with PDF- or DVI-file")
- << QString("cleardoubleempty => ") + i18n("Enables the default for an empty left page")
- << QString("cleardoubleplain => ") + i18n("An empty left page will set with the plain-pagestyle")
- << QString("cleardoublestandard => ") + i18n("An empty left page will set with the empty-pagestyle")
- << QString("headsepline => ") + i18n("Use a line to separate the header from the text body")
- << QString("headnosepline => ") + i18n("Use no line to separate the header from the text body")
- << QString("footsepline => ") + i18n("Use a line to separate the footer from the text body")
- << QString("footnosepline => ") + i18n("Use no line to separate the footer from the text body")
- << QString("parskip => ") + i18n("Normal paragraph spacing of one line")
- << QString("parskip- => ") + i18n("Normal spacing, at least 1/3 of the last line is free")
- << QString("parskip+ => ") + i18n("Normal spacing, at least 1/4 of the last line is free")
- << QString("parskip* => ") + i18n("Normal spacing, no special provision for the last line")
- << QString("halfparskip => ") + i18n("Paragraph spacing of half a line")
- << QString("halfparskip- => ") + i18n("Spacing 1/2 line, at least 1/3 of the last line is free")
- << QString("halfparskip+ => ") + i18n("Spacing 1/2 line, at least 1/4 of the last line is free")
- << QString("halfparskip* => ") + i18n("Spacing 1/2 line, no special provision for the last line")
- << QString("parindent => ") + i18n("No spacing between paragraphs, indent the first line by 1 em")
- << QString("onelinecaption => ") + i18n("One-line captions are centered, multi-line left-justified")
- << QString("noonelinecaption => ") + i18n("No special handling of one-line captions")
- << QString("bigheading => ") + i18n("Normal great title font sizes")
- << QString("normalheadings => ") + i18n("Small font sizes for titles")
- << QString("smallheadings => ") + i18n("Even smaller font sizes for titles")
- << QString("liststotoc => ") + i18n("Include lists of figures and tables in the TOC")
- << QString("bibtotoc => ") + i18n("Include the bibliography in the TOC")
- << QString("idxtotoc => ") + i18n("Include the index in the TOC")
- << QString("liststotocnumbered => ") + i18n("Number the lists of figures and tables in the TOC")
- << QString("bibtotocnumbered => ") + i18n("Number the bibliography in the TOC")
- << QString("tocleft => ") + i18n("All numbers and titles are set in a left-justified column")
- << QString("tocindent => ") + i18n("Different sectional units have different indentations")
- << QString("listsleft => ") + i18n("All numbers and captions are set in a left-justified column")
- << QString("listsindent => ") + i18n("All Numbers uses a fixed space")
- << QString("pointednumbers => ") + i18n("Numbering of sectional units have a point at the end")
- << QString("pointlessnumbers => ") + i18n("Numbering of sectional units have no point at the end")
- << QString("tablecaptionabove => ") + i18n("Caption command acts like \\captionabove")
- << QString("tablecaptionbelow => ") + i18n("Caption command acts like \\captionbelow")
- << QString("origlongtable => ") + i18n("Captions of the longtable package should not be redefined")
+ << TQString("headinclude => ") + i18n("Cause the header to be counted as text")
+ << TQString("headexclude => ") + i18n("Cause the header to be counted as border")
+ << TQString("footinclude => ") + i18n("Cause the footer to be counted as text")
+ << TQString("footexclude => ") + i18n("Cause the footer to be counted as border")
+ << TQString("mpinclude => ") + i18n("Cause the margin-note to be counted to the text body")
+ << TQString("mpexclude => ") + i18n("The normal margin is used for the margin-note area")
+ << TQString("dvips => ") + i18n("Writes the paper size as a special into the DVI-file")
+ << TQString("pdftex => ") + i18n("Writes the paper size into the pdftex page register")
+ << TQString("pagesize => ") + i18n("Uses the correct mechanism with PDF- or DVI-file")
+ << TQString("cleardoubleempty => ") + i18n("Enables the default for an empty left page")
+ << TQString("cleardoubleplain => ") + i18n("An empty left page will set with the plain-pagestyle")
+ << TQString("cleardoublestandard => ") + i18n("An empty left page will set with the empty-pagestyle")
+ << TQString("headsepline => ") + i18n("Use a line to separate the header from the text body")
+ << TQString("headnosepline => ") + i18n("Use no line to separate the header from the text body")
+ << TQString("footsepline => ") + i18n("Use a line to separate the footer from the text body")
+ << TQString("footnosepline => ") + i18n("Use no line to separate the footer from the text body")
+ << TQString("parskip => ") + i18n("Normal paragraph spacing of one line")
+ << TQString("parskip- => ") + i18n("Normal spacing, at least 1/3 of the last line is free")
+ << TQString("parskip+ => ") + i18n("Normal spacing, at least 1/4 of the last line is free")
+ << TQString("parskip* => ") + i18n("Normal spacing, no special provision for the last line")
+ << TQString("halfparskip => ") + i18n("Paragraph spacing of half a line")
+ << TQString("halfparskip- => ") + i18n("Spacing 1/2 line, at least 1/3 of the last line is free")
+ << TQString("halfparskip+ => ") + i18n("Spacing 1/2 line, at least 1/4 of the last line is free")
+ << TQString("halfparskip* => ") + i18n("Spacing 1/2 line, no special provision for the last line")
+ << TQString("parindent => ") + i18n("No spacing between paragraphs, indent the first line by 1 em")
+ << TQString("onelinecaption => ") + i18n("One-line captions are centered, multi-line left-justified")
+ << TQString("noonelinecaption => ") + i18n("No special handling of one-line captions")
+ << TQString("bigheading => ") + i18n("Normal great title font sizes")
+ << TQString("normalheadings => ") + i18n("Small font sizes for titles")
+ << TQString("smallheadings => ") + i18n("Even smaller font sizes for titles")
+ << TQString("liststotoc => ") + i18n("Include lists of figures and tables in the TOC")
+ << TQString("bibtotoc => ") + i18n("Include the bibliography in the TOC")
+ << TQString("idxtotoc => ") + i18n("Include the index in the TOC")
+ << TQString("liststotocnumbered => ") + i18n("Number the lists of figures and tables in the TOC")
+ << TQString("bibtotocnumbered => ") + i18n("Number the bibliography in the TOC")
+ << TQString("tocleft => ") + i18n("All numbers and titles are set in a left-justified column")
+ << TQString("tocindent => ") + i18n("Different sectional units have different indentations")
+ << TQString("listsleft => ") + i18n("All numbers and captions are set in a left-justified column")
+ << TQString("listsindent => ") + i18n("All Numbers uses a fixed space")
+ << TQString("pointednumbers => ") + i18n("Numbering of sectional units have a point at the end")
+ << TQString("pointlessnumbers => ") + i18n("Numbering of sectional units have no point at the end")
+ << TQString("tablecaptionabove => ") + i18n("Caption command acts like \\captionabove")
+ << TQString("tablecaptionbelow => ") + i18n("Caption command acts like \\captionbelow")
+ << TQString("origlongtable => ") + i18n("Captions of the longtable package should not be redefined")
;
}
if ( options & qd_KomaBookReport ) {
optionlist
- << QString("chapterprefix => ") + i18n("Use a separate line for the chapter number")
- << QString("nochapterprefix => ") + i18n("Use the same line for the chapter number and title")
- << QString("appendixprefix => ") + i18n("Use a separate line for the appendix name")
- << QString("noappendixprefix => ") + i18n("No separate line for the appendix name")
+ << TQString("chapterprefix => ") + i18n("Use a separate line for the chapter number")
+ << TQString("nochapterprefix => ") + i18n("Use the same line for the chapter number and title")
+ << TQString("appendixprefix => ") + i18n("Use a separate line for the appendix name")
+ << TQString("noappendixprefix => ") + i18n("No separate line for the appendix name")
;
}
if ( options & qd_KomaAbstract ) {
optionlist
- << QString("abstracton => ") + i18n("Include the abstract's title")
- << QString("abstractoff => ") + i18n("Exclude the abstract's title")
+ << TQString("abstracton => ") + i18n("Include the abstract's title")
+ << TQString("abstractoff => ") + i18n("Exclude the abstract's title")
;
}
if ( options & qd_Prosper ) {
optionlist
- << QString("draft => ") + i18n("The file is compiled in draft mode")
- << QString("final => ") + i18n("The file is compiled in final mode")
- << QString("slideColor => ") + i18n("Slides will use many colors")
- << QString("slideBW => ") + i18n("Slides will use a restricted set of colors")
- << QString("total => ") + i18n("Display the number of the current slide and the total number")
- << QString("nototal => ") + i18n("Display only the number of the current slide")
- << QString("nocolorBG => ") + i18n("The background of the slide is always white")
- << QString("colorBG => ") + i18n("The color of the background depends on the current style")
- << QString("ps => ") + i18n("The LaTeX file is compiled to produce a PostScript file")
- << QString("pdf => ") + i18n("The LaTeX file is compiled to produce a PDF file")
- << QString("accumulate => ") + i18n("Some macros interpret their argument in ps mode")
- << QString("noaccumulate => ") + i18n("Some macros do not interpret their argument in ps mode")
- << QString("distiller => ") + i18n("The PS file is to be translated into a PDF file using Adobe Distiller")
- << QString("YandY => ") + i18n("The LaTeX file is to be processed with YandY LaTeX")
- << QString("ps2pdf => ") + i18n("The PS file is to be translated into a PDF file using ps2pdf")
- << QString("vtex => ") + i18n("The LaTeX file is to be processed with MicroPress VTeX")
- << QString("noFooter => ") + i18n("Do not add any caption at the bottom of the slides")
+ << TQString("draft => ") + i18n("The file is compiled in draft mode")
+ << TQString("final => ") + i18n("The file is compiled in final mode")
+ << TQString("slideColor => ") + i18n("Slides will use many colors")
+ << TQString("slideBW => ") + i18n("Slides will use a restricted set of colors")
+ << TQString("total => ") + i18n("Display the number of the current slide and the total number")
+ << TQString("nototal => ") + i18n("Display only the number of the current slide")
+ << TQString("nocolorBG => ") + i18n("The background of the slide is always white")
+ << TQString("colorBG => ") + i18n("The color of the background depends on the current style")
+ << TQString("ps => ") + i18n("The LaTeX file is compiled to produce a PostScript file")
+ << TQString("pdf => ") + i18n("The LaTeX file is compiled to produce a PDF file")
+ << TQString("accumulate => ") + i18n("Some macros interpret their argument in ps mode")
+ << TQString("noaccumulate => ") + i18n("Some macros do not interpret their argument in ps mode")
+ << TQString("distiller => ") + i18n("The PS file is to be translated into a PDF file using Adobe Distiller")
+ << TQString("YandY => ") + i18n("The LaTeX file is to be processed with YandY LaTeX")
+ << TQString("ps2pdf => ") + i18n("The PS file is to be translated into a PDF file using ps2pdf")
+ << TQString("vtex => ") + i18n("The LaTeX file is to be processed with MicroPress VTeX")
+ << TQString("noFooter => ") + i18n("Do not add any caption at the bottom of the slides")
;
}
if ( options & qd_Beamer ) {
optionlist
- << QString("slidestop => ") + i18n("Place text of slides at the (vertical) top of the slides")
- << QString("slidescentered => ") + i18n("Place text of slides at the (vertical) center of the slides")
- << QString("draft => ") + i18n("Headlines, footlines, and sidebars are replaced by gray rectangles")
- << QString("compress => ") + i18n("Make all navigation bars as small as possible")
- << QString("usepdftitle=false => ") + i18n("Suppresses generation of some entries in the pdf information")
- << QString("notheorems => ") + i18n("Switches off the definition of default blocks like theorem")
- << QString("noamsthm => ") + i18n("Does not load amsthm and amsmath")
- << QString("CJK => ") + i18n("Needed when using the CJK package for Asian fonts")
- << QString("sans => ") + i18n("Use a sans-serif font during the presentation")
- << QString("serif => ") + i18n("Use a serif font during the presentation")
- << QString("mathsans => ") + i18n("Override the math font to be a sans-serif font")
- << QString("mathserif => ") + i18n("Override the math font to be a serif font")
- << QString("professionalfont => ") + i18n("Deactivate internal font replacements for math text")
- << QString("handout => ") + i18n("Create a PDF handout")
- << QString("trans => ") + i18n("For PDF transparency")
- << QString("blue => ") + i18n("All structure elements are typeset in blue")
- << QString("red => ") + i18n("All structure elements are typeset in red")
- << QString("blackandwhite => ") + i18n("All structure elements are typeset in black and white")
- << QString("brown => ") + i18n("All structure elements are typeset in brown")
- << QString("notes=hide => ") + i18n(" Notes are not shown")
- << QString("notes=show => ") + i18n(" Include notes in the output file")
- << QString("notes=only => ") + i18n(" Include only notes and suppress frames")
+ << TQString("slidestop => ") + i18n("Place text of slides at the (vertical) top of the slides")
+ << TQString("slidescentered => ") + i18n("Place text of slides at the (vertical) center of the slides")
+ << TQString("draft => ") + i18n("Headlines, footlines, and sidebars are replaced by gray rectangles")
+ << TQString("compress => ") + i18n("Make all navigation bars as small as possible")
+ << TQString("usepdftitle=false => ") + i18n("Suppresses generation of some entries in the pdf information")
+ << TQString("notheorems => ") + i18n("Switches off the definition of default blocks like theorem")
+ << TQString("noamsthm => ") + i18n("Does not load amsthm and amsmath")
+ << TQString("CJK => ") + i18n("Needed when using the CJK package for Asian fonts")
+ << TQString("sans => ") + i18n("Use a sans-serif font during the presentation")
+ << TQString("serif => ") + i18n("Use a serif font during the presentation")
+ << TQString("mathsans => ") + i18n("Override the math font to be a sans-serif font")
+ << TQString("mathserif => ") + i18n("Override the math font to be a serif font")
+ << TQString("professionalfont => ") + i18n("Deactivate internal font replacements for math text")
+ << TQString("handout => ") + i18n("Create a PDF handout")
+ << TQString("trans => ") + i18n("For PDF transparency")
+ << TQString("blue => ") + i18n("All structure elements are typeset in blue")
+ << TQString("red => ") + i18n("All structure elements are typeset in red")
+ << TQString("blackandwhite => ") + i18n("All structure elements are typeset in black and white")
+ << TQString("brown => ") + i18n("All structure elements are typeset in brown")
+ << TQString("notes=hide => ") + i18n(" Notes are not shown")
+ << TQString("notes=show => ") + i18n(" Include notes in the output file")
+ << TQString("notes=only => ") + i18n(" Include only notes and suppress frames")
;
}
}
// check for a standard class
-bool QuickDocument::isStandardClass(const QString &classname)
+bool QuickDocument::isStandardClass(const TQString &classname)
{
- return m_dictStandardClasses.contains(classname);
+ return m_dictStandardClasses.tqcontains(classname);
}
// check for a default option
-bool QuickDocument::isDefaultClassOption(const QString &option)
+bool QuickDocument::isDefaultClassOption(const TQString &option)
{
- return m_currentDefaultOptions.contains(option);
+ return m_currentDefaultOptions.tqcontains(option);
}
// check for an user option
-bool QuickDocument::isSelectedClassOption(const QString &option)
+bool QuickDocument::isSelectedClassOption(const TQString &option)
{
- return m_currentSelectedOptions.contains(option);
+ return m_currentSelectedOptions.tqcontains(option);
}
// insert all default options of the current class into the defaultOptions-dictionary
-void QuickDocument::setDefaultClassOptions(const QString &defaultoptions)
+void QuickDocument::setDefaultClassOptions(const TQString &defaultoptions)
{
- QStringList list = QStringList::split(",",defaultoptions);
+ TQStringList list = TQStringList::split(",",defaultoptions);
m_currentDefaultOptions.clear();
for ( uint i=0; i<list.count(); ++i ) {
if ( ! list[i].isEmpty() )
@@ -813,11 +813,11 @@ void QuickDocument::setDefaultClassOptions(const QString &defaultoptions)
}
// insert all checked options of the current class into the selectedOptions-dictionary
-void QuickDocument::setSelectedClassOptions(const QString &selectedoptions)
+void QuickDocument::setSelectedClassOptions(const TQString &selectedoptions)
{
KILE_DEBUG() << "\tset options: " << selectedoptions << endl;
- QStringList list = QStringList::split(",",selectedoptions);
+ TQStringList list = TQStringList::split(",",selectedoptions);
uint nlist = list.count();
m_currentFontsize = ( nlist >= 1 ) ? list[0] : "";
@@ -834,15 +834,15 @@ void QuickDocument::setSelectedClassOptions(const QString &selectedoptions)
// - split this string into option and description (option => description)
// - if the option is in the defaultOptions-dictionary, add 'default'
// - if the option is in the selectedOptions-dictionary, set the 'checked' symbol
-void QuickDocument::setClassOptions(const QStringList &list, uint start)
+void QuickDocument::setClassOptions(const TQStringList &list, uint start)
{
- QRegExp reg("(\\S+)\\s+=>\\s+(.*)");
+ TQRegExp reg("(\\S+)\\s+=>\\s+(.*)");
m_lvClassOptions->clear();
for (uint i=start; i<list.count(); ++i) {
int pos = reg.search( list[i] );
if ( pos != -1 ) {
- QCheckListItem *cli = new QCheckListItem(m_lvClassOptions, reg.cap(1), QCheckListItem::CheckBox);
+ TQCheckListItem *cli = new TQCheckListItem(m_lvClassOptions, reg.cap(1), TQCheckListItem::CheckBox);
// see if it is a default option
if ( isDefaultClassOption(reg.cap(1)) )
@@ -861,15 +861,15 @@ void QuickDocument::setClassOptions(const QStringList &list, uint start)
// - first entry: always the current fontsize
// - second entry: always the current papersize
// - followed by all other checked options
-QString QuickDocument::getClassOptions()
+TQString QuickDocument::getClassOptions()
{
- QString fontsize = stripDefault( m_cbTypefaceSize->currentText() );
- QString papersize = stripDefault( m_cbPaperSize->currentText() );
+ TQString fontsize = stripDefault( m_cbTypefaceSize->currentText() );
+ TQString papersize = stripDefault( m_cbPaperSize->currentText() );
- QString options = fontsize + ',' + papersize;
+ TQString options = fontsize + ',' + papersize;
- for (QListViewItem *cur = m_lvClassOptions->firstChild(); cur; cur=cur->nextSibling()) {
- QCheckListItem *cli = dynamic_cast<QCheckListItem*>(cur);
+ for (TQListViewItem *cur = m_lvClassOptions->firstChild(); cur; cur=cur->nextSibling()) {
+ TQCheckListItem *cli = dynamic_cast<TQCheckListItem*>(cur);
if (cli && cli->isOn()) {
options += ',' + cur->text(0);
}
@@ -887,21 +887,21 @@ void QuickDocument::updateClassOptions()
KILE_DEBUG() << "==QuickDocument::updateClassOptions()============" << endl;
KILE_DEBUG() << "\tclass: " << m_currentClass << endl;
- QString defaultoptions;
- QStringList newlist;
- QStringList oldlist = m_dictDocumentClasses[m_currentClass];
+ TQString defaultoptions;
+ TQStringList newlist;
+ TQStringList oldlist = m_dictDocumentClasses[m_currentClass];
// read the first four static entries
newlist << oldlist[qd_Fontsizes];
newlist << oldlist[qd_Papersizes];
- newlist << QString::null; // dummy entry: will be changed
+ newlist << TQString(); // dummy entry: will be changed
newlist << getClassOptions();
// read all options
- for (QListViewItem *cur = m_lvClassOptions->firstChild(); cur; cur=cur->nextSibling()) {
- QCheckListItem *cli = dynamic_cast<QCheckListItem*>(cur);
+ for (TQListViewItem *cur = m_lvClassOptions->firstChild(); cur; cur=cur->nextSibling()) {
+ TQCheckListItem *cli = dynamic_cast<TQCheckListItem*>(cur);
if ( cli ) {
- QString description = cur->text(1);
+ TQString description = cur->text(1);
if ( description.right(10) == " [default]" ) {
description = stripDefault(description);
if ( ! defaultoptions.isEmpty() )
@@ -926,20 +926,20 @@ void QuickDocument::updateClassOptions()
// Insert all entries from a comma separated list into a combobox.
// If this entry matches a given text, this entry will be activated.
-void QuickDocument::fillCombobox(KComboBox *combo, const QString &cslist, const QString &seltext)
+void QuickDocument::fillCombobox(KComboBox *combo, const TQString &cslist, const TQString &seltext)
{
bool documentclasscombo = ( combo == m_cbDocumentClass );
- QListBox *listbox = combo->listBox();
+ TQListBox *listbox = combo->listBox();
- QString sep = ( m_currentClass=="beamer" && combo==m_cbPaperSize ) ? ";" : ",";
- QStringList list = QStringList::split(sep,cslist);
+ TQString sep = ( m_currentClass=="beamer" && combo==m_cbPaperSize ) ? ";" : ",";
+ TQStringList list = TQStringList::split(sep,cslist);
if ( ! documentclasscombo )
list.sort();
combo->clear();
for (uint i=0; i<list.count(); ++i) {
if ( !documentclasscombo && isDefaultClassOption(list[i]) )
- combo->insertItem( QString(list[i]) + " [default]" );
+ combo->insertItem( TQString(list[i]) + " [default]" );
else if ( list[i] != "-" )
combo->insertItem( list[i] );
else
@@ -958,20 +958,20 @@ void QuickDocument::fillCombobox(KComboBox *combo, const QString &cslist, const
// Add some entries from a comma separated list to a sorted combobox.
// The new entries must match a regular expression or will be denied.
-bool QuickDocument::addComboboxEntries(KComboBox *combo, const QString &title,const QString &entry)
+bool QuickDocument::addComboboxEntries(KComboBox *combo, const TQString &title,const TQString &entry)
{
// read current comboxbox entries
- QStringList combolist;
+ TQStringList combolist;
for (int i=0; i<combo->count(); ++i)
combolist += combo->text(i);
// add new entries (one or a comma separated list)
- QStringList list = QStringList::split(",",entry);
+ TQStringList list = TQStringList::split(",",entry);
for ( uint i=0; i<list.count(); ++i ) {
- QString s = list[i].stripWhiteSpace();
+ TQString s = list[i].stripWhiteSpace();
// entries must match a regular expression
- if ( combolist.findIndex(s) != -1 )
- KMessageBox::error( this, i18n("%1 '%2' already exists.").arg(title).arg(s) );
+ if ( combolist.tqfindIndex(s) != -1 )
+ KMessageBox::error( this, i18n("%1 '%2' already exists.").tqarg(title).tqarg(s) );
else {
combolist += s;
KILE_DEBUG() << "\tinsert new " << title << ": " << s << endl;
@@ -988,18 +988,18 @@ bool QuickDocument::addComboboxEntries(KComboBox *combo, const QString &title,co
}
-QString QuickDocument::getComboxboxList(KComboBox *combo)
+TQString QuickDocument::getComboxboxList(KComboBox *combo)
{
- QStringList list;
+ TQStringList list;
for ( int i=0; i<combo->count(); ++i ) {
list += combo->text(i);
}
- return ( list.count() > 0 ) ? list.join(",") : QString::null;
+ return ( list.count() > 0 ) ? list.join(",") : TQString();
}
// strip an optional default-tag from the string
-QString QuickDocument::stripDefault(const QString &s)
+TQString QuickDocument::stripDefault(const TQString &s)
{
return ( s.right(10) == " [default]" ) ? s.left( s.length()-10 ) : s;
}
@@ -1018,8 +1018,8 @@ void QuickDocument::readPackagesConfig()
void QuickDocument::initPackages()
{
KILE_DEBUG() << "read config: init standard packages" << endl;
- QCheckListItem *cli;
- QCheckListItem *clichild;
+ TQCheckListItem *cli;
+ TQCheckListItem *clichild;
m_lvPackages->clear();
cli = insertListview(m_lvPackages,"amsmath", i18n("Special math environments and commands (AMS)") );
@@ -1035,15 +1035,15 @@ void QuickDocument::initPackages()
clichild = insertListview(cli,"pdftex",i18n("Use pdftex as hyperref driver") );
clichild = insertEditableListview(cli,"bookmarks",i18n("Make bookmarks"),"true","true" );
clichild = insertEditableListview(cli,"bookmarksnumbered",i18n("Put section numbers in bookmarks"),"false","false" );
- clichild = insertEditableListview(cli,"bookmarksopen",i18n("Open up bookmark tree"),QString::null,QString::null );
- clichild = insertEditableListview(cli,"pdfauthor",i18n("Text for PDF Author field"),QString::null,QString::null );
+ clichild = insertEditableListview(cli,"bookmarksopen",i18n("Open up bookmark tree"),TQString(),TQString() );
+ clichild = insertEditableListview(cli,"pdfauthor",i18n("Text for PDF Author field"),TQString(),TQString() );
clichild = insertEditableListview(cli,"pdfcreator",i18n("Text for PDF Creator field"),i18n("LaTeX with hyperref package"),i18n("LaTeX with hyperref package") );
clichild = insertEditableListview(cli,"pdffitwindow",i18n("Resize document window to fit document size"),"false","false" );
- clichild = insertEditableListview(cli,"pdfkeywords",i18n("Text for PDF Keywords field"),QString::null,QString::null );
- clichild = insertEditableListview(cli,"pdfproducer",i18n("Text for PDF Producer field"),QString::null,QString::null );
+ clichild = insertEditableListview(cli,"pdfkeywords",i18n("Text for PDF Keywords field"),TQString(),TQString() );
+ clichild = insertEditableListview(cli,"pdfproducer",i18n("Text for PDF Producer field"),TQString(),TQString() );
clichild = insertEditableListview(cli,"pdfstartview",i18n("Starting view of PDF document"),"/Fit","/Fit" );
- clichild = insertEditableListview(cli,"pdfsubject",i18n("Text for PDF Subject field"),QString::null,QString::null );
- clichild = insertEditableListview(cli,"pdftitle",i18n("Text for PDF Title field"),QString::null,QString::null );
+ clichild = insertEditableListview(cli,"pdfsubject",i18n("Text for PDF Subject field"),TQString(),TQString() );
+ clichild = insertEditableListview(cli,"pdftitle",i18n("Text for PDF Title field"),TQString(),TQString() );
cli = insertListview(m_lvPackages,"mathpazo",i18n("Use Palatino font as roman font (both text and math mode)") );
cli = insertListview(m_lvPackages,"mathptmx",i18n("Use Times font as roman font (both text and math mode)") );
@@ -1058,99 +1058,99 @@ void QuickDocument::initPackages()
cli = insertListview(m_lvPackages,"babel",i18n("Adds language specific support") );
cli->setOn(true);
cli->setOpen(true);
- clichild = new QCheckListItem(cli,"acadian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"afrikaans" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"american" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"australian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"austrian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"bahasa" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"basque" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"brazil" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"brazilian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"breton" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"british" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"bulgarian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"canadian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"canadien" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"catalan" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"croatian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"czech" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"danish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"dutch" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"english" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"esperanto" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"estonian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"finnish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"francais" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"frenchb" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"french" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"galician" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"german" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"germanb" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"greek" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"polutonikogreek" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"hebrew" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"hungarian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"icelandic" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"interlingua" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"irish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"italian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"latin" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"lowersorbian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"magyar" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"naustrian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"newzealand" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"ngerman" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"norsk" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"samin" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"nynorsk" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"polish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"portuges" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"portuguese" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"romanian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"russian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"scottish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"serbian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"slovak" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"slovene" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"spanish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"swedish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"turkish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"ukrainian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"uppersorbian" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"welsh" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"UKenglish" ,QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli,"USenglish" ,QCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"acadian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"afrikaans" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"american" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"australian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"austrian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"bahasa" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"basque" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"brazil" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"brazilian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"breton" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"british" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"bulgarian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"canadian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"canadien" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"catalan" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"croatian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"czech" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"danish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"dutch" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"english" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"esperanto" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"estonian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"finnish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"francais" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"frenchb" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"french" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"galician" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"german" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"germanb" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"greek" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"polutonikogreek" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"hebrew" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"hungarian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"icelandic" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"interlingua" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"irish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"italian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"latin" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"lowersorbian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"magyar" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"naustrian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"newzealand" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"ngerman" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"norsk" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"samin" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"nynorsk" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"polish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"portuges" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"portuguese" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"romanian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"russian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"scottish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"serbian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"slovak" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"slovene" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"spanish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"swedish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"turkish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"ukrainian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"uppersorbian" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"welsh" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"UKenglish" ,TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli,"USenglish" ,TQCheckListItem::CheckBox);
cli = insertListview(m_lvPackages,"fontenc",i18n("Use a font encoding scheme") );
cli->setOn(true);
cli->setOpen(true);
- clichild = new QCheckListItem(cli, "HE8",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "IL2",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LCH",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LCY",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LGR",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LHE",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LIT",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LO1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "LY1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "MTT",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "OML",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "OMS",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "OT1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "OT2",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "OT4",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "PD1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "PU",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "QX",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "T1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "T2A",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "T2B",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "T2C",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "T5",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "TS1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "UT1",QCheckListItem::CheckBox);
- clichild = new QCheckListItem(cli, "X2",QCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "HE8",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "IL2",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LCH",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LCY",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LGR",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LHE",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LIT",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LO1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "LY1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "MTT",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "OML",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "OMS",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "OT1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "OT2",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "OT4",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "PD1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "PU",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "QX",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "T1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "T2A",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "T2B",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "T2C",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "T5",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "TS1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "UT1",TQCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, "X2",TQCheckListItem::CheckBox);
cli = insertListview(m_lvPackages,"graphicx",i18n("Support for including graphics") );
cli->setOn(true);
@@ -1168,7 +1168,7 @@ bool QuickDocument::readPackagesListview()
{
KILE_DEBUG() << "\tread config: packages from config file" << endl;
- QStringList elements = KileConfig::packagesList();
+ TQStringList elements = KileConfig::packagesList();
// clear packages dictionaries and listview
m_dictPackagesEditable.clear();
@@ -1179,17 +1179,17 @@ bool QuickDocument::readPackagesListview()
return false;
// regular expression to split the string from the config file
- QRegExp reg("([^,]*),([^,]*),([^,]*),([^,]*),(.*)");
+ TQRegExp reg("([^,]*),([^,]*),([^,]*),([^,]*),(.*)");
m_config->setGroup( "QuickDocument/Packages" );
- for ( QStringList::Iterator it=elements.begin(); it!=elements.end(); ++it ) {
- QCheckListItem *cli;
+ for ( TQStringList::Iterator it=elements.begin(); it!=elements.end(); ++it ) {
+ TQCheckListItem *cli;
// look, if this is a main or a child entry
KILE_DEBUG() << "\tread config entry: " << *it << endl;
- int pos = (*it).find('!');
+ int pos = (*it).tqfind('!');
if ( pos == -1 ) { // main entry
- cli = new QCheckListItem(m_lvPackages, *it, QCheckListItem::CheckBox);
+ cli = new TQCheckListItem(m_lvPackages, *it, TQCheckListItem::CheckBox);
if ( reg.exactMatch(m_config->readEntry(*it)) ) {
if ( reg.cap(1) == "1" ) // selected state (entry 1)
cli->setOn(true);
@@ -1200,14 +1200,14 @@ bool QuickDocument::readPackagesListview()
KILE_DEBUG() << "\twrong config entry for package " << cli->text(0) << endl;
}
} else { // child entry
- cli = dynamic_cast<QCheckListItem*>(m_lvPackages->findItem((*it).left(pos), 0));
+ cli = dynamic_cast<TQCheckListItem*>(m_lvPackages->tqfindItem((*it).left(pos), 0));
if ( cli ) {
- QCheckListItem *clichild;
+ TQCheckListItem *clichild;
if ( reg.exactMatch(m_config->readEntry(*it)) ) {
if ( reg.cap(2) == "1" ) { // editable state
clichild = insertEditableListview(cli,(*it).mid(pos+1),reg.cap(5),reg.cap(4),reg.cap(3) );
} else {
- clichild = new QCheckListItem(cli, (*it).mid(pos+1), QCheckListItem::CheckBox);
+ clichild = new TQCheckListItem(cli, (*it).mid(pos+1), TQCheckListItem::CheckBox);
clichild->setText(2,reg.cap(5)); // description
}
if ( reg.cap(1) == "1" ) // selected state
@@ -1228,19 +1228,19 @@ void QuickDocument::writePackagesConfig()
{
KILE_DEBUG() << "\twrite config: packages" << endl;
- QStringList packagesList;
+ TQStringList packagesList;
m_config->setGroup( "QuickDocument/Packages" );
- for (QListViewItem *cur=m_lvPackages->firstChild(); cur; cur=cur->nextSibling()) {
+ for (TQListViewItem *cur=m_lvPackages->firstChild(); cur; cur=cur->nextSibling()) {
KILE_DEBUG() << "\twrite config: " << cur->text(0) << endl;
// add to packages list
packagesList += cur->text(0);
// determine config entry
- QString packageentry;
+ TQString packageentry;
// look for selected entries
- QCheckListItem *cli = dynamic_cast<QCheckListItem*>(cur);
+ TQCheckListItem *cli = dynamic_cast<TQCheckListItem*>(cur);
if ( cli && cli->isOn() )
packageentry = "1,";
else
@@ -1258,27 +1258,27 @@ void QuickDocument::writePackagesConfig()
// write listview entry
m_config->writeEntry(cur->text(0),packageentry);
- // look for children
- for (QListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
+ // look for tqchildren
+ for (TQListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
// add child to packages list
- QString option = cur->text(0) + '!' + curchild->text(0);
+ TQString option = cur->text(0) + '!' + curchild->text(0);
packagesList += option;
KILE_DEBUG() << "\twrite config: " << option << endl;
// determine config entry
- QString optionentry;
+ TQString optionentry;
// look for selected options
- QCheckListItem *clichild = dynamic_cast<QCheckListItem*>(curchild);
+ TQCheckListItem *clichild = dynamic_cast<TQCheckListItem*>(curchild);
if ( clichild && clichild->isOn() )
optionentry = "1,";
else
optionentry = "0,";
// look, if this child is editable
- if ( clichild && m_dictPackagesEditable.contains(option) ) {
+ if ( clichild && m_dictPackagesEditable.tqcontains(option) ) {
optionentry += "1,";
- if ( m_dictPackagesDefaultvalues.contains(option) )
+ if ( m_dictPackagesDefaultvalues.tqcontains(option) )
optionentry += m_dictPackagesDefaultvalues[option] + ',';
else
optionentry += ',';
@@ -1299,11 +1299,11 @@ void QuickDocument::writePackagesConfig()
}
// insert package
-QCheckListItem *QuickDocument::insertListview(QListView *listview,
- const QString &entry,
- const QString &description)
+TQCheckListItem *QuickDocument::insertListview(TQListView *listview,
+ const TQString &entry,
+ const TQString &description)
{
- QCheckListItem *item = new QCheckListItem(listview,entry,QCheckListItem::CheckBox);
+ TQCheckListItem *item = new TQCheckListItem(listview,entry,TQCheckListItem::CheckBox);
if ( ! description.isEmpty() )
item->setText(2,description);
@@ -1311,11 +1311,11 @@ QCheckListItem *QuickDocument::insertListview(QListView *listview,
}
// insert package option (not editable)
-QCheckListItem *QuickDocument::insertListview(QCheckListItem *parent,
- const QString &entry,
- const QString &description)
+TQCheckListItem *QuickDocument::insertListview(TQCheckListItem *tqparent,
+ const TQString &entry,
+ const TQString &description)
{
- QCheckListItem *item = new QCheckListItem(parent,entry,QCheckListItem::CheckBox);
+ TQCheckListItem *item = new TQCheckListItem(tqparent,entry,TQCheckListItem::CheckBox);
if ( ! description.isEmpty() )
item->setText(2,description);
@@ -1323,12 +1323,12 @@ QCheckListItem *QuickDocument::insertListview(QCheckListItem *parent,
}
// insert package option (editable)
-QCheckListItem *QuickDocument::insertEditableListview(QCheckListItem *parent,
- const QString &entry,const QString &description,
- const QString value,const QString defaultvalue)
+TQCheckListItem *QuickDocument::insertEditableListview(TQCheckListItem *tqparent,
+ const TQString &entry,const TQString &description,
+ const TQString value,const TQString defaultvalue)
{
- QCheckListItem *item = new EditableCheckListItem(parent,entry);
- QString option = parent->text(0) + '!' + entry;
+ TQCheckListItem *item = new EditableCheckListItem(tqparent,entry);
+ TQString option = tqparent->text(0) + '!' + entry;
m_dictPackagesEditable[option] = true;
if ( ! defaultvalue.isEmpty() )
m_dictPackagesDefaultvalues[option] = defaultvalue;
@@ -1339,11 +1339,11 @@ QCheckListItem *QuickDocument::insertEditableListview(QCheckListItem *parent,
return item;
}
-void QuickDocument::setPackagesValue(QListViewItem *item,const QString &option,const QString &val)
+void QuickDocument::setPackagesValue(TQListViewItem *item,const TQString &option,const TQString &val)
{
- QString defaultvalue = ( m_dictPackagesDefaultvalues.contains(option) )
- ? m_dictPackagesDefaultvalues[option] : QString::null;
- QString value = ( ! val.isEmpty() ) ? val : QString::null;
+ TQString defaultvalue = ( m_dictPackagesDefaultvalues.tqcontains(option) )
+ ? m_dictPackagesDefaultvalues[option] : TQString();
+ TQString value = ( ! val.isEmpty() ) ? val : TQString();
if ( value == defaultvalue )
item->setText(1,i18n("<default>") );
@@ -1353,15 +1353,15 @@ void QuickDocument::setPackagesValue(QListViewItem *item,const QString &option,c
item->setText(1,value);
}
-QString QuickDocument::getPackagesValue(const QString &value)
+TQString QuickDocument::getPackagesValue(const TQString &value)
{
- return ( value==i18n("<default>") || value==i18n("<empty>") ) ? QString::null : value;
+ return ( value==i18n("<default>") || value==i18n("<empty>") ) ? TQString() : value;
}
-bool QuickDocument::isListviewEntry(QListView *listview,const QString &entry)
+bool QuickDocument::isListviewEntry(TQListView *listview,const TQString &entry)
{
- for ( QListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() ) {
+ for ( TQListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() ) {
if ( cur->text(0) == entry )
return true;
}
@@ -1369,13 +1369,13 @@ bool QuickDocument::isListviewEntry(QListView *listview,const QString &entry)
return false;
}
-bool QuickDocument::isListviewChild(QListView *listview,const QString &entry, const QString &option)
+bool QuickDocument::isListviewChild(TQListView *listview,const TQString &entry, const TQString &option)
{
- for ( QListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() ) {
+ for ( TQListViewItem *cur=listview->firstChild(); cur; cur=cur->nextSibling() ) {
// look for the main entry
if ( cur->text(0) == entry ) {
- // look for children
- for (QListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
+ // look for tqchildren
+ for (TQListViewItem *curchild=cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
if ( option == curchild->text(0) )
return true;
}
@@ -1386,16 +1386,16 @@ bool QuickDocument::isListviewChild(QListView *listview,const QString &entry, co
return false;
}
-QString QuickDocument::addPackageDefault(const QString &option,const QString &description)
+TQString QuickDocument::addPackageDefault(const TQString &option,const TQString &description)
{
- return ( m_dictPackagesDefaultvalues.contains(option) )
+ return ( m_dictPackagesDefaultvalues.tqcontains(option) )
? description + " [" + m_dictPackagesDefaultvalues[option] + ']'
: description + " [ ]";
}
-QString QuickDocument::stripPackageDefault(const QString &option,const QString &description)
+TQString QuickDocument::stripPackageDefault(const TQString &option,const TQString &description)
{
- QRegExp reg("(.*) \\[([^\\[]*)\\]");
+ TQRegExp reg("(.*) \\[([^\\[]*)\\]");
if ( description.right(4) == " [ ]" )
return description.left(description.length()-4);
@@ -1404,7 +1404,7 @@ QString QuickDocument::stripPackageDefault(const QString &option,const QString &
return description;
return ( reg.cap(2).isEmpty() ||
- ( m_dictPackagesDefaultvalues.contains(option) && m_dictPackagesDefaultvalues[option]==reg.cap(2) )
+ ( m_dictPackagesDefaultvalues.tqcontains(option) && m_dictPackagesDefaultvalues[option]==reg.cap(2) )
) ? reg.cap(1) : description;
}
@@ -1415,24 +1415,24 @@ void QuickDocument::initHyperref()
KILE_DEBUG() << "\tread config: init hyperref" << endl;
- QString driver = "dvipdf,dvipdfm,dvips,dvipsone,"
+ TQString driver = "dvipdf,dvipdfm,dvips,dvipsone,"
"dviwindo,hypertex,latex2html,pdftex,"
"ps2pdf,tex4ht,textures,vtex";
- QStringList list = QStringList::split(",",driver);
+ TQStringList list = TQStringList::split(",",driver);
m_dictHyperrefDriver.clear();
for ( uint i=0; i<list.count(); ++i )
m_dictHyperrefDriver[list[i]] = true;
}
-bool QuickDocument::isHyperrefDriver(const QString &name)
+bool QuickDocument::isHyperrefDriver(const TQString &name)
{
- return m_dictHyperrefDriver.contains(name);
+ return m_dictHyperrefDriver.tqcontains(name);
}
////////////////////////////// check for existing exntries //////////////////////////////
-bool QuickDocument::isDocumentClass(const QString &name)
+bool QuickDocument::isDocumentClass(const TQString &name)
{
for ( int i=0; i<m_cbDocumentClass->count(); ++i ) {
if ( m_cbDocumentClass->text(i) == name )
@@ -1441,17 +1441,17 @@ bool QuickDocument::isDocumentClass(const QString &name)
return false;
}
-bool QuickDocument::isDocumentClassOption(const QString &option)
+bool QuickDocument::isDocumentClassOption(const TQString &option)
{
return isListviewEntry(m_lvClassOptions,option);
}
-bool QuickDocument::isPackage(const QString &package)
+bool QuickDocument::isPackage(const TQString &package)
{
return isListviewEntry(m_lvPackages,package);
}
-bool QuickDocument::isPackageOption(const QString &package, const QString &option)
+bool QuickDocument::isPackageOption(const TQString &package, const TQString &option)
{
return isListviewChild(m_lvPackages,package,option);
}
@@ -1464,14 +1464,14 @@ void QuickDocument::printTemplate()
KILE_DEBUG() << "==QuickDocument::printTemplate()============" << endl;
// get current document class
- QString documentclass = m_cbDocumentClass->currentText();
+ TQString documentclass = m_cbDocumentClass->currentText();
KILE_DEBUG() << "\tdocument class: " << documentclass << endl;
// build template
m_td.tagBegin = "\\documentclass";
// build options
- QString options;
+ TQString options;
if ( documentclass != "beamer" ) {
if ( !m_cbPaperSize->currentText().isEmpty() )
options += stripDefault( m_cbPaperSize->currentText() ) + ',';
@@ -1480,8 +1480,8 @@ void QuickDocument::printTemplate()
if ( !m_cbTypefaceSize->currentText().isEmpty() )
options += stripDefault( m_cbTypefaceSize->currentText() ) + ',';
- for (QListViewItem *cur=m_lvClassOptions->firstChild(); cur; cur=cur->nextSibling()) {
- QCheckListItem *cli=dynamic_cast<QCheckListItem*>(cur);
+ for (TQListViewItem *cur=m_lvClassOptions->firstChild(); cur; cur=cur->nextSibling()) {
+ TQCheckListItem *cli=dynamic_cast<TQCheckListItem*>(cur);
if ( cli && cli->isOn() )
options += cur->text(0) + ',';
}
@@ -1491,10 +1491,10 @@ void QuickDocument::printTemplate()
m_td.tagBegin += '{' + documentclass + "}\n\n";
- QString enc = m_cbEncoding->currentText();
+ TQString enc = m_cbEncoding->currentText();
if (!enc.isEmpty())
{
- if( enc.find("utf") != -1 )
+ if( enc.tqfind("utf") != -1 )
m_td.tagBegin += "\\usepackage{ucs}\n";
m_td.tagBegin += "\\usepackage[" + enc + "]{inputenc}\n";
}
@@ -1524,25 +1524,25 @@ void QuickDocument::printPackages()
KILE_DEBUG() << "\tpackages" << endl;
m_currentHyperref = false;
- m_hyperrefdriver = QString::null;
- m_hyperrefsetup = QString::null;
+ m_hyperrefdriver = TQString();
+ m_hyperrefsetup = TQString();
- for (QListViewItem *cur=m_lvPackages->firstChild(); cur; cur=cur->nextSibling()) {
- QCheckListItem *cli = dynamic_cast<QCheckListItem*>(cur);
+ for (TQListViewItem *cur=m_lvPackages->firstChild(); cur; cur=cur->nextSibling()) {
+ TQCheckListItem *cli = dynamic_cast<TQCheckListItem*>(cur);
if ( ! cli )
continue;
if ( cur->text(0) == "hyperref" ) { // manage hyperref package
m_currentHyperref = cli->isOn();
- for (QListViewItem *curchild = cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
- QCheckListItem *clichild = dynamic_cast<QCheckListItem*>(curchild);
+ for (TQListViewItem *curchild = cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
+ TQCheckListItem *clichild = dynamic_cast<TQCheckListItem*>(curchild);
if (clichild && clichild->isOn() ) { // manage hyperref option
if ( isHyperrefDriver(curchild->text(0)) ) { // either hyperref driver
if ( ! m_hyperrefdriver.isEmpty() )
m_hyperrefdriver += ',';
m_hyperrefdriver += curchild->text(0);
} else {
- QString value = curchild->text(1); // or another option
+ TQString value = curchild->text(1); // or another option
if ( value != i18n("<default>") ) {
if ( ! m_hyperrefsetup.isEmpty() )
m_hyperrefsetup += ',';
@@ -1552,13 +1552,13 @@ void QuickDocument::printPackages()
}
}
} else if ( cli->isOn() ) { // manage other package options
- QString packageOptions;
- for (QListViewItem *curchild = cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
- QCheckListItem *clichild = dynamic_cast<QCheckListItem*>(curchild);
+ TQString packageOptions;
+ for (TQListViewItem *curchild = cur->firstChild(); curchild; curchild=curchild->nextSibling()) {
+ TQCheckListItem *clichild = dynamic_cast<TQCheckListItem*>(curchild);
if (clichild && clichild->isOn()) {
- QString optiontext;
- if ( m_dictPackagesEditable.contains(cur->text(0) + '!' + curchild->text(0)) ) {
- QString value = curchild->text(1);
+ TQString optiontext;
+ if ( m_dictPackagesEditable.tqcontains(cur->text(0) + '!' + curchild->text(0)) ) {
+ TQString value = curchild->text(1);
if ( value != i18n("<default>") )
optiontext = curchild->text(0) + '=' + getPackagesValue(curchild->text(1));
} else
@@ -1608,11 +1608,11 @@ void QuickDocument::printBeamerTheme()
{
KILE_DEBUG() << "\tbeamer theme" << endl;
- QString theme = m_cbPaperSize->currentText();
- QRegExp reg("(\\w+)\\s+\\((.*)\\)$");
+ TQString theme = m_cbPaperSize->currentText();
+ TQRegExp reg("(\\w+)\\s+\\((.*)\\)$");
if ( reg.search(theme) >= 0 ) {
- QStringList optionlist = QStringList::split(",",reg.cap(2));
+ TQStringList optionlist = TQStringList::split(",",reg.cap(2));
m_td.tagBegin += "\\usepackage[" + optionlist.join(",") + "]{beamertheme" + reg.cap(1) + "}\n\n";
} else {
m_td.tagBegin += "\\usepackage{beamertheme" + theme + "}\n\n";
@@ -1647,11 +1647,11 @@ void QuickDocument::slotOk()
void QuickDocument::slotDocumentClassAdd()
{
KILE_DEBUG() << "==QuickDocument::slotDocumentClassAdd()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Document Class")
<< "label,edit,label,combobox,checkbox,checkbox"
<< i18n("Please enter the new document &class:")
- << QString::null // 3
+ << TQString() // 3
<< i18n("&Set all options from this standard class (optional):")
<< ",article,book,letter,report,scrartcl,scrbook,scrreprt" // 5
<< i18n("Use standard &fontsizes") // 6
@@ -1659,13 +1659,13 @@ void QuickDocument::slotDocumentClassAdd()
;
if ( inputDialog(list,qd_CheckNotEmpty | qd_CheckDocumentClass) ) {
- QString classname = list[3];
+ TQString classname = list[3];
- QStringList classlist;
+ TQStringList classlist;
if ( list[5].isEmpty() ) { // no base class
- QString useFontsizes = ( list[6] == "true" )
+ TQString useFontsizes = ( list[6] == "true" )
? "10pt,11pt,12pt" : "";
- QString usePapersizes = ( list[7] == "true" )
+ TQString usePapersizes = ( list[7] == "true" )
? "a4paper,a5paper,b5paper,executivepaper,legalpaper,letterpaper" : "";
KILE_DEBUG() << "\tadd document class: " << classname
<< " fontsize=" << list[6] << " papersize=" << list[7] << endl;
@@ -1676,7 +1676,7 @@ void QuickDocument::slotDocumentClassAdd()
// first get the first four parameters
classlist = m_dictDocumentClasses[list[5]];
// then add all baseclass options
- QStringList optionlist;
+ TQStringList optionlist;
initStandardOptions(list[5],optionlist);
for (uint i=0; i<optionlist.count(); ++i)
classlist.append(optionlist[i]);
@@ -1698,10 +1698,10 @@ void QuickDocument::slotDocumentClassAdd()
void QuickDocument::slotDocumentClassDelete()
{
// get the name of the current class
- QString documentclass = m_cbDocumentClass->currentText();
+ TQString documentclass = m_cbDocumentClass->currentText();
KILE_DEBUG() << "==QuickDocument::slotDocumentClassDelete()============" << endl;
- if (KMessageBox::warningContinueCancel(this, i18n("Do you want to remove \"%1\" from the document class list?").arg(documentclass), i18n("Remove Document Class"))==KMessageBox::Continue)
+ if (KMessageBox::warningContinueCancel(this, i18n("Do you want to remove \"%1\" from the document class list?").tqarg(documentclass), i18n("Remove Document Class"))==KMessageBox::Continue)
{
KILE_DEBUG() << "\tlazy delete class: " << documentclass << endl;
@@ -1709,7 +1709,7 @@ void QuickDocument::slotDocumentClassDelete()
m_dictDocumentClasses.remove(documentclass);
// mark this document class for deleting from config file (only with OK-Button)
- if ( m_deleteDocumentClasses.findIndex(documentclass) == -1 )
+ if ( m_deleteDocumentClasses.tqfindIndex(documentclass) == -1 )
m_deleteDocumentClasses.append(documentclass);
// remove it from the list of userclasses
@@ -1736,7 +1736,7 @@ void QuickDocument::slotDocumentClassChanged(int index)
}
// get old and new document class
- QString oldclass = m_currentClass;
+ TQString oldclass = m_currentClass;
m_currentClass = m_cbDocumentClass->text(index);
KILE_DEBUG() << "\tchange class: " << oldclass << " --> " << m_currentClass << endl;
@@ -1751,11 +1751,11 @@ void QuickDocument::slotDocumentClassChanged(int index)
void QuickDocument::slotTypefaceSizeAdd()
{
KILE_DEBUG() << "==QuickDocument::slotTypefaceSizeAdd()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Add Fontsize")
<< "label,edit"
<< i18n("Please enter the &fontsizes (comma-separated list):")
- << QString::null // 3
+ << TQString() // 3
;
if ( inputDialog(list,qd_CheckNotEmpty |qd_CheckFontsize) ) {
@@ -1769,7 +1769,7 @@ void QuickDocument::slotTypefaceSizeAdd()
void QuickDocument::slotTypefaceSizeDelete()
{
- if (KMessageBox::warningContinueCancel(this, i18n("Do you want to remove \"%1\" from the fontsize list?").arg(m_cbPaperSize->currentText()), i18n("Remove Fontsize"))==KMessageBox::Continue)
+ if (KMessageBox::warningContinueCancel(this, i18n("Do you want to remove \"%1\" from the fontsize list?").tqarg(m_cbPaperSize->currentText()), i18n("Remove Fontsize"))==KMessageBox::Continue)
{
int i=m_cbPaperSize->currentItem();
m_cbPaperSize->removeItem(i);
@@ -1782,11 +1782,11 @@ void QuickDocument::slotTypefaceSizeDelete()
void QuickDocument::slotPaperSizeAdd()
{
KILE_DEBUG() << "==QuickDocument::slotPaperSizeAdd()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Add Papersize")
<< "label,edit"
<< i18n("Please enter the &papersizes (comma-separated list):")
- << QString::null // 3
+ << TQString() // 3
;
if ( inputDialog(list,qd_CheckNotEmpty |qd_CheckPapersize) ) {
@@ -1800,7 +1800,7 @@ void QuickDocument::slotPaperSizeAdd()
void QuickDocument::slotPaperSizeDelete()
{
- if (KMessageBox::warningContinueCancel(this, i18n("Do you want to remove \"%1\" from the papersize list?").arg(m_cbPaperSize->currentText()), i18n("Remove Papersize"))==KMessageBox::Continue)
+ if (KMessageBox::warningContinueCancel(this, i18n("Do you want to remove \"%1\" from the papersize list?").tqarg(m_cbPaperSize->currentText()), i18n("Remove Papersize"))==KMessageBox::Continue)
{
int i=m_cbPaperSize->currentItem();
m_cbPaperSize->removeItem(i);
@@ -1815,25 +1815,25 @@ void QuickDocument::slotPaperSizeDelete()
void QuickDocument::slotClassOptionAdd()
{
KILE_DEBUG() << "==QuickDocument::slotClassOptionAdd()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Add Option")
<< "label,edit,label,edit,checkbox"
<< i18n("Name of &option:")
- << QString::null // 3
+ << TQString() // 3
<< i18n("&Description:")
- << QString::null // 5
+ << TQString() // 5
<< i18n("&Select this option") // 6
;
if ( inputDialog(list,qd_CheckNotEmpty | qd_CheckClassOption) ) {
// get results
- QString option = list[3];
- QString description = list[5];
+ TQString option = list[3];
+ TQString description = list[5];
bool check = ( list[6] == "true" );
// add class option
KILE_DEBUG() << "\tadd option: " << option << " (" << description << ") checked=" << list[6] << endl;
- QCheckListItem *cli = new QCheckListItem(m_lvClassOptions, option, QCheckListItem::CheckBox);
+ TQCheckListItem *cli = new TQCheckListItem(m_lvClassOptions, option, TQCheckListItem::CheckBox);
cli->setText(1,description);
if ( check )
@@ -1846,12 +1846,12 @@ void QuickDocument::slotClassOptionAdd()
void QuickDocument::slotClassOptionEdit()
{
- QListViewItem *cur = m_lvClassOptions->selectedItem();
+ TQListViewItem *cur = m_lvClassOptions->selectedItem();
if ( ! cur )
return;
KILE_DEBUG() << "==QuickDocument::slotClassOptionEdit()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Edit Option")
<< "label,edit-r,label,edit"
<< i18n("Name of &option:")
@@ -1863,8 +1863,8 @@ void QuickDocument::slotClassOptionEdit()
//if ( inputDialog(list,qd_CheckNotEmpty | qd_CheckClassOption) ) {
if ( inputDialog(list) ) {
// get results
- //QString option = list[3];
- QString description = list[5];
+ //TQString option = list[3];
+ TQString description = list[5];
// set changed class option
KILE_DEBUG() << "\tedit option: " << cur->text(0) << " (" << description << ")" << endl;
@@ -1880,7 +1880,7 @@ void QuickDocument::slotClassOptionDelete()
{
KILE_DEBUG() << "==QuickDocument::slotClassOptionDelete()============" << endl;
if (m_lvClassOptions->selectedItem() && (KMessageBox::warningContinueCancel(this, i18n("Do you want to delete this class option?"), i18n("Delete"))==KMessageBox::Continue)) {
- QListViewItem *cur = m_lvClassOptions->selectedItem();
+ TQListViewItem *cur = m_lvClassOptions->selectedItem();
KILE_DEBUG() << "\tdelete option: " << cur->text(0) << " (" << cur->text(1) << ")" << endl;
m_lvClassOptions->takeItem(m_lvClassOptions->selectedItem());
@@ -1890,9 +1890,9 @@ void QuickDocument::slotClassOptionDelete()
}
}
-void QuickDocument::slotOptionDoubleClicked(QListViewItem *listViewItem,const QPoint &,int)
+void QuickDocument::slotOptionDoubleClicked(TQListViewItem *listViewItem,const TQPoint &,int)
{
- QCheckListItem *cli = dynamic_cast<QCheckListItem*>(listViewItem);
+ TQCheckListItem *cli = dynamic_cast<TQCheckListItem*>(listViewItem);
if ( cli ) {
if ( ! cli->isOn() ) {
cli->setOn(true);
@@ -1907,19 +1907,19 @@ void QuickDocument::slotOptionDoubleClicked(QListViewItem *listViewItem,const QP
void QuickDocument::slotPackageAdd()
{
KILE_DEBUG() << "==QuickDocument::slotPackageAdd()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Add Package")
<< "label,edit,label,edit,checkbox"
<< i18n("&Package:")
- << QString::null // 3
+ << TQString() // 3
<< i18n("&Description:")
- << QString::null // 5
+ << TQString() // 5
<< i18n("&Select this package") // 6
;
if ( inputDialog(list,qd_CheckNotEmpty | qd_CheckPackage) ) {
KILE_DEBUG() << "\tadd package: " << list[3] << " (" << list[5] << ") checked=" << list[6] << endl;
- QCheckListItem *cli = new QCheckListItem(m_lvPackages, list[3], QCheckListItem::CheckBox);
+ TQCheckListItem *cli = new TQCheckListItem(m_lvPackages, list[3], TQCheckListItem::CheckBox);
cli->setText(2, list[5]);
if ( list[6] == "true" )
cli->setOn(true);
@@ -1928,34 +1928,34 @@ void QuickDocument::slotPackageAdd()
void QuickDocument::slotPackageAddOption()
{
- QListViewItem *cur = m_lvPackages->selectedItem();
+ TQListViewItem *cur = m_lvPackages->selectedItem();
if ( !cur )
return;
KILE_DEBUG() << "==QuickDocument::packageAddOption()============" << endl;
- QStringList list;
+ TQStringList list;
list << i18n("Add Option")
<< "label,edit,checkbox,label,edit,label,edit,label,edit,checkbox"
<< i18n("&Option:") + " (" + i18n("package:") + ' ' + cur->text(0) + ')'
- << QString::null // 3
+ << TQString() // 3
<< i18n("&Editable") // 4
<< i18n("De&fault value:")
- << QString::null // 6
+ << TQString() // 6
<< i18n("&Value:")
- << QString::null // 8
+ << TQString() // 8
<< i18n("&Description:")
- << QString::null // 10
+ << TQString() // 10
<< i18n("&Select this option") // 11
;
- if ( !cur->parent() && inputDialog(list,qd_CheckNotEmpty | qd_CheckPackageOption) ) {
+ if ( !cur->tqparent() && inputDialog(list,qd_CheckNotEmpty | qd_CheckPackageOption) ) {
KILE_DEBUG() << "\tadd option: " << list[3] << " (" << list[10] << ") checked=" << list[11] << endl;
- QCheckListItem *cli;
+ TQCheckListItem *cli;
if ( list[4] == "true" ) {
- cli = insertEditableListview((QCheckListItem *)cur,list[3],list[10],list[8],list[6]);
+ cli = insertEditableListview((TQCheckListItem *)cur,list[3],list[10],list[8],list[6]);
} else {
- cli = new QCheckListItem(cur, list[3], QCheckListItem::CheckBox);
+ cli = new TQCheckListItem(cur, list[3], TQCheckListItem::CheckBox);
cli->setText(2,list[10]);
}
if ( list[11] == "true" )
@@ -1967,36 +1967,36 @@ void QuickDocument::slotPackageAddOption()
void QuickDocument::slotPackageEdit()
{
- QListViewItem *cur = m_lvPackages->selectedItem();
+ TQListViewItem *cur = m_lvPackages->selectedItem();
if ( !cur )
return;
KILE_DEBUG() << "==QuickDocument::slotPackageEdit()============" << endl;
bool editableOption;
- QString caption,labelText,optionname;
+ TQString caption,labelText,optionname;
- if ( cur->parent() ) {
+ if ( cur->tqparent() ) {
// checkmode = qd_CheckPackageOption;
caption = i18n("Edit Option");
- labelText = i18n("Op&tion:") + " (" + i18n("package:") + ' ' + cur->parent()->text(0) + ')';
- optionname = cur->parent()->text(0) + '!' + cur->text(0);
- editableOption = m_dictPackagesEditable.contains(optionname);
+ labelText = i18n("Op&tion:") + " (" + i18n("package:") + ' ' + cur->tqparent()->text(0) + ')';
+ optionname = cur->tqparent()->text(0) + '!' + cur->text(0);
+ editableOption = m_dictPackagesEditable.tqcontains(optionname);
} else {
// checkmode = qd_CheckPackage;
caption = i18n("Edit Package");
labelText = i18n("&Package:");
- optionname = QString::null;
+ optionname = TQString();
editableOption = false;
}
// create one of three different dialogs; edit package, edit editable option, edit option
- QStringList list;
+ TQStringList list;
list << caption;
if ( editableOption ) {
- QString defaultvalue = ( m_dictPackagesDefaultvalues.contains(optionname) )
+ TQString defaultvalue = ( m_dictPackagesDefaultvalues.tqcontains(optionname) )
? m_dictPackagesDefaultvalues[optionname]
- : QString::null;
- QString value = ( cur->text(1) == i18n("<default>") )
+ : TQString();
+ TQString value = ( cur->text(1) == i18n("<default>") )
? defaultvalue : getPackagesValue(cur->text(1));
list << "label,edit-r,label,edit-r,label,edit,label,edit"
@@ -2038,16 +2038,16 @@ void QuickDocument::slotPackageEdit()
void QuickDocument::slotPackageDelete()
{
- QListViewItem *cur = m_lvPackages->selectedItem();
+ TQListViewItem *cur = m_lvPackages->selectedItem();
if ( !cur )
return;
bool packageoption;
- QString message,optionname;
- if ( cur->parent() ) {
+ TQString message,optionname;
+ if ( cur->tqparent() ) {
packageoption = true;
message = i18n("Do you want do delete this package option?");
- optionname = cur->parent()->text(0) + '!' + cur->text(0);
+ optionname = cur->tqparent()->text(0) + '!' + cur->text(0);
} else {
packageoption = false;
message = i18n("Do you want to delete this package?");
@@ -2055,18 +2055,18 @@ void QuickDocument::slotPackageDelete()
}
if (KMessageBox::warningContinueCancel(this, message, i18n("Delete"))==KMessageBox::Continue) {
- QListViewItem *childcur = cur->firstChild();
+ TQListViewItem *childcur = cur->firstChild();
while (childcur) {
- QListViewItem *nextchildcur=childcur->nextSibling();
+ TQListViewItem *nextchildcur=childcur->nextSibling();
delete childcur;
childcur = nextchildcur;
}
delete cur;
// also delete entries for editable package option
- if ( packageoption && m_dictPackagesEditable.contains(optionname) ) {
+ if ( packageoption && m_dictPackagesEditable.tqcontains(optionname) ) {
m_dictPackagesEditable.remove(optionname);
- if ( m_dictPackagesDefaultvalues.contains(optionname) )
+ if ( m_dictPackagesDefaultvalues.tqcontains(optionname) )
m_dictPackagesDefaultvalues.remove(optionname);
}
}
@@ -2083,22 +2083,22 @@ void QuickDocument::slotPackageReset()
}
}
-void QuickDocument::slotCheckParent(QListViewItem *listViewItem)
+void QuickDocument::slotCheckParent(TQListViewItem *listViewItem)
{
- QCheckListItem *cli = dynamic_cast<QCheckListItem*>(listViewItem);
- if (cli && listViewItem->parent() && cli->isOn()) {
- QCheckListItem *cliparent=dynamic_cast<QCheckListItem*>(listViewItem->parent());
- if (cliparent)
- cliparent->setOn(true);
+ TQCheckListItem *cli = dynamic_cast<TQCheckListItem*>(listViewItem);
+ if (cli && listViewItem->tqparent() && cli->isOn()) {
+ TQCheckListItem *clitqparent=dynamic_cast<TQCheckListItem*>(listViewItem->tqparent());
+ if (clitqparent)
+ clitqparent->setOn(true);
}
}
-void QuickDocument::slotPackageDoubleClicked(QListViewItem *listViewItem,const QPoint &,int)
+void QuickDocument::slotPackageDoubleClicked(TQListViewItem *listViewItem,const TQPoint &,int)
{
- if ( listViewItem && listViewItem->parent() ) {
- QCheckListItem *parentitem = dynamic_cast<QCheckListItem*>(listViewItem->parent());
- QString option = parentitem->text(0) + '!' + listViewItem->text(0);
- if ( m_dictPackagesEditable.contains(option) )
+ if ( listViewItem && listViewItem->tqparent() ) {
+ TQCheckListItem *tqparentitem = dynamic_cast<TQCheckListItem*>(listViewItem->tqparent());
+ TQString option = tqparentitem->text(0) + '!' + listViewItem->text(0);
+ if ( m_dictPackagesEditable.tqcontains(option) )
slotPackageEdit();
}
}
@@ -2125,11 +2125,11 @@ void QuickDocument::slotEnableButtons()
m_btnClassOptionsDelete->setEnabled(enable);
// packeges
- QListViewItem *cur = m_lvPackages->selectedItem();
+ TQListViewItem *cur = m_lvPackages->selectedItem();
if ( cur && cur->text(0)!= "hyperref" ) {
m_btnPackagesEdit->setEnabled(true);
m_btnPackagesDelete->setEnabled(true);
- if ( cur->parent() )
+ if ( cur->tqparent() )
m_btnPackagesAddOption->setEnabled(false);
else
m_btnPackagesAddOption->setEnabled(true);
@@ -2147,10 +2147,10 @@ void QuickDocument::slotEnableButtons()
// Entry 1 is always the label for the main lineedit, entry 2 the main lineedit. All
// other objects are optionale and their return values are not checked.
// 0 : caption (input: always)
-// 1 : comma separated list of Qt widgets (label,checkbox,edit,edit-r)
-// 2ff : strings for Qt widgets
+// 1 : comma separated list of TQt widgets (label,checkbox,edit,edit-r)
+// 2ff : strings for TQt widgets
-bool QuickDocument::inputDialog(QStringList &list, int check)
+bool QuickDocument::inputDialog(TQStringList &list, int check)
{
QuickDocumentInputDialog *dialog = new QuickDocumentInputDialog(list,check,this,"inputDialog");
@@ -2165,33 +2165,33 @@ bool QuickDocument::inputDialog(QStringList &list, int check)
}
-QuickDocumentInputDialog::QuickDocumentInputDialog(const QStringList &list,int check,
- QuickDocument *parent,
+QuickDocumentInputDialog::QuickDocumentInputDialog(const TQStringList &list,int check,
+ QuickDocument *tqparent,
const char *name )
- : KDialogBase(parent,name,true,list[0],KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true),
- m_parent(parent),
+ : KDialogBase(tqparent,name,true,list[0],KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true),
+ m_parent(tqparent),
m_check(check)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- QVBoxLayout *vl = new QVBoxLayout(page, 0, spacingHint());
+ TQVBoxLayout *vl = new TQVBoxLayout(page, 0, spacingHint());
int firstlinedit = -1;
- m_description = QStringList::split(",",list[1]);
+ m_description = TQStringList::split(",",list[1]);
for ( uint i=0; i<m_description.count(); ++i ) {
// create the object
if ( m_description[i] == "label" ) {
- m_objectlist.append( new QLabel(list[i+2],page) );
+ m_objectlist.append( new TQLabel(list[i+2],page) );
} else if ( m_description[i]=="checkbox" ) {
- m_objectlist.append( new QCheckBox(list[i+2],page) );
+ m_objectlist.append( new TQCheckBox(list[i+2],page) );
} else if ( m_description[i]=="combobox" ) {
KComboBox *combobox = new KComboBox(page);
- combobox->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Minimum);
+ combobox->tqsetSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::Minimum);
combobox->setDuplicatesEnabled(false);
- combobox->insertStringList( QStringList::split(",",list[i+2],true) );
+ combobox->insertStringList( TQStringList::split(",",list[i+2],true) );
if ( i>0 && m_description[i-1]=="label" )
- ((QLabel *)m_objectlist[i-1])->setBuddy(combobox);
+ ((TQLabel *)m_objectlist[i-1])->setBuddy(combobox);
m_objectlist.append( combobox );
} else {
m_objectlist.append( new KLineEdit(list[i+2],page) );
@@ -2200,10 +2200,10 @@ QuickDocumentInputDialog::QuickDocumentInputDialog(const QStringList &list,int c
else if ( firstlinedit == -1 )
firstlinedit = i;
if ( i>0 && m_description[i-1]=="label" )
- ((QLabel *)m_objectlist[i-1])->setBuddy(m_objectlist[i]);
+ ((TQLabel *)m_objectlist[i-1])->setBuddy(m_objectlist[i]);
}
- // insert the new object into the layout
+ // insert the new object into the tqlayout
vl->addWidget(m_objectlist[i]);
}
@@ -2216,13 +2216,13 @@ QuickDocumentInputDialog::QuickDocumentInputDialog(const QStringList &list,int c
QuickDocumentInputDialog::~QuickDocumentInputDialog()
{}
-void QuickDocumentInputDialog::getResults(QStringList &list)
+void QuickDocumentInputDialog::getResults(TQStringList &list)
{
for ( uint i=0; i<m_description.count(); ++i ) {
if ( m_description[i] == "label" ) {
- list[i+2] = ((QLabel *)m_objectlist[i])->text();
+ list[i+2] = ((TQLabel *)m_objectlist[i])->text();
} else if ( m_description[i] == "checkbox" ) {
- list[i+2] = ( ((QCheckBox *)m_objectlist[i])->isOn() ) ? "true" : "false";
+ list[i+2] = ( ((TQCheckBox *)m_objectlist[i])->isOn() ) ? "true" : "false";
} else if ( m_description[i] == "combobox" ) {
list[i+2] = ((KComboBox *)m_objectlist[i])->currentText();
} else {
@@ -2232,24 +2232,24 @@ void QuickDocumentInputDialog::getResults(QStringList &list)
}
// get the package name from string 'Option: (package: name)'
-QString QuickDocumentInputDialog::getPackageName(const QString &text)
+TQString QuickDocumentInputDialog::getPackageName(const TQString &text)
{
- QRegExp reg( i18n("package:") + " ([^\\)]+)" );
- return ( reg.search(text) >= 0 ) ? reg.cap(1) : QString::null;
+ TQRegExp reg( i18n("package:") + " ([^\\)]+)" );
+ return ( reg.search(text) >= 0 ) ? reg.cap(1) : TQString();
}
-bool QuickDocumentInputDialog::checkListEntries(const QString &title, const QString &textlist,
- const QString &pattern)
+bool QuickDocumentInputDialog::checkListEntries(const TQString &title, const TQString &textlist,
+ const TQString &pattern)
{
// split entries (one or a comma separated list)
- QStringList list = QStringList::split(",",textlist);
+ TQStringList list = TQStringList::split(",",textlist);
for ( uint i=0; i<list.count(); ++i ) {
- QString s = list[i].stripWhiteSpace();
+ TQString s = list[i].stripWhiteSpace();
// entries must match a regular expression
- QRegExp reg(pattern);
+ TQRegExp reg(pattern);
if ( ! reg.exactMatch(s) ) {
- KMessageBox::error( this, i18n("%1 '%2' is not allowed.").arg(title).arg(s) );
+ KMessageBox::error( this, i18n("%1 '%2' is not allowed.").tqarg(title).tqarg(s) );
return false;
}
}
@@ -2261,8 +2261,8 @@ void QuickDocumentInputDialog::slotOk()
{
if ( m_check ) {
// get the label and main input string from the first label/linedit
- QString inputlabel = ((QLabel *)m_objectlist[0])->text();
- QString input = ((KLineEdit *)m_objectlist[1])->text().simplifyWhiteSpace();
+ TQString inputlabel = ((TQLabel *)m_objectlist[0])->text();
+ TQString input = ((KLineEdit *)m_objectlist[1])->text().simplifyWhiteSpace();
// should we check for an empty string
if ( (m_check & qd_CheckNotEmpty) && input.isEmpty() ) {
@@ -2277,7 +2277,7 @@ void QuickDocumentInputDialog::slotOk()
return;
}
- QRegExp reg("\\w+");
+ TQRegExp reg("\\w+");
if ( ! reg.exactMatch(input) ) {
KMessageBox::error( this, i18n("This is not an allowed name for a document class.") );
return;
@@ -2298,7 +2298,7 @@ void QuickDocumentInputDialog::slotOk()
// should we check for an existing package option
if ( m_check & qd_CheckPackageOption ) {
- QString package = getPackageName(inputlabel);
+ TQString package = getPackageName(inputlabel);
if ( package.isEmpty() ) {
KMessageBox::error( this, i18n("Could not identify the package name.") );
return;
diff --git a/src/kile/quickdocumentdialog.h b/src/kile/quickdocumentdialog.h
index 57bfdf5..9d25fa6 100644
--- a/src/kile/quickdocumentdialog.h
+++ b/src/kile/quickdocumentdialog.h
@@ -16,16 +16,16 @@ email : holger.danielsson@t-online.de
* *
***************************************************************************/
-#ifndef KILEDIALOGQUICKDOCHEADER_H
-#define KILEDIALOGQUICKDOCHEADER_H
+#ifndef KILEDIALOGTQUICKDOCHEADER_H
+#define KILEDIALOGTQUICKDOCHEADER_H
-#include <qmap.h>
-#include <qvaluelist.h>
+#include <tqmap.h>
+#include <tqvaluelist.h>
#include "kilewizard.h"
class KComboBox;
-class QListView;
-class QCheckListItem;
+class TQListView;
+class TQCheckListItem;
class KLineEdit;
class KPushButton;
@@ -46,16 +46,17 @@ enum {
class QuickDocument : public Wizard
{
Q_OBJECT
+ TQ_OBJECT
public:
- QuickDocument(KConfig *, QWidget *parent=0, const char *name=0, const QString &caption = QString::null);
+ QuickDocument(KConfig *, TQWidget *tqparent=0, const char *name=0, const TQString &caption = TQString());
~QuickDocument();
- bool isStandardClass(const QString &classname);
- bool isDocumentClass(const QString &name);
- bool isDocumentClassOption(const QString &option);
- bool isPackage(const QString &package);
- bool isPackageOption(const QString &package, const QString &option);
+ bool isStandardClass(const TQString &classname);
+ bool isDocumentClass(const TQString &name);
+ bool isDocumentClassOption(const TQString &option);
+ bool isPackage(const TQString &package);
+ bool isPackageOption(const TQString &package, const TQString &option);
public slots:
void slotOk();
@@ -65,30 +66,30 @@ private:
KComboBox *m_cbTypefaceSize;
KComboBox *m_cbPaperSize;
KComboBox *m_cbEncoding;
- QListView *m_lvClassOptions;
- QListView *m_lvPackages;
+ TQListView *m_lvClassOptions;
+ TQListView *m_lvPackages;
KLineEdit *m_leAuthor;
KLineEdit *m_leTitle;
KLineEdit *m_leDate;
- QLabel *m_lbPaperSize;
+ TQLabel *m_lbPaperSize;
- QString m_currentClass;
- QString m_currentFontsize;
- QString m_currentPapersize;
- QString m_currentEncoding;
+ TQString m_currentClass;
+ TQString m_currentFontsize;
+ TQString m_currentPapersize;
+ TQString m_currentEncoding;
bool m_currentHyperref;
- QString m_hyperrefdriver;
- QString m_hyperrefsetup;
- QStringList m_userClasslist;
- QStringList m_deleteDocumentClasses;
+ TQString m_hyperrefdriver;
+ TQString m_hyperrefsetup;
+ TQStringList m_userClasslist;
+ TQStringList m_deleteDocumentClasses;
- QMap<QString,QStringList> m_dictDocumentClasses;
- QMap<QString,bool> m_dictStandardClasses;
- QMap<QString,bool> m_currentDefaultOptions;
- QMap<QString,bool> m_currentSelectedOptions;
- QMap<QString,bool> m_dictPackagesEditable;
- QMap<QString,QString> m_dictPackagesDefaultvalues;
- QMap<QString,bool> m_dictHyperrefDriver;
+ TQMap<TQString,TQStringList> m_dictDocumentClasses;
+ TQMap<TQString,bool> m_dictStandardClasses;
+ TQMap<TQString,bool> m_currentDefaultOptions;
+ TQMap<TQString,bool> m_currentSelectedOptions;
+ TQMap<TQString,bool> m_dictPackagesEditable;
+ TQMap<TQString,TQString> m_dictPackagesDefaultvalues;
+ TQMap<TQString,bool> m_dictHyperrefDriver;
KPushButton *m_btnDocumentClassAdd;
KPushButton *m_btnDocumentClassDelete;
@@ -109,9 +110,9 @@ private:
KPushButton *m_btnPackagesReset;
// GUI
- QWidget *setupClassOptions(QTabWidget *tab);
- QWidget *setupPackages(QTabWidget *tab);
- QWidget *setupProperties(QTabWidget *tab);
+ TQWidget *setupClassOptions(TQTabWidget *tab);
+ TQWidget *setupPackages(TQTabWidget *tab);
+ TQWidget *setupProperties(TQTabWidget *tab);
// read/write config files and init data
void readConfig();
@@ -124,44 +125,44 @@ private:
// document class tab
void initDocumentClass();
- void initStandardClass(const QString &classname,const QString &fontsize,
- const QString &papersize,const QString &defaultoptions,
- const QString &selectedoptions);
- void initStandardOptions(const QString &classname,QStringList &optionlist);
- void setDefaultClassOptions(const QString &defaultoptions);
- void setSelectedClassOptions(const QString &selectedoptions);
- void setClassOptions(const QStringList &list,uint start);
+ void initStandardClass(const TQString &classname,const TQString &fontsize,
+ const TQString &papersize,const TQString &defaultoptions,
+ const TQString &selectedoptions);
+ void initStandardOptions(const TQString &classname,TQStringList &optionlist);
+ void setDefaultClassOptions(const TQString &defaultoptions);
+ void setSelectedClassOptions(const TQString &selectedoptions);
+ void setClassOptions(const TQStringList &list,uint start);
void updateClassOptions();
- QString getClassOptions();
+ TQString getClassOptions();
void fillDocumentClassCombobox();
- void fillCombobox(KComboBox *combo, const QString &cslist,const QString &seltext);
- bool addComboboxEntries(KComboBox *combo, const QString &title,const QString &entry);
- QString getComboxboxList(KComboBox *combo);
+ void fillCombobox(KComboBox *combo, const TQString &cslist,const TQString &seltext);
+ bool addComboboxEntries(KComboBox *combo, const TQString &title,const TQString &entry);
+ TQString getComboxboxList(KComboBox *combo);
- bool isDefaultClassOption(const QString &option);
- bool isSelectedClassOption(const QString &option);
- QString stripDefault(const QString &s);
+ bool isDefaultClassOption(const TQString &option);
+ bool isSelectedClassOption(const TQString &option);
+ TQString stripDefault(const TQString &s);
// packages tab
void initPackages();
bool readPackagesListview();
- QCheckListItem *insertListview(QListView *listview,
- const QString &entry,
- const QString &description);
- QCheckListItem *insertListview(QCheckListItem *parent,
- const QString &entry,
- const QString &description);
- QCheckListItem *insertEditableListview(QCheckListItem *parent,
- const QString &entry,const QString &description,
- const QString value,const QString defaultvalue);
- bool isListviewEntry(QListView *listview,const QString &entry);
- void setPackagesValue(QListViewItem *item,const QString &option,const QString &val);
- QString getPackagesValue(const QString &value);
-
- bool isListviewChild(QListView *listview,const QString &entry, const QString &option);
- QString addPackageDefault(const QString &option,const QString &description);
- QString stripPackageDefault(const QString &option,const QString &description);
- bool isHyperrefDriver(const QString &name);
+ TQCheckListItem *insertListview(TQListView *listview,
+ const TQString &entry,
+ const TQString &description);
+ TQCheckListItem *insertListview(TQCheckListItem *tqparent,
+ const TQString &entry,
+ const TQString &description);
+ TQCheckListItem *insertEditableListview(TQCheckListItem *tqparent,
+ const TQString &entry,const TQString &description,
+ const TQString value,const TQString defaultvalue);
+ bool isListviewEntry(TQListView *listview,const TQString &entry);
+ void setPackagesValue(TQListViewItem *item,const TQString &option,const TQString &val);
+ TQString getPackagesValue(const TQString &value);
+
+ bool isListviewChild(TQListView *listview,const TQString &entry, const TQString &option);
+ TQString addPackageDefault(const TQString &option,const TQString &description);
+ TQString stripPackageDefault(const TQString &option,const TQString &description);
+ bool isHyperrefDriver(const TQString &name);
// document template
void printTemplate();
@@ -170,7 +171,7 @@ private:
void printBeamerTheme();
// input dialog
- bool inputDialog(QStringList &list,int check=qd_CheckNotEmpty);
+ bool inputDialog(TQStringList &list,int check=qd_CheckNotEmpty);
private slots:
void slotDocumentClassAdd();
@@ -180,13 +181,13 @@ private slots:
void slotTypefaceSizeDelete();
void slotPaperSizeAdd();
void slotPaperSizeDelete();
- void slotOptionDoubleClicked(QListViewItem *listViewItem,const QPoint &,int);
+ void slotOptionDoubleClicked(TQListViewItem *listViewItem,const TQPoint &,int);
void slotClassOptionAdd();
void slotClassOptionEdit();
void slotClassOptionDelete();
- void slotCheckParent(QListViewItem *listViewItem);
- void slotPackageDoubleClicked(QListViewItem *listViewItem,const QPoint &,int);
+ void slotCheckParent(TQListViewItem *listViewItem);
+ void slotPackageDoubleClicked(TQListViewItem *listViewItem,const TQPoint &,int);
void slotPackageAdd();
void slotPackageAddOption();
void slotPackageEdit();
@@ -198,22 +199,23 @@ private slots:
class QuickDocumentInputDialog : public KDialogBase {
Q_OBJECT
+ TQ_OBJECT
public:
- QuickDocumentInputDialog(const QStringList &list,int check=0,
- QuickDocument *parent=0, const char *name=0);
+ QuickDocumentInputDialog(const TQStringList &list,int check=0,
+ QuickDocument *tqparent=0, const char *name=0);
~QuickDocumentInputDialog();
- void getResults(QStringList &list);
+ void getResults(TQStringList &list);
private:
QuickDocument *m_parent;
int m_check;
- QStringList m_description;
- QValueList<QWidget *> m_objectlist;
+ TQStringList m_description;
+ TQValueList<TQWidget *> m_objectlist;
- QString getPackageName(const QString &text);
- bool checkListEntries(const QString &title, const QString &textlist,const QString &pattern);
+ TQString getPackageName(const TQString &text);
+ bool checkListEntries(const TQString &title, const TQString &textlist,const TQString &pattern);
private slots:
void slotOk();
diff --git a/src/kile/quickpreview.cpp b/src/kile/quickpreview.cpp
index c851361..ae1328d 100644
--- a/src/kile/quickpreview.cpp
+++ b/src/kile/quickpreview.cpp
@@ -19,12 +19,12 @@
#include "kiledocmanager.h"
#include "kilelogwidget.h"
-#include <qtextstream.h>
-#include <qtextcodec.h>
-#include <qfile.h>
-#include <qfileinfo.h>
-#include <qdir.h>
-#include <qmap.h>
+#include <tqtextstream.h>
+#include <tqtextcodec.h>
+#include <tqfile.h>
+#include <tqfileinfo.h>
+#include <tqdir.h>
+#include <tqmap.h>
#include "kiledebug.h"
#include <ktempdir.h>
@@ -36,7 +36,7 @@
namespace KileTool
{
-QuickPreview::QuickPreview(KileInfo *ki) : m_ki(ki), m_tempfile(QString::null), m_running(0)
+QuickPreview::QuickPreview(KileInfo *ki) : m_ki(ki), m_tempfile(TQString()), m_running(0)
{
m_taskList << i18n("LaTeX ---> DVI")
<< i18n("LaTeX ---> DVI (KDVI)")
@@ -82,9 +82,9 @@ void QuickPreview::previewSelection(Kate::Document *doc, bool previewInWidgetCon
void QuickPreview::previewEnvironment(Kate::Document *doc)
{
uint row,col;
- QString envname;
- QString text = m_ki->editorExtension()->getEnvironmentText(row,col,envname);
- if ( text != QString::null )
+ TQString envname;
+ TQString text = m_ki->editorExtension()->getEnvironmentText(row,col,envname);
+ if ( text != TQString() )
{
if ( m_ki->latexCommands()->isMathModeEnv(envname) )
text = '$' + text + '$';
@@ -114,7 +114,7 @@ void QuickPreview::previewSubdocument(Kate::Document *doc)
}
// the current document should not be the master document
- QString filename = doc->url().path();
+ TQString filename = doc->url().path();
if ( filename == m_ki->getCompileName() )
{
showError( i18n("This is not a subdocument, but the master document.") );
@@ -129,8 +129,8 @@ void QuickPreview::previewSubdocument(Kate::Document *doc)
void QuickPreview::previewMathgroup(Kate::Document *doc)
{
uint row,col;
- QString text = m_ki->editorExtension()->getMathgroupText(row,col);
- if ( text != QString::null )
+ TQString text = m_ki->editorExtension()->getMathgroupText(row,col);
+ if ( text != TQString() )
{
if ( KileConfig::mathgroupPreviewInWidget() )
m_ki->previewWidget()->showActivePreview( text,m_ki->getName(doc),row,KileTool::qpMathgroup );
@@ -146,7 +146,7 @@ void QuickPreview::previewMathgroup(Kate::Document *doc)
//////////////////// run quick preview ////////////////////
-void QuickPreview::getTaskList(QStringList &tasklist)
+void QuickPreview::getTaskList(TQStringList &tasklist)
{
tasklist.clear();
tasklist << "Tool/ViewDVI/Embedded Viewer=" + m_taskList[0]
@@ -164,10 +164,10 @@ bool QuickPreview::isRunning()
return ( m_running > 0 );
}
-bool QuickPreview::run(const QString &text,const QString &textfilename,int startrow)
+bool QuickPreview::run(const TQString &text,const TQString &textfilename,int startrow)
{
// define possible tools
- QMap <QString,QString> map;
+ TQMap <TQString,TQString> map;
map[m_taskList[0]] = "PreviewLaTeX,,,ViewDVI,Embedded Viewer,dvi";
map[m_taskList[1]] = "PreviewLaTeX,,,ViewDVI,KDVI Unique,dvi";
map[m_taskList[2]] = "PreviewLaTeX,DVItoPS,Default,ViewPS,Embedded Viewer,ps";
@@ -176,17 +176,17 @@ bool QuickPreview::run(const QString &text,const QString &textfilename,int start
map[m_taskList[5]] = "PreviewPDFLaTeX,,,ViewPDF,KGhostView,pdf";
map[m_taskList[6]] = "PreviewPDFLaTeX,,,ViewPDF,KPDF,pdf";
- QString previewtask = KileConfig::previewTask();
- if ( ! map.contains(previewtask) )
+ TQString previewtask = KileConfig::previewTask();
+ if ( ! map.tqcontains(previewtask) )
{
- showError(QString(i18n("Could not run QuickPreview:\nunknown task '%1'").arg(previewtask)));
+ showError(TQString(i18n("Could not run QuickPreview:\nunknown task '%1'").tqarg(previewtask)));
return false;
}
return run (text, textfilename, startrow, map[previewtask]);
}
-bool QuickPreview::run(const QString &text,const QString &textfilename,int startrow,const QString &spreviewlist)
+bool QuickPreview::run(const TQString &text,const TQString &textfilename,int startrow,const TQString &spreviewlist)
{
KILE_DEBUG() << "==QuickPreview::run()==========================" << endl;
m_ki->logWidget()->clear();
@@ -206,7 +206,7 @@ bool QuickPreview::run(const QString &text,const QString &textfilename,int start
// create the name of a temporary file or delete already existing temporary files
if ( m_tempfile.isEmpty() )
{
- m_tempfile = KTempDir(QString::null).name() + "preview.tex";
+ m_tempfile = KTempDir(TQString()).name() + "preview.tex";
KILE_DEBUG() << "\tdefine tempfile: " << m_tempfile << endl;
}
else
@@ -219,26 +219,26 @@ bool QuickPreview::run(const QString &text,const QString &textfilename,int start
if ( preamblelines == 0 )
return false;
- QStringList previewlist = QStringList::split(",",spreviewlist,true);
+ TQStringList previewlist = TQStringList::split(",",spreviewlist,true);
// create preview tools
KILE_DEBUG() << "\tcreate latex tool for QuickPreview: " << previewlist[pvLatex] << endl;
KileTool::PreviewLaTeX *latex = (KileTool::PreviewLaTeX *)m_ki->toolFactory()->create(previewlist[pvLatex],false);
if ( !latex )
{
- showError(QString(i18n("Could not run '%1' for QuickPreview.").arg("LaTeX")));
+ showError(TQString(i18n("Could not run '%1' for QuickPreview.").tqarg("LaTeX")));
return false;
}
KileTool::Base *dvips = 0L;
if ( ! previewlist[1].isEmpty() )
{
- QString dvipstool = previewlist[pvDvips] + " (" + previewlist[pvDvipsCfg] + ')';
+ TQString dvipstool = previewlist[pvDvips] + " (" + previewlist[pvDvipsCfg] + ')';
KILE_DEBUG() << "\tcreate dvips tool for QuickPreview: " << previewlist[pvDvips] << endl;
dvips = m_ki->toolFactory()->create(previewlist[pvDvips]);
if ( !dvips )
{
- showError(QString(i18n("Could not run '%1' for QuickPreview.").arg(dvipstool)));
+ showError(TQString(i18n("Could not run '%1' for QuickPreview.").tqarg(dvipstool)));
return false;
}
}
@@ -246,26 +246,26 @@ bool QuickPreview::run(const QString &text,const QString &textfilename,int start
KileTool::Base *viewer = 0L;
if ( !previewlist[pvViewer].isEmpty() )
{
- QString viewertool = previewlist[pvViewer] + " (" + previewlist[pvViewerCfg] + ')';
+ TQString viewertool = previewlist[pvViewer] + " (" + previewlist[pvViewerCfg] + ')';
KILE_DEBUG() << "\tcreate viewer for QuickPreview: " << viewertool << endl;
viewer = m_ki->toolFactory()->create(previewlist[pvViewer],false);
if ( !viewer )
{
- showError(QString(i18n("Could not run '%1' for QuickPreview.").arg(viewertool)));
+ showError(TQString(i18n("Could not run '%1' for QuickPreview.").tqarg(viewertool)));
return false;
}
}
// set value of texinput path (only for QuickPreview tools)
- QString texinputpath = KileConfig::teXPaths();
- QString inputdir = QFileInfo(m_ki->getCompileName()).dirPath(true);
+ TQString texinputpath = KileConfig::teXPaths();
+ TQString inputdir = TQFileInfo(m_ki->getCompileName()).dirPath(true);
if ( ! texinputpath.isEmpty() )
inputdir += ':' + texinputpath;
KileConfig::setPreviewTeXPaths(inputdir);
KILE_DEBUG() << "\tQuickPreview: inputdir is '" << inputdir << "'" << endl;
// prepare tools: previewlatex
- QString filepath = m_tempfile.left( m_tempfile.length()-3 );
+ TQString filepath = m_tempfile.left( m_tempfile.length()-3 );
latex->setPreviewInfo(textfilename,startrow,preamblelines+1);
latex->setSource(m_tempfile);
latex->prepareToRun();
@@ -273,7 +273,7 @@ bool QuickPreview::run(const QString &text,const QString &textfilename,int start
if ( m_ki->toolManager()->run(latex) != KileTool::Running )
return false;
- connect(latex, SIGNAL(destroyed()), this, SLOT(toolDestroyed()));
+ connect(latex, TQT_SIGNAL(destroyed()), this, TQT_SLOT(toolDestroyed()));
m_running++;
// dvips
@@ -284,14 +284,14 @@ bool QuickPreview::run(const QString &text,const QString &textfilename,int start
if ( m_ki->toolManager()->run(dvips,previewlist[pvDvipsCfg]) != KileTool::Running )
return false;
- connect(dvips, SIGNAL(destroyed()), this, SLOT(toolDestroyed()));
+ connect(dvips, TQT_SIGNAL(destroyed()), this, TQT_SLOT(toolDestroyed()));
m_running++;
}
// viewer
if ( viewer )
{
- connect(viewer, SIGNAL(destroyed()), this, SLOT(toolDestroyed()));
+ connect(viewer, TQT_SIGNAL(destroyed()), this, TQT_SLOT(toolDestroyed()));
viewer->setSource( filepath + previewlist[pvExtension] );
viewer->setQuickie();
if ( m_ki->toolManager()->run(viewer,previewlist[pvViewerCfg]) != KileTool::Running )
@@ -308,21 +308,21 @@ void QuickPreview::toolDestroyed()
m_running--;
}
-QString QuickPreview::getPreviewFile(const QString &extension)
+TQString QuickPreview::getPreviewFile(const TQString &extension)
{
if (m_tempfile.length () < 3)
- return QString::null;
+ return TQString();
- QString filepath = m_tempfile.left(m_tempfile.length () - 3);
+ TQString filepath = m_tempfile.left(m_tempfile.length () - 3);
return filepath + extension;
}
//////////////////// tempfile ////////////////////
-int QuickPreview::createTempfile(const QString &text)
+int QuickPreview::createTempfile(const TQString &text)
{
// determine main document to read the preamble
- QString filename = m_ki->getCompileName();
+ TQString filename = m_ki->getCompileName();
if ( filename.isEmpty() )
{
showError(i18n("Could not determine the main document."));
@@ -330,7 +330,7 @@ int QuickPreview::createTempfile(const QString &text)
}
// open to read
- QFile fin( filename );
+ TQFile fin( filename );
if ( !fin.exists() || !fin.open(IO_ReadOnly) )
{
showError(i18n("Could not read the preamble."));
@@ -339,32 +339,32 @@ int QuickPreview::createTempfile(const QString &text)
KILE_DEBUG() << "\tcreate a temporary file: " << m_tempfile << endl;
// use a textstream
- QTextStream preamble(&fin);
+ TQTextStream preamble(&fin);
// create the temporary file
- QFile tempfile(m_tempfile);
+ TQFile tempfile(m_tempfile);
if ( ! tempfile.open( IO_WriteOnly ) )
{
showError(i18n("Could not create a temporary file."));
return 0;
}
- QTextStream stream( &tempfile );
+ TQTextStream stream( &tempfile );
// set the encoding according to the original file (tbraun)
if(m_ki->activeTextDocument())
{
- QTextCodec *codec = QTextCodec::codecForName(m_ki->activeTextDocument()->encoding().ascii());
+ TQTextCodec *codec = TQTextCodec::codecForName(m_ki->activeTextDocument()->encoding().ascii());
if ( codec )
stream.setCodec(codec);
}
// write the whole preamble into this temporary file
- QString textline;
+ TQString textline;
int preamblelines = 0;
bool begindocumentFound = false;
while ( ! preamble.eof() )
{
textline = preamble.readLine();
- if ( textline.find("\\begin{document}") >= 0 )
+ if ( textline.tqfind("\\begin{document}") >= 0 )
{
begindocumentFound = true;
break;
@@ -396,16 +396,16 @@ void QuickPreview::removeTempFiles(bool rmdir)
if ( m_tempfile.isEmpty() )
return;
- QFileInfo fi(m_tempfile);
- QString tempdir = fi.dirPath(true) + '/';
+ TQFileInfo fi(m_tempfile);
+ TQString tempdir = fi.dirPath(true) + '/';
- QDir dir = fi.dir(true);
+ TQDir dir = fi.dir(true);
if ( dir.exists() )
{
- QStringList list = dir.entryList(fi.baseName()+".*");
- for ( QStringList::Iterator it=list.begin(); it!=list.end(); ++it )
+ TQStringList list = dir.entryList(fi.baseName()+".*");
+ for ( TQStringList::Iterator it=list.begin(); it!=list.end(); ++it )
{
- QFile::remove( tempdir + (*it) );
+ TQFile::remove( tempdir + (*it) );
// KILE_DEBUG() << "\tremove temporary file: " << tempdir + (*it) << endl;
}
@@ -416,7 +416,7 @@ void QuickPreview::removeTempFiles(bool rmdir)
//////////////////// error messages ////////////////////
-void QuickPreview::showError(const QString &text)
+void QuickPreview::showError(const TQString &text)
{
m_ki->logWidget()->printMsg( KileTool::Error, text, i18n("QuickPreview") );
}
diff --git a/src/kile/quickpreview.h b/src/kile/quickpreview.h
index eb4172b..222ade1 100644
--- a/src/kile/quickpreview.h
+++ b/src/kile/quickpreview.h
@@ -14,31 +14,32 @@
* *
***************************************************************************/
-#ifndef QUICKPREVIEW_H
-#define QUICKPREVIEW_H
+#ifndef TQUICKPREVIEW_H
+#define TQUICKPREVIEW_H
#include "kileinfo.h"
#include "kiletool.h"
#include "kileedit.h"
#include "previewwidget.h"
-#include <qobject.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
namespace KileTool
{
enum { qpSelection=0, qpEnvironment, qpSubdocument, qpMathgroup };
-class QuickPreview : public QObject
+class QuickPreview : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
QuickPreview(KileInfo *ki);
~QuickPreview();
- bool run(const QString &text,const QString &textfilename,int startrow);
+ bool run(const TQString &text,const TQString &textfilename,int startrow);
bool isRunning();
void previewEnvironment(Kate::Document *doc);
@@ -61,8 +62,8 @@ public:
* @param spreviewlist user defined configuration, e.g. "PreviewLaTeX,DVItoPS,,,ps" (with no preview)
* @return true if method succeeds, else false
*/
- bool run (const QString &text, const QString &textfilename, int startrow, const QString &spreviewlist);
- void getTaskList(QStringList &tasklist);
+ bool run (const TQString &text, const TQString &textfilename, int startrow, const TQString &spreviewlist);
+ void getTaskList(TQStringList &tasklist);
/**
* QuickPreview uses temporary files for processing the output.
@@ -75,7 +76,7 @@ public:
* @param extension defines which file to use
* @return The temporary file with extension
*/
- QString getPreviewFile(const QString &extension);
+ TQString getPreviewFile(const TQString &extension);
private slots:
void toolDestroyed();
@@ -84,13 +85,13 @@ private:
enum { pvLatex=0, pvDvips=1, pvDvipsCfg=2, pvViewer=3, pvViewerCfg=4, pvExtension=5 };
KileInfo *m_ki;
- QString m_tempfile;
- QStringList m_taskList;
+ TQString m_tempfile;
+ TQStringList m_taskList;
int m_running;
- int createTempfile(const QString &text);
+ int createTempfile(const TQString &text);
void removeTempFiles(bool rmdir=false);
- void showError(const QString &text);
+ void showError(const TQString &text);
};
}
diff --git a/src/kile/quicktoolconfigwidget.ui b/src/kile/quicktoolconfigwidget.ui
index 85b1ee3..d5c4a07 100644
--- a/src/kile/quicktoolconfigwidget.ui
+++ b/src/kile/quicktoolconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>QuickToolConfigWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>QuickToolConfigWidget</cstring>
</property>
@@ -36,14 +36,14 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>100</width>
<height>0</height>
</size>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbTool</cstring>
</property>
@@ -51,7 +51,7 @@
<string>Tool:</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="3">
+ <widget class="TQLabel" row="0" column="3">
<property name="name">
<cstring>m_lbConfig</cstring>
</property>
@@ -71,7 +71,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>150</width>
<height>0</height>
@@ -152,7 +152,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>16</height>
@@ -195,24 +195,24 @@
<includes>
<include location="global" impldecl="in implementation">klocale.h</include>
<include location="local" impldecl="in implementation">kiletoolmanager.h</include>
- <include location="global" impldecl="in implementation">qstring.h</include>
+ <include location="global" impldecl="in implementation">tqstring.h</include>
<include location="global" impldecl="in implementation">kglobal.h</include>
- <include location="local" impldecl="in implementation">quicktoolconfigwidget.ui.h</include>
+ <include location="local" impldecl="in implementation">tquicktoolconfigwidget.ui.h</include>
</includes>
<variables>
- <variable access="private">QString m_sequence;</variable>
+ <variable access="private">TQString m_sequence;</variable>
</variables>
-<signals>
- <signal>sequenceChanged(const QString &amp;)</signal>
-</signals>
-<slots>
- <slot>updateSequence( const QString &amp; sequence )</slot>
- <slot>updateConfigs( const QString &amp; tool )</slot>
+<Q_SIGNALS>
+ <signal>sequenceChanged(const TQString &amp;)</signal>
+</Q_SIGNALS>
+<Q_SLOTS>
+ <slot>updateSequence( const TQString &amp; sequence )</slot>
+ <slot>updateConfigs( const TQString &amp; tool )</slot>
<slot access="private" specifier="non virtual">down()</slot>
<slot access="private" specifier="non virtual">up()</slot>
<slot access="private" specifier="non virtual">remove()</slot>
<slot access="private" specifier="non virtual">add()</slot>
<slot access="private" specifier="non virtual">changed()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/src/kile/quicktoolconfigwidget.ui.h b/src/kile/quicktoolconfigwidget.ui.h
index 0b6ff9d..4194528 100644
--- a/src/kile/quicktoolconfigwidget.ui.h
+++ b/src/kile/quicktoolconfigwidget.ui.h
@@ -2,24 +2,24 @@
** ui.h extension file, included from the uic-generated form implementation.
**
** If you wish to add, delete or rename functions or slots use
-** Qt Designer which will update this file, preserving your code. Create an
+** TQt Designer which will update this file, preserving your code. Create an
** init() function in place of a constructor, and a destroy() function in
** place of a destructor.
*****************************************************************************/
-void QuickToolConfigWidget::updateSequence(const QString &sequence)
+void QuickToolConfigWidget::updateSequence(const TQString &sequence)
{
- QStringList toollist = KileTool::toolList(KGlobal::config(), true);
+ TQStringList toollist = KileTool::toolList(KGlobal::config(), true);
toollist.sort();
m_cbTools->clear();
m_cbTools->insertStringList(toollist);
updateConfigs(m_cbTools->currentText());
- connect(m_cbTools, SIGNAL(activated(const QString &)), this, SLOT(updateConfigs(const QString& )));
+ connect(m_cbTools, TQT_SIGNAL(activated(const TQString &)), this, TQT_SLOT(updateConfigs(const TQString& )));
m_sequence=sequence;
- QStringList list = QStringList::split(",",sequence);
- QString tl,cfg;
+ TQStringList list = TQStringList::split(",",sequence);
+ TQString tl,cfg;
m_lstbSeq->clear();
for ( uint i=0; i < list.count(); ++i)
{
@@ -31,7 +31,7 @@ void QuickToolConfigWidget::updateSequence(const QString &sequence)
}
}
-void QuickToolConfigWidget::updateConfigs(const QString &tool)
+void QuickToolConfigWidget::updateConfigs(const TQString &tool)
{
m_cbConfigs->clear();
m_cbConfigs->insertItem(i18n("Not Specified"));
@@ -43,7 +43,7 @@ void QuickToolConfigWidget::down()
int current = m_lstbSeq->currentItem();
if ( (current != -1) && (current < ( ((int)m_lstbSeq->count())-1) ))
{
- QString text = m_lstbSeq->text(current+1);
+ TQString text = m_lstbSeq->text(current+1);
m_lstbSeq->changeItem(m_lstbSeq->text(current), current+1);
m_lstbSeq->changeItem(text, current);
m_lstbSeq->setCurrentItem(current+1);
@@ -56,7 +56,7 @@ void QuickToolConfigWidget::up()
int current = m_lstbSeq->currentItem();
if ( (current != -1) && (current > 0) )
{
- QString text = m_lstbSeq->text(current-1);
+ TQString text = m_lstbSeq->text(current-1);
m_lstbSeq->changeItem(m_lstbSeq->text(current), current-1);
m_lstbSeq->changeItem(text, current);
m_lstbSeq->setCurrentItem(current-1);
@@ -76,7 +76,7 @@ void QuickToolConfigWidget::remove()
void QuickToolConfigWidget::add()
{
- QString entry = m_cbTools->currentText();
+ TQString entry = m_cbTools->currentText();
if ( m_cbConfigs->currentText() != i18n("Not Specified") )
entry += " (" + m_cbConfigs->currentText() + ")";
m_lstbSeq->insertItem(entry);
@@ -86,7 +86,7 @@ void QuickToolConfigWidget::add()
void QuickToolConfigWidget::changed()
{
- QString sequence, tool, cfg;
+ TQString sequence, tool, cfg;
for (uint i = 0; i < m_lstbSeq->count(); ++i)
{
KileTool::extract(m_lstbSeq->text(i), tool, cfg);
diff --git a/src/kile/scriptingconfigwidget.ui b/src/kile/scriptingconfigwidget.ui
index 3ab3fe3..d18a8fb 100644
--- a/src/kile/scriptingconfigwidget.ui
+++ b/src/kile/scriptingconfigwidget.ui
@@ -1,7 +1,7 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetScriptingConfig</class>
<author>Michel Ludwig (michel.ludwig@kdemail.net)</author>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetScriptingConfig</cstring>
</property>
@@ -28,7 +28,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_ScriptingEnabled</cstring>
</property>
@@ -47,7 +47,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>executionTimeLimitGroupBox</cstring>
</property>
@@ -69,7 +69,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_TimeLimitEnabled</cstring>
</property>
@@ -88,15 +88,15 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout10</cstring>
+ <cstring>tqlayout10</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -125,7 +125,7 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>16</width>
<height>20</height>
@@ -158,7 +158,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>40</width>
<height>20</height>
@@ -179,7 +179,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>40</height>
@@ -211,7 +211,7 @@
<includes>
<include location="local" impldecl="in implementation">scriptingconfigwidget.ui.h</include>
</includes>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>knuminput.h</includehint>
<includehint>knuminput.h</includehint>
diff --git a/src/kile/scriptsmanagementwidget.cpp b/src/kile/scriptsmanagementwidget.cpp
index 9360f38..588f86a 100644
--- a/src/kile/scriptsmanagementwidget.cpp
+++ b/src/kile/scriptsmanagementwidget.cpp
@@ -13,9 +13,9 @@
#include "scriptsmanagementwidget.h"
-#include <qlayout.h>
-#include <qtooltip.h>
-#include <qvbox.h>
+#include <tqlayout.h>
+#include <tqtooltip.h>
+#include <tqvbox.h>
#include <kiconloader.h>
#include <kinputdialog.h>
@@ -29,7 +29,7 @@
namespace KileWidget {
-JScriptListViewItem::JScriptListViewItem(QWidget *managementWidget, KListView *parent, KileJScript::JScript *script, KileInfo *kileInfo) : KListViewItem(parent), m_script(script), m_kileInfo(kileInfo), m_managementWidget(managementWidget) {
+JScriptListViewItem::JScriptListViewItem(TQWidget *managementWidget, KListView *tqparent, KileJScript::JScript *script, KileInfo *kileInfo) : KListViewItem(tqparent), m_script(script), m_kileInfo(kileInfo), m_managementWidget(managementWidget) {
}
JScriptListViewItem::~JScriptListViewItem() {
@@ -39,65 +39,65 @@ KileJScript::JScript* JScriptListViewItem::getScript() {
return m_script;
}
-QString JScriptListViewItem::text(int column) const {
+TQString JScriptListViewItem::text(int column) const {
switch(column) {
case 0:
return m_script->getName();
case 1:
return m_script->getKeySequence();
}
- return QString();
+ return TQString();
}
-void JScriptListViewItem::setText(int column, const QString & str) {
+void JScriptListViewItem::setText(int column, const TQString & str) {
if(column == 1) {
- QString oldAssignedString = m_script->getKeySequence();
+ TQString oldAssignedString = m_script->getKeySequence();
if(str.isEmpty()) {
// don't reload the list view here as this may cause a segfault (for example on x86_64)
- QObject::disconnect(m_kileInfo->editorKeySequenceManager(), SIGNAL(watchedKeySequencesChanged()), m_managementWidget, SLOT(updateListView()));
+ TQObject::disconnect(m_kileInfo->editorKeySequenceManager(), TQT_SIGNAL(watchedKeySequencesChanged()), m_managementWidget, TQT_SLOT(updateListView()));
m_kileInfo->scriptManager()->removeEditorKeySequence(m_script);
- QObject::connect(m_kileInfo->editorKeySequenceManager(), SIGNAL(watchedKeySequencesChanged()), m_managementWidget, SLOT(updateListView()));
+ TQObject::connect(m_kileInfo->editorKeySequenceManager(), TQT_SIGNAL(watchedKeySequencesChanged()), m_managementWidget, TQT_SLOT(updateListView()));
}
else if(str == oldAssignedString || (str.isEmpty() && oldAssignedString.isEmpty())) {
return;
}
else {
- QPair<int, QString> pair = m_kileInfo->editorKeySequenceManager()->checkSequence(str, oldAssignedString);
+ TQPair<int, TQString> pair = m_kileInfo->editorKeySequenceManager()->checkSequence(str, oldAssignedString);
if(pair.first == 0) {
// don't reload the list view here as this may cause a segfault (for example on x86_64)
- QObject::disconnect(m_kileInfo->editorKeySequenceManager(), SIGNAL(watchedKeySequencesChanged()), m_managementWidget, SLOT(updateListView()));
+ TQObject::disconnect(m_kileInfo->editorKeySequenceManager(), TQT_SIGNAL(watchedKeySequencesChanged()), m_managementWidget, TQT_SLOT(updateListView()));
m_kileInfo->scriptManager()->setEditorKeySequence(m_script, str);
- QObject::connect(m_kileInfo->editorKeySequenceManager(), SIGNAL(watchedKeySequencesChanged()), m_managementWidget, SLOT(updateListView()));
+ TQObject::connect(m_kileInfo->editorKeySequenceManager(), TQT_SIGNAL(watchedKeySequencesChanged()), m_managementWidget, TQT_SLOT(updateListView()));
return; // leaving !
}
KileEditorKeySequence::Action *action = m_kileInfo->editorKeySequenceManager()->getAction(pair.second);
- QString description = (action == 0L) ? QString() : action->getDescription();
+ TQString description = (action == 0L) ? TQString() : action->getDescription();
switch(pair.first) {
case 1:
- KMessageBox::sorry(0L, i18n("The sequence \"%1\" is already assigned to the action \"%2\"").arg(str).arg(description), i18n("Sequence Already Assigned"));
+ KMessageBox::sorry(0L, i18n("The sequence \"%1\" is already assigned to the action \"%2\"").tqarg(str).tqarg(description), i18n("Sequence Already Assigned"));
break;
case 2:
- KMessageBox::sorry(0L, i18n("The sequence \"%1\" is a subsequence of \"%2\", which is already assigned to the action \"%3\"").arg(str).arg(pair.second).arg(description), i18n("Sequence Already Assigned"));
+ KMessageBox::sorry(0L, i18n("The sequence \"%1\" is a subsequence of \"%2\", which is already assigned to the action \"%3\"").tqarg(str).tqarg(pair.second).tqarg(description), i18n("Sequence Already Assigned"));
break;
case 3:
- KMessageBox::sorry(0L, i18n("The shorter sequence \"%1\" is already assigned to the action \"%2\"").arg(pair.second).arg(description), i18n("Sequence Already Assigned"));
+ KMessageBox::sorry(0L, i18n("The shorter sequence \"%1\" is already assigned to the action \"%2\"").tqarg(pair.second).tqarg(description), i18n("Sequence Already Assigned"));
break;
}
}
}
}
-ScriptsManagement::ScriptsManagement(KileInfo *kileInfo, QWidget *parent, const char *name, WFlags f) : QWidget(parent, name, f), m_kileInfo(kileInfo) {
- QVBoxLayout *baseLayout = new QVBoxLayout(this);
+ScriptsManagement::ScriptsManagement(KileInfo *kileInfo, TQWidget *tqparent, const char *name, WFlags f) : TQWidget(tqparent, name, f), m_kileInfo(kileInfo) {
+ TQVBoxLayout *baseLayout = new TQVBoxLayout(this);
m_toolbar = new KToolBar(this, "scriptControlToolBar");
- m_executeButton = m_toolbar->insertButton(BarIcon("exec"), 0, SIGNAL(clicked(int)), this, SLOT(executeSelectedScript()), true, i18n("Run Selected Script"));
- m_newButton = m_toolbar->insertButton(BarIcon("scriptnew"), 0, SIGNAL(clicked(int)), m_kileInfo->docManager(), SLOT(createNewJScript()), true, i18n("Create New Script"));
- m_openButton = m_toolbar->insertButton(BarIcon("scriptopen"), 0, SIGNAL(clicked(int)), this, SLOT(openSelectedScript()), true, i18n("Open Selected Script in Editor"));
-// m_toolbar->insertButton(BarIcon("configure_shortcuts"), 0, SIGNAL(clicked(int)), this, SLOT(configureSelectedShortcut()), true, i18n("Configure Shortcut"));
-// m_toolbar->insertButton(BarIcon("editclear"), 1, SIGNAL(clicked(int)), m_kileInfo->scriptManager(), SLOT(scanJScriptDirectories()), true, i18n("Refresh"));
- m_refreshButton = m_toolbar->insertButton(BarIcon("reload"), 1, SIGNAL(clicked(int)), m_kileInfo->scriptManager(), SLOT(scanJScriptDirectories()), true, i18n("Refresh List"));
+ m_executeButton = m_toolbar->insertButton(BarIcon("exec"), 0, TQT_SIGNAL(clicked(int)), TQT_TQOBJECT(this), TQT_SLOT(executeSelectedScript()), true, i18n("Run Selected Script"));
+ m_newButton = m_toolbar->insertButton(BarIcon("scriptnew"), 0, TQT_SIGNAL(clicked(int)), m_kileInfo->docManager(), TQT_SLOT(createNewJScript()), true, i18n("Create New Script"));
+ m_openButton = m_toolbar->insertButton(BarIcon("scriptopen"), 0, TQT_SIGNAL(clicked(int)), TQT_TQOBJECT(this), TQT_SLOT(openSelectedScript()), true, i18n("Open Selected Script in Editor"));
+// m_toolbar->insertButton(BarIcon("configure_shortcuts"), 0, TQT_SIGNAL(clicked(int)), TQT_TQOBJECT(this), TQT_SLOT(configureSelectedShortcut()), true, i18n("Configure Shortcut"));
+// m_toolbar->insertButton(BarIcon("editclear"), 1, TQT_SIGNAL(clicked(int)), m_kileInfo->scriptManager(), TQT_SLOT(scanJScriptDirectories()), true, i18n("Refresh"));
+ m_refreshButton = m_toolbar->insertButton(BarIcon("reload"), 1, TQT_SIGNAL(clicked(int)), m_kileInfo->scriptManager(), TQT_SLOT(scanJScriptDirectories()), true, i18n("Refresh List"));
baseLayout->addWidget(m_toolbar);
m_scriptsListView = new KListView(this);
@@ -108,11 +108,11 @@ ScriptsManagement::ScriptsManagement(KileInfo *kileInfo, QWidget *parent, const
m_scriptsListView->setRenameable(0, false);
m_scriptsListView->setRenameable(1, true);
- connect(m_kileInfo->scriptManager(), SIGNAL(jScriptsChanged()), this, SLOT(updateListView()));
- connect(m_kileInfo->editorKeySequenceManager(), SIGNAL(watchedKeySequencesChanged()), this, SLOT(updateListView()));
-// connect(m_scriptsListView, SIGNAL(doubleClicked(QListViewItem*, const QPoint&, int)), this, SLOT(executed(QListViewItem*, const QPoint&, int)));
-// connect(m_scriptsListView, SIGNAL(itemRenamed(QListViewItem*, const QString&, int)), this, SLOT(itemRenamed(QListViewItem*, const QString&, int)));
- connect(m_scriptsListView, SIGNAL(selectionChanged()), this, SLOT(updateButtonPanel()));
+ connect(m_kileInfo->scriptManager(), TQT_SIGNAL(jScriptsChanged()), TQT_TQOBJECT(this), TQT_SLOT(updateListView()));
+ connect(m_kileInfo->editorKeySequenceManager(), TQT_SIGNAL(watchedKeySequencesChanged()), TQT_TQOBJECT(this), TQT_SLOT(updateListView()));
+// connect(m_scriptsListView, TQT_SIGNAL(doubleClicked(TQListViewItem*, const TQPoint&, int)), TQT_TQOBJECT(this), TQT_SLOT(executed(TQListViewItem*, const TQPoint&, int)));
+// connect(m_scriptsListView, TQT_SIGNAL(itemRenamed(TQListViewItem*, const TQString&, int)), TQT_TQOBJECT(this), TQT_SLOT(itemRenamed(TQListViewItem*, const TQString&, int)));
+ connect(m_scriptsListView, TQT_SIGNAL(selectionChanged()), TQT_TQOBJECT(this), TQT_SLOT(updateButtonPanel()));
baseLayout->addWidget(m_scriptsListView);
updateButtonPanel();
@@ -125,15 +125,15 @@ ScriptsManagement::~ScriptsManagement() {
void ScriptsManagement::updateListView() {
m_scriptsListView->clear();
- const QValueList<KileJScript::JScript*>& scriptList = m_kileInfo->scriptManager()->getJScripts();
- for(QValueList<KileJScript::JScript*>::const_iterator i = scriptList.begin(); i != scriptList.end(); ++i) {
+ const TQValueList<KileJScript::JScript*>& scriptList = m_kileInfo->scriptManager()->getJScripts();
+ for(TQValueList<KileJScript::JScript*>::const_iterator i = scriptList.begin(); i != scriptList.end(); ++i) {
new JScriptListViewItem(this, m_scriptsListView, *i, m_kileInfo);
}
m_scriptsListView->triggerUpdate();
}
void ScriptsManagement::openSelectedScript() {
- QListViewItem *item = m_scriptsListView->selectedItem();
+ TQListViewItem *item = m_scriptsListView->selectedItem();
if(!item) {
return;
}
@@ -142,7 +142,7 @@ void ScriptsManagement::openSelectedScript() {
}
void ScriptsManagement::executeSelectedScript() {
- QListViewItem *item = m_scriptsListView->selectedItem();
+ TQListViewItem *item = m_scriptsListView->selectedItem();
if(!item) {
return;
}
@@ -151,12 +151,12 @@ void ScriptsManagement::executeSelectedScript() {
}
// void ScriptsManagement::configureSelectedShortcut() {
-// QListViewItem *item = m_scriptsListView->selectedItem();
+// TQListViewItem *item = m_scriptsListView->selectedItem();
// if(!item) {
// return;
// }
// JScriptListViewItem *jItem = (JScriptListViewItem*)item;
-// QString sequence = determineKeySequence();
+// TQString sequence = determineKeySequence();
// m_kileInfo->scriptManager()->setEditorKeySequence(jItem->getScript(), sequence);
// }
diff --git a/src/kile/scriptsmanagementwidget.h b/src/kile/scriptsmanagementwidget.h
index d8bc657..b90e86c 100644
--- a/src/kile/scriptsmanagementwidget.h
+++ b/src/kile/scriptsmanagementwidget.h
@@ -14,8 +14,8 @@
#ifndef SCRIPTSMANAGEMENTWIDGET_H
#define SCRIPTSMANAGEMENTWIDGET_H
-#include <qtoolbutton.h>
-#include <qwidget.h>
+#include <tqtoolbutton.h>
+#include <tqwidget.h>
#include <klistview.h>
#include <ktoolbar.h>
@@ -38,27 +38,28 @@ namespace KileWidget {
**/
class JScriptListViewItem : public KListViewItem {
public:
- JScriptListViewItem(QWidget *managementWidget, KListView *parent, KileJScript::JScript *script, KileInfo *kileInfo);
+ JScriptListViewItem(TQWidget *managementWidget, KListView *tqparent, KileJScript::JScript *script, KileInfo *kileInfo);
virtual ~JScriptListViewItem();
KileJScript::JScript* getScript();
- virtual void setText(int column, const QString & text);
- virtual QString text(int column) const;
+ virtual void setText(int column, const TQString & text);
+ virtual TQString text(int column) const;
protected:
KileJScript::JScript *m_script;
KileInfo *m_kileInfo;
- QWidget *m_managementWidget;
+ TQWidget *m_managementWidget;
};
/**
* This widget is used to handle Kile's scripting functionality.
**/
- class ScriptsManagement : public QWidget {
+ class ScriptsManagement : public TQWidget {
Q_OBJECT
+ TQ_OBJECT
public:
- ScriptsManagement(KileInfo *kileInfo, QWidget *parent = 0, const char *name = 0, WFlags f = 0);
+ ScriptsManagement(KileInfo *kileInfo, TQWidget *tqparent = 0, const char *name = 0, WFlags f = 0);
~ScriptsManagement();
// signals:
diff --git a/src/kile/structureconfigwidget.ui b/src/kile/structureconfigwidget.ui
index 5f39dca..bcad803 100644
--- a/src/kile/structureconfigwidget.ui
+++ b/src/kile/structureconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetStructureViewConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetStructureViewConfig</cstring>
</property>
@@ -20,7 +20,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox2</cstring>
</property>
@@ -63,7 +63,7 @@
<number>7</number>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel2</cstring>
</property>
@@ -87,7 +87,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>200</width>
<height>20</height>
@@ -104,14 +104,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>60</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QLabel" row="1" column="0" rowspan="1" colspan="4">
+ <widget class="TQLabel" row="1" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>textLabel2_2</cstring>
</property>
@@ -127,14 +127,14 @@
</widget>
</grid>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox4</cstring>
</property>
<property name="title">
<string>Options</string>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowLabels</cstring>
</property>
@@ -150,7 +150,7 @@
<string>Show &amp;labels</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowReferences</cstring>
</property>
@@ -166,7 +166,7 @@
<string>Show undefined references</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowSectioningLabels</cstring>
</property>
@@ -185,7 +185,7 @@
<string></string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowInputFiles</cstring>
</property>
@@ -204,7 +204,7 @@
<string></string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowGraphics</cstring>
</property>
@@ -220,7 +220,7 @@
<string>Show graphic files</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowBibitems</cstring>
</property>
@@ -236,7 +236,7 @@
<string>Show bibitems</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowTodo</cstring>
</property>
@@ -252,7 +252,7 @@
<string>Show TODO/FIXME</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvOpenTodo</cstring>
</property>
@@ -268,7 +268,7 @@
<string>Open TODO/FIXME</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvOpenBibitems</cstring>
</property>
@@ -284,7 +284,7 @@
<string>Open bibitems item</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvOpenReferences</cstring>
</property>
@@ -300,7 +300,7 @@
<string>Open references item</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvOpenLabels</cstring>
</property>
@@ -316,7 +316,7 @@
<string>&amp;Open labels item</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>kcfg_SvShowFloats</cstring>
</property>
@@ -337,7 +337,7 @@
</widget>
<customwidgets>
</customwidgets>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>knuminput.h</includehint>
<includehint>knuminput.h</includehint>
diff --git a/src/kile/symbols/Makefile.am b/src/kile/symbols/Makefile.am
index c10322a..3cd27f1 100644
--- a/src/kile/symbols/Makefile.am
+++ b/src/kile/symbols/Makefile.am
@@ -1,6 +1,6 @@
INCLUDES = $(all_includes)
-gesymb_LDFLAGS = $(all_libraries) $(KDE_RPATH) -lqt-mt
+gesymb_LDFLAGS = $(all_libraries) $(KDE_RPATH) $(LIB_QT)
noinst_PROGRAMS = gesymb
gesymb_SOURCES = gesymb.cpp gesymb.h
diff --git a/src/kile/symbols/gesymb.cpp b/src/kile/symbols/gesymb.cpp
index 3305494..4254145 100644
--- a/src/kile/symbols/gesymb.cpp
+++ b/src/kile/symbols/gesymb.cpp
@@ -22,8 +22,8 @@ int main( int argc, char ** argv )
{
int latexret=-1;
int dvipngret=-1;
-QString texcommand, texfile,type,dvipngcommand,line;
-QString pkgs,pkgsarg,savepkgs="",savepkgsarg="";
+TQString texcommand, texfile,type,dvipngcommand,line;
+TQString pkgs,pkgsarg,savepkgs="",savepkgsarg="";
bool env=false;
@@ -34,7 +34,7 @@ if (argc < 2)
texfile=argv[2];
type=argv[1];
-QFile f( texfile );
+TQFile f( texfile );
if ( !f.open( IO_ReadOnly ) )
{
cout << "File " << texfile.latin1() << " is not readable\n";
@@ -61,14 +61,14 @@ if(dvipngret)
return 1;
}
-QTextStream t(&f);
+TQTextStream t(&f);
-QRegExp optarg("\\\\(?:math)?command\\[(.*)\\]\\{");
-QRegExp arg("\\\\(?:math)?command\\{(.*)\\}");
-QRegExp beginenvpkgs("^\\\\begin\\{neededpkgs\\}(?:\\[(.*)\\])?\\{(.*)\\}");
-QRegExp endenvpkgs("^\\\\end\\{neededpkgs\\}");
-QRegExp cmdpkgs("\\\\pkgs(?:\\[(.*)\\])?\\{(.*)\\}");
-QRegExp comment("^\\s*%");
+TQRegExp optarg("\\\\(?:math)?command\\[(.*)\\]\\{");
+TQRegExp arg("\\\\(?:math)?command\\{(.*)\\}");
+TQRegExp beginenvpkgs("^\\\\begin\\{neededpkgs\\}(?:\\[(.*)\\])?\\{(.*)\\}");
+TQRegExp endenvpkgs("^\\\\end\\{neededpkgs\\}");
+TQRegExp cmdpkgs("\\\\pkgs(?:\\[(.*)\\])?\\{(.*)\\}");
+TQRegExp comment("^\\s*%");
int number=1;
beginenvpkgs.setMinimal(true);
@@ -77,7 +77,7 @@ cmdpkgs.setMinimal(true);
while( (line = t.readLine()) != 0L)
{
- if( line.find(comment) != -1 )
+ if( line.tqfind(comment) != -1 )
continue;
if(env)
{
@@ -90,7 +90,7 @@ while( (line = t.readLine()) != 0L)
pkgsarg="";
}
- if ( line.find(beginenvpkgs) != -1)
+ if ( line.tqfind(beginenvpkgs) != -1)
{
env=true;
pkgs=beginenvpkgs.cap(2);
@@ -98,12 +98,12 @@ while( (line = t.readLine()) != 0L)
savepkgs=pkgs;
savepkgsarg=pkgsarg;
}
- else if( line.find(cmdpkgs) != -1)
+ else if( line.tqfind(cmdpkgs) != -1)
{
pkgs=cmdpkgs.cap(2);
pkgsarg=cmdpkgs.cap(1);
}
- else if( line.find(endenvpkgs) != -1)
+ else if( line.tqfind(endenvpkgs) != -1)
{
env=false;
savepkgs="";
@@ -115,9 +115,9 @@ while( (line = t.readLine()) != 0L)
cout << "line is " << line.latin1();
cout << "; pkgs=" << pkgs.latin1() << " ,pkgsarg=" << pkgsarg.latin1() << " ,savepkgs=" << savepkgs.latin1() << " ,savepkgsarg=" << savepkgsarg.latin1() << "\n";
- if ( line.find(optarg) != -1)
+ if ( line.tqfind(optarg) != -1)
writeComment(optarg.cap(1),pkgs,pkgsarg,type,number++);
- else if(line.find(arg) != -1)
+ else if(line.tqfind(arg) != -1)
writeComment(arg.cap(1),pkgs,pkgsarg,type,number++);
}
@@ -132,11 +132,11 @@ void usage()
exit(1);
}
-void writeComment(QString cmd, QString pkgs, QString pkgsarg, QString type, int number)
+void writeComment(TQString cmd, TQString pkgs, TQString pkgsarg, TQString type, int number)
{
-QImage image;
-QString fname;
+TQImage image;
+TQString fname;
fname.sprintf("img%03d%s.png",number,type.latin1());
cout << "fname is " << fname.latin1() << "\n";
@@ -158,14 +158,14 @@ else
}
-void readComment(QString fname)
+void readComment(TQString fname)
{
-QImage image;
+TQImage image;
if(image.load(fname))
{
- cout << "image " << fname.latin1() << " has Command comment_" << image.text("Command").latin1() << "_\n";
- cout << "image " << fname.latin1() << " has Packages comment_" << image.text("Packages").latin1() << "_\n";
+ cout << "image " << fname.latin1() << " has Command comment_" << TQString(image.text("Command")).latin1() << "_\n";
+ cout << "image " << fname.latin1() << " has Packages comment_" << TQString(image.text("Packages")).latin1() << "_\n";
}
else
diff --git a/src/kile/symbols/gesymb.h b/src/kile/symbols/gesymb.h
index 1477c33..e4511cb 100644
--- a/src/kile/symbols/gesymb.h
+++ b/src/kile/symbols/gesymb.h
@@ -14,14 +14,14 @@
***************************************************************************/
-#include <qimage.h>
-#include <qstring.h>
-#include <qregexp.h>
-#include <qfile.h>
+#include <tqimage.h>
+#include <tqstring.h>
+#include <tqregexp.h>
+#include <tqfile.h>
#include <stdlib.h>
#include <iostream>
void usage();
-void writeComment(QString cmd, QString pkgs, QString pkgsarg, QString type, int number);
-void readComment(QString fname);
+void writeComment(TQString cmd, TQString pkgs, TQString pkgsarg, TQString type, int number);
+void readComment(TQString fname);
diff --git a/src/kile/symbolview.cpp b/src/kile/symbolview.cpp
index b68526f..60f4a03 100644
--- a/src/kile/symbolview.cpp
+++ b/src/kile/symbolview.cpp
@@ -32,8 +32,8 @@ tbraun 2007-06-13
#include "symbolview.h"
#include "kileconfig.h"
-#include <qimage.h>
-#include <qstringlist.h>
+#include <tqimage.h>
+#include <tqstringlist.h>
#include <kimageeffect.h>
#include <klocale.h>
#include <kstandarddirs.h>
@@ -41,14 +41,14 @@ tbraun 2007-06-13
#include <kconfig.h>
-#include <qregexp.h>
-#include <qtooltip.h>
-#include <qlabel.h>
-#include <qrect.h>
-#include <qapplication.h>
+#include <tqregexp.h>
+#include <tqtooltip.h>
+#include <tqlabel.h>
+#include <tqrect.h>
+#include <tqapplication.h>
-SymbolView::SymbolView(QWidget *parent, int type, const char *name): KIconView( parent, name ),m_toolTip(0L)
+SymbolView::SymbolView(TQWidget *tqparent, int type, const char *name): KIconView( tqparent, name ),m_toolTip(0L)
{
setGridX( 36 );
setGridY( 36);
@@ -64,8 +64,8 @@ SymbolView::SymbolView(QWidget *parent, int type, const char *name): KIconView(
setArrangement(LeftToRight);
setAcceptDrops(false);
initPage(type);
- connect( this, SIGNAL( onItem( QIconViewItem * ) ),SLOT( showToolTip( QIconViewItem * ) ) );
- connect( this, SIGNAL( onViewport() ),SLOT( removeToolTip() ) );
+ connect( this, TQT_SIGNAL( onItem( TQIconViewItem * ) ),TQT_SLOT( showToolTip( TQIconViewItem * ) ) );
+ connect( this, TQT_SIGNAL( onViewport() ),TQT_SLOT( removeToolTip() ) );
}
SymbolView::~SymbolView()
@@ -73,7 +73,7 @@ SymbolView::~SymbolView()
removeToolTip();
}
-void SymbolView::extract(const QString& key, int& refCnt)
+void SymbolView::extract(const TQString& key, int& refCnt)
{
if(!key.isEmpty())
refCnt = key.section('%',0,0).toInt();
@@ -81,37 +81,37 @@ void SymbolView::extract(const QString& key, int& refCnt)
return;
}
-void SymbolView::extract(const QString& key, int& refCnt, QString &cmd, QStringList &args, QStringList &pkgs)
+void SymbolView::extract(const TQString& key, int& refCnt, TQString &cmd, TQStringList &args, TQStringList &pkgs)
{
if(key.isEmpty())
return;
extract(key,refCnt);
- QRegExp rePkgs("(?:\\[(.*)\\])?\\{(.*)\\}");
+ TQRegExp rePkgs("(?:\\[(.*)\\])?\\{(.*)\\}");
args.clear();
pkgs.clear();
cmd = key.section('%',1,1);
- QString text = key.section('%',2,2);
+ TQString text = key.section('%',2,2);
- if( text.find(rePkgs) != -1 )
+ if( text.tqfind(rePkgs) != -1 )
{
- args = QStringList::split(",",rePkgs.cap(1));
- pkgs = QStringList::split(",",rePkgs.cap(2));
+ args = TQStringList::split(",",rePkgs.cap(1));
+ pkgs = TQStringList::split(",",rePkgs.cap(2));
}
}
-void SymbolView::showToolTip( QIconViewItem *item )
+void SymbolView::showToolTip( TQIconViewItem *item )
{
removeToolTip();
if ( !item )
return;
- QString cmd, label;
- QStringList pkgs, args;
+ TQString cmd, label;
+ TQStringList pkgs, args;
int refCnt;
extract(item->key(),refCnt,cmd,args,pkgs);
@@ -134,23 +134,23 @@ void SymbolView::showToolTip( QIconViewItem *item )
}
}
- m_toolTip = new QLabel(label, 0,"myToolTip",
+ m_toolTip = new TQLabel(label, 0,"myToolTip",
WStyle_StaysOnTop | WStyle_Customize | WStyle_NoBorder | WStyle_Tool | WX11BypassWM );
- m_toolTip->setFrameStyle( QFrame::Plain | QFrame::Box );
+ m_toolTip->setFrameStyle( TQFrame::Plain | TQFrame::Box );
m_toolTip->setLineWidth( 1 );
- m_toolTip->setAlignment( AlignLeft | AlignTop );
- m_toolTip->move( QCursor::pos() + QPoint( 14, 14 ) );
+ m_toolTip->tqsetAlignment( AlignLeft | AlignTop );
+ m_toolTip->move( TQCursor::pos() + TQPoint( 14, 14 ) );
m_toolTip->adjustSize();
- QRect screen = QApplication::desktop()->screenGeometry(
- QApplication::desktop()->screenNumber(QCursor::pos()));
+ TQRect screen = TQApplication::desktop()->screenGeometry(
+ TQApplication::desktop()->screenNumber(TQCursor::pos()));
if (m_toolTip->x()+m_toolTip->width() > screen.right()) {
m_toolTip->move(m_toolTip->x()+screen.right()-m_toolTip->x()-m_toolTip->width(), m_toolTip->y());
}
if (m_toolTip->y()+m_toolTip->height() > screen.bottom()) {
m_toolTip->move(m_toolTip->x(), screen.bottom()-m_toolTip->y()-m_toolTip->height()+m_toolTip->y());
}
- m_toolTip->setFont( QToolTip::font() );
- m_toolTip->setPalette( QToolTip::palette(), true );
+ m_toolTip->setFont( TQToolTip::font() );
+ m_toolTip->tqsetPalette( TQToolTip::palette(), true );
m_toolTip->show();
}
@@ -160,7 +160,7 @@ void SymbolView::removeToolTip()
m_toolTip = 0;
}
-void SymbolView::hideEvent( QHideEvent *e )
+void SymbolView::hideEvent( TQHideEvent *e )
{
removeToolTip();
KIconView::hideEvent( e );
@@ -220,20 +220,20 @@ void SymbolView::initPage(int page)
}
}
-void SymbolView::contentsMousePressEvent(QMouseEvent *e)
+void SymbolView::contentsMousePressEvent(TQMouseEvent *e)
{
- KILE_DEBUG() << "===SymbolView::contentsMousePressEvent(QMouseEvent *e)===" << endl;
+ KILE_DEBUG() << "===SymbolView::contentsMousePressEvent(TQMouseEvent *e)===" << endl;
- QString code_symbol;
- QStringList args, pkgs;
- QIconViewItem *item = NULL;
+ TQString code_symbol;
+ TQStringList args, pkgs;
+ TQIconViewItem *item = NULL;
int count;
bool math=false, bracket=false;
- if( (e->button() & Qt::LeftButton) == Qt::LeftButton && ( item = findItem( e->pos() ) ) )
+ if( (e->button() & Qt::LeftButton) == Qt::LeftButton && ( item = tqfindItem( e->pos() ) ) )
{
- bracket = (e->state() & Qt::ControlButton) == Qt::ControlButton;
- math = (e->state() & Qt::ShiftButton) == Qt::ShiftButton;
+ bracket = (e->state() & TQt::ControlButton) == TQt::ControlButton;
+ math = (e->state() & TQt::ShiftButton) == TQt::ShiftButton;
extract(item->key(),count,code_symbol,args,pkgs);
@@ -251,21 +251,21 @@ void SymbolView::contentsMousePressEvent(QMouseEvent *e)
KILE_DEBUG() << "math is " << math << ", bracket is " << bracket << " and item->key() is " << ( item ? item->key() : "" ) << endl;
}
-void SymbolView::fillWidget(const QString& prefix)
+void SymbolView::fillWidget(const TQString& prefix)
{
- KILE_DEBUG() << "===SymbolView::fillWidget(const QString& " << prefix << " )===" << endl;
- QImage image;
+ KILE_DEBUG() << "===SymbolView::fillWidget(const TQString& " << prefix << " )===" << endl;
+ TQImage image;
KIconViewItem* item;
- QStringList refCnts,paths;
+ TQStringList refCnts,paths;
if( prefix == MFUSprefix)
{
KConfig *config = KGlobal::config();
config->setGroup(MFUSGroup);
- QString configPaths = config->readEntry("paths");
- QString configrefCnts = config->readEntry("counts");
- paths = QStringList::split(',',configPaths);
- refCnts = QStringList::split(',',configrefCnts);
+ TQString configPaths = config->readEntry("paths");
+ TQString configrefCnts = config->readEntry("counts");
+ paths = TQStringList::split(',',configPaths);
+ refCnts = TQStringList::split(',',configrefCnts);
KILE_DEBUG() << "Read " << paths.count() << " paths and " << refCnts.count() << " refCnts" << endl;
if( paths.count() != refCnts.count() )
{
@@ -289,7 +289,7 @@ void SymbolView::fillWidget(const QString& prefix)
item = new KIconViewItem(this);
item->setPixmap(image);
item->setKey( refCnts[i] + '%' + image.text("Command") + '%' + image.text("Packages") + '%' + paths[i] );
- image = KImageEffect::blend(colorGroup().text(), image, 1); // destroys our png comments, so we do it after reading the comments
+ image = KImageEffect::blend(tqcolorGroup().text(), image, 1); // destroys our png comments, so we do it after reading the comments
}
else
KILE_DEBUG() << "Loading file " << paths[i] << " failed" << endl;
@@ -298,8 +298,8 @@ void SymbolView::fillWidget(const QString& prefix)
void SymbolView::writeConfig()
{
- QIconViewItem *item;
- QStringList paths,refCnts;
+ TQIconViewItem *item;
+ TQStringList paths,refCnts;
KConfig *config = KGlobal::config();
@@ -323,16 +323,16 @@ void SymbolView::writeConfig()
}
}
-void SymbolView::slotAddToList(const QIconViewItem *item)
+void SymbolView::slotAddToList(const TQIconViewItem *item)
{
if( !item || !item->pixmap() )
return;
- QIconViewItem *tmpItem;
+ TQIconViewItem *tmpItem;
bool found=false;
- const QRegExp reCnt("^\\d+");
+ const TQRegExp reCnt("^\\d+");
- KILE_DEBUG() << "===void SymbolView::slotAddToList(const QIconViewItem *" << item << " )===" << endl;
+ KILE_DEBUG() << "===void SymbolView::slotAddToList(const TQIconViewItem *" << item << " )===" << endl;
for ( tmpItem = this->firstItem(); tmpItem; tmpItem = tmpItem->nextItem() )
{
@@ -346,7 +346,7 @@ void SymbolView::slotAddToList(const QIconViewItem *item)
if( !found && ( this->count() + 1 ) > KileConfig::numSymbolsMFUS() ) // we check before adding the symbol
{
int refCnt, minRefCnt=10000;
- QIconViewItem *unpopularItem = 0L;
+ TQIconViewItem *unpopularItem = 0L;
KILE_DEBUG() << "Removing most unpopular item" << endl;
@@ -371,13 +371,13 @@ void SymbolView::slotAddToList(const QIconViewItem *item)
int refCnt;
extract(tmpItem->key(),refCnt);
- QString key = tmpItem->key();
- key.replace(reCnt,QString::number(refCnt+1));
+ TQString key = tmpItem->key();
+ key.tqreplace(reCnt,TQString::number(refCnt+1));
tmpItem->setKey(key);
}
else
{
- tmpItem = new KIconViewItem(this,QString::null,*(item->pixmap()));
+ tmpItem = new KIconViewItem(this,TQString(),*(item->pixmap()));
tmpItem->setKey(item->key());
}
}
diff --git a/src/kile/symbolview.h b/src/kile/symbolview.h
index be90c5f..3aecd6b 100644
--- a/src/kile/symbolview.h
+++ b/src/kile/symbolview.h
@@ -17,45 +17,46 @@
#ifndef SYMBOLVIEW_H
#define SYMBOLVIEW_H
-#include <qiconview.h>
+#include <tqiconview.h>
#include <kiconview.h>
-#include <qscrollview.h>
-#include <qstring.h>
-#include <qlabel.h>
+#include <tqscrollview.h>
+#include <tqstring.h>
+#include <tqlabel.h>
-static const QString MFUSGroup = "MostFrequentlyUsedSymbols";
-static const QString MFUSprefix = "MFUS";
+static const TQString MFUSGroup = "MostFrequentlyUsedSymbols";
+static const TQString MFUSprefix = "MFUS";
class SymbolView : public KIconView
{
Q_OBJECT
+ TQ_OBJECT
public:
- SymbolView(QWidget *parent=0,int type = -1, const char *name=0);
+ SymbolView(TQWidget *tqparent=0,int type = -1, const char *name=0);
~SymbolView();
enum { MFUS = 0, Relation, Operator, Arrow, MiscMath, MiscText, Delimiters, Greek, Special, Cyrillic, User };
void writeConfig();
private:
- void fillWidget(const QString &prefix);
- void hideEvent( QHideEvent * );
- void contentsMousePressEvent(QMouseEvent *e);
- void extract(const QString& key, int& count, QString &cmd, QStringList &args, QStringList &pkgs);
- void extract(const QString& key, int& count);
+ void fillWidget(const TQString &prefix);
+ void hideEvent( TQHideEvent * );
+ void contentsMousePressEvent(TQMouseEvent *e);
+ void extract(const TQString& key, int& count, TQString &cmd, TQStringList &args, TQStringList &pkgs);
+ void extract(const TQString& key, int& count);
void initPage(int page);
signals:
- void insertText(const QString& text,const QStringList &pkgs);
- void addToList(const QIconViewItem *item);
+ void insertText(const TQString& text,const TQStringList &pkgs);
+ void addToList(const TQIconViewItem *item);
private slots:
- void showToolTip( QIconViewItem *item );
- void slotAddToList(const QIconViewItem *item);
+ void showToolTip( TQIconViewItem *item );
+ void slotAddToList(const TQIconViewItem *item);
void removeToolTip();
private:
- QLabel *m_toolTip;
+ TQLabel *m_toolTip;
};
#endif
diff --git a/src/kile/symbolviewconfig.ui b/src/kile/symbolviewconfig.ui
index 79ac81a..8066a43 100644
--- a/src/kile/symbolviewconfig.ui
+++ b/src/kile/symbolviewconfig.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>KileWidgetSymbolViewConfig</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>KileWidgetSymbolViewConfig</cstring>
</property>
@@ -19,7 +19,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -30,17 +30,17 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout6</cstring>
+ <cstring>tqlayout6</cstring>
</property>
<grid>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget" row="0" column="1">
+ <widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
- <cstring>layout4</cstring>
+ <cstring>tqlayout4</cstring>
</property>
<hbox>
<property name="name">
@@ -72,7 +72,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>40</width>
<height>20</height>
@@ -81,7 +81,7 @@
</spacer>
</hbox>
</widget>
- <widget class="QCheckBox" row="2" column="0">
+ <widget class="TQCheckBox" row="2" column="0">
<property name="name">
<cstring>kcfg_clearMFUS</cstring>
</property>
@@ -97,7 +97,7 @@
<string>&amp;Clear the list of symbols whilst closing Kile</string>
</property>
</widget>
- <widget class="QCheckBox" row="1" column="0">
+ <widget class="TQCheckBox" row="1" column="0">
<property name="name">
<cstring>kcfg_displayMFUS</cstring>
</property>
@@ -105,7 +105,7 @@
<string>Display the vie&amp;w</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -134,7 +134,7 @@
<tabstop>kcfg_displayMFUS</tabstop>
<tabstop>kcfg_clearMFUS</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>knuminput.h</includehint>
<includehint>knuminput.h</includehint>
diff --git a/src/kile/tabbingdialog.cpp b/src/kile/tabbingdialog.cpp
index d7d670e..d91a190 100644
--- a/src/kile/tabbingdialog.cpp
+++ b/src/kile/tabbingdialog.cpp
@@ -16,9 +16,9 @@
#include "tabbingdialog.h"
#include "kileedit.h"
-#include <qspinbox.h>
-#include <qlabel.h>
-#include <qlayout.h>
+#include <tqspinbox.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
#include <klineedit.h>
#include <kpushbutton.h>
@@ -27,33 +27,33 @@
namespace KileDialog
{
- QuickTabbing::QuickTabbing(KConfig *config, KileInfo *ki, QWidget *parent, const char *name, const QString &caption ) : Wizard(config, parent,name, caption), m_ki(ki)
+ QuickTabbing::QuickTabbing(KConfig *config, KileInfo *ki, TQWidget *tqparent, const char *name, const TQString &caption ) : Wizard(config, tqparent,name, caption), m_ki(ki)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- QGridLayout *gbox = new QGridLayout( page, 4, 2,5,5,"");
+ TQGridLayout *gbox = new TQGridLayout( page, 4, 2,5,5,"");
gbox->addRowSpacing( 0, fontMetrics().lineSpacing() );
- QLabel *lb = new QLabel(page);
+ TQLabel *lb = new TQLabel(page);
lb->setText(i18n("Num of columns:"));
gbox->addWidget(lb, 0, 0);
- m_spCols = new QSpinBox(page);
+ m_spCols = new TQSpinBox(page);
lb->setBuddy(m_spCols);
m_spCols ->setValue(2);
m_spCols ->setRange(2,99);
gbox->addWidget( m_spCols , 0, 1 );
- lb = new QLabel(page);
+ lb = new TQLabel(page);
lb->setText(i18n("Num of &rows:"));
gbox->addWidget(lb, 1, 0 );
- m_spRows = new QSpinBox(page);
+ m_spRows = new TQSpinBox(page);
lb->setBuddy(m_spRows);
m_spRows->setValue(1);
m_spRows->setRange(1,99);
gbox->addWidget( m_spRows, 1, 1 );
- lb= new QLabel(page);
+ lb= new TQLabel(page);
lb->setText(i18n("&Spacing:"));
gbox->addWidget(lb, 2, 0 );
m_leSpacing = new KLineEdit(page);
@@ -71,8 +71,8 @@ namespace KileDialog
{
int x = m_spCols->value();
int y = m_spRows->value();
- QString s= m_leSpacing->text();
- QString indent = m_ki->editorExtension()->autoIndentEnvironment();
+ TQString s= m_leSpacing->text();
+ TQString indent = m_ki->editorExtension()->autoIndentEnvironment();
m_td.tagBegin = "\\begin{tabbing}\n";
m_td.tagBegin += indent;
diff --git a/src/kile/tabbingdialog.h b/src/kile/tabbingdialog.h
index 2ca5c82..8d55743 100644
--- a/src/kile/tabbingdialog.h
+++ b/src/kile/tabbingdialog.h
@@ -19,9 +19,9 @@
#include "kilewizard.h"
#include "kileinfo.h"
-#include <qdialog.h>
+#include <tqdialog.h>
-class QSpinBox;
+class TQSpinBox;
class KLineEdit;
/**
@@ -34,9 +34,10 @@ namespace KileDialog
class QuickTabbing : public Wizard
{
Q_OBJECT
+ TQ_OBJECT
public:
- QuickTabbing(KConfig *config, KileInfo *ki, QWidget *parent=0, const char *name=0, const QString &caption = QString::null);
+ QuickTabbing(KConfig *config, KileInfo *ki, TQWidget *tqparent=0, const char *name=0, const TQString &caption = TQString());
~QuickTabbing();
public slots:
@@ -44,7 +45,7 @@ namespace KileDialog
public:
KileInfo *m_ki;
- QSpinBox *m_spCols, *m_spRows;
+ TQSpinBox *m_spCols, *m_spRows;
KLineEdit *m_leSpacing;
};
}
diff --git a/src/kile/tabulardialog.cpp b/src/kile/tabulardialog.cpp
index 006bfac..b75d0c3 100644
--- a/src/kile/tabulardialog.cpp
+++ b/src/kile/tabulardialog.cpp
@@ -19,15 +19,15 @@
#include "tabulardialog.h"
#include "codecompletion.h"
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qstyle.h>
-#include <qframe.h>
-#include <qgroupbox.h>
-#include <qbuttongroup.h>
-#include <qwhatsthis.h>
-#include <qcursor.h>
-#include <qmap.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqstyle.h>
+#include <tqframe.h>
+#include <tqgroupbox.h>
+#include <tqbuttongroup.h>
+#include <tqwhatsthis.h>
+#include <tqcursor.h>
+#include <tqmap.h>
#include <kmessagebox.h>
#include <klocale.h>
@@ -119,17 +119,17 @@ static const char * const no_border_xpm[] = {
////////////////////////////// TabCellFrame //////////////////////////////
-TabCellFrame::TabCellFrame(QWidget* parent) : QFrame(parent)
+TabCellFrame::TabCellFrame(TQWidget* tqparent) : TQFrame(tqparent)
{
m_border = TabularCell::cbNone;
- setBackgroundColor(Qt::white);
+ setBackgroundColor(TQt::white);
setFixedWidth(120);
setFixedHeight(120);
setLineWidth(2);
- setFrameStyle(QFrame::Box | QFrame::Raised);
+ setFrameStyle(TQFrame::Box | TQFrame::Raised);
- QRect r = contentsRect();
+ TQRect r = contentsRect();
int x1 = r.left();
int y1 = r.top();
int x2 = r.right();
@@ -148,18 +148,18 @@ void TabCellFrame::setBorder(int value)
update();
}
-void TabCellFrame::drawContents(QPainter *p)
+void TabCellFrame::drawContents(TQPainter *p)
{
p->save();
- QRect r = contentsRect();
+ TQRect r = contentsRect();
int x1 = r.left();
int y1 = r.top();
int x2 = r.right();
int y2 = r.bottom();
// left/top
- p->setPen(Qt::black);
+ p->setPen(TQt::black);
p->drawLine(x1+6,y1+14,x1+14,y1+14);
p->drawLine(x1+14,y1+14,x1+14,y1+6);
@@ -176,12 +176,12 @@ void TabCellFrame::drawContents(QPainter *p)
p->drawLine(x2-14,y2-14,x2-14,y2-6);
// centered rectangle
- p->setPen(Qt::gray);
- p->setBrush(Qt::gray);
+ p->setPen(TQt::gray);
+ p->setBrush(TQt::gray);
p->drawRect(x1+20,y1+20,x2-43,y2-43);
- //QPen pen = QPen(Qt::red,4);
- QPen pen = QPen(Qt::black,4);
+ //TQPen pen = TQPen(TQt::red,4);
+ TQPen pen = TQPen(TQt::black,4);
p->setPen(pen);
if ( m_border & TabularCell::cbLeft )
p->drawLine(x1+10,y1+20,x1+10,y2-20);
@@ -195,7 +195,7 @@ void TabCellFrame::drawContents(QPainter *p)
p->restore();
}
-void TabCellFrame::mousePressEvent(QMouseEvent *event)
+void TabCellFrame::mousePressEvent(TQMouseEvent *event)
{
if ( event->button() != Qt::LeftButton )
return;
@@ -205,13 +205,13 @@ void TabCellFrame::mousePressEvent(QMouseEvent *event)
//KILE_DEBUG() << "left mouse button: x=" << x << " y=" << endl;
int state = 0;
- if ( m_left.contains(x,y) )
+ if ( m_left.tqcontains(x,y) )
state = TabularCell::cbLeft;
- else if ( m_top.contains(x,y) )
+ else if ( m_top.tqcontains(x,y) )
state = TabularCell::cbTop;
- else if ( m_right.contains(x,y) )
+ else if ( m_right.tqcontains(x,y) )
state = TabularCell::cbRight;
- else if ( m_bottom.contains(x,y) )
+ else if ( m_bottom.tqcontains(x,y) )
state = TabularCell::cbBottom;
if ( state > 0 )
@@ -228,7 +228,7 @@ void TabCellFrame::mousePressEvent(QMouseEvent *event)
}
}
-void TabCellFrame::mouseDoubleClickEvent(QMouseEvent *event)
+void TabCellFrame::mouseDoubleClickEvent(TQMouseEvent *event)
{
event->accept();
}
@@ -237,12 +237,12 @@ void TabCellFrame::mouseDoubleClickEvent(QMouseEvent *event)
//BEGIN TabCellDialog
-TabCellDialog::TabCellDialog(QWidget *parent, TabularCell::Data *data,
- const QString &headerlabel, const QStringList &alignlist)
- : KDialogBase( parent,0, true, i18n("Cell Properties"),
+TabCellDialog::TabCellDialog(TQWidget *tqparent, TabularCell::Data *data,
+ const TQString &headerlabel, const TQStringList &alignlist)
+ : KDialogBase( tqparent,0, true, i18n("Cell Properties"),
Ok | Cancel | User1, Ok, true )
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
if ( headerlabel.isEmpty() )
@@ -256,72 +256,72 @@ TabCellDialog::TabCellDialog(QWidget *parent, TabularCell::Data *data,
m_headerlabel = headerlabel;
}
- QGridLayout *grid = new QGridLayout( page, 4,2, 6,6);
+ TQGridLayout *grid = new TQGridLayout( page, 4,2, 6,6);
// font group
- QGroupBox *fontgroup = new QGroupBox( i18n("Font"),page);
+ TQGroupBox *fontgroup = new TQGroupBox( i18n("Font"),page);
fontgroup->setColumnLayout(0, Qt::Vertical );
- fontgroup->layout()->setSpacing( 6 );
- fontgroup->layout()->setMargin( 11 );
+ fontgroup->tqlayout()->setSpacing( 6 );
+ fontgroup->tqlayout()->setMargin( 11 );
- m_cbBold = new QCheckBox(i18n("Bold"),fontgroup);
- m_cbItalic = new QCheckBox(i18n("Italic"),fontgroup);
+ m_cbBold = new TQCheckBox(i18n("Bold"),fontgroup);
+ m_cbItalic = new TQCheckBox(i18n("Italic"),fontgroup);
- QVBoxLayout *fontgrouplayout = new QVBoxLayout( fontgroup->layout() );
- fontgrouplayout->setAlignment( Qt::AlignTop );
- fontgrouplayout->addWidget( m_cbBold );
- fontgrouplayout->addWidget( m_cbItalic );
+ TQVBoxLayout *fontgrouptqlayout = new TQVBoxLayout( fontgroup->tqlayout() );
+ fontgrouptqlayout->tqsetAlignment( TQt::AlignTop );
+ fontgrouptqlayout->addWidget( m_cbBold );
+ fontgrouptqlayout->addWidget( m_cbItalic );
// color group
- QGroupBox *colorgroup = new QGroupBox( i18n("Color"),page);
+ TQGroupBox *colorgroup = new TQGroupBox( i18n("Color"),page);
colorgroup->setColumnLayout(0, Qt::Vertical );
- colorgroup->layout()->setSpacing( 6 );
- colorgroup->layout()->setMargin( 11 );
+ colorgroup->tqlayout()->setSpacing( 6 );
+ colorgroup->tqlayout()->setMargin( 11 );
- QLabel *label1 = new QLabel(i18n("Background:"),colorgroup);
- QLabel *label2 = new QLabel(i18n("Textcolor:"),colorgroup);
+ TQLabel *label1 = new TQLabel(i18n("Background:"),colorgroup);
+ TQLabel *label2 = new TQLabel(i18n("Textcolor:"),colorgroup);
m_ccBgcolor = new KColorCombo(colorgroup);
m_ccTextcolor = new KColorCombo(colorgroup);
- QGridLayout *colorgrouplayout = new QGridLayout( colorgroup->layout() );
- colorgrouplayout->setAlignment( Qt::AlignTop );
- colorgrouplayout->addWidget( label1,0,0 );
- colorgrouplayout->addWidget( label2,1,0 );
- colorgrouplayout->addWidget( m_ccBgcolor,0,1 );
- colorgrouplayout->addWidget( m_ccTextcolor,1,1 );
+ TQGridLayout *colorgrouptqlayout = new TQGridLayout( colorgroup->tqlayout() );
+ colorgrouptqlayout->tqsetAlignment( TQt::AlignTop );
+ colorgrouptqlayout->addWidget( label1,0,0 );
+ colorgrouptqlayout->addWidget( label2,1,0 );
+ colorgrouptqlayout->addWidget( m_ccBgcolor,0,1 );
+ colorgrouptqlayout->addWidget( m_ccTextcolor,1,1 );
- // alignment group
- QButtonGroup *aligngroup = new QButtonGroup( i18n("Alignment"),page);
+ // tqalignment group
+ TQButtonGroup *aligngroup = new TQButtonGroup( i18n("Alignment"),page);
aligngroup->setColumnLayout(0, Qt::Vertical );
- aligngroup->layout()->setSpacing( 6 );
- aligngroup->layout()->setMargin( 11 );
+ aligngroup->tqlayout()->setSpacing( 6 );
+ aligngroup->tqlayout()->setMargin( 11 );
- m_rbAlignleft = new QRadioButton(i18n("Left"),aligngroup);
- m_rbAligncenter = new QRadioButton(i18n("Center"),aligngroup);
- m_rbAlignright = new QRadioButton(i18n("Right"),aligngroup);
+ m_rbAlignleft = new TQRadioButton(i18n("Left"),aligngroup);
+ m_rbAligncenter = new TQRadioButton(i18n("Center"),aligngroup);
+ m_rbAlignright = new TQRadioButton(i18n("Right"),aligngroup);
- QVBoxLayout *aligngrouplayout = new QVBoxLayout( aligngroup->layout() );
- aligngrouplayout->setAlignment( Qt::AlignTop );
- aligngrouplayout->addWidget( m_rbAlignleft );
- aligngrouplayout->addWidget( m_rbAligncenter );
- aligngrouplayout->addWidget( m_rbAlignright );
+ TQVBoxLayout *aligngrouptqlayout = new TQVBoxLayout( aligngroup->tqlayout() );
+ aligngrouptqlayout->tqsetAlignment( TQt::AlignTop );
+ aligngrouptqlayout->addWidget( m_rbAlignleft );
+ aligngrouptqlayout->addWidget( m_rbAligncenter );
+ aligngrouptqlayout->addWidget( m_rbAlignright );
// frame group
- QGroupBox *framegroup = new QGroupBox( i18n("Frame"),page);
+ TQGroupBox *framegroup = new TQGroupBox( i18n("Frame"),page);
framegroup->setColumnLayout(0, Qt::Vertical );
- framegroup->layout()->setSpacing( 6 );
- framegroup->layout()->setMargin( 11 );
+ framegroup->tqlayout()->setSpacing( 6 );
+ framegroup->tqlayout()->setMargin( 11 );
- QLabel *label3 = new QLabel(i18n("Standard:"),framegroup);
- QLabel *label4 = new QLabel(i18n("User defined:"),framegroup);
+ TQLabel *label3 = new TQLabel(i18n("Standard:"),framegroup);
+ TQLabel *label4 = new TQLabel(i18n("User defined:"),framegroup);
- QWidget *lineframe = new QWidget(framegroup);
+ TQWidget *lineframe = new TQWidget(framegroup);
m_pbFrame1 = new KPushButton("x",lineframe,"pb_no_border");
m_pbFrame2 = new KPushButton("",lineframe,"pb_lr_border");
m_pbFrame3 = new KPushButton("",lineframe,"pb_tb_border");
m_pbFrame4 = new KPushButton("",lineframe,"pb_all_border");
- QHBoxLayout *linebox = new QHBoxLayout(lineframe);
+ TQHBoxLayout *linebox = new TQHBoxLayout(lineframe);
linebox->addWidget(m_pbFrame1);
linebox->addSpacing(4);
linebox->addWidget(m_pbFrame2);
@@ -331,53 +331,53 @@ TabCellDialog::TabCellDialog(QWidget *parent, TabularCell::Data *data,
linebox->addWidget(m_pbFrame4);
linebox->addStretch(1);
- QWidget *borderframe = new QWidget(framegroup);
+ TQWidget *borderframe = new TQWidget(framegroup);
m_cellframe = new TabCellFrame(borderframe);
- QHBoxLayout *borderbox = new QHBoxLayout(borderframe);
+ TQHBoxLayout *borderbox = new TQHBoxLayout(borderframe);
borderbox->addStretch(1);
borderbox->addWidget(m_cellframe);
borderbox->addStretch(1);
- QVBoxLayout *framegrouplayout = new QVBoxLayout( framegroup->layout() );
- framegrouplayout->setAlignment( Qt::AlignTop );
- framegrouplayout->addWidget( label3 );
- framegrouplayout->addWidget( lineframe );
- framegrouplayout->addSpacing( 10 );
- framegrouplayout->addWidget( label4 );
- framegrouplayout->addWidget( borderframe );
+ TQVBoxLayout *framegrouptqlayout = new TQVBoxLayout( framegroup->tqlayout() );
+ framegrouptqlayout->tqsetAlignment( TQt::AlignTop );
+ framegrouptqlayout->addWidget( label3 );
+ framegrouptqlayout->addWidget( lineframe );
+ framegrouptqlayout->addSpacing( 10 );
+ framegrouptqlayout->addWidget( label4 );
+ framegrouptqlayout->addWidget( borderframe );
// preamble group
- QGroupBox *preamblegroup = new QGroupBox( i18n("Preamble"),page);
+ TQGroupBox *preamblegroup = new TQGroupBox( i18n("Preamble"),page);
preamblegroup->setColumnLayout(0, Qt::Vertical );
- preamblegroup->layout()->setSpacing( 6 );
- preamblegroup->layout()->setMargin( 11 );
+ preamblegroup->tqlayout()->setSpacing( 6 );
+ preamblegroup->tqlayout()->setMargin( 11 );
- m_cbPre = new QCheckBox(i18n(">{decl}: insert before"),preamblegroup,"cb_pre");
- m_cbPost = new QCheckBox(i18n("<{decl}: insert after"),preamblegroup,"cb_post");
- m_cbAt = new QCheckBox(i18n("@{decl}: suppress space"),preamblegroup,"cb_at");
- m_cbSep = new QCheckBox(i18n("!{decl}: do not suppress space"),preamblegroup,"cb_sep");
+ m_cbPre = new TQCheckBox(i18n(">{decl}: insert before"),preamblegroup,"cb_pre");
+ m_cbPost = new TQCheckBox(i18n("<{decl}: insert after"),preamblegroup,"cb_post");
+ m_cbAt = new TQCheckBox(i18n("@{decl}: suppress space"),preamblegroup,"cb_at");
+ m_cbSep = new TQCheckBox(i18n("!{decl}: do not suppress space"),preamblegroup,"cb_sep");
- QVBoxLayout *preamblegrouplayout = new QVBoxLayout( preamblegroup->layout() );
- preamblegrouplayout->setAlignment( Qt::AlignTop );
- preamblegrouplayout->addWidget( m_cbPre );
- preamblegrouplayout->addWidget( m_cbPost );
- preamblegrouplayout->addWidget( m_cbAt );
- preamblegrouplayout->addWidget( m_cbSep );
+ TQVBoxLayout *preamblegrouptqlayout = new TQVBoxLayout( preamblegroup->tqlayout() );
+ preamblegrouptqlayout->tqsetAlignment( TQt::AlignTop );
+ preamblegrouptqlayout->addWidget( m_cbPre );
+ preamblegrouptqlayout->addWidget( m_cbPost );
+ preamblegrouptqlayout->addWidget( m_cbAt );
+ preamblegrouptqlayout->addWidget( m_cbSep );
// header group
- QGroupBox *headergroup = new QGroupBox( i18n("Alignment"),page);
+ TQGroupBox *headergroup = new TQGroupBox( i18n("Alignment"),page);
headergroup->setColumnLayout(0, Qt::Vertical );
- headergroup->layout()->setSpacing( 6 );
- headergroup->layout()->setMargin( 11 );
+ headergroup->tqlayout()->setSpacing( 6 );
+ headergroup->tqlayout()->setMargin( 11 );
- m_coHeader = new QComboBox(headergroup);
+ m_coHeader = new TQComboBox(headergroup);
- QVBoxLayout *headergrouplayout = new QVBoxLayout( headergroup->layout() );
- headergrouplayout->setAlignment( Qt::AlignTop );
- headergrouplayout->addStretch(1);
- headergrouplayout->addWidget(m_coHeader);
- headergrouplayout->addStretch(1);
+ TQVBoxLayout *headergrouptqlayout = new TQVBoxLayout( headergroup->tqlayout() );
+ headergrouptqlayout->tqsetAlignment( TQt::AlignTop );
+ headergrouptqlayout->addStretch(1);
+ headergrouptqlayout->addWidget(m_coHeader);
+ headergrouptqlayout->addStretch(1);
// add widgets
if ( m_header )
@@ -401,18 +401,18 @@ TabCellDialog::TabCellDialog(QWidget *parent, TabularCell::Data *data,
grid->setRowStretch(3,1);
// init some special widgets
- int buttonheight = m_pbFrame1->sizeHint().height();
+ int buttonheight = m_pbFrame1->tqsizeHint().height();
m_pbFrame1->setFixedSize(buttonheight,buttonheight);
m_pbFrame2->setFixedSize(buttonheight,buttonheight);
m_pbFrame3->setFixedSize(buttonheight,buttonheight);
m_pbFrame4->setFixedSize(buttonheight,buttonheight);
- m_pbFrame1->setPixmap( QPixmap(const_cast<const char**>(no_border_xpm)) );
- m_pbFrame2->setPixmap( QPixmap(const_cast<const char**>(lr_border_xpm)) );
- m_pbFrame3->setPixmap( QPixmap(const_cast<const char**>(tb_border_xpm)) );
- m_pbFrame4->setPixmap( QPixmap(const_cast<const char**>(all_border_xpm)) );
+ m_pbFrame1->setPixmap( TQPixmap(const_cast<const char**>(no_border_xpm)) );
+ m_pbFrame2->setPixmap( TQPixmap(const_cast<const char**>(lr_border_xpm)) );
+ m_pbFrame3->setPixmap( TQPixmap(const_cast<const char**>(tb_border_xpm)) );
+ m_pbFrame4->setPixmap( TQPixmap(const_cast<const char**>(all_border_xpm)) );
- borderframe->setFixedWidth(lineframe->sizeHint().width());
+ borderframe->setFixedWidth(lineframe->tqsizeHint().width());
setButtonText(User1,"Re&set");
if ( m_header )
@@ -431,36 +431,36 @@ TabCellDialog::TabCellDialog(QWidget *parent, TabularCell::Data *data,
// signals and slots
- connect(m_pbFrame1, SIGNAL(clicked()), this, SLOT(slotFramebuttonClicked()));
- connect(m_pbFrame2, SIGNAL(clicked()), this, SLOT(slotFramebuttonClicked()));
- connect(m_pbFrame3, SIGNAL(clicked()), this, SLOT(slotFramebuttonClicked()));
- connect(m_pbFrame4, SIGNAL(clicked()), this, SLOT(slotFramebuttonClicked()));
- connect(this, SIGNAL(user1Clicked()),this, SLOT(slotResetClicked()));
+ connect(m_pbFrame1, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotFramebuttonClicked()));
+ connect(m_pbFrame2, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotFramebuttonClicked()));
+ connect(m_pbFrame3, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotFramebuttonClicked()));
+ connect(m_pbFrame4, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotFramebuttonClicked()));
+ connect(this, TQT_SIGNAL(user1Clicked()),this, TQT_SLOT(slotResetClicked()));
if ( m_header )
{
- connect(m_cbAt, SIGNAL(clicked()),this, SLOT(slotSeparatorClicked()));
- connect(m_cbSep,SIGNAL(clicked()),this, SLOT(slotSeparatorClicked()));
+ connect(m_cbAt, TQT_SIGNAL(clicked()),this, TQT_SLOT(slotSeparatorClicked()));
+ connect(m_cbSep,TQT_SIGNAL(clicked()),this, TQT_SLOT(slotSeparatorClicked()));
}
- QWhatsThis::add(m_coHeader,i18n("Column or cell alignment."));
- QWhatsThis::add(m_cbBold,i18n("Set bold font series."));
- QWhatsThis::add(m_cbItalic,i18n("Set italic font shape."));
- QWhatsThis::add(m_rbAlignleft,i18n("The text will be aligned at the left border of the cell."));
- QWhatsThis::add(m_rbAligncenter,i18n("The text will be centered."));
- QWhatsThis::add(m_rbAlignright,i18n("The text will be aligned at the right border of the cell."));
- QWhatsThis::add(m_ccBgcolor,i18n("Choose a background color (needs color package)."));
- QWhatsThis::add(m_ccTextcolor,i18n("Choose a text color (needs color package)."));
- QWhatsThis::add(m_cbPre,i18n("Insert decl directly in front of the column entry."));
- QWhatsThis::add(m_cbPost,i18n("Insert decl right after the column entry."));
- QWhatsThis::add(m_cbAt,i18n("Suppresses inter-column space and inserts decl directly."));
- QWhatsThis::add(m_cbSep,i18n("Inserts decl, but does not suppress the normally inserted space between columns in contrast to @{decl}."));
- QWhatsThis::add(m_pbFrame1,i18n("Clear all border lines."));
- QWhatsThis::add(m_pbFrame2,i18n("Set left and right border lines."));
- QWhatsThis::add(m_pbFrame3,i18n("Set upper and lower border line."));
- QWhatsThis::add(m_pbFrame4,i18n("Set all border lines."));
- QWhatsThis::add(m_cellframe,i18n("Set user defined border lines. A mouse click into one of the four border ranges will set or clear this special border line."));
-
- setButtonWhatsThis(User1,i18n("Reset all settings to standard cell attributes: left alignment, normal font series and shape, white background color, black text color, no border lines."));
+ TQWhatsThis::add(m_coHeader,i18n("Column or cell tqalignment."));
+ TQWhatsThis::add(m_cbBold,i18n("Set bold font series."));
+ TQWhatsThis::add(m_cbItalic,i18n("Set italic font tqshape."));
+ TQWhatsThis::add(m_rbAlignleft,i18n("The text will be aligned at the left border of the cell."));
+ TQWhatsThis::add(m_rbAligncenter,i18n("The text will be centered."));
+ TQWhatsThis::add(m_rbAlignright,i18n("The text will be aligned at the right border of the cell."));
+ TQWhatsThis::add(m_ccBgcolor,i18n("Choose a background color (needs color package)."));
+ TQWhatsThis::add(m_ccTextcolor,i18n("Choose a text color (needs color package)."));
+ TQWhatsThis::add(m_cbPre,i18n("Insert decl directly in front of the column entry."));
+ TQWhatsThis::add(m_cbPost,i18n("Insert decl right after the column entry."));
+ TQWhatsThis::add(m_cbAt,i18n("Suppresses inter-column space and inserts decl directly."));
+ TQWhatsThis::add(m_cbSep,i18n("Inserts decl, but does not suppress the normally inserted space between columns in contrast to @{decl}."));
+ TQWhatsThis::add(m_pbFrame1,i18n("Clear all border lines."));
+ TQWhatsThis::add(m_pbFrame2,i18n("Set left and right border lines."));
+ TQWhatsThis::add(m_pbFrame3,i18n("Set upper and lower border line."));
+ TQWhatsThis::add(m_pbFrame4,i18n("Set all border lines."));
+ TQWhatsThis::add(m_cellframe,i18n("Set user defined border lines. A mouse click into one of the four border ranges will set or clear this special border line."));
+
+ setButtonWhatsThis(User1,i18n("Reset all settings to standard cell attributes: left tqalignment, normal font series and tqshape, white background color, black text color, no border lines."));
}
////////////////////////////// read data //////////////////////////////
@@ -471,19 +471,19 @@ TabularCell::Data TabCellDialog::data()
{
switch ( m_coHeader->currentItem() )
{
- case 1 : m_data.align = Qt::AlignHCenter; break;
- case 2 : m_data.align = Qt::AlignRight; break;
- default : m_data.align = Qt::AlignLeft;
+ case 1 : m_data.align = TQt::AlignHCenter; break;
+ case 2 : m_data.align = TQt::AlignRight; break;
+ default : m_data.align = TQt::AlignLeft;
}
}
else
{
if ( m_rbAlignright->isChecked() )
- m_data.align = Qt::AlignRight;
+ m_data.align = TQt::AlignRight;
else if ( m_rbAligncenter->isChecked() )
- m_data.align = Qt::AlignHCenter;
+ m_data.align = TQt::AlignHCenter;
else
- m_data.align = Qt::AlignLeft;
+ m_data.align = TQt::AlignLeft;
}
m_data.font = TabularCell::cfNormal;
@@ -500,9 +500,9 @@ TabularCell::Data TabCellDialog::data()
return m_data;
}
-QString TabCellDialog::header()
+TQString TabCellDialog::header()
{
- QString s;
+ TQString s;
if ( m_header )
{
@@ -513,7 +513,7 @@ QString TabCellDialog::header()
if ( m_cbPre->isChecked() )
s += ">{} ";
- s += m_coHeader->currentText().replace("{w}","{}");
+ s += m_coHeader->currentText().tqreplace("{w}","{}");
if ( m_cbPost->isChecked() )
s += " <{}";
@@ -526,18 +526,18 @@ QString TabCellDialog::header()
void TabCellDialog::initWidgetData()
{
- m_data.align = Qt::AlignLeft;
+ m_data.align = TQt::AlignLeft;
m_data.font = TabularCell::cfNormal;
m_data.border = TabularCell::cbNone;
- m_data.bgcolor = QColor(Qt::white);
- m_data.textcolor = QColor(Qt::black);
+ m_data.bgcolor = TQColor(TQt::white);
+ m_data.textcolor = TQColor(TQt::black);
}
void TabCellDialog::initWidgets()
{
- if ( m_data.align & Qt::AlignRight )
+ if ( m_data.align & TQt::AlignRight )
m_rbAlignright->setChecked(true);
- else if ( m_data.align & Qt::AlignHCenter )
+ else if ( m_data.align & TQt::AlignHCenter )
m_rbAligncenter->setChecked(true);
else
m_rbAlignleft->setChecked(true);
@@ -552,29 +552,29 @@ void TabCellDialog::initWidgets()
if ( m_header )
{
- QString s = m_headerlabel.remove(' ');
+ TQString s = m_headerlabel.remove(' ');
- bool state = ( s.find("@{}") >= 0 );
+ bool state = ( s.tqfind("@{}") >= 0 );
if ( state )
s = s.remove("@{}");
m_cbAt->setChecked(state);
- state = ( s.find("!{}") >= 0 );
+ state = ( s.tqfind("!{}") >= 0 );
if ( state )
s = s.remove("!{}");
m_cbSep->setChecked(state);
- state = ( s.find(">{}") >= 0 );
+ state = ( s.tqfind(">{}") >= 0 );
if ( state )
s = s.remove(">{}");
m_cbPre->setChecked(state);
- state = ( s.find("<{}") >= 0 );
+ state = ( s.tqfind("<{}") >= 0 );
if ( state )
s = s.remove("<{}");
m_cbPost->setChecked(state);
- int pos = m_preamblelist.findIndex(s);
+ int pos = m_preamblelist.tqfindIndex(s);
if ( pos < 0 )
pos = 0;
m_coHeader->setCurrentItem(pos);
@@ -585,7 +585,7 @@ void TabCellDialog::initWidgets()
void TabCellDialog::slotFramebuttonClicked()
{
- QString name = QString( sender()->name() ).section('_',1,1);
+ TQString name = TQString( TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->name() ).section('_',1,1);
int border = -1;
if ( name == "no" )
@@ -610,7 +610,7 @@ void TabCellDialog::slotResetClicked()
void TabCellDialog::slotSeparatorClicked()
{
- QString checkboxname = sender()->name();
+ TQString checkboxname = TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->name();
if ( m_cbAt->isChecked() && checkboxname=="cb_at" )
m_cbSep->setChecked(false);
else if ( m_cbSep->isChecked() && checkboxname=="cb_sep" )
@@ -621,22 +621,22 @@ void TabCellDialog::slotSeparatorClicked()
//BEGIN TabularItem
-TabularItem::TabularItem(QTable* table)
- : QTableItem(table,QTableItem::OnTyping,QString::null)
+TabularItem::TabularItem(TQTable* table)
+ : TQTableItem(table,TQTableItem::OnTyping,TQString())
{
TabularTable *tab = dynamic_cast<TabularTable *>(table);
m_data = tab->defaultAttributes();
}
-TabularItem::TabularItem(QTable* table, const TabularCell::Data &data)
- : QTableItem(table,QTableItem::OnTyping,QString::null)
+TabularItem::TabularItem(TQTable* table, const TabularCell::Data &data)
+ : TQTableItem(table,TQTableItem::OnTyping,TQString())
{
m_data = data;
}
-int TabularItem::alignment() const
+int TabularItem::tqalignment() const
{
- return m_data.align | Qt::AlignVCenter;
+ return m_data.align | TQt::AlignVCenter;
}
bool TabularItem::isMulticolumn()
@@ -645,10 +645,10 @@ bool TabularItem::isMulticolumn()
}
// paint the current cell and write the text with special font attributes
-void TabularItem::paint(QPainter *p,const QColorGroup &cg,const QRect &cr,bool selected)
+void TabularItem::paint(TQPainter *p,const TQColorGroup &cg,const TQRect &cr,bool selected)
{
p->fillRect(0,0,cr.width(),cr.height(),
- selected ? cg.brush(QColorGroup::Highlight) : m_data.bgcolor);
+ selected ? cg.brush(TQColorGroup::Highlight) : m_data.bgcolor);
int w = cr.width();
int h = cr.height();
@@ -660,7 +660,7 @@ void TabularItem::paint(QPainter *p,const QColorGroup &cg,const QRect &cr,bool s
if ( m_data.font )
{
- QFont f( p->font() );
+ TQFont f( p->font() );
if ( m_data.font & TabularCell::cfBold )
f.setBold(true);
if ( m_data.font & TabularCell::cfItalic )
@@ -668,18 +668,18 @@ void TabularItem::paint(QPainter *p,const QColorGroup &cg,const QRect &cr,bool s
p->setFont(f);
}
- p->drawText( 2,0,w-4,h,alignment(), text() );
+ p->drawText( 2,0,w-4,h,tqalignment(), text() );
}
//END TabularItem
//////////////////////////////////////////////////////////////////////
-TabularTable::TabularTable(int numRows,int numCols,QWidget* parent,TabularDialog *tabdialog)
- : QTable(numRows,numCols,parent), m_tabdialog(tabdialog)
+TabularTable::TabularTable(int numRows,int numCols,TQWidget* tqparent,TabularDialog *tabdialog)
+ : TQTable(numRows,numCols,tqparent), m_tabdialog(tabdialog)
{
- setSelectionMode(QTable::Single);
+ setSelectionMode(TQTable::Single);
setRowMovingEnabled(false);
setColumnMovingEnabled(false);
setSorting(false);
@@ -688,8 +688,8 @@ TabularTable::TabularTable(int numRows,int numCols,QWidget* parent,TabularDialog
clearVerticalHeader(0,numRows);
// catch right mouse clicks in the table
- connect( this, SIGNAL(contextMenuRequested(int,int,const QPoint &)),
- this, SLOT(slotContextMenuClicked(int,int,const QPoint &)) );
+ connect( this, TQT_SIGNAL(contextMenuRequested(int,int,const TQPoint &)),
+ this, TQT_SLOT(slotContextMenuClicked(int,int,const TQPoint &)) );
// catch right mouse clicks in horizontal/vertical header
horizontalHeader()->installEventFilter(this);
@@ -737,19 +737,19 @@ bool TabularTable::isColEmpty(int col)
////////////////////////////// events //////////////////////////////
-bool TabularTable::eventFilter(QObject *o, QEvent *e)
+bool TabularTable::eventFilter(TQObject *o, TQEvent *e)
{
- if ( e->type() == QEvent::MouseButtonPress )
+ if ( e->type() == TQEvent::MouseButtonPress )
{
- QMouseEvent *me = (QMouseEvent*) e;
- if ( me->button() == RightButton )
+ TQMouseEvent *me = TQT_TQMOUSEEVENT(e);
+ if ( me->button() == Qt::RightButton )
{
- if ( o == horizontalHeader() )
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(horizontalHeader()) )
{
mouseContextHorizontalHeader( me->pos().x() );
return true;
}
- else if ( o == verticalHeader() )
+ else if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(verticalHeader()) )
{
mouseContextVerticalHeader( me->pos().y() );
return true;
@@ -757,7 +757,7 @@ bool TabularTable::eventFilter(QObject *o, QEvent *e)
}
}
- return QTable::eventFilter(o,e);
+ return TQTable::eventFilter(o,e);
}
void TabularTable::mouseContextHorizontalHeader(int pos)
@@ -778,11 +778,11 @@ TabularCell::Data TabularTable::defaultAttributes()
{
TabularCell::Data data;
- data.align = Qt::AlignLeft;
+ data.align = TQt::AlignLeft;
data.font = TabularCell::cfNormal;
data.border = TabularCell::cbNone;
- data.bgcolor = QColor(Qt::white);
- data.textcolor = QColor(Qt::black);
+ data.bgcolor = TQColor(TQt::white);
+ data.textcolor = TQColor(TQt::black);
return data;
}
@@ -803,7 +803,7 @@ bool TabularTable::isDefaultAttr(const TabularCell::Data &data)
// always check first, if we have to create a new item.
TabularItem *TabularTable::cellItem(int row,int col)
{
- QTableItem *cellitem = item(row,col);
+ TQTableItem *cellitem = item(row,col);
if ( ! cellitem )
{
TabularItem *newitem = new TabularItem(this);
@@ -814,9 +814,9 @@ TabularItem *TabularTable::cellItem(int row,int col)
return dynamic_cast<TabularItem*>(cellitem);
}
-// Empty text is not written, if there is no QTableItem
-// or the current QTableItem has default attributes
-void TabularTable::setText(int row,int col,const QString &text)
+// Empty text is not written, if there is no TQTableItem
+// or the current TQTableItem has default attributes
+void TabularTable::setText(int row,int col,const TQString &text)
{
TabularItem *cellitem = cellItem(row,col);
cellitem->setText(text);
@@ -824,15 +824,15 @@ void TabularTable::setText(int row,int col,const QString &text)
updateCell(row,col);
}
-void TabularTable::setAlignment(int row,int col,int align)
+void TabularTable::tqsetAlignment(int row,int col,int align)
{
TabularItem *cellitem = cellItem(row,col);
cellitem->m_data.align = align;
- if ( align == Qt::AlignLeft )
+ if ( align == TQt::AlignLeft )
updateCell(row,col);
}
-void TabularTable::setColspan(int row,int col1,int col2,int numcols,const QString &text)
+void TabularTable::setColspan(int row,int col1,int col2,int numcols,const TQString &text)
{
//KILE_DEBUG() << "set colspan " << col1 << "-" << col2 << " "<< endl;
for ( int col=col1; col<=col2; )
@@ -862,7 +862,7 @@ bool TabularTable::isMulticolumn(int row,int col)
return ( cellitem && cellitem->isMulticolumn() );
}
-// Set new attributes. If all settings are default, delete QTableItem
+// Set new attributes. If all settings are default, delete TQTableItem
void TabularTable::setAttributes(int row,int col, const TabularCell::Data &data)
{
TabularItem *cellitem = dynamic_cast<TabularItem*>( item(row,col) );
@@ -888,13 +888,13 @@ void TabularTable::clearAttributes(int row,int col)
void TabularTable::updateCurrentCell()
{
- if ( editMode() != QTable::NotEditing )
+ if ( editMode() != TQTable::NotEditing )
endEdit(currentRow(),currentColumn(),true,true);
}
// A cell is updated or is is asked, if there is still an entry.
-// Check if we need the QTableItem anymore. The result will be true,
-// if there is still a QTableItem, else false.
+// Check if we need the TQTableItem anymore. The result will be true,
+// if there is still a TQTableItem, else false.
bool TabularTable::updateCell(int row,int col)
{
TabularItem *cellitem = dynamic_cast<TabularItem*>( item(row,col) );
@@ -911,10 +911,10 @@ bool TabularTable::updateCell(int row,int col)
return true;
}
-// when editing is finished, we check, if the QTableItem is still needed
-void TabularTable::endEdit(int row,int col,bool accept,bool replace)
+// when editing is finished, we check, if the TQTableItem is still needed
+void TabularTable::endEdit(int row,int col,bool accept,bool tqreplace)
{
- QTable::endEdit(row,col,accept,replace);
+ TQTable::endEdit(row,col,accept,tqreplace);
//updateCell(row,col);
}
@@ -948,7 +948,7 @@ void TabularTable::clearCellrange(int x1,int y1,int x2,int y2,bool cleartext,boo
for ( int col=x1; col<=x2; ++col )
{
if ( cleartext )
- setText(row,col,QString::null);
+ setText(row,col,TQString());
if ( clearattributes && (singlecell || !isMulticolumn(row,col)) )
clearAttributes(row,col);
@@ -980,7 +980,7 @@ void TabularTable::setCellrangeAlignment(int x1,int y1,int x2,int y2,int align)
for (int row=y1; row<=y2; ++row )
{
if ( singlecell || !isMulticolumn(row,col) )
- setAlignment(row,col,align);
+ tqsetAlignment(row,col,align);
}
}
}
@@ -1010,9 +1010,9 @@ void TabularTable::activateNextCell()
////////////////////////////// paint //////////////////////////////
-// Paint a table cell with all attributes, if there is a QTableItem
-void TabularTable::paintCell( QPainter *p, int row, int col,
- const QRect &cr, bool selected, const QColorGroup &cg )
+// Paint a table cell with all attributes, if there is a TQTableItem
+void TabularTable::paintCell( TQPainter *p, int row, int col,
+ const TQRect &cr, bool selected, const TQColorGroup &cg )
{
//KILE_DEBUG() << "r=" << row << " c" << col<< endl;
@@ -1034,25 +1034,25 @@ void TabularTable::paintCell( QPainter *p, int row, int col,
}
else
{
- p->fillRect( 0,0,w,h, selected ? cg.brush( QColorGroup::Highlight )
- : cg.brush( QColorGroup::Base ) );
+ p->fillRect( 0,0,w,h, selected ? cg.brush( TQColorGroup::Highlight )
+ : cg.brush( TQColorGroup::Base ) );
}
// draw gridlines
if ( showGrid() )
{
// save current pen
- QPen pen( p->pen() );
+ TQPen pen( p->pen() );
- QColor gridlinecolor;
- int gridColor = style().styleHint( QStyle::SH_Table_GridLineColor, this );
+ TQColor gridlinecolor;
+ int gridColor = tqstyle().tqstyleHint( TQStyle::SH_Table_GridLineColor, this );
if (gridColor != -1)
{
- const QPalette &pal = palette();
- if ( cg != colorGroup() && cg != pal.disabled() && cg != pal.inactive() )
+ const TQPalette &pal = palette();
+ if ( cg != tqcolorGroup() && cg != pal.disabled() && cg != pal.inactive() )
gridlinecolor = cg.mid(); // p->setPen(cg.mid());
else
- gridlinecolor = (QRgb)gridColor; // p->setPen((QRgb)gridColor);
+ gridlinecolor = (TQRgb)gridColor; // p->setPen((TQRgb)gridColor);
}
else
{
@@ -1086,7 +1086,7 @@ void TabularTable::paintCell( QPainter *p, int row, int col,
TabularItem *below = dynamic_cast<TabularItem*>( item(row+1,col) );
drawborder = ( below && (below->m_data.border & TabularCell::cbTop) );
}
- p->setPen( (drawborder) ? Qt::black : gridlinecolor );
+ p->setPen( (drawborder) ? TQt::black : gridlinecolor );
p->drawLine( 0,y2,x2,y2 );
// at the right border of the cell either the gridline or the
@@ -1098,7 +1098,7 @@ void TabularTable::paintCell( QPainter *p, int row, int col,
TabularItem *right = dynamic_cast<TabularItem*>( item(row,col+colspan) );
drawborder = ( right && (right->m_data.border & TabularCell::cbLeft) );
}
- p->setPen( (drawborder) ? Qt::black : gridlinecolor );
+ p->setPen( (drawborder) ? TQt::black : gridlinecolor );
p->drawLine( x2,0,x2,y2 );
// restore pen
@@ -1108,29 +1108,29 @@ void TabularTable::paintCell( QPainter *p, int row, int col,
////////////////////////////// popup menus //////////////////////////////
-QPopupMenu *TabularTable::createPopupMenu()
+TQPopupMenu *TabularTable::createPopupMenu()
{
- QPopupMenu *menu = new QPopupMenu(this);
+ TQPopupMenu *menu = new TQPopupMenu(this);
menu->insertItem( i18n("Edit..."));
menu->insertSeparator();
return menu;
}
-void TabularTable::insertPopupAlign(QPopupMenu *popup,bool header)
+void TabularTable::insertPopupAlign(TQPopupMenu *popup,bool header)
{
- // alignment
+ // tqalignment
int align = 0;
//calculate
if ( header && m_x1==m_x2 )
{
- QString label = horizontalHeader()->label(m_x1);
- if ( label.find('l') < 0 )
+ TQString label = horizontalHeader()->label(m_x1);
+ if ( label.tqfind('l') < 0 )
align += 1;
- if ( label.find('c') < 0 )
+ if ( label.tqfind('c') < 0 )
align += 2;
- if ( label.find('r') < 0 )
+ if ( label.tqfind('r') < 0 )
align += 4;
} else
{
@@ -1148,16 +1148,16 @@ void TabularTable::insertPopupAlign(QPopupMenu *popup,bool header)
popup->insertSeparator();
}
-void TabularTable::insertPopupClear(QPopupMenu *popup)
+void TabularTable::insertPopupClear(TQPopupMenu *popup)
{
popup->insertItem( i18n("Clear Text"));
popup->insertItem( i18n("Clear Attributes"));
popup->insertItem( i18n("Clear All"));
}
-int TabularTable::popupId(QPopupMenu *popup, int id)
+int TabularTable::popupId(TQPopupMenu *popup, int id)
{
- QString entry = popup->text(id);
+ TQString entry = popup->text(id);
int result = PopupNone;
if ( entry == i18n("Edit...") )
@@ -1184,7 +1184,7 @@ int TabularTable::popupId(QPopupMenu *popup, int id)
////////////////////////////// cellrange: right mouse button //////////////////////////////
-void TabularTable::slotContextMenuClicked(int row,int col,const QPoint &)
+void TabularTable::slotContextMenuClicked(int row,int col,const TQPoint &)
{
//KILE_DEBUG() << "context menu clicked" << endl;
if ( row<0 || col<0 )
@@ -1223,8 +1223,8 @@ void TabularTable::slotContextMenuClicked(int row,int col,const QPoint &)
insertPopupAlign(m_cellpopup,false);
insertPopupClear(m_cellpopup);
- connect(m_cellpopup,SIGNAL(activated(int)),this,SLOT(slotCellPopupActivated(int)));
- m_cellpopup->exec( QCursor::pos() );
+ connect(m_cellpopup,TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotCellPopupActivated(int)));
+ m_cellpopup->exec( TQCursor::pos() );
clearSelection();
}
@@ -1236,9 +1236,9 @@ void TabularTable::slotCellPopupActivated(int id)
case PopupEdit : cellPopupEdit(); break;
case PopupSet : cellPopupSetMulticolumn(); break;
case PopupBreak : cellPopupBreakMulticolumn(); break;
- case PopupLeft : cellPopupAlign(Qt::AlignLeft); break;
- case PopupCenter : cellPopupAlign(Qt::AlignHCenter); break;
- case PopupRight : cellPopupAlign(Qt::AlignRight); break;
+ case PopupLeft : cellPopupAlign(TQt::AlignLeft); break;
+ case PopupCenter : cellPopupAlign(TQt::AlignHCenter); break;
+ case PopupRight : cellPopupAlign(TQt::AlignRight); break;
case PopupText : clearSelectionCells(true,false); break;
case PopupAttributes : clearSelectionCells(false,true); break;
case PopupAll : clearSelectionCells(true,true); break;
@@ -1261,7 +1261,7 @@ void TabularTable::cellPopupEdit()
}
//KILE_DEBUG() << "sel " << x1 << " " << y1 << " " << x2 << " " << y2 << endl;
- cellParameterDialog(m_x1,m_y1,m_x2,m_y2,pdata,QString::null);
+ cellParameterDialog(m_x1,m_y1,m_x2,m_y2,pdata,TQString());
}
void TabularTable::cellPopupSetMulticolumn()
@@ -1275,12 +1275,12 @@ void TabularTable::cellPopupSetMulticolumn()
int xl,xr;
getCellRange(m_y1,m_x1,m_x2,xl,xr);
- QString s = getCellRangeText(m_y1,xl,xr);
+ TQString s = getCellRangeText(m_y1,xl,xr);
if ( ! s.isEmpty() )
{
- QString message = i18n("Concat all text to the new multicolumn cell?");
+ TQString message = i18n("Concat all text to the new multicolumn cell?");
if ( KMessageBox::questionYesNo(this,message,i18n("Save Text")) != KMessageBox::Yes )
- s = QString::null;
+ s = TQString();
}
setColspan(m_y1,xl,xr,xr-xl+1,s);
// update();
@@ -1298,13 +1298,13 @@ void TabularTable::cellPopupBreakMulticolumn()
int xl,xr;
getCellRange(m_y1,m_x1,m_x2,xl,xr);
- QString s = getCellRangeText(m_y1,xl,xr);
+ TQString s = getCellRangeText(m_y1,xl,xr);
if ( ! s.isEmpty() )
{
if ( KMessageBox::questionYesNo(this,
i18n("Transfer text and all attributes of the multicolumn cell to the leftmost of the separated cell?"),
i18n("Shrink Multicolumn")) != KMessageBox::Yes )
- s = QString::null;
+ s = TQString();
}
setColspan(m_y1,xl,xr,1,s);
@@ -1351,9 +1351,9 @@ void TabularTable::getCellRange(int row,int col1, int col2, int &xl, int &xr)
}
// get text from real cell range including possible multicolumn cells
-QString TabularTable::getCellRangeText(int row,int col1, int col2)
+TQString TabularTable::getCellRangeText(int row,int col1, int col2)
{
- QString s;
+ TQString s;
for ( int col=col1; col<=col2; )
{
TabularItem *cellitem = dynamic_cast<TabularItem*>( item(row,col) );
@@ -1403,8 +1403,8 @@ void TabularTable::setupContextHeaderPopup(bool horizontal, int section)
insertPopupAlign(m_headerpopup,m_horizontal);
insertPopupClear(m_headerpopup);
- connect(m_headerpopup,SIGNAL(activated(int)),this,SLOT(slotHeaderPopupActivated(int)));
- m_headerpopup->exec( QCursor::pos() );
+ connect(m_headerpopup,TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotHeaderPopupActivated(int)));
+ m_headerpopup->exec( TQCursor::pos() );
}
void TabularTable::slotHeaderPopupActivated(int id)
@@ -1430,7 +1430,7 @@ void TabularTable::headerPopupEdit()
if ( m_horizontal )
{
// default header label
- QString label = horizontalHeader()->label(m_section);
+ TQString label = horizontalHeader()->label(m_section);
// look if all labels are equal
for ( int col=m_x1; col<=m_x2; ++col )
@@ -1447,18 +1447,18 @@ void TabularTable::headerPopupEdit()
cellParameterDialog( m_x1,0,m_x2,numRows()-1,0,label );
}
else
- cellParameterDialog(0,m_y1,numCols()-1,m_y2,0,QString::null);
- // cellParameterDialog(0,m_section,numCols()-1,m_section,0,QString::null);
+ cellParameterDialog(0,m_y1,numCols()-1,m_y2,0,TQString());
+ // cellParameterDialog(0,m_section,numCols()-1,m_section,0,TQString());
}
-void TabularTable::headerPopupAlign(QChar alignchar)
+void TabularTable::headerPopupAlign(TQChar alignchar)
{
int align;
switch ( alignchar )
{
- case 'c' : align = Qt::AlignHCenter; break;
- case 'r' : align = Qt::AlignRight; break;
- default : align = Qt::AlignLeft;
+ case 'c' : align = TQt::AlignHCenter; break;
+ case 'r' : align = TQt::AlignRight; break;
+ default : align = TQt::AlignLeft;
}
setCellrangeAlignment(m_x1,m_y1,m_x2,m_y2,align);
if ( m_horizontal )
@@ -1466,18 +1466,18 @@ void TabularTable::headerPopupAlign(QChar alignchar)
}
// adjust headerlabel: lcr
-void TabularTable::updateHeaderAlignment(int col1,int col2,QChar alignchar)
+void TabularTable::updateHeaderAlignment(int col1,int col2,TQChar alignchar)
{
- QStringList list = m_tabdialog->columnAlignments();
+ TQStringList list = m_tabdialog->columnAlignments();
for ( int col=col1; col<=col2; ++col )
{
- QString label = horizontalHeader()->label(col);
+ TQString label = horizontalHeader()->label(col);
for ( uint i=0; i<list.count(); ++i )
{
- if ( label.find(list[i]) >= 0 )
+ if ( label.tqfind(list[i]) >= 0 )
{
- horizontalHeader()->setLabel( col,label.replace(list[i],alignchar) );
+ horizontalHeader()->setLabel( col,label.tqreplace(list[i],alignchar) );
break;
}
}
@@ -1493,7 +1493,7 @@ bool TabularTable::getCurrentSelection(int &x1,int &y1,int &x2,int &y2)
if ( nr >= 0 )
{
// get parameter of current selection
- QTableSelection sel = selection(nr);
+ TQTableSelection sel = selection(nr);
x1 = sel.leftCol();
y1 = sel.topRow();
x2 = sel.rightCol();
@@ -1511,7 +1511,7 @@ bool TabularTable::getCurrentSelection(int &x1,int &y1,int &x2,int &y2)
// - single cell: current attributes are shown
// - cellrange: attributes are shown, if they are all equal
void TabularTable::cellParameterDialog(int x1,int y1,int x2,int y2, TabularCell::Data *data,
- const QString &headerlabel)
+ const TQString &headerlabel)
{
//KILE_DEBUG() << "selection " << x1 << " " << y1 << " " << x2 << " " << y2 << endl;
@@ -1521,7 +1521,7 @@ void TabularTable::cellParameterDialog(int x1,int y1,int x2,int y2, TabularCell:
{
TabularCell::Data defaultdata = defaultAttributes();
- // look if there is a QTableItem in the upper left cell
+ // look if there is a TQTableItem in the upper left cell
TabularItem *cellitem = dynamic_cast<TabularItem*>( item(y1,x1) );
// Now test the range. If the result is true, cellitem must be defined
@@ -1562,7 +1562,7 @@ void TabularTable::cellParameterDialog(int x1,int y1,int x2,int y2, TabularCell:
bool TabularTable::equalParameter(int x1,int y1,int x2,int y2, int code)
{
- // no QTableItem, so we should take default values
+ // no TQTableItem, so we should take default values
TabularItem *upperleft = dynamic_cast<TabularItem*>( item(y1,x1) );
if ( ! upperleft )
return false;
@@ -1739,17 +1739,17 @@ TabularCell::Count TabularTable::countCells(int x1,int y1,int x2,int y2)
{
//KILE_DEBUG() << "count font,colors,textcolors" << endl;
- QMap<QString,int> colors;
- QMap<QString,int> textcolors;
- QMapIterator<QString,int> it, itw, itb;
+ TQMap<TQString,int> colors;
+ TQMap<TQString,int> textcolors;
+ TQMapIterator<TQString,int> it, itw, itb;
- QString whitename = Qt::white.name();
+ TQString whitename = TQt::white.name();
colors[whitename] = 0;
- itw = colors.find(whitename);
+ itw = colors.tqfind(whitename);
- QString blackname = Qt::black.name();
+ TQString blackname = TQt::black.name();
textcolors[blackname] = 0;
- itb = textcolors.find(blackname);
+ itb = textcolors.tqfind(blackname);
// initialize result
TabularCell::Count count = { 0,0,0,0,0, whitename,blackname };
@@ -1775,8 +1775,8 @@ TabularCell::Count TabularTable::countCells(int x1,int y1,int x2,int y2)
count.italic++;
// check backgroundcolor
- QString name = cellitem->m_data.bgcolor.name();
- it = colors.find(name);
+ TQString name = cellitem->m_data.bgcolor.name();
+ it = colors.tqfind(name);
if ( it != colors.end() )
(*it)++;
else
@@ -1784,7 +1784,7 @@ TabularCell::Count TabularTable::countCells(int x1,int y1,int x2,int y2)
// check textcolor
name = cellitem->m_data.textcolor.name();
- it = textcolors.find(name);
+ it = textcolors.tqfind(name);
if ( it != textcolors.end() )
(*it)++;
else
@@ -1832,61 +1832,61 @@ TabularCell::Count TabularTable::countCells(int x1,int y1,int x2,int y2)
//BEGIN TabularDialog
-TabularDialog::TabularDialog(QWidget *parent, KConfig *config, KileDocument::LatexCommands *commands, bool tabularenv)
- : Wizard(config,parent), m_latexCommands(commands)
+TabularDialog::TabularDialog(TQWidget *tqparent, KConfig *config, KileDocument::LatexCommands *commands, bool tabularenv)
+ : Wizard(config,tqparent), m_latexCommands(commands)
{
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
setCaption(i18n("Tabular Environments"));
- QVBoxLayout *vbox = new QVBoxLayout( page, 6,6);
+ TQVBoxLayout *vbox = new TQVBoxLayout( page, 6,6);
// Table
m_table = new TabularTable(3,3,page,this);
// remark
- QLabel *labelRemark = new QLabel( i18n("<center>Hint: You can set some cell properties with a right mouse click.</center>") ,page);
+ TQLabel *labelRemark = new TQLabel( i18n("<center>Hint: You can set some cell properties with a right mouse click.</center>") ,page);
// environment group
- QButtonGroup *group = new QButtonGroup( i18n("Environment"),page);
+ TQButtonGroup *group = new TQButtonGroup( i18n("Environment"),page);
group->setColumnLayout(0, Qt::Vertical );
- group->layout()->setSpacing( 4 );
- group->layout()->setMargin( 11 );
-
- QLabel *label1 = new QLabel(i18n("&Name:"),group);
- QLabel *label2 = new QLabel(i18n("&Parameter:"),group);
- QLabel *label3 = new QLabel(i18n("Number of &rows:"),group);
- QLabel *label4 = new QLabel(i18n("Number of c&ols:"),group);
- m_coEnvironment = new QComboBox(group);
- m_coParameter = new QComboBox(group);
- m_spRows = new QSpinBox(1,99,1,group);
- m_spCols = new QSpinBox(1,49,1,group);
- m_cbWarning = new QCheckBox(i18n("&Delete also non empty rows or columns, but ask"),group);
- m_cbBooktabs = new QCheckBox(i18n("Use boo&ktabs package"),group);
- m_cbStarred = new QCheckBox(i18n("Use starred &version"),group);
- m_cbCenter = new QCheckBox(i18n("C&enter"),group);
- m_cbBullets = new QCheckBox(i18n("Insert &bullets"),group);
-
- QGridLayout *grouplayout = new QGridLayout( group->layout() );
- grouplayout->setAlignment( Qt::AlignTop );
- grouplayout->setColStretch(5,1);
- grouplayout->addWidget( label1, 0,0 );
- grouplayout->addWidget( label2, 1,0 );
- grouplayout->addWidget( m_coEnvironment, 0,1 );
- grouplayout->addWidget( m_coParameter, 1,1 );
- grouplayout->setColSpacing(2,24);
- grouplayout->addWidget( label3, 0,3 );
- grouplayout->addWidget( label4, 1,3 );
- grouplayout->addWidget( m_spRows, 0,4 );
- grouplayout->addWidget( m_spCols, 1,4 );
- grouplayout->setRowSpacing(2,8);
-
- grouplayout->addMultiCellWidget( m_cbWarning, 3,3,0,4, Qt::AlignLeft );
-
- grouplayout->addMultiCellWidget( m_cbStarred, 4,4,0,1, Qt::AlignLeft );
- grouplayout->addMultiCellWidget( m_cbBooktabs, 5,5,0,1, Qt::AlignLeft );
- grouplayout->addMultiCellWidget( m_cbCenter, 4,4,3,4, Qt::AlignLeft );
- grouplayout->addMultiCellWidget( m_cbBullets, 5,5,3,4, Qt::AlignLeft );
+ group->tqlayout()->setSpacing( 4 );
+ group->tqlayout()->setMargin( 11 );
+
+ TQLabel *label1 = new TQLabel(i18n("&Name:"),group);
+ TQLabel *label2 = new TQLabel(i18n("&Parameter:"),group);
+ TQLabel *label3 = new TQLabel(i18n("Number of &rows:"),group);
+ TQLabel *label4 = new TQLabel(i18n("Number of c&ols:"),group);
+ m_coEnvironment = new TQComboBox(group);
+ m_coParameter = new TQComboBox(group);
+ m_spRows = new TQSpinBox(1,99,1,group);
+ m_spCols = new TQSpinBox(1,49,1,group);
+ m_cbWarning = new TQCheckBox(i18n("&Delete also non empty rows or columns, but ask"),group);
+ m_cbBooktabs = new TQCheckBox(i18n("Use boo&ktabs package"),group);
+ m_cbStarred = new TQCheckBox(i18n("Use starred &version"),group);
+ m_cbCenter = new TQCheckBox(i18n("C&enter"),group);
+ m_cbBullets = new TQCheckBox(i18n("Insert &bullets"),group);
+
+ TQGridLayout *grouptqlayout = new TQGridLayout( group->tqlayout() );
+ grouptqlayout->tqsetAlignment( TQt::AlignTop );
+ grouptqlayout->setColStretch(5,1);
+ grouptqlayout->addWidget( label1, 0,0 );
+ grouptqlayout->addWidget( label2, 1,0 );
+ grouptqlayout->addWidget( m_coEnvironment, 0,1 );
+ grouptqlayout->addWidget( m_coParameter, 1,1 );
+ grouptqlayout->setColSpacing(2,24);
+ grouptqlayout->addWidget( label3, 0,3 );
+ grouptqlayout->addWidget( label4, 1,3 );
+ grouptqlayout->addWidget( m_spRows, 0,4 );
+ grouptqlayout->addWidget( m_spCols, 1,4 );
+ grouptqlayout->setRowSpacing(2,8);
+
+ grouptqlayout->addMultiCellWidget( m_cbWarning, 3,3,0,4, TQt::AlignLeft );
+
+ grouptqlayout->addMultiCellWidget( m_cbStarred, 4,4,0,1, TQt::AlignLeft );
+ grouptqlayout->addMultiCellWidget( m_cbBooktabs, 5,5,0,1, TQt::AlignLeft );
+ grouptqlayout->addMultiCellWidget( m_cbCenter, 4,4,3,4, TQt::AlignLeft );
+ grouptqlayout->addMultiCellWidget( m_cbBullets, 5,5,3,4, TQt::AlignLeft );
// add widgets
vbox->addWidget( m_table);
@@ -1901,7 +1901,7 @@ TabularDialog::TabularDialog(QWidget *parent, KConfig *config, KileDocument::Lat
label4->setBuddy(m_spCols);
// init widgets
- m_table->setMinimumHeight( m_table->sizeHint().height()-3 );
+ m_table->setMinimumHeight( m_table->tqsizeHint().height()-3 );
m_spRows->setValue(3);
m_spCols->setValue(3);
m_cbCenter->setChecked(true);
@@ -1915,34 +1915,34 @@ TabularDialog::TabularDialog(QWidget *parent, KConfig *config, KileDocument::Lat
m_cols = m_spCols->value();
m_table->setFocus();
- resize(sizeHint().width(),sizeHint().height()+50);
+ resize(tqsizeHint().width(),tqsizeHint().height()+50);
// signals and slots
- connect( m_coEnvironment, SIGNAL(activated(const QString &)),
- this, SLOT(slotEnvironmentChanged(const QString &)));
- connect( m_spRows, SIGNAL(valueChanged(int)), this, SLOT(slotRowValueChanged(int)));
- connect( m_spCols, SIGNAL(valueChanged(int)), this, SLOT(slotColValueChanged(int)));
-
- QWhatsThis::add(m_table,i18n("Input data. When you press Enter, the cursor will move to the cell right of the current cell. A click with the right mouse button on a cell or a range of cells will open a popup menu, where you can edit attributes, clear attributes, delete text or define multicolumn cells."));
- QWhatsThis::add(m_table->horizontalHeader(),i18n("Current layout of the preamble. A click with the right mouse button will open a popup menu, where you can edit some attributes of all cells, which belong to the selected columns."));
- QWhatsThis::add(m_table->verticalHeader(),i18n("A click with the right mouse button will open a popup menu, where you can edit some attributes of all cells, which belong to the selected rows."));
- QWhatsThis::add(m_coEnvironment,i18n("Choose an environment."));
- QWhatsThis::add(m_coParameter,i18n("Optional parameter for the chosen environment."));
- QWhatsThis::add(m_spRows,i18n("Choose the number of table rows."));
- QWhatsThis::add(m_spCols,i18n("Choose the number of table columns."));
- QWhatsThis::add(m_cbWarning,i18n("If you want, you will be asked before a non empty row a column is deleted."));
- QWhatsThis::add(m_cbCenter,i18n("The tabular will be centered."));
- QWhatsThis::add(m_cbBooktabs,i18n("Use line commands of the booktabs package."));
- QWhatsThis::add(m_cbStarred,i18n("Use the starred version of this environment."));
- QWhatsThis::add(m_cbBullets,i18n("Insert bullets in each cell. Alt+Ctrl+Right and Alt+Ctrl+Left will move very quick from one cell to another."));
+ connect( m_coEnvironment, TQT_SIGNAL(activated(const TQString &)),
+ this, TQT_SLOT(slotEnvironmentChanged(const TQString &)));
+ connect( m_spRows, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotRowValueChanged(int)));
+ connect( m_spCols, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotColValueChanged(int)));
+
+ TQWhatsThis::add(m_table,i18n("Input data. When you press Enter, the cursor will move to the cell right of the current cell. A click with the right mouse button on a cell or a range of cells will open a popup menu, where you can edit attributes, clear attributes, delete text or define multicolumn cells."));
+ TQWhatsThis::add(m_table->horizontalHeader(),i18n("Current tqlayout of the preamble. A click with the right mouse button will open a popup menu, where you can edit some attributes of all cells, which belong to the selected columns."));
+ TQWhatsThis::add(m_table->verticalHeader(),i18n("A click with the right mouse button will open a popup menu, where you can edit some attributes of all cells, which belong to the selected rows."));
+ TQWhatsThis::add(m_coEnvironment,i18n("Choose an environment."));
+ TQWhatsThis::add(m_coParameter,i18n("Optional parameter for the chosen environment."));
+ TQWhatsThis::add(m_spRows,i18n("Choose the number of table rows."));
+ TQWhatsThis::add(m_spCols,i18n("Choose the number of table columns."));
+ TQWhatsThis::add(m_cbWarning,i18n("If you want, you will be asked before a non empty row a column is deleted."));
+ TQWhatsThis::add(m_cbCenter,i18n("The tabular will be centered."));
+ TQWhatsThis::add(m_cbBooktabs,i18n("Use line commands of the booktabs package."));
+ TQWhatsThis::add(m_cbStarred,i18n("Use the starred version of this environment."));
+ TQWhatsThis::add(m_cbBullets,i18n("Insert bullets in each cell. Alt+Ctrl+Right and Alt+Ctrl+Left will move very quick from one cell to another."));
}
void TabularDialog::initEnvironments(bool tabularenv)
{
// read all tabular environments and insert them into the combobox
- QStringList list;
- QStringList::ConstIterator it;
+ TQStringList list;
+ TQStringList::ConstIterator it;
m_latexCommands->commandList(list,KileDocument::CmdAttrTabular,false);
for ( it=list.begin(); it != list.end(); ++it )
{
@@ -1961,7 +1961,7 @@ void TabularDialog::initEnvironments(bool tabularenv)
////////////////////////////// table changed//////////////////////////////
-void TabularDialog::slotEnvironmentChanged(const QString &env)
+void TabularDialog::slotEnvironmentChanged(const TQString &env)
{
//KILE_DEBUG() << "env changed " << env << endl;
@@ -1977,14 +1977,14 @@ void TabularDialog::slotEnvironmentChanged(const QString &env)
m_cbStarred->setEnabled( attr.starred );
// option
- if ( attr.option.find('[') == 0 )
+ if ( attr.option.tqfind('[') == 0 )
{
- QStringList optionlist = QStringList::split("",attr.option);
+ TQStringList optionlist = TQStringList::split("",attr.option);
if ( optionlist.count() > 2 )
{
// ok, let's enable it
m_coParameter->setEnabled(true);
- m_coParameter->insertItem(QString::null);
+ m_coParameter->insertItem(TQString());
// insert some options
for ( uint i=1; i<optionlist.count()-1; ++i )
m_coParameter->insertItem(optionlist[i]);
@@ -1998,7 +1998,7 @@ void TabularDialog::slotEnvironmentChanged(const QString &env)
m_alignlist << "X";
}
-bool TabularDialog::isMathmodeEnvironment(const QString &env)
+bool TabularDialog::isMathmodeEnvironment(const TQString &env)
{
return m_latexCommands->isMathModeEnv(env);
}
@@ -2025,7 +2025,7 @@ void TabularDialog::slotRowValueChanged(int value)
if ( ! askBeforeDelete ) break;
if ( firstwarning )
{
- QString message = i18n("Do you want to delete this row?");
+ TQString message = i18n("Do you want to delete this row?");
if (KMessageBox::warningContinueCancel(this, message, i18n("Delete"))!=KMessageBox::Continue)
break;
firstwarning = false;
@@ -2060,7 +2060,7 @@ void TabularDialog::slotColValueChanged(int value)
if ( ! askBeforeDelete ) break;
if ( firstwarning )
{
- QString message = i18n("Do you want to delete this column?");
+ TQString message = i18n("Do you want to delete this column?");
if (KMessageBox::warningContinueCancel(this, message, i18n("Delete"))!=KMessageBox::Continue)
break;
firstwarning = false;
@@ -2078,21 +2078,21 @@ void TabularDialog::slotColValueChanged(int value)
}
-QStringList TabularDialog::columnAlignments()
+TQStringList TabularDialog::columnAlignments()
{
return m_alignlist;
}
////////////////////////////// color management//////////////////////////////
-char TabularDialog::defineColor(const QString &name, QMap<QString,char> &colors, char &colorcode)
+char TabularDialog::defineColor(const TQString &name, TQMap<TQString,char> &colors, char &colorcode)
{
if ( colorcode == '?' )
return '?';
// look for current color
- QMapIterator<QString,char> it;
- it = colors.find(name);
+ TQMapIterator<TQString,char> it;
+ it = colors.tqfind(name);
if ( it != colors.end() )
return (*it);
@@ -2105,14 +2105,14 @@ char TabularDialog::defineColor(const QString &name, QMap<QString,char> &colors,
return colors[name];
}
-QString TabularDialog::convertColor(int value)
+TQString TabularDialog::convertColor(int value)
{
if ( value == 0 )
return "0";
else if ( value == 255 )
return "1";
- QString s;
+ TQString s;
s = s.setNum( (float)value/256.0,'f',4);
while ( s.right(1) == "0" )
s.truncate( s.length()-1 );
@@ -2120,14 +2120,14 @@ QString TabularDialog::convertColor(int value)
return s;
}
-QStringList TabularDialog::sortColorTable(QMap<QString,char> &colors)
+TQStringList TabularDialog::sortColorTable(TQMap<TQString,char> &colors)
{
- QMapConstIterator<QString,char> it;
- QStringList list;
+ TQMapConstIterator<TQString,char> it;
+ TQStringList list;
int r,g,b;
- QColor c;
- QString s,sred,sgreen,sblue;
+ TQColor c;
+ TQString s,sred,sgreen,sblue;
for ( it=colors.begin(); it!=colors.end(); ++it )
{
c.setNamedColor(it.key());
@@ -2137,13 +2137,13 @@ QStringList TabularDialog::sortColorTable(QMap<QString,char> &colors)
sred = convertColor(r);
sgreen = convertColor(g);
sblue = convertColor(b);
- s = QString("{rgb}{%1,%2,%3}").arg(sred).arg(sgreen).arg(sblue);
+ s = TQString("{rgb}{%1,%2,%3}").tqarg(sred).tqarg(sgreen).tqarg(sblue);
}
else
{
- s = QString("{gray}{%1}").arg(convertColor(r));
+ s = TQString("{gray}{%1}").tqarg(convertColor(r));
}
- list << QString("\\definecolor{tc%1}%2").arg(it.data()).arg(s);
+ list << TQString("\\definecolor{tc%1}%2").tqarg(it.data()).tqarg(s);
}
list.sort();
@@ -2156,7 +2156,7 @@ void TabularDialog::slotOk()
{
m_table->updateCurrentCell();
- QString preamble,textline,s,s1,s2,s3;
+ TQString preamble,textline,s,s1,s2,s3;
TabularCell::CountLines lines;
TabularCell::Count cnt;
@@ -2170,28 +2170,28 @@ void TabularDialog::slotOk()
int numcols = m_table->numCols();
// colortable
- QMap<QString,char> colortable;
+ TQMap<TQString,char> colortable;
char colorchar = 'A';
// list with all column information
- QValueList<TabularCell::Preamble> colinfo;
- QString whitename = Qt::white.name();
- QString blackname = Qt::black.name();
+ TQValueList<TabularCell::Preamble> colinfo;
+ TQString whitename = TQt::white.name();
+ TQString blackname = TQt::black.name();
// is multicolumn command used
bool multicolumn = false;
// cursor and bullets
- QString bullet = ( m_cbBullets->isChecked() ) ? s_bullet : QString::null;
+ TQString bullet = ( m_cbBullets->isChecked() ) ? s_bullet : TQString();
bool setcursor = ( ! m_cbBullets->isChecked() );
// count all column information
- m_td.tagEnd = QString::null;
+ m_td.tagEnd = TQString();
for ( int col=0; col<=numcols; ++col )
{
TabularCell::Preamble info;
info.vline = false;
- info.align = Qt::AlignLeft;
+ info.align = TQt::AlignLeft;
// Now get column information for real columns.
// The last info is only needed for a right vline.
@@ -2211,16 +2211,16 @@ void TabularDialog::slotOk()
}
// search for left vlines all columns
- QHeader *hor = m_table->horizontalHeader();
+ TQHeader *hor = m_table->horizontalHeader();
for ( int col=0; col<numcols; ++col )
{
// get current header
s = hor->label(col).remove(' ');
- if ( s.find('>') || s.find('<') || s.find('!') || s.find('m') || s.find('b'))
+ if ( s.tqfind('>') || s.tqfind('<') || s.tqfind('!') || s.tqfind('m') || s.tqfind('b'))
pkgArray = true;
// look for @{} and !{} substrings
- bool separator = ( s.find('@')>=0 || s.find('!')>=0 );
+ bool separator = ( s.tqfind('@')>=0 || s.tqfind('!')>=0 );
if ( !separator )
{
lines = m_table->countVLines(col,true);
@@ -2232,36 +2232,36 @@ void TabularDialog::slotOk()
}
// color
- QString colorcommand = QString::null;
+ TQString colorcommand = TQString();
if ( colinfo[col].bgcolor != whitename )
{
- QChar color = defineColor(colinfo[col].bgcolor,colortable,colorchar);
- colorcommand += QString("\\columncolor{tc%1}").arg(color);
+ TQChar color = defineColor(colinfo[col].bgcolor,colortable,colorchar);
+ colorcommand += TQString("\\columncolor{tc%1}").tqarg(color);
pkgColortbl = true;
}
if ( colinfo[col].textcolor != blackname )
{
- QChar color = defineColor(colinfo[col].textcolor,colortable,colorchar);
- colorcommand += QString("\\color{tc%1}").arg(color);
+ TQChar color = defineColor(colinfo[col].textcolor,colortable,colorchar);
+ colorcommand += TQString("\\color{tc%1}").tqarg(color);
pkgColor = true;
}
if ( ! colorcommand.isEmpty() )
{
- if ( s.find('>') >= 0 )
- s = s.replace(">{}",QString(">{%1}").arg(colorcommand));
+ if ( s.tqfind('>') >= 0 )
+ s = s.tqreplace(">{}",TQString(">{%1}").tqarg(colorcommand));
else
- preamble += QString(">{%1}").arg(colorcommand);
+ preamble += TQString(">{%1}").tqarg(colorcommand);
pkgArray = true;
}
// Alignment: default is left, we look only for center or right
- if ( s.find('c') >= 0 )
- colinfo[col].align = Qt::AlignHCenter;
- else if ( s.find('r') >= 0 )
- colinfo[col].align = Qt::AlignRight;
+ if ( s.tqfind('c') >= 0 )
+ colinfo[col].align = TQt::AlignHCenter;
+ else if ( s.tqfind('r') >= 0 )
+ colinfo[col].align = TQt::AlignRight;
// pre >{} and post <{} commands can stay, but perhaps bullets are wanted
- preamble += ( m_cbBullets->isChecked() ) ? s.replace("{}", '{' + s_bullet + '}') : s;
+ preamble += ( m_cbBullets->isChecked() ) ? s.tqreplace("{}", '{' + s_bullet + '}') : s;
}
// search for right vline in last column
lines = m_table->countVLines( numcols-1,false );
@@ -2277,15 +2277,15 @@ void TabularDialog::slotOk()
// output all rows
for ( int row=0; row<numrows; ++row )
{
- textline = QString::null;
+ textline = TQString();
// first check for a rowcolor command
cnt = m_table->countCells(0,row,numcols-1,row);
- QString bgcolor = ( cnt.bgcolor > cnt.cells/2 ) ? cnt.nameBgcolor : whitename;
+ TQString bgcolor = ( cnt.bgcolor > cnt.cells/2 ) ? cnt.nameBgcolor : whitename;
if ( bgcolor != whitename )
{
- QChar color = defineColor(cnt.nameBgcolor,colortable,colorchar);
- textline += QString("\\rowcolor{tc%1}\n").arg(color);
+ TQChar color = defineColor(cnt.nameBgcolor,colortable,colorchar);
+ textline += TQString("\\rowcolor{tc%1}\n").tqarg(color);
pkgColortbl = true;
}
@@ -2297,11 +2297,11 @@ void TabularDialog::slotOk()
{
// check for multicolumn and initialize string parameter
int colspan = cellitem->colSpan();
- s1 = ( colspan > 1 ) ? QString("%1").arg(colspan) : QString::null;
- s2 = s3 = QString::null;
+ s1 = ( colspan > 1 ) ? TQString("%1").tqarg(colspan) : TQString();
+ s2 = s3 = TQString();
// Now look, if this cell(s) must be defined as multicolumn, because
- // colspan is greater than 1, or the left vline, bgcolor or alignment
+ // colspan is greater than 1, or the left vline, bgcolor or tqalignment
// is different from the preamble
bool useMulticolumn =
( ( colspan > 1 ) ||
@@ -2324,16 +2324,16 @@ void TabularDialog::slotOk()
// (colinfo[col].bgcolor==whitename) ) ) {
if ( cellitem->m_data.bgcolor.name() != whitename )
{
- QChar color = defineColor(cellitem->m_data.bgcolor.name(),colortable,colorchar);
- s2 += QString(">{\\columncolor{tc%1}}").arg(color);
+ TQChar color = defineColor(cellitem->m_data.bgcolor.name(),colortable,colorchar);
+ s2 += TQString(">{\\columncolor{tc%1}}").tqarg(color);
pkgColortbl = true;
}
- // alignment
+ // tqalignment
//if ( cellitem->m_data.align!=colinfo[col].align ) {
switch ( cellitem->m_data.align )
{
- case Qt::AlignHCenter : s2 += 'c'; break;
- case Qt::AlignRight : s2 += 'r'; break;
+ case TQt::AlignHCenter : s2 += 'c'; break;
+ case TQt::AlignRight : s2 += 'r'; break;
default : s2 += 'l';
}
// we have to set a right line in a multicolumn cell
@@ -2350,13 +2350,13 @@ void TabularDialog::slotOk()
}
if ( colinfo[col].italic != (cellitem->m_data.font & TabularCell::cfItalic) )
{
- s3 += "\\itshape";
+ s3 += "\\ittqshape";
}
if ( colinfo[col].textcolor != cellitem->m_data.textcolor.name() )
{
- QChar color = defineColor(cellitem->m_data.textcolor.name(),colortable,colorchar);
- s3 += QString("\\color{tc%1}").arg(color);
+ TQChar color = defineColor(cellitem->m_data.textcolor.name(),colortable,colorchar);
+ s3 += TQString("\\color{tc%1}").tqarg(color);
pkgColor = true;
}
if ( ! s3.isEmpty() )
@@ -2379,7 +2379,7 @@ void TabularDialog::slotOk()
// build the whole cell entry
if ( useMulticolumn )
{
- textline += QString("\\mc{%1}{%2}{%3}").arg(colspan).arg(s2).arg(s3);
+ textline += TQString("\\mc{%1}{%2}{%3}").tqarg(colspan).tqarg(s2).tqarg(s3);
multicolumn = true;
}
else
@@ -2413,14 +2413,14 @@ void TabularDialog::slotOk()
}
// build the list of colors
- QStringList colorlist = sortColorTable(colortable);
+ TQStringList colorlist = sortColorTable(colortable);
bool group = ( multicolumn || colorlist.count()>0 );
// get current environment
- QString envname = m_coEnvironment->currentText();
+ TQString envname = m_coEnvironment->currentText();
// build a list of packages
- QString packagelist = QString::null;
+ TQString packagelist = TQString();
if ( pkgColortbl )
pkgColor = true;
@@ -2435,21 +2435,21 @@ void TabularDialog::slotOk()
if ( envname=="tabularx" || envname=="longtable" || envname=="supertabular" )
packagelist += ',' + envname;
if ( ! packagelist.isEmpty() ) {
- packagelist = packagelist.replace(0,1,"% use packages: ") + '\n';
+ packagelist = packagelist.tqreplace(0,1,"% use packages: ") + '\n';
}
// get environment names
- QString centername = ( isMathmodeEnvironment(envname) ) ? "displaymath" : "center";
+ TQString centername = ( isMathmodeEnvironment(envname) ) ? "displaymath" : "center";
if ( m_cbStarred->isChecked() )
envname += '*';
// build the tag to insert
if ( m_cbCenter->isChecked() )
- m_td.tagBegin = QString("\\begin{%1}\n").arg(centername);
+ m_td.tagBegin = TQString("\\begin{%1}\n").tqarg(centername);
else if ( group )
m_td.tagBegin = "{% \n";
else
- m_td.tagBegin = QString::null;
+ m_td.tagBegin = TQString();
// add list of packages as comment
m_td.tagBegin += packagelist;
@@ -2468,22 +2468,22 @@ void TabularDialog::slotOk()
}
// add environment command
- m_td.tagBegin += QString("\\begin{%1}").arg(envname);
+ m_td.tagBegin += TQString("\\begin{%1}").tqarg(envname);
// add width for starred versions
if ( m_cbStarred->isChecked() )
- m_td.tagBegin += QString("{%1}").arg(bullet);
- // add optional alignment parameter
- QString envparameter = ( m_coParameter->isEnabled() ) ? m_coParameter->currentText() : QString::null;
+ m_td.tagBegin += TQString("{%1}").tqarg(bullet);
+ // add optional tqalignment parameter
+ TQString envparameter = ( m_coParameter->isEnabled() ) ? m_coParameter->currentText() : TQString();
if ( ! envparameter.isEmpty() )
- m_td.tagBegin += QString("[%1]").arg(envparameter);
+ m_td.tagBegin += TQString("[%1]").tqarg(envparameter);
// add preamble
- m_td.tagBegin += QString("{%1}").arg(preamble);
+ m_td.tagBegin += TQString("{%1}").tqarg(preamble);
m_td.tagBegin += getEol(0,true) + '\n';
// close environment
- m_td.tagEnd += QString("\\end{%1}\n").arg(envname);
+ m_td.tagEnd += TQString("\\end{%1}\n").tqarg(envname);
if ( m_cbCenter->isChecked() )
- m_td.tagEnd += QString("\\end{%1}\n").arg(centername);
+ m_td.tagEnd += TQString("\\end{%1}\n").tqarg(centername);
else if ( group )
m_td.tagEnd += "}\n";
@@ -2493,18 +2493,18 @@ void TabularDialog::slotOk()
// set cursor to first bullet position
if ( m_cbBullets->isChecked() )
{
- int pos = m_td.tagBegin.find(bullet);
+ int pos = m_td.tagBegin.tqfind(bullet);
if ( pos >= 0 )
{
- m_td.tagBegin = m_td.tagBegin.replace(pos,1,"%C");
+ m_td.tagBegin = m_td.tagBegin.tqreplace(pos,1,"%C");
setcursor = false;
}
else
{
- pos = m_td.tagEnd.find(bullet);
+ pos = m_td.tagEnd.tqfind(bullet);
if ( pos >= 0 )
{
- m_td.tagEnd = m_td.tagEnd.replace(pos,1,"%C");
+ m_td.tagEnd = m_td.tagEnd.tqreplace(pos,1,"%C");
setcursor = false;
}
else
@@ -2519,9 +2519,9 @@ void TabularDialog::slotOk()
accept();
}
-QString TabularDialog::getEol(int row, bool top)
+TQString TabularDialog::getEol(int row, bool top)
{
- QString s;
+ TQString s;
bool booktabs = m_cbBooktabs->isChecked();
TabularCell::CountLines lines = m_table->countHLines(row,top);
@@ -2541,9 +2541,9 @@ QString TabularDialog::getEol(int row, bool top)
}
else if ( lines.list.count() > 0 )
{
- QString cmd = ( booktabs ) ? "cmidrule" : "cline";
+ TQString cmd = ( booktabs ) ? "cmidrule" : "cline";
for ( uint i=0; i<lines.list.count(); i+=2 )
- s += QString("\\%1{%2-%3}").arg(cmd).arg(lines.list[i]+1).arg(lines.list[i+1]+1);
+ s += TQString("\\%1{%2-%3}").tqarg(cmd).tqarg(lines.list[i]+1).tqarg(lines.list[i+1]+1);
}
return s;
diff --git a/src/kile/tabulardialog.h b/src/kile/tabulardialog.h
index 9ce74f8..4b7b939 100644
--- a/src/kile/tabulardialog.h
+++ b/src/kile/tabulardialog.h
@@ -22,16 +22,16 @@
#include "kilewizard.h"
#include "latexcmd.h"
-#include <qevent.h>
-#include <qpainter.h>
-#include <qtable.h>
-#include <qcheckbox.h>
-#include <qradiobutton.h>
-#include <qcombobox.h>
-#include <qspinbox.h>
-#include <qregexp.h>
-#include <qvalidator.h>
-#include <qpopupmenu.h>
+#include <tqevent.h>
+#include <tqpainter.h>
+#include <tqtable.h>
+#include <tqcheckbox.h>
+#include <tqradiobutton.h>
+#include <tqcombobox.h>
+#include <tqspinbox.h>
+#include <tqregexp.h>
+#include <tqvalidator.h>
+#include <tqpopupmenu.h>
#include <kdialogbase.h>
#include <kcolorcombo.h>
@@ -50,8 +50,8 @@ namespace TabularCell
int align;
int font;
int border;
- QColor bgcolor;
- QColor textcolor;
+ TQColor bgcolor;
+ TQColor textcolor;
};
struct Count
@@ -61,8 +61,8 @@ namespace TabularCell
int bgcolor;
int textcolor;
int cells;
- QString nameBgcolor;
- QString nameTextcolor;
+ TQString nameBgcolor;
+ TQString nameTextcolor;
};
struct Preamble
@@ -71,50 +71,52 @@ namespace TabularCell
bool bold;
bool italic;
int align;
- QString bgcolor;
- QString textcolor;
+ TQString bgcolor;
+ TQString textcolor;
};
struct CountLines
{
int cnt;
int cells;
- QValueList<int> list;
+ TQValueList<int> list;
};
}
-class TabCellFrame : public QFrame
+class TabCellFrame : public TQFrame
{
Q_OBJECT
+ TQ_OBJECT
public:
- TabCellFrame(QWidget* parent);
+ TabCellFrame(TQWidget* tqparent);
void setBorder(int value);
int border() { return m_border; }
protected:
- void drawContents(QPainter *p);
- void mousePressEvent(QMouseEvent *event);
- void mouseDoubleClickEvent(QMouseEvent *event);
+ void drawContents(TQPainter *p);
+ void mousePressEvent(TQMouseEvent *event);
+ void mouseDoubleClickEvent(TQMouseEvent *event);
private:
int m_border;
- QRect m_left,m_top,m_right,m_bottom;
+ TQRect m_left,m_top,m_right,m_bottom;
};
class TabCellDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- TabCellDialog(QWidget *parent, TabularCell::Data *data,
- const QString &headerlabel, const QStringList &alignlist);
+ TabCellDialog(TQWidget *tqparent, TabularCell::Data *data,
+ const TQString &headerlabel, const TQStringList &alignlist);
~TabCellDialog() {}
TabularCell::Data data();
- QString header();
+ TQString header();
private slots:
void slotFramebuttonClicked();
@@ -122,18 +124,18 @@ private slots:
void slotResetClicked();
private:
- QComboBox *m_coHeader;
- QCheckBox *m_cbBold, *m_cbItalic;
- QRadioButton *m_rbAlignleft, *m_rbAligncenter, *m_rbAlignright;
+ TQComboBox *m_coHeader;
+ TQCheckBox *m_cbBold, *m_cbItalic;
+ TQRadioButton *m_rbAlignleft, *m_rbAligncenter, *m_rbAlignright;
KColorCombo *m_ccBgcolor, *m_ccTextcolor;
KPushButton *m_pbFrame1,*m_pbFrame2,*m_pbFrame3,*m_pbFrame4;
- QCheckBox *m_cbPre, *m_cbPost, *m_cbAt, *m_cbSep;
+ TQCheckBox *m_cbPre, *m_cbPost, *m_cbAt, *m_cbSep;
TabCellFrame *m_cellframe;
TabularCell::Data m_data;
bool m_header;
- QString m_headerlabel;
- QStringList m_preamblelist;
+ TQString m_headerlabel;
+ TQStringList m_preamblelist;
void initWidgets();
void initWidgetData();
@@ -141,36 +143,37 @@ private:
//////////////////////////////////////////////////////////////////////
-class TabularItem :public QTableItem
+class TabularItem :public TQTableItem
{
public:
- TabularItem(QTable* table);
- TabularItem(QTable* table, const TabularCell::Data &data);
+ TabularItem(TQTable* table);
+ TabularItem(TQTable* table, const TabularCell::Data &data);
- int alignment() const;
+ int tqalignment() const;
bool isDefault();
bool isMulticolumn();
- void paint(QPainter *p,const QColorGroup &cg,const QRect &cr,bool selected);
+ void paint(TQPainter *p,const TQColorGroup &cg,const TQRect &cr,bool selected);
TabularCell::Data m_data;
};
class TabularDialog;
-class TabularTable : public QTable
+class TabularTable : public TQTable
{
Q_OBJECT
+ TQ_OBJECT
public:
- TabularTable(int numRows,int numCols,QWidget* parent, TabularDialog *tabdialog);
+ TabularTable(int numRows,int numCols,TQWidget* tqparent, TabularDialog *tabdialog);
- void setText(int row,int col,const QString &text);
- void setAlignment(int row,int col,int align);
+ void setText(int row,int col,const TQString &text);
+ void tqsetAlignment(int row,int col,int align);
TabularCell::Data defaultAttributes();
bool isMulticolumn(int row,int col);
- void paintCell( QPainter *p, int row, int col,
- const QRect &cr, bool selected, const QColorGroup &cg );
+ void paintCell( TQPainter *p, int row, int col,
+ const TQRect &cr, bool selected, const TQColorGroup &cg );
void updateCurrentCell();
bool isRowEmpty(int row);
@@ -185,7 +188,7 @@ public:
TabularCell::CountLines countVLines(int col, bool left);
protected:
- void endEdit(int row,int col,bool accept,bool replace);
+ void endEdit(int row,int col,bool accept,bool tqreplace);
void activateNextCell();
private:
@@ -200,12 +203,12 @@ private:
void setAttributes(int row,int col,const TabularCell::Data &data);
void clearAttributes(int row,int col);
void cellParameterDialog(int x1,int y1,int x2,int y2, TabularCell::Data *data,
- const QString &headerlabel);
+ const TQString &headerlabel);
bool equalParameter(int x1,int y1,int x2,int y2, int code);
void mouseContextHorizontalHeader(int pos);
void mouseContextVerticalHeader(int pos);
- void updateHeaderAlignment(int col1,int col2,QChar alignchar);
+ void updateHeaderAlignment(int col1,int col2,TQChar alignchar);
bool getCurrentSelection(int &x1,int &y1,int &x2,int &y2);
void clearSelectionCells(bool cleartext,bool clearattributes);
@@ -214,14 +217,14 @@ private:
void setCellrangeAlignment(int x1,int y1,int x2,int y2,int align);
void setCellrangeAttributes(int x1,int y1,int x2,int y2,const TabularCell::Data &data);
- void setColspan(int row,int col1,int col2,int numcols,const QString &text);
+ void setColspan(int row,int col1,int col2,int numcols,const TQString &text);
void getCellRange(int row,int col1, int col2, int &xl, int &xr);
- QString getCellRangeText(int row,int col1, int col2);
+ TQString getCellRangeText(int row,int col1, int col2);
- QPopupMenu *createPopupMenu();
- void insertPopupAlign(QPopupMenu *popup,bool header);
- void insertPopupClear(QPopupMenu *popup);
- int popupId(QPopupMenu *popup, int id);
+ TQPopupMenu *createPopupMenu();
+ void insertPopupAlign(TQPopupMenu *popup,bool header);
+ void insertPopupClear(TQPopupMenu *popup);
+ int popupId(TQPopupMenu *popup, int id);
void cellPopupEdit();
void cellPopupSetMulticolumn();
@@ -230,23 +233,23 @@ private:
void setupContextHeaderPopup(bool horizontal, int section);
void headerPopupEdit();
- void headerPopupAlign(QChar alignchar);
+ void headerPopupAlign(TQChar alignchar);
bool m_horizontal;
int m_section;
int m_x1,m_y1,m_x2,m_y2;
- QPopupMenu *m_headerpopup;
- QPopupMenu *m_cellpopup;
+ TQPopupMenu *m_headerpopup;
+ TQPopupMenu *m_cellpopup;
TabularDialog *m_tabdialog;
private slots:
- void slotContextMenuClicked(int row,int col,const QPoint &);
+ void slotContextMenuClicked(int row,int col,const TQPoint &);
void slotCellPopupActivated(int id);
void slotHeaderPopupActivated(int id);
protected:
- bool eventFilter(QObject *o, QEvent *e);
+ bool eventFilter(TQObject *o, TQEvent *e);
};
@@ -254,11 +257,12 @@ protected:
class TabularDialog : public Wizard
{
Q_OBJECT
+ TQ_OBJECT
public:
- TabularDialog(QWidget *parent, KConfig *config, KileDocument::LatexCommands *commands, bool tabularenv= true);
+ TabularDialog(TQWidget *tqparent, KConfig *config, KileDocument::LatexCommands *commands, bool tabularenv= true);
~TabularDialog() {}
- QStringList columnAlignments();
+ TQStringList columnAlignments();
public slots:
void slotOk();
@@ -266,29 +270,29 @@ public slots:
private slots:
void slotColValueChanged(int value);
- void slotEnvironmentChanged(const QString &env);
+ void slotEnvironmentChanged(const TQString &env);
private:
KileDocument::LatexCommands *m_latexCommands;
TabularTable *m_table;
- QComboBox *m_coEnvironment, *m_coParameter;
- QSpinBox *m_spRows, *m_spCols;
- QCheckBox *m_cbWarning, *m_cbBullets, *m_cbStarred;
- QCheckBox *m_cbCenter, *m_cbBooktabs;
+ TQComboBox *m_coEnvironment, *m_coParameter;
+ TQSpinBox *m_spRows, *m_spCols;
+ TQCheckBox *m_cbWarning, *m_cbBullets, *m_cbStarred;
+ TQCheckBox *m_cbCenter, *m_cbBooktabs;
int m_rows;
int m_cols;
void initEnvironments(bool tabularenv);
- bool isMathmodeEnvironment(const QString &env);
+ bool isMathmodeEnvironment(const TQString &env);
- QStringList m_alignlist;
+ TQStringList m_alignlist;
- QStringList sortColorTable(QMap<QString,char> &colors);
- QString convertColor(int value);
- char defineColor(const QString &name, QMap<QString,char> &colors, char &colorcode);
- QString getEol(int row,bool top);
+ TQStringList sortColorTable(TQMap<TQString,char> &colors);
+ TQString convertColor(int value);
+ char defineColor(const TQString &name, TQMap<TQString,char> &colors, char &colorcode);
+ TQString getEol(int row,bool top);
};
}
diff --git a/src/kile/templates.cpp b/src/kile/templates.cpp
index 3a76962..c82af0b 100644
--- a/src/kile/templates.cpp
+++ b/src/kile/templates.cpp
@@ -25,10 +25,10 @@
#include <kio/netaccess.h>
#include <kmessagebox.h>
-#include <qdir.h>
-#include <qfileinfo.h>
-#include <qstringlist.h>
-#include <qregexp.h>
+#include <tqdir.h>
+#include <tqfileinfo.h>
+#include <tqstringlist.h>
+#include <tqregexp.h>
#include "kileinfo.h"
@@ -56,15 +56,15 @@ bool Info::operator==(const Info ti) const
////////////////////// Manager //////////////////////
-Manager::Manager(KileInfo* kileInfo, QObject* parent, const char* name) : QObject(parent, name), m_kileInfo(kileInfo)
+Manager::Manager(KileInfo* kileInfo, TQObject* tqparent, const char* name) : TQObject(tqparent, name), m_kileInfo(kileInfo)
{
}
Manager::~Manager() {
}
-bool Manager::copyAppData(const KURL& src, const QString& subdir, const QString& fileName) {
- QString dir;
+bool Manager::copyAppData(const KURL& src, const TQString& subdir, const TQString& fileName) {
+ TQString dir;
//let saveLocation find and create the appropriate place to
//store the templates (usually $HOME/.kde/share/apps/kile/templates)
dir = KGlobal::dirs()->saveLocation("appdata", subdir, true);
@@ -76,20 +76,20 @@ bool Manager::copyAppData(const KURL& src, const QString& subdir, const QString&
return KIO::NetAccess::copy(src, targetURL, kapp->mainWidget());
}
else {
- KMessageBox::error(0, i18n("Could not find a folder to save %1 to.\nCheck whether you have a .kde folder with write permissions in your home folder.").arg(fileName));
+ KMessageBox::error(0, i18n("Could not find a folder to save %1 to.\nCheck whether you have a .kde folder with write permissions in your home folder.").tqarg(fileName));
return false;
}
}
-bool Manager::removeAppData(const QString &file) {
- QFileInfo fileInfo(file);
+bool Manager::removeAppData(const TQString &file) {
+ TQFileInfo fileInfo(file);
if(fileInfo.exists()) {
return KIO::NetAccess::del(KURL::fromPathOrURL(file), kapp->mainWidget());
}
return true;
}
-bool Manager::searchForTemplate(const QString& name, KileDocument::Type& type) const {
+bool Manager::searchForTemplate(const TQString& name, KileDocument::Type& type) const {
for (KileTemplate::TemplateListConstIterator i = m_TemplateList.constBegin(); i != m_TemplateList.constEnd(); ++i)
{
KileTemplate::Info info = *i;
@@ -100,15 +100,15 @@ bool Manager::searchForTemplate(const QString& name, KileDocument::Type& type) c
return false;
}
-bool Manager::add(const KURL& templateSourceURL, const QString& name, const KURL& icon) {
+bool Manager::add(const KURL& templateSourceURL, const TQString& name, const KURL& icon) {
KileDocument::Extensions *extensions = m_kileInfo->extensions();
KileDocument::Type type = extensions->determineDocumentType(templateSourceURL);
return add(templateSourceURL, type, name, icon);
}
-bool Manager::add(const KURL& templateSourceURL, KileDocument::Type type, const QString& name, const KURL& icon) {
+bool Manager::add(const KURL& templateSourceURL, KileDocument::Type type, const TQString& name, const KURL& icon) {
KileDocument::Extensions *extensions = m_kileInfo->extensions();
- QString extension = extensions->defaultExtensionForDocumentType(type);
+ TQString extension = extensions->defaultExtensionForDocumentType(type);
return copyAppData(templateSourceURL, "templates", "template_" + name + extension) && copyAppData(icon, "pics", "type_" + name + extension + ".kileicon");
}
@@ -117,11 +117,11 @@ bool Manager::remove(Info ti) {
return removeAppData(ti.path) && removeAppData(ti.icon);
}
-bool Manager::replace(const KileTemplate::Info& toBeReplaced, const KURL& newTemplateSourceURL, const QString& newName, const KURL& newIcon) {
+bool Manager::tqreplace(const KileTemplate::Info& toBeReplaced, const KURL& newTemplateSourceURL, const TQString& newName, const KURL& newIcon) {
KileDocument::Type type = m_kileInfo->extensions()->determineDocumentType(newTemplateSourceURL);
//start by copying the files that belong to the new template to a safe place
- QString templateTempFile, iconTempFile;
+ TQString templateTempFile, iconTempFile;
if(!KIO::NetAccess::download(newTemplateSourceURL, templateTempFile, kapp->mainWidget())) {
return false;
@@ -152,23 +152,23 @@ bool Manager::replace(const KileTemplate::Info& toBeReplaced, const KURL& newTem
void Manager::scanForTemplates() {
KILE_DEBUG() << "===scanForTemplates()===================" << endl;
- QStringList dirs = KGlobal::dirs()->findDirs("appdata", "templates");
- QDir templates;
+ TQStringList dirs = KGlobal::dirs()->findDirs("appdata", "templates");
+ TQDir templates;
KileTemplate::Info ti;
KileDocument::Extensions *extensions = m_kileInfo->extensions();
m_TemplateList.clear();
- for ( QValueListIterator<QString> i = dirs.begin(); i != dirs.end(); ++i)
+ for ( TQValueListIterator<TQString> i = dirs.begin(); i != dirs.end(); ++i)
{
- templates = QDir(*i, "template_*");
+ templates = TQDir(*i, "template_*");
for ( uint j = 0; j< templates.count(); ++j)
{
ti.path = templates.path() + '/' + templates[j];
- QFileInfo fileInfo(ti.path);
+ TQFileInfo fileInfo(ti.path);
ti.name = fileInfo.baseName(true).mid(9); //remove "template_", do it this way to avoid problems with user input!
ti.type = extensions->determineDocumentType(KURL::fromPathOrURL(ti.path));
ti.icon = KGlobal::dirs()->findResource("appdata","pics/type_" + ti.name + extensions->defaultExtensionForDocumentType(ti.type) + ".kileicon");
- if (m_TemplateList.contains(ti))
+ if (m_TemplateList.tqcontains(ti))
{
KILE_DEBUG() << "\tignoring: " << ti.path << endl;
}
@@ -207,13 +207,13 @@ TemplateList Manager::getTemplates(KileDocument::Type type) const {
// new compare function to make the "Empty (...) Document" items appear at the beginning
-TemplateItem::TemplateItem(QIconView * parent, const KileTemplate::Info& info) : QIconViewItem(parent,info.name, QPixmap(info.icon))
+TemplateItem::TemplateItem(TQIconView * tqparent, const KileTemplate::Info& info) : TQIconViewItem(tqparent,info.name, TQPixmap(info.icon))
{
setDragEnabled(false);
m_info = info;
}
-int TemplateItem::compare( QIconViewItem *i ) const
+int TemplateItem::compare( TQIconViewItem *i ) const
{
if ( key() == DEFAULT_EMPTY_CAPTION ) {
return -1;
@@ -228,13 +228,13 @@ int TemplateItem::compare( QIconViewItem *i ) const
////////////////////// TemplateIconView //////////////////////
-TemplateIconView::TemplateIconView(QWidget *parent, const char *name, WFlags f) : KIconView(parent, name, f), m_templateManager(NULL), m_proc(NULL) {
+TemplateIconView::TemplateIconView(TQWidget *tqparent, const char *name, WFlags f) : KIconView(tqparent, name, f), m_templateManager(NULL), m_proc(NULL) {
setItemsMovable(false);
setMode(KIconView::Select);
- setResizeMode(QIconView::Adjust);
- setSelectionMode(QIconView::Single);
- setResizePolicy(QScrollView::Default);
- setArrangement(QIconView::TopToBottom);
+ setResizeMode(TQIconView::Adjust);
+ setSelectionMode(TQIconView::Single);
+ setResizePolicy(TQScrollView::Default);
+ setArrangement(TQIconView::TopToBottom);
setMinimumHeight(100);
}
@@ -264,22 +264,22 @@ void TemplateIconView::searchLaTeXClassFiles()
{
if(!m_templateManager) return;
- QString command = "kpsewhich -format=tex scrartcl.cls beamer.cls prosper.cls HA-prosper.sty";
+ TQString command = "kpsewhich -format=tex scrartcl.cls beamer.cls prosper.cls HA-prosper.sty";
delete m_proc;
- m_proc = new KProcess(this);
+ m_proc = new KProcess(TQT_TQOBJECT(this));
m_proc->clearArguments();
m_proc->setUseShell(true);
- (*m_proc) << QStringList::split(' ', command);
- m_output = QString::null;
+ (*m_proc) << TQStringList::split(' ', command);
+ m_output = TQString();
- connect(m_proc, SIGNAL(receivedStdout(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(receivedStderr(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(processExited(KProcess*)),
- this, SLOT(slotProcessExited(KProcess*)) );
+ connect(m_proc, TQT_SIGNAL(receivedStdout(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(receivedStderr(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(processExited(KProcess*)),
+ this, TQT_SLOT(slotProcessExited(KProcess*)) );
KILE_DEBUG() << "=== NewFileWidget::searchClassFiles() ====================" << endl;
KILE_DEBUG() << "\texecute: " << command << endl;
@@ -292,13 +292,13 @@ void TemplateIconView::searchLaTeXClassFiles()
void TemplateIconView::slotProcessOutput(KProcess*, char* buf, int len)
{
- m_output += QString::fromLocal8Bit(buf,len);
+ m_output += TQString::fromLocal8Bit(buf,len);
}
void TemplateIconView::slotProcessExited(KProcess *proc)
{
if ( ! proc->normalExit() )
- m_output = QString::null;
+ m_output = TQString();
addTemplateIcons(KileDocument::LaTeX);
emit classFileSearchFinished();
@@ -308,7 +308,7 @@ void TemplateIconView::addTemplateIcons(KileDocument::Type type)
{
if(!m_templateManager) return;
- QString emptyIcon = KGlobal::dirs()->findResource("appdata", "pics/"+ QString(DEFAULT_EMPTY_ICON) + ".png" );
+ TQString emptyIcon = KGlobal::dirs()->findResource("appdata", "pics/"+ TQString(DEFAULT_EMPTY_ICON) + ".png" );
KileTemplate::Info emptyDocumentInfo;
emptyDocumentInfo.name = DEFAULT_EMPTY_CAPTION;
@@ -319,7 +319,7 @@ void TemplateIconView::addTemplateIcons(KileDocument::Type type)
if(type == KileDocument::LaTeX) {
// disable non standard templates
- QMap<QString,bool> map;
+ TQMap<TQString,bool> map;
map["Scrartcl"] = false;
map["Scrbook"] = false;
map["Scrreprt"] = false;
@@ -329,10 +329,10 @@ void TemplateIconView::addTemplateIcons(KileDocument::Type type)
map["HA-prosper"] = false;
// split search results and look, which class files are present
- QStringList list = QStringList::split("\n",m_output);
- for ( QStringList::Iterator it=list.begin(); it!=list.end(); ++it )
+ TQStringList list = TQStringList::split("\n",m_output);
+ for ( TQStringList::Iterator it=list.begin(); it!=list.end(); ++it )
{
- QString filename = QFileInfo(*it).fileName();
+ TQString filename = TQFileInfo(*it).fileName();
if ( filename=="scrartcl.cls" )
{
map["Scrartcl"] = true;
@@ -355,8 +355,8 @@ void TemplateIconView::addTemplateIcons(KileDocument::Type type)
for (KileTemplate::TemplateListIterator i=templateList.begin(); i != templateList.end(); ++i)
{
KileTemplate::Info info = *i;
- QString classname = info.name;
- if ( !map.contains(classname) || map[classname]==true )
+ TQString classname = info.name;
+ if ( !map.tqcontains(classname) || map[classname]==true )
{
new TemplateItem(this, info);
}
@@ -374,7 +374,7 @@ void TemplateIconView::addTemplateIcons(KileDocument::Type type)
sort();
// set the default item, if its given
- for ( QIconViewItem *item = firstItem(); item; item = item->nextItem() ) {
+ for ( TQIconViewItem *item = firstItem(); item; item = item->nextItem() ) {
if ( static_cast<TemplateItem*>(item)->name() == m_selicon ) {
setSelected(item, true);
ensureItemVisible(item);
diff --git a/src/kile/templates.h b/src/kile/templates.h
index 806f416..1daa18f 100644
--- a/src/kile/templates.h
+++ b/src/kile/templates.h
@@ -27,8 +27,8 @@
#include <kprocess.h>
#include <kurl.h>
-#include <qobject.h>
-#include <qvaluelist.h>
+#include <tqobject.h>
+#include <tqvaluelist.h>
#include "kileconstants.h"
@@ -42,23 +42,24 @@ struct Info {
public:
Info();
- QString name;
- QString path;
- QString icon;
+ TQString name;
+ TQString path;
+ TQString icon;
KileDocument::Type type;
bool operator==(const Info ti) const;
};
-typedef QValueList<Info> TemplateList;
-typedef QValueListIterator<Info> TemplateListIterator;
-typedef QValueListConstIterator<Info> TemplateListConstIterator;
+typedef TQValueList<Info> TemplateList;
+typedef TQValueListIterator<Info> TemplateListIterator;
+typedef TQValueListConstIterator<Info> TemplateListConstIterator;
-class Manager : public QObject {
+class Manager : public TQObject {
Q_OBJECT
+ TQ_OBJECT
public:
- Manager(KileInfo *info, QObject* parent = NULL, const char* name = NULL);
+ Manager(KileInfo *info, TQObject* tqparent = NULL, const char* name = NULL);
virtual ~Manager();
void scanForTemplates();
@@ -81,29 +82,29 @@ class Manager : public QObject {
*
* @return true iff a template with the given name and type could be found
**/
- bool searchForTemplate(const QString& name, KileDocument::Type& type) const;
+ bool searchForTemplate(const TQString& name, KileDocument::Type& type) const;
//add a template in $HOME/kile/templates/
- bool add(const KURL& templateSourceURL, const QString& name, const KURL& icon);
+ bool add(const KURL& templateSourceURL, const TQString& name, const KURL& icon);
//remove a template from $HOME/kile/templates/
bool remove(KileTemplate::Info ti);
//replaces a template
- bool replace(const KileTemplate::Info& toBeReplaced, const KURL& newTemplateSourceURL, const QString& newName, const KURL& newIcon);
+ bool tqreplace(const KileTemplate::Info& toBeReplaced, const KURL& newTemplateSourceURL, const TQString& newName, const KURL& newIcon);
protected:
KileInfo* m_kileInfo;
private:
- bool copyAppData(const KURL& src, const QString& subdir, const QString& fileName);
- bool removeAppData(const QString &file);
+ bool copyAppData(const KURL& src, const TQString& subdir, const TQString& fileName);
+ bool removeAppData(const TQString &file);
/**
* Adds a new template. This method differs from the other add method in that it does not try to determine
* the type of the template from the passed source URL.
**/
- bool add(const KURL& templateSourceURL, KileDocument::Type type, const QString& name, const KURL& icon);
+ bool add(const KURL& templateSourceURL, KileDocument::Type type, const TQString& name, const KURL& icon);
private:
@@ -112,21 +113,21 @@ class Manager : public QObject {
}
-const QString DEFAULT_EMPTY_CAPTION = i18n("Empty Document");
-const QString DEFAULT_EMPTY_LATEX_CAPTION = i18n("Empty LaTeX Document");
-const QString DEFAULT_EMPTY_BIBTEX_CAPTION = i18n("Empty BibTeX Document");
+const TQString DEFAULT_EMPTY_CAPTION = i18n("Empty Document");
+const TQString DEFAULT_EMPTY_LATEX_CAPTION = i18n("Empty LaTeX Document");
+const TQString DEFAULT_EMPTY_BIBTEX_CAPTION = i18n("Empty BibTeX Document");
-class TemplateItem : public QIconViewItem
+class TemplateItem : public TQIconViewItem
{
public:
- TemplateItem( QIconView * parent, const KileTemplate::Info & info);
+ TemplateItem( TQIconView * tqparent, const KileTemplate::Info & info);
~TemplateItem() {}
- int compare( QIconViewItem *i ) const;
+ int compare( TQIconViewItem *i ) const;
- QString name() { return m_info.name; }
- QString path() { return m_info.path; }
- QString icon() { return m_info.icon; }
+ TQString name() { return m_info.name; }
+ TQString path() { return m_info.path; }
+ TQString icon() { return m_info.icon; }
KileDocument::Type type() { return m_info.type; }
private:
@@ -135,9 +136,10 @@ private:
class TemplateIconView : public KIconView {
Q_OBJECT
+ TQ_OBJECT
public:
- TemplateIconView(QWidget *parent=0, const char *name=0, WFlags f=0);
+ TemplateIconView(TQWidget *tqparent=0, const char *name=0, WFlags f=0);
virtual ~TemplateIconView();
void setTemplateManager(KileTemplate::Manager *templateManager);
@@ -149,8 +151,8 @@ class TemplateIconView : public KIconView {
protected:
KileTemplate::Manager *m_templateManager;
- QString m_output;
- QString m_selicon;
+ TQString m_output;
+ TQString m_selicon;
KProcess *m_proc;
void addTemplateIcons(KileDocument::Type type);
diff --git a/src/kile/texdocdialog.cpp b/src/kile/texdocdialog.cpp
index 6b88a29..c685aca 100644
--- a/src/kile/texdocdialog.cpp
+++ b/src/kile/texdocdialog.cpp
@@ -18,16 +18,16 @@
#include "texdocdialog.h"
-#include <qlayout.h>
-#include <qstringlist.h>
-#include <qfile.h>
-#include <qfileinfo.h>
-#include <qtextstream.h>
-#include <qgroupbox.h>
-#include <qregexp.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqstringlist.h>
+#include <tqfile.h>
+#include <tqfileinfo.h>
+#include <tqtextstream.h>
+#include <tqgroupbox.h>
+#include <tqregexp.h>
+#include <tqwhatsthis.h>
#include <kapplication.h>
-#include <qdesktopwidget.h>
+#include <tqdesktopwidget.h>
#include <kurl.h>
#include <krun.h>
@@ -47,8 +47,8 @@ namespace KileDialog
//BEGIN TexDocDialog
-TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
- : KDialogBase( parent,name, true, i18n("Documentation Browser"), Close | Help,
+TexDocDialog::TexDocDialog(TQWidget *tqparent, const char *name)
+ : KDialogBase( tqparent,name, true, i18n("Documentation Browser"), Close | Help,
#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
NoDefault
#else
@@ -57,10 +57,10 @@ TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
, true ),
m_tempfile(0), m_proc(0)
{
- QWidget *page = new QWidget( this );
+ TQWidget *page = new TQWidget( this );
setMainWidget(page);
- QVBoxLayout *vbox = new QVBoxLayout(page,8,8);
+ TQVBoxLayout *vbox = new TQVBoxLayout(page,8,8);
// listview
m_texdocs = new KListView(page);
@@ -68,15 +68,15 @@ TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
m_texdocs->addColumn(i18n("Table of Contents"));
// groupbox
- QGroupBox *groupbox = new QGroupBox( i18n("Search"), page, "groupbox" );
- groupbox->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5, (QSizePolicy::SizeType)1, 0, 0, groupbox->sizePolicy().hasHeightForWidth() ) );
+ TQGroupBox *groupbox = new TQGroupBox( i18n("Search"), page, "groupbox" );
+ groupbox->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)1, 0, 0, groupbox->sizePolicy().hasHeightForWidth() ) );
groupbox->setColumnLayout(0, Qt::Vertical );
- groupbox->layout()->setSpacing( 6 );
- groupbox->layout()->setMargin( 11 );
- QGridLayout *groupboxLayout = new QGridLayout( groupbox->layout() );
- groupboxLayout->setAlignment( Qt::AlignTop );
+ groupbox->tqlayout()->setSpacing( 6 );
+ groupbox->tqlayout()->setMargin( 11 );
+ TQGridLayout *groupboxLayout = new TQGridLayout( groupbox->tqlayout() );
+ groupboxLayout->tqsetAlignment( TQt::AlignTop );
- QLabel *label = new QLabel( i18n("&Keyword:"), groupbox, "label");
+ TQLabel *label = new TQLabel( i18n("&Keyword:"), groupbox, "label");
m_leKeywords = new KLineEdit("",groupbox);
m_pbSearch = new KPushButton(i18n("&Search"),groupbox);
label->setBuddy(m_leKeywords);
@@ -88,10 +88,10 @@ TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
vbox->addWidget(m_texdocs);
vbox->addWidget(groupbox);
- QWhatsThis::add(m_texdocs,i18n("A list of avaiblable documents, which are listed in 'texdoctk.dat', coming with TexLive/teTeX. A double click with the mouse or pressing the space key will open a viewer to show this file."));
- QWhatsThis::add(m_leKeywords,i18n("You can choose a keyword to show only document files, which are related to this keyword."));
- QWhatsThis::add(m_pbSearch,i18n("Start the search for the chosen keyword."));
- QWhatsThis::add(actionButton(Help),i18n("Reset TOC to show all available files."));
+ TQWhatsThis::add(m_texdocs,i18n("A list of avaiblable documents, which are listed in 'texdoctk.dat', coming with TexLive/teTeX. A double click with the mouse or pressing the space key will open a viewer to show this file."));
+ TQWhatsThis::add(m_leKeywords,i18n("You can choose a keyword to show only document files, which are related to this keyword."));
+ TQWhatsThis::add(m_pbSearch,i18n("Start the search for the chosen keyword."));
+ TQWhatsThis::add(actionButton(Help),i18n("Reset TOC to show all available files."));
setButtonText(Help,i18n("Reset &TOC"));
m_pbSearch->setEnabled(false);
@@ -101,10 +101,10 @@ TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
m_texdocs->installEventFilter(this);
m_leKeywords->installEventFilter(this);
- connect(m_texdocs, SIGNAL(doubleClicked(QListViewItem *,const QPoint &,int)),
- this, SLOT(slotListViewDoubleClicked(QListViewItem *,const QPoint &,int)));
- connect(m_pbSearch, SIGNAL(clicked()), this, SLOT(slotSearchClicked()));
- connect(m_leKeywords, SIGNAL(textChanged(const QString &)), this, SLOT(slotTextChanged(const QString &)));
+ connect(m_texdocs, TQT_SIGNAL(doubleClicked(TQListViewItem *,const TQPoint &,int)),
+ this, TQT_SLOT(slotListViewDoubleClicked(TQListViewItem *,const TQPoint &,int)));
+ connect(m_pbSearch, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSearchClicked()));
+ connect(m_leKeywords, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(slotTextChanged(const TQString &)));
// kpsewhich --expand-path='$TEXMF'
//m_texmfPath = "/usr/local/share/texmf:/usr/local/lib/texmf:/var/lib/texmf:/usr/share/texmf";
@@ -113,11 +113,11 @@ TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
// kpsewhich --progname=texdoctk --format='other text files' texdoctk.dat
//m_texdoctkPath = "/usr/share/texmf/texdoctk/texdoctk.dat";
- m_texmfPath = QString::null;
- m_texmfdocPath = QString::null;
- m_texdoctkPath = QString::null;
+ m_texmfPath = TQString();
+ m_texmfdocPath = TQString();
+ m_texdoctkPath = TQString();
- QDesktopWidget *desktop = KApplication::desktop();
+ TQDesktopWidget *desktop = KApplication::desktop();
int w = desktop->screenGeometry(0).width();
if ( w >= 1024 )
w = 550;
@@ -134,7 +134,7 @@ TexDocDialog::TexDocDialog(QWidget *parent, const char *name)
h = 450;
resize(w,h);
- connect(this, SIGNAL(processFinished()), this, SLOT(slotInitToc()));
+ connect(this, TQT_SIGNAL(processFinished()), this, TQT_SLOT(slotInitToc()));
executeScript(
"kpsewhich --progname=texdoctk --format='other text files' texdoctk.dat && "
"kpsewhich --expand-path='$TEXMF/doc' && "
@@ -158,7 +158,7 @@ TexDocDialog::~TexDocDialog()
void TexDocDialog::readToc()
{
// open to read
- QFile fin( m_texdoctkPath );
+ TQFile fin( m_texdoctkPath );
if ( !fin.exists() || !fin.open(IO_ReadOnly) )
{
KMessageBox::error(this,i18n("Could not read 'texdoctk.dat'."));
@@ -166,8 +166,8 @@ void TexDocDialog::readToc()
}
// use a textstream to read all data
- QString textline;
- QTextStream data(&fin);
+ TQString textline;
+ TQTextStream data(&fin);
while ( ! data.eof() )
{
textline = data.readLine();
@@ -178,17 +178,17 @@ void TexDocDialog::readToc()
// list entries 0,1,basename(2),3 are needed for keyword search
// (key,title,filepath,keywords)
- QStringList list = QStringList::split(';',textline,true);
+ TQStringList list = TQStringList::split(';',textline,true);
// get basename of help file
- QString basename;
+ TQString basename;
if ( list.count() > 2 )
{
- QFileInfo fi(list[2]);
+ TQFileInfo fi(list[2]);
basename = fi.baseName().lower();
}
- QString entry = list[0] + ';' + list[1];
+ TQString entry = list[0] + ';' + list[1];
if ( ! basename.isEmpty() )
entry += ';' + basename;
if ( list.count() > 3 )
@@ -198,10 +198,10 @@ void TexDocDialog::readToc()
}
}
-void TexDocDialog::showToc(const QString &caption,const QStringList &doclist, bool toc)
+void TexDocDialog::showToc(const TQString &caption,const TQStringList &doclist, bool toc)
{
- QString section,textline;
- QStringList keylist;
+ TQString section,textline;
+ TQStringList keylist;
KListViewItem *itemsection = 0L;
setUpdatesEnabled( false );
@@ -216,7 +216,7 @@ void TexDocDialog::showToc(const QString &caption,const QStringList &doclist, bo
}
else
{
- keylist = QStringList::split(';',doclist[i],true);
+ keylist = TQStringList::split(';',doclist[i],true);
if ( itemsection )
{
KListViewItem *item = new KListViewItem(itemsection,keylist[1],keylist[0]);
@@ -226,8 +226,8 @@ void TexDocDialog::showToc(const QString &caption,const QStringList &doclist, bo
m_dictDocuments[keylist[0]] = keylist[2];
// search for special keywords
- QRegExp reg( "^\\s*(-\\d-)" );
- if ( keylist[3].find(reg,0) == 0 )
+ TQRegExp reg( "^\\s*(-\\d-)" );
+ if ( keylist[3].tqfind(reg,0) == 0 )
{
m_dictStyleCodes[keylist[0]] = reg.cap(1);
}
@@ -242,32 +242,32 @@ void TexDocDialog::showToc(const QString &caption,const QStringList &doclist, bo
m_texdocs->setFocus();
}
-bool TexDocDialog::eventFilter(QObject *o, QEvent *e)
+bool TexDocDialog::eventFilter(TQObject *o, TQEvent *e)
{
// catch KeyPress events
- if ( e->type() == QEvent::KeyPress )
+ if ( e->type() == TQEvent::KeyPress )
{
- QKeyEvent *kev = (QKeyEvent*) e;
+ TQKeyEvent *kev = (TQKeyEvent*) e;
// ListView:
// - space: enable start of viewer
// - return: ignore
- if ( o == m_texdocs )
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_texdocs) )
{
- if ( kev->key() == Qt::Key_Space )
+ if ( kev->key() == TQt::Key_Space )
{
- slotListViewDoubleClicked(m_texdocs->currentItem(), QPoint(0,0), 0) ;
+ slotListViewDoubleClicked(m_texdocs->currentItem(), TQPoint(0,0), 0) ;
return true;
}
- if ( kev->key()==Qt::Key_Return || kev->key()==Qt::Key_Enter )
+ if ( kev->key()==TQt::Key_Return || kev->key()==TQt::Key_Enter )
return true;
}
// LineEdit
// - return: start search, if button is enabled
- if ( o == m_leKeywords )
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_leKeywords) )
{
- if ( kev->key()==Qt::Key_Return || kev->key()==Qt::Key_Enter )
+ if ( kev->key()==TQt::Key_Return || kev->key()==TQt::Key_Enter )
{
callSearch();
return true;
@@ -280,53 +280,53 @@ bool TexDocDialog::eventFilter(QObject *o, QEvent *e)
////////////////////// prepare document file //////////////////////
-QString TexDocDialog::searchFile(const QString &docfilename,const QString &listofpathes, const QString &subdir)
+TQString TexDocDialog::searchFile(const TQString &docfilename,const TQString &listofpathes, const TQString &subdir)
{
- QStringList pathlist = QStringList::split(':',listofpathes);
- QStringList extlist = QStringList::split(',',",.gz,.bz2",true);
+ TQStringList pathlist = TQStringList::split(':',listofpathes);
+ TQStringList extlist = TQStringList::split(',',",.gz,.bz2",true);
- QString filename;
- for ( QStringList::Iterator itp = pathlist.begin(); itp!=pathlist.end(); ++itp )
+ TQString filename;
+ for ( TQStringList::Iterator itp = pathlist.begin(); itp!=pathlist.end(); ++itp )
{
- for ( QStringList::Iterator ite = extlist.begin(); ite!=extlist.end(); ++ite )
+ for ( TQStringList::Iterator ite = extlist.begin(); ite!=extlist.end(); ++ite )
{
filename = ( subdir.isEmpty() ) ? (*itp) + '/' + docfilename + (*ite)
: (*itp) + '/' + subdir + '/' + docfilename + (*ite);
// KILE_DEBUG() << "search file: " << filename << endl;
- if ( QFile::exists(filename) )
+ if ( TQFile::exists(filename) )
return filename;
}
}
- return QString::null;
+ return TQString();
}
-void TexDocDialog::decompressFile(const QString &docfile,const QString &command)
+void TexDocDialog::decompressFile(const TQString &docfile,const TQString &command)
{
- QString ext = QFileInfo(docfile).extension(false).lower();
+ TQString ext = TQFileInfo(docfile).extension(false).lower();
if ( ! ( ext=="dvi" || ext=="pdf" || ext=="ps" || ext=="html") )
ext = "txt";
if ( m_tempfile )
delete m_tempfile;
- m_tempfile = new KTempFile(QString::null, '.' + ext);
+ m_tempfile = new KTempFile(TQString(), '.' + ext);
m_tempfile->setAutoDelete(true);
m_filename = m_tempfile->name();
KILE_DEBUG() << "\tdecompress file: " << command + " > " + m_tempfile->name() << endl;
- connect(this, SIGNAL(processFinished()), this, SLOT(slotShowFile()));
+ connect(this, TQT_SIGNAL(processFinished()), this, TQT_SLOT(slotShowFile()));
executeScript(command + " > " + m_tempfile->name());
}
-void TexDocDialog::showStyleFile(const QString &filename,const QString &stylecode)
+void TexDocDialog::showStyleFile(const TQString &filename,const TQString &stylecode)
{
KILE_DEBUG() << "\tshow style file: "<< filename << endl;
- if ( ! QFile::exists(filename) )
+ if ( ! TQFile::exists(filename) )
return;
// open to read
- QFile fin( filename );
+ TQFile fin( filename );
if ( !fin.exists() || !fin.open(IO_ReadOnly) )
{
KMessageBox::error(this,i18n("Could not read the style file."));
@@ -335,23 +335,23 @@ void TexDocDialog::showStyleFile(const QString &filename,const QString &stylecod
if ( m_tempfile )
delete m_tempfile;
- m_tempfile = new KTempFile(QString::null,".txt");
+ m_tempfile = new KTempFile(TQString(),".txt");
m_tempfile->setAutoDelete(true);
// use a textstream to write to the temporary file
- QFile tmpfile(m_tempfile->name());
+ TQFile tmpfile(m_tempfile->name());
if ( ! tmpfile.open( IO_WriteOnly ) )
{
KMessageBox::error(this,i18n("Could not create a temporary file."));
return ;
}
- QTextStream stream(&tmpfile);
+ TQTextStream stream(&tmpfile);
// use another textstream to read from the style file
- QTextStream sty( &fin );
+ TQTextStream sty( &fin );
// there are four mode to read from the style file
- QString textline;
+ TQString textline;
if ( stylecode == "-3-" )
{
// mode 3: read everything up to the first empty line
@@ -370,7 +370,7 @@ void TexDocDialog::showStyleFile(const QString &filename,const QString &stylecod
while ( ! sty.eof() )
{
textline = sty.readLine();
- if ( textline.find("%%%%") == 0 )
+ if ( textline.tqfind("%%%%") == 0 )
break;
stream << textline << "\n";
}
@@ -381,7 +381,7 @@ void TexDocDialog::showStyleFile(const QString &filename,const QString &stylecod
while ( ! sty.eof() )
{
textline = sty.readLine().stripWhiteSpace();
- if ( textline.find("\\endinput") == 0 )
+ if ( textline.tqfind("\\endinput") == 0 )
break;
}
while ( ! sty.eof() )
@@ -405,10 +405,10 @@ void TexDocDialog::showStyleFile(const QString &filename,const QString &stylecod
showFile(m_tempfile->name());
}
-void TexDocDialog::showFile(const QString &filename)
+void TexDocDialog::showFile(const TQString &filename)
{
KILE_DEBUG() << "\tshow file: "<< filename << endl;
- if ( QFile::exists(filename) )
+ if ( TQFile::exists(filename) )
{
KURL url;
url.setPath(filename);
@@ -429,63 +429,63 @@ void TexDocDialog::showFile(const QString &filename)
////////////////////// Slots //////////////////////
-void TexDocDialog::slotListViewDoubleClicked(QListViewItem *item,const QPoint &,int)
+void TexDocDialog::slotListViewDoubleClicked(TQListViewItem *item,const TQPoint &,int)
{
- if ( ! item->parent() )
+ if ( ! item->tqparent() )
return;
- QString package = item->text(1);
+ TQString package = item->text(1);
KILE_DEBUG() << "\tselect child: " << item->text(0) << endl
<< "\tis package: " << package << endl;
- if ( ! m_dictDocuments.contains( package ) )
+ if ( ! m_dictDocuments.tqcontains( package ) )
return;
- QString texdocfile = m_dictDocuments[package];
+ TQString texdocfile = m_dictDocuments[package];
KILE_DEBUG() << "\tis texdocfile: " << texdocfile << endl;
// search for the file in the documentation directories
- QString filename = searchFile(texdocfile,m_texmfdocPath);
+ TQString filename = searchFile(texdocfile,m_texmfdocPath);
if ( filename.isEmpty() )
{
// not found: search it elsewhere
filename = searchFile(texdocfile,m_texmfPath,"tex");
if ( filename.isEmpty() )
{
- KMessageBox::error(this,i18n("Could not find '%1'").arg(filename));
+ KMessageBox::error(this,i18n("Could not tqfind '%1'").tqarg(filename));
return;
}
}
KILE_DEBUG() << "\tfound file: " << filename << endl;
- QString ext = QFileInfo(filename).extension(false).lower();
- m_filename = QString::null;
+ TQString ext = TQFileInfo(filename).extension(false).lower();
+ m_filename = TQString();
if ( ext == "gz" )
decompressFile(m_dictDocuments[package],"gzip -cd "+filename);
else if ( ext == "bz2" )
decompressFile(m_dictDocuments[package],"bzip2 -cd "+filename);
- else if ( ext=="sty" && m_dictStyleCodes.contains(package) )
+ else if ( ext=="sty" && m_dictStyleCodes.tqcontains(package) )
showStyleFile(filename,m_dictStyleCodes[package]);
else
showFile(filename);
}
-void TexDocDialog::slotTextChanged(const QString &text)
+void TexDocDialog::slotTextChanged(const TQString &text)
{
m_pbSearch->setEnabled( ! text.stripWhiteSpace().isEmpty() );
}
void TexDocDialog::slotSearchClicked()
{
- QString keyword = m_leKeywords->text().stripWhiteSpace();
+ TQString keyword = m_leKeywords->text().stripWhiteSpace();
if ( keyword.isEmpty() )
{
KMessageBox::error(this,i18n("No keyword given."));
return;
}
- QString section;
+ TQString section;
bool writesection = true;
- QStringList searchlist;
+ TQStringList searchlist;
for (uint i=0; i<m_tocList.count(); i++ )
{
@@ -494,7 +494,7 @@ void TexDocDialog::slotSearchClicked()
section = m_tocList[i];
writesection = true;
}
- else if ( m_tocSearchList[i].find(keyword,0,false) > -1 )
+ else if ( m_tocSearchList[i].tqfind(keyword,0,false) > -1 )
{
if ( writesection )
searchlist.append(section);
@@ -506,15 +506,15 @@ void TexDocDialog::slotSearchClicked()
if ( searchlist.count() > 0 )
{
m_texdocs->clear();
- showToc(i18n("Search results for keyword '%1'").arg(keyword),searchlist,false);
+ showToc(i18n("Search results for keyword '%1'").tqarg(keyword),searchlist,false);
}
else
- KMessageBox::error(this,i18n("No documents found for keyword '%1'.").arg(keyword));
+ KMessageBox::error(this,i18n("No documents found for keyword '%1'.").tqarg(keyword));
}
void TexDocDialog::slotHelp()
{
- m_leKeywords->setText(QString::null);
+ m_leKeywords->setText(TQString());
m_texdocs->clear();
showToc(i18n("Table of Contents"),m_tocList,true);
}
@@ -527,22 +527,22 @@ void TexDocDialog::callSearch()
////////////////////// execute shell script //////////////////////
-void TexDocDialog::executeScript(const QString &command)
+void TexDocDialog::executeScript(const TQString &command)
{
if ( m_proc )
delete m_proc;
m_proc = new KShellProcess("/bin/sh");
m_proc->clearArguments();
- (*m_proc) << QStringList::split(' ',command);
- m_output = QString::null;
+ (*m_proc) << TQStringList::split(' ',command);
+ m_output = TQString();
- connect(m_proc, SIGNAL(receivedStdout(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(receivedStderr(KProcess*,char*,int)),
- this, SLOT(slotProcessOutput(KProcess*,char*,int)) );
- connect(m_proc, SIGNAL(processExited(KProcess*)),
- this, SLOT(slotProcessExited(KProcess*)) );
+ connect(m_proc, TQT_SIGNAL(receivedStdout(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(receivedStderr(KProcess*,char*,int)),
+ this, TQT_SLOT(slotProcessOutput(KProcess*,char*,int)) );
+ connect(m_proc, TQT_SIGNAL(processExited(KProcess*)),
+ this, TQT_SLOT(slotProcessExited(KProcess*)) );
KILE_DEBUG() << "=== TexDocDialog::runShellSkript() ====================" << endl;
KILE_DEBUG() << " execute: " << command << endl;
@@ -552,7 +552,7 @@ void TexDocDialog::executeScript(const QString &command)
void TexDocDialog::slotProcessOutput(KProcess*,char* buf,int len)
{
- m_output += QString::fromLocal8Bit(buf,len);
+ m_output += TQString::fromLocal8Bit(buf,len);
}
@@ -573,9 +573,9 @@ void TexDocDialog::slotProcessExited(KProcess *proc)
void TexDocDialog::slotInitToc()
{
- disconnect(this, SIGNAL(processFinished()), this, SLOT(slotInitToc()));
+ disconnect(this, TQT_SIGNAL(processFinished()), this, TQT_SLOT(slotInitToc()));
- QStringList results = QStringList::split('\n',m_output,true);
+ TQStringList results = TQStringList::split('\n',m_output,true);
if ( results.count() < 3 )
{
KMessageBox::error(this,i18n("Could not determine the search paths of TexLive/teTeX or file 'texdoctk.dat'.<br> So this dialog is useless."));
@@ -590,7 +590,7 @@ void TexDocDialog::slotInitToc()
KILE_DEBUG() << "\ttexmfdoc path: " << m_texmfdocPath << endl;
KILE_DEBUG() << "\ttexmf path: " << m_texmfPath << endl;
- if ( m_texdoctkPath.find('\n',-1) > -1 )
+ if ( m_texdoctkPath.tqfind('\n',-1) > -1 )
{
m_texdoctkPath.truncate(m_texdoctkPath.length()-1);
}
@@ -602,19 +602,19 @@ void TexDocDialog::slotInitToc()
void TexDocDialog::slotShowFile()
{
- disconnect(this, SIGNAL(processFinished()), this, SLOT(slotShowFile()));
+ disconnect(this, TQT_SIGNAL(processFinished()), this, TQT_SLOT(slotShowFile()));
showFile(m_filename);
}
////////////////////// Icon/Mime //////////////////////
-QString TexDocDialog::getMimeType(const QString &filename)
+TQString TexDocDialog::getMimeType(const TQString &filename)
{
- QFileInfo fi(filename);
- QString basename = fi.baseName().lower();
- QString ext = fi.extension(false).lower();
+ TQFileInfo fi(filename);
+ TQString basename = fi.baseName().lower();
+ TQString ext = fi.extension(false).lower();
- QString mimetype;
+ TQString mimetype;
if ( ext=="txt" || ext=="faq" || ext=="sty" || basename=="readme" || basename=="00readme" )
{
mimetype = "text/plain";
@@ -631,13 +631,13 @@ QString TexDocDialog::getMimeType(const QString &filename)
return mimetype;
}
-QString TexDocDialog::getIconName(const QString &filename)
+TQString TexDocDialog::getIconName(const TQString &filename)
{
- QFileInfo fi( filename );
- QString basename = fi.baseName().lower();
- QString ext = fi.extension(false).lower();
+ TQFileInfo fi( filename );
+ TQString basename = fi.baseName().lower();
+ TQString ext = fi.extension(false).lower();
- QString icon;
+ TQString icon;
if ( ext=="dvi" || ext=="pdf" || ext=="html" || ext == "htm" || ext == "txt")
icon = ext;
else if ( ext == "ps" )
diff --git a/src/kile/texdocdialog.h b/src/kile/texdocdialog.h
index fe6af35..a9eadc2 100644
--- a/src/kile/texdocdialog.h
+++ b/src/kile/texdocdialog.h
@@ -26,9 +26,9 @@
#include <ktempfile.h>
#include <klistview.h>
-#include <qlabel.h>
-#include <qstringlist.h>
-#include <qmap.h>
+#include <tqlabel.h>
+#include <tqstringlist.h>
+#include <tqmap.h>
namespace KileDialog
{
@@ -36,9 +36,10 @@ namespace KileDialog
class TexDocDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- TexDocDialog(QWidget *parent=0, const char *name=0);
+ TexDocDialog(TQWidget *tqparent=0, const char *name=0);
~TexDocDialog();
private:
@@ -46,35 +47,35 @@ private:
KLineEdit *m_leKeywords;
KPushButton *m_pbSearch;
- QString m_texmfPath, m_texmfdocPath, m_texdoctkPath;
+ TQString m_texmfPath, m_texmfdocPath, m_texdoctkPath;
- QStringList m_tocList,m_tocSearchList;
- QMap<QString,QString> m_dictDocuments;
- QMap<QString,QString> m_dictStyleCodes;
+ TQStringList m_tocList,m_tocSearchList;
+ TQMap<TQString,TQString> m_dictDocuments;
+ TQMap<TQString,TQString> m_dictStyleCodes;
void readToc();
- void showToc(const QString &caption,const QStringList &doclist, bool toc=true);
+ void showToc(const TQString &caption,const TQStringList &doclist, bool toc=true);
- QString m_filename;
- QString m_output;
+ TQString m_filename;
+ TQString m_output;
KTempFile *m_tempfile;
KShellProcess *m_proc;
void callSearch();
- void executeScript(const QString &command);
- void showFile(const QString &filename);
+ void executeScript(const TQString &command);
+ void showFile(const TQString &filename);
- QString searchFile(const QString &docfilename,const QString &listofpathes,
- const QString &subdir=QString::null);
- void decompressFile(const QString &docfile,const QString &command);
- void showStyleFile(const QString &filename,const QString &stylecode);
+ TQString searchFile(const TQString &docfilename,const TQString &listofpathes,
+ const TQString &subdir=TQString());
+ void decompressFile(const TQString &docfile,const TQString &command);
+ void showStyleFile(const TQString &filename,const TQString &stylecode);
- QString getMimeType(const QString &filename);
- QString getIconName(const QString &filename);
+ TQString getMimeType(const TQString &filename);
+ TQString getIconName(const TQString &filename);
protected:
- bool eventFilter(QObject *o, QEvent *e);
+ bool eventFilter(TQObject *o, TQEvent *e);
signals:
void processFinished();
@@ -83,8 +84,8 @@ protected slots:
void slotHelp();
private slots:
- void slotListViewDoubleClicked(QListViewItem *item,const QPoint &,int);
- void slotTextChanged(const QString &text);
+ void slotListViewDoubleClicked(TQListViewItem *item,const TQPoint &,int);
+ void slotTextChanged(const TQString &text);
void slotSearchClicked();
void slotProcessOutput(KProcess*,char* buf,int len);
diff --git a/src/kile/toolconfigwidget.ui b/src/kile/toolconfigwidget.ui
index 54816bb..59bb2f6 100644
--- a/src/kile/toolconfigwidget.ui
+++ b/src/kile/toolconfigwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>ToolConfigWidget</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>ToolConfigWidget</cstring>
</property>
@@ -20,7 +20,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>m_groupLeft</cstring>
</property>
@@ -58,7 +58,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>m_lbSelectTool</cstring>
</property>
@@ -81,7 +81,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>150</width>
<height>0</height>
@@ -120,7 +120,7 @@
<enum>Vertical</enum>
</property>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>m_groupRight</cstring>
</property>
@@ -160,7 +160,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>150</width>
<height>0</height>
@@ -202,7 +202,7 @@
<string>New Config...</string>
</property>
</widget>
- <widget class="QTabWidget" row="1" column="0" rowspan="1" colspan="4">
+ <widget class="TQTabWidget" row="1" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>m_tab</cstring>
</property>
@@ -214,13 +214,13 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>400</width>
<height>0</height>
</size>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>tab</cstring>
</property>
@@ -231,7 +231,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QWidgetStack">
+ <widget class="TQWidgetStack">
<property name="name">
<cstring>m_stackBasic</cstring>
</property>
@@ -243,7 +243,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>WStackPage</cstring>
</property>
@@ -252,7 +252,7 @@
</attribute>
</widget>
</widget>
- <widget class="QWidgetStack">
+ <widget class="TQWidgetStack">
<property name="name">
<cstring>m_stackExtra</cstring>
</property>
@@ -264,7 +264,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>WStackPage</cstring>
</property>
@@ -283,7 +283,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>240</height>
@@ -292,7 +292,7 @@
</spacer>
</vbox>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>tab</cstring>
</property>
@@ -316,7 +316,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbType</cstring>
</property>
@@ -343,7 +343,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLabel" row="6" column="0">
+ <widget class="TQLabel" row="6" column="0">
<property name="name">
<cstring>textLabel2</cstring>
</property>
@@ -354,7 +354,7 @@
<cstring>m_leRelDir</cstring>
</property>
</widget>
- <widget class="QLabel" row="5" column="0">
+ <widget class="TQLabel" row="5" column="0">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -365,7 +365,7 @@
<cstring>m_leFile</cstring>
</property>
</widget>
- <widget class="QLabel" row="4" column="0">
+ <widget class="TQLabel" row="4" column="0">
<property name="name">
<cstring>m_lbTarget</cstring>
</property>
@@ -418,7 +418,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLabel" row="3" column="0">
+ <widget class="TQLabel" row="3" column="0">
<property name="name">
<cstring>m_lbSource</cstring>
</property>
@@ -429,7 +429,7 @@
<cstring>m_leSource</cstring>
</property>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>m_lbClass</cstring>
</property>
@@ -440,7 +440,7 @@
<cstring>m_cbClass</cstring>
</property>
</widget>
- <widget class="QCheckBox" row="1" column="0" rowspan="1" colspan="2">
+ <widget class="TQCheckBox" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>m_ckClose</cstring>
</property>
@@ -471,14 +471,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
- <widget class="QLabel" row="7" column="0">
+ <widget class="TQLabel" row="7" column="0">
<property name="name">
<cstring>m_lbState</cstring>
</property>
@@ -496,7 +496,7 @@
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>TabPage</cstring>
</property>
@@ -507,7 +507,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>m_lbMenu</cstring>
</property>
@@ -531,7 +531,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>m_lbIcon</cstring>
</property>
@@ -552,7 +552,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>100</height>
@@ -570,7 +570,7 @@
</grid>
</widget>
</widget>
- <widget class="QLabel" row="0" column="0" rowspan="1" colspan="2">
+ <widget class="TQLabel" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>m_lbConfig</cstring>
</property>
@@ -623,5 +623,5 @@
<tabstop>m_leRelDir</tabstop>
<tabstop>m_cbMenu</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/src/kile/userhelp.cpp b/src/kile/userhelp.cpp
index 3d847e5..23b8a4b 100644
--- a/src/kile/userhelp.cpp
+++ b/src/kile/userhelp.cpp
@@ -18,7 +18,7 @@
#include "userhelp.h"
-#include <qfileinfo.h>
+#include <tqfileinfo.h>
#include <kglobal.h>
#include <kiconloader.h>
@@ -51,7 +51,7 @@ UserHelp::~UserHelp()
void UserHelp::readConfig()
{
//KILE_DEBUG() << "\tuserhelp: read config" << endl;
- QStringList menu,files;
+ TQStringList menu,files;
// first read all entries
KConfig *config = m_manager->config();
@@ -59,11 +59,11 @@ void UserHelp::readConfig()
int entries = config->readNumEntry("entries");
for ( int i=0; i<entries; ++i )
{
- menu << config->readEntry(QString("menu%1").arg(i));
+ menu << config->readEntry(TQString("menu%1").tqarg(i));
if ( !menu[i].isEmpty() || menu[i]=="-" )
- files << config->readEntry(QString("file%1").arg(i));
+ files << config->readEntry(TQString("file%1").tqarg(i));
else
- files << QString::null;
+ files << TQString();
}
// then update menu
@@ -84,9 +84,9 @@ void UserHelp::writeConfig()
config->writeEntry("entries",entries);
for ( int i=0; i<entries; ++i )
{
- config->writeEntry(QString("menu%1").arg(i), m_menuentries[i]);
+ config->writeEntry(TQString("menu%1").tqarg(i), m_menuentries[i]);
if ( m_menuentries[i] != "-" )
- config->writeEntry(QString("file%1").arg(i), m_helpfiles[i]);
+ config->writeEntry(TQString("file%1").tqarg(i), m_helpfiles[i]);
}
}
@@ -101,7 +101,7 @@ void UserHelp::expandHelpMenu()
{
int helpindex = getHelpIndex(m_helpmenu);
- m_helppopup = new QPopupMenu();
+ m_helppopup = new TQPopupMenu();
if ( m_helppopup )
{
m_sepid = m_helpmenu->insertSeparator(helpindex);
@@ -114,7 +114,7 @@ void UserHelp::expandHelpMenu()
// update stringlists and userhelp menu
-void UserHelp::updateEntries(const QStringList &entries, const QStringList &files, bool save)
+void UserHelp::updateEntries(const TQStringList &entries, const TQStringList &files, bool save)
{
if ( m_menuentries==entries && m_helpfiles==files)
return;
@@ -157,26 +157,26 @@ void UserHelp::setupUserHelpMenu()
else
{
// check for a http file
- bool http = ( m_helpfiles[i].find("http://",0) == 0 );
+ bool http = ( m_helpfiles[i].tqfind("http://",0) == 0 );
// some file types have an icon
- QFileInfo fi(m_helpfiles[i]);
- QString ext = fi.extension(false);
+ TQFileInfo fi(m_helpfiles[i]);
+ TQString ext = fi.extension(false);
if ( ext == "htm" )
ext = "html";
if ( http || ext=="html" || ext=="dvi" || ext=="ps" || ext=="pdf" )
{
- QString icon = ( http ) ? "viewhtml" : ext;
+ TQString icon = ( http ) ? "viewhtml" : ext;
helpid = m_helppopup->insertItem( SmallIcon(icon),m_menuentries[i],
- this,SLOT(slotUserHelpActivated(int)) );
+ this,TQT_SLOT(slotUserHelpActivated(int)) );
}
else
{
helpid = m_helppopup->insertItem( m_menuentries[i],
- this,SLOT(slotUserHelpActivated(int)) );
+ this,TQT_SLOT(slotUserHelpActivated(int)) );
}
- // send index of QStringList as parameter, when the slot is activated
+ // send index of TQStringList as parameter, when the slot is activated
m_helppopup->setItemParameter(helpid,i);
}
}
@@ -196,14 +196,14 @@ void UserHelp::enableUserHelpEntries(bool state)
}
}
-QPopupMenu *UserHelp::getHelpPopup()
+TQPopupMenu *UserHelp::getHelpPopup()
{
int helpid = 0;
for (uint i=0; i<m_menubar->count(); ++i)
{
int id = m_menubar->idAt(i);
- QString text = m_menubar->text(id);
+ TQString text = m_menubar->text(id);
if ( text == i18n("&Help") )
{
@@ -211,10 +211,10 @@ QPopupMenu *UserHelp::getHelpPopup()
break;
}
}
- return ( helpid == 0 ) ? 0 : m_menubar->findItem(helpid)->popup();
+ return ( helpid == 0 ) ? 0 : m_menubar->tqfindItem(helpid)->popup();
}
-int UserHelp::getHelpIndex(QPopupMenu *popup)
+int UserHelp::getHelpIndex(TQPopupMenu *popup)
{
if ( popup )
{
@@ -222,7 +222,7 @@ int UserHelp::getHelpIndex(QPopupMenu *popup)
for (uint i=0; i<popup->count(); ++i)
{
int entryid = popup->idAt(i);
- QString entry = popup->text(entryid);
+ TQString entry = popup->text(entryid);
if ( entry.isEmpty() )
{
@@ -242,14 +242,14 @@ void UserHelp::slotUserHelpActivated(int index)
return;
// get filename of this user help entry
- QString filename = m_helpfiles[index];
+ TQString filename = m_helpfiles[index];
// does the files exist?
- QFileInfo fi(filename);
- bool http = ( filename.find("http://",0) == 0 );
+ TQFileInfo fi(filename);
+ bool http = ( filename.tqfind("http://",0) == 0 );
if ( !http && !fi.exists() )
{
- KMessageBox::error(0,QString(i18n("File '%1' doesn't exist.")).arg(filename));
+ KMessageBox::error(0,TQString(i18n("File '%1' doesn't exist.")).tqarg(filename));
return;
}
@@ -257,11 +257,11 @@ void UserHelp::slotUserHelpActivated(int index)
KILE_DEBUG() << "\tshow userhelpfile (" << filename << ")" << endl;
// determine, how to show the file
- QString type;
- QString cfg = "Embedded Viewer";
+ TQString type;
+ TQString cfg = "Embedded Viewer";
if ( !http && KileConfig::embedded()==0 )
{
- QString ext = fi.extension(false);
+ TQString ext = fi.extension(false);
if ( ext == "dvi" )
type = "ViewDVI";
else if ( ext == "ps" )
@@ -273,7 +273,7 @@ void UserHelp::slotUserHelpActivated(int index)
}
KConfig *config = m_manager->config();
- if ( type!=QString::null && config->hasGroup("Tool/" + type + '/' + cfg) )
+ if ( type!=TQString() && config->hasGroup("Tool/" + type + '/' + cfg) )
{
KileTool::View *tool = new KileTool::View(type, m_manager, false);
tool->setFlags(0);
@@ -292,7 +292,7 @@ void UserHelp::slotUserHelpActivated(int index)
void UserHelp::userHelpDialog()
{
- QStringList userhelpmenulist, userhelpfilelist;
+ TQStringList userhelpmenulist, userhelpfilelist;
KileDialog::UserHelpDialog *dialog = new KileDialog::UserHelpDialog();
dialog->setParameter(m_menuentries,m_helpfiles);
diff --git a/src/kile/userhelp.h b/src/kile/userhelp.h
index 6149d67..37dc069 100644
--- a/src/kile/userhelp.h
+++ b/src/kile/userhelp.h
@@ -19,9 +19,9 @@
#ifndef USERHELP_H
#define USERHELP_H
-#include <qwidget.h>
-#include <qpopupmenu.h>
-#include <qstringlist.h>
+#include <tqwidget.h>
+#include <tqpopupmenu.h>
+#include <tqstringlist.h>
#include <kmenubar.h>
#include <kconfig.h>
@@ -32,9 +32,10 @@
namespace KileHelp
{
-class UserHelp: public QObject
+class UserHelp: public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
UserHelp(KileTool::Manager *manager, KMenuBar *menubar);
@@ -53,17 +54,17 @@ private:
void setupUserHelpMenu();
void expandHelpMenu();
- QPopupMenu *getHelpPopup();
- int getHelpIndex(QPopupMenu *popup);
+ TQPopupMenu *getHelpPopup();
+ int getHelpIndex(TQPopupMenu *popup);
- void updateEntries(const QStringList &entries, const QStringList &files, bool save = true);
+ void updateEntries(const TQStringList &entries, const TQStringList &files, bool save = true);
KileTool::Manager *m_manager;
KMenuBar *m_menubar;
- QPopupMenu *m_helpmenu, *m_helppopup;
+ TQPopupMenu *m_helpmenu, *m_helppopup;
int m_helpid, m_sepid;
- QStringList m_menuentries, m_helpfiles;
+ TQStringList m_menuentries, m_helpfiles;
};
}
diff --git a/src/kile/userhelpdialog.cpp b/src/kile/userhelpdialog.cpp
index 24de11d..be14da5 100644
--- a/src/kile/userhelpdialog.cpp
+++ b/src/kile/userhelpdialog.cpp
@@ -18,12 +18,12 @@
#include "userhelpdialog.h"
-#include <qlayout.h>
-#include <qvgroupbox.h>
-#include <qlabel.h>
-#include <qinputdialog.h>
-#include <qfileinfo.h>
-#include <qwhatsthis.h>
+#include <tqlayout.h>
+#include <tqvgroupbox.h>
+#include <tqlabel.h>
+#include <tqinputdialog.h>
+#include <tqfileinfo.h>
+#include <tqwhatsthis.h>
#include <klocale.h>
#include <kfiledialog.h>
@@ -41,35 +41,35 @@ namespace KileDialog
//BEGIN UserHelpDialog
-UserHelpDialog::UserHelpDialog(QWidget *parent, const char *name)
- : KDialogBase( parent, name, true, i18n("Configure User Help"), Cancel | Ok, Ok, true )
+UserHelpDialog::UserHelpDialog(TQWidget *tqparent, const char *name)
+ : KDialogBase( tqparent, name, true, i18n("Configure User Help"), Cancel | Ok, Ok, true )
{
KILE_DEBUG() << "==UserHelpDialog::UserHelpDialog()===================" << endl;
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- // layout
- QVBoxLayout *vbox = new QVBoxLayout(page, 6,6 );
- QVGroupBox* group= new QVGroupBox(i18n("User Help"),page );
+ // tqlayout
+ TQVBoxLayout *vbox = new TQVBoxLayout(page, 6,6 );
+ TQVGroupBox* group= new TQVGroupBox(i18n("User Help"),page );
- QWidget *widget = new QWidget(group);
- QGridLayout *grid = new QGridLayout( widget, 5,3, 5,5, "" );
+ TQWidget *widget = new TQWidget(group);
+ TQGridLayout *grid = new TQGridLayout( widget, 5,3, 5,5, "" );
grid->setRowStretch(1,1);
grid->setColStretch(0,1);
grid->setRowSpacing(2,12);
grid->setColSpacing(1,20);
// listbox
- QLabel *label1 = new QLabel(i18n("&Menu item:"),widget);
+ TQLabel *label1 = new TQLabel(i18n("&Menu item:"),widget);
grid->addWidget( label1,0,0 );
m_menulistbox = new KListBox(widget);
grid->addWidget( m_menulistbox, 1,0 );
label1->setBuddy(m_menulistbox);
// action widget
- QWidget *actionwidget = new QWidget(widget);
- QVBoxLayout *actions = new QVBoxLayout(actionwidget);
+ TQWidget *actionwidget = new TQWidget(widget);
+ TQVBoxLayout *actions = new TQVBoxLayout(actionwidget);
m_add = new KPushButton(i18n("&Add..."),actionwidget);
m_remove = new KPushButton(i18n("&Remove"),actionwidget);
@@ -77,14 +77,14 @@ UserHelpDialog::UserHelpDialog(QWidget *parent, const char *name)
m_up = new KPushButton(i18n("Move &Up"),actionwidget);
m_down = new KPushButton(i18n("Move &Down"),actionwidget);
- int wmax = m_add->sizeHint().width();
- int w = m_remove->sizeHint().width();
+ int wmax = m_add->tqsizeHint().width();
+ int w = m_remove->tqsizeHint().width();
if ( w > wmax ) wmax = w;
- w = m_addsep->sizeHint().width();
+ w = m_addsep->tqsizeHint().width();
if ( w > wmax ) wmax = w;
- w = m_up->sizeHint().width();
+ w = m_up->tqsizeHint().width();
if ( w > wmax ) wmax = w;
- w = m_down->sizeHint().width();
+ w = m_down->tqsizeHint().width();
if ( w > wmax ) wmax = w;
m_add->setFixedWidth(wmax);
@@ -104,10 +104,10 @@ UserHelpDialog::UserHelpDialog(QWidget *parent, const char *name)
actions->addStretch(1);
// inserta ction widget
- grid->addWidget( actionwidget,1,2, Qt::AlignTop );
+ grid->addWidget( actionwidget,1,2, TQt::AlignTop );
// file
- QLabel *label2 = new QLabel(i18n("File:"),widget);
+ TQLabel *label2 = new TQLabel(i18n("File:"),widget);
grid->addWidget( label2, 3,0 );
m_fileedit = new KLineEdit("",widget);
m_fileedit->setReadOnly(true);
@@ -116,18 +116,18 @@ UserHelpDialog::UserHelpDialog(QWidget *parent, const char *name)
// fill vbox
vbox->addWidget(group);
- connect( m_menulistbox, SIGNAL(highlighted(int)),this,SLOT(slotChange(int)));
- connect( m_add, SIGNAL(clicked()), SLOT(slotAdd()) );
- connect( m_remove, SIGNAL(clicked()), SLOT(slotRemove()) );
- connect( m_addsep, SIGNAL(clicked()), SLOT(slotAddSep()) );
- connect( m_up, SIGNAL(clicked()), SLOT(slotUp()) );
- connect( m_down, SIGNAL(clicked()), SLOT(slotDown()) );
+ connect( m_menulistbox, TQT_SIGNAL(highlighted(int)),this,TQT_SLOT(slotChange(int)));
+ connect( m_add, TQT_SIGNAL(clicked()), TQT_SLOT(slotAdd()) );
+ connect( m_remove, TQT_SIGNAL(clicked()), TQT_SLOT(slotRemove()) );
+ connect( m_addsep, TQT_SIGNAL(clicked()), TQT_SLOT(slotAddSep()) );
+ connect( m_up, TQT_SIGNAL(clicked()), TQT_SLOT(slotUp()) );
+ connect( m_down, TQT_SIGNAL(clicked()), TQT_SLOT(slotDown()) );
- resize(400,sizeHint().height());
+ resize(400,tqsizeHint().height());
updateButton();
}
-void UserHelpDialog::setParameter(const QStringList &menuentries, const QStringList &helpfiles)
+void UserHelpDialog::setParameter(const TQStringList &menuentries, const TQStringList &helpfiles)
{
for (uint i=0; i<menuentries.count(); ++i)
{
@@ -136,12 +136,12 @@ void UserHelpDialog::setParameter(const QStringList &menuentries, const QStringL
if ( m_menulistbox->text(i) != "-" )
m_filelist << helpfiles[i];
else
- m_filelist << QString::null ;
+ m_filelist << TQString() ;
}
updateButton();
}
-void UserHelpDialog::getParameter(QStringList &userhelpmenulist, QStringList &userhelpfilelist)
+void UserHelpDialog::getParameter(TQStringList &userhelpmenulist, TQStringList &userhelpfilelist)
{
// clear result
userhelpmenulist.clear();
@@ -160,7 +160,7 @@ void UserHelpDialog::getParameter(QStringList &userhelpmenulist, QStringList &us
else if ( !separator )
{
userhelpmenulist << m_menulistbox->text(i);
- userhelpfilelist << QString::null;
+ userhelpfilelist << TQString();
separator = true;
}
}
@@ -189,7 +189,7 @@ void UserHelpDialog::slotAdd()
m_menulistbox->setCurrentItem( m_menulistbox->count()-1 );
// with corresponding filename
- QString helpfile = dialog->getHelpfile();
+ TQString helpfile = dialog->getHelpfile();
m_filelist.append(helpfile);
m_fileedit->setText(helpfile);
@@ -234,7 +234,7 @@ void UserHelpDialog::slotAddSep()
// insert separator
m_menulistbox->insertItem("-",index);
- m_filelist.insert( m_filelist.at(index) ,QString::null );
+ m_filelist.insert( m_filelist.at(index) ,TQString() );
updateButton();
}
@@ -340,46 +340,46 @@ void UserHelpDialog::updateButton()
//BEGIN UserHelpAddDialog
-UserHelpAddDialog::UserHelpAddDialog(KListBox *menulistbox, QWidget *parent, const char *name)
- : KDialogBase( parent, name, true, i18n("Add User Helpfile"), Cancel | Ok, Ok, true ),
+UserHelpAddDialog::UserHelpAddDialog(KListBox *menulistbox, TQWidget *tqparent, const char *name)
+ : KDialogBase( tqparent, name, true, i18n("Add User Helpfile"), Cancel | Ok, Ok, true ),
m_menulistbox(menulistbox)
{
KILE_DEBUG() << "==UserHelpAddDialog::UserHelpAddDialog()===================" << endl;
- QWidget *page = new QWidget(this);
+ TQWidget *page = new TQWidget(this);
setMainWidget(page);
- // layout
- QVBoxLayout *vbox = new QVBoxLayout(page, 6,6 );
- QVGroupBox* group= new QVGroupBox(i18n("User Help"),page );
+ // tqlayout
+ TQVBoxLayout *vbox = new TQVBoxLayout(page, 6,6 );
+ TQVGroupBox* group= new TQVGroupBox(i18n("User Help"),page );
- QWidget *widget = new QWidget(group);
- QGridLayout *grid = new QGridLayout( widget, 2,6, 5,5, "" );
+ TQWidget *widget = new TQWidget(group);
+ TQGridLayout *grid = new TQGridLayout( widget, 2,6, 5,5, "" );
grid->setColSpacing(2,8);
grid->setColSpacing(4,8);
// menu entry
- QLabel *label1 = new QLabel(i18n("&Menu entry:"),widget);
+ TQLabel *label1 = new TQLabel(i18n("&Menu entry:"),widget);
grid->addWidget( label1,0,0 );
m_leMenuEntry = new KLineEdit("",widget);
grid->addWidget( m_leMenuEntry, 0,1 );
label1->setBuddy(m_leMenuEntry);
// help file
- QLabel *label2 = new QLabel(i18n("&Help file:"),widget);
+ TQLabel *label2 = new TQLabel(i18n("&Help file:"),widget);
grid->addWidget( label2, 1,0 );
m_leHelpFile = new KLineEdit("",widget);
m_leHelpFile->setReadOnly(false);
grid->addWidget( m_leHelpFile, 1,1 );
m_pbChooseFile = new KPushButton("", widget, "filechooser_button" );
m_pbChooseFile->setPixmap( SmallIcon("fileopen") );
- grid->addRowSpacing( 1, m_pbChooseFile->sizeHint().height()+5 );
+ grid->addRowSpacing( 1, m_pbChooseFile->tqsizeHint().height()+5 );
grid->addWidget(m_pbChooseFile,1,3);
m_pbChooseHtml = new KPushButton("", widget, "htmlchooser_button" );
m_pbChooseHtml->setPixmap( SmallIcon("viewhtml") );
grid->addWidget(m_pbChooseHtml,1,5);
- grid->setColSpacing(3, m_pbChooseFile->sizeHint().width()+5 );
- grid->setColSpacing(5, m_pbChooseHtml->sizeHint().width()+5 );
+ grid->setColSpacing(3, m_pbChooseFile->tqsizeHint().width()+5 );
+ grid->setColSpacing(5, m_pbChooseHtml->tqsizeHint().width()+5 );
label2->setBuddy(m_pbChooseFile);
@@ -387,31 +387,31 @@ UserHelpAddDialog::UserHelpAddDialog(KListBox *menulistbox, QWidget *parent, con
vbox->addWidget(group);
vbox->addStretch();
- QWhatsThis::add(m_leMenuEntry,i18n("The menu entry for this help file."));
- QWhatsThis::add(m_leHelpFile,i18n("The name of the local help file or a valid WEB url."));
- QWhatsThis::add(m_pbChooseFile,i18n("Start a file dialog to choose a local help file."));
- QWhatsThis::add(m_pbChooseHtml,i18n("Start the konqueror to choose a WEB url as help file. This url should be copied inzo the edit widget."));
+ TQWhatsThis::add(m_leMenuEntry,i18n("The menu entry for this help file."));
+ TQWhatsThis::add(m_leHelpFile,i18n("The name of the local help file or a valid WEB url."));
+ TQWhatsThis::add(m_pbChooseFile,i18n("Start a file dialog to choose a local help file."));
+ TQWhatsThis::add(m_pbChooseHtml,i18n("Start the konqueror to choose a WEB url as help file. This url should be copied inzo the edit widget."));
- connect( m_pbChooseFile, SIGNAL( clicked() ), this, SLOT( slotChooseFile() ) );
- connect( m_pbChooseHtml, SIGNAL( clicked() ), this, SLOT( slotChooseHtml() ) );
+ connect( m_pbChooseFile, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotChooseFile() ) );
+ connect( m_pbChooseHtml, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotChooseHtml() ) );
setFocusProxy( m_leMenuEntry );
- resize(500,sizeHint().height());
+ resize(500,tqsizeHint().height());
}
void UserHelpAddDialog::slotChooseFile()
{
- QString directory = QDir::currentDirPath();
- QString filter = "*.*|All Files\n*.dvi|DVI Files\n*.ps|PS Files\n*.pdf|PDF Files\n*.html *.htm|HTML Files";
+ TQString directory = TQDir::currentDirPath();
+ TQString filter = "*.*|All Files\n*.dvi|DVI Files\n*.ps|PS Files\n*.pdf|PDF Files\n*.html *.htm|HTML Files";
- QString filename = KFileDialog::getOpenFileName( directory,filter,this,i18n("Select File") );
+ TQString filename = KFileDialog::getOpenFileName( directory,filter,this,i18n("Select File") );
if ( filename.isEmpty() )
return;
- QFileInfo fi(filename);
+ TQFileInfo fi(filename);
if ( ! fi.exists() )
{
- KMessageBox::error(0,QString(i18n("File '%1' does not exist.")).arg(filename));
+ KMessageBox::error(0,TQString(i18n("File '%1' does not exist.")).tqarg(filename));
return;
}
@@ -428,7 +428,7 @@ void UserHelpAddDialog::slotChooseHtml()
void UserHelpAddDialog::slotOk()
{
m_leMenuEntry->setText( m_leMenuEntry->text().stripWhiteSpace() );
- QString filename = m_leHelpFile->text().stripWhiteSpace();
+ TQString filename = m_leHelpFile->text().stripWhiteSpace();
m_leHelpFile->setText( filename );
if ( m_leMenuEntry->text().isEmpty() )
@@ -437,7 +437,7 @@ void UserHelpAddDialog::slotOk()
return;
}
- if ( m_menulistbox->findItem(m_leMenuEntry->text(),Qt::ExactMatch) )
+ if ( m_menulistbox->tqfindItem(m_leMenuEntry->text(),TQt::ExactMatch) )
{
KMessageBox::error(this,i18n("This menuitem already exists."));
return;
@@ -449,10 +449,10 @@ void UserHelpAddDialog::slotOk()
return;
}
- QFileInfo fi(filename);
- if ( filename.find("http://",0)!=0 && !fi.exists() )
+ TQFileInfo fi(filename);
+ if ( filename.tqfind("http://",0)!=0 && !fi.exists() )
{
- KMessageBox::error(this,QString(i18n("File '%1' doesn't exist.")).arg(filename));
+ KMessageBox::error(this,TQString(i18n("File '%1' doesn't exist.")).tqarg(filename));
return;
}
diff --git a/src/kile/userhelpdialog.h b/src/kile/userhelpdialog.h
index 9c87ab8..83beeea 100644
--- a/src/kile/userhelpdialog.h
+++ b/src/kile/userhelpdialog.h
@@ -19,8 +19,8 @@
#ifndef USERHELPDIALOG_H
#define USERHELPDIALOG_H
-#include <qwidget.h>
-#include <qstringlist.h>
+#include <tqwidget.h>
+#include <tqstringlist.h>
#include <klistbox.h>
#include <klineedit.h>
@@ -33,19 +33,20 @@ namespace KileDialog
class UserHelpDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- UserHelpDialog(QWidget *parent=0, const char *name=0);
+ UserHelpDialog(TQWidget *tqparent=0, const char *name=0);
~UserHelpDialog() {}
- void setParameter(const QStringList &menuentries, const QStringList &helpfiles);
- void getParameter(QStringList &userhelpmenulist, QStringList &userhelpfilelist);
+ void setParameter(const TQStringList &menuentries, const TQStringList &helpfiles);
+ void getParameter(TQStringList &userhelpmenulist, TQStringList &userhelpfilelist);
private:
KListBox *m_menulistbox;
KLineEdit *m_fileedit;
KPushButton *m_add, *m_remove, *m_addsep, *m_up, *m_down;
- QStringList m_filelist;
+ TQStringList m_filelist;
void updateButton();
@@ -61,9 +62,10 @@ private slots:
class UserHelpAddDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- UserHelpAddDialog(KListBox *menulistbox, QWidget *parent=0, const char *name=0);
+ UserHelpAddDialog(KListBox *menulistbox, TQWidget *tqparent=0, const char *name=0);
~UserHelpAddDialog() {}
private:
@@ -72,8 +74,8 @@ private:
KListBox *m_menulistbox;
public:
- QString getMenuitem() { return m_leMenuEntry->text(); }
- QString getHelpfile() { return m_leHelpFile->text(); }
+ TQString getMenuitem() { return m_leMenuEntry->text(); }
+ TQString getHelpfile() { return m_leHelpFile->text(); }
private slots:
void slotChooseFile();
diff --git a/src/kile/usermenudialog.cpp b/src/kile/usermenudialog.cpp
index 5f26966..6b49fb9 100644
--- a/src/kile/usermenudialog.cpp
+++ b/src/kile/usermenudialog.cpp
@@ -14,13 +14,13 @@
***************************************************************************/
#include "usermenudialog.h"
-#include <qlabel.h>
-#include <qlineedit.h>
-#include <qlayout.h>
-#include <qcombobox.h>
-#include <qregexp.h>
-#include <qradiobutton.h>
-#include <qbuttongroup.h>
+#include <tqlabel.h>
+#include <tqlineedit.h>
+#include <tqlayout.h>
+#include <tqcombobox.h>
+#include <tqregexp.h>
+#include <tqradiobutton.h>
+#include <tqbuttongroup.h>
#include <kpushbutton.h>
#include <klocale.h>
@@ -30,43 +30,43 @@
namespace KileDialog
{
-UserTags::UserTags(const QValueList<KileAction::TagData> &list, QWidget* parent, const char* name, const QString &caption)
- : KDialogBase(parent,name,true,caption,KDialogBase::Apply|KDialogBase::Cancel, KDialogBase::Apply, true),
+UserTags::UserTags(const TQValueList<KileAction::TagData> &list, TQWidget* tqparent, const char* name, const TQString &caption)
+ : KDialogBase(tqparent,name,true,caption,KDialogBase::Apply|KDialogBase::Cancel, KDialogBase::Apply, true),
m_list(list)
{
- QWidget *page = new QWidget( this );
+ TQWidget *page = new TQWidget( this );
setMainWidget(page);
- QGridLayout *gbox = new QGridLayout( page, 6, 3,5,5,"");
+ TQGridLayout *gbox = new TQGridLayout( page, 6, 3,5,5,"");
gbox->addRowSpacing( 0, fontMetrics().lineSpacing() );
- m_combo=new QComboBox(page,"combo");
- connect(m_combo, SIGNAL(activated(int)),this,SLOT(change(int)));
+ m_combo=new TQComboBox(page,"combo");
+ connect(m_combo, TQT_SIGNAL(activated(int)),this,TQT_SLOT(change(int)));
- m_labelName = new QLabel( page, "label1" );
+ m_labelName = new TQLabel( page, "label1" );
m_labelName->setText(i18n("Menu item:"));
- m_editName =new QLineEdit(page,"name");
+ m_editName =new TQLineEdit(page,"name");
- m_labelTag = new QLabel( page, "label2" );
+ m_labelTag = new TQLabel( page, "label2" );
m_labelTag->setText(i18n("Value:"));
m_editTag=new KTextEdit(page,"tag");
- m_editTag->setTextFormat(Qt::PlainText);
+ m_editTag->setTextFormat(TQt::PlainText);
m_buttonAdd = new KPushButton(i18n("Add"),page);
m_buttonInsert = new KPushButton(i18n("Insert"),page);
m_buttonRemove = new KPushButton(i18n("Remove"),page);
- connect(m_buttonAdd, SIGNAL(clicked()) , this , SLOT(slotAdd()));
- connect(m_buttonInsert, SIGNAL(clicked()) , this , SLOT(slotInsert()));
- connect(m_buttonRemove, SIGNAL(clicked()) , this , SLOT(slotRemove()));
+ connect(m_buttonAdd, TQT_SIGNAL(clicked()) , this , TQT_SLOT(slotAdd()));
+ connect(m_buttonInsert, TQT_SIGNAL(clicked()) , this , TQT_SLOT(slotInsert()));
+ connect(m_buttonRemove, TQT_SIGNAL(clicked()) , this , TQT_SLOT(slotRemove()));
gbox->addMultiCellWidget(m_combo,0,0,0,2,0);
gbox->addMultiCellWidget(m_labelName,1,1,0,2,0);
gbox->addMultiCellWidget(m_editName,2,2,0,2,0);
gbox->addMultiCellWidget(m_labelTag,3,3,0,2,0);
gbox->addMultiCellWidget(m_editTag,4,4,0,2,0);
- gbox->addWidget(m_buttonAdd, 5,0, Qt::AlignLeft);
- gbox->addWidget(m_buttonInsert, 5,1, Qt::AlignLeft);
- gbox->addWidget(m_buttonRemove, 5,2, Qt::AlignLeft);
+ gbox->addWidget(m_buttonAdd, 5,0, TQt::AlignLeft);
+ gbox->addWidget(m_buttonInsert, 5,1, TQt::AlignLeft);
+ gbox->addWidget(m_buttonRemove, 5,2, TQt::AlignLeft);
resize(350,150);
@@ -80,14 +80,14 @@ UserTags::~UserTags()
void UserTags::redraw()
{
- KILE_DEBUG() << QString("usermenudialog redraw() m_prevIndex = %1, m_list.size() = %2").arg(m_prevIndex).arg(m_list.size()) << endl;
+ KILE_DEBUG() << TQString("usermenudialog redraw() m_prevIndex = %1, m_list.size() = %2").tqarg(m_prevIndex).tqarg(m_list.size()) << endl;
m_combo->clear();
if (m_list.size() > 0)
{
for (uint i=0; i<m_list.size(); ++i)
{
- m_combo->insertItem( QString::number(i+1) + ": " + m_list[i].text );
+ m_combo->insertItem( TQString::number(i+1) + ": " + m_list[i].text );
}
m_combo->setCurrentItem(m_prevIndex);
@@ -103,10 +103,10 @@ void UserTags::redraw()
void UserTags::change(int index)
{
- KILE_DEBUG() << QString("usermenudialog: change(%1) prev %2").arg(index).arg(m_prevIndex) << endl;
+ KILE_DEBUG() << TQString("usermenudialog: change(%1) prev %2").tqarg(index).tqarg(m_prevIndex) << endl;
m_list[m_prevIndex] = splitTag(m_editName->text(), m_editTag->text());
- m_combo->changeItem(QString::number(m_prevIndex+1)+": "+m_list[m_prevIndex].text, m_prevIndex);
+ m_combo->changeItem(TQString::number(m_prevIndex+1)+": "+m_list[m_prevIndex].text, m_prevIndex);
m_editTag->setText( completeTag(m_list[index]) );
m_editName->setText(m_list[index].text);
@@ -152,7 +152,7 @@ void UserTags::slotRemove()
}
}
-QString UserTags::completeTag(const KileAction::TagData & td)
+TQString UserTags::completeTag(const KileAction::TagData & td)
{
if ( td.tagEnd.length() == 0 )
return td.tagBegin;
@@ -160,18 +160,18 @@ QString UserTags::completeTag(const KileAction::TagData & td)
return td.tagBegin + "%M" + td.tagEnd;
}
-KileAction::TagData UserTags::splitTag(const QString & name, const QString & tag)
+KileAction::TagData UserTags::splitTag(const TQString & name, const TQString & tag)
{
- QStringList parts = QStringList::split("%M", tag);
+ TQStringList parts = TQStringList::split("%M", tag);
int dx = parts[0].length();
if ( parts[1].length() == 0 )
{
- int i = parts[0].find(QRegExp("[\\[\\{\\(]"));
+ int i = parts[0].tqfind(TQRegExp("[\\[\\{\\(]"));
if ( i != -1 )
dx = i + 1;
}
- return KileAction::TagData(name, parts[0], parts[1], dx, 0, QString::null);
+ return KileAction::TagData(name, parts[0], parts[1], dx, 0, TQString());
}
}
diff --git a/src/kile/usermenudialog.h b/src/kile/usermenudialog.h
index 38f1ecc..edd1fb0 100644
--- a/src/kile/usermenudialog.h
+++ b/src/kile/usermenudialog.h
@@ -15,18 +15,18 @@
#ifndef USERMENUDIALOG_H
#define USERMENUDIALOG_H
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <kdialogbase.h>
#include "kileactions.h"
-class QRadioButton;
+class TQRadioButton;
class KTextEdit;
-class QLineEdit;
-class QComboBox;
-class QLabel;
+class TQLineEdit;
+class TQComboBox;
+class TQLabel;
class KPushButton;
namespace KileDialog
@@ -35,16 +35,17 @@ namespace KileDialog
class UserTags: public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- UserTags( const QValueList<KileAction::TagData> &list, QWidget* parent = 0, const char* name = 0, const QString &caption = QString::null);
+ UserTags( const TQValueList<KileAction::TagData> &list, TQWidget* tqparent = 0, const char* name = 0, const TQString &caption = TQString());
~UserTags();
int index() { return m_prevIndex; }
- const QValueList<KileAction::TagData>& result() {return m_list; }
+ const TQValueList<KileAction::TagData>& result() {return m_list; }
- static QString completeTag(const KileAction::TagData & td);
- static KileAction::TagData splitTag(const QString & name, const QString & tag);
+ static TQString completeTag(const KileAction::TagData & td);
+ static KileAction::TagData splitTag(const TQString & name, const TQString & tag);
private slots:
void change(int index);
@@ -59,13 +60,13 @@ private slots:
private:
int m_prevIndex;
KTextEdit *m_editTag;
- QLineEdit *m_editName;
- QComboBox *m_combo;
- QLabel *m_labelName;
- QLabel *m_labelTag;
+ TQLineEdit *m_editName;
+ TQComboBox *m_combo;
+ TQLabel *m_labelName;
+ TQLabel *m_labelTag;
KPushButton *m_buttonRemove, *m_buttonAdd, *m_buttonInsert;
- QValueList<KileAction::TagData> m_list;
+ TQValueList<KileAction::TagData> m_list;
};
}