From 4ae0c208b66e0f7954e194384464fe2d0a2c56dd Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:51:49 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1157652 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kbabel/common/diff.cpp | 56 +++++++++++++++++++++++++------------------------- 1 file changed, 28 insertions(+), 28 deletions(-) (limited to 'kbabel/common/diff.cpp') diff --git a/kbabel/common/diff.cpp b/kbabel/common/diff.cpp index 7a54e4d3..455a26f1 100644 --- a/kbabel/common/diff.cpp +++ b/kbabel/common/diff.cpp @@ -37,7 +37,7 @@ #include -LCSprinter::LCSprinter(const QStringList &s_1, const QStringList &s_2, QValueVector *b_, const uint nT_, uint index):s1(s_1),s2(s_2),b(b_),nT(nT_) +LCSprinter::LCSprinter(const TQStringList &s_1, const TQStringList &s_2, TQValueVector *b_, const uint nT_, uint index):s1(s_1),s2(s_2),b(b_),nT(nT_) { it1=s1.begin(); it2=s2.begin(); @@ -93,24 +93,24 @@ void LCSprinter::printLCS(uint index) -QString wordDiff(const QString& str1, const QString& str2) +TQString wordDiff(const TQString& str1, const TQString& str2) { //separate punctuation marks etc from words as _only_ they may have changed - QStringList s1, s2; + TQStringList s1, s2; uint i=0; uint j=0; uint l1=str1.length(); uint l2=str2.length(); - QString temp; + TQString temp; temp.reserve(16); /* while ( i b(mT*nT, NOTHING); - QValueVector c(mT*nT, 0); + TQValueVector b(mT*nT, NOTHING); + TQValueVector c(mT*nT, 0); // calculate the LCS b[0] = FINAL; uint index_cache; - QStringList::iterator it1, it2; + TQStringList::iterator it1, it2; for (i=1, it1 = s1.begin(); i -QString Diff::charDiff(QString s1, QString s2) +TQString Diff::charDiff(TQString s1, TQString s2) { int n = 3; s1+="xxx"; @@ -305,7 +305,7 @@ QString Diff::charDiff(QString s1, QString s2) int pos2=0; int len1 = s1.length(); int len2 = s2.length(); - QString resultstr; + TQString resultstr; bool found = true; bool swap = false; while (found && pos1+n < len1 && pos2+n < len2) @@ -346,7 +346,7 @@ QString Diff::charDiff(QString s1, QString s2) pos1 = pos2; pos2 = pos; - QString s = s1; + TQString s = s1; s1 = s2; s2 = s; @@ -375,7 +375,7 @@ QString Diff::charDiff(QString s1, QString s2) pos1 = pos2; pos2 = pos; - QString s = s1; + TQString s = s1; s1 = s2; s2 = s; @@ -427,7 +427,7 @@ QString Diff::charDiff(QString s1, QString s2) pos1 = pos2; pos2 = pos; - QString s = s1; + TQString s = s1; s1 = s2; s2 = s; -- cgit v1.2.1