KMIME Library
23 #ifndef __KMIME_UTIL_H__
24 #define __KMIME_UTIL_H__
26 #include <QtCore/QString>
27 #include "kmime_export.h"
53 KMIME_EXPORT
extern bool isUsAscii(
const QString &s );
62 KMIME_EXPORT
extern QString nameForEncoding( KMime::Headers::contentEncoding enc );
72 extern const uchar specialsMap[16];
73 extern const uchar tSpecialsMap[16];
74 extern const uchar aTextMap[16];
75 extern const uchar tTextMap[16];
76 extern const uchar eTextMap[16];
78 inline bool isOfSet(
const uchar map[16],
unsigned char ch )
80 return ( ch < 128 ) && ( map[ ch/8 ] & 0x80 >> ch%8 );
82 inline bool isSpecial(
char ch )
84 return isOfSet( specialsMap, ch );
86 inline bool isTSpecial(
char ch )
88 return isOfSet( tSpecialsMap, ch );
90 inline bool isAText(
char ch )
92 return isOfSet( aTextMap, ch );
94 inline bool isTText(
char ch )
96 return isOfSet( tTextMap, ch );
98 inline bool isEText(
char ch )
100 return isOfSet( eTextMap, ch );
113 KMIME_EXPORT
extern void setFallbackCharEncoding(
const QString& fallbackCharEnc );
123 KMIME_EXPORT
extern QString fallbackCharEncoding();
136 KMIME_EXPORT
extern void setUseOutlookAttachmentEncoding(
bool violateStandard );
141 KMIME_EXPORT
extern bool useOutlookAttachmentEncoding();
154 KMIME_EXPORT
extern QString decodeRFC2047String(
156 bool forceCS =
false );
183 KMIME_EXPORT
extern QByteArray encodeRFC2047String(
185 bool allow8bitHeaders=
false );
199 KMIME_EXPORT
extern QString decodeRFC2231String(
201 bool forceCS =
false );
229 KMIME_EXPORT
extern QByteArray uniqueString();
239 KMIME_EXPORT
extern QByteArray multiPartBoundary();
300 KMIME_EXPORT
extern QByteArray CRLFtoLF(
const char *s );
326 KMIME_EXPORT
extern void removeQuots(
QByteArray &str );
337 KMIME_EXPORT
extern void removeQuots(
QString &str );
346 KMIME_EXPORT
extern void addQuotes(
QByteArray &str,
bool forceQuotes );
354 KMIME_EXPORT
extern void addQuotes(
QString &str,
bool forceQuotes );
407 KMIME_EXPORT
QString removeBidiControlChars(
const QString &input );
414 KMIME_EXPORT
bool hasAttachment( Content* content );
422 KMIME_EXPORT
bool hasInvitation( Content* content );
430 KMIME_EXPORT
bool isSigned( Message* message );
438 KMIME_EXPORT
bool isEncrypted( Message* message );
446 KMIME_EXPORT
bool isInvitation( Content* content );
This file is part of the API for handling MIME data and defines the Content class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:37:18 by
doxygen 1.8.7 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.