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 INSETENVIRONMENT_H
13 #define INSETENVIRONMENT_H
15 #include "insettext.h"
16 #include "lyxlayout_ptr_fwd.h"
21 class InsetEnvironment : public InsetText {
24 InsetEnvironment(BufferParams const &, std::string const & name);
26 void write(Buffer const & buf, std::ostream & os) const;
28 void read(Buffer const & buf, LyXLex & lex);
30 InsetBase::Code lyxCode() const { return InsetBase::ENVIRONMENT_CODE; }
32 int latex(Buffer const &, odocstream &,
33 OutputParams const &) const;
35 virtual docstring const editMessage() const;
37 InsetBase::EDITABLE editable() const { return HIGHLY_EDITABLE; }
39 LyXLayout_ptr const & layout() const;
40 /** returns true if, when outputing LaTeX, font changes should
41 be closed before generating this inset. This is needed for
42 insets that may contain several paragraphs */
43 bool noFontChange() const { return true; }
45 InsetEnvironment(InsetEnvironment const &);
47 virtual std::auto_ptr<InsetBase> doClone() const;
49 LyXLayout_ptr layout_;