summaryrefslogtreecommitdiff
path: root/src/lib/elm_box_eo.h
blob: 5111b296ef574978c242e9b6f8989eb5af313092 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
#define ELM_OBJ_BOX_CLASS elm_obj_box_class_get()

const Eo_Class *elm_obj_box_class_get(void) EINA_CONST;

extern EAPI Eo_Op ELM_OBJ_BOX_BASE_ID;

enum
{
   ELM_OBJ_BOX_SUB_ID_HORIZONTAL_SET,
   ELM_OBJ_BOX_SUB_ID_HORIZONTAL_GET,
   ELM_OBJ_BOX_SUB_ID_HOMOGENEOUS_SET,
   ELM_OBJ_BOX_SUB_ID_HOMOGENEOUS_GET,
   ELM_OBJ_BOX_SUB_ID_PACK_START,
   ELM_OBJ_BOX_SUB_ID_PACK_END,
   ELM_OBJ_BOX_SUB_ID_PACK_BEFORE,
   ELM_OBJ_BOX_SUB_ID_PACK_AFTER,
   ELM_OBJ_BOX_SUB_ID_CLEAR,
   ELM_OBJ_BOX_SUB_ID_UNPACK,
   ELM_OBJ_BOX_SUB_ID_UNPACK_ALL,
   ELM_OBJ_BOX_SUB_ID_LAYOUT_SET,
   ELM_OBJ_BOX_SUB_ID_CHILDREN_GET,
   ELM_OBJ_BOX_SUB_ID_PADDING_SET,
   ELM_OBJ_BOX_SUB_ID_PADDING_GET,
   ELM_OBJ_BOX_SUB_ID_ALIGN_SET,
   ELM_OBJ_BOX_SUB_ID_ALIGN_GET,
   ELM_OBJ_BOX_SUB_ID_RECALCULATE,
   ELM_OBJ_BOX_SUB_ID_LAST
};

#define ELM_OBJ_BOX_ID(sub_id) (ELM_OBJ_BOX_BASE_ID + sub_id)


/**
 * @def elm_obj_box_horizontal_set
 * @since 1.8
 *
 * Set the horizontal orientation
 *
 * @param[in] horizontal
 *
 * @see elm_box_horizontal_set
 *
 * @ingroup Box
 */
#define elm_obj_box_horizontal_set(horizontal) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_HORIZONTAL_SET), EO_TYPECHECK(Eina_Bool, horizontal)

/**
 * @def elm_obj_box_horizontal_get
 * @since 1.8
 *
 * Get the horizontal orientation
 *
 * @param[out] ret
 *
 * @see elm_box_horizontal_get
 *
 * @ingroup Box
 */
#define elm_obj_box_horizontal_get(ret) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_HORIZONTAL_GET), EO_TYPECHECK(Eina_Bool *, ret)

/**
 * @def elm_obj_box_homogeneous_set
 * @since 1.8
 *
 * Set the box to arrange its children homogeneously
 *
 * @param[in] homogeneous
 *
 * @see elm_box_homogeneous_set
 *
 * @ingroup Box
 */
#define elm_obj_box_homogeneous_set(homogeneous) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_HOMOGENEOUS_SET), EO_TYPECHECK(Eina_Bool, homogeneous)

/**
 * @def elm_obj_box_homogeneous_get
 * @since 1.8
 *
 * Get whether the box is using homogeneous mode or not
 *
 * @param[out] ret
 *
 * @see elm_box_homogeneous_get
 *
 * @ingroup Box
 */
#define elm_obj_box_homogeneous_get(ret) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_HOMOGENEOUS_GET), EO_TYPECHECK(Eina_Bool *, ret)

/**
 * @def elm_obj_box_pack_start
 * @since 1.8
 *
 * Add an object to the beginning of the pack list
 *
 * @param[in] subobj
 *
 * @see elm_box_pack_start
 *
 * @ingroup Box
 */
#define elm_obj_box_pack_start(subobj) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_PACK_START), EO_TYPECHECK(Evas_Object *, subobj)

/**
 * @def elm_obj_box_pack_end
 * @since 1.8
 *
 * Add an object at the end of the pack list
 *
 * @param[in] subobj
 *
 * @see elm_box_pack_end
 *
 * @ingroup Box
 */
#define elm_obj_box_pack_end(subobj) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_PACK_END), EO_TYPECHECK(Evas_Object *, subobj)

/**
 * @def elm_obj_box_pack_before
 * @since 1.8
 *
 * Adds an object to the box before the indicated object
 *
 * @param[in] subobj
 * @param[in] before
 *
 * @see elm_box_pack_before
 *
 * @ingroup Box
 */
#define elm_obj_box_pack_before(subobj, before) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_PACK_BEFORE), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(Evas_Object *, before)

/**
 * @def elm_obj_box_pack_after
 * @since 1.8
 *
 * Adds an object to the box after the indicated object
 *
 * @param[in] subobj
 * @param[in] after
 *
 * @see elm_box_pack_after
 *
 * @ingroup Box
 */
#define elm_obj_box_pack_after(subobj, after) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_PACK_AFTER), EO_TYPECHECK(Evas_Object *, subobj), EO_TYPECHECK(Evas_Object *, after)

/**
 * @def elm_obj_box_clear
 * @since 1.8
 *
 * Clear the box of all children
 *
 *
 * @see elm_box_clear
 *
 * @ingroup Box
 */
#define elm_obj_box_clear() ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_CLEAR)

/**
 * @def elm_obj_box_unpack
 * @since 1.8
 *
 * Unpack a box item
 *
 * @param[in] subobj
 *
 * @see elm_box_unpack
 *
 * @ingroup Box
 */
#define elm_obj_box_unpack(subobj) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_UNPACK), EO_TYPECHECK(Evas_Object *, subobj)

/**
 * @def elm_obj_box_unpack_all
 * @since 1.8
 *
 * Remove all items from the box, without deleting them
 *
 *
 * @see elm_box_unpack_all
 *
 * @ingroup Box
 */
#define elm_obj_box_unpack_all() ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_UNPACK_ALL)

/**
 * @def elm_obj_box_layout_set
 * @since 1.8
 *
 * Set the layout defining function to be used by the box
 *
 * @param[in] cb
 * @param[in] data
 * @param[in] free_data
 *
 * @see elm_box_layout_set
 *
 * @ingroup Box
 */
#define elm_obj_box_layout_set(cb, data, free_data) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_LAYOUT_SET), EO_TYPECHECK(Evas_Object_Box_Layout, cb), EO_TYPECHECK(const void *, data), EO_TYPECHECK(Ecore_Cb, free_data)

/**
 * @def elm_obj_box_children_get
 * @since 1.8
 *
 * Retrieve a list of the objects packed into the box
 *
 * @param[out] ret
 *
 * @see elm_box_children_get
 *
 * @ingroup Box
 */
#define elm_obj_box_children_get(ret) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_CHILDREN_GET), EO_TYPECHECK(Eina_List **, ret)

/**
 * @def elm_obj_box_padding_set
 * @since 1.8
 *
 * Set the space (padding) between the box's elements.
 *
 * @param[in] horizontal
 * @param[in] vertical
 *
 * @see elm_box_padding_set
 *
 * @ingroup Box
 */
#define elm_obj_box_padding_set(horizontal, vertical) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_PADDING_SET), EO_TYPECHECK(Evas_Coord, horizontal), EO_TYPECHECK(Evas_Coord, vertical)

/**
 * @def elm_obj_box_padding_get
 * @since 1.8
 *
 * Get the space (padding) between the box's elements.
 *
 * @param[out] horizontal
 * @param[out] vertical
 *
 * @see elm_box_padding_get
 *
 * @ingroup Box
 */
#define elm_obj_box_padding_get(horizontal, vertical) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_PADDING_GET), EO_TYPECHECK(Evas_Coord *, horizontal), EO_TYPECHECK(Evas_Coord *, vertical)

/**
 * @def elm_obj_box_align_set
 * @since 1.8
 *
 * Set the alignment of the whole bounding box of contents.
 *
 * @param[in] horizontal
 * @param[in] vertical
 *
 * @see elm_box_align_set
 *
 * @ingroup Box
 */
#define elm_obj_box_align_set(horizontal, vertical) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_ALIGN_SET), EO_TYPECHECK(double, horizontal), EO_TYPECHECK(double, vertical)

/**
 * @def elm_obj_box_align_get
 * @since 1.8
 *
 * Get the alignment of the whole bounding box of contents.
 *
 * @param[out] horizontal
 * @param[out] vertical
 *
 * @see elm_box_align_get
 *
 * @ingroup Box
 */
#define elm_obj_box_align_get(horizontal, vertical) ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_ALIGN_GET), EO_TYPECHECK(double *, horizontal), EO_TYPECHECK(double *, vertical)

/**
 * @def elm_obj_box_recalculate
 * @since 1.8
 *
 * Force the box to recalculate its children packing.
 *
 *
 * @see elm_box_recalculate
 *
 * @ingroup Box
 */
#define elm_obj_box_recalculate() ELM_OBJ_BOX_ID(ELM_OBJ_BOX_SUB_ID_RECALCULATE)