]> git.lyx.org Git - lyx.git/blob - src/insets/insetert.h
Remove unused font variable which caused a warning.
[lyx.git] / src / insets / insetert.h
1 // -*- C++ -*-
2 /* This file is part of
3  * ======================================================
4  * 
5  *           LyX, The Document Processor
6  *
7  *           Copyright 1998 The LyX Team.
8  *
9  *======================================================
10  */
11 // The pristine updatable inset: Text
12
13
14 #ifndef INSETERT_H
15 #define INSETERT_H
16
17 #ifdef __GNUG__
18 #pragma interface
19 #endif
20
21 #include "insetcollapsable.h"
22
23 /** A collapsable text inset for LaTeX insertions.
24   
25   To write full ert (including styles and other insets) in a given
26   space. 
27 */
28 class InsetERT : public InsetCollapsable {
29 public:
30         ///
31         InsetERT();
32         ///
33         InsetERT(InsetERT const &, bool same_id = false);
34         ///
35         Inset * clone(Buffer const &, bool same_id = false) const;
36         ///
37         InsetERT(string const & contents, bool collapsed);
38         ///
39         Inset::Code lyxCode() const { return Inset::ERT_CODE; }
40         ///
41         void read(Buffer const * buf, LyXLex & lex);
42         ///
43         void write(Buffer const * buf, std::ostream & os) const;
44         ///
45         string const editMessage() const;
46         ///
47         bool insertInset(BufferView *, Inset *);
48         ///
49         bool insetAllowed(Inset::Code) const { return false; }
50         ///
51         void setFont(BufferView *, LyXFont const &,
52                              bool toggleall = false, bool selectall = false);
53         ///
54         void edit(BufferView *, int, int, unsigned int);
55         ///
56         void edit(BufferView * bv, bool front = true);
57         ///
58         void insetButtonRelease(BufferView * bv, int x, int y, int button);
59         ///
60         int latex(Buffer const *, std::ostream &, bool fragile,
61                   bool free_spc) const;
62         ///
63         int ascii(Buffer const *,
64                           std::ostream &, int linelen = 0) const;
65         ///
66         int linuxdoc(Buffer const *, std::ostream &) const;
67         ///
68         int docBook(Buffer const *, std::ostream &) const;
69         ///
70         UpdatableInset::RESULT localDispatch(BufferView *, kb_action,
71                                              string const &);
72         ///
73         bool checkInsertChar(LyXFont &);
74
75 private:
76         ///
77         void init();
78         ///
79         string const get_new_label() const;
80         ///
81         void setButtonLabel();
82 };
83
84 #endif