2017-09-13 01:11:06 -07:00
|
|
|
import eina_types;
|
|
|
|
|
efl: apply the stabilzed column of the efl api board
Summary:
The project https://phab.enlightenment.org/tag/efl_api/ has been used in
the last few weeks to figure out which classes can be stablized and
which cannot. This commit moves those dedicated classes outside beta.
And makes them stable.
ref T7601
ref T7600
ref T7599
ref T7598
ref T7597
ref T7596
ref T7594
ref T7593
ref T7591
ref T7590
ref T7589
ref T7588
ref T7583
ref T7582
ref T7581
ref T7576
ref T7570
ref T7567
ref T7564
ref T7563
ref T7560
ref T7559
ref T7672
ref T7584
ref T7577
ref T7571
ref T7558
ref T7555
ref T7554
ref T7553
ref T7512
ref T7511
Depends on D8272
Reviewers: cedric, stefan_schmidt, zmike, segfaultxavi
Reviewed By: segfaultxavi
Subscribers: #reviewers, #committers
Tags: #efl
Maniphest Tasks: T7672, T7601, T7600, T7599, T7598, T7597, T7596, T7594, T7593, T7591, T7590, T7589, T7588, T7584, T7583, T7582, T7581, T7577, T7576, T7571, T7570, T7567, T7564, T7563, T7560, T7559, T7558, T7555, T7554, T7553, T7512, T7511
Differential Revision: https://phab.enlightenment.org/D8273
2019-03-09 04:44:17 -08:00
|
|
|
interface Efl.Layout.Calc
|
2017-08-01 02:15:34 -07:00
|
|
|
{
|
|
|
|
[[This interface defines a common set of APIs used to trigger calculations
|
|
|
|
with layout objects.
|
|
|
|
|
|
|
|
This defines all the APIs supported by legacy "Edje" object, known in EO
|
|
|
|
API as Efl.Canvas.Layout.
|
2019-03-22 08:25:22 -07:00
|
|
|
|
|
|
|
@since 1.22
|
2017-08-01 02:15:34 -07:00
|
|
|
]]
|
2019-09-26 07:39:56 -07:00
|
|
|
event_c_prefix: efl_layout;
|
2017-08-01 02:15:34 -07:00
|
|
|
methods {
|
|
|
|
@property calc_auto_update_hints {
|
|
|
|
[[Whether this object updates its size hints automatically.
|
|
|
|
|
|
|
|
By default edje doesn't set size hints on itself. If this property
|
|
|
|
is set to $true, size hints will be updated after recalculation.
|
|
|
|
Be careful, as recalculation may happen often, enabling this
|
|
|
|
property may have a considerable performance impact as other widgets
|
|
|
|
will be notified of the size hints changes.
|
|
|
|
|
|
|
|
A layout recalculation can be triggered by @.calc_size_min(),
|
2017-09-18 01:31:54 -07:00
|
|
|
@.calc_size_min(), @.calc_parts_extends() or even any other internal
|
|
|
|
event.
|
2017-08-01 02:15:34 -07:00
|
|
|
]]
|
|
|
|
set {
|
|
|
|
}
|
|
|
|
get {
|
|
|
|
}
|
|
|
|
values {
|
|
|
|
update: bool(false); [[Whether or not update the size hints.]]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
calc_size_min {
|
|
|
|
[[Calculates the minimum required size for a given layout object.
|
|
|
|
|
|
|
|
This call will trigger an internal recalculation of all parts of
|
|
|
|
the object, in order to return its minimum required dimensions for
|
|
|
|
width and height. The user might choose to impose those minimum
|
2017-09-18 01:31:54 -07:00
|
|
|
sizes, making the resulting calculation to get to values greater or
|
|
|
|
equal than $restricted in both directions.
|
2017-08-01 02:15:34 -07:00
|
|
|
|
|
|
|
Note: At the end of this call, the object won't be automatically
|
|
|
|
resized to the new dimensions, but just return the calculated sizes.
|
|
|
|
The caller is the one up to change its geometry or not.
|
|
|
|
|
|
|
|
Warning: Be advised that invisible parts in the object will be taken
|
|
|
|
into account in this calculation.
|
|
|
|
]]
|
2017-09-18 01:19:03 -07:00
|
|
|
return: Eina.Size2D; [[The minimum required size.]]
|
2017-08-01 02:15:34 -07:00
|
|
|
params {
|
2017-09-18 01:19:03 -07:00
|
|
|
@in restricted: Eina.Size2D @optional;
|
|
|
|
[[The minimum size constraint as input, the returned size
|
|
|
|
can not be lower than this (in both directions).]]
|
2017-08-01 02:15:34 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
calc_parts_extends {
|
|
|
|
[[Calculates the geometry of the region, relative to a given layout
|
|
|
|
object's area, occupied by all parts in the object.
|
|
|
|
|
|
|
|
This function gets the geometry of the rectangle equal to the area
|
|
|
|
required to group all parts in obj's group/collection. The x
|
|
|
|
and y coordinates are relative to the top left corner of the
|
|
|
|
whole obj object's area. Parts placed out of the group's
|
|
|
|
boundaries will also be taken in account, so that x and y
|
|
|
|
may be negative.
|
|
|
|
|
|
|
|
Note: On failure, this function will make all non-$null geometry
|
|
|
|
pointers' pointed variables be set to zero.
|
|
|
|
]]
|
2017-09-13 19:59:44 -07:00
|
|
|
return: Eina.Rect; [[The calculated region.]]
|
2017-08-01 02:15:34 -07:00
|
|
|
}
|
|
|
|
calc_freeze {
|
|
|
|
[[Freezes the layout object.
|
|
|
|
|
|
|
|
This function puts all changes on hold. Successive freezes will
|
|
|
|
nest, requiring an equal number of thaws.
|
|
|
|
|
|
|
|
See also @.calc_thaw.
|
|
|
|
]]
|
|
|
|
return: int; [[The frozen state or 0 on error]]
|
|
|
|
}
|
|
|
|
calc_thaw {
|
|
|
|
[[Thaws the layout object.
|
|
|
|
|
|
|
|
This function thaws (in other words "unfreezes") the given layout
|
|
|
|
object.
|
|
|
|
|
2019-04-02 02:32:05 -07:00
|
|
|
Note: If successive freezes were done, an equal number of thaws will
|
2017-08-01 02:15:34 -07:00
|
|
|
be required.
|
|
|
|
|
|
|
|
See also @.calc_freeze.
|
|
|
|
]]
|
|
|
|
return: int; [[The frozen state or 0 if the object is not frozen or on error.]]
|
|
|
|
}
|
|
|
|
calc_force @protected {
|
|
|
|
[[Forces a Size/Geometry calculation.
|
|
|
|
|
|
|
|
Forces the object to recalculate its layout regardless of
|
|
|
|
freeze/thaw. This API should be used carefully.
|
|
|
|
|
|
|
|
See also @.calc_freeze and @.calc_thaw.
|
|
|
|
]]
|
|
|
|
}
|
|
|
|
}
|
2017-12-06 17:24:08 -08:00
|
|
|
events {
|
efl: Add missing event types
Summary:
All events must have a type now, otherwise bindings don't know how to handle
the event_info field.
Most of the missing event types were actually "void" (no event_info present).
Some struct definitions had to be moved to eo instead of h files, so they
are available to bindings. Some have not, and are marked with FIXME.
Some namespaces have been fixed (like Efl_Event_Cb -> Efl.Event_Cb).
In general, there are hundreds of changed files, but mostly to add a type which
was not present before, so there's no harm done.
Also, A lot of FIXMEs have been added which should be, like, fixed.
For example, some events can send different types of event_info, which is
very inconvenient (and error prone).
Test Plan: make with c# bindings works, make check and make examples work too.
Reviewers: cedric, q66, lauromoura
Subscribers: zmike
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D6169
2018-05-11 08:20:40 -07:00
|
|
|
recalc: void; [[The layout was recalculated.]]
|
2019-03-04 10:42:04 -08:00
|
|
|
circular,dependency: const(array<string>); [[A circular dependency between parts of the
|
2017-12-06 17:24:08 -08:00
|
|
|
object was found.]]
|
|
|
|
}
|
2017-08-01 02:15:34 -07:00
|
|
|
}
|