- Encoding(string const & n, string const & l, Uchar const * e)
- : Name_(n), LatexName_(l) {
- for (int i = 0; i < 256; ++i)
- encoding_table[i] = e[i];
- }
- ///
- string const & Name() const {
- return Name_;
- }
- ///
- string const & LatexName() const {
- return LatexName_;
- }
- ///
- Uchar ucs(unsigned char c) const {
- return encoding_table[c];
- }
+ Encoding(std::string const & n, std::string const & l,
+ std::string const & i);
+ ///
+ std::string const & name() const { return Name_; }
+ ///
+ std::string const & latexName() const { return LatexName_; }
+ ///
+ std::string const & iconvName() const { return iconvName_; }
+ /**
+ * Convert \p c to something that LaTeX can understand.
+ * This is either the character itself (if it is representable
+ * in this encoding), or a LaTeX macro.
+ * If the character is not representable in this encoding, but no
+ * LaTeX macro is known, a warning is given of lyxerr, and the
+ * character is returned.
+ */
+ docstring const latexChar(char_type c) const;
+ /// Add the preamble snippet needed for the output of latexChar(c)
+ /// to \p features.
+ void validate(char_type c, LaTeXFeatures & features) const;