]> git.lyx.org Git - lyx.git/blobdiff - src/insets/insetert.h
Clean up InsetGraphics::Cache and rename as GraphicsInset.
[lyx.git] / src / insets / insetert.h
index 0217b16e69e6f26fec08942c2d558a6e211f74df..7d793bd95e27a2a0f8ababaf8ec5bc0371400491 100644 (file)
@@ -38,9 +38,9 @@ public:
        ///
        InsetERT(BufferParams const &, bool collapsed = false);
        ///
-       InsetERT(InsetERT const &, bool same_id = false);
+       InsetERT(InsetERT const &);
        ///
-       Inset * clone(Buffer const &, bool same_id = false) const;
+       Inset * clone() const;
        ///
        InsetERT(BufferParams const &,
                 Language const *, string const & contents, bool collapsed);
@@ -57,19 +57,15 @@ public:
        ///
        bool insertInset(BufferView *, Inset *);
        ///
-       bool insetAllowed(Inset::Code) const { return false; }
+       bool insetAllowed(Inset::Code code) const { return code == Inset::NEWLINE_CODE; }
        ///
        void setFont(BufferView *, LyXFont const &,
                             bool toggleall = false, bool selectall = false);
        ///
-       void edit(BufferView *, int, int, mouse_button::state);
-       ///
-       void edit(BufferView * bv, bool front = true);
-       ///
        EDITABLE editable() const;
        ///
-       int latex(Buffer const *, std::ostream &, bool fragile,
-                 bool free_spc) const;
+       int latex(Buffer const *, std::ostream &,
+                 LatexRunParams const &) const;
        ///
        int ascii(Buffer const *,
                          std::ostream &, int linelen = 0) const;
@@ -103,13 +99,9 @@ public:
        WordLangTuple const
        selectNextWordToSpellcheck(BufferView *, float &) const;
        ///
-       int ascent(BufferView *, LyXFont const &) const;
-       ///
-       int descent(BufferView *, LyXFont const &) const;
-       ///
-       int width(BufferView *, LyXFont const &) const;
+       void metrics(MetricsInfo &, Dimension &) const;
        ///
-       void draw(BufferView *, const LyXFont &, int , float &, bool) const;
+       void draw(PainterInfo & pi, int x, int y) const;
        /// set the status of the inset
        void status(BufferView *, ERTStatus const st) const;
        ///
@@ -123,7 +115,7 @@ public:
        ///
        int getMaxWidth(BufferView *, UpdatableInset const *) const;
        ///
-       void update(BufferView *, LyXFont const &, bool =false);
+       void update(BufferView *, bool =false);
 
 private:
        ///