2015-04-22 04:43:05 -07:00
|
|
|
class Elm.Table (Elm.Widget)
|
2014-03-26 08:37:22 -07:00
|
|
|
{
|
2016-11-24 05:46:11 -08:00
|
|
|
[[Elementary table class]]
|
2016-05-12 09:06:04 -07:00
|
|
|
legacy_prefix: elm_table;
|
2014-03-26 08:37:22 -07:00
|
|
|
eo_prefix: elm_obj_table;
|
|
|
|
data: null;
|
2015-05-07 09:32:53 -07:00
|
|
|
methods {
|
|
|
|
@property homogeneous {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Control the homogenous state in a table.]]
|
|
|
|
set {}
|
|
|
|
get {}
|
2014-03-26 08:37:22 -07:00
|
|
|
values {
|
2015-08-07 06:08:01 -07:00
|
|
|
homogeneous: bool; [[A boolean to set if the layout is
|
|
|
|
homogeneous in the table.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|
2015-05-07 09:32:53 -07:00
|
|
|
@property padding {
|
2014-03-26 08:37:22 -07:00
|
|
|
set {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Set padding between cells. Default value is 0.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
get {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Get padding between cells.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
values {
|
2015-08-07 06:08:01 -07:00
|
|
|
horizontal: Evas.Coord; [[The horizontal padding.]]
|
|
|
|
vertical: Evas.Coord; [[The vertical padding.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|
2015-05-07 09:32:53 -07:00
|
|
|
@property align {
|
2015-01-11 15:17:19 -08:00
|
|
|
set {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Set alignment of table. Default value is 0.5.
|
2015-01-11 15:17:19 -08:00
|
|
|
|
2015-08-07 06:08:01 -07:00
|
|
|
@since 1.13
|
|
|
|
]]
|
2015-01-11 15:17:19 -08:00
|
|
|
}
|
|
|
|
get {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Get alignment of table.
|
2015-01-11 15:17:19 -08:00
|
|
|
|
2015-08-07 06:08:01 -07:00
|
|
|
@since 1.13
|
|
|
|
]]
|
2015-01-11 15:17:19 -08:00
|
|
|
}
|
|
|
|
values {
|
2015-08-07 06:08:01 -07:00
|
|
|
horizontal: double; [[The horizontal alignment.]]
|
|
|
|
vertical: double; [[The vertical alignment.]]
|
2015-01-11 15:17:19 -08:00
|
|
|
}
|
|
|
|
}
|
2014-03-26 08:37:22 -07:00
|
|
|
clear {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Faster way to remove all child objects from a table object.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
params {
|
2016-11-24 05:46:11 -08:00
|
|
|
@in clear: bool; [[If $true, will delete children, else just remove from table.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|
2014-07-22 09:13:52 -07:00
|
|
|
child_get @const {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Get child object of table at given coordinates.]]
|
2016-06-20 21:26:15 -07:00
|
|
|
return: Efl.Canvas.Object; [[Child of object if find if not return $null.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
params {
|
2015-08-07 06:08:01 -07:00
|
|
|
@in col: int; [[Column number of child object.]]
|
|
|
|
@in row: int; [[Row number of child object.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
pack_set {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Set the packing location of an existing child of the table
|
2014-03-26 08:37:22 -07:00
|
|
|
|
2015-08-07 06:08:01 -07:00
|
|
|
Modifies the position of an object already in the table.
|
2014-03-26 08:37:22 -07:00
|
|
|
|
2015-08-07 06:08:01 -07:00
|
|
|
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 only takes that 1 cell.
|
|
|
|
]]
|
2014-03-26 08:37:22 -07:00
|
|
|
params {
|
2016-06-20 21:26:15 -07:00
|
|
|
@in subobj: Efl.Canvas.Object; [[The subobject to be modified in the table.]]
|
2015-08-07 06:08:01 -07:00
|
|
|
@in column: int; [[Column number.]]
|
|
|
|
@in row: int; [[Row number.]]
|
2016-07-02 11:41:28 -07:00
|
|
|
@in colspan: int; [[Columns span.]]
|
|
|
|
@in rowspan: int; [[Rows span.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
2014-08-11 07:46:11 -07:00
|
|
|
legacy: null;
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
pack_get {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Get the packing location of an existing child of the table.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
params {
|
2016-06-20 21:26:15 -07:00
|
|
|
@in subobj: Efl.Canvas.Object; [[The subobject to be modified in the table.]]
|
2015-08-07 06:08:01 -07:00
|
|
|
@out column: int; [[Column number.]]
|
|
|
|
@out row: int; [[Row number.]]
|
2016-07-02 11:41:28 -07:00
|
|
|
@out colspan: int; [[Columns span.]]
|
|
|
|
@out rowspan: int; [[Rows span.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
2014-08-11 07:46:11 -07:00
|
|
|
legacy: null;
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
unpack {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[Remove child from table.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
params {
|
2016-06-20 21:26:15 -07:00
|
|
|
@in subobj: Efl.Canvas.Object; [[The subobject.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
pack {
|
2015-08-07 06:08:01 -07:00
|
|
|
[[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: 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.
|
|
|
|
]]
|
2014-03-26 08:37:22 -07:00
|
|
|
params {
|
2016-06-20 21:26:15 -07:00
|
|
|
@in subobj: Efl.Canvas.Object; [[The subobject to be added to the table.]]
|
2015-08-07 06:08:01 -07:00
|
|
|
@in column: int; [[Column number.]]
|
|
|
|
@in row: int; [[Row number.]]
|
2016-07-02 11:41:28 -07:00
|
|
|
@in colspan: int; [[Columns span.]]
|
|
|
|
@in rowspan: int; [[Rows span.]]
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
implements {
|
2014-06-20 02:47:39 -07:00
|
|
|
class.constructor;
|
2016-08-10 07:23:04 -07:00
|
|
|
Efl.Object.constructor;
|
2016-06-17 01:26:08 -07:00
|
|
|
Efl.Canvas.Group.group_add;
|
|
|
|
Efl.Canvas.Group.group_del;
|
|
|
|
Efl.Canvas.Group.group_calculate;
|
2015-04-22 04:33:10 -07:00
|
|
|
Elm.Widget.focus_direction;
|
|
|
|
Elm.Widget.focus_next_manager_is;
|
|
|
|
Elm.Widget.focus_next;
|
|
|
|
Elm.Widget.focus_direction_manager_is;
|
|
|
|
Elm.Widget.theme_apply;
|
|
|
|
Elm.Widget.sub_object_del;
|
2014-03-26 08:37:22 -07:00
|
|
|
}
|
|
|
|
}
|