]> git.lyx.org Git - lyx.git/blob - src/insets/insetminipage.h
updates to minipage inset
[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
22 /** The minipage inset
23   
24 */
25 class InsetMinipage : public InsetCollapsable {
26 public:
27         ///
28         enum Position {
29                 center,
30                 top,
31                 bottom
32         };
33         ///
34         enum InnerPosition {
35                 inner_center,
36                 inner_top,
37                 inner_bottom,
38                 inner_stretch
39         };
40         ///
41         InsetMinipage();
42         ///
43         void Write(Buffer const * buf, std::ostream & os) const;
44         ///
45         Inset * Clone(Buffer const &) const;
46         ///
47         Inset::Code LyxCode() const { return Inset::MINIPAGE_CODE; }
48         ///
49         int Latex(Buffer const *, std::ostream &, bool fragile, bool fp) const;
50         ///
51         string const EditMessage() const;
52         ///
53         bool InsertInsetAllowed(Inset * inset) const;
54         ///
55         Position pos() const;
56         ///
57         void pos(Position);
58         ///
59         InnerPosition innerPos() const;
60         ///
61         void innerPos(InnerPosition);
62         ///
63         LyXLength const & height() const;
64         ///
65         void height(LyXLength const &);
66         ///
67         LyXLength const & width() const;
68         ///
69         void width(LyXLength const &);
70 private:
71         ///
72         Position pos_;
73         ///
74         InnerPosition inner_pos_;
75         ///
76         LyXLength height_;
77         ///
78         LyXLength width_;
79 };
80
81 #endif