2003-03-12 19:16:42 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
/**
|
|
|
|
* \file insetnewline.h
|
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
*
|
|
|
|
* \author John Levon
|
|
|
|
*
|
2003-08-23 00:17:00 +00:00
|
|
|
* Full author contact details are available in file CREDITS.
|
2003-03-12 19:16:42 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef INSET_NEWLINE_H
|
|
|
|
#define INSET_NEWLINE_H
|
|
|
|
|
|
|
|
|
|
|
|
#include "inset.h"
|
|
|
|
|
2003-07-25 21:20:24 +00:00
|
|
|
class InsetNewline : public InsetOld {
|
2003-03-12 19:16:42 +00:00
|
|
|
public:
|
|
|
|
|
2003-05-19 17:03:12 +00:00
|
|
|
InsetNewline() {}
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-07-25 17:11:25 +00:00
|
|
|
virtual std::auto_ptr<InsetBase> clone() const {
|
|
|
|
return std::auto_ptr<InsetBase>(new InsetNewline);
|
2003-03-12 19:16:42 +00:00
|
|
|
}
|
|
|
|
|
2003-07-25 21:20:24 +00:00
|
|
|
InsetOld::Code lyxCode() const { return InsetOld::NEWLINE_CODE; }
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-06-02 10:03:27 +00:00
|
|
|
void metrics(MetricsInfo &, Dimension &) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-05-30 06:48:24 +00:00
|
|
|
virtual void draw(PainterInfo & pi, int x, int y) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-08-28 07:41:31 +00:00
|
|
|
virtual int latex(Buffer const &, std::ostream &,
|
2003-05-23 08:59:47 +00:00
|
|
|
LatexRunParams const &) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-08-28 07:41:31 +00:00
|
|
|
virtual int ascii(Buffer const &, std::ostream &, int linelen) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-08-28 07:41:31 +00:00
|
|
|
virtual int linuxdoc(Buffer const &, std::ostream &) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-08-28 07:41:31 +00:00
|
|
|
virtual int docbook(Buffer const &, std::ostream &, bool) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-08-28 07:41:31 +00:00
|
|
|
virtual void read(Buffer const &, LyXLex & lex);
|
2003-03-12 19:16:42 +00:00
|
|
|
|
2003-08-28 07:41:31 +00:00
|
|
|
virtual void write(Buffer const & buf, std::ostream & os) const;
|
2003-03-12 19:16:42 +00:00
|
|
|
/// We don't need \begin_inset and \end_inset
|
|
|
|
virtual bool directWrite() const { return true; }
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // INSET_NEWLINE_H
|