]> git.lyx.org Git - lyx.git/blob - src/mathed/math_gridinfo.h
Get rid of trailing whitespace 'noise' in future patches for the
[lyx.git] / src / mathed / math_gridinfo.h
1 // -*- C++ -*-
2 /**
3  * \file math_gridinfo.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_GRIDINFO_H
13 #define MATH_GRIDINFO_H
14
15 #include "support/std_string.h"
16
17 struct ColInfo
18 {
19         ColInfo() : align('c'), rightline(0), leftline(false) {}
20         char   align;      // column alignment
21         string width;      // column width
22         string special;    // special column alignment
23         int    rightline;  // a line on the right?
24         bool   leftline;
25 };
26
27
28 struct RowInfo
29 {
30         RowInfo() : topline(false), bottomline(false) {}
31         bool topline;     // horizontal line above
32         int  bottomline;  // horizontal line below
33 };
34
35
36 struct CellInfo
37 {
38         CellInfo()
39                 : multi(0), leftline(false), rightline(false),
40            topline(false), bottomline(false)
41         {}
42
43         string content;    // cell content
44         int multi;         // multicolumn flag
45         char align;        // cell alignment
46         bool leftline;     // do we have a line on the left?
47         bool rightline;    // do we have a line on the right?
48         bool topline;        // do we have a line above?
49         bool bottomline;   // do we have a line below?
50 };
51
52
53 inline char const * verbose_align(char c)
54 {
55         return c == 'c' ? "center" : c == 'r' ? "right" : c == 'l' ? "left" : "none";
56 }
57
58
59 #endif