X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Flyxlayout.h;h=2d12777bf6b48d09114c234b1393a92627c7f219;hb=35204f8f33d7400a5fefeffea533fb4cb4097211;hp=adc64f7135ce94005646cb323323c7a783c08ea0;hpb=44cd0fc9a1687cc63911c7f98d978594458e7813;p=lyx.git diff --git a/src/lyxlayout.h b/src/lyxlayout.h index adc64f7135..2d12777bf6 100644 --- a/src/lyxlayout.h +++ b/src/lyxlayout.h @@ -17,9 +17,13 @@ #include "lyxfont.h" #include "layout.h" #include "Spacing.h" +#include "support/docstring.h" #include + +namespace lyx { + class LyXLex; class LyXTextClass; @@ -29,7 +33,7 @@ public: /// LyXLayout(); /// - bool Read(LyXLex &, LyXTextClass const &); + bool read(LyXLex &, LyXTextClass const &); /// void readAlign(LyXLex &); /// @@ -55,15 +59,21 @@ public: /// std::string const & latexname() const { return latexname_; } /// - std::string const & labelstring() const { return labelstring_; } + lyx::docstring const & labelstring() const { return labelstring_; } /// - std::string const & endlabelstring() const { return endlabelstring_; } + lyx::docstring const & endlabelstring() const { return endlabelstring_; } /// - std::string const & preamble() const { return preamble_; } + docstring const & preamble() const { return preamble_; } /// std::string const & latexparam() const { return latexparam_; } /// - std::string const & labelstring_appendix() const { + std::string const & innertag() const { return innertag_; } + /// + std::string const & labeltag() const { return labeltag_; } + /// + std::string const & itemtag() const { return itemtag_; } + /// + lyx::docstring const & labelstring_appendix() const { return labelstring_appendix_; } /** Default font for this layout/environment. @@ -104,17 +114,17 @@ public: /// Text that dictates the width of the indentation of indented pars std::string parindent; /// - float parskip; + double parskip; /// - float itemsep; + double itemsep; /// - float topsep; + double topsep; /// - float bottomsep; + double bottomsep; /// - float labelbottomsep; + double labelbottomsep; /// - float parsep; + double parsep; /// Spacing spacing; /// @@ -143,6 +153,8 @@ public: bool is_environment; /// show this in toc int toclevel; + /// special value of toclevel for non-section layouts + static const int NOT_IN_TOC; /// for new environment insets std::string latexheader; /// for new environment insets @@ -177,7 +189,9 @@ public: /// Does this layout allow for an optional parameter? int optionalargs; /// Which counter to step - std::string counter; + lyx::docstring counter; + /// Depth of XML command + int commanddepth; private: /// Name of the layout/paragraph environment @@ -198,15 +212,24 @@ private: /// LaTeX name for environment std::string latexname_; /// Label string. "Abstract", "Reference", "Caption"... - std::string labelstring_; + lyx::docstring labelstring_; /// - std::string endlabelstring_; + lyx::docstring endlabelstring_; /// Label string inside appendix. "Appendix", ... - std::string labelstring_appendix_; + lyx::docstring labelstring_appendix_; /// LaTeX parameter for environment std::string latexparam_; + /// Internal tag to use (e.g., for sect header) + std::string innertag_; + /// Internal tag to use e.g. to surround varlistentry label) + std::string labeltag_; + /// Internal tag to surround the item text in a list) + std::string itemtag_; /// Macro definitions needed for this layout - std::string preamble_; + docstring preamble_; }; + +} // namespace lyx + #endif