]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathCommand.h
Cell in delimiter inset should not be tight
[lyx.git] / src / mathed / InsetMathCommand.h
index 93c280aa38c9be54616f39e6820e5b92d465a6ed..da4269c9ef9df1cc0f6dec41c8168931be5c36d1 100644 (file)
@@ -4,7 +4,7 @@
  * This file is part of LyX, the document processor.
  * Licence details can be found in the file COPYING.
  *
- * \author André Pönitz
+ * \author André Pönitz
  *
  * Full author contact details are available in file CREDITS.
  */
 
 #include "InsetMathNest.h"
 
-#include "insets/render_button.h"
+#include "insets/RenderButton.h"
 
 
 namespace lyx {
 
 
 /// Inset for things like \name[options]{contents}
-class CommandInset : public InsetMathNest {
+class InsetMathCommand : public InsetMathNest {
 public:
        ///
-       explicit CommandInset(docstring const & name);
+       explicit InsetMathCommand(Buffer * buf, docstring const & name,
+               bool needs_math_mode = true);
        ///
-       bool metrics(MetricsInfo & mi, Dimension & dim) const;
+       marker_type marker(BufferView const *) const { return NO_MARKER; }
+       ///
+       void metrics(MetricsInfo & mi, Dimension & dim) const;
        ///
        void draw(PainterInfo & pi, int x, int y) const;
        ///
-       InsetBase * editXY(LCursor &, int, int);
+       Inset * editXY(Cursor &, int, int);
        ///
        void write(WriteStream & os) const;
        //
        // void infoize(odocstream & os) const;
        ///
        virtual docstring const screenLabel() const;
-       /// generate something that will be understood by the Dialogs.
-       std::string const createDialogStr(std::string const & name) const;
        ///
        docstring const & commandname() const { return name_; }
+       ///
+       bool isActive() const { return false; }
+
 private:
-       virtual std::auto_ptr<InsetBase> doClone() const;
+       virtual Inset * clone() const;
 
        ///
        docstring name_;
        ///
+       bool needs_math_mode_;
+       ///
        mutable bool set_label_;
        ///
        mutable RenderButton button_;