]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_fontinset.h
Remove mixed_content from output parameters.
[lyx.git] / src / mathed / math_fontinset.h
index 1c62eb9a7b0071844297b8ff5608fb8cf799fd3f..5174823b0435ab38c55385dbb159f797a1cb69bf 100644 (file)
@@ -1,39 +1,45 @@
 // -*- C++ -*-
+/**
+ * \file math_fontinset.h
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
+ *
+ * \author André Pönitz
+ *
+ * Full author contact details are available in file CREDITS.
+ */
+
 #ifndef MATH_FONTINSET_H
 #define MATH_FONTINSET_H
 
 #include "math_nestinset.h"
-#include "LString.h"
-#include "lyxfont.h"
 
-#ifdef __GNUG__
-#pragma interface
-#endif
 
-/** The base character inset.
-    \author André Pönitz
- */
+class latexkeys;
 
+/// Inset for font changes
 class MathFontInset : public MathNestInset {
 public:
        ///
-       explicit MathFontInset(string const & name);
+       explicit MathFontInset(latexkeys const * key);
        ///
-       MathInset * clone() const;
+       virtual std::auto_ptr<InsetBase> clone() const;
        ///
-       void metrics(MathMetricsInfo & st) const;
+       MathFontInset * asFontInset() { return this; }
        ///
-       void draw(MathPainterInfo &, int x, int y) const;
+       MathFontInset const * asFontInset() const { return this; }
+       /// are we in math mode, text mode, or unsure?
+       mode_type currentMode() const;
        ///
-       void metricsT(TextMetricsInfo const & st) const;
+       std::string name() const;
        ///
-       void drawT(TextPainter &, int x, int y) const;
+       void metrics(MetricsInfo & mi, Dimension & dim) const;
        ///
-       void write(WriteStream & os) const;
+       void draw(PainterInfo & pi, int x, int y) const;
        ///
-       void normalize(NormalStream &) const;
-       /// identifies Fontinsets
-       MathFontInset const * asFontInset() const { return this; }
+       void metricsT(TextMetricsInfo const & mi, Dimension & dim) const;
+       ///
+       void drawT(TextPainter & pi, int x, int y) const;
        ///
        void validate(LaTeXFeatures & features) const;
        ///
@@ -41,6 +47,6 @@ public:
 
 private:
        /// the font to be used on screen
-       string name_;
+       latexkeys const * key_;
 };
 #endif