]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathSymbol.h
Do not throw exceptions here either. See r22806.
[lyx.git] / src / mathed / InsetMathSymbol.h
index 5ac141724c2fe3062dce4ab56c29e44fd2ed451b..4730513dec0bd7ce5b52be3ab13066a7468d9e06 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.
  */
@@ -14,7 +14,6 @@
 
 #include "InsetMath.h"
 
-
 namespace lyx {
 
 class latexkeys;
@@ -32,16 +31,16 @@ public:
        ///
        explicit InsetMathSymbol(docstring const & name);
        ///
-       bool metrics(MetricsInfo & mi, Dimension & dim) const;
+       void metrics(MetricsInfo & mi, Dimension & dim) const;
        ///
        void draw(PainterInfo &, int x, int y) const;
        ///
-       int width() const { return width_; }
-       ///
-       int kerning() const { return kerning_; }
+       int kerning(BufferView const *) const { return kerning_; }
 
        ///
        bool isRelOp() const;
+       ///
+       bool isOrdAlpha() const;
        /// do we take scripts?
        bool isScriptable() const;
        /// do we take \limits or \nolimits?
@@ -64,20 +63,25 @@ public:
        ///
        void mathmlize(MathStream &) const;
        ///
+       void htmlize(HtmlStream &) const;
+       /// \param spacing controls whether we print spaces around
+       /// "operator"-type symbols or just print them raw
+       void htmlize(HtmlStream &, bool spacing) const;
+       ///
        void octave(OctaveStream &) const;
        ///
        void write(WriteStream & os) const;
        ///
        void infoize2(odocstream & os) const;
+       ///
+       InsetCode lyxCode() const { return MATH_SYMBOL_CODE; }
 
 private:
-       virtual std::auto_ptr<InsetBase> doClone() const;
+       virtual Inset * clone() const;
        ///
        latexkeys const * sym_;
        ///
        mutable int h_;
-       /// cached width
-       mutable int width_;
        /// cached superscript kerning
        mutable int kerning_;
        ///