From 99a2774ca6f1cab334de5d43fe36fc44ae889a4c Mon Sep 17 00:00:00 2001 From: tpearson Date: Sun, 12 Jun 2011 01:36:19 +0000 Subject: TQt4 convert kdesdk This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1236185 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- .../modules/dbsearchengine2/KDBSearchEngine2.cpp | 26 ++-- .../modules/dbsearchengine2/KDBSearchEngine2.h | 7 +- .../modules/dbsearchengine2/algorithms.cpp | 4 +- .../modules/dbsearchengine2/algorithms.h | 11 +- .../modules/dbsearchengine2/database.cpp | 46 +++---- .../kbabeldict/modules/dbsearchengine2/database.h | 4 +- .../modules/dbsearchengine2/dbentries.cpp | 8 +- .../kbabeldict/modules/dbsearchengine2/dbscan.cpp | 16 +-- kbabel/kbabeldict/modules/dbsearchengine2/dbscan.h | 6 +- kbabel/kbabeldict/modules/dbsearchengine2/dbse2.ui | 116 ++++++++-------- .../modules/dbsearchengine2/dbse2_factory.cpp | 8 +- .../modules/dbsearchengine2/dbse2_factory.h | 7 +- .../modules/dbsearchengine2/dbseprefwidget.ui | 152 ++++++++++----------- .../modules/dbsearchengine2/preferenceswidget.cpp | 10 +- .../modules/dbsearchengine2/preferenceswidget.h | 3 +- .../modules/dbsearchengine2/sourcedialog.ui | 40 +++--- 16 files changed, 238 insertions(+), 226 deletions(-) (limited to 'kbabel/kbabeldict/modules/dbsearchengine2') diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.cpp index 41f4319d..36f66fc1 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.cpp @@ -18,11 +18,11 @@ * * * In addition, as a special exception, the copyright holders give * * permission to link the code of this program with any edition of * - * the Qt library by Trolltech AS, Norway (or with modified versions * - * of Qt that use the same license as Qt), and distribute linked * + * the TQt library by Trolltech AS, Norway (or with modified versions * + * of TQt that use the same license as TQt), and distribute linked * * combinations including the two. You must obey the GNU General * * Public License in all respects for all of the code used other than * - * Qt. If you modify this file, you may extend this exception to * + * TQt. If you modify this file, you may extend this exception to * * your version of the file, but you are not obligated to do so. If * * you do not wish to do so, delete this exception statement from * * your version. * @@ -47,8 +47,8 @@ #include #define i18n (const char *) -KDBSearchEngine2::KDBSearchEngine2(TQObject *parent,const char*name) - : SearchEngine(parent,name) +KDBSearchEngine2::KDBSearchEngine2(TQObject *tqparent,const char*name) + : SearchEngine(tqparent,name) { pw=0; dbDirectory="."; @@ -250,15 +250,15 @@ void KDBSearchEngine2::stringChanged( TQString orig, TQString translated if(!init()) return; //if(translated.isEmpty()) return; InputInfo ii; - if(description.find("fuzzy",false)==-1) + if(description.tqfind("fuzzy",false)==-1) di->addEntry(orig,translated,&ii); } -PrefWidget * KDBSearchEngine2::preferencesWidget(TQWidget *parent) +PrefWidget * KDBSearchEngine2::preferencesWidget(TQWidget *tqparent) { - pw = new KDB2PreferencesWidget(parent); + pw = new KDB2PreferencesWidget(tqparent); kdDebug(0) << "new KDB2 preferences widget" << endl; setSettings(); connect(pw,TQT_SIGNAL(restoreNow()),this,TQT_SLOT(setSettings())); @@ -499,7 +499,7 @@ void KDBSearchEngine2::scanNowPressed() TQString sourceName; sourceName=pw->dbpw->sourceList->currentText(); if(!init()) return; - if(sources.contains(sourceName)) + if(sources.tqcontains(sourceName)) { TQValueList urls=sources[sourceName].urls(); PoScanner ps(di); @@ -538,7 +538,7 @@ void KDBSearchEngine2::editSource() TQString sourceName; sourceName=pw->dbpw->sourceList->currentText(); - if(sources.contains(sourceName)) + if(sources.tqcontains(sourceName)) { bool nameIsNew; TQString newName; @@ -554,7 +554,7 @@ void KDBSearchEngine2::editSource() { return; } - nameIsNew=sources.contains(newName); + nameIsNew=sources.tqcontains(newName); if(newName!=sourceName && !nameIsNew) { @@ -602,13 +602,13 @@ void KDBSearchEngine2::addSource() if(sd.exec()==TQDialog::Accepted) { newName= sd.sourceName->text(); - nameIsNew=!sources.contains(newName); + nameIsNew=!sources.tqcontains(newName); } else { return; } - // nameIsNew=sources.contains(newName); + // nameIsNew=sources.tqcontains(newName); if(!nameIsNew) { KMessageBox::error(0,i18n("The name you chose is already used.\nPlease change the source name."), diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.h b/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.h index fb9cff70..89a32571 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.h +++ b/kbabel/kbabeldict/modules/dbsearchengine2/KDBSearchEngine2.h @@ -22,10 +22,11 @@ Andrea Rizzi class KDBSearchEngine2 : public SearchEngine { Q_OBJECT + TQ_OBJECT public: - KDBSearchEngine2(TQObject *parent=0, const char *name=0); + KDBSearchEngine2(TQObject *tqparent=0, const char *name=0); virtual ~KDBSearchEngine2(); //init if needed. @@ -77,9 +78,9 @@ class KDBSearchEngine2 : public SearchEngine * search engine. The returned widget should not be bigger than * 400x400. If you need more space, you maybe want to use * a tabbed widget. - * @param parent the parent of the returned widget + * @param tqparent the tqparent of the returned widget */ - virtual PrefWidget* preferencesWidget(TQWidget *parent); + virtual PrefWidget* preferencesWidget(TQWidget *tqparent); /** @returns information about this SearchEngine */ virtual const KAboutData *about() const; diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.cpp index 466b68e5..ab3d14b1 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.cpp @@ -145,7 +145,7 @@ DataBaseInterface::ResultList ChunkByChunkSearchAlgorithm::exec( const TQString for(ResultList::iterator it1=r.begin();it1!=r.end() &&!di->stopNow(); ++it1) { TQString chunkTranslation= (*it1).result(); - if(!translationUsed.contains(chunkTranslation)) + if(!translationUsed.tqcontains(chunkTranslation)) { translationUsed[chunkTranslation]=true; kdDebug(0) << "a translation is: " << chunkTranslation << endl; @@ -330,7 +330,7 @@ DataBaseInterface::ResultList FuzzyChunkSearchAlgorithm::exec( const TQString & TQString re=di->format(di->simple(*it,true),query); QueryResult r(re,ori,score); for(TQPtrListIterator it(querychunks); it.current() && di->stopNow() ; ++it){ - ori=ori.replace(TQRegExp((*it)->chunkString(),false),""+(*it)->chunkString()+""); + ori=ori.tqreplace(TQRegExp((*it)->chunkString(),false),""+(*it)->chunkString()+""); } r.setRichOriginal(ori); if(!di->stopNow()) diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.h b/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.h index aa049f85..e2c5db67 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.h +++ b/kbabel/kbabeldict/modules/dbsearchengine2/algorithms.h @@ -16,9 +16,10 @@ #include "chunk.h" #include -class AbstractSearchAlgorithm : public QObject +class AbstractSearchAlgorithm : public TQObject { Q_OBJECT + TQ_OBJECT public: typedef TQValueList ResultList; @@ -47,6 +48,7 @@ class AbstractSearchAlgorithm : public QObject class ExactSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: ExactSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets) : AbstractSearchAlgorithm(dbi,sets) {} @@ -56,6 +58,7 @@ class ExactSearchAlgorithm : public AbstractSearchAlgorithm class AlphaSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: AlphaSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets) : AbstractSearchAlgorithm(dbi,sets) {} @@ -65,6 +68,7 @@ class AlphaSearchAlgorithm : public AbstractSearchAlgorithm class SentenceArchiveSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: SentenceArchiveSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets) ; @@ -74,6 +78,7 @@ class SentenceArchiveSearchAlgorithm : public AbstractSearchAlgorithm class ChunkByChunkSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: ChunkByChunkSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets); @@ -90,6 +95,7 @@ class ChunkByChunkSearchAlgorithm : public AbstractSearchAlgorithm class FuzzyChunkSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: FuzzyChunkSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets); @@ -105,6 +111,7 @@ class FuzzyChunkSearchAlgorithm : public AbstractSearchAlgorithm class GenericSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: GenericSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets) ; @@ -123,6 +130,7 @@ class GenericSearchAlgorithm : public AbstractSearchAlgorithm class CorrelationSearchAlgorithm : public AbstractSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: CorrelationSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets) : AbstractSearchAlgorithm(dbi,sets) {} virtual ResultList exec(const TQString& query); @@ -133,6 +141,7 @@ class CorrelationSearchAlgorithm : public AbstractSearchAlgorithm class SingleWordSearchAlgorithm : public GenericSearchAlgorithm { Q_OBJECT + TQ_OBJECT public: SingleWordSearchAlgorithm(DataBaseInterface *dbi,DBSESettings *sets); virtual DataBaseInterface::ResultList exec(const TQString& query); diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/database.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/database.cpp index 0631f7ad..e5250274 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/database.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/database.cpp @@ -174,7 +174,7 @@ DataBaseInterface::MainEntry DataBaseInterface::get(const TQString& query,Search // kdDebug(0) << "MAINDB->GET returned: " << r << endl; if(counter%5==0) kapp->processEvents(100); // kdDebug(0) << "events processed" << endl; - return qMakePair(k,d); + return tqMakePair(k,d); } @@ -282,7 +282,7 @@ bool DataBaseInterface::addEntry(TQString original,TQString translated,InputInfo TQStringList wt=words(*otIt); for(TQStringList::iterator it = wt.begin(); it!=wt.end(); ++it) { - if(correlationDiff.contains(*it)) + if(correlationDiff.tqcontains(*it)) correlationDiff[*it]--; else correlationDiff[*it]=-1; @@ -299,7 +299,7 @@ bool DataBaseInterface::addEntry(TQString original,TQString translated,InputInfo TQStringList wt=words(*otIt); for(TQStringList::iterator it = wt.begin(); it!=wt.end(); ++it) { - if(correlationDiff.contains(*it)) + if(correlationDiff.tqcontains(*it)) correlationDiff[*it]++; else correlationDiff[*it]=1; @@ -408,7 +408,7 @@ TQMap DataBaseInterface::correlation(TQString word,SearchFilter MainEntry e=get(k->getString(),filter); TQStringList trad=e.second.getTranslations(); - nocck=words(k->getString()).contains(sword); + nocck=words(k->getString()).tqcontains(sword); for( TQStringList::iterator it2=trad.begin();it2!=trad.end();++it2) { @@ -465,7 +465,7 @@ TQStringList DataBaseInterface::words(TQString s) int pos; do { - pos=str.find(TQRegExp("\\s")); + pos=str.tqfind(TQRegExp("\\s")); // if(!simple(str.left(pos)).isEmpty()) // list.append(simple(str.left(pos))); if(!str.left(pos).isEmpty()) @@ -484,13 +484,13 @@ TQString DataBaseInterface::simple(TQString str,bool ck) else res=str.lower(); //lowercase //FIXME: uncoment the foll. line (check speed) - res=res.replace(TQRegExp("(<(.*)>)(.*)()"),"\\3"); //remove enclosing tags + res=res.tqreplace(TQRegExp("(<(.*)>)(.*)()"),"\\3"); //remove enclosing tags //Try to get rid of regexps. - // res=res.replace(TQRegExp("(('|-|_|\\s|[^\\w%])+)")," "); //strip non-word char - // res=res.replace(TQRegExp("(('|-|_)+)")," "); //strip non-word char - // res=res.replace(TQRegExp("[^\\w\\s%]"),""); //strip non-word char + // res=res.tqreplace(TQRegExp("(('|-|_|\\s|[^\\w%])+)")," "); //strip non-word char + // res=res.tqreplace(TQRegExp("(('|-|_)+)")," "); //strip non-word char + // res=res.tqreplace(TQRegExp("[^\\w\\s%]"),""); //strip non-word char TQString r; TQChar c; @@ -607,16 +607,16 @@ TQString DataBaseInterface::format(TQString _s,TQString t) //FIXME use regexp TQString s=_s; - TQString noTagT=t.replace(TQRegExp("(<(.*)>)(.*)()"),"\\3"); - TQChar first=noTagT[noTagT.find(TQRegExp("\\w"))]; + TQString noTagT=t.tqreplace(TQRegExp("(<(.*)>)(.*)()"),"\\3"); + TQChar first=noTagT[noTagT.tqfind(TQRegExp("\\w"))]; bool firstCapital=isUpper(first); /* -bool dotsAtEnd=(t.find("...")+3==t.length()); -bool gtgtAtEnd=(t.find(">>")+2==t.length()); -bool ltltAtEnd=(t.find("<<")==t.length()-2); +bool dotsAtEnd=(t.tqfind("...")+3==t.length()); +bool gtgtAtEnd=(t.tqfind(">>")+2==t.length()); +bool ltltAtEnd=(t.tqfind("<<")==t.length()-2); -bool columnAtEnd=(t.find(":")+1==t.length()); +bool columnAtEnd=(t.tqfind(":")+1==t.length()); */ bool allupper=(t.upper()==t); @@ -643,13 +643,13 @@ if(columnAtEnd) if(allupper) s=s.upper(); - int pos=t.find(TQRegExp("&")); + int pos=t.tqfind(TQRegExp("&")); if(pos>=0) { - TQChar accel=t[t.find(TQRegExp("&"))+1]; + TQChar accel=t[t.tqfind(TQRegExp("&"))+1]; if(accel!='&') { - pos=s.find(accel,false); + pos=s.tqfind(accel,false); if(pos<0) pos=0; s.insert(pos,"&"); @@ -685,8 +685,8 @@ TQString DataBaseInterface::formatRegExp(TQString _s, TQString t, TQString tre,T //kdDebug(0) << "phRegExp: " << phRegExp << endl; //kdDebug(0) << "cap[" << i << "]: "<< *capit<< endl; - stringReplace = stringReplace.replace(TQRegExp(phRegExp),*capit); - stringSearch = stringSearch.replace(TQRegExp(phRegExp),*capit); + stringReplace = stringReplace.tqreplace(TQRegExp(phRegExp),*capit); + stringSearch = stringSearch.tqreplace(TQRegExp(phRegExp),*capit); i++; } @@ -694,7 +694,7 @@ TQString DataBaseInterface::formatRegExp(TQString _s, TQString t, TQString tre,T // kdDebug(0) << "stringReplace " << stringReplace << endl; TQRegExp stringSearchRegExp = TQRegExp(stringSearch); // kdDebug(0) << "before: "<get(&k,&d); if(counter%5==0) kapp->processEvents(100); - return qMakePair(k,d); + return tqMakePair(k,d); } @@ -748,5 +748,5 @@ DBItemMultiIndex::IndexList DataBaseInterface::getWordIndex( const TQString & qu -//#include "database.moc.cpp" +//#include "database.tqmoc.cpp" diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/database.h b/kbabel/kbabeldict/modules/dbsearchengine2/database.h index d6ed3482..113d7704 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/database.h +++ b/kbabel/kbabeldict/modules/dbsearchengine2/database.h @@ -153,13 +153,13 @@ class SearchFilter -class DataBaseInterface : public QObject +class DataBaseInterface : public TQObject { public: //move result list typedef to AbstractAlgorthm or somewhere else typedef TQValueList ResultList; - typedef QPair MainEntry; + typedef TQPair MainEntry; DataBaseInterface( TQString dir, DBSESettings *sets); ~DataBaseInterface(); diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbentries.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/dbentries.cpp index efa7e44d..0958b801 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbentries.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbentries.cpp @@ -71,13 +71,13 @@ void DBItemMainData::read(TQDataStream *s) void DBItemMainData::write(TQDataStream *s) { - *s << (Q_UINT32)indexnumber << translations; + *s << (TQ_UINT32)indexnumber << translations; } void DBItemMainData::addTranslation(TQString str, unsigned int ref) { //get(); - if(translations[str].find(ref)==translations[str].end()) // If it do not exists + if(translations[str].tqfind(ref)==translations[str].end()) // If it do not exists translations[str].append(ref); //add a new reference. else { @@ -106,7 +106,7 @@ TQMapIterator > it2; { //Dirty hack it2=it; it++; - if(it2.data().find(ref)!=it2.data().end()) + if(it2.data().tqfind(ref)!=it2.data().end()) removeTranslation(it2.key(),ref); } @@ -142,7 +142,7 @@ list.clear(); void DBItemMultiIndex::addEntry(unsigned int index) { // get(); - if(list.find(index)==list.end()) + if(list.tqfind(index)==list.end()) { list.append(index); qHeapSort(list); diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.cpp index 7c2d8564..b7e64c2b 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.cpp @@ -39,7 +39,7 @@ void MessagesSource::writeConfig(KConfigBase *config) config->writeEntry("LocationType",type); config->writeEntry("ProjectName",projectName); config->writeEntry("ProjectKeywords",projectKeywords); - config->writeEntry("Status",status); + config->writeEntry("tqStatus",status); } void MessagesSource::readConfig(KConfigBase *config) @@ -48,7 +48,7 @@ void MessagesSource::readConfig(KConfigBase *config) type=config->readNumEntry("LocationType",0); projectName=config->readEntry("ProjectName"); projectKeywords=config->readEntry("ProjectKeywords"); - status=config->readEntry("Status"); + status=config->readEntry("tqStatus"); } @@ -87,7 +87,7 @@ TQValueList MessagesSource::filesInDir(KURL url,bool recursive) TQDir d(url.path()); d.setMatchAllDirs(true); kdDebug(0) << d.count() << " files in dir "<< url.path()< it(*files); @@ -120,7 +120,7 @@ TQValueList MessagesSource::filesInDir(KURL url,bool recursive) //FIXME: clean this class PoScanner::PoScanner(DataBaseInterface *dbi, - TQObject *parent,const char *name):TQObject(parent,name) + TQObject *tqparent,const char *name):TQObject(tqparent,name) { di=dbi; removeOldCatalogTranslation=true; @@ -138,7 +138,7 @@ if (!called) { pb=true; count=0;} called=true; -kdDebug(0) << TQString("Scanning: %1, %2").arg(pathName).arg(pattern) << endl; +kdDebug(0) << TQString("Scanning: %1, %2").tqarg(pathName).tqarg(pattern) << endl; if(pb) { @@ -147,7 +147,7 @@ emit patternProgress(0); } TQDir d(pathName,pattern); d.setMatchAllDirs(true); - const QFileInfoList* files = d.entryInfoList(); + const TQFileInfoList* files = d.entryInfoList(); tot=files->count(); TQPtrListIterator it(*files); kdDebug(0) << tot << endl; @@ -203,7 +203,7 @@ emit fileStarted(); Catalog * catalog=new Catalog(this,"ScanPoCatalog"); TQString pretty=u.prettyURL(); -TQString location=pretty.right(pretty.length()-pretty.findRev("/")-1); +TQString location=pretty.right(pretty.length()-pretty.tqfindRev("/")-1); connect(catalog,TQT_SIGNAL(signalProgress(int)),this,TQT_SIGNAL(fileLoading(int))); emit filename(location); @@ -212,7 +212,7 @@ emit fileLoading(0); bool error; -ConversionStatus rr=catalog->openURL(u); +ConversiontqStatus rr=catalog->openURL(u); if(rr != OK && rr !=RECOVERED_PARSE_ERROR ) { delete catalog; diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.h b/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.h index e4cdf7da..3036f70c 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.h +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbscan.h @@ -69,13 +69,13 @@ class MessagesSource }; -class PoScanner : public QObject +class PoScanner : public TQObject { - Q_OBJECT; + TQ_OBJECT; public: - PoScanner(DataBaseInterface *dbi,TQObject *parent=0,const char *name=0); + PoScanner(DataBaseInterface *dbi,TQObject *tqparent=0,const char *name=0); /* Scan a single PO file. diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbse2.ui b/kbabel/kbabeldict/modules/dbsearchengine2/dbse2.ui index 327a9d9d..348900e5 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbse2.ui +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbse2.ui @@ -1,10 +1,10 @@ DBSearchEnginePrefWidget - + Form1 - + 0 0 @@ -16,11 +16,11 @@ unnamed - + tabWidget2 - + tab @@ -31,7 +31,7 @@ unnamed - + groupBox1 @@ -42,7 +42,7 @@ unnamed - + textLabel1 @@ -55,7 +55,7 @@ dbDirectory - + autoUpdate @@ -65,7 +65,7 @@ - + groupBox2 @@ -76,7 +76,7 @@ unnamed - + textLabel2 @@ -84,7 +84,7 @@ Author: - + checkBox2 @@ -109,7 +109,7 @@ Expanding - + 20 40 @@ -118,7 +118,7 @@ - + tab @@ -129,7 +129,7 @@ unnamed - + textLabel5 @@ -147,7 +147,7 @@ Expanding - + 20 40 @@ -168,7 +168,7 @@ Horizontal - + groupBox3 @@ -179,7 +179,7 @@ unnamed - + textLabel3_2 @@ -197,7 +197,7 @@ scoreGlossary - + textLabel3_2_2 @@ -205,7 +205,7 @@ Score: - + useSentence @@ -213,7 +213,7 @@ Fuzzy sentence archive - + useGlossary @@ -221,7 +221,7 @@ Glossary - + useExact @@ -244,7 +244,7 @@ scoreSentence - + useDivide @@ -252,7 +252,7 @@ Sentence by sentence - + useAlpha @@ -260,7 +260,7 @@ Alphanumeric - + textLabel3_2_3 @@ -268,7 +268,7 @@ Score: - + textLabel3_2_4 @@ -276,7 +276,7 @@ Score: - + textLabel3 @@ -289,7 +289,7 @@ scoreAlpha - + textLabel3_2_6 @@ -297,7 +297,7 @@ Score: - + textLabel3_2_5 @@ -305,7 +305,7 @@ Score: - + useWordByWord @@ -313,7 +313,7 @@ Word by word - + useDynamic @@ -328,7 +328,7 @@ - + textLabel4 @@ -348,7 +348,7 @@ - + tab @@ -359,7 +359,7 @@ unnamed - + groupBox4 @@ -380,14 +380,14 @@ Fixed - + 20 20 - + firstCapital @@ -395,7 +395,7 @@ First capital letter match - + allCapital @@ -403,7 +403,7 @@ All capital letter match - + accelerator @@ -411,7 +411,7 @@ Accelerator symbol (&&) - + sameLetter @@ -421,7 +421,7 @@ - + groupBox5 @@ -432,7 +432,7 @@ unnamed - + textLabel1_2 @@ -445,7 +445,7 @@ kLineEdit1_2 - + Enabled @@ -496,7 +496,7 @@ Expanding - + 20 20 @@ -511,7 +511,7 @@ Delete - + addRule @@ -519,7 +519,7 @@ Add - + textLabel3_3 @@ -537,7 +537,7 @@ kLineEdit2 - + textLabel2_2 @@ -549,7 +549,7 @@ - + tab @@ -560,18 +560,18 @@ unnamed - + groupBox6 Options - + checkLang - + 20 30 @@ -583,11 +583,11 @@ Check language - + useFilters - + 20 60 @@ -599,11 +599,11 @@ Use current filters - + dateToday - + 20 90 @@ -616,7 +616,7 @@ - + groupBox7 @@ -627,7 +627,7 @@ unnamed - + editSource @@ -669,7 +669,7 @@ Expanding - + 20 40 @@ -684,7 +684,7 @@ Scan All - + sourceList @@ -693,7 +693,7 @@ - + tab @@ -706,7 +706,7 @@ - + klineedit.h kpushbutton.h diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.cpp index 55f6a16f..0c65710c 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.cpp @@ -22,8 +22,8 @@ KInstance *DbSe2Factory::s_instance = 0; KAboutData *DbSe2Factory::s_about = 0; -DbSe2Factory::DbSe2Factory( TQObject *parent, const char *name) - : KLibFactory(parent,name) +DbSe2Factory::DbSe2Factory( TQObject *tqparent, const char *name) + : KLibFactory(tqparent,name) { } @@ -43,7 +43,7 @@ DbSe2Factory::~DbSe2Factory() } -TQObject *DbSe2Factory::createObject( TQObject *parent, const char *name, +TQObject *DbSe2Factory::createObject( TQObject *tqparent, const char *name, const char *classname, const TQStringList &) { if(TQCString(classname) != "SearchEngine") @@ -52,7 +52,7 @@ TQObject *DbSe2Factory::createObject( TQObject *parent, const char *name, return 0; } - KDBSearchEngine2 *se = new KDBSearchEngine2(parent,name); + KDBSearchEngine2 *se = new KDBSearchEngine2(tqparent,name); emit objectCreated(se); return se; diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.h b/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.h index 2b70184a..2f1b98ca 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.h +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbse2_factory.h @@ -8,12 +8,13 @@ class KAboutData; class DbSe2Factory : public KLibFactory { Q_OBJECT + TQ_OBJECT public: - DbSe2Factory( TQObject *parent=0, const char *name=0); + DbSe2Factory( TQObject *tqparent=0, const char *name=0); ~DbSe2Factory(); - virtual TQObject *createObject( TQObject *parent=0, const char *name=0, - const char *classname="TQObject", + virtual TQObject *createObject( TQObject *tqparent=0, const char *name=0, + const char *classname=TQOBJECT_OBJECT_NAME_STRING, const TQStringList &args = TQStringList()); static KInstance *instance(); diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/dbseprefwidget.ui b/kbabel/kbabeldict/modules/dbsearchengine2/dbseprefwidget.ui index c233265f..a9820329 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/dbseprefwidget.ui +++ b/kbabel/kbabeldict/modules/dbsearchengine2/dbseprefwidget.ui @@ -1,11 +1,11 @@ DBSearchEnginePref Andrea Rizzi <rizzi@kde.org> - + DBSEPrefWidget - + 0 0 @@ -26,14 +26,14 @@ 6 - + TabWidget6 - + Widget4 @@ -50,7 +50,7 @@ 6 - + ButtonGroup2 @@ -67,7 +67,7 @@ 6 - + allRB @@ -80,7 +80,7 @@ according to the rules defined in tabs <strong> Generic </strong> and <strong>Match</strong> - + slistRB @@ -95,7 +95,7 @@ and <strong>Match</strong> This is the best way to search because the <em>good keys</em> list probably contains all the keys that match with your query. However, it is smaller than the whole database. - + rlistRB @@ -108,7 +108,7 @@ This is the best way to search because the <em>good keys</em> list p - + caseSensitiveCB @@ -119,7 +119,7 @@ This is the best way to search because the <em>good keys</em> list p <qml>If it is checked the search will be case sensitive. It is ignored if you use <em>Return the list of "good keys"</em> search mode. - + normalizeCB @@ -134,7 +134,7 @@ This is the best way to search because the <em>good keys</em> list p It also substitutes groups of more than one space character with only one space character. - + removeContextCB @@ -148,7 +148,7 @@ It also substitutes groups of more than one space character with only one space Remove, if exists, the _:comment - + Layout11 @@ -162,7 +162,7 @@ It also substitutes groups of more than one space character with only one space 6 - + TextLabel3 @@ -182,7 +182,7 @@ It also substitutes groups of more than one space character with only one space 0 - + 0 20 @@ -204,7 +204,7 @@ It also substitutes groups of more than one space character with only one space - + Widget5 @@ -221,7 +221,7 @@ It also substitutes groups of more than one space character with only one space 6 - + ButtonGroup1 @@ -248,7 +248,7 @@ It also substitutes groups of more than one space character with only one space Fixed - + 20 20 @@ -265,14 +265,14 @@ It also substitutes groups of more than one space character with only one space Fixed - + 20 20 - + containedCB @@ -283,18 +283,18 @@ It also substitutes groups of more than one space character with only one space Match if query is contained in database string - + containsCB - Query contains + Query tqcontains Match if query contains the database string - + normalTextRB @@ -308,7 +308,7 @@ It also substitutes groups of more than one space character with only one space Consider the search string as normal text. - + equalCB @@ -335,14 +335,14 @@ It also substitutes groups of more than one space character with only one space Fixed - + 20 20 - + RegExpRB @@ -355,7 +355,7 @@ It also substitutes groups of more than one space character with only one space - + GroupBox3 @@ -387,14 +387,14 @@ If you search for <em>My name is Andrea</em> and you have activated Fixed - + 20 20 - + oneWordSubCB @@ -418,14 +418,14 @@ If you search for <em>My name is Andrea</em> and you have activated Fixed - + 20 20 - + TextLabel1 @@ -433,7 +433,7 @@ If you search for <em>My name is Andrea</em> and you have activated Max number of words in the query: - + twoWordSubSB @@ -447,7 +447,7 @@ If you search for <em>My name is Andrea</em> and you have activated 10 - + twoWordSubCB @@ -461,7 +461,7 @@ If you search for <em>My name is Andrea</em> and you have activated true - + TextLabel2 @@ -469,7 +469,7 @@ If you search for <em>My name is Andrea</em> and you have activated Max number of words in the query: - + Layout7 @@ -483,14 +483,14 @@ If you search for <em>My name is Andrea</em> and you have activated 6 - + TextLabel5_3 [A-Za-z0-9_% - + AlignVCenter|AlignRight @@ -501,7 +501,7 @@ If you search for <em>My name is Andrea</em> and you have activated regExpLE - + TextLabel6_2 @@ -511,7 +511,7 @@ If you search for <em>My name is Andrea</em> and you have activated - + TextLabel4 @@ -519,7 +519,7 @@ If you search for <em>My name is Andrea</em> and you have activated Local characters for regular expressions: - + oneWordSubSB @@ -548,7 +548,7 @@ If you search for <em>My name is Andrea</em> and you have activated - + Widget6 @@ -565,7 +565,7 @@ If you search for <em>My name is Andrea</em> and you have activated 6 - + TextLabel7_2 @@ -578,7 +578,7 @@ If you search for <em>My name is Andrea</em> and you have activated dirInput - + autoAddCB_2 @@ -595,7 +595,7 @@ If you search for <em>My name is Andrea</em> and you have activated Automatically add an entry to the database if a new translation is notified by someone (may be kbabel) - + Layout3 @@ -609,7 +609,7 @@ If you search for <em>My name is Andrea</em> and you have activated 6 - + TextLabel1_4 @@ -617,7 +617,7 @@ If you search for <em>My name is Andrea</em> and you have activated Auto added entry author: - + authorLE @@ -627,7 +627,7 @@ If you search for <em>My name is Andrea</em> and you have activated - + scanFilePB @@ -635,7 +635,7 @@ If you search for <em>My name is Andrea</em> and you have activated Scan Single PO File - + scanPB_2 @@ -643,7 +643,7 @@ If you search for <em>My name is Andrea</em> and you have activated Scan Folder - + scanrecPB @@ -651,7 +651,7 @@ If you search for <em>My name is Andrea</em> and you have activated Scan Folder && Subfolders - + Layout5 @@ -665,7 +665,7 @@ If you search for <em>My name is Andrea</em> and you have activated 6 - + filenameLB @@ -673,7 +673,7 @@ If you search for <em>My name is Andrea</em> and you have activated Scanning file: - + entriesLB @@ -683,7 +683,7 @@ If you search for <em>My name is Andrea</em> and you have activated - + Layout4 @@ -697,7 +697,7 @@ If you search for <em>My name is Andrea</em> and you have activated 6 - + processPB @@ -714,7 +714,7 @@ If you search for <em>My name is Andrea</em> and you have activated false - + TextLabel1_3 @@ -722,7 +722,7 @@ If you search for <em>My name is Andrea</em> and you have activated Total progress: - + TextLabel3_3 @@ -730,7 +730,7 @@ If you search for <em>My name is Andrea</em> and you have activated Processing file: - + totalPB @@ -744,7 +744,7 @@ If you search for <em>My name is Andrea</em> and you have activated true - + loadingPB @@ -758,7 +758,7 @@ If you search for <em>My name is Andrea</em> and you have activated true - + TextLabel2_3 @@ -768,7 +768,7 @@ If you search for <em>My name is Andrea</em> and you have activated - + exportPB @@ -779,7 +779,7 @@ If you search for <em>My name is Andrea</em> and you have activated Export... - + statPB @@ -790,7 +790,7 @@ If you search for <em>My name is Andrea</em> and you have activated Statistics - + repeatPB @@ -800,7 +800,7 @@ If you search for <em>My name is Andrea</em> and you have activated - + tab @@ -817,7 +817,7 @@ If you search for <em>My name is Andrea</em> and you have activated 6 - + GroupBox4 @@ -841,7 +841,7 @@ Finally you can set the maximum number of entries in the list. 6 - + TextLabel3_2 @@ -852,7 +852,7 @@ Finally you can set the maximum number of entries in the list. RichText - + thresholdSL @@ -866,7 +866,7 @@ Finally you can set the maximum number of entries in the list. Horizontal - + SpinBox5 @@ -880,7 +880,7 @@ Finally you can set the maximum number of entries in the list. 50 - + TextLabel2_2 @@ -888,7 +888,7 @@ Finally you can set the maximum number of entries in the list. Minimum number of query words in the key (%): - + maxSB @@ -899,7 +899,7 @@ Finally you can set the maximum number of entries in the list. 30 - + SpinBox6 @@ -913,7 +913,7 @@ Finally you can set the maximum number of entries in the list. 50 - + TextLabel4_2 @@ -921,7 +921,7 @@ Finally you can set the maximum number of entries in the list. Max list length: - + thresholdOrigSL @@ -937,7 +937,7 @@ Finally you can set the maximum number of entries in the list. - + GroupBox3_2 @@ -954,7 +954,7 @@ Finally you can set the maximum number of entries in the list. 6 - + TextLabel1_2 @@ -962,7 +962,7 @@ Finally you can set the maximum number of entries in the list. Discard words more frequent than: - + freqSB @@ -979,7 +979,7 @@ Finally you can set the maximum number of entries in the list. 100 - + nothingCB @@ -1035,5 +1035,5 @@ Finally you can set the maximum number of entries in the list. klocale.h kseparator.h - + diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.cpp b/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.cpp index 76aef878..ba16327c 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.cpp @@ -15,17 +15,17 @@ #include "dbse2.h" #include "preferenceswidget.h" -KDB2PreferencesWidget::KDB2PreferencesWidget(TQWidget *parent, const char* name) - : PrefWidget(parent,name) +KDB2PreferencesWidget::KDB2PreferencesWidget(TQWidget *tqparent, const char* name) + : PrefWidget(tqparent,name) { - TQVBoxLayout *layout = new TQVBoxLayout(this); + TQVBoxLayout *tqlayout = new TQVBoxLayout(this); // TQLabel *label = new TQLabel(i18n("Settings for KDE Database Search Engine"),this); -// layout->addWidget(label); +// tqlayout->addWidget(label); dbpw = new DBSearchEnginePrefWidget(this); dbpw->dbDirectory->setMode(KFile::Directory | KFile::LocalOnly); dbpw->show(); - layout->addWidget(dbpw); + tqlayout->addWidget(dbpw); setMinimumSize(300,300); standard(); diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.h b/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.h index 1f706902..68e283bd 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.h +++ b/kbabel/kbabeldict/modules/dbsearchengine2/preferenceswidget.h @@ -7,9 +7,10 @@ class KDB2PreferencesWidget : public PrefWidget { Q_OBJECT + TQ_OBJECT public: - KDB2PreferencesWidget(TQWidget *parent=0, const char* name=0); + KDB2PreferencesWidget(TQWidget *tqparent=0, const char* name=0); virtual ~KDB2PreferencesWidget(); virtual void apply(); diff --git a/kbabel/kbabeldict/modules/dbsearchengine2/sourcedialog.ui b/kbabel/kbabeldict/modules/dbsearchengine2/sourcedialog.ui index 3f4030a0..9447f794 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine2/sourcedialog.ui +++ b/kbabel/kbabeldict/modules/dbsearchengine2/sourcedialog.ui @@ -1,10 +1,10 @@ SourceDialog - + SourceDialog - + 0 0 @@ -29,7 +29,7 @@ Expanding - + 40 20 @@ -52,18 +52,18 @@ &Cancel - + groupBox1 Additional Informations - + textLabel6 - + 11 76 @@ -72,14 +72,14 @@ - Status: + tqStatus: projectName - + 125 22 @@ -92,7 +92,7 @@ projectKeywords - + 125 49 @@ -105,7 +105,7 @@ status - + 125 76 @@ -117,11 +117,11 @@ true - + textLabel4 - + 11 22 @@ -133,11 +133,11 @@ Project name: - + textLabel5 - + 11 49 @@ -150,7 +150,7 @@ - + groupBox2 @@ -186,7 +186,7 @@ type - + textLabel1 @@ -199,7 +199,7 @@ sourceLocation - + textLabel3 @@ -215,7 +215,7 @@ Setup Filter... - + textLabel2 @@ -223,7 +223,7 @@ Location: - + useFilter @@ -251,7 +251,7 @@ reject() - + kpushbutton.h kpushbutton.h -- cgit v1.2.1