summaryrefslogtreecommitdiffstats
path: root/libkmime
diff options
context:
space:
mode:
Diffstat (limited to 'libkmime')
-rw-r--r--libkmime/CLASSTREE.bodyparts2
-rw-r--r--libkmime/kmime_content.cpp18
-rw-r--r--libkmime/kmime_content.h2
-rw-r--r--libkmime/kmime_header_parsing.cpp20
-rw-r--r--libkmime/kmime_headers.cpp20
-rw-r--r--libkmime/kmime_parsers.cpp4
-rw-r--r--libkmime/kmime_util.cpp10
-rw-r--r--libkmime/tests/test_dates.cpp10
8 files changed, 43 insertions, 43 deletions
diff --git a/libkmime/CLASSTREE.bodyparts b/libkmime/CLASSTREE.bodyparts
index eeaa7726a..5952c2082 100644
--- a/libkmime/CLASSTREE.bodyparts
+++ b/libkmime/CLASSTREE.bodyparts
@@ -15,7 +15,7 @@
+ Message::RFC822
+ Message::Partial
+ Message::ExternalBody
- + Message::DeliveryStatus
+ + Message::DeliverytqStatus
+ GText
+ Text::Plain
+ Text::Enriched
diff --git a/libkmime/kmime_content.cpp b/libkmime/kmime_content.cpp
index b49ccf4ea..eb8deb8a2 100644
--- a/libkmime/kmime_content.cpp
+++ b/libkmime/kmime_content.cpp
@@ -22,7 +22,7 @@
#include <klocale.h>
#include <kdebug.h>
-#include <textcodec.h>
+#include <tqtextcodec.h>
using namespace KMime;
@@ -439,25 +439,25 @@ void Content::decodedText(TQStringList &l, bool trimText,
if(!decodeText()) //this is not a text content !!
return;
- TQString unicode;
+ TQString tqunicode;
bool ok=true;
TQTextCodec *codec=KGlobal::charsets()->codecForName(contentType()->charset(),ok);
- unicode=codec->toUnicode(b_ody.data(), b_ody.length());
+ tqunicode=codec->toUnicode(b_ody.data(), b_ody.length());
if (trimText && removeTrailingNewlines) {
int i;
- for (i=unicode.length()-1; i>=0; i--)
- if (!unicode[i].isSpace())
+ for (i=tqunicode.length()-1; i>=0; i--)
+ if (!tqunicode[i].isSpace())
break;
- unicode.truncate(i+1);
+ tqunicode.truncate(i+1);
} else {
- if (unicode.right(1)=="\n")
- unicode.truncate(unicode.length()-1); // remove trailing new-line
+ if (tqunicode.right(1)=="\n")
+ tqunicode.truncate(tqunicode.length()-1); // remove trailing new-line
}
- l=TQStringList::split('\n', unicode, true); //split the string at linebreaks
+ l=TQStringList::split('\n', tqunicode, true); //split the string at linebreaks
}
diff --git a/libkmime/kmime_content.h b/libkmime/kmime_content.h
index b7f56e6fe..1d2aac2d3 100644
--- a/libkmime/kmime_content.h
+++ b/libkmime/kmime_content.h
@@ -29,7 +29,7 @@ class KMime::Headers::List;
#include "kmime_util.h"
#include "kmime_headers.h"
-#include <textstream.h>
+#include <tqtextstream.h>
namespace KMime {
diff --git a/libkmime/kmime_header_parsing.cpp b/libkmime/kmime_header_parsing.cpp
index adbf72fc1..59957f10b 100644
--- a/libkmime/kmime_header_parsing.cpp
+++ b/libkmime/kmime_header_parsing.cpp
@@ -39,7 +39,7 @@
#include <kglobal.h>
#include <kcharsets.h>
-#include <textcodec.h>
+#include <tqtextcodec.h>
#include <tqmap.h>
#include <tqcstring.h>
#include <tqstringlist.h>
@@ -256,7 +256,7 @@ bool parseAtom( const char * & scursor, const char * const send,
TQPair<const char*,int> maybeResult;
if ( parseAtom( scursor, send, maybeResult, allow8Bit ) ) {
- result += TQString::fromLatin1( maybeResult.first, maybeResult.second );
+ result += TQString::tqfromLatin1( maybeResult.first, maybeResult.second );
return true;
}
@@ -296,7 +296,7 @@ bool parseToken( const char * & scursor, const char * const send,
TQPair<const char*,int> maybeResult;
if ( parseToken( scursor, send, maybeResult, allow8Bit ) ) {
- result += TQString::fromLatin1( maybeResult.first, maybeResult.second );
+ result += TQString::tqfromLatin1( maybeResult.first, maybeResult.second );
return true;
}
@@ -1065,9 +1065,9 @@ bool parseAddressList( const char* & scursor, const char * const send,
}
-static TQString asterisk = TQString::fromLatin1("*0*",1);
-static TQString asteriskZero = TQString::fromLatin1("*0*",2);
-//static TQString asteriskZeroAsterisk = TQString::fromLatin1("*0*",3);
+static TQString asterisk = TQString::tqfromLatin1("*0*",1);
+static TQString asteriskZero = TQString::tqfromLatin1("*0*",2);
+//static TQString asteriskZeroAsterisk = TQString::tqfromLatin1("*0*",3);
bool parseParameter( const char* & scursor, const char * const send,
TQPair<TQString,TQStringOrTQPair> & result, bool isCRLF ) {
@@ -1223,7 +1223,7 @@ static void decodeRFC2231Value( Codec* & rfc2231Codec,
// take the whole value to be in latin-1:
KMIME_WARN << "No charset in extended-initial-value. "
"Assuming \"iso-8859-1\"." << endl;
- value += TQString::fromLatin1( decBegin, source.second );
+ value += TQString::tqfromLatin1( decBegin, source.second );
return;
}
@@ -1263,7 +1263,7 @@ static void decodeRFC2231Value( Codec* & rfc2231Codec,
}
if ( !textcodec ) {
- value += TQString::fromLatin1( decCursor, decEnd - decCursor );
+ value += TQString::tqfromLatin1( decCursor, decEnd - decCursor );
return;
}
@@ -1348,7 +1348,7 @@ bool parseParameterList( const char* & scursor, const char * const send,
} else {
// not encoded.
if ( (*it).qpair.first )
- value += TQString::fromLatin1( (*it).qpair.first, (*it).qpair.second );
+ value += TQString::tqfromLatin1( (*it).qpair.first, (*it).qpair.second );
else
value += (*it).qstring;
}
@@ -1377,7 +1377,7 @@ bool parseParameterList( const char* & scursor, const char * const send,
} else {
// not encoded
if ( (*it).qpair.first )
- value += TQString::fromLatin1( (*it).qpair.first, (*it).qpair.second );
+ value += TQString::tqfromLatin1( (*it).qpair.first, (*it).qpair.second );
else
value += (*it).qstring;
}
diff --git a/libkmime/kmime_headers.cpp b/libkmime/kmime_headers.cpp
index e939d8f40..85d4c4049 100644
--- a/libkmime/kmime_headers.cpp
+++ b/libkmime/kmime_headers.cpp
@@ -25,7 +25,7 @@
#include "kqcstringsplitter.h"
-#include <textcodec.h>
+#include <tqtextcodec.h>
#include <tqstring.h>
#include <tqcstring.h>
#include <tqstringlist.h>
@@ -529,7 +529,7 @@ void MessageID::fromUnicodeString(const TQString &s, const TQCString&)
TQString MessageID::asUnicodeString()
{
- return TQString::fromLatin1(m_id);
+ return TQString::tqfromLatin1(m_id);
}
@@ -567,7 +567,7 @@ void Control::fromUnicodeString(const TQString &s, const TQCString&)
TQString Control::asUnicodeString()
{
- return TQString::fromLatin1(c_trlMsg);
+ return TQString::tqfromLatin1(c_trlMsg);
}
//-----</Control>------------------------------
@@ -797,7 +797,7 @@ void Date::fromUnicodeString(const TQString &s, const TQCString&)
TQString Date::asUnicodeString()
{
- return TQString::fromLatin1(as7BitString(false));
+ return TQString::tqfromLatin1(as7BitString(false));
}
@@ -1075,7 +1075,7 @@ void References::fromUnicodeString(const TQString &s, const TQCString&)
TQString References::asUnicodeString()
{
- return TQString::fromLatin1(r_ef);
+ return TQString::tqfromLatin1(r_ef);
}
@@ -1174,7 +1174,7 @@ void References::append(const TQCString &s)
for (int i=1;i<=3;i++) { // include the last three ids
if (!lst.isEmpty()) {
temp = lst.last();
- r_ef.insert(insPos,(TQString(" %1").arg(temp)).latin1());
+ r_ef.insert(insPos,(TQString(" %1").tqarg(temp)).latin1());
lst.remove(temp);
} else
break;
@@ -1183,7 +1183,7 @@ void References::append(const TQCString &s)
while (!lst.isEmpty()) { // now insert the rest, up to 1000 characters
temp = lst.last();
if ((15+r_ef.length()+temp.length())<1000) {
- r_ef.insert(insPos,(TQString(" %1").arg(temp)).latin1());
+ r_ef.insert(insPos,(TQString(" %1").tqarg(temp)).latin1());
lst.remove(temp);
} else
return;
@@ -1221,7 +1221,7 @@ void UserAgent::fromUnicodeString(const TQString &s, const TQCString&)
TQString UserAgent::asUnicodeString()
{
- return TQString::fromLatin1(u_agent);
+ return TQString::tqfromLatin1(u_agent);
}
//-----</UserAgent>----------------------------
@@ -1268,7 +1268,7 @@ void ContentType::fromUnicodeString(const TQString &s, const TQCString&)
TQString ContentType::asUnicodeString()
{
- return TQString::fromLatin1(as7BitString(false));
+ return TQString::tqfromLatin1(as7BitString(false));
}
@@ -1544,7 +1544,7 @@ void CTEncoding::fromUnicodeString(const TQString &s, const TQCString&)
TQString CTEncoding::asUnicodeString()
{
- return TQString::fromLatin1(as7BitString(false));
+ return TQString::tqfromLatin1(as7BitString(false));
}
//-----</CTEncoding>---------------------------
diff --git a/libkmime/kmime_parsers.cpp b/libkmime/kmime_parsers.cpp
index 202ce4bf4..bd07c2375 100644
--- a/libkmime/kmime_parsers.cpp
+++ b/libkmime/kmime_parsers.cpp
@@ -391,7 +391,7 @@ bool YENCEncoded::parse()
ch+=256;
if (totalSize>=yencSize)
break;
- binary.at(totalSize++)=ch;
+ binary.tqat(totalSize++)=ch;
lineLength++;
}
else
@@ -404,7 +404,7 @@ bool YENCEncoded::parse()
ch+=256;
if (totalSize>=yencSize)
break;
- binary.at(totalSize++)=ch;
+ binary.tqat(totalSize++)=ch;
lineLength++;
pos++;
}
diff --git a/libkmime/kmime_util.cpp b/libkmime/kmime_util.cpp
index a31008d3d..8110227e5 100644
--- a/libkmime/kmime_util.cpp
+++ b/libkmime/kmime_util.cpp
@@ -29,7 +29,7 @@
#include <kcalendarsystem.h>
#endif
-#include <textcodec.h>
+#include <tqtextcodec.h>
#include <tqstrlist.h> // for TQStrIList
#include <tqregexp.h>
#include <tqdatetime.h>
@@ -72,7 +72,7 @@ bool isUsAscii(const TQString &s)
{
uint sLength = s.length();
for (uint i=0; i<sLength; i++)
- if (s.at(i).latin1()<=0) // c==0: non-latin1, c<0: non-us-ascii
+ if (s.tqat(i).latin1()<=0) // c==0: non-latin1, c<0: non-us-ascii
return false;
return true;
@@ -683,14 +683,14 @@ DateFormatter::fancy(time_t otime) const
if ( diff < 24 * 60 * 60 ) {
if ( old.date().year() == mDate.date().year() &&
old.date().dayOfYear() == mDate.date().dayOfYear() )
- return i18n( "Today %1" ).arg( locale->
+ return i18n( "Today %1" ).tqarg( locale->
formatTime( old.time(), true ) );
}
if ( diff < 2 * 24 * 60 * 60 ) {
TQDateTime yesterday( mDate.addDays( -1 ) );
if ( old.date().year() == yesterday.date().year() &&
old.date().dayOfYear() == yesterday.date().dayOfYear() )
- return i18n( "Yesterday %1" ).arg( locale->
+ return i18n( "Yesterday %1" ).tqarg( locale->
formatTime( old.time(), true) );
}
for ( int i = 3; i < 7; i++ )
@@ -739,7 +739,7 @@ DateFormatter::localized(time_t otime, bool shortFormat, bool includeSecs,
TQString
DateFormatter::cTime(time_t otime) const
{
- return TQString::fromLatin1( ctime( &otime ) ).stripWhiteSpace() ;
+ return TQString::tqfromLatin1( ctime( &otime ) ).stripWhiteSpace() ;
}
TQString
diff --git a/libkmime/tests/test_dates.cpp b/libkmime/tests/test_dates.cpp
index 7087a01a6..e3a40f812 100644
--- a/libkmime/tests/test_dates.cpp
+++ b/libkmime/tests/test_dates.cpp
@@ -80,14 +80,14 @@ main()
"Z MMMM dddd yyyy") <<endl;
t.setFormat(DateFormatter::Fancy);
kdDebug()<<"TQDateTime taking: (dates as in first test)"<<endl;
- kdDebug()<<"\tFancy : \t"<<t.dateString((TQDateTime::currentDateTime()))<<endl;
+ kdDebug()<<"\tFancy : \t"<<t.dateString((TQDateTime::tqcurrentDateTime()))<<endl;
t.setFormat(DateFormatter::Localized);
- kdDebug()<<"\tLocalized : \t"<<t.dateString(TQDateTime::currentDateTime())<<endl;
+ kdDebug()<<"\tLocalized : \t"<<t.dateString(TQDateTime::tqcurrentDateTime())<<endl;
t.setFormat(DateFormatter::CTime);
- kdDebug()<<"\tCTime : \t"<<t.dateString(TQDateTime::currentDateTime())<<endl;
+ kdDebug()<<"\tCTime : \t"<<t.dateString(TQDateTime::tqcurrentDateTime())<<endl;
t.setFormat(DateFormatter::Iso);
- kdDebug()<<"\tIso : \t"<<t.dateString(TQDateTime::currentDateTime())<<endl;
+ kdDebug()<<"\tIso : \t"<<t.dateString(TQDateTime::tqcurrentDateTime())<<endl;
t.setCustomFormat("MMMM d dddd yyyy Z");
- kdDebug()<<"\tCustom : \t"<<t.dateString(TQDateTime::currentDateTime())<<endl;
+ kdDebug()<<"\tCustom : \t"<<t.dateString(TQDateTime::tqcurrentDateTime())<<endl;
}