+ /// A DocumentClass nevers count as loaded, since it is dynamic
+ virtual bool loaded() { return false; }
+ /// Inset layouts of this doc class
+ InsetLayouts const & insetLayouts() const { return insetlayoutlist_; };
+ /// \return the layout object of an inset given by name. If the name
+ /// is not found as such, the part after the ':' is stripped off, and
+ /// searched again. In this way, an error fallback can be provided:
+ /// An erroneous 'CharStyle:badname' (e.g., after a documentclass switch)
+ /// will invoke the layout object defined by name = 'CharStyle'.
+ /// If that doesn't work either, an empty object returns (shouldn't
+ /// happen). -- Idea JMarc, comment MV
+ InsetLayout const & insetLayout(docstring const & name) const;
+ /// an empty inset layout for use as a default
+ static InsetLayout const & emptyInsetLayout() { return empty_insetlayout_; }
+
+ ///////////////////////////////////////////////////////////////////
+ // accessors
+ ///////////////////////////////////////////////////////////////////
+ /// the list of floats defined in the document class
+ FloatList const & floats() const { return floatlist_; }
+ ///
+ Counters & counters() const { return counters_; }
+ ///
+ std::string const & opt_fontsize() const { return opt_fontsize_; }
+ ///
+ std::string const & opt_pagestyle() const { return opt_pagestyle_; }
+ ///
+ std::string const & options() const { return options_; }
+ ///
+ std::string const & class_header() const { return class_header_; }
+ ///
+ std::string const & pagestyle() const { return pagestyle_; }
+ ///
+ docstring const & preamble() const { return preamble_; }
+ /// is this feature already provided by the class?
+ bool provides(std::string const & p) const;
+ /// features required by the class?
+ std::set<std::string> const & requires() const { return requires_; }
+ ///
+ unsigned int columns() const { return columns_; }
+ ///
+ PageSides sides() const { return sides_; }
+ ///
+ int secnumdepth() const { return secnumdepth_; }
+ ///
+ int tocdepth() const { return tocdepth_; }
+ ///
+ FontInfo const & defaultfont() const { return defaultfont_; }
+ /// Text that dictates how wide the left margin is on the screen
+ docstring const & leftmargin() const { return leftmargin_; }
+ /// Text that dictates how wide the right margin is on the screen
+ docstring const & rightmargin() const { return rightmargin_; }
+ /// The type of command used to produce a title
+ TitleLatexType titletype() const { return titletype_; };
+ /// The name of the title command
+ std::string const & titlename() const { return titlename_; };
+ ///
+ int size() const { return layoutlist_.size(); }
+ /// The minimal TocLevel of sectioning layouts
+ int min_toclevel() const { return min_toclevel_; }
+ /// The maximal TocLevel of sectioning layouts
+ int max_toclevel() const { return max_toclevel_; }
+ /// returns true if the class has a ToC structure
+ bool hasTocLevels() const;
+ /// Can be LaTeX, DocBook, etc.
+ OutputType outputType() const { return outputType_; }
+protected:
+ /// Constructs a DocumentClass based upon a LayoutFile.
+ DocumentClass(LayoutFile const & tc);
+ /// Needed in tex2lyx
+ DocumentClass() {}