4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS.
15 #include "support/FileName.h"
23 * This struct represents a particular LyX "module", which is a like a layout
24 * file, except that it does not stand alone. In that sense, it is more like
25 * a LaTeX package, where a layout file corresponds to a LaTeX class.
28 /// what appears in the ui
30 /// the filename, without any path
32 /// a short description for use in the ui
33 std::string description;
34 /// the LaTeX packages on which this depends, if any (not implemented)
35 std::vector<std::string> packageList;
36 /// whether those packages are available (not implemented yet)
40 typedef std::vector<LyXModule> LyXModuleList;
43 * The ModuleList represents the various LyXModule's that are available at
50 /// reads the modules from a file generated by configure.py
52 /// add a module to the list
53 void addLayoutModule(std::string const & name,
54 std::string const & filename, std::string const & description,
55 std::vector<std::string> const & packages);
57 LyXModuleList::const_iterator begin() const;
59 LyXModuleList::iterator begin();
61 LyXModuleList::const_iterator end() const;
63 LyXModuleList::iterator end();
65 bool empty() const { return modlist_.empty(); }
66 /// Returns a pointer to the LyXModule with name str.
67 /// Returns a null pointer if no such module is found.
68 LyXModule * operator[](std::string const & str);
71 ModuleList(ModuleList const &);
72 void operator=(ModuleList const &);
75 std::vector<LyXModule> modlist_;
78 extern ModuleList moduleList;