]> git.lyx.org Git - lyx.git/blob - src/insets/insetfloat.h
dont use pragma impementation and interface anymore
[lyx.git] / src / insets / insetfloat.h
1 // -*- C++ -*-
2 /**
3  * \file insetfloat.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Jürgen Vigna
8  * \author Lars Gullik Bjønnes
9  *
10  * Full author contact details are available in file CREDITS
11  */
12
13 #ifndef InsetFloat_H
14 #define InsetFloat_H
15
16
17 #include "insetcollapsable.h"
18 #include "toc.h"
19
20 #include <boost/signals/signal0.hpp>
21
22 class Painter;
23
24 /** The float inset
25
26 */
27 class InsetFloat : public InsetCollapsable {
28 public:
29         ///
30         InsetFloat(BufferParams const &, string const &);
31         ///
32         InsetFloat(InsetFloat const &, bool same_id = false);
33         ///
34         ~InsetFloat();
35         ///
36         void write(Buffer const * buf, std::ostream & os) const;
37         ///
38         void read(Buffer const * buf, LyXLex & lex);
39         ///
40         void validate(LaTeXFeatures & features) const;
41         ///
42         Inset * clone(Buffer const &, bool same_id = false) const;
43         ///
44         Inset::Code lyxCode() const { return Inset::FLOAT_CODE; }
45         ///
46         int latex(Buffer const *, std::ostream &, bool fragile, bool fp) const;
47         ///
48         int docbook(Buffer const *, std::ostream &, bool mixcont) const;
49         ///
50         string const editMessage() const;
51         ///
52         bool insetAllowed(Inset::Code) const;
53         /** returns true if, when outputing LaTeX, font changes should
54             be closed before generating this inset. This is needed for
55             insets that may contain several paragraphs */
56         bool noFontChange() const { return true; }
57         ///
58         string const & type() const;
59         ///
60         void placement(string const & p);
61         ///
62         string const & placement() const;
63         ///
64         void wide(bool w, BufferParams const &);
65         ///
66         bool wide() const;
67         ///
68         void addToToc(toc::TocList &, Buffer const *) const;
69         ///
70         bool  showInsetDialog(BufferView *) const;
71         ///
72         boost::signal0<void> hideDialog;
73 private:
74         ///
75         string floatType_;
76         ///
77         string floatPlacement_;
78         ///
79         bool wide_;
80 };
81
82 #endif