2 /* This file is part of*
3 * ======================================================
5 * LyX, The Document Word Processor
7 * Copyright 1995 Matthias Ettrich
8 * Copyright 1996-2000 The LyX Team.
10 * ====================================================== */
19 #include "insetcommand.h"
26 /** Used to insert table of contents
28 class InsetTOC : public InsetCommand {
31 InsetTOC() : InsetCommand("tableofcontents") {}
33 InsetTOC(Buffer * b) : InsetCommand("tableofcontents"), owner(b) {}
35 Inset * Clone() const { return new InsetTOC(owner); }
37 string getScreenLabel() const { return _("Table of Contents"); }
38 /// On edit, we open the TOC pop-up
39 void Edit(BufferView * bv, int, int, unsigned int);
41 EDITABLE Editable() const {
45 bool display() const { return true; }
47 Inset::Code LyxCode() const { return Inset::TOC_CODE; }
49 int Linuxdoc(ostream &) const;
51 int DocBook(ostream &) const;