X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fmathed%2FCommandInset.h;h=770ecb388d78d6e98808d5a2446157599376a6f8;hb=e1d9ad9f2802875bc233122e14c8d273a95dd1ed;hp=22cdb1935e9c88bbd296df1dfb63ff25719f209e;hpb=42123ab8a71080b6d15fca4e0c43ae76abf00a1e;p=lyx.git diff --git a/src/mathed/CommandInset.h b/src/mathed/CommandInset.h index 22cdb1935e..770ecb388d 100644 --- a/src/mathed/CommandInset.h +++ b/src/mathed/CommandInset.h @@ -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. */ @@ -25,13 +25,14 @@ namespace lyx { class CommandInset : public InsetMathNest { public: /// - explicit CommandInset(docstring const & name); + explicit CommandInset(Buffer * buf, docstring const & name, + bool needs_math_mode = true); /// - bool metrics(MetricsInfo & mi, Dimension & dim) const; + void metrics(MetricsInfo & mi, Dimension & dim) const; /// void draw(PainterInfo & pi, int x, int y) const; /// - InsetBase * editXY(Cursor &, int, int); + Inset * editXY(Cursor &, int, int); /// void write(WriteStream & os) const; // @@ -40,12 +41,17 @@ public: virtual docstring const screenLabel() const; /// docstring const & commandname() const { return name_; } + /// + bool isActive() const { return false; } + private: - virtual std::auto_ptr doClone() const; + virtual Inset * clone() const; /// docstring name_; /// + bool needs_math_mode_; + /// mutable bool set_label_; /// mutable RenderButton button_;