3 * \file lyxtextclasslist.h
4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Lars Gullik Bjønnes
9 * Full author contact details are available in file CREDITS.
12 #ifndef LYXTEXTCLASSLIST_H
13 #define LYXTEXTCLASSLIST_H
15 #include "support/types.h"
17 #include <boost/utility.hpp>
25 /// Reads the style files
26 extern void LyXSetStyle();
29 class LyXTextClassList
: boost::noncopyable
{
32 typedef std::vector
<LyXTextClass
> ClassList
;
34 typedef ClassList::const_iterator const_iterator
;
36 const_iterator
begin() const { return classlist_
.begin(); }
38 const_iterator
end() const { return classlist_
.end(); }
40 /// Gets textclass number from name, -1 if textclass name does not exist
41 std::pair
<bool, lyx::textclass_type
> const
42 NumberOfClass(std::string
const & textclass
) const;
45 LyXTextClass
const & operator[](lyx::textclass_type textclass
) const;
47 /// Read textclass list. Returns false if this fails.
51 mutable ClassList classlist_
;
55 extern LyXTextClassList textclasslist
;