summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_table.eo
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/evas/canvas/evas_table.eo')
-rw-r--r--src/lib/evas/canvas/evas_table.eo211
1 files changed, 0 insertions, 211 deletions
diff --git a/src/lib/evas/canvas/evas_table.eo b/src/lib/evas/canvas/evas_table.eo
deleted file mode 100644
index fe33a00..0000000
--- a/src/lib/evas/canvas/evas_table.eo
+++ /dev/null
@@ -1,211 +0,0 @@
1/* XXX: Remove the Object_ part once the relevant Eolian bugs are fixed. */
2enum Evas.Object_Table.Homogeneous_Mode {
3 [[How to pack items into cells in a table.
4
5 See @Evas.Table.homogeneous for an explanation of the function of each one.]]
6 legacy: Evas_Object_Table_Homogeneous;
7 none = 0, [[No mode specified]]
8 table = 1, [[Table mode]]
9 item = 2 [[Item mode]]
10}
11
12class Evas.Table extends Efl.Canvas.Group
13{
14 [[Evas table class]]
15 legacy_prefix: evas_object_table;
16 eo_prefix: evas_obj_table;
17 methods {
18 @property homogeneous {
19 [[Set how this table should layout children.
20
21 Todo: consider aspect hint and respect it.
22
23 @Evas.Object_Table.Homogeneous_Mode.none
24 If table does not use homogeneous mode then columns and rows will
25 be calculated based on hints of individual cells. This operation
26 mode is more flexible, but more complex and heavy to calculate as
27 well. Weight properties are handled as a boolean expand. Negative
28 alignment will be considered as 0.5. This is the default.
29
30 Todo: @Evas.Object_Table.Homogeneous_Mode.none should balance weight.
31
32 @Evas.Object_Table.Homogeneous_Mode.table
33 When homogeneous is relative to table the own table size is divided
34 equally among children, filling the whole table area. That is, if
35 table has $WIDTH and $COLUMNS, each cell will get _WIDTH /
36 COLUMNS_ pixels. If children have minimum size that is larger
37 than this amount (including padding), then it will overflow and be
38 aligned respecting the alignment hint, possible overlapping sibling
39 cells. Weight hint is used as a boolean, if greater than zero it
40 will make the child expand in that axis, taking as much space as
41 possible (bounded to maximum size hint). Negative alignment will be
42 considered as 0.5.
43
44 @Evas.Object_Table.Homogeneous_Mode.item
45 When homogeneous is relative to item it means the greatest minimum
46 cell size will be used. That is, if no element is set to expand,
47 the table will have its contents to a minimum size, the bounding
48 box of all these children will be aligned relatively to the table
49 object using evas_object_table_align_get(). If the table area is
50 too small to hold this minimum bounding box, then the objects will
51 keep their size and the bounding box will overflow the box area,
52 still respecting the alignment. Weight hint is used as a
53 boolean, if greater than zero it will make that cell expand in that
54 axis, toggling the *expand mode*, which makes the table behave
55 much like @Evas.Object_Table.Homogeneous_Mode.table, except that the
56 bounding box will overflow and items will not overlap siblings. If
57 no minimum size is provided at all then the table will fallback to
58 expand mode as well.]]
59 set {
60 }
61 get {
62 }
63 values {
64 homogeneous: Evas.Object_Table.Homogeneous_Mode; [[Table homogeneous mode]]
65 }
66 }
67 @property align {
68 [[Control the alignment of the whole bounding box of contents.]]
69 set {
70 }
71 get {
72 }
73 values {
74 horizontal: double; [[Horizontal alignment]]
75 vertical: double; [[Vertical alignment]]
76 }
77 }
78 @property padding {
79 [[Control the padding between cells.]]
80 set {
81 }
82 get {
83 }
84 values {
85 horizontal: int; [[Horizontal padding]]
86 vertical: int; [[Vertical padding]]
87 }
88 }
89 @property col_row_size {
90 get {
91 [[Get the number of columns and rows this table takes.
92
93 Note: columns and rows are virtual entities, one can specify a table
94 with a single object that takes 4 columns and 5 rows. The only
95 difference for a single cell table is that paddings will be
96 accounted proportionally.]]
97 }
98 values {
99 cols: int; [[Columns in table]]
100 rows: int; [[Rows in table]]
101 }
102 }
103 @property children {
104 get {
105 [[Get the list of children for the table.
106
107 Note: This is a duplicate of the list kept by the table internally.
108 It's up to the user to destroy it when it no longer needs it.
109 It's possible to remove objects from the table when walking this
110 list, but these removals won't be reflected on it.]]
111 return: list<Efl.Canvas.Object> @owned @warn_unused; [[Children list]]
112 }
113 }
114 @property child {
115 get {
116 [[Get the child of the table at the given coordinates
117
118 Note: This does not take into account col/row spanning]]
119 }
120 keys {
121 col: ushort; [[Child column]]
122 row: ushort; [[Child row]]
123 }
124 values {
125 child: Efl.Canvas.Object; [[Child object]]
126 }
127 }
128 clear {
129 [[Faster way to remove all child objects from a table object.]]
130
131 params {
132 @in clear: bool; [[If $true, it will delete just removed children.]]
133 }
134 }
135 accessor_new @const {
136 [[Get an accessor to get random access to the list of children for the table.
137
138 Note: Do not remove or delete objects while walking the list.]]
139 return: accessor<Efl.Canvas.Object> @owned
140 @warn_unused; [[Accessor to children list]]
141 }
142 iterator_new @const {
143 [[Get an iterator to walk the list of children for the table.
144
145 Note: Do not remove or delete objects while walking the list.]]
146 return: iterator<Efl.Canvas.Object> @owned
147 @warn_unused; [[Iterator to children]]
148 }
149 add_to {
150 [[Create a table that is child of a given element $parent.]]
151
152 return: Efl.Canvas.Object @warn_unused; [[Children table]]
153 }
154 pack_get @const {
155 [[Get packing location of a child of table
156
157 @since 1.1]]
158 return: bool; [[$true on success, $false on failure.]]
159 params {
160 @in child: Efl.Canvas.Object; [[The child object to add.]]
161 @out col: ushort; [[Pointer to store relative-horizontal position to place child.]]
162 @out row: ushort; [[Pointer to store relative-vertical position to place child.]]
163 @out colspan: ushort; [[Pointer to store how many relative-horizontal positions to use for this child.]]
164 @out rowspan: ushort; [[Pointer to store how many relative-vertical positions to use for this child.]]
165 }
166 }
167 pack {
168 [[Add a new child to a table object or set its current packing.
169
170 Note that columns and rows only guarantee 16bit unsigned values at best.
171 That means that col + colspan AND row + rowspan must fit inside 16bit
172 unsigned values cleanly. You will be warned once values exceed 15bit
173 storage, and attempting to use values not able to fit in 16bits will
174 result in failure.]]
175
176 return: bool; [[$true on success, $false on failure.]]
177 params {
178 @in child: Efl.Canvas.Object @nonull; [[The child object to add.]]
179 @in col: ushort; [[Relative-horizontal position to place child.]]
180 @in row: ushort; [[Relative-vertical position to place child.]]
181 @in colspan: ushort; [[How many relative-horizontal positions to use for this child.]]
182 @in rowspan: ushort; [[How many relative-vertical positions to use for this child.]]
183 }
184 }
185 unpack {
186 [[Remove child from table.
187
188 Note: removing a child will immediately call a walk over children in order
189 to recalculate numbers of columns and rows. If you plan to remove
190 all children, use @Evas.Table.clear instead.]]
191
192 return: bool; [[$true on success, $false on failure.]]
193 params {
194 @in child: Efl.Canvas.Object @nonull; [[Child to be removed]]
195 }
196 }
197 count {
198 [[Returns the number of items in the table]]
199 legacy: null;
200 return: int; [[Number of items in table]]
201 }
202 }
203 implements {
204 class.constructor;
205 Efl.Object.constructor;
206 Efl.Gfx.Entity.size { set; }
207 Efl.Gfx.Entity.position { set; }
208 Efl.Canvas.Group.group_calculate;
209 Efl.Ui.I18n.mirrored { get; set; }
210 }
211}