h: int; [[Integer to use as the maximum height hint.]]
}
}
+ @property hint_min {
+ [[Hints on the object's minimum size.
+
+ This is not a size enforcement in any way, it's just a hint
+ that should be used whenever appropriate. The object container
+ is in charge of fetching this property and placing the object
+ accordingly.
+
+ Value 0 will be treated as unset hint components, when queried
+ by managers.
+
+ Note: This property is meant to be set by applications and not by
+ EFL itself. Use this to request a specific size (treated as minimum
+ size).
+ ]]
+ values {
+ w: int; [[Integer to use as the maximum width hint.]]
+ h: int; [[Integer to use as the maximum height hint.]]
+ }
+ }
@property hint_request {
[[Hints for the object's optimum size.
queried by managers.
Note: This property is meant to be set by applications and not by
- EFL itself. Use this to request a specific size (treated as minimum
- size).
+ EFL itself. Very few containers actually implement support for
+ this requested size, see @.hint_min instead.
]]
values {
w: int; [[Integer to use as the preferred width hint.]]
Note: This property is internal and meant for widget developers to
define the absolute minimum size of the object. EFL itself sets
this size internally, so any change to it from an application
- might be ignored. Use @.hint_request instead.
+ might be ignored. Use @.hint_min instead.
]]
values {
w: int; [[Integer to use as the minimum width hint.]]
}
@property hint_combined_min {
[[Read-only minimum size combining both @.hint_restricted_min and
- @.hint_request size hints.
+ @.hint_min size hints.
@.hint_restricted_min is intended for mostly internal usage
- and widget developers, and @.hint_request is intended to be
+ and widget developers, and @.hint_min is intended to be
set from application side. @.hint_combined_min combines both values
by taking their repective maximum (in both width and height), and
is used internally to get an object's minimum size.
Efl.Gfx.Size.Hint.hint_combined_min.get;
Efl.Gfx.Size.Hint.hint_restricted_min.set;
Efl.Gfx.Size.Hint.hint_restricted_min.get;
+ Efl.Gfx.Size.Hint.hint_min.set;
+ Efl.Gfx.Size.Hint.hint_min.get;
Efl.Gfx.Size.Hint.hint_max.set;
Efl.Gfx.Size.Hint.hint_max.get;
Efl.Gfx.Size.Hint.hint_margin.set;
if (h) *h = 0;
return;
}
- if (w) *w = MAX(obj->size_hints->min.w, obj->size_hints->request.w);
- if (h) *h = MAX(obj->size_hints->min.h, obj->size_hints->request.h);
+ if (w) *w = MAX(obj->size_hints->min.w, obj->size_hints->user_min.w);
+ if (h) *h = MAX(obj->size_hints->min.h, obj->size_hints->user_min.h);
}
EOLIAN static void
}
EOLIAN static void
+_evas_object_efl_gfx_size_hint_hint_min_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj, Evas_Coord *w, Evas_Coord *h)
+{
+ if ((!obj->size_hints) || obj->delete_me)
+ {
+ if (w) *w = 0;
+ if (h) *h = 0;
+ return;
+ }
+ if (w) *w = obj->size_hints->user_min.w;
+ if (h) *h = obj->size_hints->user_min.h;
+}
+
+EOLIAN static void
+_evas_object_efl_gfx_size_hint_hint_min_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Evas_Coord w, Evas_Coord h)
+{
+ if (obj->delete_me)
+ return;
+ evas_object_async_block(obj);
+ _evas_object_size_hint_alloc(eo_obj, obj);
+ if ((obj->size_hints->user_min.w == w) && (obj->size_hints->user_min.h == h)) return;
+ obj->size_hints->user_min.w = w;
+ obj->size_hints->user_min.h = h;
+
+ evas_object_inform_call_changed_size_hints(eo_obj);
+}
+
+EOLIAN static void
_evas_object_efl_gfx_size_hint_hint_aspect_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj, Efl_Gfx_Size_Hint_Aspect *aspect, Evas_Coord *w, Evas_Coord *h)
{
if ((!obj->size_hints) || obj->delete_me)