diff --git a/kxmleditor/dcopiface_shell.cpp b/kxmleditor/dcopiface_shell.cpp index a03d149..09ac715 100644 --- a/kxmleditor/dcopiface_shell.cpp +++ b/kxmleditor/dcopiface_shell.cpp @@ -18,7 +18,7 @@ #include "dcopiface_shell.h" #include "kxmleditorshell.h" -QString +TQString KXMLEditorShellIface::Quit() { // m_pKXEShell->close(); diff --git a/kxmleditor/dcopiface_shell.h b/kxmleditor/dcopiface_shell.h index 63a0f8c..8353dd3 100644 --- a/kxmleditor/dcopiface_shell.h +++ b/kxmleditor/dcopiface_shell.h @@ -54,7 +54,7 @@ k_dcop: * * @returns Error description or empty string if program closed. **/ - QString Quit(); + TQString Quit(); /** diff --git a/kxmleditor/kxeshellmanager.cpp b/kxmleditor/kxeshellmanager.cpp index b20b1af..c5d2832 100644 --- a/kxmleditor/kxeshellmanager.cpp +++ b/kxmleditor/kxeshellmanager.cpp @@ -12,7 +12,7 @@ #include "kxeshellmanager.h" #include "kxmleditorshell.h" -#include +#include KXEShellManager::KXEShellManager() { @@ -49,7 +49,7 @@ void KXEShellManager::removeShell(KXMLEditorShell* pShell) /*! \fn KXEShellManager::shells() */ -QPtrList* KXEShellManager::shells() +TQPtrList* KXEShellManager::shells() { return &m_shells; } diff --git a/kxmleditor/kxeshellmanager.h b/kxmleditor/kxeshellmanager.h index 0eeff8e..ac93cac 100644 --- a/kxmleditor/kxeshellmanager.h +++ b/kxmleditor/kxeshellmanager.h @@ -15,7 +15,7 @@ @file */ -#include +#include class KXMLEditorShell; @@ -55,11 +55,11 @@ public: void removeShell(KXMLEditorShell* pShell); /** @short Returns list of currently opened shells. */ - QPtrList *shells(); + TQPtrList *shells(); private: /** @short Internally stores list of available shells. */ - QPtrList m_shells; + TQPtrList m_shells; }; #endif diff --git a/kxmleditor/kxmleditorshell.cpp b/kxmleditor/kxmleditorshell.cpp index e3715cc..8299bc3 100644 --- a/kxmleditor/kxmleditorshell.cpp +++ b/kxmleditor/kxmleditorshell.cpp @@ -38,7 +38,7 @@ #include -#include +#include #include "dcopiface_shell.h" @@ -116,7 +116,7 @@ void KXMLEditorShell::slotFileOpen() { statusBar()->message( i18n("Opening file...") ); - KURL url = KFileDialog::getOpenURL( QString::null, + KURL url = KFileDialog::getOpenURL( TQString::null, i18n(FILE_DIALOG_FILTER), this ); openURL(url); @@ -261,7 +261,7 @@ void KXMLEditorShell::readProperties( KConfig * pConfig ) KParts::MainWindow::readProperties(pConfig); /// @todo Check if ths is a deadcode -// QString strURL = pConfig->readEntry( "CurrentURL", "" ); +// TQString strURL = pConfig->readEntry( "CurrentURL", "" ); // if ( strURL.isEmpty()) // part()->openURL( strURL ); } @@ -277,7 +277,7 @@ void KXMLEditorShell::slotEnableBrowserExtActions( const char * pszName, bool bE // Set main window caption (by using the base class functionality), // Enables/disables Save button (corresponding to the parts modified status) -void KXMLEditorShell::setCaption( const QString & strCaption ) +void KXMLEditorShell::setCaption( const TQString & strCaption ) { if (part()) { @@ -335,14 +335,14 @@ void KXMLEditorShell::mail() if (!part()->url().isEmpty()) { - QStringList urls(part()->url().url()); // we can prepare then list of attachments (1 element in the list) - QString theSubject(part()->url().fileName(false)); // and set the mail subject - kapp->invokeMailer(QString::null, // finally we can compose e-mail (addressed to no-one) out of that - QString::null, - QString::null, + TQStringList urls(part()->url().url()); // we can prepare then list of attachments (1 element in the list) + TQString theSubject(part()->url().fileName(false)); // and set the mail subject + kapp->invokeMailer(TQString::null, // finally we can compose e-mail (addressed to no-one) out of that + TQString::null, + TQString::null, theSubject, // subject - QString::null, // body - QString::null, + TQString::null, // body + TQString::null, urls); // attachments } } @@ -398,12 +398,12 @@ void KXMLEditorShell::setPart(KParts::ReadWritePart* pPart) connect(m_windowMenu,SIGNAL(aboutToShow()),this,SLOT(slotBeforeWindowMenuShown())); } -KParts::ReadWritePart* KXMLEditorShell::createXMLPart(QObject *parent) +KParts::ReadWritePart* KXMLEditorShell::createXMLPart(TQObject *parent) { return createPart(parent,"libkxmleditorpart", "KParts::ReadWritePart"); } -KParts::ReadWritePart* KXMLEditorShell::createPart(QObject *parent, const QString& libName, const QString& className) +KParts::ReadWritePart* KXMLEditorShell::createPart(TQObject *parent, const TQString& libName, const TQString& className) { KParts::ReadWritePart* newPart = 0L; KLibFactory * pFactory = KLibLoader::self()->factory(libName); @@ -432,7 +432,7 @@ void KXMLEditorShell::close() void KXMLEditorShell::slotActWindowCloseAllOthers() { - QPtrListIterator it(*KMainWindow::memberList); + TQPtrListIterator it(*KMainWindow::memberList); for (it.toFirst();it.current();++it) { if (it.current()!=this) @@ -473,7 +473,7 @@ void KXMLEditorShell::slotBeforeWindowMenuShown() // and then we can add entries for all shells // that are registered in Shell Manager... - QPtrListIterator it (*(manager()->shells())); + TQPtrListIterator it (*(manager()->shells())); for (it.toFirst(); it.current();++it) { int id = m_windowMenu->insertItem(it.current()->caption(),it.current(),SLOT(slotActivate())); diff --git a/kxmleditor/kxmleditorshell.h b/kxmleditor/kxmleditorshell.h index 848e47a..1f0f0a1 100644 --- a/kxmleditor/kxmleditorshell.h +++ b/kxmleditor/kxmleditorshell.h @@ -64,9 +64,9 @@ class KXMLEditorShell : public KParts::MainWindow /** @short Creates new part which can be shown in the shell. @param parent parent object for the part*/ - static KParts::ReadWritePart* createXMLPart(QObject *parent) ; + static KParts::ReadWritePart* createXMLPart(TQObject *parent) ; - static KParts::ReadWritePart* createPart(QObject *parent, const QString& libName, const QString& className); + static KParts::ReadWritePart* createPart(TQObject *parent, const TQString& libName, const TQString& className); /** @short Changes currenly shown part. */ void setPart(KParts::ReadWritePart* pPart); @@ -96,7 +96,7 @@ class KXMLEditorShell : public KParts::MainWindow void slotConfigureToolbars(); /** @short Changes shell caption.*/ - virtual void setCaption( const QString & strCaption ); + virtual void setCaption( const TQString & strCaption ); /** @short Sends currently opened XML file over e-mail. diff --git a/kxmleditor/main.cpp b/kxmleditor/main.cpp index 23b1f8a..0bbfc79 100644 --- a/kxmleditor/main.cpp +++ b/kxmleditor/main.cpp @@ -58,7 +58,7 @@ int main(int argc, char *argv[]) KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); if(args->count()) - { QString strPath; + { TQString strPath; if(args->count() > 1) { strPath = args->arg(1); diff --git a/part/actions.cpp b/part/actions.cpp index 13f1260..7076e09 100644 --- a/part/actions.cpp +++ b/part/actions.cpp @@ -19,10 +19,10 @@ // include files for QT -#include -#include -#include -#include +#include +#include +#include +#include // include files for KDE #include @@ -36,11 +36,11 @@ // //------------------------------------------------------------------- -KXmlEditorComboAction::KXmlEditorComboAction(const QString& text, +KXmlEditorComboAction::KXmlEditorComboAction(const TQString& text, int accel, - const QObject *receiver, + const TQObject *receiver, const char *member, - QObject* parent, + TQObject* parent, const char* name) : KAction(text, accel, parent, name), m_pCombo(0) @@ -54,12 +54,12 @@ KXmlEditorComboAction::~KXmlEditorComboAction() //delete m_pCombo; // L.V. this cause crash !!! } -QComboBox* KXmlEditorComboAction::comboBox() +TQComboBox* KXmlEditorComboAction::comboBox() { return m_pCombo; } -int KXmlEditorComboAction::plug(QWidget *w, int index) +int KXmlEditorComboAction::plug(TQWidget *w, int index) { // if ( !w->inherits( "KToolBar" ) ); // return -1; @@ -69,11 +69,11 @@ int KXmlEditorComboAction::plug(QWidget *w, int index) int id = KAction::getToolButtonID(); //kdDebug() << "KXmlEditorComboAction::plug id=" << id << endl; - m_pCombo = new QComboBox( toolBar, "Path Combo" ); + m_pCombo = new TQComboBox( toolBar, "Path Combo" ); m_pCombo->setEditable(true); - m_pCombo->setInsertionPolicy(QComboBox::NoInsertion); + m_pCombo->setInsertionPolicy(TQComboBox::NoInsertion); toolBar->insertWidget( id, 70, m_pCombo, index ); - connect( m_pCombo, SIGNAL(activated(const QString&)), m_receiver, m_member ); + connect( m_pCombo, SIGNAL(activated(const TQString&)), m_receiver, m_member ); addContainer( toolBar, id ); @@ -81,12 +81,12 @@ int KXmlEditorComboAction::plug(QWidget *w, int index) toolBar->setItemAutoSized(id, true); - QWhatsThis::add( m_pCombo, whatsThis() ); + TQWhatsThis::add( m_pCombo, whatsThis() ); return containerCount() - 1; } -void KXmlEditorComboAction::unplug(QWidget *w) +void KXmlEditorComboAction::unplug(TQWidget *w) { // if ( !w->inherits( "KToolBar" ) ) // return; @@ -135,18 +135,18 @@ void KXmlEditorComboAction::slotFocusEdit() m_pCombo->setFocus(); } -QString KXmlEditorComboAction::currentText() const +TQString KXmlEditorComboAction::currentText() const { if ( containerCount() == 0 ) { kdWarning() << "[KXmlEditorComboAction::currentText] action not plugged" << endl; - return QString::null; + return TQString::null; } return m_pCombo->currentText(); } -const QPixmap * KXmlEditorComboAction::currentPixmap() const +const TQPixmap * KXmlEditorComboAction::currentPixmap() const { if ( containerCount() == 0 ) { @@ -157,7 +157,7 @@ const QPixmap * KXmlEditorComboAction::currentPixmap() const return m_pCombo->pixmap( m_pCombo->currentItem() ); } -void KXmlEditorComboAction::insertItem( const QPixmap & pixmap, const QString & text ) +void KXmlEditorComboAction::insertItem( const TQPixmap & pixmap, const TQString & text ) { if ( containerCount() == 0 ) { @@ -179,7 +179,7 @@ void KXmlEditorComboAction::insertItem( const QPixmap & pixmap, const QString & m_pCombo->removeItem(15); } -void KXmlEditorComboAction::removeItem( const QString & text ) +void KXmlEditorComboAction::removeItem( const TQString & text ) { if ( containerCount() == 0 ) { @@ -197,7 +197,7 @@ void KXmlEditorComboAction::removeItem( const QString & text ) m_pCombo->removeItem(nIndex); } -int KXmlEditorComboAction::findItem( const QString & text ) +int KXmlEditorComboAction::findItem( const TQString & text ) { if ( containerCount() == 0 ) { @@ -217,13 +217,13 @@ int KXmlEditorComboAction::findItem( const QString & text ) return nIndex; } -ToolbarLabel::ToolbarLabel( const QString& text ) - : QLabel( text, 0L, "kde toolbar widget" ) // Use this name for it to be styled! +ToolbarLabel::ToolbarLabel( const TQString& text ) + : TQLabel( text, 0L, "kde toolbar widget" ) // Use this name for it to be styled! // , m_mw(mw) { - setBackgroundMode( Qt::PaletteButton ); - setAlignment( (QApplication::reverseLayout() ? Qt::AlignRight : Qt::AlignLeft) | - Qt::AlignVCenter | Qt::ShowPrefix ); + setBackgroundMode( TQt::PaletteButton ); + setAlignment( (TQApplication::reverseLayout() ? TQt::AlignRight : TQt::AlignLeft) | + TQt::AlignVCenter | TQt::ShowPrefix ); adjustSize(); } diff --git a/part/actions.h b/part/actions.h index 43d0967..3956c74 100644 --- a/part/actions.h +++ b/part/actions.h @@ -19,8 +19,8 @@ #define ACTIONS_H #include -#include -class QComboBox; +#include +class TQComboBox; /** *@author Lumir Vanek @@ -30,33 +30,33 @@ class KXmlEditorComboAction : public KAction { Q_OBJECT public: - KXmlEditorComboAction(const QString& text, int accel, const QObject *receiver, const char *member, QObject* parent, const char* name); + KXmlEditorComboAction(const TQString& text, int accel, const TQObject *receiver, const char *member, TQObject* parent, const char* name); ~KXmlEditorComboAction(); - virtual int plug(QWidget *w, int index = -1); + virtual int plug(TQWidget *w, int index = -1); - virtual void unplug(QWidget *w); + virtual void unplug(TQWidget *w); - /** Returns the text from the combobox' editline (@ref QComboBox::currentText). */ - QString currentText() const; + /** Returns the text from the combobox' editline (@ref TQComboBox::currentText). */ + TQString currentText() const; - /** Returns the current pixmap or 0, if there isn't any (see @ref QComboBox::pixmap). */ - const QPixmap * currentPixmap() const; + /** Returns the current pixmap or 0, if there isn't any (see @ref TQComboBox::pixmap). */ + const TQPixmap * currentPixmap() const; /** * Inserts the given item as the first. * Deletes the old entry, if the item was already in the list. */ - void insertItem( const QPixmap & pixmap, const QString & text ); + void insertItem( const TQPixmap & pixmap, const TQString & text ); /** Tries to remove the item with the given text. */ - void removeItem( const QString & text ); + void removeItem( const TQString & text ); /** returns combo box */ - QComboBox *comboBox(); + TQComboBox *comboBox(); public slots: - /** Clears the whole combobox using @ref QComboBox::clear. */ + /** Clears the whole combobox using @ref TQComboBox::clear. */ void slotClear(); /** Clears the combobox' editline. */ void slotClearEdit(); @@ -68,20 +68,20 @@ protected: * Tries to find an item with the given text. If it finds it, * the items id is returned, otherwise -1. */ - virtual int findItem( const QString & text ); + virtual int findItem( const TQString & text ); private: - const QObject *m_receiver; + const TQObject *m_receiver; const char *m_member; - QComboBox * m_pCombo; + TQComboBox * m_pCombo; }; -class ToolbarLabel : public QLabel +class ToolbarLabel : public TQLabel { Q_OBJECT public: - ToolbarLabel( const QString & text ); + ToolbarLabel( const TQString & text ); }; diff --git a/part/commands_edit.cpp b/part/commands_edit.cpp index ba298b0..d899479 100644 --- a/part/commands_edit.cpp +++ b/part/commands_edit.cpp @@ -22,7 +22,7 @@ /////////// Cutting element to clipboard ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXECutCommand::KXECutCommand(KXEDocument *pDocument, QDomNode &domNode) +KXECutCommand::KXECutCommand(KXEDocument *pDocument, TQDomNode &domNode) : KXEDeleteNodeCommand(pDocument, domNode) { } @@ -37,8 +37,8 @@ KXECutCommand::~KXECutCommand() KXEPasteToDocumentCommand::KXEPasteToDocumentCommand( KXEDocument *pDocument, - QDomDocument *pDomTargetDoc, - QDomElement &domSourceElement + TQDomDocument *pDomTargetDoc, + TQDomElement &domSourceElement ) : KXECommand(pDocument) { @@ -56,14 +56,14 @@ KXEPasteToDocumentCommand::~KXEPasteToDocumentCommand() void KXEPasteToDocumentCommand::execute() { // Insert root element - QDomNode newNode = m_pDomTargetDoc->importNode(m_domSourceElement, true); + TQDomNode newNode = m_pDomTargetDoc->importNode(m_domSourceElement, true); m_pDomTargetDoc->appendChild(newNode); m_pDocument->updateNodeCreated(newNode); } void KXEPasteToDocumentCommand::unexecute() { - QDomNode removedNode = m_pDomTargetDoc->removeChild( m_pDomTargetDoc->documentElement()); + TQDomNode removedNode = m_pDomTargetDoc->removeChild( m_pDomTargetDoc->documentElement()); if ( removedNode.isNull() ) kdError() << "KXEPasteToDocumentCommand::unexecute error removing node." << endl; @@ -79,8 +79,8 @@ void KXEPasteToDocumentCommand::unexecute() KXEPasteToElementCommand::KXEPasteToElementCommand( KXEDocument *pDocument, - QDomElement & domTargetElement, - QDomNode &domSourceNode + TQDomElement & domTargetElement, + TQDomNode &domSourceNode ) : KXECommand(pDocument) { @@ -117,8 +117,8 @@ void KXEPasteToElementCommand::unexecute() KXEPasteToProcInstrCommand::KXEPasteToProcInstrCommand( KXEDocument *pDocument, - QDomProcessingInstruction &domTargetProcInstr, - QDomProcessingInstruction &domSourceProcInstr + TQDomProcessingInstruction &domTargetProcInstr, + TQDomProcessingInstruction &domSourceProcInstr ) : KXECommand(pDocument) { @@ -158,8 +158,8 @@ void KXEPasteToProcInstrCommand::unexecute() KXEPasteToCharDataCommand::KXEPasteToCharDataCommand( KXEDocument *pDocument, - QDomCharacterData &domTargetCharData, - QDomCharacterData &domSourceCharData + TQDomCharacterData &domTargetCharData, + TQDomCharacterData &domSourceCharData ) : KXECommand(pDocument) { @@ -197,8 +197,8 @@ void KXEPasteToCharDataCommand::unexecute() KXEDragDropMoveCommand::KXEDragDropMoveCommand( KXEDocument *pDocument, - QDomElement & domTargetElement, - QDomNode &domSourceNode + TQDomElement & domTargetElement, + TQDomNode &domSourceNode ) : KXECommand(pDocument) { @@ -247,7 +247,7 @@ void KXEDragDropMoveCommand::unexecute() /////////// Deleting node ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXEDeleteNodeCommand::KXEDeleteNodeCommand(KXEDocument *pDocument, QDomNode &domNode) +KXEDeleteNodeCommand::KXEDeleteNodeCommand(KXEDocument *pDocument, TQDomNode &domNode) : KXECommand(pDocument) { m_domNode = domNode; @@ -288,8 +288,8 @@ void KXEDeleteNodeCommand::unexecute() KXEDeleteAttrCommand::KXEDeleteAttrCommand( KXEDocument *pDocument, - QDomElement &domOwnerElement, - QDomAttr &domAttr + TQDomElement &domOwnerElement, + TQDomAttr &domAttr ) : KXECommand(pDocument) { @@ -319,7 +319,7 @@ void KXEDeleteAttrCommand::unexecute() KXEDeleteAllAttribCommand::KXEDeleteAllAttribCommand( KXEDocument *pDocument, - QDomElement &domOwnerElement + TQDomElement &domOwnerElement ) : KXECommand(pDocument) { @@ -333,7 +333,7 @@ KXEDeleteAllAttribCommand::~KXEDeleteAllAttribCommand() void KXEDeleteAllAttribCommand::execute() { - QDomNamedNodeMap mapAttributes = m_domOwnerElement.attributes(); + TQDomNamedNodeMap mapAttributes = m_domOwnerElement.attributes(); uint nAttributes = mapAttributes.count(); if( nAttributes == 0 ) @@ -341,11 +341,11 @@ void KXEDeleteAllAttribCommand::execute() for( uint nRow = nAttributes; nRow > 0; nRow-- ) { - QDomNode node = mapAttributes.item(nRow-1); + TQDomNode node = mapAttributes.item(nRow-1); if ( node.isAttr() ) - { QDomAttr domAttr = node.toAttr(); + { TQDomAttr domAttr = node.toAttr(); - QDomAttr *pNodeCloned = new QDomAttr(domAttr.cloneNode(true).toAttr()); + TQDomAttr *pNodeCloned = new TQDomAttr(domAttr.cloneNode(true).toAttr()); m_listRemovedAttributes.append(pNodeCloned); m_domOwnerElement.removeAttributeNode(node.toAttr()); @@ -359,13 +359,13 @@ void KXEDeleteAllAttribCommand::execute() void KXEDeleteAllAttribCommand::unexecute() { - QDomNamedNodeMap mapAttributes = m_domOwnerElement.attributes(); + TQDomNamedNodeMap mapAttributes = m_domOwnerElement.attributes(); uint nAttributes = m_listRemovedAttributes.count(); if ( nAttributes == 0 ) return; - QDomAttr *pDomAttr; + TQDomAttr *pDomAttr; for ( pDomAttr = m_listRemovedAttributes.first(); pDomAttr; pDomAttr = m_listRemovedAttributes.next() ) { if(!pDomAttr->namespaceURI().isEmpty()) @@ -383,7 +383,7 @@ void KXEDeleteAllAttribCommand::unexecute() /////////// Moving node up ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXEUpCommand::KXEUpCommand(KXEDocument *pDocument, QDomNode &domNode) +KXEUpCommand::KXEUpCommand(KXEDocument *pDocument, TQDomNode &domNode) : KXECommand(pDocument) { m_domNode = domNode; @@ -399,14 +399,14 @@ KXEUpCommand::~KXEUpCommand() void KXEUpCommand::execute() { - QDomNode domPrevSibling = m_domNode.previousSibling(); + TQDomNode domPrevSibling = m_domNode.previousSibling(); if ( domPrevSibling.isNull() ) { kdError() << "KXEUpCommand::execute selected node doesn't seem to have a previous sibling." << endl; return; } - QDomNode domNode = m_domParentNode.removeChild( m_domNode ); + TQDomNode domNode = m_domParentNode.removeChild( m_domNode ); if ( domNode.isNull() ) kdError() << "KXEUpCommand::execute can't remove child node." << endl; else @@ -423,14 +423,14 @@ void KXEUpCommand::execute() void KXEUpCommand::unexecute() { - QDomNode domNextSibling = m_domNode.nextSibling(); + TQDomNode domNextSibling = m_domNode.nextSibling(); if ( domNextSibling.isNull() ) { kdError() << "KXEUpCommand::unexecute selected node doesn't seem to have a next sibling." << endl; return; } - QDomNode domNode = m_domParentNode.removeChild( m_domNode ); + TQDomNode domNode = m_domParentNode.removeChild( m_domNode ); if ( domNode.isNull() ) kdError() << "KXEUpCommand::unexecute can't remove child node." << endl; else @@ -449,7 +449,7 @@ void KXEUpCommand::unexecute() /////////// Moving node down ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXEDownCommand::KXEDownCommand(KXEDocument *pDocument, QDomNode &domNode) +KXEDownCommand::KXEDownCommand(KXEDocument *pDocument, TQDomNode &domNode) : KXECommand(pDocument) { m_domNode = domNode; @@ -465,14 +465,14 @@ KXEDownCommand::~KXEDownCommand() void KXEDownCommand::execute() { - QDomNode domNextSibling = m_domNode.nextSibling(); + TQDomNode domNextSibling = m_domNode.nextSibling(); if ( domNextSibling.isNull() ) { kdError() << "KXEDownCommand::execute selected node doesn't seem to have a next sibling." << endl; return; } - QDomNode domNode = m_domParentNode.removeChild( m_domNode ); + TQDomNode domNode = m_domParentNode.removeChild( m_domNode ); if ( domNode.isNull() ) kdError() << "KXEDownCommand::execute can't remove child node." << endl; else @@ -489,14 +489,14 @@ void KXEDownCommand::execute() void KXEDownCommand::unexecute() { - QDomNode domPrevSibling = m_domNode.previousSibling(); + TQDomNode domPrevSibling = m_domNode.previousSibling(); if ( domPrevSibling.isNull() ) { kdError() << "KXEDownCommand::unexecute selected node doesn't seem to have a previous sibling." << endl; return; } - QDomNode domNode = m_domParentNode.removeChild( m_domNode ); + TQDomNode domNode = m_domParentNode.removeChild( m_domNode ); if ( domNode.isNull() ) kdError() << "KXEDownCommand::unexecute can't remove child node." << endl; else @@ -517,8 +517,8 @@ void KXEDownCommand::unexecute() KXEEditCharDataCommand::KXEEditCharDataCommand( KXEDocument *pDocument, - QDomCharacterData &domCharacterData, - const QString strNewContents + TQDomCharacterData &domCharacterData, + const TQString strNewContents ) : KXECommand(pDocument) { @@ -549,8 +549,8 @@ void KXEEditCharDataCommand::unexecute() KXEEditProcInstrCommand::KXEEditProcInstrCommand( KXEDocument *pDocument, - QDomProcessingInstruction &domProcInstr, - const QString strNewData + TQDomProcessingInstruction &domProcInstr, + const TQString strNewData ) : KXECommand(pDocument) { @@ -581,9 +581,9 @@ void KXEEditProcInstrCommand::unexecute() KXEEditElementCommand::KXEEditElementCommand( KXEDocument *pDocument, - QDomElement &domElement, - const QString strNewPrefix, - const QString strNewName + TQDomElement &domElement, + const TQString strNewPrefix, + const TQString strNewName ) : KXECommand(pDocument) { @@ -627,8 +627,8 @@ void KXEEditElementCommand::unexecute() KXEEditAttrValueCommand::KXEEditAttrValueCommand( KXEDocument *pDocument, - const QDomAttr &domAttr, - const QString strNewValue + const TQDomAttr &domAttr, + const TQString strNewValue ) : KXECommand(pDocument) { @@ -662,8 +662,8 @@ void KXEEditAttrValueCommand::unexecute() KXEEditAttrNameCommand::KXEEditAttrNameCommand( KXEDocument *pDocument, - const QDomAttr &domOldAttr, - const QString strNewName + const TQDomAttr &domOldAttr, + const TQString strNewName ) : KXECommand(pDocument) { @@ -722,8 +722,8 @@ void KXEEditAttrNameCommand::unexecute() KXEEditRawXmlCommand::KXEEditRawXmlCommand( KXEDocument *pDocument, - QDomElement &domOldElement, - QDomElement &domNewElement + TQDomElement &domOldElement, + TQDomElement &domNewElement ) : KXECommand(pDocument) { diff --git a/part/commands_edit.h b/part/commands_edit.h index c713861..776ebfc 100644 --- a/part/commands_edit.h +++ b/part/commands_edit.h @@ -21,7 +21,7 @@ #include -#include +#include /** @file @@ -35,21 +35,21 @@ class KXEDeleteNodeCommand : public KXECommand { public: /** @brief Constructor */ - KXEDeleteNodeCommand(KXEDocument*, QDomNode &); + KXEDeleteNodeCommand(KXEDocument*, TQDomNode &); /** @brief Destructor */ ~KXEDeleteNodeCommand(); /** @brief Performs node removal.*/ virtual void execute(); /** @brief Node removal rollback.*/ virtual void unexecute(); - virtual QString name() const { return i18n("Delete node"); } + virtual TQString name() const { return i18n("Delete node"); } protected: /** @short Stores infromation about parent node of the node to be deleted. */ - QDomNode m_domParentNode; + TQDomNode m_domParentNode; /** @short Stores infromation the node to be deleted. */ - QDomNode m_domNode; + TQDomNode m_domNode; /** @short Stores infromation about sibling node of the node to be deleted. */ - QDomNode m_afterNode; + TQDomNode m_afterNode; }; /** @short Command for removing element attributes. @@ -58,19 +58,19 @@ class KXEDeleteAttrCommand : public KXECommand { public: /** @brief Constructor */ - KXEDeleteAttrCommand(KXEDocument*, QDomElement &, QDomAttr &); + KXEDeleteAttrCommand(KXEDocument*, TQDomElement &, TQDomAttr &); /** @brief Destructor */ ~KXEDeleteAttrCommand(); /** @brief Preforms attributte removal. */ virtual void execute(); /** @brief Attributte removal rollback. */ virtual void unexecute(); - virtual QString name() const { return i18n("Delete attribute"); } + virtual TQString name() const { return i18n("Delete attribute"); } protected: /** @brief Stores attribute owner. */ - QDomElement m_domOwnerElement; + TQDomElement m_domOwnerElement; /** @brief Attribute about to be removed. */ - QDomAttr m_domAttr; + TQDomAttr m_domAttr; }; /** @@ -80,15 +80,15 @@ class KXEDeleteAllAttribCommand : public KXECommand { public: /** @brief Constructor */ - KXEDeleteAllAttribCommand(KXEDocument*, QDomElement &); + KXEDeleteAllAttribCommand(KXEDocument*, TQDomElement &); /** @brief Destructor */ ~KXEDeleteAllAttribCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Delete all attributes"); } + virtual TQString name() const { return i18n("Delete all attributes"); } protected: - QDomElement m_domOwnerElement; - QPtrList m_listRemovedAttributes; + TQDomElement m_domOwnerElement; + TQPtrList m_listRemovedAttributes; }; /** @@ -98,10 +98,10 @@ class KXECutCommand : public KXEDeleteNodeCommand { public: /** @brief Constructor */ - KXECutCommand(KXEDocument*, QDomNode &); + KXECutCommand(KXEDocument*, TQDomNode &); /** @brief Destructor */ ~KXECutCommand(); - virtual QString name() const { return i18n("Cut node"); } + virtual TQString name() const { return i18n("Cut node"); } }; /** @@ -111,15 +111,15 @@ class KXEPasteToDocumentCommand : public KXECommand { public: /** @brief Constructor */ - KXEPasteToDocumentCommand(KXEDocument*, QDomDocument *, QDomElement &); + KXEPasteToDocumentCommand(KXEDocument*, TQDomDocument *, TQDomElement &); /** @brief Destructor */ ~KXEPasteToDocumentCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Paste node to document"); } + virtual TQString name() const { return i18n("Paste node to document"); } protected: - QDomDocument * m_pDomTargetDoc; - QDomElement m_domSourceElement; + TQDomDocument * m_pDomTargetDoc; + TQDomElement m_domSourceElement; }; /** @@ -129,47 +129,47 @@ class KXEPasteToElementCommand : public KXECommand { public: /** @brief Constructor */ - KXEPasteToElementCommand(KXEDocument*, QDomElement &, QDomNode &); + KXEPasteToElementCommand(KXEDocument*, TQDomElement &, TQDomNode &); /** @brief Destructor */ ~KXEPasteToElementCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Paste node to element"); } + virtual TQString name() const { return i18n("Paste node to element"); } protected: - QDomElement m_domTargetElement; - QDomNode m_domSourceNode; + TQDomElement m_domTargetElement; + TQDomNode m_domSourceNode; }; class KXEPasteToProcInstrCommand : public KXECommand { public: /** @brief Constructor */ - KXEPasteToProcInstrCommand(KXEDocument*, QDomProcessingInstruction &, QDomProcessingInstruction &); + KXEPasteToProcInstrCommand(KXEDocument*, TQDomProcessingInstruction &, TQDomProcessingInstruction &); /** @brief Destructor */ ~KXEPasteToProcInstrCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Paste node to proc. instruction"); } + virtual TQString name() const { return i18n("Paste node to proc. instruction"); } protected: - QDomProcessingInstruction m_domTargetProcInstr; - QString m_strNewData; - QString m_strOldData; + TQDomProcessingInstruction m_domTargetProcInstr; + TQString m_strNewData; + TQString m_strOldData; }; class KXEPasteToCharDataCommand : public KXECommand { public: /** @brief Constructor */ - KXEPasteToCharDataCommand(KXEDocument*, QDomCharacterData &, QDomCharacterData &); + KXEPasteToCharDataCommand(KXEDocument*, TQDomCharacterData &, TQDomCharacterData &); /** @brief Destructor */ ~KXEPasteToCharDataCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Paste node to char. data"); } + virtual TQString name() const { return i18n("Paste node to char. data"); } protected: - QDomCharacterData m_domTargetCharData; - QString m_strNewData; - QString m_strOldData; + TQDomCharacterData m_domTargetCharData; + TQString m_strNewData; + TQString m_strOldData; }; /** @@ -179,16 +179,16 @@ class KXEDragDropMoveCommand : public KXECommand { public: /** @brief Constructor */ - KXEDragDropMoveCommand(KXEDocument*, QDomElement &, QDomNode &); + KXEDragDropMoveCommand(KXEDocument*, TQDomElement &, TQDomNode &); /** @brief Destructor */ ~KXEDragDropMoveCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Drag&&drop node"); } + virtual TQString name() const { return i18n("Drag&&drop node"); } protected: - QDomElement m_domTargetElement; - QDomNode m_domSourceNode; - QDomNode m_domPreviousParentNode; + TQDomElement m_domTargetElement; + TQDomNode m_domSourceNode; + TQDomNode m_domPreviousParentNode; }; /** @@ -198,15 +198,15 @@ class KXEUpCommand : public KXECommand { public: /** @brief Constructor */ - KXEUpCommand(KXEDocument*, QDomNode &); + KXEUpCommand(KXEDocument*, TQDomNode &); /** @brief Destructor */ ~KXEUpCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Move node up"); } + virtual TQString name() const { return i18n("Move node up"); } protected: - QDomNode m_domParentNode; - QDomNode m_domNode; + TQDomNode m_domParentNode; + TQDomNode m_domNode; }; /** @@ -216,31 +216,31 @@ class KXEDownCommand : public KXECommand { public: /** @brief Constructor */ - KXEDownCommand(KXEDocument*, QDomNode &); + KXEDownCommand(KXEDocument*, TQDomNode &); /** @brief Destructor */ ~KXEDownCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Move node down"); } + virtual TQString name() const { return i18n("Move node down"); } protected: - QDomNode m_domParentNode; - QDomNode m_domNode; + TQDomNode m_domParentNode; + TQDomNode m_domNode; }; class KXEEditCharDataCommand : public KXECommand { public: /** @brief Constructor */ - KXEEditCharDataCommand(KXEDocument*, QDomCharacterData &, const QString); + KXEEditCharDataCommand(KXEDocument*, TQDomCharacterData &, const TQString); /** @brief Destructor */ ~KXEEditCharDataCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Editing character data"); } + virtual TQString name() const { return i18n("Editing character data"); } protected: - QDomCharacterData m_domCharacterData; - QString m_strNewContents; - QString m_strOldContents; + TQDomCharacterData m_domCharacterData; + TQString m_strNewContents; + TQString m_strOldContents; }; /** @@ -250,16 +250,16 @@ class KXEEditProcInstrCommand : public KXECommand { public: /** @brief Constructor */ - KXEEditProcInstrCommand(KXEDocument*, QDomProcessingInstruction &, const QString); + KXEEditProcInstrCommand(KXEDocument*, TQDomProcessingInstruction &, const TQString); /** @brief Destructor */ ~KXEEditProcInstrCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Editing proc. instruction"); } + virtual TQString name() const { return i18n("Editing proc. instruction"); } protected: - QDomProcessingInstruction m_domProcInstr; - QString m_strNewData; - QString m_strOldData; + TQDomProcessingInstruction m_domProcInstr; + TQString m_strNewData; + TQString m_strOldData; }; /** @@ -269,18 +269,18 @@ class KXEEditElementCommand : public KXECommand { public: /** @brief Constructor */ - KXEEditElementCommand(KXEDocument*, QDomElement &, const QString, const QString); + KXEEditElementCommand(KXEDocument*, TQDomElement &, const TQString, const TQString); /** @brief Destructor */ ~KXEEditElementCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Editing element"); } + virtual TQString name() const { return i18n("Editing element"); } protected: - QDomElement m_domElement; - QString m_strNewPrefix; - QString m_strNewName; - QString m_strOldPrefix; - QString m_strOldName; + TQDomElement m_domElement; + TQString m_strNewPrefix; + TQString m_strNewName; + TQString m_strOldPrefix; + TQString m_strOldName; }; /** @@ -290,16 +290,16 @@ class KXEEditAttrValueCommand : public KXECommand { public: /** @brief Constructor */ - KXEEditAttrValueCommand(KXEDocument*, const QDomAttr &, const QString); + KXEEditAttrValueCommand(KXEDocument*, const TQDomAttr &, const TQString); /** @brief Destructor */ ~KXEEditAttrValueCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Edit attribute value"); } + virtual TQString name() const { return i18n("Edit attribute value"); } protected: - QDomAttr m_domAttr; - QString m_strNewValue; - QString m_strOldValue; + TQDomAttr m_domAttr; + TQString m_strNewValue; + TQString m_strOldValue; }; /** @@ -309,18 +309,18 @@ class KXEEditAttrNameCommand : public KXECommand { public: /** @brief Constructor */ - KXEEditAttrNameCommand(KXEDocument*, const QDomAttr &, const QString); + KXEEditAttrNameCommand(KXEDocument*, const TQDomAttr &, const TQString); /** @brief Destructor */ ~KXEEditAttrNameCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Edit attribute name"); } + virtual TQString name() const { return i18n("Edit attribute name"); } protected: - QDomElement m_domOwnerElement; - QString m_strNewName; - QString m_strOldName; - QString m_strValue; - QString m_strNamespaceURI; + TQDomElement m_domOwnerElement; + TQString m_strNewName; + TQString m_strOldName; + TQString m_strValue; + TQString m_strNamespaceURI; }; /** @@ -330,17 +330,17 @@ class KXEEditRawXmlCommand : public KXECommand { public: /** @brief Constructor */ - KXEEditRawXmlCommand(KXEDocument*, QDomElement &, QDomElement &); + KXEEditRawXmlCommand(KXEDocument*, TQDomElement &, TQDomElement &); /** @brief Destructor */ ~KXEEditRawXmlCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Editing raw XML"); } + virtual TQString name() const { return i18n("Editing raw XML"); } protected: - QDomElement m_domOldElement; - QDomNode m_domParentNode; - QDomElement m_domNewElement; - QDomNode m_afterNode; + TQDomElement m_domOldElement; + TQDomNode m_domParentNode; + TQDomElement m_domNewElement; + TQDomNode m_afterNode; }; #endif diff --git a/part/commands_file.cpp b/part/commands_file.cpp index f30ff2d..b19e15d 100644 --- a/part/commands_file.cpp +++ b/part/commands_file.cpp @@ -15,14 +15,14 @@ * * ***************************************************************************/ #include "commands_file.h" -#include +#include #include #include ////////////////////////////////////////////////////////////////////////////////////////// /////////// Setting Version & Encoding ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXEVersionEncodingCommand::KXEVersionEncodingCommand(KXEDocument* pDocument, const QString& oldData, const QString &newData) +KXEVersionEncodingCommand::KXEVersionEncodingCommand(KXEDocument* pDocument, const TQString& oldData, const TQString &newData) : KXECommand(pDocument) { m_strOldData = oldData; @@ -47,7 +47,7 @@ void KXEVersionEncodingCommand::unexecute() /////////// Attaching stylesheet ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXEStylesheetAttachCommand::KXEStylesheetAttachCommand(KXEDocument* pDocument,const QString& prevStylesheet,const QString& newStylesheet) +KXEStylesheetAttachCommand::KXEStylesheetAttachCommand(KXEDocument* pDocument,const TQString& prevStylesheet,const TQString& newStylesheet) : KXECommand(pDocument) { m_strNewStylesheet = newStylesheet; @@ -75,7 +75,7 @@ void KXEStylesheetAttachCommand::unexecute() /////////// Detaching Stylesheet ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXEStylesheetDetachCommand::KXEStylesheetDetachCommand(KXEDocument* pDocument,const QString& prevStylesheet) +KXEStylesheetDetachCommand::KXEStylesheetDetachCommand(KXEDocument* pDocument,const TQString& prevStylesheet) : KXECommand(pDocument) { m_strPrevStylesheet = prevStylesheet; @@ -100,14 +100,14 @@ void KXEStylesheetDetachCommand::unexecute() /////////// Attaching Schema ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXESchemaAttachCommand::KXESchemaAttachCommand(KXEDocument *pDocument,const QString& newSchema) +KXESchemaAttachCommand::KXESchemaAttachCommand(KXEDocument *pDocument,const TQString& newSchema) : KXECommand(pDocument) { m_pDocument = pDocument; m_strNewSchema = newSchema; m_strPrevSchema = ""; } -KXESchemaAttachCommand::KXESchemaAttachCommand(KXEDocument *pDocument,const QString& newSchema,const QString& prevSchema) +KXESchemaAttachCommand::KXESchemaAttachCommand(KXEDocument *pDocument,const TQString& newSchema,const TQString& prevSchema) : KXECommand(pDocument) { m_strNewSchema = newSchema; @@ -135,7 +135,7 @@ void KXESchemaAttachCommand::unexecute() /////////// Detaching schema ////////// ////////////////////////////////////////////////////////////////////////////////////////// -KXESchemaDetachCommand::KXESchemaDetachCommand(KXEDocument* pDocument, const QString& schema) +KXESchemaDetachCommand::KXESchemaDetachCommand(KXEDocument* pDocument, const TQString& schema) : KXECommand(pDocument) { m_schema = schema; diff --git a/part/commands_file.h b/part/commands_file.h index 00dc484..18c695a 100644 --- a/part/commands_file.h +++ b/part/commands_file.h @@ -33,70 +33,70 @@ Command for setting version and encoding to XML file. */ class KXEDocument; -class QString; +class TQString; class KXEVersionEncodingCommand : public KXECommand { public: - KXEVersionEncodingCommand(KXEDocument* pDocument, const QString& oldData, const QString &newData); + KXEVersionEncodingCommand(KXEDocument* pDocument, const TQString& oldData, const TQString &newData); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Changing version and encoding"); } + virtual TQString name() const { return i18n("Changing version and encoding"); } ~KXEVersionEncodingCommand(); protected: - QString m_strOldData; - QString m_strNewData; + TQString m_strOldData; + TQString m_strNewData; }; class KXEStylesheetAttachCommand : public KXECommand { public: - KXEStylesheetAttachCommand(KXEDocument* pDocument,const QString& prevStylesheet,const QString& newStylesheet); + KXEStylesheetAttachCommand(KXEDocument* pDocument,const TQString& prevStylesheet,const TQString& newStylesheet); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Attaching stylesheet ")+m_strNewStylesheet; } + virtual TQString name() const { return i18n("Attaching stylesheet ")+m_strNewStylesheet; } ~KXEStylesheetAttachCommand(); protected: - QString m_strPrevStylesheet; - QString m_strNewStylesheet; + TQString m_strPrevStylesheet; + TQString m_strNewStylesheet; }; class KXEStylesheetDetachCommand : public KXECommand { public: - KXEStylesheetDetachCommand(KXEDocument* pDocument,const QString& prevStylesheet); + KXEStylesheetDetachCommand(KXEDocument* pDocument,const TQString& prevStylesheet); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Detaching stylesheet ")+m_strPrevStylesheet; } + virtual TQString name() const { return i18n("Detaching stylesheet ")+m_strPrevStylesheet; } ~KXEStylesheetDetachCommand(); protected: - QString m_strPrevStylesheet; + TQString m_strPrevStylesheet; }; class KXESchemaAttachCommand : public KXECommand { public: - KXESchemaAttachCommand(KXEDocument *pDocument,const QString& newSchema); - KXESchemaAttachCommand(KXEDocument *pDocument,const QString& newSchema, const QString& prevSchema); + KXESchemaAttachCommand(KXEDocument *pDocument,const TQString& newSchema); + KXESchemaAttachCommand(KXEDocument *pDocument,const TQString& newSchema, const TQString& prevSchema); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Attaching schema ")+m_strNewSchema; } + virtual TQString name() const { return i18n("Attaching schema ")+m_strNewSchema; } ~KXESchemaAttachCommand(); protected: - QString m_strNewSchema; - QString m_strPrevSchema; + TQString m_strNewSchema; + TQString m_strPrevSchema; }; class KXESchemaDetachCommand : public KXECommand { public: - KXESchemaDetachCommand(KXEDocument* pDocument, const QString& schema); + KXESchemaDetachCommand(KXEDocument* pDocument, const TQString& schema); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Detaching schema ")+m_schema; } + virtual TQString name() const { return i18n("Detaching schema ")+m_schema; } ~KXESchemaDetachCommand(); protected: - QString m_schema; + TQString m_schema; }; #endif diff --git a/part/commands_insert.cpp b/part/commands_insert.cpp index 9f17d51..fb79d63 100644 --- a/part/commands_insert.cpp +++ b/part/commands_insert.cpp @@ -16,7 +16,7 @@ ***************************************************************************/ #include "commands_insert.h" -#include +#include #include @@ -26,10 +26,10 @@ KXEElementCommand::KXEElementCommand( KXEDocument *pDocument, - QDomDocument * pDomDoc, - QString strNsURI, - QString strPrefix, - QString strName + TQDomDocument * pDomDoc, + TQString strNsURI, + TQString strPrefix, + TQString strName ) : KXECommand(pDocument) { @@ -46,10 +46,10 @@ KXEElementCommand::KXEElementCommand( KXEElementCommand::KXEElementCommand( KXEDocument *pDocument, - QDomElement & domParentElement, - QString strNsURI, - QString strPrefix, - QString strName, + TQDomElement & domParentElement, + TQString strNsURI, + TQString strPrefix, + TQString strName, bool bAtTop ) : KXECommand(pDocument) @@ -85,7 +85,7 @@ void KXEElementCommand::execute() // Insert child element if ( m_bAtTop ) { // insert as first child - QDomNode domFirstChildNode = m_domParentElement.firstChild(); + TQDomNode domFirstChildNode = m_domParentElement.firstChild(); if ( domFirstChildNode.isNull() ) m_domParentElement.appendChild( m_domElement ); // no childs yet -> simply append else @@ -118,10 +118,10 @@ void KXEElementCommand::unexecute() KXEAttributeCommand::KXEAttributeCommand( KXEDocument *pDocument, - QDomElement &domOwnerElement, - QString strNamespace, - QString strQName, - QString strValue + TQDomElement &domOwnerElement, + TQString strNamespace, + TQString strQName, + TQString strValue ) : KXECommand(pDocument) { @@ -167,10 +167,10 @@ void KXEAttributeCommand::unexecute() KXECharDataCommand::KXECharDataCommand( KXEDocument *pDocument, - QDomElement & domParentElement, + TQDomElement & domParentElement, bool bAtTop, CharDataKind eCharDataKind, - QString strContents + TQString strContents ) : KXECommand(pDocument) { @@ -211,7 +211,7 @@ void KXECharDataCommand::execute() { if ( m_bAtTop ) { // insert as first child - QDomNode domFirstChildNode = m_domParentElement.firstChild(); + TQDomNode domFirstChildNode = m_domParentElement.firstChild(); if ( domFirstChildNode.isNull() ) m_domParentElement.appendChild( m_domCharData ); // no childs yet -> simply append else @@ -239,10 +239,10 @@ void KXECharDataCommand::unexecute() KXEProcInstrCommand::KXEProcInstrCommand( KXEDocument *pDocument, - QDomDocument * pDomDoc, + TQDomDocument * pDomDoc, bool bAtTop, - QString strTarget, - QString strData + TQString strTarget, + TQString strData ) : KXECommand(pDocument) { @@ -260,10 +260,10 @@ KXEProcInstrCommand::KXEProcInstrCommand( KXEProcInstrCommand::KXEProcInstrCommand( KXEDocument *pDocument, - QDomElement & domParentElement, + TQDomElement & domParentElement, bool bAtTop, - QString strTarget, - QString strData + TQString strTarget, + TQString strData ) : KXECommand(pDocument) { @@ -299,7 +299,7 @@ void KXEProcInstrCommand::execute() // Insert child proc. instr if ( m_bAtTop ) { // insert as first child - QDomNode domFirstChildNode = m_domParentElement.firstChild(); + TQDomNode domFirstChildNode = m_domParentElement.firstChild(); if ( domFirstChildNode.isNull() ) m_domParentElement.appendChild( m_domProcInstr ); // no childs yet -> simply append else diff --git a/part/commands_insert.h b/part/commands_insert.h index 4d9da8d..d0f5963 100644 --- a/part/commands_insert.h +++ b/part/commands_insert.h @@ -28,67 +28,67 @@ class KXEElementCommand : public KXECommand { public: - KXEElementCommand(KXEDocument*, QDomDocument *, QString, QString, QString); - KXEElementCommand(KXEDocument*, QDomElement &, QString, QString, QString, bool); + KXEElementCommand(KXEDocument*, TQDomDocument *, TQString, TQString, TQString); + KXEElementCommand(KXEDocument*, TQDomElement &, TQString, TQString, TQString, bool); ~KXEElementCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Insert element"); } + virtual TQString name() const { return i18n("Insert element"); } protected: - QDomDocument * m_pDomDoc; - QDomElement m_domParentElement; + TQDomDocument * m_pDomDoc; + TQDomElement m_domParentElement; bool m_bAtTop; - QDomElement m_domElement; + TQDomElement m_domElement; }; class KXEAttributeCommand : public KXECommand { public: - KXEAttributeCommand(KXEDocument*, QDomElement &, QString, QString, QString); + KXEAttributeCommand(KXEDocument*, TQDomElement &, TQString, TQString, TQString); ~KXEAttributeCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Insert attribute"); } + virtual TQString name() const { return i18n("Insert attribute"); } protected: - QString m_strNamespace; - QString m_strQName; - QString m_strValue; - QDomElement m_domOwnerElement; + TQString m_strNamespace; + TQString m_strQName; + TQString m_strValue; + TQDomElement m_domOwnerElement; }; class KXECharDataCommand : public KXECommand { public: - KXECharDataCommand(KXEDocument*, QDomElement &, bool, CharDataKind, QString); + KXECharDataCommand(KXEDocument*, TQDomElement &, bool, CharDataKind, TQString); ~KXECharDataCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Insert char data"); } + virtual TQString name() const { return i18n("Insert char data"); } protected: bool m_bAtTop; - QDomElement m_domParentElement; - QDomCharacterData m_domCharData; + TQDomElement m_domParentElement; + TQDomCharacterData m_domCharData; }; class KXEProcInstrCommand : public KXECommand { public: - KXEProcInstrCommand(KXEDocument*, QDomDocument *, bool, QString, QString); - KXEProcInstrCommand(KXEDocument*, QDomElement &, bool, QString, QString); + KXEProcInstrCommand(KXEDocument*, TQDomDocument *, bool, TQString, TQString); + KXEProcInstrCommand(KXEDocument*, TQDomElement &, bool, TQString, TQString); ~KXEProcInstrCommand(); virtual void execute(); virtual void unexecute(); - virtual QString name() const { return i18n("Insert proc. instr."); } + virtual TQString name() const { return i18n("Insert proc. instr."); } protected: - QDomDocument * m_pDomDoc; - QDomElement m_domParentElement; + TQDomDocument * m_pDomDoc; + TQDomElement m_domParentElement; bool m_bAtTop; - QDomProcessingInstruction m_domProcInstr; + TQDomProcessingInstruction m_domProcInstr; }; #endif diff --git a/part/dcopiface_part_ro.cpp b/part/dcopiface_part_ro.cpp index c2794d0..c7780a9 100644 --- a/part/dcopiface_part_ro.cpp +++ b/part/dcopiface_part_ro.cpp @@ -19,24 +19,24 @@ //--------------------------------------------------------------------------- // KXMLEditorPartIfaceReadOnly //--------------------------------------------------------------------------- -QString -KXMLEditorPartIfaceReadOnly::saveAsFile(const QString & ) +TQString +KXMLEditorPartIfaceReadOnly::saveAsFile(const TQString & ) { return "Not implemented."; } -QString -KXMLEditorPartIfaceReadOnly::selectNode(const QString & szPathToNode) +TQString +KXMLEditorPartIfaceReadOnly::selectNode(const TQString & szPathToNode) { m_pKXEPart->slotPathSelected(szPathToNode); if ( m_pKXEPart->getSelectedPath() == szPathToNode ) return "Selecting node failed."; - return QString(); + return TQString(); } -QString +TQString KXMLEditorPartIfaceReadOnly::currentNode() const { return m_pKXEPart->getSelectedPath(); @@ -46,20 +46,20 @@ KXMLEditorPartIfaceReadOnly::currentNode() const //--------------------------------------------------------------------------- // KXMLEditorPartIface //--------------------------------------------------------------------------- -QString -KXMLEditorPartIfaceReadWrite::openURL(const QString & szURL) +TQString +KXMLEditorPartIfaceReadWrite::openURL(const TQString & szURL) { KURL url(szURL); if (! url.isValid () ) return "URL is not valid."; if ( m_pKXEPart->openURL(url) ) - return QString(); + return TQString(); else return "Opening URL failed."; } -QString +TQString KXMLEditorPartIfaceReadWrite::close() { return "Not implemented."; diff --git a/part/dcopiface_part_ro.h b/part/dcopiface_part_ro.h index 90f5982..0d73f1d 100644 --- a/part/dcopiface_part_ro.h +++ b/part/dcopiface_part_ro.h @@ -62,18 +62,18 @@ k_dcop: * @returns Error description or empty string if file succesfully saved. **/ - QString saveAsFile(const QString & path_to_file); + TQString saveAsFile(const TQString & path_to_file); /** Tries to change current node * @param pathToNode Path to new node * @returns Empty string if selection OK otherwise error description **/ - QString selectNode(const QString & pathToNode); + TQString selectNode(const TQString & pathToNode); /** Returns path to current node * @returns If error empty string **/ - QString currentNode() const; + TQString currentNode() const; }; @@ -107,7 +107,7 @@ k_dcop: * * @returns Error description or empty string if file succesfully loaded. **/ - QString openURL(const QString & szURL); + TQString openURL(const TQString & szURL); /** * Closes object behind interface. @@ -115,7 +115,7 @@ k_dcop: * * @returns Error description or empty string if program closed. **/ - QString close(); + TQString close(); }; diff --git a/part/kxe_treeview.cpp b/part/kxe_treeview.cpp index 93e3be5..ce89961 100644 --- a/part/kxe_treeview.cpp +++ b/part/kxe_treeview.cpp @@ -32,19 +32,19 @@ #include #include -// include files for Qt +// include files for TQt #include "qdom_add.h" -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include static const int autoOpenTimeout = 750; -KXE_TreeView::KXE_TreeView( KXMLGUIClient * pGUIClient, QWidget * pParent, const char * pszName ) +KXE_TreeView::KXE_TreeView( KXMLGUIClient * pGUIClient, TQWidget * pParent, const char * pszName ) : KListView(pParent,pszName), m_pGUIClient(pGUIClient), m_nBookmarkedItems(0) @@ -53,10 +53,10 @@ KXE_TreeView::KXE_TreeView( KXMLGUIClient * pGUIClient, QWidget * pParent, const addColumn(i18n("Qualified name")); - setSelectionMode(QListView::Single); + setSelectionMode(TQListView::Single); connect( this, SIGNAL(selectionChanged()), this, SLOT(slotSelectionChanged()) ); - connect( this, SIGNAL(expanded(QListViewItem*)), this, SLOT(slotItemExpanded(QListViewItem*)) ); + connect( this, SIGNAL(expanded(TQListViewItem*)), this, SLOT(slotItemExpanded(TQListViewItem*)) ); setReadWrite(false); @@ -64,7 +64,7 @@ KXE_TreeView::KXE_TreeView( KXMLGUIClient * pGUIClient, QWidget * pParent, const m_pCurrentBeforeDropItem = 0; m_pDropItem = 0; - m_autoOpenTimer = new QTimer(this); + m_autoOpenTimer = new TQTimer(this); connect(m_autoOpenTimer, SIGNAL(timeout()), this, SLOT(slotAutoOpenFolder())); // Apply current configuration @@ -136,7 +136,7 @@ void KXE_TreeView::editDeselect() void KXE_TreeView::viewNodeUp() { // get selected item from tree view - QListViewItem * pSelItem = selectedItem(); + TQListViewItem * pSelItem = selectedItem(); if ( ! pSelItem ) { kdDebug() << "KXE_TreeView::slotViewNodeUp no item selected" << endl; @@ -144,7 +144,7 @@ void KXE_TreeView::viewNodeUp() } // get parent item - QListViewItem * pParentItem = pSelItem->parent(); + TQListViewItem * pParentItem = pSelItem->parent(); // select parent item in tree view if (pParentItem) @@ -157,7 +157,7 @@ void KXE_TreeView::viewNodeUp() void KXE_TreeView::viewExpNode( int nLevel ) { // get selected item from tree view (if any) - QListViewItem * pSelItem = selectedItem(); + TQListViewItem * pSelItem = selectedItem(); if ( ! pSelItem ) { kdDebug() << "KXE_TreeView::slotViewExpNode no item selected" << endl; @@ -172,7 +172,7 @@ void KXE_TreeView::viewExpNode( int nLevel ) void KXE_TreeView::viewColNode( int nLevel ) { // get selected item from tree view (if any) - QListViewItem * pSelItem = selectedItem(); + TQListViewItem * pSelItem = selectedItem(); if ( ! pSelItem ) { kdDebug() << "KXE_TreeView::slotViewColNode no item selected" << endl; @@ -213,7 +213,7 @@ void KXE_TreeView::bookmarksPrev() KXE_TreeViewItem * pSelItem = static_cast (selectedItem()); if ( ! pSelItem ) // If there is no item selected we take { // the last root items last grand child. - QListViewItem * pTmpItem = firstChild(); // Take first child and + TQListViewItem * pTmpItem = firstChild(); // Take first child and while ( pTmpItem->nextSibling() ) // find last child by pTmpItem = pTmpItem->nextSibling(); // traversing all childs @@ -283,7 +283,7 @@ void KXE_TreeView::selectItem( KXE_TreeViewItem * const pItem ) ensureItemVisible( pItem ); } -bool KXE_TreeView::selectNode( const QDomNode & node ) +bool KXE_TreeView::selectNode( const TQDomNode & node ) { if ( node.isNull() ) { @@ -303,10 +303,10 @@ bool KXE_TreeView::selectNode( const QDomNode & node ) return true; } -QDomNode * KXE_TreeView::getSelectedNode() const +TQDomNode * KXE_TreeView::getSelectedNode() const { // get selected item from tree view - QListViewItem * pSelItem = selectedItem(); + TQListViewItem * pSelItem = selectedItem(); if ( ! pSelItem ) return 0; @@ -314,14 +314,14 @@ QDomNode * KXE_TreeView::getSelectedNode() const return pSelTreeItem->xmlNode(); } -QDomNode * KXE_TreeView::getSpecProcInstrNode(const QString& target) const +TQDomNode * KXE_TreeView::getSpecProcInstrNode(const TQString& target) const { KXE_TreeViewItem * pTreeItem = static_cast (firstChild()); while ( pTreeItem ) { if (pTreeItem->xmlNode()->isProcessingInstruction()) { - QDomProcessingInstruction domProcInstr = pTreeItem->xmlNode()->toProcessingInstruction(); + TQDomProcessingInstruction domProcInstr = pTreeItem->xmlNode()->toProcessingInstruction(); if(domProcInstr.target() == target) return pTreeItem->xmlNode(); } @@ -350,40 +350,40 @@ bool KXE_TreeView::hasRootNode() } -QString KXE_TreeView::getSelectedPath() const +TQString KXE_TreeView::getSelectedPath() const { // get selected item from tree view - QListViewItem * pSelItem = selectedItem(); + TQListViewItem * pSelItem = selectedItem(); if ( ! pSelItem ) - return QString(); + return TQString(); KXE_TreeViewItem * pSelTreeItem = static_cast (pSelItem); return domTool_getPath( * pSelTreeItem->xmlNode() ); } -void KXE_TreeView::contentsMousePressEvent( QMouseEvent * pEvent ) +void KXE_TreeView::contentsMousePressEvent( TQMouseEvent * pEvent ) { KListView::contentsMousePressEvent(pEvent); if ( pEvent->button() == RightButton ) { - QString szMenuName; + TQString szMenuName; - QListViewItem * pItem = itemAt( contentsToViewport(pEvent->pos()) ); + TQListViewItem * pItem = itemAt( contentsToViewport(pEvent->pos()) ); if (pItem) { KXE_TreeViewItem * pTreeItem = static_cast (pItem); switch( pTreeItem->xmlNode()->nodeType() ) { - case QDomNode::ElementNode: + case TQDomNode::ElementNode: szMenuName = "popupXmlElement"; break; - case QDomNode::TextNode: - case QDomNode::CDATASectionNode: - case QDomNode::CommentNode: + case TQDomNode::TextNode: + case TQDomNode::CDATASectionNode: + case TQDomNode::CommentNode: szMenuName = "popupXmlContent"; break; - case QDomNode::ProcessingInstructionNode: + case TQDomNode::ProcessingInstructionNode: szMenuName = "popupXmlProcInstr"; break; default: @@ -394,13 +394,13 @@ void KXE_TreeView::contentsMousePressEvent( QMouseEvent * pEvent ) else szMenuName = "popupXmlTree"; - emit sigContextMenuRequested( szMenuName, QCursor::pos() ); + emit sigContextMenuRequested( szMenuName, TQCursor::pos() ); return; } //--- Drag & Drop ------------------------------------------------------ - QPoint p(contentsToViewport(pEvent->pos())); - QListViewItem *i = itemAt(p); + TQPoint p(contentsToViewport(pEvent->pos())); + TQListViewItem *i = itemAt(p); if(pEvent->button() == LeftButton && i) { // if the user clicked into the root decoration of the item, don't try to start a drag! @@ -422,22 +422,22 @@ void KXE_TreeView::slotSelectionChanged() emit sigSelectionCleared(hasRootNode()); else { - QDomNode selectedNode = * ( pItem->xmlNode() ); // uses QDomNode copy constructor + TQDomNode selectedNode = * ( pItem->xmlNode() ); // uses TQDomNode copy constructor // choose appropriate object kind switch ( selectedNode.nodeType() ) { - case QDomNode::ElementNode: + case TQDomNode::ElementNode: emit sigSelectionChanged( selectedNode.toElement()); break; - case QDomNode::TextNode: - case QDomNode::CDATASectionNode: - case QDomNode::CommentNode: + case TQDomNode::TextNode: + case TQDomNode::CDATASectionNode: + case TQDomNode::CommentNode: emit sigSelectionChanged( selectedNode.toCharacterData()); break; - case QDomNode::ProcessingInstructionNode: + case TQDomNode::ProcessingInstructionNode: emit sigSelectionChanged( selectedNode.toProcessingInstruction()); break; @@ -449,7 +449,7 @@ void KXE_TreeView::slotSelectionChanged() } -void KXE_TreeView::slotItemExpanded( QListViewItem * pItem ) +void KXE_TreeView::slotItemExpanded( TQListViewItem * pItem ) { KXE_TreeViewItem * pTreeViewItem = static_cast (pItem); pTreeViewItem->ensureGrandChildItemsCreated(); @@ -460,7 +460,7 @@ void KXE_TreeView::slotItemExpanded( QListViewItem * pItem ) // update slots ////////////////////////////////////////////////////////////// -void KXE_TreeView::updateNodeCreated( const QDomNode & node ) +void KXE_TreeView::updateNodeCreated( const TQDomNode & node ) { if ( node.isNull() ) { @@ -476,7 +476,7 @@ void KXE_TreeView::updateNodeCreated( const QDomNode & node ) if (node.isProcessingInstruction()) // Tree looks much nicer if root processing instructions are ont the top... { - QDomNode *pNode = getSpecProcInstrNode("xml"); + TQDomNode *pNode = getSpecProcInstrNode("xml"); if (pNode) pNewItem = new KXE_TreeViewItem( node, this,findCorrespondingItem(*pNode)); else @@ -499,7 +499,7 @@ void KXE_TreeView::updateNodeCreated( const QDomNode & node ) } // To create the new item, we need (1st) the item corresponding to the parent node of the given one. - QDomNode parentNode = node.parentNode(); + TQDomNode parentNode = node.parentNode(); // Because the currently selected item is very likely (in many cases) the correct one, try it first. KXE_TreeViewItem * pParentItem = static_cast (selectedItem()); if ( (!pParentItem) || ( *(pParentItem->xmlNode()) != parentNode ) ) @@ -515,7 +515,7 @@ void KXE_TreeView::updateNodeCreated( const QDomNode & node ) // Now we need (2nd) the item corresponding to the previous sibling of the given one, // because, the new item has to be inserted behind the given one. - QDomNode prevNode = node.previousSibling(); + TQDomNode prevNode = node.previousSibling(); if ( prevNode.isNull() ) { // it seems to be the first child node, so create a first child item pNewItem = new KXE_TreeViewItem( node, pParentItem ); @@ -538,7 +538,7 @@ void KXE_TreeView::updateNodeCreated( const QDomNode & node ) ensureItemVisible( pNewItem ); } -void KXE_TreeView::updateNodeChanged( const QDomNode & node ) +void KXE_TreeView::updateNodeChanged( const TQDomNode & node ) { if ( node.isNull() ) { @@ -564,7 +564,7 @@ void KXE_TreeView::updateNodeChanged( const QDomNode & node ) ensureItemVisible( pItem ); } -void KXE_TreeView::updateNodeDeleted( const QDomNode & node ) +void KXE_TreeView::updateNodeDeleted( const TQDomNode & node ) { if ( node.isNull() ) { @@ -591,7 +591,7 @@ void KXE_TreeView::updateNodeDeleted( const QDomNode & node ) emit sigSelectionCleared(hasRootNode()); } -void KXE_TreeView::updateNodeMoved( const QDomNode & node ) +void KXE_TreeView::updateNodeMoved( const TQDomNode & node ) { if ( node.isNull() ) { @@ -661,7 +661,7 @@ void KXE_TreeView::updateClear() clear(); } -void KXE_TreeView::rename( QListViewItem * pItem, int nColumn ) +void KXE_TreeView::rename( TQListViewItem * pItem, int nColumn ) { if ( nColumn != 0 ) // inplace editing only return; // for the first column @@ -681,7 +681,7 @@ void KXE_TreeView::rename( QListViewItem * pItem, int nColumn ) // misc functions ////////////////////////////////////////////////////////////// -KXE_TreeViewItem * KXE_TreeView::findCorrespondingItem( const QDomNode & node ) +KXE_TreeViewItem * KXE_TreeView::findCorrespondingItem( const TQDomNode & node ) { KXE_TreeViewItem * pItem = static_cast (firstChild()); while ( pItem ) @@ -699,7 +699,7 @@ KXE_TreeViewItem * KXE_TreeView::findCorrespondingItem( const QDomNode & node ) ////////////////////////////////////////////////////////////// /** Overrides KListView::contentsMouseMoveEvent */ -void KXE_TreeView::contentsMouseMoveEvent(QMouseEvent *e) +void KXE_TreeView::contentsMouseMoveEvent(TQMouseEvent *e) { KListView::contentsMouseMoveEvent(e); @@ -712,20 +712,20 @@ void KXE_TreeView::contentsMouseMoveEvent(QMouseEvent *e) m_bDrag = false; - QListViewItem *item = itemAt(contentsToViewport(m_dragPos)); + TQListViewItem *item = itemAt(contentsToViewport(m_dragPos)); if(!item || !item->isSelectable()) return; // copy item into clipboard KXE_TreeViewItem *pXmlTreeItem = static_cast (item); - QTextDrag *pDrag = (dynamic_cast (m_pGUIClient))->copyNode(pXmlTreeItem->xmlNode()); + TQTextDrag *pDrag = (dynamic_cast (m_pGUIClient))->copyNode(pXmlTreeItem->xmlNode()); // Start a drag - const QPixmap *pix = item->pixmap(0); + const TQPixmap *pix = item->pixmap(0); if(pix && pDrag->pixmap().isNull()) - { QPoint hotspot(pix->width() / 2, pix->height() / 2); + { TQPoint hotspot(pix->width() / 2, pix->height() / 2); pDrag->setPixmap(*pix, hotspot); } @@ -733,14 +733,14 @@ void KXE_TreeView::contentsMouseMoveEvent(QMouseEvent *e) } /** Overrides KListView::contentsMouseReleaseEvent */ -void KXE_TreeView::contentsMouseReleaseEvent(QMouseEvent *e) +void KXE_TreeView::contentsMouseReleaseEvent(TQMouseEvent *e) { KListView::contentsMouseReleaseEvent(e); m_bDrag = false; } -/** Overrides QScrollView::contentsDragEnterEvent */ -void KXE_TreeView::contentsDragEnterEvent(QDragEnterEvent *e) +/** Overrides TQScrollView::contentsDragEnterEvent */ +void KXE_TreeView::contentsDragEnterEvent(TQDragEnterEvent *e) { m_pDropItem = 0; m_pCurrentBeforeDropItem = selectedItem(); @@ -754,10 +754,10 @@ void KXE_TreeView::contentsDragEnterEvent(QDragEnterEvent *e) } } -/** Overrides QScrollView::contentsDragMoveEvent */ -void KXE_TreeView::contentsDragMoveEvent(QDragMoveEvent *e) +/** Overrides TQScrollView::contentsDragMoveEvent */ +void KXE_TreeView::contentsDragMoveEvent(TQDragMoveEvent *e) { - QListViewItem *item = itemAt(contentsToViewport(e->pos())); + TQListViewItem *item = itemAt(contentsToViewport(e->pos())); // Accept drops on the background, if Texts if(!item && (m_lstDropFormats.contains("text/"))) @@ -786,8 +786,8 @@ void KXE_TreeView::contentsDragMoveEvent(QDragMoveEvent *e) } } -/** Overrides QScrollView::contentsDragLeaveEvent */ -void KXE_TreeView::contentsDragLeaveEvent(QDragLeaveEvent *e) +/** Overrides TQScrollView::contentsDragLeaveEvent */ +void KXE_TreeView::contentsDragLeaveEvent(TQDragLeaveEvent *e) { e=e; // Restore the current item to what it was before the dragging (#17070) @@ -801,8 +801,8 @@ void KXE_TreeView::contentsDragLeaveEvent(QDragLeaveEvent *e) m_lstDropFormats.clear(); } -/** Overrides QScrollView::contentsDropEvent */ -void KXE_TreeView::contentsDropEvent(QDropEvent *pDropEvent) +/** Overrides TQScrollView::contentsDropEvent */ +void KXE_TreeView::contentsDropEvent(TQDropEvent *pDropEvent) { m_autoOpenTimer->stop(); @@ -822,16 +822,16 @@ void KXE_TreeView::slotAutoOpenFolder() } /** Drop or paste text into item */ -bool KXE_TreeView::drop(QListViewItem *pItem, QDropEvent *pDropEvent) +bool KXE_TreeView::drop(TQListViewItem *pItem, TQDropEvent *pDropEvent) { KXE_TreeViewItem* pTreeItem = 0; if(pItem) pTreeItem = static_cast (pItem); - QDomNode *pTargetNode = pTreeItem->xmlNode(); + TQDomNode *pTargetNode = pTreeItem->xmlNode(); // First, make check, if moved item is not moved to their children - if((pDropEvent->source() == this) && (pDropEvent->action() == QDropEvent::Move)) + if((pDropEvent->source() == this) && (pDropEvent->action() == TQDropEvent::Move)) { // make check, if moved item is not moved to itself if(m_pCurrentBeforeDropItem && pTreeItem && (m_pCurrentBeforeDropItem == pTreeItem)) { return false; @@ -849,10 +849,10 @@ bool KXE_TreeView::drop(QListViewItem *pItem, QDropEvent *pDropEvent) return false; } - QDomNode * pNode = static_cast (m_pCurrentBeforeDropItem)->xmlNode(); + TQDomNode * pNode = static_cast (m_pCurrentBeforeDropItem)->xmlNode(); if (pNode->isProcessingInstruction()) { - QDomProcessingInstruction domProcInstr = pNode->toProcessingInstruction(); + TQDomProcessingInstruction domProcInstr = pNode->toProcessingInstruction(); if(domProcInstr.target() == "xml") { KMessageBox::sorry(0, i18n("This processing instruction cannot be moved !")); @@ -862,11 +862,11 @@ bool KXE_TreeView::drop(QListViewItem *pItem, QDropEvent *pDropEvent) } //-- If Move from same instance of this widget - if((pDropEvent->source() == this) && (pDropEvent->action() == QDropEvent::Move) && (m_pCurrentBeforeDropItem) && pTargetNode->isElement()) + if((pDropEvent->source() == this) && (pDropEvent->action() == TQDropEvent::Move) && (m_pCurrentBeforeDropItem) && pTargetNode->isElement()) { // remove source item - QDomNode * pSourceNode = static_cast (m_pCurrentBeforeDropItem)->xmlNode(); - QDomElement domTargetElement = pTargetNode->toElement(); + TQDomNode * pSourceNode = static_cast (m_pCurrentBeforeDropItem)->xmlNode(); + TQDomElement domTargetElement = pTargetNode->toElement(); if((dynamic_cast (m_pGUIClient))->dropMoveNode(domTargetElement, *pSourceNode)) { @@ -892,7 +892,7 @@ bool KXE_TreeView::drop(QListViewItem *pItem, QDropEvent *pDropEvent) // KXE_TreeViewItem* KXE_TreeView::lastChild() { - QListViewItem* pItem = firstChild(); + TQListViewItem* pItem = firstChild(); if (pItem && pItem->nextSibling()) do pItem = pItem->nextSibling(); @@ -902,7 +902,7 @@ KXE_TreeViewItem* KXE_TreeView::lastChild() return (KXE_TreeViewItem*) pItem; } -void KXE_TreeView::keyPressEvent(QKeyEvent *e) +void KXE_TreeView::keyPressEvent(TQKeyEvent *e) { KListView::keyPressEvent(e); emit sigKeyPressed(e); diff --git a/part/kxe_treeview.h b/part/kxe_treeview.h index 0ba2c86..1b642f5 100644 --- a/part/kxe_treeview.h +++ b/part/kxe_treeview.h @@ -19,19 +19,19 @@ #define KXE_TREEVIEW_H #include -#include +#include class KXESearchDialog; -class QDomDocument; -class QDomNode; -class QDomElement; -class QDomCharacterData; -class QDomProcessingInstruction; +class TQDomDocument; +class TQDomNode; +class TQDomElement; +class TQDomCharacterData; +class TQDomProcessingInstruction; -class QMouseEvent; -class QTimer; -class QKeyEvent; +class TQMouseEvent; +class TQTimer; +class TQKeyEvent; class KXMLGUIClient; class KXE_TreeViewItem; @@ -44,7 +44,7 @@ class KXE_TreeView : public KListView Q_OBJECT public: - KXE_TreeView( KXMLGUIClient * pGUIClient, QWidget * pParent = 0, const char * pszName = 0 ); + KXE_TreeView( KXMLGUIClient * pGUIClient, TQWidget * pParent = 0, const char * pszName = 0 ); /** Changes the behaviour of this view to readonly or readwrite. */ void setReadWrite( bool fReadWrite ); @@ -54,22 +54,22 @@ public: /** Selects the item corresponding to the given node. * Returns true on success, false otherwise. */ - bool selectNode( const QDomNode & node ); + bool selectNode( const TQDomNode & node ); /** Returns the a pointer to the selected items node or a null pointer (if no item is selected). */ - QDomNode * getSelectedNode() const; + TQDomNode * getSelectedNode() const; /** Returns the a pointer to the special processing instruction or a null pointer for (if no item is exists). */ - QDomNode * getSpecProcInstrNode(const QString& target) const; + TQDomNode * getSpecProcInstrNode(const TQString& target) const; /** Returns the selected items path or an empty string, if no item is selected. */ - QString getSelectedPath() const; + TQString getSelectedPath() const; /** Returns true, if this tree view contains bookmarked tree items and false otherwise. */ bool containsBookmarkedItems() const { return (m_nBookmarkedItems>0); } /** Drop or paste text into item */ - bool drop(QListViewItem *, QDropEvent *); + bool drop(TQListViewItem *, TQDropEvent *); /** toggles bookmark on the selected item */ void bookmarksToggle(); @@ -96,16 +96,16 @@ public: * Creates new item(s) to the given node (and its child nodes) * and inserts it (or them) in the tree. */ - void updateNodeCreated( const QDomNode & node ); + void updateNodeCreated( const TQDomNode & node ); /** Changes the item corresponding to the given node. */ - void updateNodeChanged( const QDomNode & node ); + void updateNodeChanged( const TQDomNode & node ); /** Removes the item corresponding to the given node. */ - void updateNodeDeleted( const QDomNode & node ); + void updateNodeDeleted( const TQDomNode & node ); /** Moves the item corresponding to the given node. */ - void updateNodeMoved( const QDomNode & node ); + void updateNodeMoved( const TQDomNode & node ); /** Clears the whole tree. */ void updateClear(); @@ -117,7 +117,7 @@ public: * class functionality is used and the signal * @ref sigItemRenamedInplace emitted. */ - virtual void rename( QListViewItem * pItem, int nColumn ); + virtual void rename( TQListViewItem * pItem, int nColumn ); /** Returns info, is root element is already created */ bool hasRootNode(); @@ -140,13 +140,13 @@ signals: void sigSelectionCleared(bool); /** emitted, when an XML element item is selected */ - void sigSelectionChanged( const QDomElement & ); + void sigSelectionChanged( const TQDomElement & ); /** emitted, when an XML Content item is selected */ - void sigSelectionChanged( const QDomCharacterData & ); + void sigSelectionChanged( const TQDomCharacterData & ); /** emitted, when an XML proc.instr. item is selected */ - void sigSelectionChanged( const QDomProcessingInstruction & ); + void sigSelectionChanged( const TQDomProcessingInstruction & ); /** * Signals the change of bookmark status. @@ -156,35 +156,35 @@ signals: void sigNewBookmarkStatus( bool fStatus ); /** Emitted, when a context menu is requested */ - void sigContextMenuRequested( const QString & szMenuName, const QPoint & pos ); + void sigContextMenuRequested( const TQString & szMenuName, const TQPoint & pos ); /** Emitted when user presses a key. */ - void sigKeyPressed(QKeyEvent* e); + void sigKeyPressed(TQKeyEvent* e); protected: /** if RMB shows the popupmenu corresponding to the selected item */ - void contentsMousePressEvent( QMouseEvent * ); + void contentsMousePressEvent( TQMouseEvent * ); /** Finds the corresponding treeview item to the given node. */ - KXE_TreeViewItem * findCorrespondingItem( const QDomNode & node ); + KXE_TreeViewItem * findCorrespondingItem( const TQDomNode & node ); /** Overrides KListView::contentsMouseReleaseEvent */ - void contentsMouseReleaseEvent(QMouseEvent *); + void contentsMouseReleaseEvent(TQMouseEvent *); /** Overrides KListView::contentsMouseMoveEvent */ - void contentsMouseMoveEvent(QMouseEvent *); + void contentsMouseMoveEvent(TQMouseEvent *); - /** Overrides QScrollView::contentsDragEnterEvent */ - void contentsDragEnterEvent(QDragEnterEvent *); + /** Overrides TQScrollView::contentsDragEnterEvent */ + void contentsDragEnterEvent(TQDragEnterEvent *); - /** Overrides QScrollView::contentsDragMoveEvent */ - void contentsDragMoveEvent(QDragMoveEvent *); + /** Overrides TQScrollView::contentsDragMoveEvent */ + void contentsDragMoveEvent(TQDragMoveEvent *); - /** Overrides QScrollView::contentsDragLeaveEvent */ - void contentsDragLeaveEvent(QDragLeaveEvent *); + /** Overrides TQScrollView::contentsDragLeaveEvent */ + void contentsDragLeaveEvent(TQDragLeaveEvent *); - /** Overrides QScrollView::contentsDropEvent */ - void contentsDropEvent(QDropEvent *); - virtual void keyPressEvent(QKeyEvent *e); + /** Overrides TQScrollView::contentsDropEvent */ + void contentsDropEvent(TQDropEvent *); + virtual void keyPressEvent(TQKeyEvent *e); protected slots: /** Checks, which type of item was selected an emits the corresponding signal. */ @@ -196,9 +196,9 @@ protected slots: * because KXMLEditor could have been in "create items on demand" mode during * the opening of the document. * - * To be connected to the signal QListView::expanded(QListViewItem*). + * To be connected to the signal TQListView::expanded(TQListViewItem*). */ - void slotItemExpanded( QListViewItem * ); + void slotItemExpanded( TQListViewItem * ); private slots: @@ -217,19 +217,19 @@ protected: bool m_bDrag; /** Contain mouse position of drag operation */ - QPoint m_dragPos; + TQPoint m_dragPos; /** The item that was current before the drag-enter event happened */ - QListViewItem *m_pCurrentBeforeDropItem; + TQListViewItem *m_pCurrentBeforeDropItem; /** The item we are moving the mouse over (during a drag) */ - QListViewItem *m_pDropItem; + TQListViewItem *m_pDropItem; /** List of avalilable drop formats */ - QStrList m_lstDropFormats; + TQStrList m_lstDropFormats; /** Timer for counting time to auto open fselected folder while drag */ - QTimer *m_autoOpenTimer; + TQTimer *m_autoOpenTimer; }; #endif diff --git a/part/kxe_treeviewitem.cpp b/part/kxe_treeviewitem.cpp index 0107bee..c6537b0 100644 --- a/part/kxe_treeviewitem.cpp +++ b/part/kxe_treeviewitem.cpp @@ -23,14 +23,14 @@ #include "qdom_add.h" -#include +#include #include #include #include -KXE_TreeViewItem::KXE_TreeViewItem( const QDomNode & xmlNode, QListViewItem * pParent ) - : QListViewItem(pParent), +KXE_TreeViewItem::KXE_TreeViewItem( const TQDomNode & xmlNode, TQListViewItem * pParent ) + : TQListViewItem(pParent), m_xmlNode(xmlNode), m_pPrevSibling(0), m_bBookmarked(false), @@ -41,8 +41,8 @@ KXE_TreeViewItem::KXE_TreeViewItem( const QDomNode & xmlNode, QListViewItem * pP initChilds(); } -KXE_TreeViewItem::KXE_TreeViewItem( const QDomNode & xmlNode, KListView * pParent, QListViewItem* pAfter) - : QListViewItem(pParent,pAfter), +KXE_TreeViewItem::KXE_TreeViewItem( const TQDomNode & xmlNode, KListView * pParent, TQListViewItem* pAfter) + : TQListViewItem(pParent,pAfter), m_xmlNode(xmlNode), m_pPrevSibling(0), m_bBookmarked(false), @@ -53,8 +53,8 @@ KXE_TreeViewItem::KXE_TreeViewItem( const QDomNode & xmlNode, KListView * pParen initChilds(); } -KXE_TreeViewItem::KXE_TreeViewItem( const QDomNode & xmlNode, QListViewItem * pParent, QListViewItem * pAfter ) - : QListViewItem( pParent, pAfter ), +KXE_TreeViewItem::KXE_TreeViewItem( const TQDomNode & xmlNode, TQListViewItem * pParent, TQListViewItem * pAfter ) + : TQListViewItem( pParent, pAfter ), m_xmlNode(xmlNode), m_pPrevSibling(0), m_bBookmarked(false), @@ -98,16 +98,16 @@ void KXE_TreeViewItem::setTexts() { switch ( m_xmlNode.nodeType() ) { - case QDomNode::ElementNode: + case TQDomNode::ElementNode: setText( 0, m_xmlNode.toElement().nodeName() ); if ( KXMLEditorFactory::configuration()->treeview()->elemDisplMode() == KXETreeViewSettings::NoAttributes ) - setText( 1, QString() ); + setText( 1, TQString() ); else { // parse all attributes to fill the second column - QString str2ndCol; + TQString str2ndCol; for ( uint i=0; i < m_xmlNode.toElement().attributes().length(); i++ ) { if ( i > 0 ) @@ -120,15 +120,15 @@ void KXE_TreeViewItem::setTexts() } break; - case QDomNode::TextNode: - case QDomNode::CDATASectionNode: - case QDomNode::CommentNode: + case TQDomNode::TextNode: + case TQDomNode::CDATASectionNode: + case TQDomNode::CommentNode: { // set name - QString strText = m_xmlNode.toCharacterData().data(); - strText = strText.replace( QRegExp("\n"), " " ); // replace every newline by a space - strText = strText.replace( QRegExp("\t"), "" ); // removes every tab - strText = strText.replace( QRegExp("\r"), "" ); // removes every return + TQString strText = m_xmlNode.toCharacterData().data(); + strText = strText.replace( TQRegExp("\n"), " " ); // replace every newline by a space + strText = strText.replace( TQRegExp("\t"), "" ); // removes every tab + strText = strText.replace( TQRegExp("\r"), "" ); // removes every return strText = strText.simplifyWhiteSpace(); if( strText.length() > 30 ) // reduce name length, if necessary strText = strText.left(30) + "..."; @@ -137,7 +137,7 @@ void KXE_TreeViewItem::setTexts() break; } - case QDomNode::ProcessingInstructionNode: + case TQDomNode::ProcessingInstructionNode: setText( 0, m_xmlNode.toProcessingInstruction().target() ); break; @@ -169,12 +169,12 @@ bool KXE_TreeViewItem::toggleBookmark() KXE_TreeViewItem * KXE_TreeViewItem::lastChild() const { // take the first child - QListViewItem * pTmpItem = firstChild(); + TQListViewItem * pTmpItem = firstChild(); // if there are no childs return 0 if ( ! pTmpItem ) return 0; - QListViewItem * pTmpItem2; + TQListViewItem * pTmpItem2; while ( (pTmpItem2 = pTmpItem->nextSibling()) != 0 ) // traversing all childs { pTmpItem = pTmpItem2; @@ -200,7 +200,7 @@ KXE_TreeViewItem * KXE_TreeViewItem::prevItem() KXE_TreeViewItem * KXE_TreeViewItem::nextItem() { // checking for a child - QListViewItem * pTmp = firstChild(); + TQListViewItem * pTmp = firstChild(); if (pTmp) return static_cast (pTmp); @@ -210,7 +210,7 @@ KXE_TreeViewItem * KXE_TreeViewItem::nextItem() return static_cast (pTmp); // there is no next sibling -> checking for parents' next sibling(s) - QListViewItem * pParent = parent(); + TQListViewItem * pParent = parent(); while (pParent) { pTmp = pParent->nextSibling(); @@ -286,7 +286,7 @@ void KXE_TreeViewItem::ensureChildItemsCreated() { if ( ! m_bChildsCreated ) { - QDomNode tmpNode = m_xmlNode.lastChild(); + TQDomNode tmpNode = m_xmlNode.lastChild(); while ( ! tmpNode.isNull() ) { @@ -326,5 +326,5 @@ void KXE_TreeViewItem::startRename( int iCol ) // we can start renaming in-place. // Remember: This function is only reached for items representing XML elements. if ( (reinterpret_cast ( listView() ))->isRenameable( iCol ) ) - QListViewItem::startRename( iCol ); + TQListViewItem::startRename( iCol ); } diff --git a/part/kxe_treeviewitem.h b/part/kxe_treeviewitem.h index c24b99f..20430f8 100644 --- a/part/kxe_treeviewitem.h +++ b/part/kxe_treeviewitem.h @@ -18,24 +18,24 @@ #ifndef KXE_TREEVIEWITEM_H #define KXE_TREEVIEWITEM_H -#include -#include -#include +#include +#include +#include class KListView; /** - * This is a tree item, which represents one XML node (see @ref QDomNode and its childclasses). + * This is a tree item, which represents one XML node (see @ref TQDomNode and its childclasses). * @short tree item * @author The KXMLEditor Team */ -class KXE_TreeViewItem : public QListViewItem +class KXE_TreeViewItem : public TQListViewItem { public: - KXE_TreeViewItem( const QDomNode & xmlNode, KListView * pParent, QListViewItem* pAfter=NULL); - KXE_TreeViewItem( const QDomNode & xmlNode, QListViewItem * pParent ); - KXE_TreeViewItem( const QDomNode & xmlNode, QListViewItem * pParent, QListViewItem * pAfter ); + KXE_TreeViewItem( const TQDomNode & xmlNode, KListView * pParent, TQListViewItem* pAfter=NULL); + KXE_TreeViewItem( const TQDomNode & xmlNode, TQListViewItem * pParent ); + KXE_TreeViewItem( const TQDomNode & xmlNode, TQListViewItem * pParent, TQListViewItem * pAfter ); ~KXE_TreeViewItem(); /** @@ -47,7 +47,7 @@ class KXE_TreeViewItem : public QListViewItem void setTexts(); /** Returns the corresponding XML node, e.g. the XML node represented by this tree item. */ - QDomNode * xmlNode() { return & m_xmlNode; } + TQDomNode * xmlNode() { return & m_xmlNode; } /** Returns true, if this tree item is bookmarked (false otherwise). */ bool isBookmarked() const { return m_bBookmarked; } @@ -65,7 +65,7 @@ class KXE_TreeViewItem : public QListViewItem KXE_TreeViewItem * prevSibling() const { return m_pPrevSibling; } /** - * Does the same like @ref QListViewItem::itemAbove but the parent items doesn't need to be open. + * Does the same like @ref TQListViewItem::itemAbove but the parent items doesn't need to be open. * Returns this items previous siblings last grand child, if there is one. * Otherwise it returns this items previous sibling or, * if there are no sibling above, it returns this items parent or @@ -74,7 +74,7 @@ class KXE_TreeViewItem : public QListViewItem KXE_TreeViewItem * prevItem(); /** - * Does the same like @ref QListViewItem::itemBelow but the parent items doesn't need to be open. + * Does the same like @ref TQListViewItem::itemBelow but the parent items doesn't need to be open. * Returns a pointer to the next item of this or a null pointer if this is the last item. * This will be it's first child, * if there are no childs, it will be the next sibling @@ -110,7 +110,7 @@ class KXE_TreeViewItem : public QListViewItem protected: - QDomNode m_xmlNode; + TQDomNode m_xmlNode; KXE_TreeViewItem * m_pPrevSibling; bool m_bBookmarked; bool m_bChildsCreated; diff --git a/part/kxe_viewattributes.cpp b/part/kxe_viewattributes.cpp index bfa0609..0a4d3f3 100644 --- a/part/kxe_viewattributes.cpp +++ b/part/kxe_viewattributes.cpp @@ -23,8 +23,8 @@ #include #include -KXE_ViewAttributes::KXE_ViewAttributes( QWidget * pParent, const char * pszName ) - : QTable( 0, 3, pParent, pszName ) +KXE_ViewAttributes::KXE_ViewAttributes( TQWidget * pParent, const char * pszName ) + : TQTable( 0, 3, pParent, pszName ) { horizontalHeader()->setLabel( 0, i18n("Namespace") ); horizontalHeader()->setLabel( 1, i18n("Name") ); @@ -37,17 +37,17 @@ KXE_ViewAttributes::KXE_ViewAttributes( QWidget * pParent, const char * pszName connect( this, SIGNAL(valueChanged(int,int)), this, SLOT(slotItemRenamedInplace(int,int)) ); } -QDomAttr KXE_ViewAttributes::getSelectedAttribute() const +TQDomAttr KXE_ViewAttributes::getSelectedAttribute() const { if ( currentRow() == -1 ) - return QDomAttr(); + return TQDomAttr(); if ( m_domElement.attributes().item(currentRow()).isAttr() ) { return m_domElement.attributes().item(currentRow()).toAttr(); } else - return QDomAttr(); + return TQDomAttr(); } void KXE_ViewAttributes::setReadWrite( bool fReadWrite ) @@ -56,19 +56,19 @@ void KXE_ViewAttributes::setReadWrite( bool fReadWrite ) setColumnReadOnly( 2, ! fReadWrite ); if ( fReadWrite ) - connect( this, SIGNAL(contextMenuRequested(int,int,const QPoint&)), this, SLOT(slotContextMenuRequested(int,int,const QPoint&)) ); + connect( this, SIGNAL(contextMenuRequested(int,int,const TQPoint&)), this, SLOT(slotContextMenuRequested(int,int,const TQPoint&)) ); else - disconnect( this, SIGNAL(contextMenuRequested(int,int,const QPoint&)), this, SLOT(slotContextMenuRequested(int,int,const QPoint&)) ); + disconnect( this, SIGNAL(contextMenuRequested(int,int,const TQPoint&)), this, SLOT(slotContextMenuRequested(int,int,const TQPoint&)) ); } -void KXE_ViewAttributes::slotContextMenuRequested( int nRow, int nCol, const QPoint & pos ) +void KXE_ViewAttributes::slotContextMenuRequested( int nRow, int nCol, const TQPoint & pos ) { nCol = nCol; - QString szMenuName = ( nRow == -1 ) ? "popupXmlAttributes" : "popupXmlAttribute"; + TQString szMenuName = ( nRow == -1 ) ? "popupXmlAttributes" : "popupXmlAttribute"; emit sigContextMenuRequested( szMenuName, pos ); } -void KXE_ViewAttributes::slotChange( const QDomElement & element ) +void KXE_ViewAttributes::slotChange( const TQDomElement & element ) { m_domElement = element; @@ -79,7 +79,7 @@ void KXE_ViewAttributes::slotChange( const QDomElement & element ) { for ( uint iRow = 0; iRow < iLength; iRow++ ) { - QDomNode node = m_domElement.attributes().item(iRow); + TQDomNode node = m_domElement.attributes().item(iRow); if ( node.isAttr() ) { setText( iRow, 0, node.toAttr().namespaceURI() ); @@ -105,12 +105,12 @@ void KXE_ViewAttributes::slotItemRenamedInplace( int nRow, int nCol ) return; } - QDomNode node = m_domElement.attributes().item(nRow); + TQDomNode node = m_domElement.attributes().item(nRow); if ( node.isAttr() ) { if (nCol == 1) { // check if name is OK - QString strMessage = KXEAttributeDialog::checkName(text(nRow,nCol)); + TQString strMessage = KXEAttributeDialog::checkName(text(nRow,nCol)); if(strMessage.length() > 0) { // restore old name @@ -139,7 +139,7 @@ void KXE_ViewAttributes::slotItemRenamedInplace( int nRow, int nCol ) if ( node.toAttr().value() != text(nRow,nCol) ) // only if the value really was changed { // check if value is OK - QString strMessage = KXEAttributeDialog::checkValue(text(nRow,nCol)); + TQString strMessage = KXEAttributeDialog::checkValue(text(nRow,nCol)); if(strMessage.length() > 0) { // restore old value diff --git a/part/kxe_viewattributes.h b/part/kxe_viewattributes.h index c314c56..9b92d60 100644 --- a/part/kxe_viewattributes.h +++ b/part/kxe_viewattributes.h @@ -18,22 +18,22 @@ #ifndef KXE_VIEWATTRIBUTES_H #define KXE_VIEWATTRIBUTES_H -#include -#include +#include +#include /** * @author The KXMLEditor Team */ -class KXE_ViewAttributes : public QTable +class KXE_ViewAttributes : public TQTable { Q_OBJECT public: - KXE_ViewAttributes( QWidget * pParent = 0, const char * pszName = 0 ); + KXE_ViewAttributes( TQWidget * pParent = 0, const char * pszName = 0 ); /** Returns a pointer to the currently selected attribute or a null pointer. */ - QDomAttr getSelectedAttribute() const; + TQDomAttr getSelectedAttribute() const; /** Changes the behaviour of this view to readonly or readwrite. */ void setReadWrite( bool fReadWrite ); @@ -41,17 +41,17 @@ class KXE_ViewAttributes : public QTable public slots: /** Changes/Rebuilds the whole table according to the given element's attributes. */ - void slotChange( const QDomElement & element ); + void slotChange( const TQDomElement & element ); protected: /** the currently selected node */ - QDomElement m_domElement; + TQDomElement m_domElement; protected slots: - /** Called, when a context menu was requested (connected to @ref QTable::contextMenuRequested). */ - void slotContextMenuRequested( int nRow, int nCol, const QPoint & pos ); + /** Called, when a context menu was requested (connected to @ref TQTable::contextMenuRequested). */ + void slotContextMenuRequested( int nRow, int nCol, const TQPoint & pos ); /** Called, when an item was changed via inplace editing. */ void slotItemRenamedInplace( int nRow, int nCol ); @@ -59,13 +59,13 @@ class KXE_ViewAttributes : public QTable signals: /** Emitted, when a context menu is requested */ - void sigContextMenuRequested( const QString & szMenuName, const QPoint & pos ); + void sigContextMenuRequested( const TQString & szMenuName, const TQPoint & pos ); /** Emitted, when an attributes value was renamed via inplace editing. */ - void sigAttributeNameChangedInplace( const QDomAttr &, const QString ); + void sigAttributeNameChangedInplace( const TQDomAttr &, const TQString ); /** Emitted, when an attributes value was renamed via inplace editing. */ - void sigAttributeValueChangedInplace( const QDomAttr &, const QString ); + void sigAttributeValueChangedInplace( const TQDomAttr &, const TQString ); }; #endif diff --git a/part/kxe_viewelement.cpp b/part/kxe_viewelement.cpp index 21c1ee5..39271b9 100644 --- a/part/kxe_viewelement.cpp +++ b/part/kxe_viewelement.cpp @@ -26,37 +26,37 @@ #include #include -#include -#include -#include +#include +#include +#include #include "qdom_add.h" #define CONFIG_SPLITTER_SIZES "View Element splitter sizes" -KXE_ViewElement::KXE_ViewElement( QWidget * pParent, KConfig *pConfig, const char * pszName ) - : QSplitter( Qt::Vertical, pParent, pszName ) +KXE_ViewElement::KXE_ViewElement( TQWidget * pParent, KConfig *pConfig, const char * pszName ) + : TQSplitter( TQt::Vertical, pParent, pszName ) { setOpaqueResize(true); m_pConfig = pConfig; m_pViewAttributes = new KXE_ViewAttributes( this, "table of element attributes"); - connect( m_pViewAttributes, SIGNAL(sigContextMenuRequested(const QString&,const QPoint&)), this, SIGNAL(sigContextMenuRequested(const QString&,const QPoint&)) ); + connect( m_pViewAttributes, SIGNAL(sigContextMenuRequested(const TQString&,const TQPoint&)), this, SIGNAL(sigContextMenuRequested(const TQString&,const TQPoint&)) ); - connect( m_pViewAttributes, SIGNAL(sigAttributeNameChangedInplace(const QDomAttr&, const QString)), this, SIGNAL(sigAttributeNameChangedInplace(const QDomAttr&, const QString)) ); - connect( m_pViewAttributes, SIGNAL(sigAttributeValueChangedInplace(const QDomAttr&, const QString)), this, SIGNAL(sigAttributeValueChangedInplace(const QDomAttr&, const QString)) ); + connect( m_pViewAttributes, SIGNAL(sigAttributeNameChangedInplace(const TQDomAttr&, const TQString)), this, SIGNAL(sigAttributeNameChangedInplace(const TQDomAttr&, const TQString)) ); + connect( m_pViewAttributes, SIGNAL(sigAttributeValueChangedInplace(const TQDomAttr&, const TQString)), this, SIGNAL(sigAttributeValueChangedInplace(const TQDomAttr&, const TQString)) ); m_pViewPlainXML = new KTextEdit( this, "plain XML" ); m_pViewPlainXML->setReadOnly(true); m_pViewPlainXML->setTextFormat(KTextEdit::PlainText); m_pViewPlainXML->setPaletteBackgroundColor(pParent->palette().active().base()); // Owerwrite read-only background color - m_pViewPlainXML->setWordWrap( QTextEdit::NoWrap ); + m_pViewPlainXML->setWordWrap( TQTextEdit::NoWrap ); m_pSyntaxHighlighter = new KXESyntaxHighlighter(m_pViewPlainXML); // configuring splitter sizes if (m_pConfig) { - QValueList list = m_pConfig->readIntListEntry(CONFIG_SPLITTER_SIZES); + TQValueList list = m_pConfig->readIntListEntry(CONFIG_SPLITTER_SIZES); if (!list.isEmpty()) setSizes(list); } @@ -76,7 +76,7 @@ KXE_ViewElement::~KXE_ViewElement() delete m_pSyntaxHighlighter; } -QDomAttr KXE_ViewElement::getSelectedAttribute() const +TQDomAttr KXE_ViewElement::getSelectedAttribute() const { return m_pViewAttributes->getSelectedAttribute(); } @@ -86,7 +86,7 @@ void KXE_ViewElement::setReadWrite( bool fReadWrite ) m_pViewAttributes->setReadWrite(fReadWrite); } -void KXE_ViewElement::slotChange( const QDomElement & element ) +void KXE_ViewElement::slotChange( const TQDomElement & element ) { // change attribute view m_pViewAttributes->slotChange(element); @@ -113,13 +113,13 @@ void KXE_ViewElement::slotTextViewSettingsChanged() if(KXMLEditorFactory::configuration()->textview()->isWrapOn()) { - m_pViewPlainXML->setHScrollBarMode(QScrollView::AlwaysOff); - m_pViewPlainXML->setWordWrap(QTextEdit::WidgetWidth); + m_pViewPlainXML->setHScrollBarMode(TQScrollView::AlwaysOff); + m_pViewPlainXML->setWordWrap(TQTextEdit::WidgetWidth); } else { - m_pViewPlainXML->setHScrollBarMode(QScrollView::Auto); - m_pViewPlainXML->setWordWrap(QTextEdit::NoWrap); + m_pViewPlainXML->setHScrollBarMode(TQScrollView::Auto); + m_pViewPlainXML->setWordWrap(TQTextEdit::NoWrap); } m_pSyntaxHighlighter->rehighlight(); diff --git a/part/kxe_viewelement.h b/part/kxe_viewelement.h index bac7669..f838079 100644 --- a/part/kxe_viewelement.h +++ b/part/kxe_viewelement.h @@ -18,9 +18,9 @@ #ifndef KXE_VIEWELEMENT_H #define KXE_VIEWELEMENT_H -#include +#include -#include +#include // forward declarations class KXE_ViewAttributes; @@ -35,17 +35,17 @@ class KXESyntaxHighlighter; * * @short Widget for XML elements. */ -class KXE_ViewElement : public QSplitter +class KXE_ViewElement : public TQSplitter { Q_OBJECT public: - KXE_ViewElement( QWidget * pParent, KConfig *pConfig, const char * pszName = 0 ); + KXE_ViewElement( TQWidget * pParent, KConfig *pConfig, const char * pszName = 0 ); ~KXE_ViewElement(); /** Returns a pointer to the currently selected attribute or a null pointer. */ - QDomAttr getSelectedAttribute() const; + TQDomAttr getSelectedAttribute() const; /** Changes the behaviour of this view to readonly or readwrite. */ void setReadWrite( bool fReadWrite ); @@ -53,7 +53,7 @@ class KXE_ViewElement : public QSplitter public slots: /** Changes/Rebuilds the whole widget according to the given element. */ - void slotChange( const QDomElement & ); + void slotChange( const TQDomElement & ); /** * Changes syntax highlighting colors. @@ -76,19 +76,19 @@ class KXE_ViewElement : public QSplitter signals: /** Emitted, when a context menu is requested (see @ref KXE_ViewAttributes::sigContextMenuRequested) */ - void sigContextMenuRequested( const QString & szMenuName, const QPoint & pos ); + void sigContextMenuRequested( const TQString & szMenuName, const TQPoint & pos ); /** * Emitted, when an attributes name was renamed via inplace editing * (see @ref KXE_ViewAttributes::sigAttributeChangedInplace). */ - void sigAttributeNameChangedInplace( const QDomAttr &, const QString ); + void sigAttributeNameChangedInplace( const TQDomAttr &, const TQString ); /** * Emitted, when an attributes value was renamed via inplace editing * (see @ref KXE_ViewAttributes::sigAttributeChangedInplace). */ - void sigAttributeValueChangedInplace( const QDomAttr &, const QString ); + void sigAttributeValueChangedInplace( const TQDomAttr &, const TQString ); }; #endif diff --git a/part/kxearchiveextssettings.cpp b/part/kxearchiveextssettings.cpp index 3dfde77..9f51882 100644 --- a/part/kxearchiveextssettings.cpp +++ b/part/kxearchiveextssettings.cpp @@ -21,14 +21,14 @@ #include #include -#include -#include -#include -#include +#include +#include +#include +#include #define CONF_ENTRY_NAME_EXTS_TARGZ "Extensions" -KXEArchiveExtsSettings::KXEArchiveExtsSettings( QObject * pParent, const char * pszName ) +KXEArchiveExtsSettings::KXEArchiveExtsSettings( TQObject * pParent, const char * pszName ) : KXESettings( "TarGz Extensions", pParent, pszName ), m_pDialogPage(0) { @@ -46,22 +46,22 @@ void KXEArchiveExtsSettings::read( const KConfig * pConfig ) m_lstExtensions = pConfig->readListEntry( CONF_ENTRY_NAME_EXTS_TARGZ ); } -QString KXEArchiveExtsSettings::dialogPageName() const +TQString KXEArchiveExtsSettings::dialogPageName() const { return i18n( "Archive Extensions" ); } -QString KXEArchiveExtsSettings::dialogPageHeader() const +TQString KXEArchiveExtsSettings::dialogPageHeader() const { return i18n( "Specify Archive Extensions" ); } -QString KXEArchiveExtsSettings::dialogPageIcon() const +TQString KXEArchiveExtsSettings::dialogPageIcon() const { return "filetypes"; } -QWidget * KXEArchiveExtsSettings::dialogPage( QFrame * pParent ) +TQWidget * KXEArchiveExtsSettings::dialogPage( TQFrame * pParent ) { if ( ! m_pDialogPage ) { @@ -71,10 +71,10 @@ QWidget * KXEArchiveExtsSettings::dialogPage( QFrame * pParent ) // and fill its widgets with the corresponding values updatePage(); - connect( m_pDialogPage->m_pExtensions, SIGNAL(highlighted(const QString&)), this, SLOT(slotPageEditExtension(const QString&)) ); + connect( m_pDialogPage->m_pExtensions, SIGNAL(highlighted(const TQString&)), this, SLOT(slotPageEditExtension(const TQString&)) ); connect( m_pDialogPage->m_pBtnNew, SIGNAL(clicked()), this, SLOT(slotPageAddExtension()) ); connect( m_pDialogPage->m_pBtnDelete, SIGNAL(clicked()), this, SLOT(slotPageDeleteExtension()) ); - connect( m_pDialogPage->m_pExtension, SIGNAL(textChanged(const QString&)), this, SLOT(slotPageUpdateExtension(const QString&)) ); + connect( m_pDialogPage->m_pExtension, SIGNAL(textChanged(const TQString&)), this, SLOT(slotPageUpdateExtension(const TQString&)) ); connect( m_pDialogPage->m_pBtnNew, SIGNAL(clicked()), this, SIGNAL(sigDialogPageChanged()) ); connect( m_pDialogPage->m_pBtnDelete, SIGNAL(clicked()), this, SIGNAL(sigDialogPageChanged()) ); @@ -89,7 +89,7 @@ void KXEArchiveExtsSettings::setFromPage() if ( m_pDialogPage ) { m_lstExtensions.clear(); - QListBoxItem * pTmpItem = m_pDialogPage->m_pExtensions->firstItem(); + TQListBoxItem * pTmpItem = m_pDialogPage->m_pExtensions->firstItem(); while ( pTmpItem ) { m_lstExtensions << pTmpItem->text(); @@ -113,7 +113,7 @@ void KXEArchiveExtsSettings::updatePage() const // additional slots for the corresponding configuration dialog page // ////////////////////////////////////////////////////////////////////// -void KXEArchiveExtsSettings::slotPageEditExtension( const QString & strText ) +void KXEArchiveExtsSettings::slotPageEditExtension( const TQString & strText ) { m_pDialogPage->m_pExtension->setText( strText ); m_pDialogPage->m_pExtension->setEnabled( true ); @@ -142,7 +142,7 @@ void KXEArchiveExtsSettings::slotPageDeleteExtension() m_pDialogPage->m_pExtensions->setSelected( m_pDialogPage->m_pExtensions->currentItem(), true ); } -void KXEArchiveExtsSettings::slotPageUpdateExtension( const QString & strText ) +void KXEArchiveExtsSettings::slotPageUpdateExtension( const TQString & strText ) { if ( ( m_pDialogPage->m_pExtensions->count() > 0 ) && ( m_pDialogPage->m_pExtensions->currentText() != m_pDialogPage->m_pExtension->text() ) ) diff --git a/part/kxearchiveextssettings.h b/part/kxearchiveextssettings.h index ad2f212..107fc77 100644 --- a/part/kxearchiveextssettings.h +++ b/part/kxearchiveextssettings.h @@ -20,7 +20,7 @@ #include "kxesettings.h" -#include +#include class KXEArchiveExtsSettingsPage; @@ -36,27 +36,27 @@ class KXEArchiveExtsSettings : public KXESettings public: - KXEArchiveExtsSettings( QObject * pParent = 0, const char * pszName = 0 ); + KXEArchiveExtsSettings( TQObject * pParent = 0, const char * pszName = 0 ); // The following function(s) can be used to access this object's settings. - const QStringList & extensions() const { return m_lstExtensions; } + const TQStringList & extensions() const { return m_lstExtensions; } /** * Derived from @ref KXESettings */ - virtual QString dialogPageName() const; + virtual TQString dialogPageName() const; /** * Derived from @ref KXESettings */ - virtual QString dialogPageHeader() const; + virtual TQString dialogPageHeader() const; /** * Derived from @ref KXESettings */ - virtual QString dialogPageIcon() const; + virtual TQString dialogPageIcon() const; /** * Derived from @ref KXESettings */ - virtual QWidget * dialogPage( QFrame * pParent ); + virtual TQWidget * dialogPage( TQFrame * pParent ); protected: @@ -78,7 +78,7 @@ class KXEArchiveExtsSettings : public KXESettings virtual void updatePage() const; // the settings itself - QStringList m_lstExtensions; + TQStringList m_lstExtensions; /** * the corresponding configuration dialog page @@ -94,7 +94,7 @@ class KXEArchiveExtsSettings : public KXESettings /** * Copies the selected item's extension to the editline. */ - void slotPageEditExtension( const QString & ); + void slotPageEditExtension( const TQString & ); /** * Creates a new (empty) item/ extension in the listbox and selects it. */ @@ -106,7 +106,7 @@ class KXEArchiveExtsSettings : public KXESettings /** * Copies the lineedit's current text to the currently selected item. */ - void slotPageUpdateExtension( const QString & ); + void slotPageUpdateExtension( const TQString & ); }; diff --git a/part/kxearchiveextssettingspage.ui b/part/kxearchiveextssettingspage.ui index 0936850..b393fe6 100644 --- a/part/kxearchiveextssettingspage.ui +++ b/part/kxearchiveextssettingspage.ui @@ -1,6 +1,6 @@ KXEArchiveExtsSettingsPage - + KXEArchiveExtsSettingsPage @@ -19,7 +19,7 @@ unnamed - + m_pLblExtensions @@ -36,7 +36,7 @@ This list contains the known extensions for archive files.<br> You can choose one to edit or remove it with the dialog widgets below. - + m_pExtensions @@ -52,7 +52,7 @@ You can choose one to edit or remove it with the dialog widgets below. This list contains the known extensions for archive files. - + layout2 @@ -60,7 +60,7 @@ This list contains the known extensions for archive files. unnamed - + m_pLblExtension @@ -76,7 +76,7 @@ This list contains the known extensions for archive files. Change the selected extension here. - + m_pExtension @@ -103,7 +103,7 @@ Change the selected extension here. - + layout1 @@ -111,7 +111,7 @@ Change the selected extension here. unnamed - + m_pBtnNew @@ -127,7 +127,7 @@ Change the selected extension here. You can create a new item for another known extension in the list above. - + m_pBtnDelete @@ -167,7 +167,7 @@ You can delete the selected extension from the list above. - slotUpdateExtension( const QString & ) + slotUpdateExtension( const TQString & ) slotDeleteExtension() slotAddExtension() diff --git a/part/kxeattachdialogbase.ui b/part/kxeattachdialogbase.ui index 447ac9f..56c3428 100644 --- a/part/kxeattachdialogbase.ui +++ b/part/kxeattachdialogbase.ui @@ -1,6 +1,6 @@ KXEAttachDialogBase - + KXEAttachDialogBase @@ -22,7 +22,7 @@ unnamed - + Label @@ -35,7 +35,7 @@ attachURI - + Layout1 @@ -49,7 +49,7 @@ 6 - + buttonHelp @@ -80,7 +80,7 @@ - + buttonOk @@ -97,7 +97,7 @@ true - + buttonCancel diff --git a/part/kxeattributedialog.cpp b/part/kxeattributedialog.cpp index 93bf9a7..80f66ed 100644 --- a/part/kxeattributedialog.cpp +++ b/part/kxeattributedialog.cpp @@ -21,15 +21,15 @@ #include #include -#include -#include +#include +#include -KXEAttributeDialog::KXEAttributeDialog( QWidget * pParent, const char * pszName, bool fModal, WFlags fl ) +KXEAttributeDialog::KXEAttributeDialog( TQWidget * pParent, const char * pszName, bool fModal, WFlags fl ) : KXEAttributeDialogBase( pParent, pszName, fModal, fl ) { - connect( m_pEditNamespace, SIGNAL(textChanged(const QString &)), this, SLOT(slotNamespaceChanged(const QString &)) ); - connect( m_pEditQName, SIGNAL(textChanged(const QString &)), this, SLOT(slotNameChanged(const QString &)) ); - connect( m_pEditValue, SIGNAL(textChanged(const QString &)), this, SLOT(slotValueChanged(const QString &)) ); + connect( m_pEditNamespace, SIGNAL(textChanged(const TQString &)), this, SLOT(slotNamespaceChanged(const TQString &)) ); + connect( m_pEditQName, SIGNAL(textChanged(const TQString &)), this, SLOT(slotNameChanged(const TQString &)) ); + connect( m_pEditValue, SIGNAL(textChanged(const TQString &)), this, SLOT(slotValueChanged(const TQString &)) ); } void KXEAttributeDialog::clearDialog() @@ -59,9 +59,9 @@ int KXEAttributeDialog::exec() return iReturn; } -void KXEAttributeDialog::slotNameChanged(const QString & strNewName) +void KXEAttributeDialog::slotNameChanged(const TQString & strNewName) { - QString strMessage = checkName(strNewName); + TQString strMessage = checkName(strNewName); if(strMessage.isEmpty()) { strMessage = checkNamespace(m_pEditNamespace->text()); @@ -77,9 +77,9 @@ void KXEAttributeDialog::slotNameChanged(const QString & strNewName) m_pBtnOK->setEnabled(true); } -void KXEAttributeDialog::slotValueChanged(const QString & strNewValue) +void KXEAttributeDialog::slotValueChanged(const TQString & strNewValue) { - QString strMessage = checkName(m_pEditQName->text()); + TQString strMessage = checkName(m_pEditQName->text()); if(strMessage.isEmpty()) { strMessage = checkNamespace(m_pEditNamespace->text()); @@ -95,9 +95,9 @@ void KXEAttributeDialog::slotValueChanged(const QString & strNewValue) m_pBtnOK->setEnabled(true); } -void KXEAttributeDialog::slotNamespaceChanged(const QString & strNewNamespace) +void KXEAttributeDialog::slotNamespaceChanged(const TQString & strNewNamespace) { - QString strMessage = checkName(m_pEditQName->text()); + TQString strMessage = checkName(m_pEditQName->text()); if(strMessage.isEmpty()) { strMessage = checkNamespace(strNewNamespace); @@ -114,7 +114,7 @@ void KXEAttributeDialog::slotNamespaceChanged(const QString & strNewNamespace) } // Check, if XML attribute name is OK -QString KXEAttributeDialog::checkNamespace(const QString strAtttributeName) +TQString KXEAttributeDialog::checkNamespace(const TQString strAtttributeName) { if(strAtttributeName.length() == 0) return ""; @@ -124,10 +124,10 @@ QString KXEAttributeDialog::checkNamespace(const QString strAtttributeName) return i18n("Atttribute namespace cannot contain space !"); // Forbidden characters - QString strForbiddenChars("<>\"'"); + TQString strForbiddenChars("<>\"'"); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strAtttributeName.find(ch) >= 0) return i18n("Atttribute namespace cannot contain character: %1 !").arg(ch); @@ -137,7 +137,7 @@ QString KXEAttributeDialog::checkNamespace(const QString strAtttributeName) } // Check, if XML attribute name is OK -QString KXEAttributeDialog::checkName(const QString strAtttributeName) +TQString KXEAttributeDialog::checkName(const TQString strAtttributeName) { if(strAtttributeName.length() == 0) return ""; @@ -147,10 +147,10 @@ QString KXEAttributeDialog::checkName(const QString strAtttributeName) return i18n("Atttribute name cannot contain space !"); // Forbidden characters - QString strForbiddenChars("&@#$%^()%+?=:<>;\"'*"); + TQString strForbiddenChars("&@#$%^()%+?=:<>;\"'*"); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strAtttributeName.find(ch) >= 0) return i18n("Atttribute name cannot contain character: %1 !").arg(ch); @@ -160,16 +160,16 @@ QString KXEAttributeDialog::checkName(const QString strAtttributeName) } // Check, if XML attribute value is OK -QString KXEAttributeDialog::checkValue(const QString strData) +TQString KXEAttributeDialog::checkValue(const TQString strData) { if(strData.length() == 0) return ""; // Forbidden characters - QString strForbiddenChars("<>\""); + TQString strForbiddenChars("<>\""); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strData.find(ch) >= 0) return i18n("Attribute value cannot contain character: %1 !").arg(ch); diff --git a/part/kxeattributedialog.h b/part/kxeattributedialog.h index e2019b9..25b8879 100644 --- a/part/kxeattributedialog.h +++ b/part/kxeattributedialog.h @@ -20,23 +20,23 @@ #include "kxeattributedialogbase.h" -#include +#include class KXEAttributeDialog : public KXEAttributeDialogBase { Q_OBJECT public: - KXEAttributeDialog( QWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); + KXEAttributeDialog( TQWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); - const QString attributeNamespace() const { return m_strNamespace; } - const QString QName() const { return m_strQName; } - const QString Value() const { return m_strValue; } + const TQString attributeNamespace() const { return m_strNamespace; } + const TQString QName() const { return m_strQName; } + const TQString Value() const { return m_strValue; } /** * To be used for adding an attribute to new XML element. * - * @return see @ref QDialog::exec + * @return see @ref TQDialog::exec */ int exec( ); @@ -46,37 +46,37 @@ class KXEAttributeDialog : public KXEAttributeDialogBase void clearDialog(); // Check, if XML attribute name is OK - static QString checkName(const QString); + static TQString checkName(const TQString); // Check, if XML attribute value is OK - static QString checkValue(const QString); + static TQString checkValue(const TQString); // Check, if XML attribute namespace is OK - static QString checkNamespace(const QString); + static TQString checkNamespace(const TQString); protected slots: /** * Called, when user change attribute name. * Disables the OK button, if user input is wrong or incomplete. */ - void slotNameChanged(const QString &); + void slotNameChanged(const TQString &); /** * Called, when user change attribute value. * Disables the OK button, if user input is wrong or incomplete. */ - void slotValueChanged(const QString &); + void slotValueChanged(const TQString &); /** * Called, when user change attribute namespace. * Disables the OK button, if user input is wrong or incomplete. */ - void slotNamespaceChanged(const QString &); + void slotNamespaceChanged(const TQString &); protected: - QString m_strNamespace; - QString m_strQName; - QString m_strValue; + TQString m_strNamespace; + TQString m_strQName; + TQString m_strValue; }; #endif diff --git a/part/kxeattributedialogbase.ui b/part/kxeattributedialogbase.ui index d03b8eb..29eadc1 100644 --- a/part/kxeattributedialogbase.ui +++ b/part/kxeattributedialogbase.ui @@ -1,6 +1,6 @@ KXEAttributeDialogBase - + KXEAttributeDialogBase @@ -79,7 +79,7 @@ - + m_pEditNamespace @@ -89,7 +89,7 @@ Enter the namespace URI for this attribute here. - + m_pEditValue @@ -99,7 +99,7 @@ Enter the namespace URI for this attribute here. Enter the attribute's value here. - + m_pEditQName @@ -109,7 +109,7 @@ Enter the attribute's value here. Enter a qualified name for the attribute here. - + Layout1 @@ -140,7 +140,7 @@ Enter a qualified name for the attribute here. - + m_pBtnOK @@ -157,7 +157,7 @@ Enter a qualified name for the attribute here. true - + m_pBtnCancel @@ -173,7 +173,7 @@ Enter a qualified name for the attribute here. - + m_pLblValue @@ -189,7 +189,7 @@ Enter a qualified name for the attribute here. Enter the attribute's value here. - + m_pLblQName @@ -205,7 +205,7 @@ Enter the attribute's value here. Enter a qualified name for the attribute here. - + m_pLblNamespace @@ -221,7 +221,7 @@ Enter a qualified name for the attribute here. Enter the namespace URI for this attribute here. - + m_pTextLabelMessage diff --git a/part/kxechardatadialog.cpp b/part/kxechardatadialog.cpp index 483ab1c..434c156 100644 --- a/part/kxechardatadialog.cpp +++ b/part/kxechardatadialog.cpp @@ -17,15 +17,15 @@ #include "kxechardatadialog.h" -#include -#include -#include -#include +#include +#include +#include +#include #include #include -KXECharDataDialog::KXECharDataDialog( QWidget * pParent, const char * pszName, bool fModal, WFlags fl ) +KXECharDataDialog::KXECharDataDialog( TQWidget * pParent, const char * pszName, bool fModal, WFlags fl ) : KXECharDataDialogBase( pParent, pszName, fModal, fl ) { connect( m_pEditData, SIGNAL(textChanged()), this, SLOT(slotDataChanged()) ); @@ -82,7 +82,7 @@ int KXECharDataDialog::exec() void KXECharDataDialog::slotDataChanged() { - QString strMessage = checkContents(m_pEditData->text()); + TQString strMessage = checkContents(m_pEditData->text()); m_pTextLabelMessage->setText(strMessage); @@ -93,22 +93,22 @@ void KXECharDataDialog::slotDataChanged() } // Check, if XML chardata contents is OK -QString KXECharDataDialog::checkContents(const QString strData) +TQString KXECharDataDialog::checkContents(const TQString strData) { if(strData.length() == 0) return ""; // Forbidden characters - /*QString strForbiddenChars("<>"); + /*TQString strForbiddenChars("<>"); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strData.find(ch) >= 0) return i18n("Contents cannot contain character: %1 !").arg(ch); } - L.V. Removed this check, bacause QDomCharacterData.setData() escapec special + L.V. Removed this check, bacause TQDomCharacterData.setData() escapec special charactesr and data() unescapes it back to original string */ diff --git a/part/kxechardatadialog.h b/part/kxechardatadialog.h index 7e1507b..2e263a8 100644 --- a/part/kxechardatadialog.h +++ b/part/kxechardatadialog.h @@ -32,13 +32,13 @@ class KXECharDataDialog : public KXECharDataDialogBase Q_OBJECT public: - KXECharDataDialog( QWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); + KXECharDataDialog( TQWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); // const CharDataKind charDataKind() const { return m_eCharDataKind; } const bool atTop() const { return m_bAtTop; } - const QString contents() const { return m_strContents; } + const TQString contents() const { return m_strContents; } - void setContents(const QString strContents) { m_strContents = strContents; } + void setContents(const TQString strContents) { m_strContents = strContents; } // void setCharDataKind(const CharDataKind eCharDataKind) { m_eCharDataKind = eCharDataKind; } public: @@ -47,7 +47,7 @@ class KXECharDataDialog : public KXECharDataDialogBase * To be used for inserting the given XML character data as child * of the given parent element. * - * @return see @ref QDialog::exec + * @return see @ref TQDialog::exec */ int exec( bool ); @@ -57,7 +57,7 @@ class KXECharDataDialog : public KXECharDataDialogBase void clearDialog(); // check contents - static QString checkContents(const QString); + static TQString checkContents(const TQString); protected: /** @@ -77,7 +77,7 @@ class KXECharDataDialog : public KXECharDataDialogBase protected: //CharDataKind m_eCharDataKind; bool m_bAtTop; - QString m_strContents; + TQString m_strContents; }; #endif diff --git a/part/kxechardatadialogbase.ui b/part/kxechardatadialogbase.ui index 7f8b874..3d85300 100644 --- a/part/kxechardatadialogbase.ui +++ b/part/kxechardatadialogbase.ui @@ -1,6 +1,6 @@ KXECharDataDialogBase - + KXECharDataDialogBase @@ -28,7 +28,7 @@ 6 - + Layout4 @@ -42,7 +42,7 @@ 6 - + m_pLblInsert @@ -58,7 +58,7 @@ Choose, where to place this XML character data in the XML elements list of childnodes. - + at bottom @@ -97,7 +97,7 @@ Choose, where to place this XML character data in the XML elements list of child - + m_pEditData @@ -111,7 +111,7 @@ Choose, where to place this XML character data in the XML elements list of child You can edit the XML character data in this editor. - + Layout1 @@ -142,7 +142,7 @@ Choose, where to place this XML character data in the XML elements list of child - + m_pBtnOK @@ -159,7 +159,7 @@ Choose, where to place this XML character data in the XML elements list of child true - + m_pBtnCancel @@ -172,7 +172,7 @@ Choose, where to place this XML character data in the XML elements list of child - + m_pTextLabelMessage diff --git a/part/kxechoosestringdialog.cpp b/part/kxechoosestringdialog.cpp index f46856b..180b865 100644 --- a/part/kxechoosestringdialog.cpp +++ b/part/kxechoosestringdialog.cpp @@ -17,11 +17,11 @@ #include "kxechoosestringdialog.h" -#include -#include -#include +#include +#include +#include -KXEChooseStringDialog::KXEChooseStringDialog(QWidget *parent, +KXEChooseStringDialog::KXEChooseStringDialog(TQWidget *parent, const char *name, const char *szCaption, const char *szPrompt) diff --git a/part/kxechoosestringdialog.h b/part/kxechoosestringdialog.h index 2065e3a..13c12cc 100644 --- a/part/kxechoosestringdialog.h +++ b/part/kxechoosestringdialog.h @@ -20,7 +20,7 @@ #include "kxechoosestringdialogbase.h" -#include +#include /**Dialog with combobox that allow enter or select any string @@ -31,14 +31,14 @@ class KXEChooseStringDialog : public KXEChooseStringDialogBase { Q_OBJECT public: - KXEChooseStringDialog(QWidget *, const char *, const char *, const char *); + KXEChooseStringDialog(TQWidget *, const char *, const char *, const char *); protected slots: // Protected slots /** Called, when user press OK button */ void slotOk(); public: // Public attributes /** Contain text choosed by user */ - QString m_strChoosedText; + TQString m_strChoosedText; }; #endif diff --git a/part/kxechoosestringdialogbase.ui b/part/kxechoosestringdialogbase.ui index 5fb8079..58e5cb8 100644 --- a/part/kxechoosestringdialogbase.ui +++ b/part/kxechoosestringdialogbase.ui @@ -3,7 +3,7 @@ Dialog with combobox that allow enter or select any string Lumir Vanek - + KXEChooseStringDialogBase @@ -28,7 +28,7 @@ or select any string 6 - + m_pComboBox @@ -38,7 +38,7 @@ or select any string Enter or choose string, that you want. - + Layout3 @@ -69,7 +69,7 @@ Enter or choose string, that you want. - + m_pPushButtonOk @@ -77,7 +77,7 @@ Enter or choose string, that you want. &OK - + m_pPushButtonCancel @@ -87,7 +87,7 @@ Enter or choose string, that you want. - + m_pTextLabel diff --git a/part/kxeconfiguration.cpp b/part/kxeconfiguration.cpp index 1b933b3..a06e90e 100644 --- a/part/kxeconfiguration.cpp +++ b/part/kxeconfiguration.cpp @@ -27,11 +27,11 @@ #include #include -#include +#include KXEConfiguration::KXEConfiguration() - : QObject( 0, "KXMLEditor's configuration (KXEConfiguration)" ), + : TQObject( 0, "KXMLEditor's configuration (KXEConfiguration)" ), m_pDialog( 0 ) { // initialize all setting group objects @@ -94,15 +94,15 @@ void KXEConfiguration::showDialog() connect( m_pDialog, SIGNAL(okClicked()), this, SLOT(slotDlgApplied()) ); // and add the pages - QFrame * pFrame; - QWidget * pPage; - QVBoxLayout * pLayout; + TQFrame * pFrame; + TQWidget * pPage; + TQVBoxLayout * pLayout; // - tree view properties page pFrame = m_pDialog->addPage( m_pTreeView->dialogPageName(), m_pTreeView->dialogPageHeader(), KGlobal::instance()->iconLoader()->loadIcon( m_pTreeView->dialogPageIcon(), KIcon::NoGroup, KIcon::SizeMedium ) ); - pLayout = new QVBoxLayout( pFrame ); + pLayout = new TQVBoxLayout( pFrame ); pPage = m_pTreeView->dialogPage( pFrame ); pLayout->addWidget( pPage ); connect( m_pTreeView, SIGNAL(sigDialogPageChanged()), this, SLOT(slotDlgChanged()) ); @@ -111,7 +111,7 @@ void KXEConfiguration::showDialog() pFrame = m_pDialog->addPage( m_pTextView->dialogPageName(), m_pTextView->dialogPageHeader(), KGlobal::instance()->iconLoader()->loadIcon( m_pTextView->dialogPageIcon(), KIcon::NoGroup, KIcon::SizeMedium ) ); - pLayout = new QVBoxLayout( pFrame ); + pLayout = new TQVBoxLayout( pFrame ); pPage = m_pTextView->dialogPage( pFrame ); pLayout->addWidget( pPage ); connect( m_pTextView, SIGNAL(sigDialogPageChanged()), this, SLOT(slotDlgChanged()) ); @@ -120,7 +120,7 @@ void KXEConfiguration::showDialog() pFrame = m_pDialog->addPage( m_pNewFile->dialogPageName(), m_pNewFile->dialogPageHeader(), KGlobal::instance()->iconLoader()->loadIcon( m_pNewFile->dialogPageIcon(), KIcon::NoGroup, KIcon::SizeMedium ) ); - pLayout = new QVBoxLayout( pFrame ); + pLayout = new TQVBoxLayout( pFrame ); pPage = m_pNewFile->dialogPage( pFrame ); pLayout->addWidget( pPage ); connect( m_pNewFile, SIGNAL(sigDialogPageChanged()), this, SLOT(slotDlgChanged()) ); @@ -129,7 +129,7 @@ void KXEConfiguration::showDialog() pFrame = m_pDialog->addPage( m_pPrint->dialogPageName(), m_pPrint->dialogPageHeader(), KGlobal::instance()->iconLoader()->loadIcon( m_pPrint->dialogPageIcon(), KIcon::NoGroup, KIcon::SizeMedium ) ); - pLayout = new QVBoxLayout( pFrame ); + pLayout = new TQVBoxLayout( pFrame ); pPage = m_pPrint->dialogPage( pFrame ); pLayout->addWidget( pPage ); connect( m_pPrint, SIGNAL(sigDialogPageChanged()), this, SLOT(slotDlgChanged()) ); @@ -138,7 +138,7 @@ void KXEConfiguration::showDialog() pFrame = m_pDialog->addPage( m_pArcExts->dialogPageName(), m_pArcExts->dialogPageHeader(), KGlobal::instance()->iconLoader()->loadIcon( m_pArcExts->dialogPageIcon(), KIcon::NoGroup, KIcon::SizeMedium ) ); - pLayout = new QVBoxLayout( pFrame ); + pLayout = new TQVBoxLayout( pFrame ); pPage = m_pArcExts->dialogPage( pFrame ); pLayout->addWidget( pPage ); connect( m_pArcExts, SIGNAL(sigDialogPageChanged()), this, SLOT(slotDlgChanged()) ); diff --git a/part/kxeconfiguration.h b/part/kxeconfiguration.h index 3afd8b2..a0569c8 100644 --- a/part/kxeconfiguration.h +++ b/part/kxeconfiguration.h @@ -18,7 +18,7 @@ #ifndef KXECONFIGURATION_H #define KXECONFIGURATION_H -#include +#include class KXETreeViewSettings; class KXETextViewSettings; @@ -39,7 +39,7 @@ class KDialogBase; * @short container for KXMLEditor's configuration data * @author Olaf Hartig */ -class KXEConfiguration : public QObject +class KXEConfiguration : public TQObject { Q_OBJECT diff --git a/part/kxedocument.cpp b/part/kxedocument.cpp index 8f48529..52394fa 100644 --- a/part/kxedocument.cpp +++ b/part/kxedocument.cpp @@ -37,16 +37,16 @@ #include #include -#include -#include -#include -#include -#include -#include - -KXEDocument::KXEDocument(QObject *parent, const char *name) - :QObject (parent,name), - QDomDocument(), +#include +#include +#include +#include +#include +#include + +KXEDocument::KXEDocument(TQObject *parent, const char *name) + :TQObject (parent,name), + TQDomDocument(), KXMLGUIClient() { m_bDocIsCompressed = false; @@ -63,7 +63,7 @@ KXEDocument::~KXEDocument() } -bool KXEDocument::save(const QString &strFileName) +bool KXEDocument::save(const TQString &strFileName) { if (this->documentElement().isNull() && KMessageBox::warningContinueCancel(0, @@ -73,14 +73,14 @@ bool KXEDocument::save(const QString &strFileName) return false; } - QString strXML; + TQString strXML; - QTextStream streamXML(&strXML, IO_WriteOnly); + TQTextStream streamXML(&strXML, IO_WriteOnly); int iIndent = KXMLEditorFactory::configuration()->textview()->indentSteps(); - ((QDomDocument*)this)->save(streamXML, iIndent); + ((TQDomDocument*)this)->save(streamXML, iIndent); - QString strEncoding; - QTextCodec *pTextCodec; + TQString strEncoding; + TQTextCodec *pTextCodec; // find encoding info if(strXML.left(5) == " 0) + if((iStart = strXML.find(TQRegExp("[\"']"), iStart)) > 0) { - QChar ch = strXML[iStart]; + TQChar ch = strXML[iStart]; iStart++; // skip ch if((iEnd = strXML.find(ch, iStart)) > 0) { @@ -104,23 +104,23 @@ bool KXEDocument::save(const QString &strFileName) } if(strEncoding.length() <= 0) - pTextCodec = QTextCodec::codecForLocale(); // default + pTextCodec = TQTextCodec::codecForLocale(); // default else - pTextCodec = QTextCodec::codecForName(strEncoding); + pTextCodec = TQTextCodec::codecForName(strEncoding); if(pTextCodec == 0) { if(KMessageBox::questionYesNo(0, i18n("Codec for encoding %1 not found ! Continue saving ?").arg(strEncoding)) != KMessageBox::Yes) return false; } - QCString strDecoded; + TQCString strDecoded; if(pTextCodec) { strDecoded = pTextCodec->fromUnicode(strXML); } // save string to file if(!m_bDocIsCompressed) - { QFile file(strFileName); + { TQFile file(strFileName); if(file.open(IO_WriteOnly) == true) { file.writeBlock(strDecoded, strDecoded.length()); file.flush(); @@ -134,7 +134,7 @@ bool KXEDocument::save(const QString &strFileName) } else { // obtain file extension ----------------------------------------- - QString strExtension; + TQString strExtension; int iPos = strFileName.findRev('.'); @@ -167,14 +167,14 @@ bool KXEDocument::save(const QString &strFileName) return true; } -bool KXEDocument::open(const QString &strFileName) +bool KXEDocument::open(const TQString &strFileName) { - QString strCompressedTarEntryName; + TQString strCompressedTarEntryName; kdDebug() << "KXEDocument::open: opening file " << strFileName << endl; // obtain file extension ----------------------------------------- - QString strExtension; + TQString strExtension; int iPos = strFileName.findRev('.'); @@ -182,7 +182,7 @@ bool KXEDocument::open(const QString &strFileName) { strExtension = strFileName.mid(iPos + 1); } - QString strTmpfileName; + TQString strTmpfileName; if ( KXMLEditorFactory::configuration()->archexts()->extensions().contains(strExtension) ) { @@ -196,7 +196,7 @@ bool KXEDocument::open(const QString &strFileName) } tmp.setAutoDelete(false); - QFile &fileTemporary = *(tmp.file()); + TQFile &fileTemporary = *(tmp.file()); if(strExtension == "svgz") @@ -211,12 +211,12 @@ bool KXEDocument::open(const QString &strFileName) { m_strCompressedTarEntryName = m_strCompressedTarEntryName.mid(iPos + 1); } - QIODevice *pIODevice = KFilterDev::deviceForFile(strFileName, "application/x-gzip"); + TQIODevice *pIODevice = KFilterDev::deviceForFile(strFileName, "application/x-gzip"); if(pIODevice->open( IO_ReadOnly )) { - QTextStream stream(pIODevice); - QString line; + TQTextStream stream(pIODevice); + TQString line; //int i = 1; while ( !stream.atEnd() ) { @@ -263,7 +263,7 @@ bool KXEDocument::open(const QString &strFileName) if(entry && entry->isFile()) { const KArchiveFile *pTarFile = static_cast (entry); - QBuffer buffer(pTarFile->data()); + TQBuffer buffer(pTarFile->data()); buffer.open(IO_ReadOnly); fileTemporary.writeBlock(buffer.buffer(), buffer.size()); @@ -284,7 +284,7 @@ bool KXEDocument::open(const QString &strFileName) // ( 1.) parse the file and fill our document - QFile file(m_bDocIsCompressed ? strTmpfileName : strFileName); + TQFile file(m_bDocIsCompressed ? strTmpfileName : strFileName); if(! file.open(IO_ReadOnly)) { kdDebug() << "KXEDocument::openFile: Can't open file." << endl; @@ -292,42 +292,42 @@ bool KXEDocument::open(const QString &strFileName) } // auxiliary file for obtaining encoding info - QFile fileAux(m_bDocIsCompressed ? strTmpfileName : strFileName); + TQFile fileAux(m_bDocIsCompressed ? strTmpfileName : strFileName); if(! fileAux.open(IO_ReadOnly)) { kdDebug() << "KXEDocument::openFile: Can't open file." << endl; return false; } - QTextStream txtStreamLocal( & file ); + TQTextStream txtStreamLocal( & file ); // Lookup at XML document encoding ----------------------------------------------- - QTextStream txtStreamAux( & fileAux ); - QString strFirstLine = txtStreamAux.readLine(); + TQTextStream txtStreamAux( & fileAux ); + TQString strFirstLine = txtStreamAux.readLine(); fileAux.close(); int iStart, iEnd; if((iStart = strFirstLine.find("encoding", 0)) > 0) { - QString strEncoding; + TQString strEncoding; // info about encoding found; iStart += 8; // skip encoding // search " or ' after encoding - if((iStart = strFirstLine.find(QRegExp("[\"']"), iStart)) > 0) + if((iStart = strFirstLine.find(TQRegExp("[\"']"), iStart)) > 0) { - QChar ch = strFirstLine[iStart]; + TQChar ch = strFirstLine[iStart]; iStart++; // skip ch if((iEnd = strFirstLine.find(ch, iStart)) > 0) { strEncoding = strFirstLine.mid(iStart, iEnd - iStart); - QTextCodec *pTextCodec = QTextCodec::codecForName(strEncoding); + TQTextCodec *pTextCodec = TQTextCodec::codecForName(strEncoding); if(pTextCodec) txtStreamLocal.setCodec(pTextCodec); else { KMessageBox::sorry(0, i18n("Codec for encoding %1 not found ! Using locale encoding for load.").arg(strEncoding)); - txtStreamLocal.setEncoding(QTextStream::Locale); + txtStreamLocal.setEncoding(TQTextStream::Locale); } } } @@ -335,24 +335,24 @@ bool KXEDocument::open(const QString &strFileName) else { // XML documment dont have info about encoding, set default UTF-8 - txtStreamLocal.setCodec(QTextCodec::codecForName("UTF-8")); + txtStreamLocal.setCodec(TQTextCodec::codecForName("UTF-8")); } //-------------------------------------------------------------------------------- - QString strFileContents = txtStreamLocal.read(); + TQString strFileContents = txtStreamLocal.read(); file.close(); if(m_bDocIsCompressed) { - QDir dir; + TQDir dir; dir.remove(strTmpfileName); } - //-- Set string with XML to QDomDocument ------------------------------------------ - QString strErrorMsg; + //-- Set string with XML to TQDomDocument ------------------------------------------ + TQString strErrorMsg; int iErrorLine, iErrorColumn; - QDomDocument * pNewDoc = new QDomDocument; // first try with a new document + TQDomDocument * pNewDoc = new TQDomDocument; // first try with a new document if( ! pNewDoc->setContent(strFileContents, true, &strErrorMsg, &iErrorLine, &iErrorColumn) ) { kdDebug() << "KXEDocument::openFile: Failed parsing the file." << endl; @@ -368,8 +368,8 @@ bool KXEDocument::open(const QString &strFileName) // The following commented code is performance wise buggy, because the string // gets parsed a second time. I replaced it with this code. // copy the content of the parsed document to this one - QDomNode e = pNewDoc->removeChild( pNewDoc->documentElement() ); - QDomDocument::operator=( *pNewDoc ); + TQDomNode e = pNewDoc->removeChild( pNewDoc->documentElement() ); + TQDomDocument::operator=( *pNewDoc ); appendChild( e ); // Here comes the "buggy" code. //this->setContent(pNewDoc->toString(),true,0,0); // and take the new one @@ -397,37 +397,37 @@ void KXEDocument::setURL(KURL url) emit sigURLChanged(url); } -void KXEDocument::updateNodeCreated(const QDomNode & node) +void KXEDocument::updateNodeCreated(const TQDomNode & node) { emit sigNodeCreated(node); setModified(); } -void KXEDocument::updateNodeDeleted(const QDomNode & node) +void KXEDocument::updateNodeDeleted(const TQDomNode & node) { emit sigNodeDeleted(node); setModified(); } -void KXEDocument::updateNodeChanged( const QDomElement & domElement ) +void KXEDocument::updateNodeChanged( const TQDomElement & domElement ) { emit sigNodeChanged(domElement); setModified(); } -void KXEDocument::updateNodeChanged( const QDomCharacterData & node ) +void KXEDocument::updateNodeChanged( const TQDomCharacterData & node ) { emit sigNodeChanged(node); setModified(); } -void KXEDocument::updateNodeChanged( const QDomProcessingInstruction &domProcInstr ) +void KXEDocument::updateNodeChanged( const TQDomProcessingInstruction &domProcInstr ) { emit sigNodeChanged(domProcInstr); setModified(); } -void KXEDocument::updateNodeMoved( const QDomNode & node ) +void KXEDocument::updateNodeMoved( const TQDomNode & node ) { emit sigNodeMoved(node); setModified(); @@ -435,7 +435,7 @@ void KXEDocument::updateNodeMoved( const QDomNode & node ) void KXEDocument::attachStylesheet(const KURL& stylesheet) { - setSpecProcInstr("xml-stylesheet",QString("type = 'text/xsl' href = '")+stylesheet.url()+"' "); + setSpecProcInstr("xml-stylesheet",TQString("type = 'text/xsl' href = '")+stylesheet.url()+"' "); } void KXEDocument::detachStylesheet() @@ -445,7 +445,7 @@ void KXEDocument::detachStylesheet() void KXEDocument::attachSchema(const KURL& schema) { - QDomElement domElement = documentElement(); + TQDomElement domElement = documentElement(); if (!domElement.isNull()) { domElement.setAttributeNS(SCHEMA_NAMESPACE, @@ -459,7 +459,7 @@ void KXEDocument::attachSchema(const KURL& schema) void KXEDocument::detachSchema() { - QDomElement domElement = this->documentElement(); + TQDomElement domElement = this->documentElement(); if (!domElement.isNull()) { domElement.removeAttributeNS(SCHEMA_NAMESPACE,SCHEMA_ATTRIBUTE); @@ -469,16 +469,16 @@ void KXEDocument::detachSchema() } } -void KXEDocument::setSpecProcInstr(const QString& target, const QString& data) +void KXEDocument::setSpecProcInstr(const TQString& target, const TQString& data) { // removing old one removeSpecProcInstr(target); // create new one if (!data.isEmpty()) { - QDomProcessingInstruction domProcInstr = this->createProcessingInstruction(target,data); + TQDomProcessingInstruction domProcInstr = this->createProcessingInstruction(target,data); - QDomNode node = getSpecProcInstr("xml"); + TQDomNode node = getSpecProcInstr("xml"); if (!node.isNull()) // if there is already xml instruction, then put that one below it this->insertAfter(domProcInstr,node); @@ -491,25 +491,25 @@ void KXEDocument::setSpecProcInstr(const QString& target, const QString& data) setModified(); } -void KXEDocument::removeSpecProcInstr(const QString &target) +void KXEDocument::removeSpecProcInstr(const TQString &target) { - QDomNode domNode = getSpecProcInstr(target); + TQDomNode domNode = getSpecProcInstr(target); if (!domNode.isNull()) { updateNodeDeleted(domNode); - ((QDomDocument*)this)->removeChild(domNode); + ((TQDomDocument*)this)->removeChild(domNode); setModified(); } } -QDomNode KXEDocument::getSpecProcInstr(const QString& target) +TQDomNode KXEDocument::getSpecProcInstr(const TQString& target) { - QDomNode result; - QDomNodeList domNodeList = this->childNodes(); + TQDomNode result; + TQDomNodeList domNodeList = this->childNodes(); for (uint i=0;inewfile()->dfltVersion()).arg(KXMLEditorFactory::configuration()->newfile()->dfltEncoding()) ); + setSpecProcInstr( "xml", TQString( "version='%1' encoding='%2'" ).arg(KXMLEditorFactory::configuration()->newfile()->dfltVersion()).arg(KXMLEditorFactory::configuration()->newfile()->dfltEncoding()) ); break; } emit sigOpened(); @@ -553,7 +553,7 @@ void KXEDocument::newFile() KCommand * KXEDocument::actDetachStylesheet() { - QDomNode domNode = getSpecProcInstr("xml-stylesheet"); + TQDomNode domNode = getSpecProcInstr("xml-stylesheet"); if (!domNode.isNull()) { KCommand *pCmd = new KXEStylesheetDetachCommand(this,domNode.toProcessingInstruction().data()); @@ -568,8 +568,8 @@ KCommand * KXEDocument::actAttachStylesheet() dlg.Label->setText(i18n("Stylesheet URL:")); if (dlg.exec()) { - QDomNode domNode = getSpecProcInstr("xml-stylesheet"); - QString data = ""; + TQDomNode domNode = getSpecProcInstr("xml-stylesheet"); + TQString data = ""; if (!domNode.isNull()) data = domNode.toProcessingInstruction().data(); KCommand *pCmd = new KXEStylesheetAttachCommand(this,data,dlg.attachURI->url()); @@ -610,7 +610,7 @@ KCommand * KXEDocument::actAttachSchema() // Instert or edit special processing instruction KCommand * KXEDocument::actVersionEncoding() { - QDomNode node = getSpecProcInstr("xml"); + TQDomNode node = getSpecProcInstr("xml"); KXESpecProcInstrDialog dlg; if(!node.isNull()) @@ -621,7 +621,7 @@ KCommand * KXEDocument::actVersionEncoding() if(dlg.exec()) { - QString strOldData = ""; + TQString strOldData = ""; if (!node.isNull()) strOldData = node.toProcessingInstruction().data(); KCommand *pCmd = new KXEVersionEncodingCommand(this,strOldData,dlg.getData()); diff --git a/part/kxedocument.h b/part/kxedocument.h index 2b78659..7379086 100644 --- a/part/kxedocument.h +++ b/part/kxedocument.h @@ -14,8 +14,8 @@ #include -#include -#include +#include +#include #include #include @@ -23,7 +23,7 @@ #define SCHEMA_ATTRIBUTE "schemaLocation" #define SCHEMA_ATTRIBUTE_XSI "xsi:schemaLocation" -class QString; +class TQString; class KCommand; @@ -39,21 +39,21 @@ Stores XML document data which can be manipulated by KXMLEditor application. @author Adam Charytoniuk */ -class KXEDocument : public QObject, public QDomDocument, public KXMLGUIClient +class KXEDocument : public TQObject, public TQDomDocument, public KXMLGUIClient { Q_OBJECT public: /** @short Constructor */ - KXEDocument(QObject *parent=0, const char *name=0); + KXEDocument(TQObject *parent=0, const char *name=0); /** @short Destructor */ ~KXEDocument(); /** @short Saves document into given file */ - bool save(const QString &); + bool save(const TQString &); /** @short Loads document from given file */ - bool open(const QString &); + bool open(const TQString &); /** @short Sets modification flag. @@ -76,7 +76,7 @@ public: @param node newly created node */ - void updateNodeCreated(const QDomNode & node); + void updateNodeCreated(const TQDomNode & node); /** @short Notifies views about deleting node @@ -84,14 +84,14 @@ public: This will give a chanse to the views to remove that node visualization. @param node that is going to be deleted */ - void updateNodeDeleted(const QDomNode & node); + void updateNodeDeleted(const TQDomNode & node); /** @short Notifies views about element properties changes Should be called after element name or element attributes are changed. @param domElement element that has changed */ - void updateNodeChanged( const QDomElement & domElement ); + void updateNodeChanged( const TQDomElement & domElement ); /** @short Notifies views after change char. data properties @@ -99,21 +99,21 @@ public: (including texts, comments, .CDATA sections). @param node character data node that has changed */ - void updateNodeChanged( const QDomCharacterData & node ) ; + void updateNodeChanged( const TQDomCharacterData & node ) ; /** @short Notifies views after change proc. instr. properties Should be called after any processing intruction is changed. @param domProcInstr processing instruction that has changed */ - void updateNodeChanged( const QDomProcessingInstruction &domProcInstr ); + void updateNodeChanged( const TQDomProcessingInstruction &domProcInstr ); /** @short Notifies views after moving node Should be called if any node in the document was moved. @param node XML node that has been moved */ - void updateNodeMoved( const QDomNode & node ); + void updateNodeMoved( const TQDomNode & node ); /** @short Removes spec. processing instruction from XML file. @@ -121,24 +121,24 @@ public: @warning Removes processing instruction from DomDocument children node list only (no subnodes are modiified). @sa setSpecProcInstr() */ - void removeSpecProcInstr(const QString &target); + void removeSpecProcInstr(const TQString &target); /** @short Adds or changes (if already exists) processing instruction. - Processing instruction will be added as a child in QDomDocument object. + Processing instruction will be added as a child in TQDomDocument object. @param target processing intruction target @param data processing intruction data @sa removeSpecProcInstr() */ - virtual void setSpecProcInstr(const QString& target, const QString& data); + virtual void setSpecProcInstr(const TQString& target, const TQString& data); - /** @short Returns processing instruction located in QDomDocument. + /** @short Returns processing instruction located in TQDomDocument. If given processing intruction is not found, null node is returned. @param target name of the processing instruction target. @sa setSpecProcInstr() */ - QDomNode getSpecProcInstr(const QString& target); + TQDomNode getSpecProcInstr(const TQString& target); /** @short Attaches stylesheet to current XML file. @@ -192,7 +192,7 @@ public: KCommand * actAttachSchema(); private: - QString m_strCompressedTarEntryName; + TQString m_strCompressedTarEntryName; /** Equals true if document was opened from compressed file */ bool m_bDocIsCompressed; /** @short Stores modification flag */ @@ -218,11 +218,11 @@ signals: void sigURLChanged(KURL url); /** @short Emitted when new node was added to document.*/ - void sigNodeCreated(const QDomNode & node); + void sigNodeCreated(const TQDomNode & node); /** @short Emitted everytime node was deleted from document.*/ - void sigNodeDeleted(const QDomNode & node); + void sigNodeDeleted(const TQDomNode & node); /** @short Emitted everytime document element was changed .*/ - void sigNodeChanged( const QDomElement & domElement ); + void sigNodeChanged( const TQDomElement & domElement ); /** @short Emitted everytime character data node was changed. This is the case for nodes like: @@ -230,11 +230,11 @@ signals: - comments, - CDATA sections, */ - void sigNodeChanged( const QDomCharacterData & node ) ; + void sigNodeChanged( const TQDomCharacterData & node ) ; /** @short Emitted everytime processing instruction in document was changed .*/ - void sigNodeChanged( const QDomProcessingInstruction &domProcInstr ); + void sigNodeChanged( const TQDomProcessingInstruction &domProcInstr ); /** @short Emitted everytime document node was moved was changed .*/ - void sigNodeMoved( const QDomNode & node ); + void sigNodeMoved( const TQDomNode & node ); }; #endif diff --git a/part/kxeelementdialog.cpp b/part/kxeelementdialog.cpp index e2fc14a..ef807c0 100644 --- a/part/kxeelementdialog.cpp +++ b/part/kxeelementdialog.cpp @@ -17,19 +17,19 @@ #include "kxeelementdialog.h" -#include -#include -#include +#include +#include +#include #include #include #include -KXEElementDialog::KXEElementDialog( QWidget * pParent, const char * pszName, bool fModal, WFlags fl ) +KXEElementDialog::KXEElementDialog( TQWidget * pParent, const char * pszName, bool fModal, WFlags fl ) : KXEElementDialogBase( pParent, pszName, fModal, fl ) { - connect( m_pEditNsURI, SIGNAL(textChanged(const QString&)), this, SLOT(slotNsURIChanged(const QString&)) ); - connect( m_pEditName, SIGNAL(textChanged(const QString&)), this, SLOT(slotNameChanged(const QString&)) ); + connect( m_pEditNsURI, SIGNAL(textChanged(const TQString&)), this, SLOT(slotNsURIChanged(const TQString&)) ); + connect( m_pEditName, SIGNAL(textChanged(const TQString&)), this, SLOT(slotNameChanged(const TQString&)) ); } void KXEElementDialog::clearDialog() @@ -133,7 +133,7 @@ int KXEElementDialog::exec() return KXEElementDialogBase::exec(); } -void KXEElementDialog::slotNsURIChanged( const QString & strNewNsURI ) +void KXEElementDialog::slotNsURIChanged( const TQString & strNewNsURI ) { if ( strNewNsURI.isEmpty() ) m_pEditPrefix->setEnabled(false); @@ -141,9 +141,9 @@ void KXEElementDialog::slotNsURIChanged( const QString & strNewNsURI ) m_pEditPrefix->setEnabled(true); } -void KXEElementDialog::slotNameChanged( const QString & strNewName ) +void KXEElementDialog::slotNameChanged( const TQString & strNewName ) { - QString strMessage = checkName(strNewName); + TQString strMessage = checkName(strNewName); m_pTextLabelMessage->setText(strMessage); @@ -154,7 +154,7 @@ void KXEElementDialog::slotNameChanged( const QString & strNewName ) } // Check, if XML element name is OK -QString KXEElementDialog::checkName(const QString strElementName) +TQString KXEElementDialog::checkName(const TQString strElementName) { if(strElementName.length() == 0) return ""; @@ -168,17 +168,17 @@ QString KXEElementDialog::checkName(const QString strElementName) return i18n("Element name cannot start with 'xml' or 'XML' !"); // check first character - QChar firstChar(strElementName[0]); + TQChar firstChar(strElementName[0]); if((firstChar != '_') && !firstChar.isLetter()) { return i18n("Element name must start with an underscore or a letter !"); } // Forbidden characters - QString strForbiddenChars("&@#$%^()%+?=:<>;\"'*"); + TQString strForbiddenChars("&@#$%^()%+?=:<>;\"'*"); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strElementName.find(ch) >= 0) return i18n("Element name cannot contain character: %1 !").arg(ch); diff --git a/part/kxeelementdialog.h b/part/kxeelementdialog.h index 8012525..fec812c 100644 --- a/part/kxeelementdialog.h +++ b/part/kxeelementdialog.h @@ -25,28 +25,28 @@ class KXEElementDialog : public KXEElementDialogBase Q_OBJECT public: - KXEElementDialog( QWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); + KXEElementDialog( TQWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); public: - const QString nsURI() const { return m_strNsURI; } - const QString prefix() const { return m_strPrefix; } - const QString name() const { return m_strName; } + const TQString nsURI() const { return m_strNsURI; } + const TQString prefix() const { return m_strPrefix; } + const TQString name() const { return m_strName; } const bool atTop() const { return m_bAtTop; } - void setNsURI(const QString strNsURI) { m_strNsURI = strNsURI; } - void setPrefix(const QString strPrefix) { m_strPrefix = strPrefix; } - void setName(const QString strName) { m_strName = strName; } + void setNsURI(const TQString strNsURI) { m_strNsURI = strNsURI; } + void setPrefix(const TQString strPrefix) { m_strPrefix = strPrefix; } + void setName(const TQString strName) { m_strName = strName; } /** * To be used for creating a new XML element * - * @return see @ref QDialog::exec + * @return see @ref TQDialog::exec */ int exec( bool, bool, bool ); // check element name - static QString checkName(const QString); + static TQString checkName(const TQString); protected: /** @@ -74,18 +74,18 @@ class KXEElementDialog : public KXEElementDialogBase protected slots: - void slotNsURIChanged( const QString & szNewNsURI ); + void slotNsURIChanged( const TQString & szNewNsURI ); /** * Called, when the name in the edit line @ref DlgXMLElementBase::m_pEditName * is changed. * Disables the OK button, if the given string is empty. */ - void slotNameChanged( const QString & szNewName ); + void slotNameChanged( const TQString & szNewName ); protected: - QString m_strNsURI; - QString m_strPrefix; - QString m_strName; + TQString m_strNsURI; + TQString m_strPrefix; + TQString m_strName; bool m_bAtTop; }; diff --git a/part/kxeelementdialogbase.ui b/part/kxeelementdialogbase.ui index 0cf8cac..f531bbe 100644 --- a/part/kxeelementdialogbase.ui +++ b/part/kxeelementdialogbase.ui @@ -1,6 +1,6 @@ KXEElementDialogBase - + KXEElementDialogBase @@ -53,7 +53,7 @@ - + m_pLblPrefix @@ -103,7 +103,7 @@ You can enter the namespace prefix for this XML element here. - + m_pEditNsURI @@ -112,7 +112,7 @@ You can enter the namespace prefix for this XML element here. You can enter the namespace URI of this XML element here. - + m_pEditName @@ -122,7 +122,7 @@ You can enter the namespace URI of this XML element here. You have to enter this XML elements name here. - + m_pEditPrefix @@ -132,7 +132,7 @@ You have to enter this XML elements name here. You can enter the namespace prefix for this XML element here. - + m_pLblTagName @@ -148,7 +148,7 @@ You can enter the namespace prefix for this XML element here. You have to enter this XML elements name here. - + m_pLblNsURI @@ -163,7 +163,7 @@ You have to enter this XML elements name here. You can enter the namespace URI of this XML element here. - + Layout1 @@ -194,7 +194,7 @@ You can enter the namespace URI of this XML element here. - + m_pBtnOK @@ -211,7 +211,7 @@ You can enter the namespace URI of this XML element here. true - + m_pBtnCancel @@ -227,7 +227,7 @@ You can enter the namespace URI of this XML element here. - + Layout4 @@ -241,7 +241,7 @@ You can enter the namespace URI of this XML element here. 6 - + m_pLblInsert @@ -257,7 +257,7 @@ You can enter the namespace URI of this XML element here. Choose, where to place this XML element in the parent elements list of childelements. - + at bottom @@ -296,7 +296,7 @@ Choose, where to place this XML element in the parent elements list of childelem - + m_pTextLabelMessage diff --git a/part/kxefilenewdialog.cpp b/part/kxefilenewdialog.cpp index 807f477..39eaeb0 100644 --- a/part/kxefilenewdialog.cpp +++ b/part/kxefilenewdialog.cpp @@ -11,10 +11,10 @@ // #include "kxefilenewdialog.h" -#include -#include +#include +#include -KXEFileNewDialog::KXEFileNewDialog(QWidget* parent, const char* name) +KXEFileNewDialog::KXEFileNewDialog(TQWidget* parent, const char* name) : KXESpecProcInstrDialog(parent, name) { m_pDontShowAgain->show(); diff --git a/part/kxefilenewdialog.h b/part/kxefilenewdialog.h index 20b3f1b..ba1c44c 100644 --- a/part/kxefilenewdialog.h +++ b/part/kxefilenewdialog.h @@ -22,7 +22,7 @@ Dialog for File->New assistance. class KXEFileNewDialog : public KXESpecProcInstrDialog { public: - KXEFileNewDialog(QWidget* parent, const char* name=0); + KXEFileNewDialog(TQWidget* parent, const char* name=0); ~KXEFileNewDialog(); diff --git a/part/kxenewfilesettings.cpp b/part/kxenewfilesettings.cpp index fcd4562..cc9a4fc 100644 --- a/part/kxenewfilesettings.cpp +++ b/part/kxenewfilesettings.cpp @@ -22,11 +22,11 @@ #include #include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include #define CONF_ENTRY_NAME_DFLT_VERSION "Default version" #define DFLT_VALUE_DFLT_VERSION "1.0" @@ -38,7 +38,7 @@ #define DFLT_VALUE_NEWFILE_CREAT_BEHAVIOUR UseDefaults -KXENewFileSettings::KXENewFileSettings( QObject * pParent, const char * pszName ) +KXENewFileSettings::KXENewFileSettings( TQObject * pParent, const char * pszName ) : KXESettings( "New File Settings", pParent, pszName ), m_strDfltVersion( DFLT_VALUE_DFLT_VERSION ), m_strDfltEncoding( DFLT_VALUE_DFLT_ENCODING ), @@ -64,23 +64,23 @@ void KXENewFileSettings::read( const KConfig * pConfig ) } -QString KXENewFileSettings::dialogPageName() const +TQString KXENewFileSettings::dialogPageName() const { return i18n( "New Files" ); } -QString KXENewFileSettings::dialogPageHeader() const +TQString KXENewFileSettings::dialogPageHeader() const { return i18n( "New File Settings" ); } -QString KXENewFileSettings::dialogPageIcon() const +TQString KXENewFileSettings::dialogPageIcon() const { return "files"; } -QWidget * KXENewFileSettings::dialogPage( QFrame * pParent ) +TQWidget * KXENewFileSettings::dialogPage( TQFrame * pParent ) { if ( ! m_pDialogPage ) @@ -92,7 +92,7 @@ QWidget * KXENewFileSettings::dialogPage( QFrame * pParent ) m_pDialogPage->m_pDfltEncoding->insertStringList( encodings() ); updatePage(); - connect( m_pDialogPage->m_pDfltVersion, SIGNAL(textChanged(const QString&)), this, SIGNAL(sigDialogPageChanged()) ); + connect( m_pDialogPage->m_pDfltVersion, SIGNAL(textChanged(const TQString&)), this, SIGNAL(sigDialogPageChanged()) ); connect( m_pDialogPage->m_pDfltEncoding, SIGNAL(activated(int)), this, SIGNAL(sigDialogPageChanged()) ); connect( m_pDialogPage->m_pNewFileCreatBehav1, SIGNAL(toggled(bool)), this, SIGNAL(sigDialogPageChanged()) ); connect( m_pDialogPage->m_pNewFileCreatBehav2, SIGNAL(toggled(bool)), this, SIGNAL(sigDialogPageChanged()) ); @@ -142,9 +142,9 @@ void KXENewFileSettings::updatePage() const } } -QStringList KXENewFileSettings::encodings() +TQStringList KXENewFileSettings::encodings() { - static QStringList lstEncs; + static TQStringList lstEncs; if ( lstEncs.empty() ) { lstEncs.append("UTF-8"); diff --git a/part/kxenewfilesettings.h b/part/kxenewfilesettings.h index b1203ec..647f080 100644 --- a/part/kxenewfilesettings.h +++ b/part/kxenewfilesettings.h @@ -39,17 +39,17 @@ class KXENewFileSettings : public KXESettings UseDefaults }; - KXENewFileSettings( QObject * pParent = 0, const char * pszName = 0 ); + KXENewFileSettings( TQObject * pParent = 0, const char * pszName = 0 ); // The following functions can be used to access this object's settings. - QString dfltVersion() const { return m_strDfltVersion; } - QString dfltEncoding() const { return m_strDfltEncoding; } + TQString dfltVersion() const { return m_strDfltVersion; } + TQString dfltEncoding() const { return m_strDfltEncoding; } NewFileCreationBehaviour newFileCreaBehav() const { return m_enmNewFileCreaBehav; } /** * Returns a list of all possible encodings. */ - static QStringList encodings(); + static TQStringList encodings(); /** * Sets this object's new file creation behavior to the given one, @@ -62,19 +62,19 @@ class KXENewFileSettings : public KXESettings /** * Derived from @ref KXESettings */ - virtual QString dialogPageName() const; + virtual TQString dialogPageName() const; /** * Derived from @ref KXESettings */ - virtual QString dialogPageHeader() const; + virtual TQString dialogPageHeader() const; /** * Derived from @ref KXESettings */ - virtual QString dialogPageIcon() const; + virtual TQString dialogPageIcon() const; /** * Derived from @ref KXESettings */ - virtual QWidget * dialogPage( QFrame * pParent ); + virtual TQWidget * dialogPage( TQFrame * pParent ); protected: @@ -96,8 +96,8 @@ class KXENewFileSettings : public KXESettings virtual void updatePage() const; // the settings itself - QString m_strDfltVersion; - QString m_strDfltEncoding; + TQString m_strDfltVersion; + TQString m_strDfltEncoding; NewFileCreationBehaviour m_enmNewFileCreaBehav; /** diff --git a/part/kxenewfilesettingspage.ui b/part/kxenewfilesettingspage.ui index bf766e8..d5be1b8 100644 --- a/part/kxenewfilesettingspage.ui +++ b/part/kxenewfilesettingspage.ui @@ -1,6 +1,6 @@ KXENewFileSettingsPage - + KXENewFileSettingsPage @@ -19,7 +19,7 @@ unnamed - + layout3 @@ -27,7 +27,7 @@ unnamed - + m_pLblDfltVersion @@ -44,7 +44,7 @@ You can determine the default XML version for XML documents being created. This Since there's only one XML version yet, you shouldn't change this value. - + m_pDfltVersion @@ -57,7 +57,7 @@ Since there's only one XML version yet, you shouldn't change this value. - + layout4 @@ -65,7 +65,7 @@ Since there's only one XML version yet, you shouldn't change this value. unnamed - + m_pLblDfltEncoding @@ -81,7 +81,7 @@ Since there's only one XML version yet, you shouldn't change this value. - + m_pDfltEncoding @@ -93,7 +93,7 @@ You can determine the default encoding for XML documents being created. This ver - + m_pNewFileCreatBehav @@ -121,7 +121,7 @@ Creates an XML document with the default XML version and default encoding select unnamed - + m_pNewFileCreatBehav1 @@ -129,7 +129,7 @@ Creates an XML document with the default XML version and default encoding select Start with new empty file - + m_pNewFileCreatBehav2 @@ -140,7 +140,7 @@ Creates an XML document with the default XML version and default encoding select true - + m_pNewFileCreatBehav3 diff --git a/part/kxeprintsettings.cpp b/part/kxeprintsettings.cpp index 765102b..61451fe 100644 --- a/part/kxeprintsettings.cpp +++ b/part/kxeprintsettings.cpp @@ -22,9 +22,9 @@ #include #include -#include -#include -#include +#include +#include +#include #define CONF_ENTRY_NAME_FONTFAMILY "Print font family" #define DFLT_VALUE_FONTFAMILY "Courier" @@ -42,7 +42,7 @@ #define DFLT_VALUE_WITH_HEADER true -KXEPrintSettings::KXEPrintSettings( QObject * pParent, const char * pszName ) +KXEPrintSettings::KXEPrintSettings( TQObject * pParent, const char * pszName ) : KXESettings( "Print Settings", pParent, pszName ), m_strFontFamily( DFLT_VALUE_FONTFAMILY ), m_iFontSize( DFLT_VALUE_FONTSIZE ), @@ -73,22 +73,22 @@ void KXEPrintSettings::read( const KConfig * pConfig ) m_bWithFooter = pConfig->readBoolEntry( CONF_ENTRY_NAME_WITH_HEADER, DFLT_VALUE_WITH_HEADER ); } -QString KXEPrintSettings::dialogPageName() const +TQString KXEPrintSettings::dialogPageName() const { return i18n( "Printing" ); } -QString KXEPrintSettings::dialogPageHeader() const +TQString KXEPrintSettings::dialogPageHeader() const { return i18n( "Print Settings" ); } -QString KXEPrintSettings::dialogPageIcon() const +TQString KXEPrintSettings::dialogPageIcon() const { return "printer2"; } -QWidget * KXEPrintSettings::dialogPage( QFrame * pParent ) +TQWidget * KXEPrintSettings::dialogPage( TQFrame * pParent ) { if ( ! m_pDialogPage ) { diff --git a/part/kxeprintsettings.h b/part/kxeprintsettings.h index fb833f6..0b24a0f 100644 --- a/part/kxeprintsettings.h +++ b/part/kxeprintsettings.h @@ -32,10 +32,10 @@ class KXEPrintSettings : public KXESettings { public: - KXEPrintSettings( QObject * pParent = 0, const char * pszName = 0 ); + KXEPrintSettings( TQObject * pParent = 0, const char * pszName = 0 ); // The following functions can be used to access this object's settings. - QString fontFamily() const { return m_strFontFamily; } + TQString fontFamily() const { return m_strFontFamily; } int fontSize() const { return m_iFontSize; } int indentSteps() const { return m_iIndentSteps; } bool hasHeader() const { return m_bWithHeader; } @@ -44,19 +44,19 @@ class KXEPrintSettings : public KXESettings /** * Derived from @ref KXESettings */ - virtual QString dialogPageName() const; + virtual TQString dialogPageName() const; /** * Derived from @ref KXESettings */ - virtual QString dialogPageHeader() const; + virtual TQString dialogPageHeader() const; /** * Derived from @ref KXESettings */ - virtual QString dialogPageIcon() const; + virtual TQString dialogPageIcon() const; /** * Derived from @ref KXESettings */ - virtual QWidget * dialogPage( QFrame * pParent ); + virtual TQWidget * dialogPage( TQFrame * pParent ); protected: @@ -78,7 +78,7 @@ class KXEPrintSettings : public KXESettings virtual void updatePage() const; // the settings itself - QString m_strFontFamily; + TQString m_strFontFamily; int m_iFontSize; int m_iIndentSteps; bool m_bWithHeader; diff --git a/part/kxeprintsettingspage.ui b/part/kxeprintsettingspage.ui index a857413..69d6eb1 100644 --- a/part/kxeprintsettingspage.ui +++ b/part/kxeprintsettingspage.ui @@ -1,6 +1,6 @@ KXEPrintSettingsPage - + KXEPrintSettingsPage @@ -19,7 +19,7 @@ unnamed - + m_pLblFontFamily @@ -51,7 +51,7 @@ Choose the font family you want to be used on printing your XML documents. - + layout3 @@ -59,7 +59,7 @@ Choose the font family you want to be used on printing your XML documents. unnamed - + m_pLblFontSize @@ -75,7 +75,7 @@ Choose the font family you want to be used on printing your XML documents. - + m_pFontSize @@ -116,7 +116,7 @@ Choose the font size you want to be used on printing your XML documents. - + layout4 @@ -124,7 +124,7 @@ Choose the font size you want to be used on printing your XML documents. unnamed - + m_pLblIndentSteps @@ -140,7 +140,7 @@ Choose the font size you want to be used on printing your XML documents. - + m_pIndentSteps @@ -169,7 +169,7 @@ Choose the number of characters you want to be used for indenting childnodes on - + m_pWithHeader @@ -185,7 +185,7 @@ Choose the number of characters you want to be used for indenting childnodes on You can determine wether you want a header to be printed on every page when printing you XML documents or not. - + m_pWithFooter diff --git a/part/kxeprocinstrdialog.cpp b/part/kxeprocinstrdialog.cpp index 00529b8..1210beb 100644 --- a/part/kxeprocinstrdialog.cpp +++ b/part/kxeprocinstrdialog.cpp @@ -17,23 +17,23 @@ #include "kxeprocinstrdialog.h" -#include -#include -#include -#include +#include +#include +#include +#include #include #include #include #include -KXEProcInstrDialog::KXEProcInstrDialog( QWidget * pParent, const char * pszName, bool fModal, WFlags fl ) +KXEProcInstrDialog::KXEProcInstrDialog( TQWidget * pParent, const char * pszName, bool fModal, WFlags fl ) : KXEProcInstrDialogBase( pParent, pszName, fModal, fl ) { // signals and slots connections connect( m_pBtnOK, SIGNAL( clicked() ), this, SLOT( slotAccept() ) ); connect( m_pEditData, SIGNAL(textChanged()), this, SLOT(slotDataChanged()) ); - connect( m_pEditTarget, SIGNAL(textChanged(const QString &)), this, SLOT(slotTargetChanged(const QString &)) ); + connect( m_pEditTarget, SIGNAL(textChanged(const TQString &)), this, SLOT(slotTargetChanged(const TQString &)) ); } @@ -101,7 +101,7 @@ int KXEProcInstrDialog::exec() void KXEProcInstrDialog::slotDataChanged() { - QString strMessage = checkData(m_pEditData->text()); + TQString strMessage = checkData(m_pEditData->text()); if(strMessage.isEmpty()) strMessage = checkTarget(m_pEditTarget->text()); @@ -116,9 +116,9 @@ void KXEProcInstrDialog::slotDataChanged() m_pBtnOK->setEnabled(true); } -void KXEProcInstrDialog::slotTargetChanged(const QString &strNewTarget) +void KXEProcInstrDialog::slotTargetChanged(const TQString &strNewTarget) { - QString strMessage = checkTarget(strNewTarget); + TQString strMessage = checkTarget(strNewTarget); if(strMessage.isEmpty()) strMessage = checkData(m_pEditData->text()); @@ -145,16 +145,16 @@ void KXEProcInstrDialog::slotAccept() } // Check, if XML proc. instr. target is OK -QString KXEProcInstrDialog::checkTarget(const QString strTarget) +TQString KXEProcInstrDialog::checkTarget(const TQString strTarget) { if(strTarget.length() == 0) return ""; // Forbidden characters - QString strForbiddenChars("<>"); + TQString strForbiddenChars("<>"); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strTarget.find(ch) >= 0) return i18n("Target cannot contain character: %1 !").arg(ch); @@ -164,16 +164,16 @@ QString KXEProcInstrDialog::checkTarget(const QString strTarget) } // Check, if XML proc. instr. data is OK -QString KXEProcInstrDialog::checkData(const QString strData) +TQString KXEProcInstrDialog::checkData(const TQString strData) { if(strData.length() == 0) return ""; // Forbidden characters - QString strForbiddenChars("<>"); + TQString strForbiddenChars("<>"); for(unsigned int i = 0; i < strForbiddenChars.length(); i++) { - QChar ch = strForbiddenChars[i]; + TQChar ch = strForbiddenChars[i]; if(strData.find(ch) >= 0) return i18n("Contents cannot contain character: %1 !").arg(ch); diff --git a/part/kxeprocinstrdialog.h b/part/kxeprocinstrdialog.h index 5b4de2e..2fac93b 100644 --- a/part/kxeprocinstrdialog.h +++ b/part/kxeprocinstrdialog.h @@ -25,14 +25,14 @@ class KXEProcInstrDialog : public KXEProcInstrDialogBase Q_OBJECT public: - KXEProcInstrDialog( QWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); + KXEProcInstrDialog( TQWidget * pParent = 0, const char * pszName = 0, bool fModal = true, WFlags fl = 0 ); const bool atTop() const { return m_bAtTop; } - const QString target() const { return m_strTarget; } - const QString data() const { return m_strData; } + const TQString target() const { return m_strTarget; } + const TQString data() const { return m_strData; } - void setTarget(const QString strTarget) { m_strTarget = strTarget; } - void setData(const QString strData) { m_strData = strData; } + void setTarget(const TQString strTarget) { m_strTarget = strTarget; } + void setData(const TQString strData) { m_strData = strData; } public: @@ -40,7 +40,7 @@ class KXEProcInstrDialog : public KXEProcInstrDialogBase * To be used for inserting a proc.instruction as child * of the given parent node. * - * @return see @ref QDialog::exec + * @return see @ref TQDialog::exec */ int exec( bool, bool ); @@ -50,10 +50,10 @@ class KXEProcInstrDialog : public KXEProcInstrDialogBase void clearDialog(); // check target - static QString checkTarget(const QString); + static TQString checkTarget(const TQString); // check data - static QString checkData(const QString); + static TQString checkData(const TQString); protected: /** @@ -73,14 +73,14 @@ class KXEProcInstrDialog : public KXEProcInstrDialogBase * Called, when the target edit box is changed. * Disables the OK button, if the editbox is empty. */ - void slotTargetChanged(const QString &); + void slotTargetChanged(const TQString &); /** Called when user press OK button */ void slotAccept(); protected: - QString m_strTarget; - QString m_strData; + TQString m_strTarget; + TQString m_strData; bool m_bAtTop; }; diff --git a/part/kxeprocinstrdialogbase.ui b/part/kxeprocinstrdialogbase.ui index c77d10b..67c1392 100644 --- a/part/kxeprocinstrdialogbase.ui +++ b/part/kxeprocinstrdialogbase.ui @@ -1,6 +1,6 @@ KXEProcInstrDialogBase - + KXEProcInstrDialogBase @@ -28,7 +28,7 @@ 6 - + layout4 @@ -36,7 +36,7 @@ unnamed - + m_pLblTarget @@ -51,7 +51,7 @@ Define the target of this processing instruction here. - + m_pEditTarget @@ -77,7 +77,7 @@ Define the target of this processing instruction here. - + m_pLblInsert @@ -93,7 +93,7 @@ Define the target of this processing instruction here. Choose, where to place this processing instruction in the parent elements list. - + at bottom @@ -115,7 +115,7 @@ Choose, where to place this processing instruction in the parent elements list.< - + m_pEditData @@ -126,7 +126,7 @@ Choose, where to place this processing instruction in the parent elements list.< Here you can enter the data (the instructions) of this XML processing instruction. - + Layout1 @@ -157,7 +157,7 @@ Choose, where to place this processing instruction in the parent elements list.< - + m_pBtnOK @@ -174,7 +174,7 @@ Choose, where to place this processing instruction in the parent elements list.< true - + m_pBtnCancel @@ -190,7 +190,7 @@ Choose, where to place this processing instruction in the parent elements list.< - + m_pTextLabelMessage diff --git a/part/kxesearchdialog.cpp b/part/kxesearchdialog.cpp index 09e3a49..b6cb5cc 100644 --- a/part/kxesearchdialog.cpp +++ b/part/kxesearchdialog.cpp @@ -17,9 +17,9 @@ #include "kxesearchdialog.h" -#include +#include -KXESearchDialog::KXESearchDialog(QWidget *parent, const char *name, bool modal) +KXESearchDialog::KXESearchDialog(TQWidget *parent, const char *name, bool modal) : KXESearchDialogBase(parent, name, modal) { m_pPushButtonFind->setEnabled(false); @@ -27,7 +27,7 @@ KXESearchDialog::KXESearchDialog(QWidget *parent, const char *name, bool modal) m_pPushButtonFind->setDefault(true); } -void KXESearchDialog::slotTextChanged(const QString& string) +void KXESearchDialog::slotTextChanged(const TQString& string) { if ( string.isEmpty() ) m_pPushButtonFind->setEnabled(false); diff --git a/part/kxesearchdialog.h b/part/kxesearchdialog.h index abe7f3d..3ec8630 100644 --- a/part/kxesearchdialog.h +++ b/part/kxesearchdialog.h @@ -20,8 +20,8 @@ #include "kxesearchdialogbase.h" -#include -#include +#include +#include /** * Dialog for input information from user @@ -33,9 +33,9 @@ class KXESearchDialog : public KXESearchDialogBase Q_OBJECT public: - KXESearchDialog( QWidget * pParent, const char * pszName = 0, bool bModal = true ); + KXESearchDialog( TQWidget * pParent, const char * pszName = 0, bool bModal = true ); - QString getSearchString() const { return m_pEditSearchedString->text(); } + TQString getSearchString() const { return m_pEditSearchedString->text(); } bool getMatchCase() const { return m_pCheckBoxMatchCase->isChecked(); } bool getInElementNames() const { return m_pCheckBoxElementNames->isChecked(); } bool getInAttributeNames() const { return m_pCheckBoxAttributeNames->isChecked(); } @@ -48,7 +48,7 @@ class KXESearchDialog : public KXESearchDialogBase protected slots: /** Called when text in edit line is changed */ - virtual void slotTextChanged(const QString & ); + virtual void slotTextChanged(const TQString & ); /** Called on a change of the "find in" checkbuttons. */ virtual void slotFindInChanged(); diff --git a/part/kxesearchdialogbase.ui b/part/kxesearchdialogbase.ui index 23be699..1f017f1 100644 --- a/part/kxesearchdialogbase.ui +++ b/part/kxesearchdialogbase.ui @@ -3,7 +3,7 @@ Dialog for input information from user about searching in XML document Lumir Vanek - + KXESearchDialogBase @@ -40,7 +40,7 @@ about searching in XML document 6 - + Layout5 @@ -54,7 +54,7 @@ about searching in XML document 6 - + m_pTextLabelSearchedString @@ -94,7 +94,7 @@ Here you can enter the string you want to search for in your XML document. - + m_pEditSearchedString @@ -103,7 +103,7 @@ Here you can enter the string you want to search for in your XML document. - + layout13 @@ -128,7 +128,7 @@ Here you can enter the string you want to search for in your XML document. - + m_pPushButtonFind @@ -136,7 +136,7 @@ Here you can enter the string you want to search for in your XML document.&Find - + m_pPushButtonCancel @@ -163,7 +163,7 @@ Here you can enter the string you want to search for in your XML document. - + m_pGroupBoxSearchIn @@ -193,7 +193,7 @@ These are 6 - + m_pCheckBoxElementNames @@ -201,7 +201,7 @@ These are Element names - + m_pCheckBoxAttributeNames @@ -209,7 +209,7 @@ These are Attribute names - + m_pCheckBoxAttributeValues @@ -217,7 +217,7 @@ These are Attribute values - + m_pCheckBoxContents @@ -227,7 +227,7 @@ These are - + layout23 @@ -252,7 +252,7 @@ These are - + m_pCheckBoxMatchCase @@ -291,9 +291,9 @@ Check this for case sensitive search. m_pEditSearchedString - textChanged(const QString&) + textChanged(const TQString&) KXESearchDialogBase - slotTextChanged(const QString&) + slotTextChanged(const TQString&) m_pPushButtonCancel @@ -344,7 +344,7 @@ Check this for case sensitive search. slotFindInChanged() - slotTextChanged(const QString &) + slotTextChanged(const TQString &) diff --git a/part/kxesettings.cpp b/part/kxesettings.cpp index 8b5bb6e..59b71f0 100644 --- a/part/kxesettings.cpp +++ b/part/kxesettings.cpp @@ -19,8 +19,8 @@ #include -KXESettings::KXESettings( const QString & strConfigGroup, QObject * pParent, const char * pszName ) - : QObject( pParent, pszName ), +KXESettings::KXESettings( const TQString & strConfigGroup, TQObject * pParent, const char * pszName ) + : TQObject( pParent, pszName ), m_bPageChanged( false ), m_strConfigGroup( strConfigGroup ) { diff --git a/part/kxesettings.h b/part/kxesettings.h index 804c63e..b1a98ea 100644 --- a/part/kxesettings.h +++ b/part/kxesettings.h @@ -18,10 +18,10 @@ #ifndef KXESETTINGS_H #define KXESETTINGS_H -#include +#include class KConfig; -class QFrame; +class TQFrame; /** * This is an abstract base class for classes representing a group, that stores @@ -30,7 +30,7 @@ class QFrame; * * @author Olaf Hartig */ -class KXESettings : public QObject +class KXESettings : public TQObject { Q_OBJECT @@ -42,7 +42,7 @@ class KXESettings : public QObject * @param strConfigGroup the name of the corresponding group in the config file, * it is copied to the member @ref m_strConfigGroup */ - KXESettings( const QString & strConfigGroup, QObject * pParent = 0, const char * pszName = 0 ); + KXESettings( const TQString & strConfigGroup, TQObject * pParent = 0, const char * pszName = 0 ); /** * Stores this settings to the given @ref KConfig object, by doing the @@ -80,7 +80,7 @@ class KXESettings : public QObject * pages in the configuration dialog. * This name has to be internationalized. */ - virtual QString dialogPageName() const = 0; + virtual TQString dialogPageName() const = 0; /** * You can override this function and return a header line to * be used for the corresponding configuration dialog page. @@ -88,12 +88,12 @@ class KXESettings : public QObject * @ref dialogPageName) * This string has to be internationalized. */ - virtual QString dialogPageHeader() const { return QString::null; } + virtual TQString dialogPageHeader() const { return TQString::null; } /** * Override this function and return the (file-)name of the icon * to be used in the configuration dialog for the corresponding page. */ - virtual QString dialogPageIcon() const = 0; + virtual TQString dialogPageIcon() const = 0; /** * Override this function to create the corresponding configuration * dialog page with the given parent and return it. @@ -101,7 +101,7 @@ class KXESettings : public QObject * Connect the signal @ref sigDialogPageChanged to the page's * data changed signal(s). */ - virtual QWidget * dialogPage( QFrame * pParent ) = 0; + virtual TQWidget * dialogPage( TQFrame * pParent ) = 0; signals: @@ -168,7 +168,7 @@ class KXESettings : public QObject /** * name of the config group for this group of settings */ - const QString m_strConfigGroup; + const TQString m_strConfigGroup; }; diff --git a/part/kxespecprocinstrdialog.cpp b/part/kxespecprocinstrdialog.cpp index e2a81b5..299b9e7 100644 --- a/part/kxespecprocinstrdialog.cpp +++ b/part/kxespecprocinstrdialog.cpp @@ -21,17 +21,17 @@ #include "kxeconfiguration.h" #include "kxenewfilesettings.h" -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include #include -KXESpecProcInstrDialog::KXESpecProcInstrDialog(QWidget *parent, const char *name ) +KXESpecProcInstrDialog::KXESpecProcInstrDialog(TQWidget *parent, const char *name ) : KXESpecProcInstrDialogBase(parent,name) { m_pComboBoxEncoding->insertStringList( KXMLEditorFactory::configuration()->newfile()->encodings() ); @@ -49,10 +49,10 @@ KXESpecProcInstrDialog::~KXESpecProcInstrDialog() { } -void KXESpecProcInstrDialog::fillDialog( const QString strData ) +void KXESpecProcInstrDialog::fillDialog( const TQString strData ) { - QString strVersion; - QString strEncoding; + TQString strVersion; + TQString strEncoding; int iStart, iEnd; @@ -63,9 +63,9 @@ void KXESpecProcInstrDialog::fillDialog( const QString strData ) iStart += 7; // skip version // search " or ' after encoding - if((iStart = strData.find(QRegExp("[\"']"), iStart)) > 0) + if((iStart = strData.find(TQRegExp("[\"']"), iStart)) > 0) { - QChar ch = strData[iStart]; + TQChar ch = strData[iStart]; iStart++; // skip ch if((iEnd = strData.find(ch, iStart)) > 0) strVersion = strData.mid(iStart, iEnd - iStart); @@ -81,9 +81,9 @@ void KXESpecProcInstrDialog::fillDialog( const QString strData ) iStart += 8; // skip encoding // search " or ' after encoding - if((iStart = strData.find(QRegExp("[\"']"), iStart)) > 0) + if((iStart = strData.find(TQRegExp("[\"']"), iStart)) > 0) { - QChar ch = strData[iStart]; + TQChar ch = strData[iStart]; iStart++; // skip ch if((iEnd = strData.find(ch, iStart)) > 0) strEncoding = strData.mid(iStart, iEnd - iStart); @@ -117,7 +117,7 @@ void KXESpecProcInstrDialog::slotAccept() @param version XML file version @param encoding encoding type for the XML file */ -void KXESpecProcInstrDialog::fillDialog(const QString& version, const QString& encoding) +void KXESpecProcInstrDialog::fillDialog(const TQString& version, const TQString& encoding) { m_pLineEditVersion->setText(version); @@ -128,9 +128,9 @@ void KXESpecProcInstrDialog::fillDialog(const QString& version, const QString& e /*! Returns content of the dialog as an string of format: '"version = '...' encoding = '...' ". */ -QString KXESpecProcInstrDialog::getData() +TQString KXESpecProcInstrDialog::getData() { - return QString("version = '")+m_pLineEditVersion->text()+ + return TQString("version = '")+m_pLineEditVersion->text()+ "' encoding = '"+m_pComboBoxEncoding->currentText()+"' "; } diff --git a/part/kxespecprocinstrdialog.h b/part/kxespecprocinstrdialog.h index c78301f..128dd20 100644 --- a/part/kxespecprocinstrdialog.h +++ b/part/kxespecprocinstrdialog.h @@ -20,7 +20,7 @@ #include "kxespecprocinstrdialogbase.h" -#include +#include /** *@author Lumir Vanek @@ -31,16 +31,16 @@ class KXESpecProcInstrDialog : public KXESpecProcInstrDialogBase Q_OBJECT public: - KXESpecProcInstrDialog(QWidget *parent=0, const char *name=0); + KXESpecProcInstrDialog(TQWidget *parent=0, const char *name=0); ~KXESpecProcInstrDialog(); - QString getData(); + TQString getData(); /** Initialize dialog from given target and data string */ - void fillDialog(const QString&, const QString&); + void fillDialog(const TQString&, const TQString&); /** Initialize dialog from given data string */ - void fillDialog(const QString); + void fillDialog(const TQString); int exec(); diff --git a/part/kxespecprocinstrdialogbase.ui b/part/kxespecprocinstrdialogbase.ui index 1bcbb25..efbdcc7 100644 --- a/part/kxespecprocinstrdialogbase.ui +++ b/part/kxespecprocinstrdialogbase.ui @@ -1,7 +1,7 @@ KXESpecProcInstrDialogBase Lumir Vanek - + KXESpecProcInstrDialogBase @@ -34,7 +34,7 @@ 6 - + m_pTextLabel1 @@ -49,7 +49,7 @@ You can determine the XML version for XML document. - + m_pLineEditVersion @@ -58,7 +58,7 @@ You can determine the XML version for XML document. You can determine the XML version for XML document. - + m_pTextLabel2 @@ -73,7 +73,7 @@ You can determine the XML version for XML document. You can determine the encoding used while saving this XML document. - + m_pComboBoxEncoding @@ -85,7 +85,7 @@ You can determine the encoding used while saving this XML document. You can determine the encoding used while saving this XML document. - + layout4 @@ -93,7 +93,7 @@ You can determine the encoding used while saving this XML document. unnamed - + m_pDontShowAgain @@ -110,7 +110,7 @@ If you select this option, your choice will be remembered. Next time you create - + m_pHLine @@ -121,7 +121,7 @@ If you select this option, your choice will be remembered. Next time you create Raised - + layout2 @@ -146,7 +146,7 @@ If you select this option, your choice will be remembered. Next time you create - + m_pBtnOK @@ -157,7 +157,7 @@ If you select this option, your choice will be remembered. Next time you create true - + m_pBtnCancel diff --git a/part/kxesyntaxhighlighter.cpp b/part/kxesyntaxhighlighter.cpp index c783077..8397244 100644 --- a/part/kxesyntaxhighlighter.cpp +++ b/part/kxesyntaxhighlighter.cpp @@ -19,18 +19,18 @@ #include -#include -#include -#include -#include +#include +#include +#include +#include #include // Regular expressions for parsing XML borrowed from: // http://www.cs.sfu.ca/~cameron/REX.html -KXESyntaxHighlighter::KXESyntaxHighlighter(QTextEdit *textEdit) - : QSyntaxHighlighter(textEdit) +KXESyntaxHighlighter::KXESyntaxHighlighter(TQTextEdit *textEdit) + : TQSyntaxHighlighter(textEdit) { m_clrDefaultText.setRgb(0, 0, 0); m_clrElementName.setRgb(128, 0, 0); @@ -46,10 +46,10 @@ KXESyntaxHighlighter::~KXESyntaxHighlighter() } -int KXESyntaxHighlighter::highlightParagraph(const QString& text, int endStateOfLastPara) +int KXESyntaxHighlighter::highlightParagraph(const TQString& text, int endStateOfLastPara) { - //first I format the given line to default so any remaining highlighting is removed (Qt does not do it by itself) - setFormat(0 , text.length(), QColor(0, 0, 0)); + //first I format the given line to default so any remaining highlighting is removed (TQt does not do it by itself) + setFormat(0 , text.length(), TQColor(0, 0, 0)); int iBracketNesting = 0; m_eParserState = parsingNone; @@ -58,7 +58,7 @@ int KXESyntaxHighlighter::highlightParagraph(const QString& text, int endStateOf if(endStateOfLastPara == 1) { - QRegExp patternComment("[^-]*-([^-][^-]*-)*->"); // search end of comment + TQRegExp patternComment("[^-]*-([^-][^-]*-)*->"); // search end of comment pos=patternComment.search(text, i); if(pos >= 0) // end comment found ? @@ -137,7 +137,7 @@ int KXESyntaxHighlighter::highlightParagraph(const QString& text, int endStateOf if(m_eParserState == expectAttributeValue) { - QRegExp patternAttribute("\"[^<\"]*\"|'[^<']*'"); // search attribute value + TQRegExp patternAttribute("\"[^<\"]*\"|'[^<']*'"); // search attribute value pos=patternAttribute.search(text, i); if(pos == (int) i) // attribute value found ? @@ -162,7 +162,7 @@ int KXESyntaxHighlighter::highlightParagraph(const QString& text, int endStateOf case '!': if(m_eParserState == expectElementNameOrSlash) { - QRegExp patternComment("