2 /* This file is part of*
3 * ======================================================
5 * LyX, The Document Processor
7 * Copyright 1997 Asger Alstrup
9 * ====================================================== */
11 #ifndef INSET_SPECIALCHAR_H
12 #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 (\-)
33 /// End of sentence punctuation (\@)
37 /// Protected Separator
45 InsetSpecialChar(Kind k);
47 int ascent(BufferView *, LyXFont const &) const;
49 int descent(BufferView *, LyXFont const &) const;
51 int width(BufferView *, LyXFont const &) const;
53 void draw(BufferView *, LyXFont const &, int, float &, bool) const;
55 void Write(Buffer const *, std::ostream &) const;
56 /// Will not be used when lyxf3
57 void Read(Buffer const *, LyXLex & lex);
59 int Latex(Buffer const *, std::ostream &,
60 bool fragile, bool free_spc) const;
62 int Ascii(Buffer const *, std::ostream &, int linelen) const;
64 int Linuxdoc(Buffer const *, std::ostream &) const;
66 int DocBook(Buffer const *, std::ostream &) const;
68 Inset * Clone() const;
70 Inset::Code LyxCode() const
72 return Inset::SPECIALCHAR_CODE;
74 /// We don't need \begin_inset and \end_inset
75 bool DirectWrite() const
80 void Validate(LaTeXFeatures &) const;
82 /// And which kind is this?