4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Martin Vermeer
10 * Full author contact details are available in file CREDITS.
13 #ifndef INSET_LAYOUT_H
14 #define INSET_LAYOUT_H
16 #include "ColorCode.h"
19 #include "support/docstring.h"
35 enum InsetDecoration {
56 bool read(Lexer & lexrc, TextClass const & tclass);
58 docstring name() const { return name_; };
60 void setName(docstring const & n) { name_ = n; }
62 InsetLyXType lyxtype() const { return lyxtype_; };
64 docstring labelstring() const { return labelstring_; };
66 InsetDecoration decoration() const { return decoration_; };
68 InsetLaTeXType latextype() const { return latextype_; };
70 std::string latexname() const { return latexname_; };
72 std::string latexparam() const { return latexparam_; };
74 FontInfo font() const { return font_; };
76 FontInfo labelfont() const { return labelfont_; };
78 ColorCode bgcolor() const { return bgcolor_; };
80 docstring preamble() const { return preamble_; };
82 std::string const & htmltag() const { return htmltag_; }
84 std::string const & htmlattr() const { return htmlattr_; }
86 docstring htmlstyle() const { return htmlstyle_; }
88 std::set<std::string> requires() const { return requires_; };
90 bool isMultiPar() const { return multipar_; };
92 bool forcePlainLayout() const { return forceplain_; }
94 bool allowParagraphCustomization() const { return custompars_; }
96 bool isPassThru() const { return passthru_; };
98 bool isNeedProtect() const { return needprotect_; };
100 bool isFreeSpacing() const { return freespacing_; };
102 bool isKeepEmpty() const { return keepempty_; };
104 bool isForceLtr() const { return forceltr_; };
106 bool isInToc() const { return intoc_; };
111 * This is only used (at present) to decide where to put them on the menus.
112 * Values are 'charstyle', 'custom' (things that by default look like a
113 * footnote), 'element' (docbook), 'standard'.
115 InsetLyXType lyxtype_;
117 docstring labelstring_;
119 InsetDecoration decoration_;
121 InsetLaTeXType latextype_;
123 std::string latexname_;
125 std::string latexparam_;
135 std::string htmltag_;
137 std::string htmlattr_;
139 docstring htmlstyle_;
141 std::set<std::string> requires_;
158 /// should the contents be written to TOC strings?
163 InsetLayout::InsetLyXType translateLyXType(std::string const & str);