4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS.
12 #ifndef INSET_NEWLINE_H
13 #define INSET_NEWLINE_H
18 class InsetNewline : public InsetOld {
23 InsetBase::Code lyxCode() const { return InsetBase::NEWLINE_CODE; }
25 void metrics(MetricsInfo &, Dimension &) const;
27 virtual void draw(PainterInfo & pi, int x, int y) const;
29 virtual int latex(Buffer const &, std::ostream &,
30 OutputParams const &) const;
32 virtual int plaintext(Buffer const &, std::ostream &,
33 OutputParams const &) const;
35 virtual int docbook(Buffer const &, std::ostream &,
36 OutputParams const &) const;
38 virtual void read(Buffer const &, LyXLex & lex);
40 virtual void write(Buffer const & buf, std::ostream & os) const;
41 /// We don't need \begin_inset and \end_inset
42 virtual bool directWrite() const { return true; }
43 /// is this equivalent to a space (which is BTW different from
47 virtual std::auto_ptr<InsetBase> doClone() const
49 return std::auto_ptr<InsetBase>(new InsetNewline);
53 #endif // INSET_NEWLINE_H