summaryrefslogtreecommitdiffstats
path: root/libkmime/kmime_util.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libkmime/kmime_util.cpp')
-rw-r--r--libkmime/kmime_util.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/libkmime/kmime_util.cpp b/libkmime/kmime_util.cpp
index 6fea9fc84..624e0dae3 100644
--- a/libkmime/kmime_util.cpp
+++ b/libkmime/kmime_util.cpp
@@ -48,7 +48,7 @@ TQStrIList l_anguageCache;
const char* cachedCharset(const TQCString &name)
{
- int idx=c_harsetCache.tqfind(name.data());
+ int idx=c_harsetCache.find(name.data());
if(idx>-1)
return c_harsetCache.at(idx);
@@ -59,7 +59,7 @@ const char* cachedCharset(const TQCString &name)
const char* cachedLanguage(const TQCString &name)
{
- int idx=l_anguageCache.tqfind(name.data());
+ int idx=l_anguageCache.find(name.data());
if(idx>-1)
return l_anguageCache.at(idx);
@@ -134,7 +134,7 @@ TQString decodeRFC2047String(const TQCString &src, const char **usedCS,
const int maxLen=400;
int i;
- if(src.tqfind("=?") < 0)
+ if(src.find("=?") < 0)
result = src.copy();
else {
result.truncate(src.length());
@@ -262,7 +262,7 @@ TQCString encodeRFC2047String(const TQString &src, const char *charset,
codec=KGlobal::charsets()->codecForName(usedCS, ok);
}
- if (usedCS.tqfind("8859-")>=0) // use "B"-Encoding for non iso-8859-x charsets
+ if (usedCS.find("8859-")>=0) // use "B"-Encoding for non iso-8859-x charsets
useTQEncoding=true;
encoded8Bit=codec->fromUnicode(src);
@@ -377,7 +377,7 @@ TQCString extractHeader(const TQCString &src, const char *name)
pos1 = 0;
} else {
n.prepend("\n");
- pos1 = src.tqfind(n.data(),0,false);
+ pos1 = src.find(n.data(),0,false);
}
if (pos1>-1) { //there is a header with the given name
@@ -389,7 +389,7 @@ TQCString extractHeader(const TQCString &src, const char *name)
if (src[pos2]!='\n') { // check if the header is not empty
while(1) {
- pos2=src.tqfind("\n", pos2+1);
+ pos2=src.find("\n", pos2+1);
if(pos2==-1 || pos2==len || ( src[pos2+1]!=' ' && src[pos2+1]!='\t') ) //break if we reach the end of the string, honor folded lines
break;
else
@@ -402,7 +402,7 @@ TQCString extractHeader(const TQCString &src, const char *name)
if (!folded)
return src.mid(pos1, pos2-pos1);
else
- return (src.mid(pos1, pos2-pos1).tqreplace(TQRegExp("\\s*\\n\\s*")," "));
+ return (src.mid(pos1, pos2-pos1).replace(TQRegExp("\\s*\\n\\s*")," "));
}
else {
return TQCString(0); //header not found
@@ -413,7 +413,7 @@ TQCString extractHeader(const TQCString &src, const char *name)
TQCString CRLFtoLF(const TQCString &s)
{
TQCString ret=s.copy();
- ret.tqreplace(TQRegExp("\\r\\n"), "\n");
+ ret.replace(TQRegExp("\\r\\n"), "\n");
return ret;
}
@@ -421,7 +421,7 @@ TQCString CRLFtoLF(const TQCString &s)
TQCString CRLFtoLF(const char *s)
{
TQCString ret=s;
- ret.tqreplace(TQRegExp("\\r\\n"), "\n");
+ ret.replace(TQRegExp("\\r\\n"), "\n");
return ret;
}
@@ -429,7 +429,7 @@ TQCString CRLFtoLF(const char *s)
TQCString LFtoCRLF(const TQCString &s)
{
TQCString ret=s.copy();
- ret.tqreplace(TQRegExp("\\n"), "\r\n");
+ ret.replace(TQRegExp("\\n"), "\r\n");
return ret;
}
@@ -559,13 +559,13 @@ DateFormatter::custom(time_t t) const
if ( mCustomFormat.isEmpty() )
return TQString();
- int z = mCustomFormat.tqfind("Z");
+ int z = mCustomFormat.find("Z");
TQDateTime d;
TQString ret = mCustomFormat;
d.setTime_t(t);
if ( z != -1 ) {
- ret.tqreplace(z,1,zone(t));
+ ret.replace(z,1,zone(t));
}
ret = d.toString(ret);