X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Finsets%2FInsetWrap.h;h=789774241d89c17dfa8da11edf1b87709ebf3c7b;hb=d8a6b5bfd0baa02a4ba03f8c9e9c618baf41b03f;hp=a2f8d0932d1f9a322b5d0ad0a3c719615b9e802c;hpb=42123ab8a71080b6d15fca4e0c43ae76abf00a1e;p=lyx.git diff --git a/src/insets/InsetWrap.h b/src/insets/InsetWrap.h index a2f8d0932d..789774241d 100644 --- a/src/insets/InsetWrap.h +++ b/src/insets/InsetWrap.h @@ -13,7 +13,7 @@ #define INSETWRAP_H #include "InsetCollapsable.h" -#include "LyXLength.h" +#include "Length.h" #include "MailInset.h" @@ -30,9 +30,13 @@ public: /// std::string type; /// + int lines; + /// std::string placement; /// - LyXLength width; + Length overhang; + /// + Length width; }; @@ -45,42 +49,45 @@ public: /// ~InsetWrap(); /// - void write(Buffer const & buf, std::ostream & os) const; + void write(std::ostream & os) const; /// - void read(Buffer const & buf, Lexer & lex); + void read(Lexer & lex); /// void validate(LaTeXFeatures & features) const; /// - InsetBase::Code lyxCode() const { return InsetBase::WRAP_CODE; } + InsetCode lyxCode() const { return WRAP_CODE; } /// - int latex(Buffer const &, odocstream &, - OutputParams const &) const; + bool isMacroScope() const { return true; } /// - int plaintext(Buffer const &, odocstream &, - OutputParams const &) const; + int latex(odocstream &, OutputParams const &) const; /// - int docbook(Buffer const &, odocstream &, - OutputParams const &) const; + int plaintext(odocstream &, OutputParams const &) const; /// - virtual docstring const editMessage() const; + int docbook(odocstream &, OutputParams const &) const; /// - bool insetAllowed(InsetBase::Code) const; + docstring editMessage() const; /// - void addToToc(TocList &, Buffer const &) const; + bool insetAllowed(InsetCode) const; /// bool showInsetDialog(BufferView *) const; /// InsetWrapParams const & params() const { return params_; } /// bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const; + // Update the counters of this inset and of its contents + void updateLabels(ParIterator const &); protected: /// - virtual void doDispatch(Cursor & cur, FuncRequest & cmd); + void doDispatch(Cursor & cur, FuncRequest & cmd); + /// + docstring name() const { return name_; } private: - virtual std::auto_ptr doClone() const; + Inset * clone() const; /// InsetWrapParams params_; + /// + docstring name_; }; @@ -89,7 +96,7 @@ public: /// InsetWrapMailer(InsetWrap & inset); /// - virtual InsetBase & inset() const { return inset_; } + virtual Inset & inset() const { return inset_; } /// virtual std::string const & name() const { return name_; } ///