3 * \file insetspecialchar.h
4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Asger Alstrup Nielsen
8 * \author Jean-Marc Lasgouttes
9 * \author Lars Gullik Bjønnes
11 * Full author contact details are available in file CREDITS
14 #ifndef INSET_SPECIALCHAR_H
15 #define INSET_SPECIALCHAR_H
23 /// Used to insert special chars
24 class InsetSpecialChar : public Inset {
27 /// The different kinds of special chars we support
29 /// Optional hyphenation point (\-)
31 /// Ligature break point (\textcompwordmark)
35 /// End of sentence punctuation (\@)
45 InsetSpecialChar(Kind k);
49 void dimension(BufferView *, LyXFont const &, Dimension &) const;
51 void draw(BufferView *, LyXFont const &, int, float &) const;
53 void write(Buffer const *, std::ostream &) const;
54 /// Will not be used when lyxf3
55 void read(Buffer const *, LyXLex & lex);
57 int latex(Buffer const *, std::ostream &,
58 LatexRunParams const &) const;
60 int ascii(Buffer const *, std::ostream &, int linelen) const;
62 int linuxdoc(Buffer const *, std::ostream &) const;
64 int docbook(Buffer const *, std::ostream &, bool mixcont) const;
66 virtual Inset * clone(Buffer const &) const;
68 Inset::Code lyxCode() const { return Inset::SPECIALCHAR_CODE; }
69 /// We don't need \begin_inset and \end_inset
70 bool directWrite() const { return true; }
72 void validate(LaTeXFeatures &) const;
74 // should this inset be handled like a normal charater
76 /// is this equivalent to a letter?
77 bool isLetter() const;
78 /// is this equivalent to a space (which is BTW different from
81 // should we break lines after this inset?
82 bool isLineSeparator() const;
84 /// And which kind is this?