elementary/map - map supports language,changed
[framework/uifw/elementary.git] / src / lib / elm_grid.h
1 /**
2  * @defgroup Grid Grid
3  * @ingroup Elementary
4  *
5  * @image html grid_inheritance_tree.png
6  * @image latex grid_inheritance_tree.eps
7  *
8  * The grid is a grid layout widget that lays out a series of children as a
9  * fixed "grid" of widgets using a given percentage of the grid width and
10  * height each using the child object.
11  *
12  * The Grid uses a "Virtual resolution" that is stretched to fill the grid
13  * widgets size itself. The default is 100 x 100, so that means the
14  * position and sizes of children will effectively be percentages (0 to 100)
15  * of the width or height of the grid widget
16  *
17  * @{
18  */
19
20 /**
21  * Add a new grid to the parent
22  *
23  * @param parent The parent object
24  * @return The new object or NULL if it cannot be created
25  *
26  * @ingroup Grid
27  */
28 EAPI Evas_Object *elm_grid_add(Evas_Object *parent);
29
30 /**
31  * Set the virtual size of the grid
32  *
33  * @param obj The grid object
34  * @param w The virtual width of the grid
35  * @param h The virtual height of the grid
36  *
37  * @ingroup Grid
38  */
39 EAPI void         elm_grid_size_set(Evas_Object *obj, Evas_Coord w, Evas_Coord h);
40
41 /**
42  * Get the virtual size of the grid
43  *
44  * @param obj The grid object
45  * @param w Pointer to integer to store the virtual width of the grid
46  * @param h Pointer to integer to store the virtual height of the grid
47  *
48  * @ingroup Grid
49  */
50 EAPI void         elm_grid_size_get(const Evas_Object *obj, Evas_Coord *w, Evas_Coord *h);
51
52 /**
53  * Pack child at given position and size
54  *
55  * @param obj The grid object
56  * @param subobj The child to pack
57  * @param x The virtual x coord at which to pack it
58  * @param y The virtual y coord at which to pack it
59  * @param w The virtual width at which to pack it
60  * @param h The virtual height at which to pack it
61  *
62  * @ingroup Grid
63  */
64 EAPI void         elm_grid_pack(Evas_Object *obj, Evas_Object *subobj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h);
65
66 /**
67  * Unpack a child from a grid object
68  *
69  * @param obj The grid object
70  * @param subobj The child to unpack
71  *
72  * @ingroup Grid
73  */
74 EAPI void         elm_grid_unpack(Evas_Object *obj, Evas_Object *subobj);
75
76 /**
77  * Faster way to remove all child objects from a grid object.
78  *
79  * @param obj The grid object
80  * @param clear If true, it will delete just removed children
81  *
82  * @ingroup Grid
83  */
84 EAPI void         elm_grid_clear(Evas_Object *obj, Eina_Bool clear);
85
86 /**
87  * Set packing of an existing child at to position and size
88  *
89  * @param subobj The child to set packing of
90  * @param x The virtual x coord at which to pack it
91  * @param y The virtual y coord at which to pack it
92  * @param w The virtual width at which to pack it
93  * @param h The virtual height at which to pack it
94  *
95  * @ingroup Grid
96  */
97 EAPI void         elm_grid_pack_set(Evas_Object *subobj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h);
98
99 /**
100  * Get packing of a child
101  *
102  * @param subobj The child to query
103  * @param x Pointer to integer to store the virtual x coord
104  * @param y Pointer to integer to store the virtual y coord
105  * @param w Pointer to integer to store the virtual width
106  * @param h Pointer to integer to store the virtual height
107  *
108  * @ingroup Grid
109  */
110 EAPI void         elm_grid_pack_get(Evas_Object *subobj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h);
111
112 /**
113  * Get the list of the children for the grid.
114  *
115  * @param obj The grid object
116  *
117  * @note This is a duplicate of the list kept by the grid internally.
118          It's up to the user to destroy it when it no longer needs it.
119                         It's possible to remove objects from the grid when walking this
120                         list, but these removals won't be reflected on it.
121  *
122  * @ingroup Grid
123  */
124 EAPI Eina_List *elm_grid_children_get(const Evas_Object *obj);
125
126 /**
127  * @}
128  */