]> git.lyx.org Git - features.git/blobdiff - src/mathed/math_macrotemplate.h
mathed64.diff
[features.git] / src / mathed / math_macrotemplate.h
index e30ef406e893a72f5c4ea2b21243392184aff401..12bdbc0cb3df0d5c9b0e951f84a007611c3b29a1 100644 (file)
@@ -2,13 +2,9 @@
 #ifndef MATHMACROTEMPLATE
 #define MATHMACROTEMPLATE
 
-#include <vector>
-
-#include <boost/utility.hpp>
-//#include <boost/smart_ptr.hpp>
+#include <set>
 
 #include "math_parinset.h"
-#include "math_macroarg.h"
 
 #ifdef __GNUG__
 #pragma interface
@@ -19,44 +15,32 @@ class MathMacro;
 /** This class contains the macro definition
     \author Alejandro Aguilar Sierra
  */
-class MathMacroTemplate : public MathParInset, boost::noncopyable {
+//class MathMacroTemplate : public MathParInset, boost::noncopyable 
+
+class MathMacroTemplate : public MathParInset {
 public:
-       friend class MathMacro;
-       
-       /// A template constructor needs all the data
-       explicit
-       MathMacroTemplate(string const &, int na);
        ///
-       void draw(Painter &, int, int);
+       MathMacroTemplate();
        ///
-       void Metrics();
+       MathMacroTemplate(std::string const & name, int nargs);
        ///
-       void WriteDef(std::ostream &, bool fragile);
-       /// useful for special insets
-       void setTCode(MathedTextCodes t);
-       ///
-       MathedTextCodes getTCode() const;
+       void WriteDef(std::ostream &, bool fragile) const;
        /// Number of arguments
-       int getNoArgs() const;
-       ///
-       void GetMacroXY(int, int &, int &) const;
-       ///
-       MathParInset * getMacroPar(int) const;
+       int nargs() const;
        ///
-       void setMacroPar(int, MathedArray const &);
-       ///
-       void SetMacroFocus(int &, int, int);
+       void draw(Painter &, int, int);
        ///
-       void setEditMode(bool);
+       void Metrics();
 private:
-       /// Are we in edit mode or not?
-       bool edit_;
        ///
-       MathedTextCodes tcode_;
+       int na_;
        ///
-       //std::vector<boost::shared_ptr<MathMacroArgument> > args_;
-       std::vector<MathMacroArgument> args_;
-       ///
-       int nargs_;
+       std::set<MathMacro *> users_;
+
+       /// unimplemented
+       void operator=(MathMacroTemplate const &);
+       /// unimplemented
+       MathMacroTemplate(MathMacroTemplate const &);
 };
+
 #endif