]> git.lyx.org Git - lyx.git/blob - src/mathed/InsetMathAMSArray.h
Account for old versions of Pygments
[lyx.git] / src / mathed / InsetMathAMSArray.h
1 // -*- C++ -*-
2 /**
3  * \file InsetMathAMSArray.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_AMSARRAYINSET_H
13 #define MATH_AMSARRAYINSET_H
14
15 #include "InsetMathGrid.h"
16
17
18 namespace lyx {
19
20 /// Inset for things like [pbvV]matrix, psmatrix etc
21 class InsetMathAMSArray : public InsetMathGrid {
22 public:
23         ///
24         InsetMathAMSArray(Buffer * buf, docstring const &, int m, int n);
25         ///
26         InsetMathAMSArray(Buffer * buf, docstring const &);
27         ///
28         void metrics(MetricsInfo & mi, Dimension & dim) const;
29         ///
30         void draw(PainterInfo & pain, int x, int y) const;
31         ///
32         InsetMathAMSArray * asAMSArrayInset() { return this; }
33         ///
34         InsetMathAMSArray const * asAMSArrayInset() const { return this; }
35
36         ///
37         bool getStatus(Cursor & cur, FuncRequest const & cmd,
38                 FuncStatus & flag) const;
39         ///
40         void write(WriteStream & os) const;
41         ///
42         void infoize(odocstream & os) const;
43         ///
44         void normalize(NormalStream &) const;
45         // Don't need mathmlize or htmlize, as this is handled by 
46         // InsetMathMatrix after being extracted in MathExtern.
47         // void mathmlize(MathStream &) const;
48         // void htmlize(HTMLStream &) const;
49         ///
50         void validate(LaTeXFeatures & features) const;
51         ///
52         InsetCode lyxCode() const { return MATH_AMSARRAY_CODE; }
53         ///
54         char const * name_left() const;
55         ///
56         char const * name_right() const;
57         ///
58         int leftMargin() const { return 6; } //override
59         ///
60         int rightMargin() const { return 8; } //override
61         ///
62         bool handlesMulticolumn() const { return true; } //override
63
64 private:
65         virtual Inset * clone() const;
66         ///
67         docstring name_;
68 };
69
70 } // namespace lyx
71
72 #endif