]> git.lyx.org Git - lyx.git/blob - src/mathed/InsetMathUnknown.h
106fae98ea4c370728b59f7bc895a9f4f29592a9
[lyx.git] / src / mathed / InsetMathUnknown.h
1 // -*- C++ -*-
2 /**
3  * \file InsetMathUnknown.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author André Pönitz
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef MATH_UNKNOWNINSET_H
13 #define MATH_UNKNOWNINSET_H
14
15 #include "InsetMathDim.h"
16
17
18 namespace lyx {
19
20
21 /// LaTeX names for objects that we really don't know
22 class InsetMathUnknown : public InsetMathDim {
23 public:
24         ///
25         explicit InsetMathUnknown(std::string const & name,
26                 bool final = true, bool black = false);
27         ///
28         void metrics(MetricsInfo & mi, Dimension & dim) const;
29         ///
30         void draw(PainterInfo & pi, int x, int y) const;
31         ///
32         void setName(std::string const & name);
33         ///
34         std::string name() const;
35         /// identifies UnknownInsets
36         InsetMathUnknown const * asUnknownInset() const { return this; }
37         /// identifies UnknownInsets
38         InsetMathUnknown * asUnknownInset() { return this; }
39
40         ///
41         void normalize(NormalStream &) const;
42         ///
43         void maple(MapleStream &) const;
44         ///
45         void mathematica(MathematicaStream &) const;
46         ///
47         void mathmlize(MathMLStream &) const;
48         ///
49         void octave(OctaveStream &) const;
50         ///
51         void finalize();
52         ///
53         bool final() const;
54 private:
55         virtual std::auto_ptr<InsetBase> doClone() const;
56         ///
57         std::string name_;
58         /// are we finished creating the name?
59         bool final_;
60         ///
61         bool black_;
62 };
63
64
65 } // namespace lyx
66 #endif