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 InsetOld {
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(Buffer const &, std::ostream &) const;
64 /// Will not be used when lyxf3
65 void read(Buffer const &, LyXLex & lex);
67 int latex(Buffer const &, odocstream &,
68 OutputParams const &) const;
70 int plaintext(Buffer const &, odocstream &,
71 OutputParams const &) const;
73 int docbook(Buffer const &, odocstream &,
74 OutputParams const &) const;
75 /// the string that is passed to the TOC
76 virtual int textString(Buffer const &, odocstream &,
77 OutputParams const &) const;
79 InsetBase::Code lyxCode() const { return InsetBase::SPACE_CODE; }
80 /// We don't need \begin_inset and \end_inset
81 bool directWrite() const { return true; }
83 // should this inset be handled like a normal charater
85 /// is this equivalent to a letter?
86 bool isLetter() const;
87 /// is this equivalent to a space (which is BTW different from
91 virtual std::auto_ptr<InsetBase> doClone() const;
93 /// And which kind is this?
100 #endif // INSET_SPACE_H