2 * @defgroup Table Table
4 * A container widget to arrange other widgets in a table where items can
5 * also span multiple columns or rows - even overlap (and then be raised or
6 * lowered accordingly to adjust stacking if they do overlap).
8 * For a Table widget the row/column count is not fixed.
9 * The table widget adjusts itself when subobjects are added to it dynamically.
11 * The followin are examples of how to use a table:
12 * @li @ref tutorial_table_01
13 * @li @ref tutorial_table_02
19 * @brief Add a new table to the parent
21 * @param parent The parent object
22 * @return The new object or NULL if it cannot be created
24 EAPI Evas_Object *elm_table_add(Evas_Object *parent);
27 * @brief Set the homogeneous layout in the table
29 * @param obj The layout object
30 * @param homogeneous A boolean to set if the layout is homogeneous in the
31 * table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)
33 EAPI void elm_table_homogeneous_set(Evas_Object *obj, Eina_Bool homogeneous);
36 * @brief Get the current table homogeneous mode.
38 * @param obj The table object
39 * @return A boolean to indicating if the layout is homogeneous in the table
40 * (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)
42 EAPI Eina_Bool elm_table_homogeneous_get(const Evas_Object *obj);
45 * @brief Set padding between cells.
47 * @param obj The layout object.
48 * @param horizontal set the horizontal padding.
49 * @param vertical set the vertical padding.
53 EAPI void elm_table_padding_set(Evas_Object *obj, Evas_Coord horizontal, Evas_Coord vertical);
56 * @brief Get padding between cells.
58 * @param obj The layout object.
59 * @param horizontal set the horizontal padding.
60 * @param vertical set the vertical padding.
62 EAPI void elm_table_padding_get(const Evas_Object *obj, Evas_Coord *horizontal, Evas_Coord *vertical);
65 * @brief Add a subobject on the table with the coordinates passed
67 * @param obj The table object
68 * @param subobj The subobject to be added to the table
70 * @param y Column number
74 * @note All positioning inside the table is relative to rows and columns, so
75 * a value of 0 for x and y, means the top left cell of the table, and a
76 * value of 1 for w and h means @p subobj only takes that 1 cell.
78 EAPI void elm_table_pack(Evas_Object *obj, Evas_Object *subobj, int x, int y, int w, int h);
81 * @brief Remove child from table.
83 * @param obj The table object
84 * @param subobj The subobject
86 EAPI void elm_table_unpack(Evas_Object *obj, Evas_Object *subobj);
89 * @brief Faster way to remove all child objects from a table object.
91 * @param obj The table object
92 * @param clear If true, will delete children, else just remove from table.
94 EAPI void elm_table_clear(Evas_Object *obj, Eina_Bool clear);
97 * @brief Set the packing location of an existing child of the table
99 * @param subobj The subobject to be modified in the table
100 * @param x Row number
101 * @param y Column number
105 * Modifies the position of an object already in the table.
107 * @note All positioning inside the table is relative to rows and columns, so
108 * a value of 0 for x and y, means the top left cell of the table, and a
109 * value of 1 for w and h means @p subobj only takes that 1 cell.
111 EAPI void elm_table_pack_set(Evas_Object *subobj, int x, int y, int w, int h);
114 * @brief Get the packing location of an existing child of the table
116 * @param subobj The subobject to be modified in the table
117 * @param x Row number
118 * @param y Column number
122 * @see elm_table_pack_set()
124 EAPI void elm_table_pack_get(Evas_Object *subobj, int *x, int *y, int *w, int *h);