]> git.lyx.org Git - lyx.git/blob - src/ParameterStruct.h
ws changes only
[lyx.git] / src / ParameterStruct.h
1 // -*- C++ -*-
2 /**
3  * \file ParameterStruct.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Lars Gullik Bjønnes
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef PARAMETERSTRUCT_H
13 #define PARAMETERSTRUCT_H
14
15 #include "layout.h"
16 #include "lyxlength.h"
17 #include "Spacing.h"
18 #include "vspace.h"
19
20 #include "support/types.h"
21
22
23 ///
24 struct ParameterStruct {
25         ///
26         typedef lyx::depth_type depth_type;
27         ///
28         ParameterStruct();
29         ///
30         VSpace added_space_top;
31         ///
32         VSpace added_space_bottom;
33         ///
34         Spacing spacing;
35         ///
36         bool noindent;
37         ///
38         bool line_top;
39         ///
40         bool line_bottom;
41         ///
42         bool pagebreak_top;
43         ///
44         bool pagebreak_bottom;
45         ///
46         LyXAlignment align;
47         ///
48         depth_type depth;
49         ///
50         bool start_of_appendix;
51         ///
52         bool appendix;
53         ///
54         std::string labelstring;
55         ///
56         std::string labelwidthstring;
57         ///
58         LyXLength leftindent;
59 };
60
61
62 inline
63 ParameterStruct::ParameterStruct()
64         : noindent(false), line_top(false), line_bottom(false),
65           pagebreak_top(false), pagebreak_bottom(false),
66           align(LYX_ALIGN_BLOCK), depth(0), start_of_appendix(false),
67           appendix(false)
68 {}
69
70
71 inline
72 bool operator==(ParameterStruct const & ps1,
73                 ParameterStruct const & ps2)
74 {
75         return ps1.added_space_top == ps2.added_space_top
76                 && ps1.added_space_bottom == ps2.added_space_bottom
77                 && ps1.spacing == ps2.spacing
78                 && ps1.noindent == ps2.noindent
79                 && ps1.line_top == ps2.line_top
80                 && ps1.line_bottom == ps2.line_bottom
81                 && ps1.pagebreak_top == ps2.pagebreak_top
82                 && ps1.pagebreak_bottom == ps2.pagebreak_bottom
83                 && ps1.align == ps2.align
84                 && ps1.depth == ps2.depth
85                 && ps1.start_of_appendix == ps2.start_of_appendix
86                 && ps1.appendix == ps2.appendix
87                 && ps1.labelstring == ps2.labelstring
88                 && ps1.labelwidthstring == ps2.labelwidthstring
89                 && ps1.leftindent == ps2.leftindent;
90
91 }
92
93 #endif