]> git.lyx.org Git - lyx.git/blob - src/insets/insetminipage.h
Added Minipage-Dialog, small fix in LyXTabular::l_getline (removing \r).
[lyx.git] / src / insets / insetminipage.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
12 #ifndef InsetMinipage_H
13 #define InsetMinipage_H
14
15 #ifdef __GNUG__
16 #pragma interface
17 #endif
18
19 #include "insetcollapsable.h"
20 #include "vspace.h"
21 #include <sigc++/signal_system.h>
22
23 /** The minipage inset
24   
25 */
26 class InsetMinipage : public InsetCollapsable {
27 public:
28         ///
29         enum Position {
30                 top,
31                 center,
32                 bottom
33         };
34         ///
35         enum InnerPosition {
36                 inner_center,
37                 inner_top,
38                 inner_bottom,
39                 inner_stretch
40         };
41         ///
42         InsetMinipage();
43         ///
44         ~InsetMinipage();
45         ///
46         void Write(Buffer const * buf, std::ostream & os) const;
47         ///
48         Inset * Clone(Buffer const &) const;
49         ///
50         Inset::Code LyxCode() const { return Inset::MINIPAGE_CODE; }
51         ///
52         int Latex(Buffer const *, std::ostream &, bool fragile, bool fp) const;
53         ///
54         string const EditMessage() const;
55         ///
56         bool InsertInsetAllowed(Inset * inset) const;
57         ///
58         Position pos() const;
59         ///
60         void pos(Position);
61         ///
62         InnerPosition innerPos() const;
63         ///
64         void innerPos(InnerPosition);
65         ///
66         LyXLength const & height() const;
67         ///
68         void height(LyXLength const &);
69         ///
70         string const & width() const;
71         ///
72         void width(string const &);
73         ///
74         int widthp() const;
75         ///
76         void widthp(int);
77         ///
78         void widthp(string const &);
79         ///
80         SigC::Signal0<void> hideDialog;
81         ///
82         void InsetButtonRelease(BufferView * bv, int x, int y, int button);
83
84 private:
85         ///
86         Position pos_;
87         ///
88         InnerPosition inner_pos_;
89         ///
90         LyXLength height_;
91         ///
92         string width_;
93         ///
94         int widthp_;
95 };
96
97 #endif