summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_box_eo.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/evas/canvas/evas_box_eo.h')
-rw-r--r--src/lib/evas/canvas/evas_box_eo.h818
1 files changed, 818 insertions, 0 deletions
diff --git a/src/lib/evas/canvas/evas_box_eo.h b/src/lib/evas/canvas/evas_box_eo.h
new file mode 100644
index 0000000..2f36d7c
--- /dev/null
+++ b/src/lib/evas/canvas/evas_box_eo.h
@@ -0,0 +1,818 @@
1#ifndef _EVAS_BOX_EO_H_
2#define _EVAS_BOX_EO_H_
3
4#ifndef _EVAS_BOX_EO_CLASS_TYPE
5#define _EVAS_BOX_EO_CLASS_TYPE
6
7typedef Eo Evas_Box;
8
9#endif
10
11#ifndef _EVAS_BOX_EO_TYPES
12#define _EVAS_BOX_EO_TYPES
13
14
15#endif
16/** Evas box class
17 *
18 * @ingroup Evas_Box
19 */
20#define EVAS_BOX_CLASS evas_box_class_get()
21
22EWAPI const Efl_Class *evas_box_class_get(void);
23
24/**
25 * @brief Set the alignment of the whole bounding box of contents, for a given
26 * box object.
27 *
28 * This will influence how a box object is to align its bounding box of
29 * contents within its own area. The values must be in the range $0.0 - $1.0,
30 * or undefined behavior is expected. For horizontal alignment, $0.0 means to
31 * the left, with $1.0 meaning to the right. For vertical alignment, $0.0 means
32 * to the top, with $1.0 meaning to the bottom.
33 *
34 * @note The default values for both alignments is $0.5.
35 *
36 * See also @ref evas_obj_box_align_get.
37 *
38 * @param[in] obj The object.
39 * @param[in] horizontal The horizontal alignment, in pixels.
40 * @param[in] vertical The vertical alignment, in pixels.
41 *
42 * @ingroup Evas_Box
43 */
44EOAPI void evas_obj_box_align_set(Eo *obj, double horizontal, double vertical);
45
46/**
47 * @brief Get the alignment of the whole bounding box of contents, for a given
48 * box object.
49 *
50 * See also @ref evas_obj_box_align_set for more information.
51 *
52 * @param[in] obj The object.
53 * @param[out] horizontal The horizontal alignment, in pixels.
54 * @param[out] vertical The vertical alignment, in pixels.
55 *
56 * @ingroup Evas_Box
57 */
58EOAPI void evas_obj_box_align_get(const Eo *obj, double *horizontal, double *vertical);
59
60/**
61 * @brief Set the (space) padding between cells set for a given box object.
62 *
63 * @note The default values for both padding components is $0.
64 *
65 * See also @ref evas_obj_box_padding_get.
66 *
67 * @param[in] obj The object.
68 * @param[in] horizontal The horizontal padding, in pixels.
69 * @param[in] vertical The vertical padding, in pixels.
70 *
71 * @ingroup Evas_Box
72 */
73EOAPI void evas_obj_box_padding_set(Eo *obj, int horizontal, int vertical);
74
75/**
76 * @brief Get the (space) padding between cells set for a given box object.
77 *
78 * See also @ref evas_obj_box_padding_set.
79 *
80 * @param[in] obj The object.
81 * @param[out] horizontal The horizontal padding, in pixels.
82 * @param[out] vertical The vertical padding, in pixels.
83 *
84 * @ingroup Evas_Box
85 */
86EOAPI void evas_obj_box_padding_get(const Eo *obj, int *horizontal, int *vertical);
87
88/**
89 * @brief Set a new layouting function to a given box object
90 *
91 * A box layout function affects how a box object displays child elements
92 * within its area. The list of pre-defined box layouts available in Evas are
93 * @ref evas_obj_box_layout_horizontal, @ref evas_obj_box_layout_vertical,
94 * @ref evas_obj_box_layout_homogeneous_horizontal,
95 * @ref evas_obj_box_layout_homogeneous_vertical,
96 * @ref evas_obj_box_layout_homogeneous_max_size_horizontal,
97 * @ref evas_obj_box_layout_homogeneous_max_size_vertical,
98 * @ref evas_obj_box_layout_flow_horizontal,
99 * @ref evas_obj_box_layout_flow_vertical and @ref evas_obj_box_layout_stack
100 *
101 * Refer to each of their documentation texts for details on them.
102 *
103 * @note A box layouting function will be triggered by the $'calculate' smart
104 * callback of the box's smart class.
105 *
106 * @param[in] obj The object.
107 * @param[in] cb The new layout function to set on @c o.
108 * @param[in] data Data pointer to be passed to @c cb.
109 * @param[in] free_data Function to free @c data, if need be.
110 *
111 * @ingroup Evas_Box
112 */
113EOAPI void evas_obj_box_layout_set(Eo *obj, Evas_Object_Box_Layout cb, const void *data, Eina_Free_Cb free_data) EINA_ARG_NONNULL(2);
114
115/**
116 * @brief Layout function which sets the box o to a (basic) horizontal box
117 *
118 * In this layout, the box object's overall behavior is controlled by its
119 * padding/alignment properties, which are set by the
120 * evas_object_box_{h,v}_{align,padding}_set family of functions. The size
121 * hints of the elements in the box -- set by the
122 * evas_object_size_hint_{align,padding,weight}_set functions -- also control
123 * the way this function works.
124 *
125 * Box's properties: @c align_h controls the horizontal alignment of the child
126 * objects relative to the containing box. When set to $0.0, children are
127 * aligned to the left. A value of $1.0 makes them aligned to the right border.
128 * Values in between align them proportionally. Note that if the size required
129 * by the children, which is given by their widths and the @c padding_h
130 * property of the box, is bigger than the their container's width, the
131 * children will be displayed out of the box's bounds. A negative value of
132 * @c align_h makes the box to justify its children. The padding between them,
133 * in this case, is corrected so that the leftmost one touches the left border
134 * and the rightmost one touches the right border (even if they must overlap).
135 * The @c align_v and @c padding_v properties of the box don't contribute to
136 * its behaviour when this layout is chosen.
137 *
138 * Child element's properties: @c align_x does not influence the box's
139 * behavior. @c padding_l and @c padding_r sum up to the container's horizontal
140 * padding between elements. The child's @c padding_t, @c padding_b and
141 * @c align_y properties apply for padding/alignment relative to the overall
142 * height of the box. Finally, there is the @c weight_x property, which, if set
143 * to a non-zero value, tells the container that the child width is not
144 * pre-defined. If the container can't accommodate all its children, it sets
145 * the widths of the ones with weights to sizes as small as they can all fit
146 * into it. If the size required by the children is less than the available,
147 * the box increases its childrens' (which have weights) widths as to fit the
148 * remaining space. The @c weight_x property, besides telling the element is
149 * resizable, gives a weight for the resizing process. The parent box will try
150 * to distribute (or take off) widths accordingly to the normalized list of
151 * weights: most weighted children remain/get larger in this process than the
152 * least ones. @c weight_y does not influence the layout.
153 *
154 * If one desires that, besides having weights, child elements must be resized
155 * bounded to a minimum or maximum size, those size hints must be set, by the
156 * evas_object_size_hint_{min,max}_set functions.
157 *
158 * @param[in] obj The object.
159 * @param[in] priv Private data pointer
160 * @param[in] data Data pointer
161 *
162 * @ingroup Evas_Box
163 */
164EOAPI void evas_obj_box_layout_horizontal(Eo *obj, Evas_Object_Box_Data *priv, void *data);
165
166/**
167 * @brief Layout function which sets the box o to a (basic) vertical box
168 *
169 * This function behaves analogously to evas_object_box_layout_horizontal. The
170 * description of its behaviour can be derived from that function's
171 * documentation.
172 *
173 * @param[in] obj The object.
174 * @param[in] priv Private data pointer
175 * @param[in] data Data pointer
176 *
177 * @ingroup Evas_Box
178 */
179EOAPI void evas_obj_box_layout_vertical(Eo *obj, Evas_Object_Box_Data *priv, void *data);
180
181/**
182 * @brief Layout function which sets the box o to a maximum size, homogeneous
183 * horizontal box
184 *
185 * In a maximum size, homogeneous horizontal box, besides having cells of equal
186 * size reserved for the child objects, this size will be defined by the size
187 * of the largest child in the box (in width). The box's overall behavior is
188 * controlled by its properties, which are set by the
189 * evas_object_box_{h,v}_{align,padding}_set family of functions. The size
190 * hints of the elements in the box -- set by the
191 * evas_object_size_hint_{align,padding,weight}_set functions -- also control
192 * the way this function works.
193 *
194 * Box's properties: @c padding_h tells the box to draw empty spaces of that
195 * size, in pixels, between the child objects' cells. @c align_h controls the
196 * horizontal alignment of the child objects, relative to the containing box.
197 * When set to $0.0, children are aligned to the left. A value of $1.0 lets
198 * them aligned to the right border. Values in between align them
199 * proportionally. A negative value of @c align_h makes the box to justify its
200 * children cells. The padding between them, in this case, is corrected so that
201 * the leftmost one touches the left border and the rightmost one touches the
202 * right border (even if they must overlap). The @c align_v and @c padding_v
203 * properties of the box don't contribute to its behaviour when this layout is
204 * chosen.
205 *
206 * Child element's properties: @c padding_l and @c padding_r sum up to the
207 * required width of the child element. The @c align_x property tells the
208 * relative position of this overall child width in its allocated cell ($0.0 to
209 * extreme left, $1.0 to extreme right). A value of $-1.0 to @c align_x makes
210 * the box try to resize this child element to the exact width of its cell
211 * (respecting the minimum and maximum size hints on the child's width and
212 * accounting for its horizontal padding hints). The child's @c padding_t,
213 * @c padding_b and @c align_y properties apply for padding/alignment relative
214 * to the overall height of the box. A value of $-1.0 to @c align_y makes the
215 * box try to resize this child element to the exact height of its parent
216 * (respecting the max hint on the child's height).
217 *
218 * @param[in] obj The object.
219 * @param[in] priv Private data pointer
220 * @param[in] data Data pointer
221 *
222 * @ingroup Evas_Box
223 */
224EOAPI void evas_obj_box_layout_homogeneous_max_size_horizontal(Eo *obj, Evas_Object_Box_Data *priv, void *data);
225
226/**
227 * @brief No description supplied by the EAPI.
228 *
229 * @param[in] obj The object.
230 * @param[in] child Child object to be removed
231 *
232 * @return New object with child removed
233 *
234 * @ingroup Evas_Box
235 */
236EOAPI Efl_Canvas_Object *evas_obj_box_internal_remove(Eo *obj, Efl_Canvas_Object *child);
237
238/**
239 * @brief Layout function which sets the box o to a flow vertical box.
240 *
241 * This function behaves analogously to evas_object_box_layout_flow_horizontal.
242 * The description of its behaviour can be derived from that function's
243 * documentation.
244 *
245 * @param[in] obj The object.
246 * @param[in] priv Private data pointer
247 * @param[in] data Data pointer
248 *
249 * @ingroup Evas_Box
250 */
251EOAPI void evas_obj_box_layout_flow_vertical(Eo *obj, Evas_Object_Box_Data *priv, void *data);
252
253/**
254 * @brief No description supplied by the EAPI.
255 *
256 * @param[in] obj The object.
257 * @param[in] opt Box option to be freed
258 *
259 * @ingroup Evas_Box
260 */
261EOAPI void evas_obj_box_internal_option_free(Eo *obj, Evas_Object_Box_Option *opt);
262
263/**
264 * @brief Insert a new child object after another existing one, in a given box
265 * object o.
266 *
267 * On success, the $"child,added" smart event will take place.
268 *
269 * @note This function will fail if @c reference is not a member of @c o.
270 *
271 * @note The actual placing of the item relative to @c o's area will depend on
272 * the layout set to it.
273 *
274 * @note This call will trigger the box's _Evas_Object_Box_Api.insert_after
275 * smart function.
276 *
277 * @param[in] obj The object.
278 * @param[in] child A child Evas object to be made a member of @c o.
279 * @param[in] reference The child object to place this new one after.
280 *
281 * @return A box option bound to the recently added box item or @c null, on
282 * errors
283 *
284 * @ingroup Evas_Box
285 */
286EOAPI Evas_Object_Box_Option *evas_obj_box_insert_after(Eo *obj, Efl_Canvas_Object *child, const Efl_Canvas_Object *reference) EINA_ARG_NONNULL(2, 3);
287
288/**
289 * @brief Remove all child objects from a box object, unparenting them again.
290 *
291 * This has the same effect of calling evas_object_box_remove on each of @c o's
292 * child objects, in sequence. If, and only if, all those calls succeed, so
293 * does this one.
294 *
295 * @param[in] obj The object.
296 * @param[in] clear If @c true, it will delete just removed children.
297 *
298 * @return @c true on success, @c false otherwise.
299 *
300 * @ingroup Evas_Box
301 */
302EOAPI Eina_Bool evas_obj_box_remove_all(Eo *obj, Eina_Bool clear);
303
304/**
305 * @brief Get an iterator to walk the list of children of a given box object.
306 *
307 * @note Do not remove or delete objects while walking the list.
308 *
309 * @param[in] obj The object.
310 *
311 * @return An iterator on @c o's child objects, on success, or @c null, on
312 * errors.
313 *
314 * @ingroup Evas_Box
315 */
316EOAPI Eina_Iterator *evas_obj_box_iterator_new(const Eo *obj) EINA_WARN_UNUSED_RESULT;
317
318/**
319 * @brief Add a new box as a child of a given smart object.
320 *
321 * This is a helper function that has the same effect of putting a new box
322 * object into @c parent by use of evas_object_smart_member_add.
323 *
324 * @param[in] obj The object.
325 *
326 * @return @c null on error, a pointer to a new box object on success.
327 *
328 * @ingroup Evas_Box
329 */
330EOAPI Efl_Canvas_Object *evas_obj_box_add_to(Eo *obj) EINA_WARN_UNUSED_RESULT;
331
332/**
333 * @brief Append a new child object to the given box object o.
334 *
335 * On success, the $"child,added" smart event will take place.
336 *
337 * @note The actual placing of the item relative to @c o's area will depend on
338 * the layout set to it. For example, on horizontal layouts an item in the end
339 * of the box's list of children will appear on its right.
340 *
341 * @note This call will trigger the box's _Evas_Object_Box_Api.append smart
342 * function.
343 *
344 * @param[in] obj The object.
345 * @param[in] child A child Evas object to be made a member of @c o.
346 *
347 * @return A box option bound to the recently added box item or @c null, on
348 * errors.
349 *
350 * @ingroup Evas_Box
351 */
352EOAPI Evas_Object_Box_Option *evas_obj_box_append(Eo *obj, Efl_Canvas_Object *child) EINA_ARG_NONNULL(2);
353
354/**
355 * @brief Get the numerical identifier of the property of the child elements of
356 * the box o which have name as name string
357 *
358 * @note This call won't do anything for a canonical Evas box. Only users which
359 * have subclassed it, setting custom box items options (see
360 * #Evas_Object_Box_Option) on it, would benefit from this function. They'd
361 * have to implement it and set it to be the
362 * _Evas_Object_Box_Api.property_id_get smart class function of the box, which
363 * is originally set to @c null.
364 *
365 * @param[in] obj The object.
366 * @param[in] name The name string of the option being searched, for its ID.
367 *
368 * @return The numerical ID of the given property or $-1, on errors.
369 *
370 * @ingroup Evas_Box
371 */
372EOAPI int evas_obj_box_option_property_id_get(const Eo *obj, const char *name) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(2);
373
374/**
375 * @brief Prepend a new child object to the given box object o.
376 *
377 * On success, the $"child,added" smart event will take place.
378 *
379 * @note The actual placing of the item relative to @c o's area will depend on
380 * the layout set to it. For example, on horizontal layouts an item in the
381 * beginning of the box's list of children will appear on its left.
382 *
383 * @note This call will trigger the box's _Evas_Object_Box_Api.prepend smart
384 * function.
385 *
386 * @param[in] obj The object.
387 * @param[in] child A child Evas object to be made a member of @c o.
388 *
389 * @return A box option bound to the recently added box item or @c null, on
390 * errors.
391 *
392 * @ingroup Evas_Box
393 */
394EOAPI Evas_Object_Box_Option *evas_obj_box_prepend(Eo *obj, Efl_Canvas_Object *child) EINA_ARG_NONNULL(2);
395
396/**
397 * @brief Get an accessor (a structure providing random items access) to the
398 * list of children of a given box object.
399 *
400 * @note Do not remove or delete objects while walking the list.
401 *
402 * @param[in] obj The object.
403 *
404 * @return An accessor on @c o's child objects, on success, or @c null, on
405 * errors.
406 *
407 * @ingroup Evas_Box
408 */
409EOAPI Eina_Accessor *evas_obj_box_accessor_new(const Eo *obj) EINA_WARN_UNUSED_RESULT;
410
411/**
412 * @brief No description supplied by the EAPI.
413 *
414 * @param[in] obj The object.
415 * @param[in] child Child object to be appended
416 *
417 * @return Box option
418 *
419 * @ingroup Evas_Box
420 */
421EOAPI Evas_Object_Box_Option *evas_obj_box_internal_append(Eo *obj, Efl_Canvas_Object *child);
422
423/**
424 * @brief Set a property value (by its given numerical identifier), on a given
425 * box child element -- by a variable argument list
426 *
427 * This is a variable argument list variant of the
428 * evas_object_box_option_property_set. See its documentation for more details.
429 *
430 * @param[in] obj The object.
431 * @param[in] opt The box option structure bound to the child box element to
432 * set a property on.
433 * @param[in] property The numerical ID of the given property.
434 * @param[in] args The variable argument list implementing the value to be set
435 * for this property. It must be of the same type the user has defined for it.
436 *
437 * @return @c true on success, @c false on failure.
438 *
439 * @ingroup Evas_Box
440 */
441EOAPI Eina_Bool evas_obj_box_option_property_vset(Eo *obj, Evas_Object_Box_Option *opt, int property, va_list *args) EINA_ARG_NONNULL(2);
442
443/**
444 * @brief No description supplied by the EAPI.
445 *
446 * @param[in] obj The object.
447 * @param[in] pos Position of object to be removed
448 *
449 * @return Canvas object
450 *
451 * @ingroup Evas_Box
452 */
453EOAPI Efl_Canvas_Object *evas_obj_box_internal_remove_at(Eo *obj, unsigned int pos);
454
455/**
456 * @brief Remove an object, bound to a given position in a box object,
457 * unparenting it again.
458 *
459 * On removal, you'll get an unparented object again, just as it was before you
460 * inserted it in the box. The @c option_free box smart callback will be called
461 * automatically for you and, also, the $"child,removed" smart event will take
462 * place.
463 *
464 * @note This function will fail if the given position is invalid, given @c o's
465 * internal list of elements.
466 *
467 * @note This call will trigger the box's _Evas_Object_Box_Api.remove_at smart
468 * function.
469 *
470 * @param[in] obj The object.
471 * @param[in] pos The numeric position (starting from $0) of the child object
472 * to be removed.
473 *
474 * @return @c true on success, @c false on failure.
475 *
476 * @ingroup Evas_Box
477 */
478EOAPI Eina_Bool evas_obj_box_remove_at(Eo *obj, unsigned int pos);
479
480/**
481 * @brief Get a property's value (by its given numerical identifier), on a
482 * given box child element -- by a variable argument list
483 *
484 * This is a variable argument list variant of the
485 * evas_object_box_option_property_get. See its documentation for more details.
486 *
487 * @param[in] obj The object.
488 * @param[in] opt The box option structure bound to the child box element to
489 * get a property from.
490 * @param[in] property The numerical ID of the given property.
491 * @param[in] args The variable argument list with pointers to where to store
492 * the values of this property. They must point to variables of the same type
493 * the user has defined for them.
494 *
495 * @return @c true on success, @c false on failure.
496 *
497 * @ingroup Evas_Box
498 */
499EOAPI Eina_Bool evas_obj_box_option_property_vget(const Eo *obj, Evas_Object_Box_Option *opt, int property, va_list *args) EINA_ARG_NONNULL(2);
500
501/**
502 * @brief No description supplied by the EAPI.
503 *
504 * @param[in] obj The object.
505 * @param[in] child Child object to be inserted
506 * @param[in] pos Position where the object will be inserted
507 *
508 * @return Box option
509 *
510 * @ingroup Evas_Box
511 */
512EOAPI Evas_Object_Box_Option *evas_obj_box_internal_insert_at(Eo *obj, Efl_Canvas_Object *child, unsigned int pos);
513
514/**
515 * @brief Insert a new child object before another existing one, in a given box
516 * object o.
517 *
518 * On success, the $"child,added" smart event will take place.
519 *
520 * @note This function will fail if @c reference is not a member of @c o.
521 *
522 * @note The actual placing of the item relative to @c o's area will depend on
523 * the layout set to it.
524 *
525 * @note This call will trigger the box's _Evas_Object_Box_Api.insert_before
526 * smart function.
527 *
528 * @param[in] obj The object.
529 * @param[in] child A child Evas object to be made a member of @c o.
530 * @param[in] reference The child object to place this new one before.
531 *
532 * @return A box option bound to the recently added box item or @c null, on
533 * errors.
534 *
535 * @ingroup Evas_Box
536 */
537EOAPI Evas_Object_Box_Option *evas_obj_box_insert_before(Eo *obj, Efl_Canvas_Object *child, const Efl_Canvas_Object *reference) EINA_ARG_NONNULL(2, 3);
538
539/**
540 * @brief Get the name of the property of the child elements of the box o which
541 * have id as identifier
542 *
543 * @note This call won't do anything for a canonical Evas box. Only users which
544 * have subclassed it, setting custom box items options (see
545 * #Evas_Object_Box_Option) on it, would benefit from this function. They'd
546 * have to implement it and set it to be the
547 * _Evas_Object_Box_Api.property_name_get smart class function of the box,
548 * which is originally set to @c null.
549 *
550 * @param[in] obj The object.
551 * @param[in] property The numerical identifier of the option being searched,
552 * for its name.
553 *
554 * @return The name of the given property or @c null, on errors.
555 *
556 * @ingroup Evas_Box
557 */
558EOAPI const char *evas_obj_box_option_property_name_get(const Eo *obj, int property) EINA_WARN_UNUSED_RESULT;
559
560/**
561 * @brief No description supplied by the EAPI.
562 *
563 * @param[in] obj The object.
564 * @param[in] child Object to be inserted
565 * @param[in] reference Reference where the object will be inserted
566 *
567 * @return Box option
568 *
569 * @ingroup Evas_Box
570 */
571EOAPI Evas_Object_Box_Option *evas_obj_box_internal_insert_before(Eo *obj, Efl_Canvas_Object *child, const Efl_Canvas_Object *reference);
572
573/**
574 * @brief Layout function which sets the box o to a homogeneous horizontal box
575 *
576 * In a homogeneous horizontal box, its width is divided equally between the
577 * contained objects. The box's overall behavior is controlled by its
578 * padding/alignment properties, which are set by the
579 * evas_object_box_{h,v}_{align,padding}_set family of functions. The size
580 * hints the elements in the box -- set by the
581 * evas_object_size_hint_{align,padding,weight}_set functions -- also control
582 * the way this function works.
583 *
584 * Box's properties: @c align_h has no influence on the box for this layout.
585 * @c padding_h tells the box to draw empty spaces of that size, in pixels,
586 * between the (equal) child objects' cells. The @c align_v and @c padding_v
587 * properties of the box don't contribute to its behaviour when this layout is
588 * chosen.
589 *
590 * Child element's properties: @c padding_l and @c padding_r sum up to the
591 * required width of the child element. The @c align_x property tells the
592 * relative position of this overall child width in its allocated cell ($0.0 to
593 * extreme left, $1.0 to extreme right). A value of $-1.0 to @c align_x makes
594 * the box try to resize this child element to the exact width of its cell
595 * (respecting the minimum and maximum size hints on the child's width and
596 * accounting for its horizontal padding hints). The child's @c padding_t,
597 * @c padding_b and @c align_y properties apply for padding/alignment relative
598 * to the overall height of the box. A value of $-1.0 to @c align_y makes the
599 * box try to resize this child element to the exact height of its parent
600 * (respecting the maximum size hint on the child's height).
601 *
602 * @param[in] obj The object.
603 * @param[in] priv Private data pointer
604 * @param[in] data Data pointer
605 *
606 * @ingroup Evas_Box
607 */
608EOAPI void evas_obj_box_layout_homogeneous_horizontal(Eo *obj, Evas_Object_Box_Data *priv, void *data);
609
610/**
611 * @brief No description supplied by the EAPI.
612 *
613 * @param[in] obj The object.
614 * @param[in] child New box object
615 *
616 * @return Box option
617 *
618 * @ingroup Evas_Box
619 */
620EOAPI Evas_Object_Box_Option *evas_obj_box_internal_option_new(Eo *obj, Efl_Canvas_Object *child);
621
622/**
623 * @brief Layout function which sets the box o to a maximum size, homogeneous
624 * vertical box
625 *
626 * This function behaves analogously to
627 * evas_object_box_layout_homogeneous_max_size_horizontal. The description of
628 * its behaviour can be derived from that function's documentation.
629 *
630 * @param[in] obj The object.
631 * @param[in] priv Private data pointer
632 * @param[in] data Data pointer
633 *
634 * @ingroup Evas_Box
635 */
636EOAPI void evas_obj_box_layout_homogeneous_max_size_vertical(Eo *obj, Evas_Object_Box_Data *priv, void *data);
637
638/**
639 * @brief No description supplied by the EAPI.
640 *
641 * @param[in] obj The object.
642 * @param[in] child Object to be inserted
643 * @param[in] reference Reference where the object will be inserted
644 *
645 * @return Box option
646 *
647 * @ingroup Evas_Box
648 */
649EOAPI Evas_Object_Box_Option *evas_obj_box_internal_insert_after(Eo *obj, Efl_Canvas_Object *child, const Efl_Canvas_Object *reference);
650
651/**
652 * @brief Insert a new child object at a given position, in a given box object
653 * @c o.
654 *
655 * On success, the $"child,added" smart event will take place.
656 *
657 * @note This function will fail if the given position is invalid, given @c o's
658 * internal list of elements.
659 *
660 * @note The actual placing of the item relative to @c o's area will depend on
661 * the layout set to it.
662 *
663 * @note This call will trigger the box's _Evas_Object_Box_Api.insert_at smart
664 * function.
665 *
666 * @param[in] obj The object.
667 * @param[in] child A child Evas object to be made a member of @c o.
668 * @param[in] pos The numeric position (starting from $0) to place the new
669 * child object at.
670 *
671 * @return A box option bound to the recently added box item or @c null, on
672 * errors.
673 *
674 * @ingroup Evas_Box
675 */
676EOAPI Evas_Object_Box_Option *evas_obj_box_insert_at(Eo *obj, Efl_Canvas_Object *child, unsigned int pos) EINA_ARG_NONNULL(2);
677
678/**
679 * @brief No description supplied by the EAPI.
680 *
681 * @param[in] obj The object.
682 * @param[in] child Object to be prepended
683 *
684 * @return Box option
685 *
686 * @ingroup Evas_Box
687 */
688EOAPI Evas_Object_Box_Option *evas_obj_box_internal_prepend(Eo *obj, Efl_Canvas_Object *child);
689
690/**
691 * @brief Remove a given object from a box object, unparenting it again.
692 *
693 * On removal, you'll get an unparented object again, just as it was before you
694 * inserted it in the box. The _Evas_Object_Box_Api.option_free box smart
695 * callback will be called automatically for you and, also, the
696 * $"child,removed" smart event will take place.
697 *
698 * @note This call will trigger the box's _Evas_Object_Box_Api.remove smart
699 * function.
700 *
701 * @param[in] obj The object.
702 * @param[in] child The handle to the child object to be removed.
703 *
704 * @return @c true on success, @c false otherwise.
705 *
706 * @ingroup Evas_Box
707 */
708EOAPI Eina_Bool evas_obj_box_remove(Eo *obj, Efl_Canvas_Object *child) EINA_ARG_NONNULL(2);
709
710/**
711 * @brief Layout function which sets the box o to a stacking box
712 *
713 * In a stacking box, all children will be given the same size -- the box's own
714 * size -- and they will be stacked one above the other, so that the first
715 * object in @c o's internal list of child elements will be the bottommost in
716 * the stack.
717 *
718 * Box's properties: No box properties are used.
719 *
720 * Child element's properties: @c padding_l and @c padding_r sum up to the
721 * required width of the child element. The @c align_x property tells the
722 * relative position of this overall child width in its allocated cell ($0.0 to
723 * extreme left, $1.0 to extreme right). A value of $-1.0 to @c align_x makes
724 * the box try to resize this child element to the exact width of its cell
725 * (respecting the min and max hints on the child's width and accounting for
726 * its horizontal padding properties). The same applies to the vertical axis.
727 *
728 * @param[in] obj The object.
729 * @param[in] priv Private data pointer
730 * @param[in] data Data pointer
731 *
732 * @ingroup Evas_Box
733 */
734EOAPI void evas_obj_box_layout_stack(Eo *obj, Evas_Object_Box_Data *priv, void *data);
735
736/**
737 * @brief Layout function which sets the box o to a homogeneous vertical box.
738 *
739 * This function behaves analogously to
740 * evas_object_box_layout_homogeneous_horizontal. The description of its
741 * behaviour can be derived from that function's documentation.
742 *
743 * @param[in] obj The object.
744 * @param[in] priv Private data pointer
745 * @param[in] data Data pointer
746 *
747 * @ingroup Evas_Box
748 */
749EOAPI void evas_obj_box_layout_homogeneous_vertical(Eo *obj, Evas_Object_Box_Data *priv, void *data);
750
751/**
752 * @brief Layout function which sets the box o to a flow horizontal box.
753 *
754 * In a flow horizontal box, the box's child elements are placed in rows (think
755 * of text as an analogy). A row has as many elements as can fit into the box's
756 * width. The box's overall behavior is controlled by its properties, which are
757 * set by the evas_object_box_{h,v}_{align,padding}_set family of functions.
758 * The size hints of the elements in the box -- set by the
759 * evas_object_size_hint_{align,padding,weight}_set functions -- also control
760 * the way this function works.
761 *
762 * Box's properties: @c padding_h tells the box to draw empty spaces of that
763 * size, in pixels, between the child objects' cells. @c align_h dictates the
764 * horizontal alignment of the rows ($0.0 to left align them, $1.0 to right
765 * align). A value of $-1.0 to @c align_h lets the rows justified horizontally.
766 * @c align_v controls the vertical alignment of the entire set of rows ($0.0
767 * to top, $1.0 to bottom). A value of $-1.0 to @c align_v makes the box to
768 * justify the rows vertically. The padding between them in this case is
769 * corrected so that the first row touches the top border and the last one
770 * touches the bottom border (even if they must overlap). @c padding_v has no
771 * influence on the layout.
772 *
773 * Child element's properties: @c padding_l and @c padding_r sum up to the
774 * required width of the child element. The @c align_x property has no
775 * influence on the layout. The child's @c padding_t and @c padding_b sum up to
776 * the required height of the child element and is the only means (besides row
777 * justifying) of setting space between rows. Note, however, that @c align_y
778 * dictates positioning relative to the largest height required by a child
779 * object in the actual row.
780 *
781 * @param[in] obj The object.
782 * @param[in] priv Private data pointer
783 * @param[in] data Data pointer
784 *
785 * @ingroup Evas_Box
786 */
787EOAPI void evas_obj_box_layout_flow_horizontal(Eo *obj, Evas_Object_Box_Data *priv, void *data);
788
789/**
790 * @brief Returns the number of items in the box.
791 *
792 * @param[in] obj The object.
793 *
794 * @return Number of items in the box
795 *
796 * @ingroup Evas_Box
797 */
798EOAPI int evas_obj_box_count(Eo *obj);
799
800EWAPI extern const Efl_Event_Description _EVAS_BOX_EVENT_CHILD_ADDED;
801
802/** Called when a child object was added to the box
803 * @return Evas_Object_Box_Option *
804 *
805 * @ingroup Evas_Box
806 */
807#define EVAS_BOX_EVENT_CHILD_ADDED (&(_EVAS_BOX_EVENT_CHILD_ADDED))
808
809EWAPI extern const Efl_Event_Description _EVAS_BOX_EVENT_CHILD_REMOVED;
810
811/** Called when a child object was removed from the box
812 * @return Efl_Canvas_Object *
813 *
814 * @ingroup Evas_Box
815 */
816#define EVAS_BOX_EVENT_CHILD_REMOVED (&(_EVAS_BOX_EVENT_CHILD_REMOVED))
817
818#endif