aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Andreoli <dave@gurumeditation.it>2018-07-22 08:04:09 +0200
committerDave Andreoli <dave@gurumeditation.it>2018-07-22 08:04:09 +0200
commit48d9c26945e918ef5c2f45b8971ae6b1d262dba4 (patch)
tree136343c63e6ec3aff59aba8ac3094bc2ad00988a
parentNew 1.21 API: elm.Entry.prediction_hint_hash_set/del (diff)
downloadpython-efl-48d9c26945e918ef5c2f45b8971ae6b1d262dba4.tar.gz
New 1.21 API: edje.Object.part_text_prediction_hint_hash_set/del
-rw-r--r--efl/edje/efl.edje_object.pxi45
-rw-r--r--include/efl.edje.pxd2
2 files changed, 47 insertions, 0 deletions
diff --git a/efl/edje/efl.edje_object.pxi b/efl/edje/efl.edje_object.pxi
index 29354ce..4c98986 100644
--- a/efl/edje/efl.edje_object.pxi
+++ b/efl/edje/efl.edje_object.pxi
@@ -786,6 +786,51 @@ cdef class Edje(Object):
<const char *>part if part is not None else NULL,
<const char *>hint if hint is not None else NULL)
+ def part_text_prediction_hint_hash_set(self, part, key, value):
+ """Sets the prediction hint data at the specified key
+
+ :param part: the part name
+ :type part: str
+
+ :param key: the key of the prediction hint
+ :type key: str
+
+ :param value: the data to replace
+ :type value: str
+
+ :return bool: `True` on success, `False` otherwise
+
+ .. versionadded:: 1.21
+
+ """
+ if isinstance(part, unicode): part = PyUnicode_AsUTF8String(part)
+ if isinstance(key, unicode): key = PyUnicode_AsUTF8String(key)
+ if isinstance(value, unicode): value = PyUnicode_AsUTF8String(value)
+ edje_object_part_text_prediction_hint_hash_set(self.obj,
+ <const char *>part if part is not None else NULL,
+ <const char *>key if key is not None else NULL,
+ <const char *>value if value is not None else NULL)
+
+ def part_text_prediction_hint_hash_del(self, part, key):
+ """Removes the prediction hint data identified by a key
+
+ :param part: the part name
+ :type part: str
+
+ :param key: the key of the prediction hint
+ :type key: str
+
+ :return bool: `True` on success, `False` otherwise
+
+ .. versionadded:: 1.21
+
+ """
+ if isinstance(part, unicode): part = PyUnicode_AsUTF8String(part)
+ if isinstance(key, unicode): key = PyUnicode_AsUTF8String(key)
+ edje_object_part_text_prediction_hint_hash_del(self.obj,
+ <const char *>part if part is not None else NULL,
+ <const char *>key if key is not None else NULL)
+
def part_swallow(self, part, Object obj):
"""Swallows an object into the edje
diff --git a/include/efl.edje.pxd b/include/efl.edje.pxd
index 14862c8..d99e879 100644
--- a/include/efl.edje.pxd
+++ b/include/efl.edje.pxd
@@ -256,6 +256,8 @@ cdef extern from "Edje.h":
Edje_Input_Hints edje_object_part_text_input_hint_get(Evas_Object *obj, char *part)
void edje_object_part_text_prediction_hint_set(Evas_Object *obj, char *part, const char *prediction_hint)
+ Eina_Bool edje_object_part_text_prediction_hint_hash_set(Evas_Object *obj, const char *part, const char *key, const char *value)
+ Eina_Bool edje_object_part_text_prediction_hint_hash_del(Evas_Object *obj, const char *part, const char *key)
void edje_object_part_swallow(Evas_Object *obj, char *part, Evas_Object *obj_swallow)
void edje_object_part_unswallow(Evas_Object *obj, Evas_Object *obj_swallow)