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
10 * \author Jürgen Spitzmüller
12 * Full author contact details are available in file CREDITS.
26 /// Used to insert different kinds of spaces
27 class InsetSpace : public Inset {
30 /// The different kinds of spaces we support
32 /// Normal space ('\ ')
34 /// Protected (no break) space ('~')
42 /// \enspace (0.5em unbreakable)
44 /// \enspace (0.5em breakable)
46 /// Negative thin space ('\negthinspace')
59 void metrics(MetricsInfo &, Dimension &) const;
61 void draw(PainterInfo & pi, int x, int y) const;
63 void write(std::ostream &) const;
64 /// Will not be used when lyxf3
65 void read(Lexer & lex);
67 int latex(odocstream &, OutputParams const &) const;
69 int plaintext(odocstream &, OutputParams const &) const;
71 int docbook(odocstream &, OutputParams const &) const;
72 /// the string that is passed to the TOC
73 void textString(odocstream &) const;
75 InsetCode lyxCode() const { return SPACE_CODE; }
76 /// We don't need \begin_inset and \end_inset
77 bool directWrite() const { return true; }
79 // should this inset be handled like a normal charater
80 bool isChar() const { return true; }
81 /// is this equivalent to a letter?
82 bool isLetter() const { return false; }
83 /// is this equivalent to a space (which is BTW different from
85 bool isSpace() const { return true; }
87 virtual Inset * clone() const;
89 /// And which kind is this?
96 #endif // INSET_SPACE_H