2003-05-07 07:46:04 +00:00
|
|
|
// -*- C++ -*-
|
2003-08-19 13:00:56 +00:00
|
|
|
/**
|
|
|
|
* \file math_makeboxinset.h
|
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
*
|
|
|
|
* \author Ling Li
|
|
|
|
*
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
*/
|
|
|
|
|
2003-05-07 07:46:04 +00:00
|
|
|
#ifndef MATH_MAKEBOXINSET_H
|
|
|
|
#define MATH_MAKEBOXINSET_H
|
|
|
|
|
|
|
|
#include "math_nestinset.h"
|
|
|
|
|
2003-08-19 13:00:56 +00:00
|
|
|
/// Extra nesting: \\makebox.
|
2003-05-07 07:46:04 +00:00
|
|
|
// consolidate with MathFrameboxInset?
|
|
|
|
|
|
|
|
class MathMakeboxInset : public MathNestInset {
|
|
|
|
public:
|
|
|
|
///
|
|
|
|
MathMakeboxInset();
|
|
|
|
///
|
2003-07-25 17:11:25 +00:00
|
|
|
virtual std::auto_ptr<InsetBase> clone() const;
|
2003-05-07 07:46:04 +00:00
|
|
|
///
|
2003-06-02 10:03:27 +00:00
|
|
|
void metrics(MetricsInfo & mi, Dimension & dim) const;
|
2003-05-07 07:46:04 +00:00
|
|
|
///
|
|
|
|
void draw(PainterInfo & pi, int x, int y) const;
|
|
|
|
///
|
|
|
|
void write(WriteStream & os) const;
|
|
|
|
/// write normalized content
|
|
|
|
void normalize(NormalStream & ns) const;
|
|
|
|
///
|
|
|
|
mode_type currentMode() const { return TEXT_MODE; }
|
|
|
|
private:
|
|
|
|
/// width of '[' in current font
|
|
|
|
mutable int w_;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|