summaryrefslogtreecommitdiffstats
path: root/poxml/po2xml.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
commit0813b39aed2cf4c84157a22c4c9594336d93d412 (patch)
tree0f6157f9c9ecc6ed26cb98f058219a8021d3f4a6 /poxml/po2xml.cpp
parent35dc58791106d7a1864264063df5f3ee3f1f0f15 (diff)
downloadtdesdk-0813b39aed2cf4c84157a22c4c9594336d93d412.tar.gz
tdesdk-0813b39aed2cf4c84157a22c4c9594336d93d412.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'poxml/po2xml.cpp')
-rw-r--r--poxml/po2xml.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/poxml/po2xml.cpp b/poxml/po2xml.cpp
index 314b0b5b..c30a340f 100644
--- a/poxml/po2xml.cpp
+++ b/poxml/po2xml.cpp
@@ -19,7 +19,7 @@ TQString translate(TQString xml, TQString orig, TQString translation)
TQString prefix;
while (xml.at(0) == '<' && orig.at(0) != '<') {
// a XML tag as prefix
- int index = xml.tqfind('>');
+ int index = xml.find('>');
assert(index != -1);
index++;
while (xml.at(index) == ' ')
@@ -28,13 +28,13 @@ TQString translate(TQString xml, TQString orig, TQString translation)
xml = xml.mid(index, xml.length());
}
- int index = xml.tqfind(orig);
+ int index = xml.find(orig);
if (index == -1) {
- qWarning("can't tqfind\n%s\nin\n%s", orig.latin1(), xml.latin1());
+ qWarning("can't find\n%s\nin\n%s", orig.latin1(), xml.latin1());
exit(1);
}
if (!translation.isEmpty())
- xml.tqreplace(index, orig.length(), translation);
+ xml.replace(index, orig.length(), translation);
return prefix + xml;
}
@@ -65,7 +65,7 @@ int main( int argc, char **argv )
{
TQString msgstr;
TQString msgid = escapePO((*it).msgid);
- if ((*it).comment.tqfind("fuzzy") < 0)
+ if ((*it).comment.find("fuzzy") < 0)
msgstr = escapePO((*it).msgstr);
#ifdef POXML_DEBUG
@@ -88,7 +88,7 @@ int main( int argc, char **argv )
line_offsets.append(0);
int index = 0;
while (true) {
- index = xml_text.tqfind('\n', index) + 1;
+ index = xml_text.find('\n', index) + 1;
if (index <= 0)
break;
line_offsets.append(index);
@@ -137,7 +137,7 @@ int main( int argc, char **argv )
TQString xml = xml_text.mid(start_pos, end_pos - start_pos);
int index = 0;
while (true) {
- index = xml.tqfind("<!--");
+ index = xml.find("<!--");
if (index == -1)
break;
int end_index = index + 4;
@@ -147,13 +147,13 @@ int main( int argc, char **argv )
{
end_index++;
}
- xml.tqreplace(index, end_index + 1 - index, " ");
+ xml.replace(index, end_index + 1 - index, " ");
index = end_index;
}
StructureParser::descape(xml);
TQString descaped = StructureParser::descapeLiterals((*it).msgid);
- if (translations.tqcontains(descaped))
+ if (translations.contains(descaped))
descaped = translations[descaped];
#ifdef POXML_DEBUG
@@ -236,21 +236,21 @@ int main( int argc, char **argv )
ts << xml_text.mid(old_pos);
- output.tqreplace(TQRegExp("<trans_comment\\s*>"), "");
- output.tqreplace(TQRegExp("</trans_comment\\s*>"), "");
+ output.replace(TQRegExp("<trans_comment\\s*>"), "");
+ output.replace(TQRegExp("</trans_comment\\s*>"), "");
StructureParser::removeEmptyTags(output);
index = 0;
while (true) {
- index = output.tqfind(TQRegExp(">[^\n]"), index );
+ index = output.find(TQRegExp(">[^\n]"), index );
if ( index == -1 )
break;
if ( output.at( index - 1 ) == '/' || output.at( index - 1 ) == '-' ||
output.at( index - 1 ) == ']' || output.at( index - 1 ) == '?' )
index = index + 1;
else {
- output.tqreplace( index, 1, "\n>" );
+ output.replace( index, 1, "\n>" );
index = index + 2;
}
}