2 * \file ControlMinipage.C
3 * Read the file COPYING
6 * \author Angus Leeming
8 * Full author contact details are available in file CREDITS
14 #pragma implementation
17 #include "ControlMinipage.h"
18 #include "BufferView.h"
21 ControlMinipage::ControlMinipage(LyXView & lv, Dialogs & d)
22 : ControlInset<InsetMinipage, MinipageParams>(lv, d)
26 void ControlMinipage::applyParamsToInset()
28 inset()->pageWidth(params().pageWidth);
29 inset()->pos(params().pos);
31 bufferview()->updateInset(inset(), true);
35 void ControlMinipage::applyParamsNoInset()
40 MinipageParams const ControlMinipage::getParams(InsetMinipage const & inset)
42 return MinipageParams(inset);
46 MinipageParams::MinipageParams()
47 : pos(InsetMinipage::top)
50 MinipageParams::MinipageParams(InsetMinipage const & inset)
51 : pageWidth(inset.pageWidth()), pos(inset.pos())
55 bool operator==(MinipageParams const & p1, MinipageParams const & p2)
57 return (p1.pageWidth == p2.pageWidth && p1.pos == p2.pos);
61 bool operator!=(MinipageParams const & p1, MinipageParams const & p2)