elm_legacy_eolian_files = \
lib/elementary/efl_ui_animation_view.eo \
lib/elementary/efl_ui_clock_legacy.eo \
- lib/elementary/elm_label.eo \
lib/elementary/elm_list.eo \
lib/elementary/elm_map.eo \
lib/elementary/elm_map_pan.eo \
lib/elementary/elm_interface_fileselector_eo.c \
lib/elementary/elm_inwin_eo.c \
lib/elementary/elm_inwin_eo.legacy.c \
+lib/elementary/elm_label_eo.c \
+lib/elementary/elm_label_eo.legacy.c \
$(NULL)
elm_legacy_eo_headers = \
lib/elementary/elm_interface_fileselector_eo.legacy.h \
lib/elementary/elm_inwin_eo.h \
lib/elementary/elm_inwin_eo.legacy.h \
+lib/elementary/elm_label_eo.h \
+lib/elementary/elm_label_eo.legacy.h \
$(NULL)
ELM_LAYOUT_SIZING_EVAL_OPS(elm_label), \
EFL_CANVAS_GROUP_ADD_OPS(elm_label)
-#include "elm_label.eo.c"
+#include "elm_label_eo.c"
+++ /dev/null
-import elm_general;
-
-enum Elm.Label.Slide_Mode
-{
- [[Slide mode of a label widget]]
- none = 0, [[No slide effect.]]
- auto, [[Slide only if the label area is bigger than the text width length.]]
- always [[Slide always.]]
-}
-
-class Elm.Label extends Efl.Ui.Layout_Base implements Efl.Ui.Legacy
-{
- [[Elementary label class]]
- legacy_prefix: elm_label;
- eo_prefix: elm_obj_label;
- event_prefix: elm_label;
- methods {
- @property wrap_width {
- [[Control wrap width of the label
-
- This function sets the maximum width size hint of the label.
-
- Warning: This is only relevant if the label is inside a container.]]
- set {
- }
- get {
- }
- values {
- w: int; [[The wrap width in pixels at a minimum where words need to wrap]]
- }
- }
- @property slide_speed {
- [[Control the slide speed of the label
-
- Note: If you set the duration of the slide using @.slide_duration.set
- you cannot get the correct speed using this function until the label
- is actually rendered and resized.
-
- See @.slide_duration.set]]
- set {
- }
- get {
- }
- values {
- speed: double; [[The speed of the slide animation in px per seconds]]
- }
- }
- @property slide_mode {
- [[Control the slide mode of the label widget.
-
- By default, slide mode is none. Possible values for $mode are:
- @Elm.Label.Slide_Mode.none - no slide effect
- @Elm.Label.Slide_Mode.auto - slide only if the label area is bigger than
- the text width length
- @Elm.Label.Slide_Mode.always - slide always
-
- Warning: @Elm.Label.Slide_Mode.auto, @Elm.Label.Slide_Mode.always only work
- with the themes "slide_short", "slide_long" and "slide_bounce".
- Warning: @Elm.Label.Slide_Mode.auto, @Elm.Label.Slide_Mode.always don't work
- if the line wrap(elm_label_line_wrap_set()) or
- ellipsis(elm_label_ellipsis_set()) is set.
-
- @since 1.8]]
- set {
- }
- get {
- }
- values {
- mode: Elm.Label.Slide_Mode; [[The slide mode]]
- }
- }
- @property slide_duration {
- [[Control the slide duration of the label
-
- Note: If you set the speed of the slide using @.slide_speed.set
- you cannot get the correct duration using this function until the label
- is actually rendered and resized.]]
- set {
- }
- get {
- }
- values {
- duration: double; [[The duration in seconds in moving text from slide begin position to slide end position]]
- }
- }
- @property line_wrap {
- [[Control the wrapping behavior of the label
-
- By default no wrapping is done. Possible values for $wrap are:
- $ELM_WRAP_NONE - No wrapping
- $ELM_WRAP_CHAR - wrap between characters
- $ELM_WRAP_WORD - wrap between words
- $ELM_WRAP_MIXED - Word wrap, and if that fails, char wrap]]
- set {
- }
- get {
- }
- values {
- wrap: Elm.Wrap.Type; [[To wrap text or not]]
- }
- }
- @property ellipsis {
- [[Control the ellipsis behavior of the label
-
- If set to true and the text doesn't fit in the label an ellipsis("...")
- will be shown at the end of the widget.
-
- Warning This doesn't work with slide(elm_label_slide_set()) or if the
- chosen wrap method was $ELM_WRAP_WORD.]]
- set {
- }
- get {
- }
- values {
- ellipsis: bool; [[To ellipsis text or not]]
- }
- }
- slide_go {
- [[Start slide effect.
-
- See @.slide_mode.set.]]
- }
- /* TIZEN_ONLY(20170526): Add elm_label_text_style_user_push, pop, peek APIs for internal usages */
- text_style_user_push {
- [[\@internal
- ]]
- params {
- @in style: string; [[The style user to push.]]
- }
- }
- text_style_user_pop {
- [[\@internal
- ]]
- }
- text_style_user_peek @const {
- [[\@internal
- ]]
- return: string;
- }
- /* END */
- }
- implements {
- class.constructor;
- Efl.Object.constructor;
- Efl.Ui.Widget.theme_apply;
- Efl.Part.part_get;
- //TIZEN_ONLY(20180607): Restore legacy focus
- Efl.Ui.Widget.focus_next_manager_is;
- Efl.Ui.Widget.focus_direction_manager_is;
- //
- }
- events {
- slide,end: void; [[Called when slide stopped]]
- }
-}
--- /dev/null
+EWAPI const Efl_Event_Description _ELM_LABEL_EVENT_SLIDE_END =
+ EFL_EVENT_DESCRIPTION("slide,end");
+
+void _elm_label_wrap_width_set(Eo *obj, Elm_Label_Data *pd, int w);
+
+
+static Eina_Error
+__eolian_elm_label_wrap_width_set_reflect(Eo *obj, Eina_Value val)
+{
+ Eina_Error r = 0; int cval;
+ if (!eina_value_int_convert(&val, &cval))
+ {
+ r = EINA_ERROR_VALUE_FAILED;
+ goto end;
+ }
+ elm_obj_label_wrap_width_set(obj, cval);
+ end:
+ eina_value_flush(&val);
+ return r;
+}
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_label_wrap_width_set, EFL_FUNC_CALL(w), int w);
+
+int _elm_label_wrap_width_get(const Eo *obj, Elm_Label_Data *pd);
+
+
+static Eina_Value
+__eolian_elm_label_wrap_width_get_reflect(Eo *obj)
+{
+ int val = elm_obj_label_wrap_width_get(obj);
+ return eina_value_int_init(val);
+}
+
+EOAPI EFL_FUNC_BODY_CONST(elm_obj_label_wrap_width_get, int, 0);
+
+void _elm_label_slide_speed_set(Eo *obj, Elm_Label_Data *pd, double speed);
+
+
+static Eina_Error
+__eolian_elm_label_slide_speed_set_reflect(Eo *obj, Eina_Value val)
+{
+ Eina_Error r = 0; double cval;
+ if (!eina_value_double_convert(&val, &cval))
+ {
+ r = EINA_ERROR_VALUE_FAILED;
+ goto end;
+ }
+ elm_obj_label_slide_speed_set(obj, cval);
+ end:
+ eina_value_flush(&val);
+ return r;
+}
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_label_slide_speed_set, EFL_FUNC_CALL(speed), double speed);
+
+double _elm_label_slide_speed_get(const Eo *obj, Elm_Label_Data *pd);
+
+
+static Eina_Value
+__eolian_elm_label_slide_speed_get_reflect(Eo *obj)
+{
+ double val = elm_obj_label_slide_speed_get(obj);
+ return eina_value_double_init(val);
+}
+
+EOAPI EFL_FUNC_BODY_CONST(elm_obj_label_slide_speed_get, double, 0);
+
+void _elm_label_slide_mode_set(Eo *obj, Elm_Label_Data *pd, Elm_Label_Slide_Mode mode);
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_label_slide_mode_set, EFL_FUNC_CALL(mode), Elm_Label_Slide_Mode mode);
+
+Elm_Label_Slide_Mode _elm_label_slide_mode_get(const Eo *obj, Elm_Label_Data *pd);
+
+EOAPI EFL_FUNC_BODY_CONST(elm_obj_label_slide_mode_get, Elm_Label_Slide_Mode, 0);
+
+void _elm_label_slide_duration_set(Eo *obj, Elm_Label_Data *pd, double duration);
+
+
+static Eina_Error
+__eolian_elm_label_slide_duration_set_reflect(Eo *obj, Eina_Value val)
+{
+ Eina_Error r = 0; double cval;
+ if (!eina_value_double_convert(&val, &cval))
+ {
+ r = EINA_ERROR_VALUE_FAILED;
+ goto end;
+ }
+ elm_obj_label_slide_duration_set(obj, cval);
+ end:
+ eina_value_flush(&val);
+ return r;
+}
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_label_slide_duration_set, EFL_FUNC_CALL(duration), double duration);
+
+double _elm_label_slide_duration_get(const Eo *obj, Elm_Label_Data *pd);
+
+
+static Eina_Value
+__eolian_elm_label_slide_duration_get_reflect(Eo *obj)
+{
+ double val = elm_obj_label_slide_duration_get(obj);
+ return eina_value_double_init(val);
+}
+
+EOAPI EFL_FUNC_BODY_CONST(elm_obj_label_slide_duration_get, double, 0);
+
+void _elm_label_line_wrap_set(Eo *obj, Elm_Label_Data *pd, Elm_Wrap_Type wrap);
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_label_line_wrap_set, EFL_FUNC_CALL(wrap), Elm_Wrap_Type wrap);
+
+Elm_Wrap_Type _elm_label_line_wrap_get(const Eo *obj, Elm_Label_Data *pd);
+
+EOAPI EFL_FUNC_BODY_CONST(elm_obj_label_line_wrap_get, Elm_Wrap_Type, 0);
+
+void _elm_label_ellipsis_set(Eo *obj, Elm_Label_Data *pd, Eina_Bool ellipsis);
+
+
+static Eina_Error
+__eolian_elm_label_ellipsis_set_reflect(Eo *obj, Eina_Value val)
+{
+ Eina_Error r = 0; Eina_Bool cval;
+ if (!eina_value_bool_convert(&val, &cval))
+ {
+ r = EINA_ERROR_VALUE_FAILED;
+ goto end;
+ }
+ elm_obj_label_ellipsis_set(obj, cval);
+ end:
+ eina_value_flush(&val);
+ return r;
+}
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_label_ellipsis_set, EFL_FUNC_CALL(ellipsis), Eina_Bool ellipsis);
+
+Eina_Bool _elm_label_ellipsis_get(const Eo *obj, Elm_Label_Data *pd);
+
+
+static Eina_Value
+__eolian_elm_label_ellipsis_get_reflect(Eo *obj)
+{
+ Eina_Bool val = elm_obj_label_ellipsis_get(obj);
+ return eina_value_bool_init(val);
+}
+
+EOAPI EFL_FUNC_BODY_CONST(elm_obj_label_ellipsis_get, Eina_Bool, 0);
+
+void _elm_label_slide_go(Eo *obj, Elm_Label_Data *pd);
+
+EOAPI EFL_VOID_FUNC_BODY(elm_obj_label_slide_go);
+
+Efl_Object *_elm_label_efl_object_constructor(Eo *obj, Elm_Label_Data *pd);
+
+
+Eina_Error _elm_label_efl_ui_widget_theme_apply(Eo *obj, Elm_Label_Data *pd);
+
+
+Efl_Object *_elm_label_efl_part_part_get(const Eo *obj, Elm_Label_Data *pd, const char *name);
+
+
+static Eina_Bool
+_elm_label_class_initializer(Efl_Class *klass)
+{
+ const Efl_Object_Ops *opsp = NULL;
+
+ const Efl_Object_Property_Reflection_Ops *ropsp = NULL;
+
+#ifndef ELM_LABEL_EXTRA_OPS
+#define ELM_LABEL_EXTRA_OPS
+#endif
+
+ EFL_OPS_DEFINE(ops,
+ EFL_OBJECT_OP_FUNC(elm_obj_label_wrap_width_set, _elm_label_wrap_width_set),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_wrap_width_get, _elm_label_wrap_width_get),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_speed_set, _elm_label_slide_speed_set),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_speed_get, _elm_label_slide_speed_get),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_mode_set, _elm_label_slide_mode_set),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_mode_get, _elm_label_slide_mode_get),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_duration_set, _elm_label_slide_duration_set),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_duration_get, _elm_label_slide_duration_get),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_line_wrap_set, _elm_label_line_wrap_set),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_line_wrap_get, _elm_label_line_wrap_get),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_ellipsis_set, _elm_label_ellipsis_set),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_ellipsis_get, _elm_label_ellipsis_get),
+ EFL_OBJECT_OP_FUNC(elm_obj_label_slide_go, _elm_label_slide_go),
+ EFL_OBJECT_OP_FUNC(efl_constructor, _elm_label_efl_object_constructor),
+ EFL_OBJECT_OP_FUNC(efl_ui_widget_theme_apply, _elm_label_efl_ui_widget_theme_apply),
+ EFL_OBJECT_OP_FUNC(efl_part_get, _elm_label_efl_part_part_get),
+ ELM_LABEL_EXTRA_OPS
+ );
+ opsp = &ops;
+
+ static const Efl_Object_Property_Reflection refl_table[] = {
+ {"wrap_width", __eolian_elm_label_wrap_width_set_reflect, __eolian_elm_label_wrap_width_get_reflect},
+ {"slide_speed", __eolian_elm_label_slide_speed_set_reflect, __eolian_elm_label_slide_speed_get_reflect},
+ {"slide_duration", __eolian_elm_label_slide_duration_set_reflect, __eolian_elm_label_slide_duration_get_reflect},
+ {"ellipsis", __eolian_elm_label_ellipsis_set_reflect, __eolian_elm_label_ellipsis_get_reflect},
+ };
+ static const Efl_Object_Property_Reflection_Ops rops = {
+ refl_table, EINA_C_ARRAY_LENGTH(refl_table)
+ };
+ ropsp = &rops;
+
+ return efl_class_functions_set(klass, opsp, ropsp);
+}
+
+static const Efl_Class_Description _elm_label_class_desc = {
+ EO_VERSION,
+ "Elm.Label",
+ EFL_CLASS_TYPE_REGULAR,
+ sizeof(Elm_Label_Data),
+ _elm_label_class_initializer,
+ _elm_label_class_constructor,
+ NULL
+};
+
+EFL_DEFINE_CLASS(elm_label_class_get, &_elm_label_class_desc, EFL_UI_LAYOUT_BASE_CLASS, EFL_UI_LEGACY_INTERFACE, NULL);
+
+#include "elm_label_eo.legacy.c"
--- /dev/null
+#ifndef _ELM_LABEL_EO_H_
+#define _ELM_LABEL_EO_H_
+
+#ifndef _ELM_LABEL_EO_CLASS_TYPE
+#define _ELM_LABEL_EO_CLASS_TYPE
+
+typedef Eo Elm_Label;
+
+#endif
+
+#ifndef _ELM_LABEL_EO_TYPES
+#define _ELM_LABEL_EO_TYPES
+
+/** Slide mode of a label widget
+ *
+ * @ingroup Elm_Label
+ */
+typedef enum
+{
+ ELM_LABEL_SLIDE_MODE_NONE = 0, /**< No slide effect. */
+ ELM_LABEL_SLIDE_MODE_AUTO, /**< Slide only if the label area is bigger than
+ * the text width length. */
+ ELM_LABEL_SLIDE_MODE_ALWAYS /**< Slide always. */
+} Elm_Label_Slide_Mode;
+
+
+#endif
+/** Elementary label class
+ *
+ * @ingroup Elm_Label
+ */
+#define ELM_LABEL_CLASS elm_label_class_get()
+
+EWAPI const Efl_Class *elm_label_class_get(void);
+
+/**
+ * @brief Control wrap width of the label
+ *
+ * This function sets the maximum width size hint of the label.
+ *
+ * @warning This is only relevant if the label is inside a container.
+ *
+ * @param[in] obj The object.
+ * @param[in] w The wrap width in pixels at a minimum where words need to wrap
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_wrap_width_set(Eo *obj, int w);
+
+/**
+ * @brief Control wrap width of the label
+ *
+ * This function sets the maximum width size hint of the label.
+ *
+ * @warning This is only relevant if the label is inside a container.
+ *
+ * @param[in] obj The object.
+ *
+ * @return The wrap width in pixels at a minimum where words need to wrap
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI int elm_obj_label_wrap_width_get(const Eo *obj);
+
+/**
+ * @brief Control the slide speed of the label
+ *
+ * @note If you set the duration of the slide using
+ * @ref elm_obj_label_slide_duration_set you cannot get the correct speed using
+ * this function until the label is actually rendered and resized.
+ *
+ * See @ref elm_obj_label_slide_duration_set
+ *
+ * @param[in] obj The object.
+ * @param[in] speed The speed of the slide animation in px per seconds
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_slide_speed_set(Eo *obj, double speed);
+
+/**
+ * @brief Control the slide speed of the label
+ *
+ * @note If you set the duration of the slide using
+ * @ref elm_obj_label_slide_duration_set you cannot get the correct speed using
+ * this function until the label is actually rendered and resized.
+ *
+ * See @ref elm_obj_label_slide_duration_set
+ *
+ * @param[in] obj The object.
+ *
+ * @return The speed of the slide animation in px per seconds
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI double elm_obj_label_slide_speed_get(const Eo *obj);
+
+/**
+ * @brief Control the slide mode of the label widget.
+ *
+ * By default, slide mode is none. Possible values for @c mode are:
+ * @ref ELM_LABEL_SLIDE_MODE_NONE - no slide effect
+ * @ref ELM_LABEL_SLIDE_MODE_AUTO - slide only if the label area is bigger than
+ * the text width length @ref ELM_LABEL_SLIDE_MODE_ALWAYS - slide always
+ *
+ * @warning @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * only work with the themes "slide_short", "slide_long" and "slide_bounce".
+ * Warning: @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * don't work if the line wrap(elm_label_line_wrap_set()) or
+ * ellipsis(elm_label_ellipsis_set()) is set.
+ *
+ * @param[in] obj The object.
+ * @param[in] mode The slide mode
+ *
+ * @since 1.8
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_slide_mode_set(Eo *obj, Elm_Label_Slide_Mode mode);
+
+/**
+ * @brief Control the slide mode of the label widget.
+ *
+ * By default, slide mode is none. Possible values for @c mode are:
+ * @ref ELM_LABEL_SLIDE_MODE_NONE - no slide effect
+ * @ref ELM_LABEL_SLIDE_MODE_AUTO - slide only if the label area is bigger than
+ * the text width length @ref ELM_LABEL_SLIDE_MODE_ALWAYS - slide always
+ *
+ * @warning @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * only work with the themes "slide_short", "slide_long" and "slide_bounce".
+ * Warning: @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * don't work if the line wrap(elm_label_line_wrap_set()) or
+ * ellipsis(elm_label_ellipsis_set()) is set.
+ *
+ * @param[in] obj The object.
+ *
+ * @return The slide mode
+ *
+ * @since 1.8
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI Elm_Label_Slide_Mode elm_obj_label_slide_mode_get(const Eo *obj);
+
+/**
+ * @brief Control the slide duration of the label
+ *
+ * @note If you set the speed of the slide using
+ * @ref elm_obj_label_slide_speed_set you cannot get the correct duration using
+ * this function until the label is actually rendered and resized.
+ *
+ * @param[in] obj The object.
+ * @param[in] duration The duration in seconds in moving text from slide begin
+ * position to slide end position
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_slide_duration_set(Eo *obj, double duration);
+
+/**
+ * @brief Control the slide duration of the label
+ *
+ * @note If you set the speed of the slide using
+ * @ref elm_obj_label_slide_speed_set you cannot get the correct duration using
+ * this function until the label is actually rendered and resized.
+ *
+ * @param[in] obj The object.
+ *
+ * @return The duration in seconds in moving text from slide begin position to
+ * slide end position
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI double elm_obj_label_slide_duration_get(const Eo *obj);
+
+/**
+ * @brief Control the wrapping behavior of the label
+ *
+ * By default no wrapping is done. Possible values for @c wrap are:
+ * @c ELM_WRAP_NONE - No wrapping @c ELM_WRAP_CHAR - wrap between characters
+ * @c ELM_WRAP_WORD - wrap between words @c ELM_WRAP_MIXED - Word wrap, and if
+ * that fails, char wrap
+ *
+ * @param[in] obj The object.
+ * @param[in] wrap To wrap text or not
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_line_wrap_set(Eo *obj, Elm_Wrap_Type wrap);
+
+/**
+ * @brief Control the wrapping behavior of the label
+ *
+ * By default no wrapping is done. Possible values for @c wrap are:
+ * @c ELM_WRAP_NONE - No wrapping @c ELM_WRAP_CHAR - wrap between characters
+ * @c ELM_WRAP_WORD - wrap between words @c ELM_WRAP_MIXED - Word wrap, and if
+ * that fails, char wrap
+ *
+ * @param[in] obj The object.
+ *
+ * @return To wrap text or not
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI Elm_Wrap_Type elm_obj_label_line_wrap_get(const Eo *obj);
+
+/**
+ * @brief Control the ellipsis behavior of the label
+ *
+ * If set to true and the text doesn't fit in the label an ellipsis("...") will
+ * be shown at the end of the widget.
+ *
+ * Warning This doesn't work with slide(elm_label_slide_set()) or if the chosen
+ * wrap method was @c ELM_WRAP_WORD.
+ *
+ * @param[in] obj The object.
+ * @param[in] ellipsis To ellipsis text or not
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_ellipsis_set(Eo *obj, Eina_Bool ellipsis);
+
+/**
+ * @brief Control the ellipsis behavior of the label
+ *
+ * If set to true and the text doesn't fit in the label an ellipsis("...") will
+ * be shown at the end of the widget.
+ *
+ * Warning This doesn't work with slide(elm_label_slide_set()) or if the chosen
+ * wrap method was @c ELM_WRAP_WORD.
+ *
+ * @param[in] obj The object.
+ *
+ * @return To ellipsis text or not
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI Eina_Bool elm_obj_label_ellipsis_get(const Eo *obj);
+
+/**
+ * @brief Start slide effect.
+ *
+ * See @ref elm_obj_label_slide_mode_set.
+ * @param[in] obj The object.
+ *
+ * @ingroup Elm_Label
+ */
+EOAPI void elm_obj_label_slide_go(Eo *obj);
+
+EWAPI extern const Efl_Event_Description _ELM_LABEL_EVENT_SLIDE_END;
+
+/** Called when slide stopped
+ *
+ * @ingroup Elm_Label
+ */
+#define ELM_LABEL_EVENT_SLIDE_END (&(_ELM_LABEL_EVENT_SLIDE_END))
+
+#endif
--- /dev/null
+
+EAPI void
+elm_label_wrap_width_set(Elm_Label *obj, int w)
+{
+ elm_obj_label_wrap_width_set(obj, w);
+}
+
+EAPI int
+elm_label_wrap_width_get(const Elm_Label *obj)
+{
+ return elm_obj_label_wrap_width_get(obj);
+}
+
+EAPI void
+elm_label_slide_speed_set(Elm_Label *obj, double speed)
+{
+ elm_obj_label_slide_speed_set(obj, speed);
+}
+
+EAPI double
+elm_label_slide_speed_get(const Elm_Label *obj)
+{
+ return elm_obj_label_slide_speed_get(obj);
+}
+
+EAPI void
+elm_label_slide_mode_set(Elm_Label *obj, Elm_Label_Slide_Mode mode)
+{
+ elm_obj_label_slide_mode_set(obj, mode);
+}
+
+EAPI Elm_Label_Slide_Mode
+elm_label_slide_mode_get(const Elm_Label *obj)
+{
+ return elm_obj_label_slide_mode_get(obj);
+}
+
+EAPI void
+elm_label_slide_duration_set(Elm_Label *obj, double duration)
+{
+ elm_obj_label_slide_duration_set(obj, duration);
+}
+
+EAPI double
+elm_label_slide_duration_get(const Elm_Label *obj)
+{
+ return elm_obj_label_slide_duration_get(obj);
+}
+
+EAPI void
+elm_label_line_wrap_set(Elm_Label *obj, Elm_Wrap_Type wrap)
+{
+ elm_obj_label_line_wrap_set(obj, wrap);
+}
+
+EAPI Elm_Wrap_Type
+elm_label_line_wrap_get(const Elm_Label *obj)
+{
+ return elm_obj_label_line_wrap_get(obj);
+}
+
+EAPI void
+elm_label_ellipsis_set(Elm_Label *obj, Eina_Bool ellipsis)
+{
+ elm_obj_label_ellipsis_set(obj, ellipsis);
+}
+
+EAPI Eina_Bool
+elm_label_ellipsis_get(const Elm_Label *obj)
+{
+ return elm_obj_label_ellipsis_get(obj);
+}
+
+EAPI void
+elm_label_slide_go(Elm_Label *obj)
+{
+ elm_obj_label_slide_go(obj);
+}
--- /dev/null
+#ifndef _ELM_LABEL_EO_LEGACY_H_
+#define _ELM_LABEL_EO_LEGACY_H_
+
+#ifndef _ELM_LABEL_EO_CLASS_TYPE
+#define _ELM_LABEL_EO_CLASS_TYPE
+
+typedef Eo Elm_Label;
+
+#endif
+
+#ifndef _ELM_LABEL_EO_TYPES
+#define _ELM_LABEL_EO_TYPES
+
+/** Slide mode of a label widget
+ *
+ * @ingroup Elm_Label
+ */
+typedef enum
+{
+ ELM_LABEL_SLIDE_MODE_NONE = 0, /**< No slide effect. */
+ ELM_LABEL_SLIDE_MODE_AUTO, /**< Slide only if the label area is bigger than
+ * the text width length. */
+ ELM_LABEL_SLIDE_MODE_ALWAYS /**< Slide always. */
+} Elm_Label_Slide_Mode;
+
+
+#endif
+
+/**
+ * @brief Control wrap width of the label
+ *
+ * This function sets the maximum width size hint of the label.
+ *
+ * @warning This is only relevant if the label is inside a container.
+ *
+ * @param[in] obj The object.
+ * @param[in] w The wrap width in pixels at a minimum where words need to wrap
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_wrap_width_set(Elm_Label *obj, int w);
+
+/**
+ * @brief Control wrap width of the label
+ *
+ * This function sets the maximum width size hint of the label.
+ *
+ * @warning This is only relevant if the label is inside a container.
+ *
+ * @param[in] obj The object.
+ *
+ * @return The wrap width in pixels at a minimum where words need to wrap
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI int elm_label_wrap_width_get(const Elm_Label *obj);
+
+/**
+ * @brief Control the slide speed of the label
+ *
+ * @note If you set the duration of the slide using
+ * @ref elm_label_slide_duration_set you cannot get the correct speed using
+ * this function until the label is actually rendered and resized.
+ *
+ * See @ref elm_label_slide_duration_set
+ *
+ * @param[in] obj The object.
+ * @param[in] speed The speed of the slide animation in px per seconds
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_slide_speed_set(Elm_Label *obj, double speed);
+
+/**
+ * @brief Control the slide speed of the label
+ *
+ * @note If you set the duration of the slide using
+ * @ref elm_label_slide_duration_set you cannot get the correct speed using
+ * this function until the label is actually rendered and resized.
+ *
+ * See @ref elm_label_slide_duration_set
+ *
+ * @param[in] obj The object.
+ *
+ * @return The speed of the slide animation in px per seconds
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI double elm_label_slide_speed_get(const Elm_Label *obj);
+
+/**
+ * @brief Control the slide mode of the label widget.
+ *
+ * By default, slide mode is none. Possible values for @c mode are:
+ * @ref ELM_LABEL_SLIDE_MODE_NONE - no slide effect
+ * @ref ELM_LABEL_SLIDE_MODE_AUTO - slide only if the label area is bigger than
+ * the text width length @ref ELM_LABEL_SLIDE_MODE_ALWAYS - slide always
+ *
+ * @warning @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * only work with the themes "slide_short", "slide_long" and "slide_bounce".
+ * Warning: @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * don't work if the line wrap(elm_label_line_wrap_set()) or
+ * ellipsis(elm_label_ellipsis_set()) is set.
+ *
+ * @param[in] obj The object.
+ * @param[in] mode The slide mode
+ *
+ * @since 1.8
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_slide_mode_set(Elm_Label *obj, Elm_Label_Slide_Mode mode);
+
+/**
+ * @brief Control the slide mode of the label widget.
+ *
+ * By default, slide mode is none. Possible values for @c mode are:
+ * @ref ELM_LABEL_SLIDE_MODE_NONE - no slide effect
+ * @ref ELM_LABEL_SLIDE_MODE_AUTO - slide only if the label area is bigger than
+ * the text width length @ref ELM_LABEL_SLIDE_MODE_ALWAYS - slide always
+ *
+ * @warning @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * only work with the themes "slide_short", "slide_long" and "slide_bounce".
+ * Warning: @ref ELM_LABEL_SLIDE_MODE_AUTO, @ref ELM_LABEL_SLIDE_MODE_ALWAYS
+ * don't work if the line wrap(elm_label_line_wrap_set()) or
+ * ellipsis(elm_label_ellipsis_set()) is set.
+ *
+ * @param[in] obj The object.
+ *
+ * @return The slide mode
+ *
+ * @since 1.8
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI Elm_Label_Slide_Mode elm_label_slide_mode_get(const Elm_Label *obj);
+
+/**
+ * @brief Control the slide duration of the label
+ *
+ * @note If you set the speed of the slide using @ref elm_label_slide_speed_set
+ * you cannot get the correct duration using this function until the label is
+ * actually rendered and resized.
+ *
+ * @param[in] obj The object.
+ * @param[in] duration The duration in seconds in moving text from slide begin
+ * position to slide end position
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_slide_duration_set(Elm_Label *obj, double duration);
+
+/**
+ * @brief Control the slide duration of the label
+ *
+ * @note If you set the speed of the slide using @ref elm_label_slide_speed_set
+ * you cannot get the correct duration using this function until the label is
+ * actually rendered and resized.
+ *
+ * @param[in] obj The object.
+ *
+ * @return The duration in seconds in moving text from slide begin position to
+ * slide end position
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI double elm_label_slide_duration_get(const Elm_Label *obj);
+
+/**
+ * @brief Control the wrapping behavior of the label
+ *
+ * By default no wrapping is done. Possible values for @c wrap are:
+ * @c ELM_WRAP_NONE - No wrapping @c ELM_WRAP_CHAR - wrap between characters
+ * @c ELM_WRAP_WORD - wrap between words @c ELM_WRAP_MIXED - Word wrap, and if
+ * that fails, char wrap
+ *
+ * @param[in] obj The object.
+ * @param[in] wrap To wrap text or not
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_line_wrap_set(Elm_Label *obj, Elm_Wrap_Type wrap);
+
+/**
+ * @brief Control the wrapping behavior of the label
+ *
+ * By default no wrapping is done. Possible values for @c wrap are:
+ * @c ELM_WRAP_NONE - No wrapping @c ELM_WRAP_CHAR - wrap between characters
+ * @c ELM_WRAP_WORD - wrap between words @c ELM_WRAP_MIXED - Word wrap, and if
+ * that fails, char wrap
+ *
+ * @param[in] obj The object.
+ *
+ * @return To wrap text or not
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI Elm_Wrap_Type elm_label_line_wrap_get(const Elm_Label *obj);
+
+/**
+ * @brief Control the ellipsis behavior of the label
+ *
+ * If set to true and the text doesn't fit in the label an ellipsis("...") will
+ * be shown at the end of the widget.
+ *
+ * Warning This doesn't work with slide(elm_label_slide_set()) or if the chosen
+ * wrap method was @c ELM_WRAP_WORD.
+ *
+ * @param[in] obj The object.
+ * @param[in] ellipsis To ellipsis text or not
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_ellipsis_set(Elm_Label *obj, Eina_Bool ellipsis);
+
+/**
+ * @brief Control the ellipsis behavior of the label
+ *
+ * If set to true and the text doesn't fit in the label an ellipsis("...") will
+ * be shown at the end of the widget.
+ *
+ * Warning This doesn't work with slide(elm_label_slide_set()) or if the chosen
+ * wrap method was @c ELM_WRAP_WORD.
+ *
+ * @param[in] obj The object.
+ *
+ * @return To ellipsis text or not
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI Eina_Bool elm_label_ellipsis_get(const Elm_Label *obj);
+
+/**
+ * @brief Start slide effect.
+ *
+ * See @ref elm_label_slide_mode_set.
+ * @param[in] obj The object.
+ *
+ * @ingroup Elm_Label_Group
+ */
+EAPI void elm_label_slide_go(Elm_Label *obj);
+
+#endif
*/
EAPI Evas_Object *elm_label_add(Evas_Object *parent);
-#include "elm_label.eo.legacy.h"
+#include "elm_label_eo.legacy.h"
#include "elm_priv.h"
#include "elm_entry_eo.h"
#include "elm_thumb.eo.h"
-#include "elm_label.eo.h"
+#include "elm_label_eo.h"
#include <assert.h>
#include <Eio.h>
-#include "elm_label.eo.h"
+#include "elm_label_eo.h"
/* DO NOT USE THIS HEADER UNLESS YOU ARE PREPARED FOR BREAKING OF YOUR
* CODE. THIS IS ELEMENTARY'S INTERNAL WIDGET API (for now) AND IS NOT
pub_legacy_eo_files = [
'efl_ui_clock_legacy.eo',
- 'elm_label.eo',
'elm_list.eo',
'elm_map.eo',
'elm_map_pan.eo',
'elm_interface_fileselector_eo.legacy.h',
'elm_inwin_eo.h',
'elm_inwin_eo.legacy.h',
+ 'elm_label_eo.h',
+ 'elm_label_eo.legacy.h',
]
elementary_header_src = [