summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-reader/CEncoding.h
Unidiff
Diffstat (limited to 'noncore/apps/opie-reader/CEncoding.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-reader/CEncoding.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/noncore/apps/opie-reader/CEncoding.h b/noncore/apps/opie-reader/CEncoding.h
index 86562e7..463fba9 100644
--- a/noncore/apps/opie-reader/CEncoding.h
+++ b/noncore/apps/opie-reader/CEncoding.h
@@ -3,11 +3,14 @@
3 3
4#include "CExpander.h" 4#include "CExpander.h"
5 5
6#define MAX_ENCODING 6
7
6class CEncoding : public CCharacterSource 8class CEncoding : public CCharacterSource
7{ 9{
8 friend class CFilterChain; 10 friend class CFilterChain;
9 protected: 11 protected:
10 CExpander* parent; 12 CExpander* parent;
13 linkType hyperlink(unsigned int n, QString& t) { return parent->hyperlink(n,t); }
11public: 14public:
12 CEncoding() : parent(NULL) {} 15 CEncoding() : parent(NULL) {}
13 void setparent(CExpander* p) { parent = p; } 16 void setparent(CExpander* p) { parent = p; }
@@ -50,4 +53,22 @@ public:
50 void getch(tchar& ch, CStyle& sty); 53 void getch(tchar& ch, CStyle& sty);
51}; 54};
52 55
56#include "CEncoding_tables.h"
57
58class CGeneral8Bit : public CEncoding
59{
60 int m_index;
61 public:
62 CGeneral8Bit(int _i) : m_index(_i)
63 {
64 // qDebug("8Bit:%d", _i);
65 // qDebug("%s", unicodetable::iterator(_i)->mime);
66 }
67 void getch(tchar& ch, CStyle& sty)
68 {
69 parent->getch(ch, sty);
70 ch = unicodetable::unicodevalue(m_index, ch);
71 }
72};
73
53#endif 74#endif