]> git.tdb.fi Git - libs/gltk.git/blobdiff - source/column.h
Support specifying layouts in datafiles
[libs/gltk.git] / source / column.h
index 0e5f0040364d5c52055e1e44112670e84acb824a..b6092bb5dded802e92fb579ad8569218dd00399e 100644 (file)
@@ -1,24 +1,38 @@
 #ifndef MSP_GLTK_COLUMN_H_
 #define MSP_GLTK_COLUMN_H_
 
-#include "layout.h"
+#include <msp/datafile/objectloader.h>
+#include "arrangement.h"
 
 namespace Msp {
 namespace GLtk {
 
-/**
-Arranges widgets in a single column.
-*/
-class Column: public Layout
+class Column: public Arrangement
 {
+public:
+       class Loader: public DataFile::ObjectLoader<Column>
+       {
+       public:
+               Loader(Column &);
+       private:
+               void split();
+       };
+
 private:
-       bool uniform;
+       Edge next_bottom;
+       bool first;
+       bool split_here;
+       int gravity;
 
 public:
-       Column(bool = false);
+       Column(Layout &);
+
+       void split();
 
 private:
-       virtual Slot *create_slot(Widget &);
+       virtual void process_widget(Widget &, Side, bool);
+       virtual void finish_widget(Widget &);
+       virtual void finish_slot();
 };
 
 } // namespace GLtk