1 #ifndef MATH_METRICSINFO_H
2 #define MATH_METRICSINFO_H
13 /// Standard Math Sizes (Math mode styles)
26 struct MathMetricsBase {
39 struct MathMetricsInfo {
47 /// used to pass some info down
48 MathNestInset const * inset;
56 struct MathPainterInfo {
58 MathPainterInfo(Painter & p);
60 void draw(int x, int y, char c);
69 struct TextMetricsInfo {};
72 // Generic base for temporarily changing things.
73 // The original state gets restored when the Changer is destructed
74 template <class Struct, class Temp = Struct>
77 MathChanger(Struct & orig) : orig_(orig) {}
87 struct MathScriptChanger : public MathChanger<MathMetricsBase> {
89 MathScriptChanger(MathMetricsBase & orig);
95 struct MathFracChanger : public MathChanger<MathMetricsBase> {
97 MathFracChanger(MathMetricsBase & orig);
104 struct MathFontChanger : public MathChanger<LyXFont> {
106 MathFontChanger(LyXFont & orig, char const * font);
112 struct MathFontSetChanger : public MathChanger<MathMetricsBase> {
114 MathFontSetChanger(MathMetricsBase & mb, char const * font);
116 ~MathFontSetChanger();
120 struct MathStyleChanger : public MathChanger<MathMetricsBase> {
122 MathStyleChanger(MathMetricsBase & mb, MathStyles shape);
128 struct MathShapeChanger : public MathChanger<LyXFont, LyXFont::FONT_SHAPE> {
130 MathShapeChanger(LyXFont & font, LyXFont::FONT_SHAPE shape);