Tizen Native API
Grid Smart Object.

Functions

void evas_object_grid_mirrored_set (Evas_Grid *obj, Eina_Bool mirrored)
 Sets the mirrored mode of the grid. In mirrored mode the grid items go from right to left instead of left to right. That is, 0,0 is top right, not to left.
Eina_Bool evas_object_grid_mirrored_get (const Evas_Grid *obj)
 Gets the mirrored mode of the grid.
void evas_object_grid_size_set (Evas_Grid *obj, int w, int h)
 Set the virtual resolution for the grid.
void evas_object_grid_size_get (const Evas_Grid *obj, int *w, int *h)
 Get the current virtual resolution.
Eina_Listevas_object_grid_children_get (const Evas_Grid *obj)
 Get the list of children for the grid.
Eina_Accessorevas_object_grid_accessor_new (const Evas_Grid *obj)
 Get an accessor to get random access to the list of children for the grid.
void evas_object_grid_clear (Evas_Grid *obj, Eina_Bool clear)
 Faster way to remove all child objects from a grid object.
Eina_Iteratorevas_object_grid_iterator_new (const Evas_Grid *obj)
 Get an iterator to walk the list of children for the grid.
Evas_Objectevas_object_grid_add_to (Evas_Grid *obj)
 Create a grid that is child of a given element parent.
Eina_Bool evas_object_grid_unpack (Evas_Grid *obj, Evas_Object *child)
 Remove child from grid.
Eina_Bool evas_object_grid_pack_get (const Evas_Grid *obj, Evas_Object *child, int *x, int *y, int *w, int *h)
 Get the pack options for a grid child.
Eina_Bool evas_object_grid_pack (Evas_Grid *obj, Evas_Object *child, int x, int y, int w, int h)
 Add a new child to a grid object.
Evas_Objectevas_object_grid_add (Evas *evas)
 Create a new grid.

Convenience smart object that packs children under a regular grid layout, using their virtual grid location and size to determine children's positions inside the grid object's area.

Since (EFL) :
1.1

Function Documentation

Eina_Accessor* evas_object_grid_accessor_new ( const Evas_Grid *  obj)

Get an accessor to get random access to the list of children for the grid.

Since :
2.3
Remarks:
Do not remove or delete objects while walking the list.
Since (EFL) :
1.1
Parameters:
[in]objThe grid object

Create a new grid.

Since :
2.3
Parameters:
[in]evasCanvas in which grid will be added.
Remarks:
It's set to a virtual size of 1x1 by default and add children with evas_object_grid_pack().
Since (EFL) :
1.1
Evas_Object* evas_object_grid_add_to ( Evas_Grid *  obj)

Create a grid that is child of a given element parent.

Since :
2.3
See also:
evas_object_grid_add()
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
Eina_List* evas_object_grid_children_get ( const Evas_Grid *  obj)

Get the list of children for the grid.

Since :
2.3
Remarks:
This is a duplicate of the list kept by the grid internally. It's up to the user to destroy it when it no longer needs it. It's possible to remove objects from the grid when walking this list, but these removals won't be reflected on it.
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
void evas_object_grid_clear ( Evas_Grid *  obj,
Eina_Bool  clear 
)

Faster way to remove all child objects from a grid object.

Since :
2.3
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[in]clearif true, it will delete just removed children.
Eina_Iterator* evas_object_grid_iterator_new ( const Evas_Grid *  obj)

Get an iterator to walk the list of children for the grid.

Since :
2.3
Remarks:
Do not remove or delete objects while walking the list.
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
Eina_Bool evas_object_grid_mirrored_get ( const Evas_Grid *  obj)

Gets the mirrored mode of the grid.

Since :
2.3
Returns:
EINA_TRUE if it's a mirrored grid, EINA_FALSE otherwise.
See also:
evas_object_grid_mirrored_set()
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
void evas_object_grid_mirrored_set ( Evas_Grid *  obj,
Eina_Bool  mirrored 
)

Sets the mirrored mode of the grid. In mirrored mode the grid items go from right to left instead of left to right. That is, 0,0 is top right, not to left.

Since :
2.3
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[in]mirroredthe mirrored mode to set
Eina_Bool evas_object_grid_pack ( Evas_Grid *  obj,
Evas_Object child,
int  x,
int  y,
int  w,
int  h 
)

Add a new child to a grid object.

Since :
2.3
Returns:
1 on success, 0 on failure.
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[in]childThe child object to add.
[in]xThe virtual x coordinate of the child
[in]yThe virtual y coordinate of the child
[in]wThe virtual width of the child
[in]hThe virtual height of the child
Eina_Bool evas_object_grid_pack_get ( const Evas_Grid *  obj,
Evas_Object child,
int *  x,
int *  y,
int *  w,
int *  h 
)

Get the pack options for a grid child.

Since :
2.3
Remarks:
Get the pack x, y, width and height in virtual coordinates set by evas_object_grid_pack()
Returns:
1 on success, 0 on failure.
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[in]childThe grid child to query for coordinates
[out]xThe pointer to where the x coordinate will be returned
[out]yThe pointer to where the y coordinate will be returned
[out]wThe pointer to where the width will be returned
[out]hThe pointer to where the height will be returned
void evas_object_grid_size_get ( const Evas_Grid *  obj,
int *  w,
int *  h 
)

Get the current virtual resolution.

Since :
2.3
See also:
evas_object_grid_size_set()
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[out]wThe virtual horizontal size (resolution) in integer units
[out]hThe virtual vertical size (resolution) in integer units
void evas_object_grid_size_set ( Evas_Grid *  obj,
int  w,
int  h 
)

Set the virtual resolution for the grid.

Since :
2.3
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[in]wThe virtual horizontal size (resolution) in integer units
[in]hThe virtual vertical size (resolution) in integer units
Eina_Bool evas_object_grid_unpack ( Evas_Grid *  obj,
Evas_Object child 
)

Remove child from grid.

Since :
2.3
Remarks:
removing a child will immediately call a walk over children in order to recalculate numbers of columns and rows. If you plan to remove all children, use evas_object_grid_clear() instead.
Returns:
1 on success, 0 on failure.
Since (EFL) :
1.1
Parameters:
[in]objThe grid object
[in]childNo description supplied.