]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/formula.h
architectural changes to tex2lyx
[lyx.git] / src / mathed / formula.h
index 8074c37f86cea37b9c99c532a6fb3ccf41a667a4..63b85275fe78c6685155bdf590be749c23f3711c 100644 (file)
 #ifndef INSET_FORMULA_H
 #define INSET_FORMULA_H
 
-
 #include "formulabase.h"
 #include "math_atom.h"
 
 #include <boost/scoped_ptr.hpp>
 
+
 /// The main LyX math inset
 class InsetFormula : public InsetFormulaBase {
 public:
@@ -29,15 +29,15 @@ public:
        ///
        explicit InsetFormula(BufferView *);
        ///
-       explicit InsetFormula(const string & data);
+       explicit InsetFormula(string const & data);
        ///
        InsetFormula(InsetFormula const &);
        ///
        ~InsetFormula();
        ///
-       void dimension(BufferView *, LyXFont const &, Dimension &) const;
+       void metrics(MetricsInfo & mi, Dimension & dim) const;
        ///
-       void draw(BufferView *, LyXFont const &, int, float &) const;
+       void draw(PainterInfo & pi, int x, int y) const;
 
        ///
        void write(Buffer const *, std::ostream &) const;
@@ -54,17 +54,15 @@ public:
        int docbook(Buffer const *, std::ostream &, bool mixcont) const;
 
        ///
-       Inset * clone(Buffer const &) const;
-       ///
-       //Inset * clone(Buffer const &, bool same_id) const;
+       virtual std::auto_ptr<InsetBase> clone() const;
        ///
        void validate(LaTeXFeatures & features) const;
        ///
-       Inset::Code lyxCode() const;
+       InsetOld::Code lyxCode() const;
        ///
-       bool insetAllowed(Inset::Code code) const;
+       bool insetAllowed(InsetOld::Code code) const;
        ///
-       std::vector<string> const getLabelList() const;
+       void getLabelList(std::vector<string> &) const;
        ///
        MathAtom const & par() const { return par_; }
        ///
@@ -72,7 +70,7 @@ public:
        ///
        void generatePreview() const;
        ///
-       void addPreview(grfx::PreviewLoader &) const;
+       void addPreview(lyx::graphics::PreviewLoader &) const;
        ///
        void mutate(string const & type);