2001-10-19 11:25:48 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
#ifndef MATH_BOXINSET_H
|
|
|
|
#define MATH_BOXINSET_H
|
|
|
|
|
2001-12-18 12:21:33 +00:00
|
|
|
#include "math_gridinset.h"
|
2001-10-19 11:25:48 +00:00
|
|
|
#include "LString.h"
|
|
|
|
|
|
|
|
#ifdef __GNUG__
|
|
|
|
#pragma interface
|
|
|
|
#endif
|
|
|
|
|
|
|
|
class LyXFont;
|
|
|
|
|
|
|
|
/// Support for \\mbox
|
|
|
|
|
2001-12-18 12:21:33 +00:00
|
|
|
class MathBoxInset : public MathGridInset {
|
2001-10-19 11:25:48 +00:00
|
|
|
public:
|
|
|
|
///
|
|
|
|
explicit MathBoxInset(string const &);
|
|
|
|
///
|
|
|
|
MathInset * clone() const;
|
2001-12-18 12:21:33 +00:00
|
|
|
/// identifies BoxInsets
|
|
|
|
MathBoxInset * asBoxInset() { return this; }
|
|
|
|
/// identifies BoxInsets
|
|
|
|
MathBoxInset const * asBoxInset() const { return this; }
|
2001-10-19 11:25:48 +00:00
|
|
|
///
|
2001-12-18 12:21:33 +00:00
|
|
|
void rebreak();
|
2001-10-19 11:25:48 +00:00
|
|
|
///
|
2001-11-09 08:35:57 +00:00
|
|
|
void write(WriteStream & os) const;
|
2001-10-19 11:25:48 +00:00
|
|
|
///
|
2001-11-09 08:35:57 +00:00
|
|
|
void normalize(NormalStream &) const;
|
2001-10-19 11:25:48 +00:00
|
|
|
///
|
2002-05-30 07:09:54 +00:00
|
|
|
void draw(MathPainterInfo &, int x, int y) const;
|
2001-10-19 11:25:48 +00:00
|
|
|
|
|
|
|
private:
|
2001-10-22 15:37:49 +00:00
|
|
|
///
|
|
|
|
mutable MathMetricsInfo mi_;
|
2001-10-19 11:25:48 +00:00
|
|
|
///
|
|
|
|
string name_;
|
|
|
|
};
|
|
|
|
#endif
|