3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
6 * \author Angus Leeming
8 * Full author contact details are available in file CREDITS
14 #pragma implementation
17 #include "ControlToc.h"
20 #include "support/lstrings.h" // tostr
26 ControlToc::ControlToc(LyXView & lv, Dialogs & d)
27 : ControlCommand(lv, d, LFUN_TOC_INSERT)
31 void ControlToc::goTo(toc::TocItem const & item) const
37 vector<string> const ControlToc::getTypes() const
39 return toc::getTypes(buffer());
43 toc::Toc const ControlToc::getContents(string const & type) const
47 // This shouldn't be possible...
48 if (!bufferIsAvailable()) {
52 toc::TocList tmp = toc::getTocList(buffer());
53 toc::TocList::iterator it = tmp.find(type);
54 if (it == tmp.end()) {