diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-19 01:42:14 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-19 01:42:14 +0000 |
commit | 8155225c9be993acc0512956416d195edfef4eb9 (patch) | |
tree | de4f3cd17614fc67e47eefabcdbe2fbe170c9be7 /khelpcenter | |
parent | 364641b8e0279758d236af39abd138d379328a19 (diff) | |
download | tdebase-8155225c9be993acc0512956416d195edfef4eb9.tar.gz tdebase-8155225c9be993acc0512956416d195edfef4eb9.zip |
Enable compilation with TQt for Qt4 3.4.0 TP2
This should not break compatibility with TQt for Qt3; if it does please fix it ASAP!
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1215552 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'khelpcenter')
28 files changed, 143 insertions, 143 deletions
diff --git a/khelpcenter/docentry.cpp b/khelpcenter/docentry.cpp index 716c4d99e..96747696b 100644 --- a/khelpcenter/docentry.cpp +++ b/khelpcenter/docentry.cpp @@ -219,7 +219,7 @@ bool DocEntry::readFromFile( const TQString &fileName ) mIdentifier = fi.baseName( true ); } mIndexer = file.readEntry( "X-DOC-Indexer" ); - mIndexer.replace( "%f", fileName ); + mIndexer.tqreplace( "%f", fileName ); mIndexTestFile = file.readEntry( "X-DOC-IndexTestFile" ); mSearchEnabledDefault = file.readBoolEntry( "X-DOC-SearchEnabledDefault", false ); diff --git a/khelpcenter/docmetainfo.cpp b/khelpcenter/docmetainfo.cpp index 4d6dd6fad..cfdfa9f7e 100644 --- a/khelpcenter/docmetainfo.cpp +++ b/khelpcenter/docmetainfo.cpp @@ -60,7 +60,7 @@ DocEntry *DocMetaInfo::addDocEntry( const TQString &fileName ) lang = extensions[ extensions.count() - 2 ]; } - if ( !lang.isEmpty() && mLanguages.find( lang ) == mLanguages.end() ) { + if ( !lang.isEmpty() && mLanguages.tqfind( lang ) == mLanguages.end() ) { return 0; } @@ -77,7 +77,7 @@ DocEntry *DocMetaInfo::addDocEntry( const TQString &fileName ) mHtmlSearch->setupDocEntry( entry ); } TQString indexer = entry->indexer(); - indexer.replace( "%f", fileName ); + indexer.tqreplace( "%f", fileName ); entry->setIndexer( indexer ); addDocEntry( entry ); return entry; @@ -108,7 +108,7 @@ TQString DocMetaInfo::languageName( const TQString &langcode ) if ( langcode == "en" ) return i18n("English"); TQString cfgfile = locate( "locale", - TQString::fromLatin1( "%1/entry.desktop" ).arg( langcode ) ); + TQString::tqfromLatin1( "%1/entry.desktop" ).arg( langcode ) ); kdDebug() << "-- langcode: " << langcode << " cfgfile: " << cfgfile << endl; @@ -155,8 +155,8 @@ DocEntry *DocMetaInfo::scanMetaInfoDir( const TQString &dirName, TQDir dir( dirName ); if ( !dir.exists() ) return 0; - const QFileInfoList *entryList = dir.entryInfoList(); - QFileInfoListIterator it( *entryList ); + const TQFileInfoList *entryList = dir.entryInfoList(); + TQFileInfoListIterator it( *entryList ); TQFileInfo *fi; for( ; ( fi = it.current() ); ++it ) { DocEntry *entry = 0; diff --git a/khelpcenter/formatter.cpp b/khelpcenter/formatter.cpp index b9f394289..859d003c3 100644 --- a/khelpcenter/formatter.cpp +++ b/khelpcenter/formatter.cpp @@ -73,7 +73,7 @@ bool Formatter::readTemplates() switch ( state ) { case IDLE: if ( !line.isEmpty() && !line.startsWith( "#" ) ) { - int pos = line.find( "<<" ); + int pos = line.tqfind( "<<" ); if ( pos >= 0 ) { state = MULTILINE; symbol = line.left( pos ).stripWhiteSpace(); @@ -120,7 +120,7 @@ bool Formatter::readTemplates() bool success = true; TQStringList::ConstIterator it2; for( it2 = requiredSymbols.begin(); it2 != requiredSymbols.end(); ++it2 ) { - if ( !mSymbols.contains( *it2 ) ) { + if ( !mSymbols.tqcontains( *it2 ) ) { success = false; kdError() << "Symbol '" << *it2 << "' is missing from main template file." << endl; @@ -137,7 +137,7 @@ TQString Formatter::header( const TQString &title ) TQString s; if ( mHasTemplate ) { s = mSymbols[ "HEADER" ]; - s.replace( "--TITLE:--", title ); + s.tqreplace( "--TITLE:--", title ); } else { s = "<html><head><title>" + title + "</title></head>\n<body>\n"; } diff --git a/khelpcenter/glossary.cpp b/khelpcenter/glossary.cpp index dc596372e..6538a77eb 100644 --- a/khelpcenter/glossary.cpp +++ b/khelpcenter/glossary.cpp @@ -49,7 +49,7 @@ class SectionItem : public KListViewItem { KListViewItem::setOpen(open); - setPixmap( 0, SmallIcon( TQString::fromLatin1( open ? "contents" : "contents2" ) ) ); + setPixmap( 0, SmallIcon( TQString::tqfromLatin1( open ? "contents" : "contents2" ) ) ); } }; @@ -92,7 +92,7 @@ Glossary::Glossary( TQWidget *parent ) : KListView( parent ) m_cacheFile = locateLocal( "cache", "help/glossary.xml" ); - m_sourceFile = View::View::langLookup( TQString::fromLatin1( "khelpcenter/glossary/index.docbook" ) ); + m_sourceFile = View::View::langLookup( TQString::tqfromLatin1( "khelpcenter/glossary/index.docbook" ) ); m_config = kapp->config(); m_config->setGroup( "Glossary" ); @@ -150,10 +150,10 @@ void Glossary::rebuildGlossaryCache() connect( meinproc, TQT_SIGNAL( processExited( KProcess * ) ), this, TQT_SLOT( meinprocExited( KProcess * ) ) ); - *meinproc << locate( "exe", TQString::fromLatin1( "meinproc" ) ); - *meinproc << TQString::fromLatin1( "--output" ) << m_cacheFile; - *meinproc << TQString::fromLatin1( "--stylesheet" ) - << locate( "data", TQString::fromLatin1( "khelpcenter/glossary.xslt" ) ); + *meinproc << locate( "exe", TQString::tqfromLatin1( "meinproc" ) ); + *meinproc << TQString::tqfromLatin1( "--output" ) << m_cacheFile; + *meinproc << TQString::tqfromLatin1( "--stylesheet" ) + << locate( "data", TQString::tqfromLatin1( "khelpcenter/glossary.xslt" ) ); *meinproc << m_sourceFile; meinproc->start( KProcess::NotifyOnExit ); @@ -189,21 +189,21 @@ void Glossary::buildGlossaryTree() if ( !doc.setContent( &cacheFile ) ) return; - TQDomNodeList sectionNodes = doc.documentElement().elementsByTagName( TQString::fromLatin1( "section" ) ); + TQDomNodeList sectionNodes = doc.documentElement().elementsByTagName( TQString::tqfromLatin1( "section" ) ); for ( unsigned int i = 0; i < sectionNodes.count(); i++ ) { TQDomElement sectionElement = sectionNodes.item( i ).toElement(); - TQString title = sectionElement.attribute( TQString::fromLatin1( "title" ) ); + TQString title = sectionElement.attribute( TQString::tqfromLatin1( "title" ) ); SectionItem *topicSection = new SectionItem( m_byTopicItem, title ); - TQDomNodeList entryNodes = sectionElement.elementsByTagName( TQString::fromLatin1( "entry" ) ); + TQDomNodeList entryNodes = sectionElement.elementsByTagName( TQString::tqfromLatin1( "entry" ) ); for ( unsigned int j = 0; j < entryNodes.count(); j++ ) { TQDomElement entryElement = entryNodes.item( j ).toElement(); - TQString entryId = entryElement.attribute( TQString::fromLatin1( "id" ) ); + TQString entryId = entryElement.attribute( TQString::tqfromLatin1( "id" ) ); if ( entryId.isNull() ) continue; - TQDomElement termElement = childElement( entryElement, TQString::fromLatin1( "term" ) ); + TQDomElement termElement = childElement( entryElement, TQString::tqfromLatin1( "term" ) ); TQString term = termElement.text().simplifyWhiteSpace(); EntryItem *entry = new EntryItem(topicSection, term, entryId ); @@ -221,19 +221,19 @@ void Glossary::buildGlossaryTree() new EntryItem( alphabSection, term, entryId ); - TQDomElement definitionElement = childElement( entryElement, TQString::fromLatin1( "definition" ) ); + TQDomElement definitionElement = childElement( entryElement, TQString::tqfromLatin1( "definition" ) ); TQString definition = definitionElement.text().simplifyWhiteSpace(); GlossaryEntryXRef::List seeAlso; - TQDomElement referencesElement = childElement( entryElement, TQString::fromLatin1( "references" ) ); - TQDomNodeList referenceNodes = referencesElement.elementsByTagName( TQString::fromLatin1( "reference" ) ); + TQDomElement referencesElement = childElement( entryElement, TQString::tqfromLatin1( "references" ) ); + TQDomNodeList referenceNodes = referencesElement.elementsByTagName( TQString::tqfromLatin1( "reference" ) ); if ( referenceNodes.count() > 0 ) for ( unsigned int k = 0; k < referenceNodes.count(); k++ ) { TQDomElement referenceElement = referenceNodes.item( k ).toElement(); - TQString term = referenceElement.attribute( TQString::fromLatin1( "term" ) ); - TQString id = referenceElement.attribute( TQString::fromLatin1( "id" ) ); + TQString term = referenceElement.attribute( TQString::tqfromLatin1( "term" ) ); + TQString id = referenceElement.attribute( TQString::tqfromLatin1( "id" ) ); seeAlso += GlossaryEntryXRef( term, id ); } @@ -279,10 +279,10 @@ TQString Glossary::entryToHtml( const GlossaryEntry &entry ) GlossaryEntryXRef::List::ConstIterator it = seeAlsos.begin(); GlossaryEntryXRef::List::ConstIterator end = seeAlsos.end(); for (; it != end; ++it) { - seeAlso += TQString::fromLatin1("<a href=\"glossentry:"); + seeAlso += TQString::tqfromLatin1("<a href=\"glossentry:"); seeAlso += (*it).id(); - seeAlso += TQString::fromLatin1("\">") + (*it).term(); - seeAlso += TQString::fromLatin1("</a>, "); + seeAlso += TQString::tqfromLatin1("\">") + (*it).term(); + seeAlso += TQString::tqfromLatin1("</a>, "); } seeAlso = seeAlso.left(seeAlso.length() - 2); } @@ -303,7 +303,7 @@ TQString Glossary::entryToHtml( const GlossaryEntry &entry ) void Glossary::slotSelectGlossEntry( const TQString &id ) { - EntryItem *newItem = m_idDict.find( id ); + EntryItem *newItem = m_idDict.tqfind( id ); if ( newItem == 0 ) return; @@ -311,7 +311,7 @@ void Glossary::slotSelectGlossEntry( const TQString &id ) if ( curItem != 0 ) { if ( curItem->id() == id ) return; - curItem->parent()->setOpen( false ); + curItem->tqparent()->setOpen( false ); } setCurrentItem( newItem ); diff --git a/khelpcenter/history.cpp b/khelpcenter/history.cpp index 9a90831f7..ef9cbe7c0 100644 --- a/khelpcenter/history.cpp +++ b/khelpcenter/history.cpp @@ -53,7 +53,7 @@ History::~History() void History::setupActions( KActionCollection *coll ) { - QPair<KGuiItem, KGuiItem> backForward = KStdGuiItem::backAndForward(); + TQPair<KGuiItem, KGuiItem> backForward = KStdGuiItem::backAndForward(); m_backAction = new KToolBarPopupAction( backForward.first, ALT+Key_Left, this, TQT_SLOT( back() ), coll, "back" ); @@ -257,7 +257,7 @@ void History::fillForwardMenu() void History::fillGoMenu() { KMainWindow *mainWindow = static_cast<KMainWindow *>( kapp->mainWidget() ); - TQPopupMenu *goMenu = dynamic_cast<TQPopupMenu *>( mainWindow->guiFactory()->container( TQString::fromLatin1( "go" ), mainWindow ) ); + TQPopupMenu *goMenu = dynamic_cast<TQPopupMenu *>( mainWindow->guiFactory()->container( TQString::tqfromLatin1( "go" ), mainWindow ) ); if ( !goMenu || m_goMenuIndex == -1 ) return; @@ -290,7 +290,7 @@ void History::fillGoMenu() void History::goMenuActivated( int id ) { KMainWindow *mainWindow = static_cast<KMainWindow *>( kapp->mainWidget() ); - TQPopupMenu *goMenu = dynamic_cast<TQPopupMenu *>( mainWindow->guiFactory()->container( TQString::fromLatin1( "go" ), mainWindow ) ); + TQPopupMenu *goMenu = dynamic_cast<TQPopupMenu *>( mainWindow->guiFactory()->container( TQString::tqfromLatin1( "go" ), mainWindow ) ); if ( !goMenu ) return; @@ -324,7 +324,7 @@ void History::fillHistoryPopup( TQPopupMenu *popup, bool onlyBack, bool onlyForw { TQString text = it.current()->title; text = KStringHandler::csqueeze(text, 50); //CT: squeeze - text.replace( "&", "&&" ); + text.tqreplace( "&", "&&" ); if ( checkCurrentItem && it.current() == current ) { int id = popup->insertItem( text ); // no pixmap if checked diff --git a/khelpcenter/history.h b/khelpcenter/history.h index a5a7327a4..ba30f312b 100644 --- a/khelpcenter/history.h +++ b/khelpcenter/history.h @@ -34,7 +34,7 @@ namespace KHC { class View; -class History : public QObject +class History : public TQObject { Q_OBJECT public: diff --git a/khelpcenter/htmlsearch/htmlsearch.cpp b/khelpcenter/htmlsearch/htmlsearch.cpp index c47300190..c9feaa61f 100644 --- a/khelpcenter/htmlsearch/htmlsearch.cpp +++ b/khelpcenter/htmlsearch/htmlsearch.cpp @@ -43,7 +43,7 @@ void HTMLSearch::scanDir(const TQString& dir) for (it=list.begin(); it != list.end(); ++it) { file = adir + *it; - if ( !_files.contains( file ) ) { + if ( !_files.tqcontains( file ) ) { _files.append(file); progress->setFilesScanned(++_filesScanned); } @@ -375,13 +375,13 @@ void HTMLSearch::htdigStdout(KProcess *, char *buffer, int len) TQString line = TQString(buffer).left(len); int cnt=0, index=-1; - while ( (index = line.find("file://", index+1)) > 0) + while ( (index = line.tqfind("file://", index+1)) > 0) cnt++; _filesDigged += cnt; cnt=0; index=-1; - while ( (index = line.find("not changed", index+1)) > 0) + while ( (index = line.tqfind("not changed", index+1)) > 0) cnt++; _filesDigged -= cnt; @@ -467,8 +467,8 @@ TQString HTMLSearch::search(TQString _lang, TQString words, TQString method, int delete _proc; // modify the search result - _searchResult = _searchResult.replace("http://localhost/", "file:/"); - _searchResult = _searchResult.replace("Content-type: text/html", TQString::null); + _searchResult = _searchResult.tqreplace("http://localhost/", "file:/"); + _searchResult = _searchResult.tqreplace("Content-type: text/html", TQString::null); // dump the search result TQFile f(result); diff --git a/khelpcenter/htmlsearch/kcmhtmlsearch.cpp b/khelpcenter/htmlsearch/kcmhtmlsearch.cpp index 9dfc5e350..c2b1cd883 100644 --- a/khelpcenter/htmlsearch/kcmhtmlsearch.cpp +++ b/khelpcenter/htmlsearch/kcmhtmlsearch.cpp @@ -50,15 +50,15 @@ KHTMLSearchConfig::KHTMLSearchConfig(TQWidget *parent, const char *name) TQLabel *l = new TQLabel(i18n("The fulltext search feature makes use of the " "ht://dig HTML search engine. " "You can get ht://dig at the"), gb); - l->setAlignment(TQLabel::WordBreak); - l->setMinimumSize(l->sizeHint()); + l->tqsetAlignment(TQLabel::WordBreak); + l->setMinimumSize(l->tqsizeHint()); grid->addMultiCellWidget(l, 1, 1, 0, 1); TQWhatsThis::add( gb, i18n( "Information about where to get the ht://dig package." ) ); KURLLabel *url = new KURLLabel(gb); url->setURL("http://www.htdig.org"); url->setText(i18n("ht://dig home page")); - url->setAlignment(TQLabel::AlignHCenter); + url->tqsetAlignment(TQLabel::AlignHCenter); grid->addMultiCellWidget(url, 2,2, 0, 1); connect(url, TQT_SIGNAL(leftClickedURL(const TQString&)), this, TQT_SLOT(urlClicked(const TQString&))); @@ -157,7 +157,7 @@ KHTMLSearchConfig::KHTMLSearchConfig(TQWidget *parent, const char *name) runButton = new TQPushButton(i18n("Generate Index..."), this); TQWhatsThis::add( runButton, i18n( "Click this button to generate the index for the fulltext search." ) ); - runButton->setFixedSize(runButton->sizeHint()); + runButton->setFixedSize(runButton->tqsizeHint()); vbox->addWidget(runButton, AlignRight); connect(runButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(generateIndex())); @@ -179,19 +179,19 @@ void KHTMLSearchConfig::loadLanguages() // add all languages to the list TQStringList langs = KGlobal::dirs()->findAllResources("locale", - TQString::fromLatin1("*/entry.desktop")); + TQString::tqfromLatin1("*/entry.desktop")); langs.sort(); for (TQStringList::ConstIterator it = langs.begin(); it != langs.end(); ++it) { KSimpleConfig entry(*it); - entry.setGroup(TQString::fromLatin1("KCM Locale")); - TQString name = entry.readEntry(TQString::fromLatin1("Name"), KGlobal::locale()->translate("without name")); + entry.setGroup(TQString::tqfromLatin1("KCM Locale")); + TQString name = entry.readEntry(TQString::tqfromLatin1("Name"), KGlobal::locale()->translate("without name")); TQString path = *it; - int index = path.findRev('/'); + int index = path.tqfindRev('/'); path = path.left(index); - index = path.findRev('/'); + index = path.tqfindRev('/'); path = path.mid(index+1); language->insertLanguage(path, name); } diff --git a/khelpcenter/htmlsearch/klangcombo.cpp b/khelpcenter/htmlsearch/klangcombo.cpp index 308109d12..6f4b01c42 100644 --- a/khelpcenter/htmlsearch/klangcombo.cpp +++ b/khelpcenter/htmlsearch/klangcombo.cpp @@ -39,14 +39,14 @@ KLanguageCombo::KLanguageCombo (TQWidget * parent, const char *name) void KLanguageCombo::insertLanguage(const TQString& path, const TQString& name, const TQString& sub, const TQString &submenu, int index) { - TQString output = name + TQString::fromLatin1(" (") + path + TQString::fromLatin1(")"); - TQPixmap flag(locate("locale", sub + path + TQString::fromLatin1("/flag.png"))); + TQString output = name + TQString::tqfromLatin1(" (") + path + TQString::tqfromLatin1(")"); + TQPixmap flag(locate("locale", sub + path + TQString::tqfromLatin1("/flag.png"))); insertItem(TQIconSet(flag), output, path, submenu, index); } void KLanguageCombo::changeLanguage(const TQString& name, int i) { if (i < 0 || i >= count()) return; - TQString output = name + TQString::fromLatin1(" (") + tag(i) + TQString::fromLatin1(")"); + TQString output = name + TQString::tqfromLatin1(" (") + tag(i) + TQString::tqfromLatin1(")"); changeItem(output, i); } diff --git a/khelpcenter/htmlsearch/ktagcombobox.cpp b/khelpcenter/htmlsearch/ktagcombobox.cpp index 6bb74c860..3cb642b5f 100644 --- a/khelpcenter/htmlsearch/ktagcombobox.cpp +++ b/khelpcenter/htmlsearch/ktagcombobox.cpp @@ -83,7 +83,7 @@ void KTagComboBox::internalActivate( int index ) if (current == index) return; current = index; emit activated( index ); - repaint(); + tqrepaint(); } void KTagComboBox::internalHighlight( int index ) @@ -133,7 +133,7 @@ static inline void checkInsertPos(TQPopupMenu *popup, const TQString & str, int static inline TQPopupMenu *checkInsertIndex(TQPopupMenu *popup, const TQStringList *tags, const TQString &submenu) { - int pos = tags->findIndex(submenu); + int pos = tags->tqfindIndex(submenu); TQPopupMenu *pi = 0; if (pos != -1) @@ -192,7 +192,7 @@ void KTagComboBox::paintEvent( TQPaintEvent * ev) TQRect clip(2, 2, width() - 4, height() - 4); #if 0 if ( hasFocus() && style().guiStyle() != MotifStyle ) - p.setPen( colorGroup().highlightedText() ); + p.setPen( tqcolorGroup().highlightedText() ); #endif p.drawText(clip, AlignCenter | SingleLine, popup->text( current )); @@ -206,7 +206,7 @@ void KTagComboBox::paintEvent( TQPaintEvent * ev) bool KTagComboBox::containsTag( const TQString &str ) const { - return tags->contains(str) > 0; + return tags-.tqcontains(str) > 0; } TQString KTagComboBox::currentTag() const @@ -233,12 +233,12 @@ void KTagComboBox::setCurrentItem(int i) { if (i < 0 || i >= count()) return; current = i; - repaint(); + tqrepaint(); } void KTagComboBox::setCurrentItem(const TQString &code) { - int i = tags->findIndex(code); + int i = tags->tqfindIndex(code); if (code.isNull()) i = 0; if (i != -1) diff --git a/khelpcenter/htmlsearchconfig.cpp b/khelpcenter/htmlsearchconfig.cpp index ea6dff669..8581b25c8 100644 --- a/khelpcenter/htmlsearchconfig.cpp +++ b/khelpcenter/htmlsearchconfig.cpp @@ -51,15 +51,15 @@ HtmlSearchConfig::HtmlSearchConfig(TQWidget *parent, const char *name) TQLabel *l = new TQLabel(i18n("The fulltext search feature makes use of the " "ht://dig HTML search engine. " "You can get ht://dig at the"), gb); - l->setAlignment(TQLabel::WordBreak); - l->setMinimumSize(l->sizeHint()); + l->tqsetAlignment(TQLabel::WordBreak); + l->setMinimumSize(l->tqsizeHint()); grid->addMultiCellWidget(l, 1, 1, 0, 1); TQWhatsThis::add( gb, i18n( "Information about where to get the ht://dig package." ) ); KURLLabel *url = new KURLLabel(gb); url->setURL("http://www.htdig.org"); url->setText(i18n("ht://dig home page")); - url->setAlignment(TQLabel::AlignHCenter); + url->tqsetAlignment(TQLabel::AlignHCenter); grid->addMultiCellWidget(url, 2,2, 0, 1); connect(url, TQT_SIGNAL(leftClickedURL(const TQString&)), this, TQT_SLOT(urlClicked(const TQString&))); diff --git a/khelpcenter/htmlsearchconfig.h b/khelpcenter/htmlsearchconfig.h index ef74cce5d..f1e093f13 100644 --- a/khelpcenter/htmlsearchconfig.h +++ b/khelpcenter/htmlsearchconfig.h @@ -1,7 +1,7 @@ /** * This file is part of KHelpCenter * - * Copyright (c) 2000 Matthias H�lzer-Kl�pfel <[email protected]> + * Copyright (c) 2000 Matthias H�lzer-Kl�pfel <[email protected]> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -28,7 +28,7 @@ class KConfig; namespace KHC { -class HtmlSearchConfig : public QWidget +class HtmlSearchConfig : public TQWidget { Q_OBJECT public: diff --git a/khelpcenter/infotree.cpp b/khelpcenter/infotree.cpp index a23cce174..6097a0b33 100644 --- a/khelpcenter/infotree.cpp +++ b/khelpcenter/infotree.cpp @@ -146,10 +146,10 @@ void InfoTree::parseInfoDirFile( const TQString &infoDirFileName ) while ( !stream.eof() && !s.stripWhiteSpace().isEmpty() ) { s = stream.readLine(); if ( s[ 0 ] == '*' ) { - const int colon = s.find( ":" ); - const int openBrace = s.find( "(", colon ); - const int closeBrace = s.find( ")", openBrace ); - const int dot = s.find( ".", closeBrace ); + const int colon = s.tqfind( ":" ); + const int openBrace = s.tqfind( "(", colon ); + const int closeBrace = s.tqfind( ")", openBrace ); + const int dot = s.tqfind( ".", closeBrace ); TQString appName = s.mid( 2, colon - 2 ); TQString url = "info:/" + s.mid( openBrace + 1, closeBrace - openBrace - 1 ); diff --git a/khelpcenter/kcmhelpcenter.cpp b/khelpcenter/kcmhelpcenter.cpp index aadce700a..c88e7218a 100644 --- a/khelpcenter/kcmhelpcenter.cpp +++ b/khelpcenter/kcmhelpcenter.cpp @@ -101,7 +101,7 @@ IndexProgressDialog::IndexProgressDialog( TQWidget *parent ) topLayout->setSpacing( spacingHint() ); mLabel = new TQLabel( this ); - mLabel->setAlignment( AlignHCenter ); + mLabel->tqsetAlignment( AlignHCenter ); topLayout->addWidget( mLabel ); mProgressBar = new TQProgressBar( this ); @@ -417,9 +417,9 @@ bool KCMHelpCenter::buildIndex() .arg( entry->documentType() ) ); hasError = true; } else { - indexer.replace( TQRegExp( "%i" ), entry->identifier() ); - indexer.replace( TQRegExp( "%d" ), Prefs::indexDirectory() ); - indexer.replace( TQRegExp( "%p" ), entry->url() ); + indexer.tqreplace( TQRegExp( "%i" ), entry->identifier() ); + indexer.tqreplace( TQRegExp( "%d" ), Prefs::indexDirectory() ); + indexer.tqreplace( TQRegExp( "%p" ), entry->url() ); kdDebug() << "INDEXER: " << indexer << endl; *ts << indexer << endl; @@ -611,7 +611,7 @@ void KCMHelpCenter::advanceProgress() void KCMHelpCenter::slotReceivedStdout( KProcess *, char *buffer, int buflen ) { TQString text = TQString::fromLocal8Bit( buffer, buflen ); - int pos = text.findRev( '\n' ); + int pos = text.tqfindRev( '\n' ); if ( pos < 0 ) { mStdOut.append( text ); } else { @@ -625,7 +625,7 @@ void KCMHelpCenter::slotReceivedStdout( KProcess *, char *buffer, int buflen ) void KCMHelpCenter::slotReceivedStderr( KProcess *, char *buffer, int buflen ) { TQString text = TQString::fromLocal8Bit( buffer, buflen ); - int pos = text.findRev( '\n' ); + int pos = text.tqfindRev( '\n' ); if ( pos < 0 ) { mStdErr.append( text ); } else { diff --git a/khelpcenter/mainwindow.cpp b/khelpcenter/mainwindow.cpp index 633bf0085..e70065bfc 100644 --- a/khelpcenter/mainwindow.cpp +++ b/khelpcenter/mainwindow.cpp @@ -90,7 +90,7 @@ MainWindow::MainWindow() { mSplitter = new TQSplitter( this ); - mDoc = new View( mSplitter, 0, this, 0, KHTMLPart::DefaultGUI, actionCollection() ); + mDoc = new View( mSplitter, 0, TQT_TQOBJECT(this), 0, KHTMLPart::DefaultGUI, actionCollection() ); connect( mDoc, TQT_SIGNAL( setWindowCaption( const TQString & ) ), TQT_SLOT( setCaption( const TQString & ) ) ); connect( mDoc, TQT_SIGNAL( setStatusBarText( const TQString & ) ), @@ -208,8 +208,8 @@ void MainWindow::writeConfig() void MainWindow::setupActions() { - KStdAction::quit( this, TQT_SLOT( close() ), actionCollection() ); - KStdAction::print( this, TQT_SLOT( print() ), actionCollection(), + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( close() ), actionCollection() ); + KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT( print() ), actionCollection(), "printFrame" ); KAction *prevPage = new KAction( i18n( "Previous Page" ), CTRL+Key_PageUp, mDoc, TQT_SLOT( prevPage() ), @@ -220,19 +220,19 @@ void MainWindow::setupActions() actionCollection(), "nextPage" ); nextPage->setWhatsThis( i18n( "Moves to the next page of the document" ) ); - KAction *home = KStdAction::home( this, TQT_SLOT( slotShowHome() ), actionCollection() ); + KAction *home = KStdAction::home( TQT_TQOBJECT(this), TQT_SLOT( slotShowHome() ), actionCollection() ); home->setText(i18n("Table of &Contents")); home->setToolTip(i18n("Table of contents")); home->setWhatsThis(i18n("Go back to the table of contents")); - mCopyText = KStdAction::copy( this, TQT_SLOT(slotCopySelectedText()), actionCollection(), "copy_text"); + mCopyText = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(slotCopySelectedText()), actionCollection(), "copy_text"); - mLastSearchAction = new KAction( i18n("&Last Search Result"), 0, this, + mLastSearchAction = new KAction( i18n("&Last Search Result"), 0, TQT_TQOBJECT(this), TQT_SLOT( slotLastSearch() ), actionCollection(), "lastsearch" ); mLastSearchAction->setEnabled( false ); - new KAction( i18n("Build Search Index..."), 0, mNavigator, + new KAction( i18n("Build Search Index..."), 0, TQT_TQOBJECT(mNavigator), TQT_SLOT( showIndexDialog() ), actionCollection(), "build_index" ); KStdAction::keyBindings( guiFactory(), TQT_SLOT( configureShortcuts() ), actionCollection() ); @@ -240,16 +240,16 @@ void MainWindow::setupActions() KConfig *cfg = KGlobal::config(); cfg->setGroup( "Debug" ); if ( cfg->readBoolEntry( "SearchErrorLog", false ) ) { - new KAction( i18n("Show Search Error Log"), 0, this, + new KAction( i18n("Show Search Error Log"), 0, TQT_TQOBJECT(this), TQT_SLOT( showSearchStderr() ), actionCollection(), "show_search_stderr" ); } History::self().setupActions( actionCollection() ); - new KAction( i18n( "Configure Fonts..." ), KShortcut(), this, TQT_SLOT( slotConfigureFonts() ), actionCollection(), "configure_fonts" ); - new KAction( i18n( "Increase Font Sizes" ), "viewmag+", KShortcut(), this, TQT_SLOT( slotIncFontSizes() ), actionCollection(), "incFontSizes" ); - new KAction( i18n( "Decrease Font Sizes" ), "viewmag-", KShortcut(), this, TQT_SLOT( slotDecFontSizes() ), actionCollection(), "decFontSizes" ); + new KAction( i18n( "Configure Fonts..." ), KShortcut(), TQT_TQOBJECT(this), TQT_SLOT( slotConfigureFonts() ), actionCollection(), "configure_fonts" ); + new KAction( i18n( "Increase Font Sizes" ), "viewmag+", KShortcut(), TQT_TQOBJECT(this), TQT_SLOT( slotIncFontSizes() ), actionCollection(), "incFontSizes" ); + new KAction( i18n( "Decrease Font Sizes" ), "viewmag-", KShortcut(), TQT_TQOBJECT(this), TQT_SLOT( slotDecFontSizes() ), actionCollection(), "decFontSizes" ); } void MainWindow::slotCopySelectedText() @@ -325,7 +325,7 @@ void MainWindow::viewUrl( const KURL &url, const KParts::URLArgs &args ) mDoc->browserExtension()->setURLArgs( args ); - if ( proto == TQString::fromLatin1("glossentry") ) { + if ( proto == TQString::tqfromLatin1("glossentry") ) { TQString decodedEntryId = KURL::decode_string( url.encodedPathAndQuery() ); slotGlossSelected( mNavigator->glossEntry( decodedEntryId ) ); mNavigator->slotSelectGlossEntry( decodedEntryId ); diff --git a/khelpcenter/navigator.cpp b/khelpcenter/navigator.cpp index ad308cfc6..35ebf0218 100644 --- a/khelpcenter/navigator.cpp +++ b/khelpcenter/navigator.cpp @@ -262,8 +262,8 @@ void Navigator::insertIOSlaveDocs( const TQString &name, NavigatorItem *topItem void Navigator::insertAppletDocs( NavigatorItem *topItem ) { - TQDir appletDir( locate( "data", TQString::fromLatin1( "kicker/applets/" ) ) ); - appletDir.setNameFilter( TQString::fromLatin1( "*.desktop" ) ); + TQDir appletDir( locate( "data", TQString::tqfromLatin1( "kicker/applets/" ) ) ); + appletDir.setNameFilter( TQString::tqfromLatin1( "*.desktop" ) ); TQStringList files = appletDir.entryList( TQDir::Files | TQDir::Readable ); TQStringList::ConstIterator it = files.begin(); @@ -290,14 +290,14 @@ void Navigator::createItemFromDesktopFile( NavigatorItem *topItem, void Navigator::insertInfoDocs( NavigatorItem *topItem ) { - InfoTree *infoTree = new InfoTree( this ); + InfoTree *infoTree = new InfoTree( TQT_TQOBJECT(this) ); infoTree->build( topItem ); } NavigatorItem *Navigator::insertScrollKeeperDocs( NavigatorItem *topItem, NavigatorItem *after ) { - ScrollKeeperTreeBuilder *builder = new ScrollKeeperTreeBuilder( this ); + ScrollKeeperTreeBuilder *builder = new ScrollKeeperTreeBuilder( TQT_TQOBJECT(this) ); return builder->build( topItem, after ); } @@ -337,7 +337,7 @@ void Navigator::selectItem( const KURL &url ) item = item->nextSibling() ) { NavigatorAppItem *appItem = dynamic_cast<NavigatorAppItem *>( item ); if ( appItem ) appItem->populate( true /* recursive */ ); - for ( QListViewItem *subitem = item->firstChild(); subitem; + for ( TQListViewItem *subitem = item->firstChild(); subitem; subitem = subitem->nextSibling() ) { appItem = dynamic_cast<NavigatorAppItem *>( subitem ); if ( appItem ) appItem->populate( true /* recursive */ ); @@ -407,9 +407,9 @@ void Navigator::slotItemSelected( TQListViewItem *currentItem ) // Enforce the original .docbook version, in case langLookup returns a // cached version if ( !doc.isNull() ) { - int pos = doc.find( ".html" ); + int pos = doc.tqfind( ".html" ); if ( pos >= 0 ) { - doc.replace( pos, 5, ".docbook" ); + doc.tqreplace( pos, 5, ".docbook" ); } kdDebug( 1400 ) << "slotItemSelected(): doc = " << doc << endl; @@ -552,7 +552,7 @@ void Navigator::slotSearch() // disable search Button during searches mSearchButton->setEnabled(false); - TQApplication::setOverrideCursor(waitCursor); + TQApplication::setOverrideCursor(tqwaitCursor); if ( !mSearchEngine->search( words, method, pages, scope ) ) { slotSearchFinished(); @@ -563,7 +563,7 @@ void Navigator::slotSearch() void Navigator::slotShowSearchResult( const TQString &url ) { TQString u = url; - u.replace( "%k", mSearchEdit->text() ); + u.tqreplace( "%k", mSearchEdit->text() ); emit itemSelected( u ); } diff --git a/khelpcenter/navigator.h b/khelpcenter/navigator.h index c49d5c585..c432d3a6a 100644 --- a/khelpcenter/navigator.h +++ b/khelpcenter/navigator.h @@ -52,7 +52,7 @@ class SearchEngine; class SearchWidget; class Formatter; -class Navigator : public QWidget +class Navigator : public TQWidget { Q_OBJECT public: diff --git a/khelpcenter/navigatoritem.h b/khelpcenter/navigatoritem.h index 50d2465c4..11b2f975d 100644 --- a/khelpcenter/navigatoritem.h +++ b/khelpcenter/navigatoritem.h @@ -27,7 +27,7 @@ namespace KHC { class TOC; class DocEntry; -class NavigatorItem : public QListViewItem +class NavigatorItem : public TQListViewItem { public: NavigatorItem( DocEntry *entry, TQListView *parent ); diff --git a/khelpcenter/scopeitem.h b/khelpcenter/scopeitem.h index 9b828a54f..cabbab76e 100644 --- a/khelpcenter/scopeitem.h +++ b/khelpcenter/scopeitem.h @@ -7,7 +7,7 @@ namespace KHC { -class ScopeItem : public QCheckListItem +class ScopeItem : public TQCheckListItem { public: ScopeItem( TQListView *parent, DocEntry *entry ) diff --git a/khelpcenter/scrollkeepertreebuilder.cpp b/khelpcenter/scrollkeepertreebuilder.cpp index 20a4b0851..4ee28d21d 100644 --- a/khelpcenter/scrollkeepertreebuilder.cpp +++ b/khelpcenter/scrollkeepertreebuilder.cpp @@ -180,7 +180,7 @@ void ScrollKeeperTreeBuilder::insertDoc( NavigatorItem *parent, if ( url.left( 5 ) == "file:" ) url = url.mid( 5 ); url.prepend( "ghelp:" ); #if 0 - url.replace( TQRegExp( ".xml$" ), ".html" ); + url.tqreplace( TQRegExp( ".xml$" ), ".html" ); #endif } else if ( mimeType == "text/sgml" ) { // GNOME docs use this type. We don't have a real viewer for this. diff --git a/khelpcenter/scrollkeepertreebuilder.h b/khelpcenter/scrollkeepertreebuilder.h index 5ed69caf7..a2e3356a2 100644 --- a/khelpcenter/scrollkeepertreebuilder.h +++ b/khelpcenter/scrollkeepertreebuilder.h @@ -31,7 +31,7 @@ class TQDomNode; namespace KHC { -class ScrollKeeperTreeBuilder : public QObject +class ScrollKeeperTreeBuilder : public TQObject { Q_OBJECT public: diff --git a/khelpcenter/searchengine.cpp b/khelpcenter/searchengine.cpp index b779afc8e..58217c031 100644 --- a/khelpcenter/searchengine.cpp +++ b/khelpcenter/searchengine.cpp @@ -93,7 +93,7 @@ void SearchTraverser::startProcess( DocEntry *entry ) void SearchTraverser::connectHandler( SearchHandler *handler ) { TQMap<SearchHandler *,int>::Iterator it; - it = mConnectCount.find( handler ); + it = mConnectCount.tqfind( handler ); int count = 0; if ( it != mConnectCount.end() ) count = *it; if ( count == 0 ) { @@ -108,7 +108,7 @@ void SearchTraverser::connectHandler( SearchHandler *handler ) void SearchTraverser::disconnectHandler( SearchHandler *handler ) { TQMap<SearchHandler *,int>::Iterator it; - it = mConnectCount.find( handler ); + it = mConnectCount.tqfind( handler ); if ( it == mConnectCount.end() ) { kdError() << "SearchTraverser::disconnectHandler() handler not connected." << endl; @@ -326,15 +326,15 @@ bool SearchEngine::search( TQString words, TQString method, int matches, lang = "en"; // if the string contains '&' replace with a '+' and set search method to and - if (mWords.find("&") != -1) { - mWords.replace("&", " "); + if (mWords.tqfind("&") != -1) { + mWords.tqreplace("&", " "); method = "and"; } // replace whitespace with a '+' mWords = mWords.stripWhiteSpace(); mWords = mWords.simplifyWhiteSpace(); - mWords.replace(TQRegExp("\\s"), "+"); + mWords.tqreplace(TQRegExp("\\s"), "+"); commonSearchProgram = substituteSearchQuery( commonSearchProgram ); @@ -379,8 +379,8 @@ bool SearchEngine::search( TQString words, TQString method, int matches, delete mProc; // modify the search result - mSearchResult = mSearchResult.replace("http://localhost/", "file:/"); - mSearchResult = mSearchResult.mid( mSearchResult.find( '<' ) ); + mSearchResult = mSearchResult.tqreplace("http://localhost/", "file:/"); + mSearchResult = mSearchResult.mid( mSearchResult.tqfind( '<' ) ); mView->beginSearchResult(); mView->writeSearchResult( mSearchResult ); @@ -395,11 +395,11 @@ bool SearchEngine::search( TQString words, TQString method, int matches, TQString SearchEngine::substituteSearchQuery( const TQString &query ) { TQString result = query; - result.replace( "%k", mWords ); - result.replace( "%n", TQString::number( mMatches ) ); - result.replace( "%m", mMethod ); - result.replace( "%l", mLang ); - result.replace( "%s", mScope ); + result.tqreplace( "%k", mWords ); + result.tqreplace( "%n", TQString::number( mMatches ) ); + result.tqreplace( "%m", mMethod ); + result.tqreplace( "%l", mLang ); + result.tqreplace( "%s", mScope ); return result; } @@ -409,15 +409,15 @@ TQString SearchEngine::substituteSearchQuery( const TQString &query, Operation operation, const TQString &lang ) { TQString result = query; - result.replace( "%i", identifier ); - result.replace( "%w", words.join( "+" ) ); - result.replace( "%m", TQString::number( maxResults ) ); + result.tqreplace( "%i", identifier ); + result.tqreplace( "%w", words.join( "+" ) ); + result.tqreplace( "%m", TQString::number( maxResults ) ); TQString o; if ( operation == Or ) o = "or"; else o = "and"; - result.replace( "%o", o ); - result.replace( "%d", Prefs::indexDirectory() ); - result.replace( "%l", lang ); + result.tqreplace( "%o", o ); + result.tqreplace( "%d", Prefs::indexDirectory() ); + result.tqreplace( "%l", lang ); return result; } @@ -458,7 +458,7 @@ bool SearchEngine::isRunning() const SearchHandler *SearchEngine::handler( const TQString &documentType ) const { TQMap<TQString,SearchHandler *>::ConstIterator it; - it = mHandlers.find( documentType ); + it = mHandlers.tqfind( documentType ); if ( it == mHandlers.end() ) return 0; else return *it; diff --git a/khelpcenter/searchengine.h b/khelpcenter/searchengine.h index bdd1860ed..84f252746 100644 --- a/khelpcenter/searchengine.h +++ b/khelpcenter/searchengine.h @@ -64,7 +64,7 @@ class SearchTraverser : public TQObject, public DocEntryTraverser }; -class SearchEngine : public QObject +class SearchEngine : public TQObject { Q_OBJECT public: diff --git a/khelpcenter/searchhandler.cpp b/khelpcenter/searchhandler.cpp index 9c34d7399..48f61e9e2 100644 --- a/khelpcenter/searchhandler.cpp +++ b/khelpcenter/searchhandler.cpp @@ -62,9 +62,9 @@ TQStringList SearchHandler::documentTypes() const TQString SearchHandler::indexCommand( const TQString &identifier ) { TQString cmd = mIndexCommand; - cmd.replace( "%i", identifier ); - cmd.replace( "%d", Prefs::indexDirectory() ); - cmd.replace( "%l", mLang ); + cmd.tqreplace( "%i", identifier ); + cmd.tqreplace( "%d", Prefs::indexDirectory() ); + cmd.tqreplace( "%l", mLang ); return cmd; } @@ -83,7 +83,7 @@ bool SearchHandler::checkBinary( const TQString &cmd ) const { TQString binary; - int pos = cmd.find( ' ' ); + int pos = cmd.tqfind( ' ' ); if ( pos < 0 ) binary = cmd; else binary = cmd.left( pos ); @@ -166,7 +166,7 @@ void SearchHandler::searchStdout( KProcess *proc, char *buffer, int len ) p = strncpy( p, buffer, len ); p[len] = '\0'; - TQMap<KProcess *, SearchJob *>::ConstIterator it = mProcessJobs.find( proc ); + TQMap<KProcess *, SearchJob *>::ConstIterator it = mProcessJobs.tqfind( proc ); if ( it != mProcessJobs.end() ) { (*it)->mResult += bufferStr.fromUtf8( p ); } @@ -179,7 +179,7 @@ void SearchHandler::searchStderr( KProcess *proc, char *buffer, int len ) if ( !buffer || len == 0 ) return; - TQMap<KProcess *, SearchJob *>::ConstIterator it = mProcessJobs.find( proc ); + TQMap<KProcess *, SearchJob *>::ConstIterator it = mProcessJobs.tqfind( proc ); if ( it != mProcessJobs.end() ) { (*it)->mError += TQString::fromUtf8( buffer, len ); } @@ -193,7 +193,7 @@ void SearchHandler::searchExited( KProcess *proc ) TQString error; DocEntry *entry = 0; - TQMap<KProcess *, SearchJob *>::ConstIterator it = mProcessJobs.find( proc ); + TQMap<KProcess *, SearchJob *>::ConstIterator it = mProcessJobs.tqfind( proc ); if ( it != mProcessJobs.end() ) { SearchJob *j = *it; entry = j->mEntry; @@ -218,7 +218,7 @@ void SearchHandler::slotJobResult( KIO::Job *job ) TQString result; DocEntry *entry = 0; - TQMap<KIO::Job *, SearchJob *>::ConstIterator it = mKioJobs.find( job ); + TQMap<KIO::Job *, SearchJob *>::ConstIterator it = mKioJobs.tqfind( job ); if ( it != mKioJobs.end() ) { SearchJob *j = *it; @@ -240,7 +240,7 @@ void SearchHandler::slotJobData( KIO::Job *job, const TQByteArray &data ) { // kdDebug() << "SearchHandler::slotJobData()" << endl; - TQMap<KIO::Job *, SearchJob *>::ConstIterator it = mKioJobs.find( job ); + TQMap<KIO::Job *, SearchJob *>::ConstIterator it = mKioJobs.tqfind( job ); if ( it != mKioJobs.end() ) { (*it)->mResult += data.data(); } diff --git a/khelpcenter/toc.cpp b/khelpcenter/toc.cpp index 7bda95b8c..02e59936a 100644 --- a/khelpcenter/toc.cpp +++ b/khelpcenter/toc.cpp @@ -88,7 +88,7 @@ void TOC::build( const TQString &file ) } } - TQString cacheFile = fileName.replace( TQDir::separator(), "__" ); + TQString cacheFile = fileName.tqreplace( TQDir::separator(), "__" ); m_cacheFile = locateLocal( "cache", "help/" + cacheFile ); m_sourceFile = file; @@ -188,9 +188,9 @@ void TOC::fillTree() TQDomNodeList chapters = doc.documentElement().elementsByTagName( "chapter" ); for ( unsigned int chapterCount = 0; chapterCount < chapters.count(); chapterCount++ ) { TQDomElement chapElem = chapters.item( chapterCount ).toElement(); - TQDomElement chapTitleElem = childElement( chapElem, TQString::fromLatin1( "title" ) ); + TQDomElement chapTitleElem = childElement( chapElem, TQString::tqfromLatin1( "title" ) ); TQString chapTitle = chapTitleElem.text().simplifyWhiteSpace(); - TQDomElement chapRefElem = childElement( chapElem, TQString::fromLatin1( "anchor" ) ); + TQDomElement chapRefElem = childElement( chapElem, TQString::tqfromLatin1( "anchor" ) ); TQString chapRef = chapRefElem.text().stripWhiteSpace(); chapItem = new TOCChapterItem( this, m_parentItem, chapItem, chapTitle, chapRef ); @@ -199,9 +199,9 @@ void TOC::fillTree() TQDomNodeList sections = chapElem.elementsByTagName( "section" ); for ( unsigned int sectCount = 0; sectCount < sections.count(); sectCount++ ) { TQDomElement sectElem = sections.item( sectCount ).toElement(); - TQDomElement sectTitleElem = childElement( sectElem, TQString::fromLatin1( "title" ) ); + TQDomElement sectTitleElem = childElement( sectElem, TQString::tqfromLatin1( "title" ) ); TQString sectTitle = sectTitleElem.text().simplifyWhiteSpace(); - TQDomElement sectRefElem = childElement( sectElem, TQString::fromLatin1( "anchor" ) ); + TQDomElement sectRefElem = childElement( sectElem, TQString::tqfromLatin1( "anchor" ) ); TQString sectRef = sectRefElem.text().stripWhiteSpace(); sectItem = new TOCSectionItem( this, chapItem, sectItem, sectTitle, sectRef ); @@ -261,8 +261,8 @@ TOCSectionItem::TOCSectionItem( TOC *toc, TOCChapterItem *parent, TQListViewItem TQString TOCSectionItem::url() { - if ( static_cast<TOCSectionItem *>( parent()->firstChild() ) == this ) - return static_cast<TOCChapterItem *>( parent() )->url() + "#" + m_name; + if ( static_cast<TOCSectionItem *>( tqparent()->firstChild() ) == this ) + return static_cast<TOCChapterItem *>( tqparent() )->url() + "#" + m_name; return "help:" + toc()->application() + "/" + m_name + ".html"; } diff --git a/khelpcenter/treebuilder.h b/khelpcenter/treebuilder.h index 99516d1ec..d926d2f84 100644 --- a/khelpcenter/treebuilder.h +++ b/khelpcenter/treebuilder.h @@ -28,7 +28,7 @@ namespace KHC { class NavigatorItem; -class TreeBuilder : public QObject +class TreeBuilder : public TQObject { Q_OBJECT public: diff --git a/khelpcenter/view.cpp b/khelpcenter/view.cpp index 64e6238ed..a28b5097f 100644 --- a/khelpcenter/view.cpp +++ b/khelpcenter/view.cpp @@ -20,9 +20,9 @@ using namespace KHC; -View::View( TQWidget *parentWidget, const char *widgetName, +View::View( TQWidget *tqparentWidget, const char *widgetName, TQObject *parent, const char *name, KHTMLPart::GUIProfile prof, KActionCollection *col ) - : KHTMLPart( parentWidget, widgetName, parent, name, prof ), mState( Docu ), mActionCollection(col) + : KHTMLPart( tqparentWidget, widgetName, parent, name, prof ), mState( Docu ), mActionCollection(col) { setJScriptEnabled(false); setJavaEnabled(false); @@ -174,7 +174,7 @@ TQString View::langLookup( const TQString &fname ) // css etc) then look in other languages first. if ( ( *it ).endsWith( "docbook" ) ) { - TQString file = (*it).left((*it).findRev('/')) + "/index.docbook"; + TQString file = (*it).left((*it).tqfindRev('/')) + "/index.docbook"; info.setFile(file); if (info.exists() && info.isFile() && info.isReadable()) { @@ -328,8 +328,8 @@ bool View::eventFilter( TQObject *o, TQEvent *e ) htmlDocument().links().length() == 0 ) return KHTMLPart::eventFilter( o, e ); - TQKeyEvent *ke = static_cast<TQKeyEvent *>( e ); - if ( ke->state() & Qt::ShiftButton && ke->key() == Key_Space ) { + TQKeyEvent *ke = TQT_TQKEYEVENT( e ); + if ( ke->state() & TQt::ShiftButton && ke->key() == Key_Space ) { // If we're on the first page, it does not make sense to go back. if ( baseURL().path().endsWith( "/index.html" ) ) return KHTMLPart::eventFilter( o, e ); @@ -361,7 +361,7 @@ KURL View::urlFromLinkNode( const DOM::Node &n ) const return href; TQString path = baseURL().path(); - path.truncate( path.findRev( '/' ) + 1 ); + path.truncate( path.tqfindRev( '/' ) + 1 ); path += href.url(); KURL url = baseURL(); diff --git a/khelpcenter/view.h b/khelpcenter/view.h index 3af2a15b8..1c5a2bf66 100644 --- a/khelpcenter/view.h +++ b/khelpcenter/view.h @@ -20,7 +20,7 @@ class View : public KHTMLPart { Q_OBJECT public: - View( TQWidget *parentWidget, const char *widgetName, + View( TQWidget *tqparentWidget, const char *widgetName, TQObject *parent, const char *name, KHTMLPart::GUIProfile prof, KActionCollection *col ); |