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"
18 class InsetEnvironment : public InsetText {
21 InsetEnvironment(BufferParams const &, std::string const & name);
23 InsetEnvironment(InsetEnvironment const &);
25 void write(Buffer const & buf, std::ostream & os) const;
27 void read(Buffer const & buf, LyXLex & lex);
29 virtual std::auto_ptr<InsetBase> clone() const;
31 InsetOld::Code lyxCode() const { return InsetOld::ENVIRONMENT_CODE; }
33 int latex(Buffer const &, std::ostream &,
34 OutputParams const &) const;
36 std::string const editMessage() const;
38 InsetOld::EDITABLE editable() const { return HIGHLY_EDITABLE; }
40 bool isTextInset() const { return true; }
42 LyXLayout_ptr const & layout() const;
43 /** returns true if, when outputing LaTeX, font changes should
44 be closed before generating this inset. This is needed for
45 insets that may contain several paragraphs */
46 bool noFontChange() const { return true; }
50 LyXLayout_ptr layout_;