InsetEnvironment::InsetEnvironment
(BufferParams const & bp, string const & name)
- : InsetCollapsable(bp)
+ : InsetText(bp)
{
- setLabel(name);
+ //setLabel(name);
setInsetName(name);
+ autoBreakRows = true;
+ drawFrame_ = ALWAYS;
// needs more stuff in lyxlayout. coming in later patches.
//LyXTextClass const & tc = bp.getLyXTextClass();
//LyXLayout_ptr const & layout = tc.getEnv(name);
InsetEnvironment::InsetEnvironment(InsetEnvironment const & in, bool same_id)
- : InsetCollapsable(in, same_id), header_(in.header_), footer_(in.footer_)
+ : InsetText(in, same_id), header_(in.header_), footer_(in.footer_)
{}
void InsetEnvironment::write(Buffer const * buf, ostream & os) const
{
os << "Environment " << getInsetName() << "\n";
- InsetCollapsable::write(buf, os);
+ InsetText::write(buf, os);
}
void InsetEnvironment::read(Buffer const * buf, LyXLex & lex)
{
- InsetCollapsable::read(buf, lex);
+ InsetText::read(buf, lex);
}
ostream & os, bool fragile, bool fp) const
{
os << header_;
- int i = inset.latex(buf, os, fragile, fp);
+ int i = InsetText::latex(buf, os, fragile, fp);
os << footer_;
return i;
}
#ifndef INSETENVIRONMENT_H
#define INSETENVIRONMENT_H
-#include "insetcollapsable.h"
+#include "insettext.h"
-
-class InsetEnvironment : public InsetCollapsable {
+class InsetEnvironment : public InsetText {
public:
///
InsetEnvironment(BufferParams const &, string const & name);
///
string const editMessage() const;
///
+ Inset::EDITABLE editable() const { return HIGHLY_EDITABLE; }
+ ///
+ bool isTextInset() const { return true; }
+ ///
bool needFullRow() const { return true; }
/** returns true if, when outputing LaTeX, font changes should
be closed before generating this inset. This is needed for