Functions
Table

Functions

EOAPI void elm_obj_table_homogeneous_set (Eina_Bool homogeneous)
 Set the homogeneous layout in the table. More...
 
EOAPI Eina_Bool elm_obj_table_homogeneous_get (void)
 Get the current table homogeneous mode. More...
 
EOAPI void elm_obj_table_padding_set (Evas_Coord horizontal, Evas_Coord vertical)
 Set padding between cells. More...
 
EOAPI void elm_obj_table_padding_get (Evas_Coord *horizontal, Evas_Coord *vertical)
 Get padding between cells. More...
 
EOAPI void elm_obj_table_align_set (double horizontal, double vertical)
 Set alignment of table. More...
 
EOAPI void elm_obj_table_align_get (double *horizontal, double *vertical)
 Get alignment of table. More...
 
EOAPI void elm_obj_table_clear (Eina_Bool clear)
 Faster way to remove all child objects from a table object. More...
 
EOAPI void elm_obj_table_pack_set (Evas_Object *subobj, int column, int row, int colspan, int rowspan)
 Set the packing location of an existing child of the table. More...
 
EOAPI void elm_obj_table_pack_get (Evas_Object *subobj, int *column, int *row, int *colspan, int *rowspan)
 Get the packing location of an existing child of the table. More...
 
EOAPI void elm_obj_table_unpack (Evas_Object *subobj)
 Remove child from table. More...
 
EOAPI void elm_obj_table_pack (Evas_Object *subobj, int column, int row, int colspan, int rowspan)
 Add a subobject on the table with the coordinates passed. More...
 
void elm_table::clear (bool clear_) const
 Faster way to remove all child objects from a table object. More...
 
void elm_table::pack_set (evas::object subobj_, int column_, int row_, int colspan_, int rowspan_) const
 Set the packing location of an existing child of the table. More...
 
void elm_table::pack_get (evas::object subobj_, int *column_, int *row_, int *colspan_, int *rowspan_) const
 Get the packing location of an existing child of the table. More...
 
void elm_table::unpack (evas::object subobj_) const
 Remove child from table. More...
 
void elm_table::pack (evas::object subobj_, int column_, int row_, int colspan_, int rowspan_) const
 Add a subobject on the table with the coordinates passed. More...
 
bool elm_table::homogeneous_get () const
 Get the current table homogeneous mode. More...
 
void elm_table::homogeneous_set (bool homogeneous_) const
 Get the current table homogeneous mode. More...
 
void elm_table::padding_get (Evas_Coord *horizontal_, Evas_Coord *vertical_) const
 Get padding between cells. More...
 
void elm_table::padding_set (Evas_Coord horizontal_, Evas_Coord vertical_) const
 Get padding between cells. More...
 
void elm_table_homogeneous_set (Elm_Table *obj, Eina_Bool homogeneous)
 Set the homogeneous layout in the table. More...
 
Eina_Bool elm_table_homogeneous_get (const Elm_Table *obj)
 Get the current table homogeneous mode. More...
 
void elm_table_padding_set (Elm_Table *obj, Evas_Coord horizontal, Evas_Coord vertical)
 Set padding between cells. More...
 
void elm_table_padding_get (const Elm_Table *obj, Evas_Coord *horizontal, Evas_Coord *vertical)
 Get padding between cells. More...
 
void elm_table_align_set (Elm_Table *obj, double horizontal, double vertical)
 Set alignment of table. More...
 
void elm_table_align_get (const Elm_Table *obj, double *horizontal, double *vertical)
 Get alignment of table. More...
 
void elm_table_clear (Elm_Table *obj, Eina_Bool clear)
 Faster way to remove all child objects from a table object. More...
 
void elm_table_unpack (Elm_Table *obj, Evas_Object *subobj)
 Remove child from table. More...
 
void elm_table_pack (Elm_Table *obj, Evas_Object *subobj, int column, int row, int colspan, int rowspan)
 Add a subobject on the table with the coordinates passed. More...
 
Evas_Object * elm_table_add (Evas_Object *parent)
 Add a new table to the parent. More...
 
void elm_table_pack_set (Evas_Object *subobj, int col, int row, int colspan, int rowspan)
 Set the packing location of an existing child of the table. More...
 
void elm_table_pack_get (Evas_Object *subobj, int *col, int *row, int *colspan, int *rowspan)
 Get the packing location of an existing child of the table. More...
 

Detailed Description

table_inheritance_tree.png

A container widget to arrange other widgets in a table where items can span multiple columns or rows - even overlap (and then be raised or lowered accordingly to adjust stacking if they do overlap).

The row and column count is not fixed. The table widget adjusts itself when subobjects are added to it dynamically.

The most common way to use a table is:

table = elm_table_add(win);
evas_object_show(table);
elm_table_padding_set(table, space_between_columns, space_between_rows);
elm_table_pack(table, table_content_object, column, row, colspan, rowspan);
elm_table_pack(table, table_content_object, next_column, next_row, colspan, rowspan);
elm_table_pack(table, table_content_object, other_column, other_row, colspan, rowspan);

The following are examples of how to use a table:

Function Documentation

void elm_table::clear ( bool  clear_) const
inline

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

Parameters
clearIf true, will delete children, else just remove from table.

References elm_obj_table_clear().

EOAPI void elm_obj_table_align_get ( double *  horizontal,
double *  vertical 
)

Get alignment of table.

Since
1.13
Parameters
[out]horizontalthe horizontal alignment.
[out]verticalthe vertical alignment.

Referenced by elm_table_align_get().

EOAPI void elm_obj_table_align_set ( double  horizontal,
double  vertical 
)

Set alignment of table.

Since
1.13

Default value is 0.5.

Parameters
[in]horizontalthe horizontal alignment.
[in]verticalthe vertical alignment.

Referenced by elm_table_align_set().

EOAPI void elm_obj_table_clear ( Eina_Bool  clear)

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

Parameters
[in]clearIf true, will delete children, else just remove from table.

Referenced by elm_table::clear(), and elm_table_clear().

EOAPI Eina_Bool elm_obj_table_homogeneous_get ( void  )

Get the current table homogeneous mode.

Returns
A boolean to indicating if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)

Referenced by elm_table_homogeneous_get(), and elm_table::homogeneous_get().

EOAPI void elm_obj_table_homogeneous_set ( Eina_Bool  homogeneous)

Set the homogeneous layout in the table.

Parameters
[in]homogeneousA boolean to set if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)

Referenced by elm_table_homogeneous_set(), and elm_table::homogeneous_set().

EOAPI void elm_obj_table_pack ( Evas_Object *  subobj,
int  column,
int  row,
int  colspan,
int  rowspan 
)

Add a subobject on the table with the coordinates passed.

Note
All positioning inside the table is relative to rows and columns, so a value of 0 for x and y, means the top left cell of the table, and a value of 1 for w and h means subobj only takes that 1 cell.

Note that columns and rows only guarantee 16bit unsigned values at best. That means that col + colspan AND row + rowspan must fit inside 16bit unsigned values cleanly. You will be warned once values exceed 15bit storage, and attempting to use values not able to fit in 16bits will result in failure.

Parameters
[in]subobjThe subobject to be added to the table
[in]columnColumn number
[in]rowRow number
[in]colspancolspan
[in]rowspanrowspan

Referenced by elm_table_pack(), and elm_table::pack().

EOAPI void elm_obj_table_pack_get ( Evas_Object *  subobj,
int *  column,
int *  row,
int *  colspan,
int *  rowspan 
)

Get the packing location of an existing child of the table.

See also
elm_table_pack_set()
Parameters
[in]subobjThe subobject to be modified in the table
[out]columnColumn number
[out]rowRow number
[out]colspancolspan
[out]rowspanrowspan

Referenced by elm_table_pack_get(), and elm_table::pack_get().

EOAPI void elm_obj_table_pack_set ( Evas_Object *  subobj,
int  column,
int  row,
int  colspan,
int  rowspan 
)

Set the packing location of an existing child of the table.

Modifies the position of an object already in the table.

Note
All positioning inside the table is relative to rows and columns, so a value of 0 for col and row, means the top left cell of the table, and a value of 1 for colspan and rowspan means subobj only takes that 1 cell.
Parameters
[in]subobjThe subobject to be modified in the table
[in]columnColumn number
[in]rowRow number
[in]colspancolspan
[in]rowspanrowspan

Referenced by elm_table_pack_set(), and elm_table::pack_set().

EOAPI void elm_obj_table_padding_get ( Evas_Coord *  horizontal,
Evas_Coord *  vertical 
)

Get padding between cells.

Parameters
[out]horizontalset the horizontal padding.
[out]verticalset the vertical padding.

Referenced by elm_table_padding_get(), and elm_table::padding_get().

EOAPI void elm_obj_table_padding_set ( Evas_Coord  horizontal,
Evas_Coord  vertical 
)

Set padding between cells.

Default value is 0.

Parameters
[in]horizontalset the horizontal padding.
[in]verticalset the vertical padding.

Referenced by elm_table_padding_set(), and elm_table::padding_set().

EOAPI void elm_obj_table_unpack ( Evas_Object *  subobj)

Remove child from table.

Parameters
[in]subobjThe subobject

Referenced by elm_table_unpack(), and elm_table::unpack().

Evas_Object* elm_table_add ( Evas_Object *  parent)

Add a new table to the parent.

Parameters
parentThe parent object
Returns
The new object or NULL if it cannot be created
void elm_table_align_get ( const Elm_Table *  obj,
double *  horizontal,
double *  vertical 
)

Get alignment of table.

Since
1.13
Parameters
[out]horizontalthe horizontal alignment.
[out]verticalthe vertical alignment.

References elm_obj_table_align_get().

void elm_table_align_set ( Elm_Table *  obj,
double  horizontal,
double  vertical 
)

Set alignment of table.

Since
1.13

Default value is 0.5.

Parameters
[in]horizontalthe horizontal alignment.
[in]verticalthe vertical alignment.

References elm_obj_table_align_set().

void elm_table_clear ( Elm_Table *  obj,
Eina_Bool  clear 
)

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

Parameters
[in]clearIf true, will delete children, else just remove from table.

References elm_obj_table_clear().

Eina_Bool elm_table_homogeneous_get ( const Elm_Table *  obj)

Get the current table homogeneous mode.

Returns
A boolean to indicating if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)

References elm_obj_table_homogeneous_get().

void elm_table_homogeneous_set ( Elm_Table *  obj,
Eina_Bool  homogeneous 
)

Set the homogeneous layout in the table.

Parameters
[in]homogeneousA boolean to set if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)

References elm_obj_table_homogeneous_set().

void elm_table_pack ( Elm_Table *  obj,
Evas_Object *  subobj,
int  column,
int  row,
int  colspan,
int  rowspan 
)

Add a subobject on the table with the coordinates passed.

Note
All positioning inside the table is relative to rows and columns, so a value of 0 for x and y, means the top left cell of the table, and a value of 1 for w and h means subobj only takes that 1 cell.

Note that columns and rows only guarantee 16bit unsigned values at best. That means that col + colspan AND row + rowspan must fit inside 16bit unsigned values cleanly. You will be warned once values exceed 15bit storage, and attempting to use values not able to fit in 16bits will result in failure.

Parameters
[in]subobjThe subobject to be added to the table
[in]columnColumn number
[in]rowRow number
[in]colspancolspan
[in]rowspanrowspan

References elm_obj_table_pack().

void elm_table_pack_get ( Evas_Object *  subobj,
int *  col,
int *  row,
int *  colspan,
int *  rowspan 
)

Get the packing location of an existing child of the table.

Parameters
subobjThe subobject to be modified in the table
colColumn number
rowRow number
colspancolspan
rowspanrowspan
See also
elm_table_pack_set()

References elm_obj_table_pack_get().

void elm_table_pack_set ( Evas_Object *  subobj,
int  col,
int  row,
int  colspan,
int  rowspan 
)

Set the packing location of an existing child of the table.

Parameters
subobjThe subobject to be modified in the table
colColumn number
rowRow number
colspancolspan
rowspanrowspan

Modifies the position of an object already in the table.

Note
All positioning inside the table is relative to rows and columns, so a value of 0 for col and row, means the top left cell of the table, and a value of 1 for colspan and rowspan means subobj only takes that 1 cell.

References elm_obj_table_pack_set().

void elm_table_padding_get ( const Elm_Table *  obj,
Evas_Coord *  horizontal,
Evas_Coord *  vertical 
)

Get padding between cells.

Parameters
[out]horizontalset the horizontal padding.
[out]verticalset the vertical padding.

References elm_obj_table_padding_get().

void elm_table_padding_set ( Elm_Table *  obj,
Evas_Coord  horizontal,
Evas_Coord  vertical 
)

Set padding between cells.

Default value is 0.

Parameters
[in]horizontalset the horizontal padding.
[in]verticalset the vertical padding.

References elm_obj_table_padding_set().

void elm_table_unpack ( Elm_Table *  obj,
Evas_Object *  subobj 
)

Remove child from table.

Parameters
[in]subobjThe subobject

References elm_obj_table_unpack().

bool elm_table::homogeneous_get ( ) const
inline

Get the current table homogeneous mode.

Returns
A boolean to indicating if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)
Parameters
homogeneousA boolean to set if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)

References elm_obj_table_homogeneous_get().

void elm_table::homogeneous_set ( bool  homogeneous_) const
inline

Get the current table homogeneous mode.

Returns
A boolean to indicating if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)
Parameters
homogeneousA boolean to set if the layout is homogeneous in the table (EINA_TRUE = homogeneous, EINA_FALSE = no homogeneous)

References elm_obj_table_homogeneous_set().

void elm_table::pack ( evas::object  subobj_,
int  column_,
int  row_,
int  colspan_,
int  rowspan_ 
) const
inline

Add a subobject on the table with the coordinates passed.

Note
All positioning inside the table is relative to rows and columns, so a value of 0 for x and y, means the top left cell of the table, and a value of 1 for w and h means subobj only takes that 1 cell.

Note that columns and rows only guarantee 16bit unsigned values at best. That means that col + colspan AND row + rowspan must fit inside 16bit unsigned values cleanly. You will be warned once values exceed 15bit storage, and attempting to use values not able to fit in 16bits will result in failure.

Parameters
subobjThe subobject to be added to the table
columnColumn number
rowRow number
colspancolspan
rowspanrowspan

References elm_obj_table_pack().

void elm_table::pack_get ( evas::object  subobj_,
int *  column_,
int *  row_,
int *  colspan_,
int *  rowspan_ 
) const
inline

Get the packing location of an existing child of the table.

See also
elm_table_pack_set()
Parameters
subobjThe subobject to be modified in the table
[out]columnColumn number
[out]rowRow number
[out]colspancolspan
[out]rowspanrowspan

References elm_obj_table_pack_get().

void elm_table::pack_set ( evas::object  subobj_,
int  column_,
int  row_,
int  colspan_,
int  rowspan_ 
) const
inline

Set the packing location of an existing child of the table.

Modifies the position of an object already in the table.

Note
All positioning inside the table is relative to rows and columns, so a value of 0 for col and row, means the top left cell of the table, and a value of 1 for colspan and rowspan means subobj only takes that 1 cell.
Parameters
subobjThe subobject to be modified in the table
columnColumn number
rowRow number
colspancolspan
rowspanrowspan

References elm_obj_table_pack_set().

void elm_table::padding_get ( Evas_Coord *  horizontal_,
Evas_Coord *  vertical_ 
) const
inline

Get padding between cells.

Parameters
horizontalset the horizontal padding.
verticalset the vertical padding.

References elm_obj_table_padding_get().

void elm_table::padding_set ( Evas_Coord  horizontal_,
Evas_Coord  vertical_ 
) const
inline

Get padding between cells.

Parameters
horizontalset the horizontal padding.
verticalset the vertical padding.

References elm_obj_table_padding_set().

void elm_table::unpack ( evas::object  subobj_) const
inline

Remove child from table.

Parameters
subobjThe subobject

References elm_obj_table_unpack().