summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_textblock_legacy.h
diff options
context:
space:
mode:
authorYoungbok Shin <youngb.shin@samsung.com>2018-08-20 07:21:53 -0400
committerMike Blumenkrantz <zmike@samsung.com>2018-08-20 10:29:32 -0400
commit517018e00897f61136418861563a49144a5fe39a (patch)
tree694c299402631380a10a7ad6ddbebfbb774e7e91 /src/lib/evas/canvas/evas_textblock_legacy.h
parent8da56ac873d5bb083b7cfe08aeefdaa2ad9a4b99 (diff)
evas textblock: add/apply cursor cluster APIs based on grapheme cluster
Summary: Add a feature for moving cursor over a grapheme cluster. It is applied to edje_entry.c and elm_entry.c for improving cursor handling just like other modern text editors. ex) gedit The patch on Evas needs to update libunibreak library. So, the patch will update libunibreak, too. @feature Test Plan: 1. Put "ഹലോ" in your entry. 2. Your cursor can reach at the end of text from the beginning only in 2 right key event with this feature. Reviewers: raster, cedric, jpeg, herdsman, zmike, devilhorns Reviewed By: herdsman, zmike Subscribers: #reviewers, #committers, zmike, bowonryu, woohyun Tags: #efl Differential Revision: https://phab.enlightenment.org/D5490
Diffstat (limited to '')
-rw-r--r--src/lib/evas/canvas/evas_textblock_legacy.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/lib/evas/canvas/evas_textblock_legacy.h b/src/lib/evas/canvas/evas_textblock_legacy.h
index 0d84075fa0..2c8ee05f57 100644
--- a/src/lib/evas/canvas/evas_textblock_legacy.h
+++ b/src/lib/evas/canvas/evas_textblock_legacy.h
@@ -605,6 +605,22 @@ EAPI Eina_Bool evas_textblock_cursor_char_prev(Evas_Textblock_Cursor *obj);
605EAPI Eina_Bool evas_textblock_cursor_char_next(Evas_Textblock_Cursor *obj); 605EAPI Eina_Bool evas_textblock_cursor_char_next(Evas_Textblock_Cursor *obj);
606 606
607/** 607/**
608 * @brief Advances the cursor one grapheme cluster backwards.
609 *
610 * @return @c true on success, @c false otherwise.
611 */
612EAPI Eina_Bool evas_textblock_cursor_cluster_prev(Evas_Textblock_Cursor *obj);
613
614/**
615 * @brief Advances the cursor one grapheme cluster forward.
616 *
617 * @return @c true on success, @c false otherwise.
618 *
619 * @ingroup Evas_Textblock_Cursor
620 */
621EAPI Eina_Bool evas_textblock_cursor_cluster_next(Evas_Textblock_Cursor *obj);
622
623/**
608 * @brief Advances to the start of the next text node 624 * @brief Advances to the start of the next text node
609 * 625 *
610 * @return @c true if managed to advance, @c false otherwise 626 * @return @c true if managed to advance, @c false otherwise
@@ -860,6 +876,16 @@ EAPI Evas_Textblock_Cursor *evas_object_textblock_cursor_new(const Evas_Object *
860EAPI Eina_Bool evas_textblock_cursor_char_coord_set(Evas_Textblock_Cursor *obj, Evas_Coord x, Evas_Coord y); 876EAPI Eina_Bool evas_textblock_cursor_char_coord_set(Evas_Textblock_Cursor *obj, Evas_Coord x, Evas_Coord y);
861 877
862/** 878/**
879 * @brief Sets the position of the cursor according to the X and Y coordinates and
880 * grapheme clusters of text.
881 *
882 * @param[in] y y coord to set by.
883 *
884 * @return @c true on success, @c false otherwise.
885 */
886EAPI Eina_Bool evas_textblock_cursor_cluster_coord_set(Evas_Textblock_Cursor *obj, Evas_Coord x, Evas_Coord y);
887
888/**
863 * Free the cursor and unassociate it from the object. 889 * Free the cursor and unassociate it from the object.
864 * @note do not use it to free unassociated cursors. 890 * @note do not use it to free unassociated cursors.
865 * 891 *