gravity = primary;
}
+void LinearArrangement::expand()
+{
+ if(gravity==primary)
+ throw arrangement_error("already split");
+ if(edges[primary].empty())
+ throw arrangement_error("no widgets");
+
+ add_constraint(*edges[primary].widgets.front(), get_align_constraint(primary), primary);
+ layout.set_expand(*edges[primary].widgets.front(), false, true);
+ edges[primary].align();
+ gravity = primary;
+}
+
void LinearArrangement::process_widget(Widget &wdg, Side side, bool aligned)
{
if(side==opposite)
LinearArrangement::Loader::Loader(LinearArrangement &c):
DataFile::ObjectLoader<LinearArrangement>(c)
{
+ add("expand", &Loader::expand);
add("split", &Loader::split);
}
+void LinearArrangement::Loader::expand()
+{
+ obj.expand();
+}
+
void LinearArrangement::Loader::split()
{
obj.split();