4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Lars Gullik Bjønnes
8 * \author Jean-Marc Lasgouttes
10 * Full author contact details are available in file CREDITS.
16 #include "support/std_string.h"
20 typedef unsigned short int Uchar;
28 Encoding(string const & n, string const & l, Uchar const * e)
29 : Name_(n), LatexName_(l) {
30 for (int i = 0; i < 256; ++i)
31 encoding_table[i] = e[i];
34 string const & Name() const {
38 string const & LatexName() const {
42 Uchar ucs(unsigned char c) const {
43 return encoding_table[c];
51 Uchar encoding_table[256];
54 extern Encoding symbol_encoding;
59 typedef std::map<string, Encoding> EncodingList;
63 void read(string const & filename);
65 Encoding const * getEncoding(string const & encoding) const;
67 Encoding const * symbol_encoding() {
68 return &symbol_encoding_;
84 bool IsComposeChar_hebrew(unsigned char c);
87 bool IsComposeChar_arabic(unsigned char c);
90 bool is_arabic_special(unsigned char c);
93 bool is_arabic(unsigned char c);
96 unsigned char TransformChar(unsigned char c, Letter_Form form);
100 EncodingList encodinglist;
102 Encoding symbol_encoding_;
105 extern Encodings encodings;