*
* \author Angus Leeming
* \author Martin Vermeer
+ * \author Uwe Stöhr
*
* Full author contact details are available in file CREDITS.
*/
#ifndef INSETBOX_H
#define INSETBOX_H
-#include "InsetCollapsable.h"
-#include "Length.h"
+#include "InsetCollapsible.h"
+
+#include "support/Length.h"
namespace lyx {
{
public:
///
- InsetBoxParams(std::string const &);
+ explicit InsetBoxParams(std::string const &);
///
void write(std::ostream & os) const;
///
Length height;
///
std::string height_special;
+ ///
+ Length thickness;
+ ///
+ Length separation;
+ ///
+ Length shadowsize;
+ ///
+ std::string framecolor;
+ ///
+ std::string backgroundcolor;
};
///////////////////////////////////////////////////////////////////////
-class InsetBox : public InsetCollapsable
+class InsetBox : public InsetCollapsible
{
public:
///
/// \name Public functions inherited from Inset class
//@{
///
- InsetCode lyxCode() const { return BOX_CODE; }
+ InsetCode lyxCode() const override { return BOX_CODE; }
///
- docstring layoutName() const;
+ docstring layoutName() const override;
///
- void write(std::ostream &) const;
+ void write(std::ostream &) const override;
///
- void read(Lexer & lex);
+ void read(Lexer & lex) override;
+ ///
+ void metrics(MetricsInfo &, Dimension &) const override;
+ ///
+ ColorCode backgroundColor(PainterInfo const &) const override;
///
- void metrics(MetricsInfo &, Dimension &) const;
+ LyXAlignment contentAlignment() const override;
///
- DisplayType display() const { return Inline; }
+ bool allowParagraphCustomization(idx_type = 0) const override { return !forcePlainLayout(); }
///
- ColorCode backgroundColor(PainterInfo const &) const;
+ bool allowMultiPar() const override;
///
- bool allowParagraphCustomization(idx_type = 0) const { return !forcePlainLayout(); }
+ bool forcePlainLayout(idx_type = 0) const override;
///
- bool forcePlainLayout(idx_type = 0) const;
+ bool needsCProtection(bool const maintext = false,
+ bool const fragile = false) const override;
///
- bool neverIndent() const { return true; }
+ bool neverIndent() const override { return true; }
///
- bool inheritFont() const { return false; }
+ bool inheritFont() const override { return false; }
///
- void latex(otexstream &, OutputParams const &) const;
+ void latex(otexstream &, OutputParams const &) const override;
///
- int plaintext(odocstream &, OutputParams const &) const;
+ int plaintext(odocstringstream & ods, OutputParams const & op,
+ size_t max_length = INT_MAX) const override;
///
- int docbook(odocstream &, OutputParams const &) const;
+ void docbook(XMLStream &, OutputParams const &) const override;
///
- docstring xhtml(XHTMLStream &, OutputParams const &) const;
+ docstring xhtml(XMLStream &, OutputParams const &) const override;
///
- void validate(LaTeXFeatures &) const;
+ void validate(LaTeXFeatures &) const override;
///
- bool hasFixedWidth() const;
+ bool hasFixedWidth() const override;
///
- std::string contextMenuName() const;
+ std::string contextMenuName() const override;
//@}
- /// \name Public functions inherited from InsetCollapsable class
+ /// \name Public functions inherited from InsetCollapsible class
//@{
///
- void setButtonLabel();
+ void setButtonLabel() override;
//@}
protected:
/// \name Protected functions inherited from Inset class
//@{
///
- bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
+ bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const override;
///
- void doDispatch(Cursor & cur, FuncRequest & cmd);
+ void doDispatch(Cursor & cur, FuncRequest & cmd) override;
///
- Inset * clone() const { return new InsetBox(*this); }
+ Inset * clone() const override { return new InsetBox(*this); }
//@}
private: