kmail
encodingdetector.cpp File Reference
#include "encodingdetector.h"
#include <assert.h>
#include <stdlib.h>
#include "encodingdetector_ja_p.h"
#include <qregexp.h>
#include <qtextcodec.h>
#include <kglobal.h>
#include <kcharsets.h>
#include <kdebug.h>
#include <klocale.h>
#include <ctype.h>
Go to the source code of this file.
Defines | |
#define | MAX_BUFFER 16*1024 |
#define | PANGO_SCRIPT_ARABIC EncodingDetector::Arabic |
#define | PANGO_SCRIPT_ARMENIAN EncodingDetector::None |
#define | PANGO_SCRIPT_BENGALI EncodingDetector::None |
#define | PANGO_SCRIPT_CANADIAN_ABORIGINAL EncodingDetector::None |
#define | PANGO_SCRIPT_CHEROKEE EncodingDetector::None |
#define | PANGO_SCRIPT_CYRILLIC EncodingDetector::Cyrillic |
#define | PANGO_SCRIPT_DEVANAGARI EncodingDetector::None |
#define | PANGO_SCRIPT_ETHIOPIC EncodingDetector::None |
#define | PANGO_SCRIPT_GEORGIAN EncodingDetector::SouthEasternEurope |
#define | PANGO_SCRIPT_GREEK EncodingDetector::Greek |
#define | PANGO_SCRIPT_GUJARATI EncodingDetector::None |
#define | PANGO_SCRIPT_GURMUKHI EncodingDetector::None |
#define | PANGO_SCRIPT_HEBREW EncodingDetector::Hebrew |
#define | PANGO_SCRIPT_KANNADA EncodingDetector::None |
#define | PANGO_SCRIPT_KHMER EncodingDetector::None |
#define | PANGO_SCRIPT_LAO EncodingDetector::None |
#define | PANGO_SCRIPT_LATIN EncodingDetector::WesternEuropean |
#define | PANGO_SCRIPT_MALAYALAM EncodingDetector::None |
#define | PANGO_SCRIPT_MONGOLIAN EncodingDetector::None |
#define | PANGO_SCRIPT_MYANMAR EncodingDetector::None |
#define | PANGO_SCRIPT_ORIYA EncodingDetector::None |
#define | PANGO_SCRIPT_SINHALA EncodingDetector::None |
#define | PANGO_SCRIPT_SYRIAC EncodingDetector::None |
#define | PANGO_SCRIPT_TAGALOG EncodingDetector::None |
#define | PANGO_SCRIPT_TAMIL EncodingDetector::None |
#define | PANGO_SCRIPT_TELUGU EncodingDetector::None |
#define | PANGO_SCRIPT_THAI EncodingDetector::Thai |
#define | PANGO_SCRIPT_TIBETAN EncodingDetector::None |
Typedefs | |
typedef struct _PangoScriptForLang | PangoScriptForLang |
Enumerations | |
enum | MIB { MibLatin1 = 4, Mib8859_8 = 85, MibUtf8 = 106, MibUcs2 = 1000, MibUtf16 = 1015, MibUtf16BE = 1013, MibUtf16LE = 1014 } |
Functions | |
static QCString | automaticDetectionForArabic (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForBaltic (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForCentralEuropean (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForCyrillic (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForGreek (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForHebrew (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForJapanese (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForTurkish (const unsigned char *ptr, int size) |
static QCString | automaticDetectionForWesternEuropean (const unsigned char *ptr, int size) |
static int | findXMLEncoding (const QCString &str, int &encodingLength) |
static bool | is16Bit (QTextCodec *codec) |
static void | skipComment (const char *&ptr, const char *pEnd) |
Variables | |
static const PangoScriptForLang | pango_script_for_lang [] |
Define Documentation
#define MAX_BUFFER 16*1024 |
Definition at line 33 of file encodingdetector.cpp.
#define PANGO_SCRIPT_ARABIC EncodingDetector::Arabic |
Definition at line 99 of file encodingdetector.cpp.
#define PANGO_SCRIPT_ARMENIAN EncodingDetector::None |
Definition at line 76 of file encodingdetector.cpp.
#define PANGO_SCRIPT_BENGALI EncodingDetector::None |
Definition at line 77 of file encodingdetector.cpp.
#define PANGO_SCRIPT_CANADIAN_ABORIGINAL EncodingDetector::None |
Definition at line 78 of file encodingdetector.cpp.
#define PANGO_SCRIPT_CHEROKEE EncodingDetector::None |
Definition at line 79 of file encodingdetector.cpp.
#define PANGO_SCRIPT_CYRILLIC EncodingDetector::Cyrillic |
Definition at line 100 of file encodingdetector.cpp.
#define PANGO_SCRIPT_DEVANAGARI EncodingDetector::None |
Definition at line 80 of file encodingdetector.cpp.
#define PANGO_SCRIPT_ETHIOPIC EncodingDetector::None |
Definition at line 81 of file encodingdetector.cpp.
#define PANGO_SCRIPT_GEORGIAN EncodingDetector::SouthEasternEurope |
Definition at line 101 of file encodingdetector.cpp.
#define PANGO_SCRIPT_GREEK EncodingDetector::Greek |
Definition at line 102 of file encodingdetector.cpp.
#define PANGO_SCRIPT_GUJARATI EncodingDetector::None |
Definition at line 82 of file encodingdetector.cpp.
#define PANGO_SCRIPT_GURMUKHI EncodingDetector::None |
Definition at line 83 of file encodingdetector.cpp.
#define PANGO_SCRIPT_HEBREW EncodingDetector::Hebrew |
Definition at line 103 of file encodingdetector.cpp.
#define PANGO_SCRIPT_KANNADA EncodingDetector::None |
Definition at line 84 of file encodingdetector.cpp.
#define PANGO_SCRIPT_KHMER EncodingDetector::None |
Definition at line 85 of file encodingdetector.cpp.
#define PANGO_SCRIPT_LAO EncodingDetector::None |
Definition at line 86 of file encodingdetector.cpp.
#define PANGO_SCRIPT_LATIN EncodingDetector::WesternEuropean |
Definition at line 104 of file encodingdetector.cpp.
#define PANGO_SCRIPT_MALAYALAM EncodingDetector::None |
Definition at line 87 of file encodingdetector.cpp.
#define PANGO_SCRIPT_MONGOLIAN EncodingDetector::None |
Definition at line 88 of file encodingdetector.cpp.
#define PANGO_SCRIPT_MYANMAR EncodingDetector::None |
Definition at line 89 of file encodingdetector.cpp.
#define PANGO_SCRIPT_ORIYA EncodingDetector::None |
Definition at line 90 of file encodingdetector.cpp.
#define PANGO_SCRIPT_SINHALA EncodingDetector::None |
Definition at line 91 of file encodingdetector.cpp.
#define PANGO_SCRIPT_SYRIAC EncodingDetector::None |
Definition at line 92 of file encodingdetector.cpp.
#define PANGO_SCRIPT_TAGALOG EncodingDetector::None |
Definition at line 93 of file encodingdetector.cpp.
#define PANGO_SCRIPT_TAMIL EncodingDetector::None |
Definition at line 94 of file encodingdetector.cpp.
#define PANGO_SCRIPT_TELUGU EncodingDetector::None |
Definition at line 96 of file encodingdetector.cpp.
#define PANGO_SCRIPT_THAI EncodingDetector::Thai |
Definition at line 105 of file encodingdetector.cpp.
#define PANGO_SCRIPT_TIBETAN EncodingDetector::None |
Definition at line 95 of file encodingdetector.cpp.
Typedef Documentation
typedef struct _PangoScriptForLang PangoScriptForLang |
Enumeration Type Documentation
enum MIB |
Definition at line 312 of file encodingdetector.cpp.
Function Documentation
static QCString automaticDetectionForArabic | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 391 of file encodingdetector.cpp.
static QCString automaticDetectionForBaltic | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 405 of file encodingdetector.cpp.
static QCString automaticDetectionForCentralEuropean | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 418 of file encodingdetector.cpp.
static QCString automaticDetectionForCyrillic | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 450 of file encodingdetector.cpp.
static QCString automaticDetectionForGreek | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 646 of file encodingdetector.cpp.
static QCString automaticDetectionForHebrew | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 659 of file encodingdetector.cpp.
static QCString automaticDetectionForJapanese | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 675 of file encodingdetector.cpp.
static QCString automaticDetectionForTurkish | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 695 of file encodingdetector.cpp.
static QCString automaticDetectionForWesternEuropean | ( | const unsigned char * | ptr, | |
int | size | |||
) | [static] |
Definition at line 706 of file encodingdetector.cpp.
static int findXMLEncoding | ( | const QCString & | str, | |
int & | encodingLength | |||
) | [static] |
Definition at line 768 of file encodingdetector.cpp.
static bool is16Bit | ( | QTextCodec * | codec | ) | [static] |
Definition at line 323 of file encodingdetector.cpp.
static void skipComment | ( | const char *& | ptr, | |
const char * | pEnd | |||
) | [static] |
Definition at line 734 of file encodingdetector.cpp.
Variable Documentation
const PangoScriptForLang pango_script_for_lang[] [static] |
Definition at line 108 of file encodingdetector.cpp.