summaryrefslogtreecommitdiffstats
path: root/kmail/kmmsgpart.h
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:53:50 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:53:50 +0000
commit7be55ffa061c026e35e2d6a0effe1161ddb0d41f (patch)
tree8474f9b444b2756228600050f07a7ff25de532b2 /kmail/kmmsgpart.h
parentf587f20a6d09f1729dd0a8c1cd8ee0110aec7451 (diff)
downloadtdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.tar.gz
tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kmail/kmmsgpart.h')
-rw-r--r--kmail/kmmsgpart.h130
1 files changed, 65 insertions, 65 deletions
diff --git a/kmail/kmmsgpart.h b/kmail/kmmsgpart.h
index a28238177..ce3245c89 100644
--- a/kmail/kmmsgpart.h
+++ b/kmail/kmmsgpart.h
@@ -22,9 +22,9 @@
#include <kiconloader.h>
-#include <qstring.h>
-#include <qcstring.h>
-#include <qdict.h>
+#include <tqstring.h>
+#include <tqcstring.h>
+#include <tqdict.h>
template <typename T>
class QValueList;
@@ -35,7 +35,7 @@ class KMMessagePart
{
public:
KMMessagePart();
- KMMessagePart( QDataStream & stream );
+ KMMessagePart( TQDataStream & stream );
virtual ~KMMessagePart();
/** Reset to text/plain with 7bit cte and clear all other properties. */
@@ -46,30 +46,30 @@ public:
void duplicate( const KMMessagePart & msgPart );
/** Get or set the message body */
- QCString body(void) const;
- void setBody(const QCString &aStr);
+ TQCString body(void) const;
+ void setBody(const TQCString &aStr);
DwString dwBody() const;
void setBody(const DwString &aStr);
// warning, doesn't detach from 'arr'
- void setBody(const QByteArray &arr);
+ void setBody(const TQByteArray &arr);
/** Sets this body part's content to @p str. @p str is subject to
automatic charset and CTE detection.
**/
- void setBodyFromUnicode( const QString & str );
+ void setBodyFromUnicode( const TQString & str );
/** Returns the body part decoded to unicode.
**/
- QString bodyToUnicode(const QTextCodec* codec=0) const;
+ TQString bodyToUnicode(const TQTextCodec* codec=0) const;
/** Returns body as decoded string. Assumes that content-transfer-encoding
contains the correct encoding. This routine is meant for binary data.
No trailing 0 is appended. */
- QByteArray bodyDecodedBinary(void) const;
+ TQByteArray bodyDecodedBinary(void) const;
/** Returns body as decoded string. Assumes that content-transfer-encoding
contains the correct encoding. This routine is meant for text strings! */
- QCString bodyDecoded(void) const;
+ TQCString bodyDecoded(void) const;
/** Sets body, encoded in the best fitting
content-transfer-encoding, which is determined by character
@@ -80,13 +80,13 @@ public:
@param allow8Bit whether "8bit" is allowed as cte.
@param willBeSigned whether "7bit"/"8bit" is allowed as cte according to RFC 3156
*/
- void setBodyAndGuessCte(const QByteArray& aBuf,
- QValueList<int>& allowedCte,
+ void setBodyAndGuessCte(const TQByteArray& aBuf,
+ TQValueList<int>& allowedCte,
bool allow8Bit = false,
bool willBeSigned = false);
/** Same for text */
- void setBodyAndGuessCte(const QCString& aBuf,
- QValueList<int>& allowedCte,
+ void setBodyAndGuessCte(const TQCString& aBuf,
+ TQValueList<int>& allowedCte,
bool allow8Bit = false,
bool willBeSigned = false);
@@ -94,22 +94,22 @@ public:
BEWARE: The entire aStr is used including trailing 0 of text strings!
This version is faster than setBodyEncoded, no duplication necessary.
*/
- void setBodyEncodedBinary(const QByteArray& aStr);
+ void setBodyEncodedBinary(const TQByteArray& aStr);
/** Sets body, encoded according to the content-transfer-encoding.
This one is for text strings, the trailing 0 is not used.
For speed reasons, prefer setBodyEncodedBinary.
- When possible (the QCString isn't used afterwards), change setBodyEncoded(myQCString) into:
+ When possible (the TQCString isn't used afterwards), change setBodyEncoded(myQCString) into:
setBodyEncodedBinary(byteArrayFromQCStringNoDetach(myQCString));
*/
- void setBodyEncoded(const QCString& aStr);
+ void setBodyEncoded(const TQCString& aStr);
/** Set a full message string as the body of the message part,
disallowing anything but 7bit or 8bit encoding.
(RFC 1521 section 7.3)
*/
- void setMessageBody( const QByteArray & aBuf );
+ void setMessageBody( const TQByteArray & aBuf );
/** Returns decoded length of body. */
int decodedSize(void) const;
@@ -117,24 +117,24 @@ public:
/** Get or set the 'Content-Type' header field
The member functions that involve enumerated types (ints)
will work only for well-known types or subtypes. */
- QCString originalContentTypeStr(void) const { return mOriginalContentTypeStr; }
- void setOriginalContentTypeStr( const QCString& txt )
+ TQCString originalContentTypeStr(void) const { return mOriginalContentTypeStr; }
+ void setOriginalContentTypeStr( const TQCString& txt )
{
mOriginalContentTypeStr = txt;
}
- QCString typeStr() const { return mType; }
- void setTypeStr( const QCString & aStr ) { mType = aStr; }
+ TQCString typeStr() const { return mType; }
+ void setTypeStr( const TQCString & aStr ) { mType = aStr; }
int type() const;
void setType(int aType);
/** Subtype */
- QCString subtypeStr() const { return mSubtype; }
- void setSubtypeStr( const QCString & aStr ) { mSubtype = aStr; }
+ TQCString subtypeStr() const { return mSubtype; }
+ void setSubtypeStr( const TQCString & aStr ) { mSubtype = aStr; }
int subtype() const;
void setSubtype(int aSubtype);
/** Content-Id */
- QCString contentId() const { return mContentId; }
- void setContentId( const QCString & aStr ) { mContentId = aStr; }
+ TQCString contentId() const { return mContentId; }
+ void setContentId( const TQCString & aStr ) { mContentId = aStr; }
/** Set the 'Content-Type' by mime-magic from the contents of the body.
If autoDecode is TRUE the decoded body will be used for mime type
@@ -143,15 +143,15 @@ public:
/** Get or set a custom content type parameter, consisting of an attribute
name and a corresponding value. */
- QCString parameterAttribute(void) const;
- QString parameterValue(void) const;
- void setParameter(const QCString &attribute, const QString &value);
+ TQCString parameterAttribute(void) const;
+ TQString parameterValue(void) const;
+ void setParameter(const TQCString &attribute, const TQString &value);
- QCString additionalCTypeParamStr(void) const
+ TQCString additionalCTypeParamStr(void) const
{
return mAdditionalCTypeParamStr;
}
- void setAdditionalCTypeParamStr( const QCString &param )
+ void setAdditionalCTypeParamStr( const TQCString &param )
{
mAdditionalCTypeParamStr = param;
}
@@ -159,55 +159,55 @@ public:
/** Tries to find a good icon for the 'Content-Type' by scanning
the installed mimelnk files. Returns the found icon. If no matching
icon is found, the one for application/octet-stream is returned. */
- QString iconName( int size = KIcon::Desktop ) const;
+ TQString iconName( int size = KIcon::Desktop ) const;
/** Get or set the 'Content-Transfer-Encoding' header field
The member functions that involve enumerated types (ints)
will work only for well-known encodings. */
- QCString contentTransferEncodingStr(void) const;
+ TQCString contentTransferEncodingStr(void) const;
int contentTransferEncoding(void) const;
- void setContentTransferEncodingStr(const QCString &aStr);
+ void setContentTransferEncodingStr(const TQCString &aStr);
void setContentTransferEncoding(int aCte);
/** Cte is short for ContentTransferEncoding.
These functions are an alternative to the ones with longer names. */
- QCString cteStr(void) const { return contentTransferEncodingStr(); }
+ TQCString cteStr(void) const { return contentTransferEncodingStr(); }
int cte(void) const { return contentTransferEncoding(); }
- void setCteStr(const QCString& aStr) { setContentTransferEncodingStr(aStr); }
+ void setCteStr(const TQCString& aStr) { setContentTransferEncodingStr(aStr); }
void setCte(int aCte) { setContentTransferEncoding(aCte); }
/** Get or set the 'Content-Description' header field */
- QString contentDescription() const;
- QCString contentDescriptionEncoded() const { return mContentDescription; }
- void setContentDescription(const QString &aStr);
+ TQString contentDescription() const;
+ TQCString contentDescriptionEncoded() const { return mContentDescription; }
+ void setContentDescription(const TQString &aStr);
/** Get or set the 'Content-Disposition' header field */
- QCString contentDisposition() const { return mContentDisposition; }
- void setContentDisposition( const QCString & cd ) { mContentDisposition = cd; }
+ TQCString contentDisposition() const { return mContentDisposition; }
+ void setContentDisposition( const TQCString & cd ) { mContentDisposition = cd; }
/** Get the message part charset.*/
- QCString charset() const { return mCharset; }
+ TQCString charset() const { return mCharset; }
/** Set the message part charset. */
- void setCharset( const QCString & c );
+ void setCharset( const TQCString & c );
- /** Get a QTextCodec suitable for this message part */
- const QTextCodec * codec() const;
+ /** Get a TQTextCodec suitable for this message part */
+ const TQTextCodec * codec() const;
/** Get or set name parameter */
- QString name() const { return mName; }
- void setName( const QString & name ) { mName = name; }
+ TQString name() const { return mName; }
+ void setName( const TQString & name ) { mName = name; }
/** Returns name of filename part of 'Content-Disposition' header field,
if present. */
- QString fileName(void) const;
+ TQString fileName(void) const;
/** Returns the part number */
- QString partSpecifier() const { return mPartSpecifier; }
+ TQString partSpecifier() const { return mPartSpecifier; }
/** Sets the part number */
- void setPartSpecifier( const QString & part ) { mPartSpecifier = part; }
+ void setPartSpecifier( const TQString & part ) { mPartSpecifier = part; }
/** If this part is complete (contains a body) */
bool isComplete() { return (!mBody.isNull()); }
@@ -231,20 +231,20 @@ public:
void setLoadPart( bool load ) { mLoadPart = load; }
protected:
- QCString mOriginalContentTypeStr;
- QCString mType;
- QCString mSubtype;
- QCString mCte;
- QCString mContentDescription;
- QCString mContentDisposition;
- QCString mContentId;
- QByteArray mBody;
- QCString mAdditionalCTypeParamStr;
- QString mName;
- QCString mParameterAttribute;
- QString mParameterValue;
- QCString mCharset;
- QString mPartSpecifier;
+ TQCString mOriginalContentTypeStr;
+ TQCString mType;
+ TQCString mSubtype;
+ TQCString mCte;
+ TQCString mContentDescription;
+ TQCString mContentDisposition;
+ TQCString mContentId;
+ TQByteArray mBody;
+ TQCString mAdditionalCTypeParamStr;
+ TQString mName;
+ TQCString mParameterAttribute;
+ TQString mParameterValue;
+ TQCString mCharset;
+ TQString mPartSpecifier;
mutable int mBodyDecodedSize;
KMMessagePart* mParent;
bool mLoadHeaders;