diff options
Diffstat (limited to 'quanta/src/dtds.cpp')
-rw-r--r-- | quanta/src/dtds.cpp | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/quanta/src/dtds.cpp b/quanta/src/dtds.cpp index d6bdd9e1..7b26bc7a 100644 --- a/quanta/src/dtds.cpp +++ b/quanta/src/dtds.cpp @@ -120,9 +120,9 @@ DTDs::DTDs(TQObject *tqparent) DTDStruct * dtd = it.current(); for (uint i = 0; i < dtd->insideDTDs.count(); i++) { - const DTDStruct *insideDTD = m_dict->tqfind(dtd->insideDTDs[i]); // search but don't load + const DTDStruct *insideDTD = m_dict->find(dtd->insideDTDs[i]); // search but don't load if (!insideDTD) - insideDTD = m_dict->tqfind(getDTDNameFromNickName(dtd->insideDTDs[i])); // search but don't load + insideDTD = m_dict->find(getDTDNameFromNickName(dtd->insideDTDs[i])); // search but don't load if (insideDTD && !insideDTD->toplevel) dtd->mimeTypes += insideDTD->mimeTypes; } @@ -168,7 +168,7 @@ bool DTDs::readTagDir(const TQString &dirName, bool loadAll) KConfig *dtdConfig = new KConfig(tmpStr, true); dtdConfig->setGroup("General"); TQString dtdName = dtdConfig->readEntry("Name", "Unknown"); - if (m_dict->tqfind(dtdName.lower())) + if (m_dict->find(dtdName.lower())) { delete dtdConfig; kdDebug(24000) << "dtds::readTagDir from " << dirName @@ -205,8 +205,8 @@ bool DTDs::readTagDir(const TQString &dirName, bool loadAll) for (uint i = 0; i < tmpStrList.count(); i++) { tmpStr = tmpStrList[i].stripWhiteSpace(); - int pos = tmpStr.tqfind('('); - dtd->definitionTags[tmpStr.left(pos).stripWhiteSpace()] = tmpStr.mid(pos+1, tmpStr.tqfindRev(')')-pos-1).stripWhiteSpace(); + int pos = tmpStr.find('('); + dtd->definitionTags[tmpStr.left(pos).stripWhiteSpace()] = tmpStr.mid(pos+1, tmpStr.findRev(')')-pos-1).stripWhiteSpace(); } //Which DTD can be present in this one? dtd->insideDTDs = dtdConfig->readListEntry("MayContain"); @@ -317,7 +317,7 @@ bool DTDs::readTagDir2(DTDStruct *dtd) tag->setName(TQString(extraTagsList.at(i)).stripWhiteSpace()); tmpStr = (dtd->caseSensitive) ? tag->name() : tag->name().upper(); - if (tagList->tqfind(tmpStr)) //the tag is already defined in a .tag file + if (tagList->find(tmpStr)) //the tag is already defined in a .tag file { delete tag; continue; //skip this tag @@ -422,8 +422,8 @@ bool DTDs::readTagDir2(DTDStruct *dtd) for (uint i = 0; i < tmpStrList.count(); i++) { tmpStr = tmpStrList[i].stripWhiteSpace(); - int pos = tmpStr.tqfind('('); - dtd->specialTags[tmpStr.left(pos).stripWhiteSpace()] = tmpStr.mid(pos+1, tmpStr.tqfindRev(')')-pos-1).stripWhiteSpace(); + int pos = tmpStr.find('('); + dtd->specialTags[tmpStr.left(pos).stripWhiteSpace()] = tmpStr.mid(pos+1, tmpStr.findRev(')')-pos-1).stripWhiteSpace(); } //static const TQString quotationStr = "\\\\\"|\\\\'"; @@ -595,7 +595,7 @@ bool DTDs::readTagDir2(DTDStruct *dtd) attrRx.search(tagStr); tmpStr = attrRx.cap(); tmpStrList = TQStringList::split(',', tmpStr.mid(1, tmpStr.length()-2)); - tagName = tagStr.left(tagStr.tqfind('(')).lower(); + tagName = tagStr.left(tagStr.find('(')).lower(); group.attributes.clear(); for (uint i = 0; i < tmpStrList.count(); i++) group.attributes += tmpStrList[i].stripWhiteSpace(); @@ -620,13 +620,13 @@ void DTDs::resolveInherited (DTDStruct *dtd) //Resolve the inheritence if (!dtd->inheritsTagsFrom.isEmpty()) { - DTDStruct *tqparent = (DTDStruct *) tqfind(dtd->inheritsTagsFrom); // this loads the dtd, if not present in memory + DTDStruct *tqparent = (DTDStruct *) find(dtd->inheritsTagsFrom); // this loads the dtd, if not present in memory TQDictIterator<TQTag> tag_it(*(tqparent->tagsList)); for ( ; tag_it.current(); ++tag_it) { TQTag *tag = tag_it.current(); TQString searchForTag = (dtd->caseSensitive) ? tag->name() : tag->name().upper(); - if (!dtd->tagsList->tqfind(searchForTag)) + if (!dtd->tagsList->find(searchForTag)) { TQTag *newTag = new TQTag(*tag); dtd->tagsList->insert(searchForTag, newTag); @@ -642,9 +642,9 @@ void DTDs::resolveInherited (DTDStruct *dtd) specialAreaStartRxStr += "|"; for (uint i = 0; i < dtd->insideDTDs.count(); i++) { - const DTDStruct *insideDTD = m_dict->tqfind(dtd->insideDTDs[i]); // search but don't load + const DTDStruct *insideDTD = m_dict->find(dtd->insideDTDs[i]); // search but don't load if (!insideDTD) - insideDTD = m_dict->tqfind(getDTDNameFromNickName(dtd->insideDTDs[i])); // search but don't load + insideDTD = m_dict->find(getDTDNameFromNickName(dtd->insideDTDs[i])); // search but don't load if (insideDTD) { for (mapIt = insideDTD->definitionAreas.begin(); mapIt != insideDTD->definitionAreas.end(); ++mapIt) @@ -725,10 +725,10 @@ uint DTDs::readTagFile(const TQString& fileName, DTDStruct* parentDTD, TQTagList { if (parentDTD->caseSensitive) { - tagList->tqreplace(tag->name(), tag); //append the tag to the list for this DTD + tagList->replace(tag->name(), tag); //append the tag to the list for this DTD } else { - tagList->tqreplace(tag->name().upper(), tag); + tagList->replace(tag->name().upper(), tag); } } } @@ -912,7 +912,7 @@ void DTDs::slotLoadDTD() dtdcfg.setGroup("General"); TQString dtdName = dtdcfg.readEntry("Name"); TQString nickName = dtdcfg.readEntry("NickName", dtdName); - DTDStruct * dtd = m_dict->tqfind(dtdName) ; + DTDStruct * dtd = m_dict->find(dtdName) ; if (dtd && KMessageBox::warningYesNo(0L, i18n("<qt>Do you want to replace the existing <b>%1</b> DTD?</qt>").tqarg(nickName), TQString(), i18n("Replace"), i18n("Do Not Replace")) == KMessageBox::No) { @@ -944,7 +944,7 @@ void DTDs::slotLoadDTEP(const TQString &_dirName, bool askForAutoload) dtdcfg.setGroup("General"); TQString dtdName = dtdcfg.readEntry("Name"); TQString nickName = dtdcfg.readEntry("NickName", dtdName); - DTDStruct * dtd = m_dict->tqfind(dtdName) ; + DTDStruct * dtd = m_dict->find(dtdName) ; if ( dtd && KMessageBox::warningYesNo(0L, i18n("<qt>Do you want to replace the existing <b>%1</b> DTD?</qt>").tqarg(nickName), TQString(), i18n("Replace"), i18n("Do Not Replace")) == KMessageBox::No) { @@ -987,12 +987,12 @@ void DTDs::slotLoadEntities() if (w) { TQString nickName = DTDs::ref()->getDTDNickNameFromName(w->getDTDIdentifier()); - entitiesWidget.targetDTEPCombo->setCurrentItem(lst.tqfindIndex(nickName)); + entitiesWidget.targetDTEPCombo->setCurrentItem(lst.findIndex(nickName)); } dlg.setMainWidget(&entitiesWidget); if (dlg.exec()) { - DTDStruct * dtd = m_dict->tqfind(getDTDNameFromNickName(entitiesWidget.targetDTEPCombo->currentText())); + DTDStruct * dtd = m_dict->find(getDTDNameFromNickName(entitiesWidget.targetDTEPCombo->currentText())); DTDParser dtdParser(KURL::fromPathOrURL(entitiesWidget.sourceDTDRequester->url()), KGlobal::dirs()->saveLocation("data") + resourceDir + "dtep"); TQString dtdDir = TQFileInfo(dtd->fileName).dirPath(); if (dtdParser.parse(dtdDir, true)) @@ -1077,7 +1077,7 @@ const DTDStruct * DTDs::DTDforURL(const KURL &url) } } if (foundList.isEmpty()) - return tqfind("empty"); + return find("empty"); else { TQString path = url.path(); @@ -1093,7 +1093,7 @@ const DTDStruct * DTDs::DTDforURL(const KURL &url) bool DTDs::canHandle(const DTDStruct *dtd, const KURL &url) { TQString mimetype = KMimeType::findByURL(url)->name(); - if (dtd->mimeTypes.tqcontains(mimetype)) + if (dtd->mimeTypes.contains(mimetype)) return true; if (url.path().endsWith('.' + dtd->defaultExtension)) return true; |