]> git.lyx.org Git - lyx.git/blob - src/insets/insettoc.h
Fix small bug in reading \set_color in lyxrc
[lyx.git] / src / insets / insettoc.h
1 // -*- C++ -*-
2 /* This file is part of*
3  * ======================================================
4  *
5  *           LyX, The Document Word Processor
6  *       
7  *           Copyright 1995 Matthias Ettrich
8  *           Copyright 1996-2000 The LyX Team.
9  * 
10  * ====================================================== */
11
12 #ifndef INSET_TOC_H
13 #define INSET_TOC_H
14
15 #ifdef __GNUG__
16 #pragma interface
17 #endif
18
19 #include "insetcommand.h"
20
21 class Buffer;
22
23 /** Used to insert table of contents
24  */
25 class InsetTOC : public InsetCommand {
26 public:
27         ///
28         InsetTOC() : InsetCommand("tableofcontents") {}
29         ///
30         explicit
31         InsetTOC(Buffer * b) : InsetCommand("tableofcontents"), owner(b) {}
32         ///
33         Inset * Clone() const { return new InsetTOC(owner); }
34         ///
35         string getScreenLabel() const;
36         /// On edit, we open the TOC pop-up
37         void Edit(BufferView * bv, int, int, unsigned int);
38         ///
39         EDITABLE Editable() const {
40                 return IS_EDITABLE;
41         }
42         ///
43         bool display() const { return true; }
44         ///
45         Inset::Code LyxCode() const { return Inset::TOC_CODE; }
46         ///
47         int Linuxdoc(Buffer const *, std::ostream &) const;
48         ///
49         int DocBook(Buffer const *, std::ostream &) const;
50 private:
51         ///
52         Buffer * owner;
53 };
54
55 #endif