]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetFloat.h
Reduce caption hardcoding
[lyx.git] / src / insets / InsetFloat.h
index 3edba343140ca9cbb0ec14bcccbe0377bc64cbb9..6cff1089754a15401dff14d5a33d2b169cc815db 100644 (file)
@@ -51,9 +51,7 @@ class InsetFloat : public InsetCollapsable
 {
 public:
        ///
-       InsetFloat(Buffer *, std::string const &);
-       ///
-       ~InsetFloat();
+       InsetFloat(Buffer * buffer, std::string params_str);
 
        ///
        static void string2params(std::string const &, InsetFloatParams &);
@@ -69,9 +67,11 @@ public:
        void setNewLabel();
        ///
        InsetFloatParams const & params() const { return params_; }
+       ///
+       bool allowsCaptionVariation(std::string const &) const;
 private:
        ///
-       docstring name() const;
+       docstring layoutName() const;
        ///
        docstring toolTip(BufferView const & bv, int x, int y) const;
        ///
@@ -83,25 +83,24 @@ private:
        ///
        InsetCode lyxCode() const { return FLOAT_CODE; }
        ///
-       int latex(odocstream &, OutputParams const &) const;
+       void latex(otexstream &, OutputParams const &) const;
        ///
-       int plaintext(odocstream &, OutputParams const &) const;
+       int plaintext(odocstringstream & ods, OutputParams const & op,
+                     size_t max_length = INT_MAX) const;
        ///
        int docbook(odocstream &, OutputParams const &) const;
        ///
        docstring xhtml(XHTMLStream &, OutputParams const &) const;
        ///
        bool insetAllowed(InsetCode) const;
-       /** returns true if, when outputing LaTeX, font changes should
+       /** returns false if, when outputing LaTeX, font changes should
            be closed before generating this inset. This is needed for
            insets that may contain several paragraphs */
-       bool noFontChange() const { return true; }
-       ///
-       bool showInsetDialog(BufferView *) const;
+       bool inheritFont() const { return false; }
        ///
        bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
        // Update the counters of this inset and of its contents
-       void updateLabels(ParIterator const &, UpdateType);
+       void updateBuffer(ParIterator const &, UpdateType);
        ///
        void doDispatch(Cursor & cur, FuncRequest & cmd);
        ///
@@ -110,8 +109,6 @@ private:
        docstring getCaption(OutputParams const &) const;
        ///
        InsetFloatParams params_;
-       ///
-       docstring name_;
 };