]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetFlex.h
Loop refactoring
[lyx.git] / src / insets / InsetFlex.h
index 2fdc43ccb0065238c14093ff8dbfc3a99008c39b..a781fb8a7680d0d93d498b7a406ecc523c6682aa 100644 (file)
 #ifndef INSETFLEX_H
 #define INSETFLEX_H
 
-#include "InsetCollapsable.h"
+#include "InsetCollapsible.h"
 
 namespace lyx {
 
 /** The Flex inset, e.g., CharStyle, Custom inset or XML short element
 
 */
-class InsetFlex : public InsetCollapsable {
+class InsetFlex : public InsetCollapsible {
 public:
        ///
-       InsetFlex(Buffer const &, std::string const & layoutName);
+       InsetFlex(Buffer *, std::string const & layoutName);
        ///
-       docstring name() const { return from_utf8(name_); }
-
-       ///
-       docstring editMessage() const;
+       docstring layoutName() const override { return from_utf8("Flex:" + name_); }
        ///
-       InsetCode lyxCode() const { return FLEX_CODE; }
+       InsetLayout const & getLayout() const override;
        ///
-       void write(std::ostream &) const;
+       InsetCode lyxCode() const override { return FLEX_CODE; }
+       /// Default looks
+       InsetLayout::InsetDecoration decoration() const override;
        ///
-       void read(Lexer & lex);
+       void write(std::ostream &) const override;
+       /// should paragraph indentation be omitted in any case?
+       bool neverIndent() const override { return true; }
        ///
-       virtual bool allowParagraphCustomization(idx_type = 0) const { return false; }
-
+       bool hasSettings() const override { return false; }
        ///
-       int plaintext(odocstream &, OutputParams const &) const;
+       bool getStatus(Cursor & cur, FuncRequest const & cmd,
+               FuncStatus &) const override;
        ///
-       int docbook(odocstream &, OutputParams const &) const;
-       /// the string that is passed to the TOC
-       void textString(odocstream &) const;
+       void doDispatch(Cursor & cur, FuncRequest & cmd) override;
        ///
-       void validate(LaTeXFeatures &) const;
-
-       /// should paragraph indendation be ommitted in any case?
-       bool neverIndent() const { return true; }
+       void updateBuffer(ParIterator const & it, UpdateType utype, bool const deleted = false) override;
 
 protected:
+       ///
        InsetFlex(InsetFlex const &);
 
 private:
-       Inset * clone() const { return new InsetFlex(*this); }
-
+       ///
+       Inset * clone() const override { return new InsetFlex(*this); }
        ///
        std::string name_;
 };