]> git.lyx.org Git - lyx.git/blob - src/mathed/InsetMathUnknown.h
* completion infrastructure
[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 "InsetMath.h"
16
17
18 namespace lyx {
19
20
21 /// LaTeX names for objects that we really don't know
22 class InsetMathUnknown : public InsetMath {
23 public:
24         ///
25         explicit InsetMathUnknown(docstring 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(docstring const & name);
33         ///
34         docstring name() const;
35
36         /// identifies UnknownInsets
37         InsetMathUnknown const * asUnknownInset() const { return this; }
38         /// identifies UnknownInsets
39         InsetMathUnknown * asUnknownInset() { return this; }
40
41         ///
42         void normalize(NormalStream &) const;
43         ///
44         void maple(MapleStream &) const;
45         ///
46         void mathematica(MathematicaStream &) const;
47         ///
48         void mathmlize(MathStream &) const;
49         ///
50         void octave(OctaveStream &) const;
51         ///
52         void finalize();
53         ///
54         bool final() const;
55         ///
56         int kerning(BufferView const *) const { return kerning_; }
57 private:
58         virtual Inset * clone() const;
59         ///
60         docstring name_;
61         /// are we finished creating the name?
62         bool final_;
63         ///
64         bool black_;
65         ///
66         mutable int kerning_;
67 };
68
69
70 } // namespace lyx
71 #endif