filters
rtfimport_tokenizer.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef __RTFIMPORT_TOKENIZER_H__
00013 #define __RTFIMPORT_TOKENIZER_H__
00014
00015 #include <qcstring.h>
00016 #include <qfile.h>
00017
00018
00020 class RTFTokenizer
00021 {
00022 public:
00023 enum TokenType { OpenGroup, CloseGroup, ControlWord, PlainText, BinaryData };
00024
00025 RTFTokenizer();
00026
00031 void open( QFile *in );
00035 void next();
00036
00037
00038
00040 char *text;
00041 TokenType type;
00043 int value;
00045 bool hasParam;
00046
00047 public:
00049 QByteArray binaryData;
00050
00051
00052 private:
00053 int nextChar();
00054
00055 QFile *infile;
00056 QByteArray fileBuffer;
00057 QCString tokenText;
00058 uchar *fileBufferPtr;
00059 uchar *fileBufferEnd;
00060 };
00061
00062 #endif
|