[EGIT] [core/efl] master 01/01: evas_textblock: cursor function null check at start

2019-11-22 Thread ali
lauromoura pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=aeee3497afaff7ca7b1bfe80a2dd85cd3ede712d

commit aeee3497afaff7ca7b1bfe80a2dd85cd3ede712d
Author: ali 
Date:   Fri Nov 22 15:32:01 2019 -0300

evas_textblock: cursor function null check at start

Reviewers: segfaultxavi, woohyun, lauromoura

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10727
---
 src/lib/evas/canvas/evas_object_textblock.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 487df68179..e854d167e2 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -10462,6 +10462,8 @@ evas_textblock_cursor_line_set(Evas_Textblock_Cursor 
*cur, int line)
 EAPI void
 evas_textblock_cursor_line_jump_by(Efl_Text_Cursor_Handle *cur, int by)
 {
+   if (!cur) return;
+
Efl_Canvas_Text_Data *o = efl_data_scope_get(cur->obj, MY_CLASS);
ASYNC_BLOCK;
int ln;
@@ -10471,11 +10473,8 @@ 
evas_textblock_cursor_line_jump_by(Efl_Text_Cursor_Handle *cur, int by)
Evas_Object_Textblock_Node_Text *pnode;
size_t ppos;
 
-
ln = evas_textblock_cursor_line_geometry_get(cur, NULL, NULL, NULL, NULL) + 
by;
 
-   if (!cur) return;
-
pnode = cur->node;
ppos = cur->pos;
 

-- 




[EGIT] [core/efl] master 01/01: README: update COMPILING AND INSTALLING section

2019-07-19 Thread ali
xartigas pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e57d819b2a7be24a990eb3eb34a9a99f365ad425

commit e57d819b2a7be24a990eb3eb34a9a99f365ad425
Author: ali 
Date:   Fri Jul 19 16:29:31 2019 +0200

README: update COMPILING AND INSTALLING section

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: raster, vtorri, segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9302
---
 README | 10 +-
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/README b/README
index f2404c0246..cdfd852d16 100644
--- a/README
+++ b/README
@@ -422,15 +422,7 @@ libc calls not in Mingw32 that EFL needs.
 COMPILING AND INSTALLING
 
 
-./configure
-make
-sudo make install
-
-If you have doxygen, then you can build documentation with:
-
-make doc
-
-You will find documentation in the doc/ directory.
+See the INSTALL file : https://git.enlightenment.org/core/efl.git/tree/INSTALL
 
 
 REQUIREMENTS

-- 




[EGIT] [core/efl] master 01/01: evas_textblock: change font-size/font-family only using EFL.Text.Font Interface

2019-09-15 Thread ali
cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=32cffb4494c46fa3705062c8e43294bf8f5eca87

commit 32cffb4494c46fa3705062c8e43294bf8f5eca87
Author: ali 
Date:   Mon Jul 29 20:18:37 2019 +

evas_textblock: change font-size/font-family only using EFL.Text.Font 
Interface

Currently:
User cannot change font size only, he needs to set both font and font size 
with (**efl_text_font_font_set**)
To change size only, you need to make two calls, one to get font 
(**efl_text_font_font_get**) , then pass it again with new size to 
(**efl_text_font_font_set**).

New Behaviour:
If user want to change size only, then he passes NULL as font argument to 
keep same font.
If user want to change font only, then he passes 0 as font-size argument, 
to keep same font-size.

Notes:
This is not best solution, but it better than current behaviour.
I think best solution to have separate function to set font size, but It 
might break current api or duplicate functions.

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D9158
---
 src/lib/efl/interfaces/efl_text_font.eo |  3 +++
 src/lib/evas/canvas/evas_object_text.c  | 42 -
 src/lib/evas/canvas/evas_object_textblock.c |  4 +--
 src/tests/evas/evas_test_textblock.c| 30 +
 4 files changed, 58 insertions(+), 21 deletions(-)

diff --git a/src/lib/efl/interfaces/efl_text_font.eo 
b/src/lib/efl/interfaces/efl_text_font.eo
index 27d32d6433..31ded3e43e 100644
--- a/src/lib/efl/interfaces/efl_text_font.eo
+++ b/src/lib/efl/interfaces/efl_text_font.eo
@@ -63,6 +63,9 @@ interface @beta Efl.Text_Font {
   to get an idea). Alternatively, youe can use the full path to a 
font
   file.
 
+  To skip changing font family pass null as font family.
+  To skip changing font size pass 0 as font size.
+
   See also @.font.get, @.font_source.get.
 ]]
  }
diff --git a/src/lib/evas/canvas/evas_object_text.c 
b/src/lib/evas/canvas/evas_object_text.c
index 40277e2ef4..1f8f340f89 100644
--- a/src/lib/evas/canvas/evas_object_text.c
+++ b/src/lib/evas/canvas/evas_object_text.c
@@ -455,34 +455,38 @@ _evas_text_efl_text_font_font_set(Eo *eo_obj, 
Evas_Text_Data *o, const char *fon
Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, 
EFL_CANVAS_OBJECT_CLASS);
Evas_Font_Description *fdesc;
 
-   if ((!font) || (size <= 0)) return;
+   if (!font && size <= 0) return;
 
evas_object_async_block(obj);
if ((size == o->cur.size) &&
(o->cur.font && !strcmp(font, o->cur.font))) return;
 
-   /* We can't assume the given font is same with current fdesc by comparing 
string.
-  Since Evas starts to supporting "auto" for language,
-  the given font string should be parsed once before comparing it. */
-   fdesc = evas_font_desc_new();
+   if (font)
+ {
+/* We can't assume the given font is same with current fdesc by 
comparing string.
+   Since Evas starts to supporting "auto" for language,
+   the given font string should be parsed once before comparing it. */
+fdesc = evas_font_desc_new();
 
-   /* Set default language according to locale. */
-   eina_stringshare_replace(&(fdesc->lang), evas_font_lang_normalize("auto"));
-   evas_font_name_parse(fdesc, font);
+/* Set default language according to locale. */
+eina_stringshare_replace(&(fdesc->lang), 
evas_font_lang_normalize("auto"));
+evas_font_name_parse(fdesc, font);
 
-   if (o->cur.fdesc && !evas_font_desc_cmp(fdesc, o->cur.fdesc) &&
-   (size == o->cur.size))
- {
-evas_font_desc_unref(fdesc);
-return;
- }
+if (o->cur.fdesc && !evas_font_desc_cmp(fdesc, o->cur.fdesc) &&
+(size == o->cur.size))
+  {
+ evas_font_desc_unref(fdesc);
+ return;
+  }
 
-   if (o->cur.fdesc) evas_font_desc_unref(o->cur.fdesc);
-   o->cur.fdesc = fdesc;
+if (o->cur.fdesc) evas_font_desc_unref(o->cur.fdesc);
+o->cur.fdesc = fdesc;
+eina_stringshare_replace(&o->cur.font, font);
+o->prev.font = NULL;
+ }
 
-   o->cur.size = size;
-   eina_stringshare_replace(&o->cur.font, font);
-   o->prev.font = NULL;
+   if ( size > 0 )
+  o->cur.size = size;
 
_evas_text_font_reload(eo_obj, o);
 }
diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 510f6ce05a..1135527ad2 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -15808,13 +15808,13 @@ _efl_canvas_text_efl_text_font_font

[EGIT] [core/efl] master 01/01: evas_textblock: fix warning

2019-09-15 Thread ali
zmike pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c9399b2154d6cdad89fd2e8bc45627c3fcf8be05

commit c9399b2154d6cdad89fd2e8bc45627c3fcf8be05
Author: ali 
Date:   Wed Sep 11 11:07:51 2019 -0400

evas_textblock: fix warning

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9903
---
 src/lib/evas/canvas/evas_object_textblock.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 4b88d82ac8..82c66e3c0d 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -9802,8 +9802,8 @@ EAPI Eina_Bool 
evas_textblock_cursor_at_cluster_as_single_glyph(Evas_Textblock_C
 {
Eina_Bool is_single_glyph = EINA_FALSE;
size_t ret = _evas_textblock_cursor_cluster_pos_get(cur, forward, 
&is_single_glyph);
-
-if ((abs(ret-cur->pos) > 1) && is_single_glyph)
+   size_t distance = (ret > cur->pos) ? ret - cur->pos : cur->pos - ret;
+if ((distance > 1) && is_single_glyph)
   {
  return EINA_TRUE;
   }

-- 




[EGIT] [tools/expedite] master 01/01: evas_textblock: add test for parsing styles time (fill_format)

2019-09-15 Thread ali
cedric pushed a commit to branch master.

http://git.enlightenment.org/tools/expedite.git/commit/?id=dc6c931dc2e6c240d3e240f24578980c689ab7fc

commit dc6c931dc2e6c240d3e240f24578980c689ab7fc
Author: ali 
Date:   Sat Aug 10 11:33:18 2019 +

evas_textblock: add test for parsing styles time (fill_format)

speed test for setting parsing formats during layot_setup stage
this is related to D9536
Differential Revision: https://phab.enlightenment.org/D9541
---
 src/bin/Makefile.am  |   1 +
 src/bin/meson.build  |   1 +
 src/bin/tests.h  |   1 +
 src/bin/textblock_text_fill_format.c | 116 +++
 4 files changed, 119 insertions(+)

diff --git a/src/bin/Makefile.am b/src/bin/Makefile.am
index 754b8ab..046aad3 100644
--- a/src/bin/Makefile.am
+++ b/src/bin/Makefile.am
@@ -86,6 +86,7 @@ textblock_basic.c \
 textblock_intl.c \
 textblock_auto_align.c \
 textblock_text_append.c \
+textblock_text_fill_format.c \
 rect_blend.c \
 rect_blend_pow2.c \
 rect_solid.c \
diff --git a/src/bin/meson.build b/src/bin/meson.build
index b68f600..03c60b4 100644
--- a/src/bin/meson.build
+++ b/src/bin/meson.build
@@ -76,6 +76,7 @@ expedite_sources = [ 'main.c',
'textblock_intl.c',
'textblock_auto_align.c',
'textblock_text_append.c',
+   'textblock_text_fill_format.c',
'rect_blend.c',
'rect_blend_pow2.c',
'rect_solid.c',
diff --git a/src/bin/tests.h b/src/bin/tests.h
index a3fdb1c..3308836 100644
--- a/src/bin/tests.h
+++ b/src/bin/tests.h
@@ -69,6 +69,7 @@
 #include "textblock_intl.c"
 #include "textblock_auto_align.c"
 #include "textblock_text_append.c"
+#include "textblock_text_fill_format.c"
 #include "rect_blend.c"
 #include "rect_blend_pow2.c"
 #include "rect_solid.c"
diff --git a/src/bin/textblock_text_fill_format.c 
b/src/bin/textblock_text_fill_format.c
new file mode 100644
index 000..278a4d4
--- /dev/null
+++ b/src/bin/textblock_text_fill_format.c
@@ -0,0 +1,116 @@
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME textblock_text_fill_format
+#define NAME "Textblock text_fill_format"
+#define ICON "text.png"
+
+#ifndef PROTO
+# ifndef UI
+#  include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_text;
+static int sizes[] = {500, 600};
+Evas_Coord ll, rr, tt, bb;
+
+/* setup */
+static void _setup(void)
+{
+   Evas_Object *o;
+   Evas_Textblock_Style *st;
+
+   o = evas_object_textblock_add(evas);
+   o_text = o;
+   st = evas_textblock_style_new();
+   evas_textblock_style_set (st, "DEFAULT='font=Sans font_size=10 
color=#00 wrap=word align=left outline_color=#000 shadow_color=#fff8 
shadow_color=#0002 glow2_color=#fe87 glow_color=#f214 underline_color=#00f 
linesize=40'");
+   evas_object_textblock_style_set(o, st);
+   evas_object_textblock_clear(o);
+   evas_object_textblock_text_markup_set(o, "This test resize text block and 
keep style (style parsed only once)");
+
+   efl_gfx_entity_position_set(o, EINA_POSITION2D(0, 0)); \
+   efl_gfx_entity_size_set(o, EINA_SIZE2D(win_w, win_h)); \
+   efl_gfx_entity_visible_set(o, EINA_TRUE);
+
+   evas_textblock_style_free(st);
+
+   done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+   efl_del(o_text);
+   o_text = NULL;
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+   Evas_Coord x, y, w, h, w0, h0;
+   int i = 0;
+
+   w0 = 160;
+   h0 = 120;
+   w = 150 + ((1.0 + cos((double)(f + (i * 10)) / (37.4 * SLOW) )) * w0 * 2);
+   h = 50 + ((1.0 + sin((double)(f + (i * 19)) / (52.6 * SLOW) )) * h0 * 2);
+   x = (win_w / 2) - (w / 2);
+   x += sin((double)(f + (i * 13)) / (86.7 * SLOW)) * (w0 / 2);
+   y = (win_h / 2) - (h / 2);
+   y += cos((double)(f + (i * 28)) / (93.8 * SLOW)) * (h0 / 2);
+   efl_gfx_entity_position_set(o_text, EINA_POSITION2D(x, y));
+
+   for (i = 0; i < 1; i++)
+ {
+evas_object_resize(o_text, sizes[i%2], sizes[i%2]);
+evas_object_textblock_style_insets_get((Efl_Canvas_Object*) o_text, 
&ll, &rr, &tt, &bb);
+ }
+   FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(const char *key)
+{
+   KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+   ui_func_set(_key, _loop);
+   _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON

-- 




[EGIT] [core/efl] master 02/03: evas_common: parse color in rgb()/rgba() format

2019-09-15 Thread ali
cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=a821eb456a8c89943f306286669093e2a43aa1f1

commit a821eb456a8c89943f306286669093e2a43aa1f1
Author: ali 
Date:   Thu Aug 1 23:00:07 2019 +

evas_common: parse color in rgb()/rgba() format

evas_common_format_color_parse: support rgb()/rgba() format

efl user can now specify colors in text formats and styles as 
rgb(0-255,0-255,0-255) &  rgba(0-255,0-255,0-255,0-255)  format.

This is related to task: T8068

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D9309
---
 src/bin/elementary/test_label.c |  2 +
 src/lib/evas/canvas/evas_object_textblock.c | 20 ++
 src/lib/evas/common/evas_text_utils.c   | 98 -
 3 files changed, 104 insertions(+), 16 deletions(-)

diff --git a/src/bin/elementary/test_label.c b/src/bin/elementary/test_label.c
index c00ae7986e..233ce015b4 100644
--- a/src/bin/elementary/test_label.c
+++ b/src/bin/elementary/test_label.c
@@ -393,6 +393,8 @@ test_label_colors(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
elm_object_text_set(lb,
"this is red color line(color = 
red)"
"this is blue color line (color = 
#FF)"
+   "this is green color line (color = 
rgb(0,255,0))"
+   "this is blue color line 
(color = rgba(0,255,0,255))"
);
evas_object_size_hint_weight_set(lb, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_win_resize_object_add(win, lb);
diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 0ffcaf72e9..6299e3f195 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -1953,6 +1953,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * color=
@@ -1972,6 +1974,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * underline_color=
@@ -1992,6 +1996,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * underline2_color=
@@ -2011,6 +2017,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * underline_dash_color=
@@ -2031,6 +2039,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * outline_color=
@@ -2051,6 +2061,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * shadow_color=
@@ -2071,6 +2083,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * glow_color=
@@ -2091,6 +2105,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "rgb(r,g,b)"
+  * @li "rgba(r,g,b,a)"
   * @li "color_name"  like "red"
   * @code
   * glow2_color=
@@ -2111,6 +2127,8 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch

[EGIT] [core/efl] master 03/03: evas_textblock: markup text: improve handling invalide escape characters

2019-09-15 Thread ali
cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e08ca174888da9d11742e2b08501a1449ebe5b7d

commit e08ca174888da9d11742e2b08501a1449ebe5b7d
Author: ali 
Date:   Sat Aug 3 09:19:20 2019 +

evas_textblock: markup text: improve handling invalide escape characters

Improve handling invalid escape characters.

(*) When '&' character founded in Markup text.
  Old Behavior   : Any text after '&' (if it is not escape), all text 
will be discarded
  New Behavior : Any text after '&' (if it is not escape), will be 
processes as normal plain text.

Example:
 Markup  Text :  Hello X & Y & Z 1 2 3
 Old output :  Hello
 New   output :  Hello X & Y & Z 1 2 3

This is related to T8077

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D9489
---
 src/lib/evas/canvas/evas_object_textblock.c | 18 ++
 src/tests/evas/evas_test_textblock.c| 24 
 2 files changed, 42 insertions(+)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 6299e3f195..433597fa27 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -8144,6 +8144,12 @@ _evas_object_textblock_text_markup_prepend(Eo *eo_obj,
_prepend_escaped_char(cur, esc_start, esc_end + 1);
esc_start = esc_end = NULL;
 }
+  else if (*p == 0 && esc_start) /* escape start with no end, 
append it as text */
+{
+   _prepend_text_run(cur, esc_start, p);
+   esc_start = esc_end = NULL;
+   s = NULL;
+}
   else if (*p == 0)
 {
_prepend_text_run(cur, s, p);
@@ -8154,6 +8160,12 @@ _evas_object_textblock_text_markup_prepend(Eo *eo_obj,
}
  if (*p == '<')
{
+  if (esc_start) /* escape start with no end, append it as 
text */
+{
+   _prepend_text_run(cur, esc_start, p);
+   esc_start = esc_end = NULL;
+   s = NULL;
+}
   if (!esc_start)
 {
/* Append the text prior to this to the textblock and 
mark
@@ -8174,6 +8186,12 @@ _evas_object_textblock_text_markup_prepend(Eo *eo_obj,
}
  else if (*p == '&')
{
+  if (esc_start) /* escape start with no end, append it as 
text */
+{
+   _prepend_text_run(cur, esc_start, p);
+   esc_start = esc_end = NULL;
+   s = NULL;
+}
   if (!tag_start)
 {
/* Append the text prior to this to the textblock and 
mark
diff --git a/src/tests/evas/evas_test_textblock.c 
b/src/tests/evas/evas_test_textblock.c
index ef81ae3172..f61574c065 100644
--- a/src/tests/evas/evas_test_textblock.c
+++ b/src/tests/evas/evas_test_textblock.c
@@ -4654,6 +4654,29 @@ EFL_START_TEST(efl_canvas_text_markup)
 }
 EFL_END_TEST
 
+EFL_START_TEST(efl_canvas_text_markup_invalid_escape)
+{
+   START_EFL_CANVAS_TEXT_TEST();
+
+   char * text1 = "Hello";
+   char * text2 = "Hello&123";
+   char * text3 = "Hello&123&456";
+   Evas_Coord fw1, fw2, fw3;
+
+   efl_text_markup_set(txt,text1);
+   efl_canvas_text_size_native_get(txt, &fw1, NULL);
+   efl_text_markup_set(txt,text2);
+   efl_canvas_text_size_native_get(txt, &fw2, NULL);
+   fail_if(fw2 <= fw1);
+   efl_text_markup_set(txt,text3);
+   efl_canvas_text_size_native_get(txt, &fw3, NULL);
+   fail_if(fw3 <= fw2);
+
+   END_EFL_CANVAS_TEXT_TEST();
+}
+EFL_END_TEST
+
+
 EFL_START_TEST(efl_text_font)
 {
START_EFL_CANVAS_TEXT_TEST();
@@ -4715,6 +4738,7 @@ void evas_test_textblock(TCase *tc)
tcase_add_test(tc, efl_text);
tcase_add_test(tc, efl_canvas_text_cursor);
tcase_add_test(tc, efl_canvas_text_markup);
+   tcase_add_test(tc, efl_canvas_text_markup_invalid_escape);
tcase_add_test(tc, efl_text_font);
 }
 

-- 




[EGIT] [core/efl] efl-1.22 13/119: elm_entry: speed up setting text (check if same text is already set), fix setting same text pointer

2019-05-30 Thread Ali Alzyod
zmike pushed a commit to branch efl-1.22.

http://git.enlightenment.org/core/efl.git/commit/?id=546805650ea7e8c0c6fa61306c09c6dfff11b35f

commit 546805650ea7e8c0c6fa61306c09c6dfff11b35f
Author: Ali Alzyod 
Date:   Tue Apr 23 15:46:47 2019 +

elm_entry: speed up setting text (check if same text is already set), fix 
setting same text pointer

This patch deal with two cases:

1- Setting text in Entry (elm_entry_entry_set) , as the one get using 
(elm_entry_entry_get), caused the entry to become empty.
 * becase entry string was free inside the elm_entry_entry_set 
function, without checking new passed string.

Now we check if same string was passed to the function, then nothing need 
to be changed.

```
// Old Behaviour : Entry will become empty
// New Behaviour : Entry will Skip setting same text
elm_entry_entry_set(app->entry, elm_entry_entry_get(app->entry));
```

2- Setting text in Entry (elm_entry_entry_set) , with same content string.
 * internally entry will set empty string then set passed string, which 
will case recalculation and re-render the entry element.

Now we check if same string data that is passed to the function is the same 
of the entry content, then nothing need to be changed.

```
// This will be skiped internally since same text is set
elm_entry_entry_set(app->entry, "a");
elm_entry_entry_set(app->entry, "a");  //skipped
```

Reviewed-by: Marcel Hollerbach 
Differential Revision: https://phab.enlightenment.org/D8572
---
 src/lib/elementary/elm_entry.c | 12 ++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/src/lib/elementary/elm_entry.c b/src/lib/elementary/elm_entry.c
index 7478a40fd8..2a6ad77518 100644
--- a/src/lib/elementary/elm_entry.c
+++ b/src/lib/elementary/elm_entry.c
@@ -3314,6 +3314,7 @@ static Eina_Bool
 _elm_entry_text_set(Eo *obj, Elm_Entry_Data *sd, const char *part, const char 
*entry)
 {
int len = 0;
+   const char * current_text = NULL;
 
if (!entry) entry = "";
if (!_elm_layout_part_aliasing_eval(obj, &part, EINA_TRUE))
@@ -3327,8 +3328,6 @@ _elm_entry_text_set(Eo *obj, Elm_Entry_Data *sd, const 
char *part, const char *e
  }
 
evas_event_freeze(evas_object_evas_get(obj));
-   ELM_SAFE_FREE(sd->text, eina_stringshare_del);
-   sd->changed = EINA_TRUE;
 
/* Clear currently pending job if there is one */
if (sd->append_text_idler)
@@ -3345,6 +3344,14 @@ _elm_entry_text_set(Eo *obj, Elm_Entry_Data *sd, const 
char *part, const char *e
 sd->append_text_left = NULL;
  }
 
+   /* If old and new text are the same do nothing */
+   current_text = edje_object_part_text_get(sd->entry_edje, "elm.text");
+   if (current_text == entry || !strcmp(entry, current_text))
+ goto done;
+
+   ELM_SAFE_FREE(sd->text, eina_stringshare_del);
+   sd->changed = EINA_TRUE;
+
/* Need to clear the entry first */
sd->cursor_pos = edje_object_part_text_cursor_pos_get
(sd->entry_edje, "elm.text", EDJE_CURSOR_MAIN);
@@ -3356,6 +3363,7 @@ _elm_entry_text_set(Eo *obj, Elm_Entry_Data *sd, const 
char *part, const char *e
else
  _elm_entry_guide_update(obj, EINA_FALSE);
 
+done:
evas_event_thaw(evas_object_evas_get(obj));
evas_event_thaw_eval(evas_object_evas_get(obj));
return EINA_TRUE;

-- 




[EGIT] [core/efl] efl-1.22 14/119: efl_ui_text: clear selection after cut

2019-05-30 Thread Ali Alzyod
zmike pushed a commit to branch efl-1.22.

http://git.enlightenment.org/core/efl.git/commit/?id=8d5b9c4807f218c88fb8f10fbd1ba401d156c56b

commit 8d5b9c4807f218c88fb8f10fbd1ba401d156c56b
Author: Ali Alzyod 
Date:   Mon May 6 14:01:24 2019 +0200

efl_ui_text: clear selection after cut

Test Plan:
```
#define EFL_EO_API_SUPPORT 1
#define EFL_BETA_API_SUPPORT 1

#include 
#include 
#include 

static void
_gui_quit_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
{
   efl_exit(0);
}

static void
_gui_setup()
{
   Eo *win, *box;

   win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
 efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
 efl_text_set(efl_added, "Hello World"),
 efl_ui_win_autodel_set(efl_added, EINA_TRUE));

   // when the user clicks "close" on a window there is a request to delete
   efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, 
_gui_quit_cb, NULL);

   box = efl_add(EFL_UI_BOX_CLASS, win,
efl_content_set(win, efl_added),
efl_gfx_hint_size_min_set(efl_added, EINA_SIZE2D(360, 
240)));

   efl_add(EFL_UI_TEXT_CLASS, box,
   efl_text_markup_set(efl_added, "Hello World.This is an 
Efl.Ui application!"),
   efl_text_interactive_selection_allowed_set(efl_added, EINA_TRUE),
   efl_text_multiline_set(efl_added,EINA_TRUE),
   efl_gfx_hint_weight_set(efl_added, 1.0, 0.9),
   efl_gfx_hint_align_set(efl_added, 0.5, 0.5),
   efl_pack(box, efl_added));

   efl_add(EFL_UI_BUTTON_CLASS, box,
   efl_text_set(efl_added, "Quit"),
   efl_gfx_hint_weight_set(efl_added, 1.0, 0.1),
   efl_pack(box, efl_added),
   efl_event_callback_add(efl_added, EFL_UI_EVENT_CLICKED,
  _gui_quit_cb, efl_added));
}

EAPI_MAIN void
efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
   _gui_setup();
}
EFL_MAIN()
```

Reviewers: woohyun, bowonryu, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8833
---
 src/lib/elementary/efl_ui_text.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/lib/elementary/efl_ui_text.c b/src/lib/elementary/efl_ui_text.c
index ebb2dd539e..b92df12edb 100644
--- a/src/lib/elementary/efl_ui_text.c
+++ b/src/lib/elementary/efl_ui_text.c
@@ -1231,6 +1231,7 @@ _cut_cb(Eo *obj)
_selection_store(EFL_UI_SELECTION_TYPE_CLIPBOARD, obj);
efl_text_interactive_selection_cursors_get(obj, &start, &end);
efl_canvas_text_range_delete(obj, start, end);
+   _efl_ui_text_select_none(obj, sd);
 }
 
 static void

-- 




[EGIT] [core/efl] master 01/01: evas_object_textblock: add support for variation sequences

2019-10-18 Thread Ali Alzyod
woohyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=46f2d8acdcda3f374c9e393ecb734ff9d00fef7d

commit 46f2d8acdcda3f374c9e393ecb734ff9d00fef7d
Author: Ali Alzyod 
Date:   Sat Oct 19 14:01:36 2019 +0900

evas_object_textblock: add support for variation sequences

Summary: update font processing to handle variation sequences unicodes to 
select proper glypg in respect to variation seqences

Test Plan:
```
#define EFL_EO_API_SUPPORT 1
#define EFL_BETA_API_SUPPORT 1
#include 
#include 
#include 

EAPI_MAIN int
elm_main(int argc, char **argv)
{
   Evas_Object *win, *textblock;

   elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);

   win = elm_win_util_standard_add("Main", "");
   elm_win_autodel_set(win, EINA_TRUE);
   textblock = evas_object_textblock_add(win);
   efl_canvas_text_style_set(textblock,NULL,"DEFAULT='font=DejaVuSans 
font_fallbacks=SamsungColorEmoji color=#000 font_size=20'");
   evas_object_textblock_text_markup_set(textblock, 
"8️⃣☪️AAA☪︎1234567️⃣");

   evas_object_size_hint_weight_set(textblock, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
   evas_object_size_hint_align_set(textblock, EVAS_HINT_FILL, 
EVAS_HINT_FILL);
   evas_object_show(textblock);
   evas_object_move(textblock, 0, 0);
   evas_object_resize(textblock, 320, 320);
   evas_object_resize(win, 320, 320);
   evas_object_show(win);
   elm_run();
   return 0;

}

ELM_MAIN()

```

Reviewers: woohyun, bowonryu, segfaultxavi, cedric, bu5hm4n

Reviewed By: woohyun, cedric

Subscribers: bu5hm4n, subodh6129, herdsman, segfaultxavi, zmike, cedric, 
#committers, #reviewers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9053
---
 src/bin/elementary/test.c  |   2 +
 src/bin/elementary/test_label.c|  24 +++
 src/lib/evas/common/evas_font.h|  53 +-
 src/lib/evas/common/evas_font_load.c   |   6 +-
 src/lib/evas/common/evas_font_main.c   | 296 ++---
 src/lib/evas/common/evas_font_query.c  |  54 --
 src/lib/evas/common/evas_text_utils.c  |   6 +-
 src/tests/evas/evas_test_textblock.c   |  20 +-
 src/tests/evas/fonts/NotoColorEmoji.ttf| Bin 0 -> 7297112 bytes
 src/tests/evas/fonts/NotoEmoji-Regular.ttf | Bin 0 -> 418804 bytes
 10 files changed, 412 insertions(+), 49 deletions(-)

diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index 8259ed8b0c..bcdb484af3 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -243,6 +243,7 @@ void test_label_wrap(void *data, Evas_Object *obj, void 
*event_info);
 void test_label_ellipsis(void *data, Evas_Object *obj, void *event_info);
 void test_label_colors(void *data, Evas_Object *obj, void *event_info);
 void test_label_emoji(void *data, Evas_Object *obj, void *event_info);
+void test_label_variation_sequence(void *data, Evas_Object *obj, void 
*event_info);
 void test_conformant(void *data, Evas_Object *obj, void *event_info);
 void test_conformant2(void *data, Evas_Object *obj, void *event_info);
 void test_conformant_indicator(void *data, Evas_Object *obj, void *event_info);
@@ -1210,6 +1211,7 @@ add_tests:
ADD_TEST(NULL, "Text", "Label Ellipsis", test_label_ellipsis);
ADD_TEST(NULL, "Text", "Label Colors", test_label_colors);
ADD_TEST(NULL, "Text", "Label Emoji", test_label_emoji);
+   ADD_TEST(NULL, "Text", "Label Variation Sequnece", 
test_label_variation_sequence);
ADD_TEST_EO(NULL, "Text", "Efl.Ui.Textpath", test_ui_textpath);
 
//--//
diff --git a/src/bin/elementary/test_label.c b/src/bin/elementary/test_label.c
index 233ce015b4..72cb2aeca3 100644
--- a/src/bin/elementary/test_label.c
+++ b/src/bin/elementary/test_label.c
@@ -403,6 +403,30 @@ test_label_colors(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
evas_object_show(win);
 }
 
+/*** Label variation sequence 
**/
+void
+test_label_variation_sequence(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_info EINA_UNUSED)
+{
+   Evas_Object *win, *lb;
+
+   win = elm_win_util_standard_add("label-variation sequence", "Label 
variation sequnece");
+   elm_win_autodel_set(win, EINA_TRUE);
+
+   lb = elm_label_add(win);
+   elm_object_text_set(lb,
+   "You need to have at least on font contains variation 
sequence"
+   "Three different 8 glyphs : "
+   "88️8️⃣"
+   "line with 3 variation glyphs : "

[EGIT] [core/efl] master 01/01: evas_textblock: content fit feature

2019-11-05 Thread Ali Alzyod
woohyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2f676a6591c117e15d65f263ebd267866963b627

commit 2f676a6591c117e15d65f263ebd267866963b627
Author: Ali Alzyod 
Date:   Tue Nov 5 20:40:59 2019 +0900

evas_textblock: content fit feature

Summary:
**Content Fit Feature for Evas_Object_Textblock**

This Feature is available at **Evas **object level.  And **Edje **level 
(where it is internally use evas functionality)
This feature will allow text block to fit its content font size to proper 
size to fit its area.

**Main Properties:**
Fit Modes:   None=Default, Width, Height, All [Width+Height]
Fit Size Range :   Contains maximum and minimum font size to be used (and 
in between).
Fit Step Size:   Step(Jump) value when trying fonts sizes between 
Size_Range max and min.
Fit Size Array   :   Other way to resize font, where you explicitly select 
font sizes to be uses(for example [20, 50, 100] it will try 3 sizes only)

Text Fit feature was available in Edje but:
1- It doesn't effected by ellipsis or warping in font style (or do not 
handle the in right way)
2- Accuracy is not good (specially if you have fix pixel size elements 
(spaces,tabs,items))
3- No (Step size, Size Array) available.

Test Plan:
To check the Feature
> elementary_test
> fit
> textbock fit
You can modify all the modes and properties

These are two examples, One using Evas other uses Edje

**Evas**

```
#include 

enum BUTTON{
   BUTTON_MODE = 0,
   BUTTON_MAX  = 1,
   BUTTON_MIN  = 2,
   BUTTON_STEP = 3,
   BUTTON_ARRAY= 4,
   BUTTON_CONTENT  = 5,
   BUTTON_STYLE= 6,
   BUTTON_ALL  = BUTTON_STYLE+1,
};

char* BUTTON_STR[BUTTON_ALL] ={
   "MODE",
   "MAX",
   "MIN",
   "STEP",
   "ARRAY",
   "CONTENT",
   "STYLE",
};

char *contents[] = {
   "Hello World",
   "This is LineTHis is other Line",
   "This text contains SPECIFIC SIZE 
that does not effected by fit mode"
   };

char *styles[] = {
   "DEFAULT='font=sans font_size=30 color=#000 wrap=mixed ellipsis=1.0'",
   "DEFAULT='font=sans font_size=30 color=#000 wrap=mixed'",
   "DEFAULT='font=sans font_size=30 color=#000 ellipsis=1.0'",
   "DEFAULT='font=sans font_size=30 color=#000'",
   };

char *styles_names[] = {
   "wrap=mixed ellipsis=1.0",
   "wrap=mixed ellipsis=NONE",
   "wrap=NONE ellipsis=1.0",
   "wrap=NONE ellipsis=NONE",
   };

typedef struct _APP
{
   Evas_Object *win, *box, *txtblock,*bg, *boxHor, *boxHor2;
   Eo *btn[BUTTON_ALL];
   Eo *lbl_status;
   char * str;
   unsigned int i_contnet, i_style;
} APP;
APP *app;

char * get_fit_status(Eo * textblock);

static void _btn_clicked(void *data EINA_UNUSED, Eo *obj, void *eventInfo 
EINA_UNUSED){
   if (obj == app->btn[BUTTON_MODE])
 {
unsigned int options;
evas_textblock_fit_options_get(app->txtblock, &options);
if (options == TEXTBLOCK_FIT_MODE_NONE)
   evas_textblock_fit_options_set(app->txtblock, 
TEXTBLOCK_FIT_MODE_HEIGHT);
else if (options == TEXTBLOCK_FIT_MODE_HEIGHT)
   evas_textblock_fit_options_set(app->txtblock, 
TEXTBLOCK_FIT_MODE_WIDTH);
else if (options == TEXTBLOCK_FIT_MODE_WIDTH)
   evas_textblock_fit_options_set(app->txtblock, 
TEXTBLOCK_FIT_MODE_ALL);
else if (options == TEXTBLOCK_FIT_MODE_ALL)
   evas_textblock_fit_options_set(app->txtblock, 
TEXTBLOCK_FIT_MODE_NONE);
 }
   else if (obj == app->btn[BUTTON_MAX])
 {
unsigned int min, max;
evas_textblock_fit_size_range_get(app->txtblock, &min, &max);
max -= 5;
evas_textblock_fit_size_range_set(app->txtblock, min, max);
 }
   else if (obj == app->btn[BUTTON_MIN])
 {
unsigned int min, max;
evas_textblock_fit_size_range_get(app->txtblock, &min, &max);
min += 5;
evas_textblock_fit_size_range_set(app->txtblock, min, max);
 }
   else if (obj == app->btn[BUTTON_STEP])
 {
unsigned int step;
evas_textblock_fit_step_size_get(app->txtblock, &step);
step++;
evas_textblock_fit_step_size_set(app->txtblock, step);
 }
   else if (obj == app->btn[

[EGIT] [core/efl] master 01/01: Efl.Text.Attribute_Factory

2019-11-26 Thread Ali Alzyod
woohyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c7f37fe61852ea45dce071e0f80f98adcce08981

commit c7f37fe61852ea45dce071e0f80f98adcce08981
Author: Ali Alzyod 
Date:   Wed Nov 27 13:04:31 2019 +0900

Efl.Text.Attribute_Factory

Summary:
Implementation of new Efl.Text.Attribute_Factory class which replace the 
annotation interface.

Currently, we have two public methods:

```
void efl_text_attribute_factory_attribute_insert(const Efl_Text_Cursor 
*start, const Efl_Text_Cursor *end, const char *format)
unsigned int efl_text_attribute_factory_attribute_clear(const 
Efl_Text_Cursor *start, const Efl_Text_Cursor *end);
```

Other methods will be internal methods, for the time being, we will 
redesign internal methods

Reviewers: woohyun, tasn, segfaultxavi, bu5hm4n, zmike

Subscribers: zmike, q66, cedric, segfaultxavi, bu5hm4n, a.srour, 
#committers, #reviewers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10646
---
 src/bin/elementary/test.c  |   2 -
 src/bin/elementary/test_efl_ui_text.c  | 162 +--
 src/lib/efl/Efl.h  |   3 +-
 src/lib/efl/interfaces/efl_interfaces_main.c   |   1 -
 src/lib/efl/interfaces/efl_text_annotate.eo| 137 --
 src/lib/efl/interfaces/efl_text_types.eot  |   4 +-
 src/lib/efl/interfaces/meson.build |   1 -
 .../elementary/efl_ui_internal_text_interactive.c  |   1 +
 src/lib/elementary/efl_ui_text.c   |  78 +++---
 src/lib/evas/Efl_Canvas.h  |   1 +
 src/lib/evas/Evas_Eo.h |   1 +
 src/lib/evas/Evas_Internal.h   |  11 +
 src/lib/evas/canvas/efl_canvas_text.eo |  11 +-
 src/lib/evas/canvas/efl_canvas_text_internal.h | 104 ++-
 src/lib/evas/canvas/efl_text_attribute_factory.c   | 133 +
 src/lib/evas/canvas/efl_text_attribute_factory.eo  |  37 +++
 src/lib/evas/canvas/efl_text_cursor.c  |  10 +-
 src/lib/evas/canvas/efl_text_cursor.eo |  13 -
 src/lib/evas/canvas/evas_object_textblock.c| 303 +
 src/lib/evas/canvas/meson.build|   4 +-
 src/tests/evas/evas_test_textblock.c   | 224 ++-
 21 files changed, 431 insertions(+), 810 deletions(-)

diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index a78850aa31..1d91bf5a4b 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -366,7 +366,6 @@ void test_code_diff_inline(void *data, Evas_Object *obj, 
void *event_info);
 void test_efl_ui_text(void *data, Evas_Object *obj, void *event_info);
 void test_efl_ui_text_inputfield(void *data, Evas_Object *obj, void 
*event_info);
 void test_efl_ui_text_label(void *data, Evas_Object *obj, void *event_info);
-void test_ui_text_item_factory(void *data, Evas_Object *obj, void *event_info);
 void test_evas_mask(void *data, Edje_Object *obj, void *event_info);
 void test_gfx_filters(void *data, Evas_Object *obj, void *event_info);
 void test_evas_snapshot(void *data, Evas_Object *obj, void *event_info);
@@ -941,7 +940,6 @@ add_tests:
ADD_TEST_EO(NULL, "Entries", "Efl.Ui.Text", test_efl_ui_text);
ADD_TEST_EO(NULL, "Entries", "Efl.Ui.Text Input Field", 
test_efl_ui_text_inputfield);
ADD_TEST_EO(NULL, "Entries", "Efl.Ui.Text Label", test_efl_ui_text_label);
-   ADD_TEST_EO(NULL, "Entries", "Ui.Text Item Factory", 
test_ui_text_item_factory);
ADD_TEST_EO(NULL, "Entries", "Efl.Ui.Tags", test_ui_tags);
 
//--//
diff --git a/src/bin/elementary/test_efl_ui_text.c 
b/src/bin/elementary/test_efl_ui_text.c
index d56fddb78d..e06006703e 100644
--- a/src/bin/elementary/test_efl_ui_text.c
+++ b/src/bin/elementary/test_efl_ui_text.c
@@ -5,6 +5,7 @@
 #include 
 #include 
 #include "elm_priv.h" //FIXME remove this once efl.ui.text doesn't need 
elm_general.h
+
 static void
 _apply_style(Eo *obj, size_t start_pos, size_t end_pos, const char *style)
 {
@@ -16,7 +17,7 @@ _apply_style(Eo *obj, size_t start_pos, size_t end_pos, const 
char *style)
efl_text_cursor_position_set(start, start_pos);
efl_text_cursor_position_set(end, end_pos);
 
-   efl_text_annotation_insert(obj, efl_text_cursor_handle_get(start), 
efl_text_cursor_handle_get(end), style);
+   efl_text_attribute_factory_attribute_insert(start, end, style);
 
efl_del(start);
efl_del(end);
@@ -235,162 +236,3 @@ test_efl_ui_text_inputfield(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED
efl_gfx_entity_size_set(win, EINA_SIZE2D(300, 200));
 
 }
-
-#define IMAGES_SZ 5
-
-static const char *images[IMAGES_SZ] = {
- "sky", "logo", "dog", &quo

[EGIT] [core/efl] master 01/01: Polish text interface methods

2019-11-28 Thread Ali Alzyod
woohyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=7bdb63d045cf3377abb7966d018da10c4e8d6b13

commit 7bdb63d045cf3377abb7966d018da10c4e8d6b13
Author: Ali Alzyod 
Date:   Thu Nov 28 16:55:26 2019 +0900

Polish text interface methods

Summary:
This patch is set to rename some properties of `Efl.Text_Font` & 
`Efl.Text_Format` interfaces.

1- efl_text_font_set/get become (efl_text_font_family_set/get, 
efl_text_font_size_set/get)

2- efl_text_valign/halign   become efl_text_vertical/horizontal_align

3- efl_text_halign_auto_type  become  efl_text_horizontal_align_auto_type

Reviewers: ali.alzyod, woohyun, segfaultxavi, bu5hm4n, zmike, cedric

Reviewed By: woohyun

Subscribers: zmike, #committers, #reviewers, cedric

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10716
---
 src/bin/elementary/test_efl_ui_text.c| 12 ++--
 src/bin/elementary/test_gfx_filters.c|  7 +-
 src/bin/elementary/test_photocam.c   |  3 +-
 src/bin/elementary/test_ui_relative_container.c  |  6 +-
 src/examples/elementary/efl_canvas_layout_text.c |  3 +-
 src/examples/elementary/efl_ui_list_example_1.c  |  6 +-
 src/lib/edje/edje_part_text.c| 48 ++---
 src/lib/edje/edje_text.c | 30 ++---
 src/lib/edje/efl_canvas_layout_part_text.eo  |  3 +-
 src/lib/efl/interfaces/efl_text_font.eo  | 23 +--
 src/lib/efl/interfaces/efl_text_format.eo|  6 +-
 src/lib/elementary/efl_ui_text.c |  6 +-
 src/lib/evas/canvas/efl_canvas_text.eo   |  9 +--
 src/lib/evas/canvas/evas_object_text.c   | 86 +++-
 src/lib/evas/canvas/evas_object_textblock.c  | 45 -
 src/lib/evas/canvas/evas_object_textgrid.c   | 42 
 src/lib/evas/canvas/evas_text_eo.c   |  6 +-
 src/lib/evas/canvas/evas_textgrid_eo.c   | 16 +++--
 src/lib/evas/canvas/evas_textgrid_eo.h   |  2 +-
 src/lib/evas/canvas/evas_textgrid_eo.legacy.h|  2 +-
 src/tests/edje/edje_test_text.c  |  9 ++-
 src/tests/evas/evas_test_textblock.c | 21 --
 22 files changed, 259 insertions(+), 132 deletions(-)

diff --git a/src/bin/elementary/test_efl_ui_text.c 
b/src/bin/elementary/test_efl_ui_text.c
index e06006703e..24870b54ec 100644
--- a/src/bin/elementary/test_efl_ui_text.c
+++ b/src/bin/elementary/test_efl_ui_text.c
@@ -67,7 +67,8 @@ test_efl_ui_text_label(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, voi
 
en = _create_label(win, bx);
efl_text_markup_set(en, "You can also ENTER markup!");
-   efl_text_font_set(en, "Sans", 14);
+   efl_text_font_family_set(en, "Sans");
+   efl_text_font_size_set(en, 14);
efl_text_wrap_set(en, EFL_TEXT_FORMAT_WRAP_WORD);
efl_text_multiline_set(en, EINA_TRUE);
 
@@ -76,7 +77,8 @@ test_efl_ui_text_label(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, voi
  "You can use the text -> markup helper\nto make coding easier.");
efl_text_markup_set(en, markup);
free(markup);
-   efl_text_font_set(en, "Sans", 14);
+   efl_text_font_family_set(en, "Sans");
+   efl_text_font_size_set(en, 14);
efl_text_wrap_set(en, EFL_TEXT_FORMAT_WRAP_WORD);
efl_text_multiline_set(en, EINA_TRUE);
 
@@ -85,7 +87,8 @@ test_efl_ui_text_label(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, voi
  "You can use markup -> text helpersto make coding easier.");
efl_text_set(en, markup);
free(markup);
-   efl_text_font_set(en, "Sans", 14);
+   efl_text_font_family_set(en, "Sans");
+   efl_text_font_size_set(en, 14);
efl_text_wrap_set(en, EFL_TEXT_FORMAT_WRAP_WORD);
efl_text_multiline_set(en, EINA_TRUE);
 }
@@ -161,7 +164,8 @@ test_efl_ui_text(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *eve
efl_text_interactive_editable_set(en, EINA_TRUE);
efl_ui_text_scrollable_set(en, EINA_TRUE);
 
-   efl_text_font_set(en, "Sans", 12);
+   efl_text_font_family_set(en, "Sans");
+   efl_text_font_size_set(en, 12);
efl_text_font_width_set(en, EFL_TEXT_FONT_WIDTH_ULTRACONDENSED);
efl_text_normal_color_set(en, 255, 255, 255, 255);
 
diff --git a/src/bin/elementary/test_gfx_filters.c 
b/src/bin/elementary/test_gfx_filters.c
index 35360b61b6..988c0769c4 100644
--- a/src/bin/elementary/test_gfx_filters.c
+++ b/src/bin/elementary/test_gfx_filters.c
@@ -294,11 +294,9 @@ _font_size_change(void *data, const Efl_Event *ev)
 {
Eo *win = data;
Eo *text;
-   const char *font;
 
text = efl_key_wref_get(win, "text");
-   efl_text_font_get(text, &font, NULL);
-   efl_text_font_set(text, font, elm_spinner_value_get(ev->object));
+   efl_text_font_size_set(text, elm_spinner_value_get(ev->obje

[EGIT] [core/efl] master 01/01: Content Fit Enhancment

2021-08-30 Thread ali-alzyod
ali-alzyod pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=3a5d04b12506daf0e6ce41b218190e65f68cdc3a

commit 3a5d04b12506daf0e6ce41b218190e65f68cdc3a
Author: ali-alzyod 
Date:   Mon Aug 30 21:13:38 2021 +0300

Content Fit Enhancment

Summary:
Allow user to get currently used font size when Text Fitting is enabled.

previously, the user can not know what is current font size, he only 
specifies font size ranges, and the algorithm internally decides suitable font 
size.
with this change, the user has the ability to know the font size, that the 
fitting algorithm has picked

Reviewers: raster

Subscribers: raster, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12288
---
 src/bin/elementary/test_label.c | 15 ---
 src/lib/evas/canvas/evas_object_textblock.c | 16 
 src/lib/evas/canvas/evas_textblock_legacy.h |  7 +++
 3 files changed, 35 insertions(+), 3 deletions(-)

diff --git a/src/bin/elementary/test_label.c b/src/bin/elementary/test_label.c
index de7c2bcf32..f291c4472e 100644
--- a/src/bin/elementary/test_label.c
+++ b/src/bin/elementary/test_label.c
@@ -320,7 +320,8 @@ enum BUTTON{
BUTTON_ARRAY= 4,
BUTTON_CONTENT  = 5,
BUTTON_STYLE= 6,
-   BUTTON_ALL  = BUTTON_STYLE+1,
+   BUTTON_SIZE = 7,
+   BUTTON_ALL  = BUTTON_SIZE+1,
 };
 
 char* BUTTON_STR[BUTTON_ALL] ={
@@ -331,6 +332,7 @@ char* BUTTON_STR[BUTTON_ALL] ={
"ARRAY",
"CONTENT",
"STYLE",
+   "Get Size",
 };
 
 char *contents[] = {
@@ -430,6 +432,8 @@ char * get_fit_status(Eo * textblock)
static char status[0xFFF];
unsigned int options,min,max,step,size_array[256];
size_t size_array_len;
+   int current_fitting_fontsize = 0;
+   current_fitting_fontsize = evas_textblock_fit_font_size_get(textblock);
evas_textblock_fit_options_get(textblock,&options);
evas_textblock_fit_size_range_get(textblock,&min,&max);
evas_textblock_fit_step_size_get(textblock,&step);
@@ -464,8 +468,13 @@ char * get_fit_status(Eo * textblock)
sprintf(status + strlen(status)," ]");
 
sprintf(status + strlen(status),"");
-   sprintf(status + strlen(status),"%s",styles_names[app->i_style]);
-
+   sprintf(status + strlen(status),"%s",styles_names[app->i_style]);
+   if (current_fitting_fontsize == -1) {
+  sprintf(status + strlen(status),"Current Font Size = No Fitting");
+   }
+   else {
+  sprintf(status + strlen(status),"Current Font Size = %d", 
current_fitting_fontsize);
+   }
 
 
return status;
diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 8f339fe5d2..12bcd38eda 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -431,6 +431,7 @@ struct _TEXT_FIT_CONTENT_CONFIG
   unsigned int min_font_size,max_font_size;
   unsigned int step_size;
   unsigned int *p_size_array;
+  int font_size;
   size_t size_list_length;
   Eina_Size2D size_cache[256+1]; /** used hash font sizes 1-255 */
   Eina_Size2D last_size;
@@ -17881,6 +17882,7 @@ int fit_text_block(Evas_Object *eo_obj)
 /*Lower bound founded, subtract one to move for nearest value*/
 fc->last_size_index = MAX(l-1, 0);
 
fit_style_update(eo_obj,fc->p_size_array[fc->last_size_index],(fc->last_size_index
 != 0) && fc->options != TEXTBLOCK_FIT_MODE_HEIGHT ,EINA_FALSE);
+fc->font_size = fc->p_size_array[fc->last_size_index];
 fit_finish_fitting(eo_obj);
   }
  }
@@ -18052,6 +18054,20 @@ int compareUINT(const void * a, const void * b)
else return 0;
 }
 
+EVAS_API int evas_textblock_fit_font_size_get(Evas_Object *obj){
+   EINA_SAFETY_ON_NULL_RETURN_VAL(obj, EVAS_ERROR_INVALID_PARAM);
+   Efl_Canvas_Textblock_Data *o = efl_data_scope_get(obj, MY_CLASS);
+   TEXT_FIT_CONTENT_CONFIG *fc = &o->fit_content_config;
+   if (fc->options == TEXTBLOCK_FIT_MODE_NONE)
+ {
+return -1;
+ }
+   else
+ {
+return fc->font_size;
+ }
+}
+
 EVAS_API int evas_textblock_fit_size_array_set(Evas_Object *obj, const 
unsigned int *p_size_array, size_t size_array_len)
 {
int n_ret = EVAS_ERROR_SUCCESS;
diff --git a/src/lib/evas/canvas/evas_textblock_legacy.h 
b/src/lib/evas/canvas/evas_textblock_legacy.h
index ae1aaf72b6..e4fee16149 100644
--- a/src/lib/evas/canvas/evas_textblock_legacy.h
+++ b/src/lib/evas/canvas/evas_textblock_legacy.h
@@ -1143,6 +1143,13 @@ EVAS_API int evas_textblock_fit_size_array_get(const 
Evas_Object *obj,  unsigned
  */
 EVAS_API int evas_textblock_fit_size_array_set(Evas_Ob

[EGIT] [core/efl] master 01/01: fix if state formatting

2021-08-30 Thread ali-alzyod
ali-alzyod pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=5f419d5b5fb2bd1abdf369eff8e0247e0eb3d576

commit 5f419d5b5fb2bd1abdf369eff8e0247e0eb3d576
Author: ali-alzyod 
Date:   Mon Aug 30 21:19:14 2021 +0300

fix if state formatting
---
 src/bin/elementary/test_label.c | 14 --
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/src/bin/elementary/test_label.c b/src/bin/elementary/test_label.c
index f291c4472e..a7f0d62da0 100644
--- a/src/bin/elementary/test_label.c
+++ b/src/bin/elementary/test_label.c
@@ -469,12 +469,14 @@ char * get_fit_status(Eo * textblock)
 
sprintf(status + strlen(status),"");
sprintf(status + strlen(status),"%s",styles_names[app->i_style]);
-   if (current_fitting_fontsize == -1) {
-  sprintf(status + strlen(status),"Current Font Size = No Fitting");
-   }
-   else {
-  sprintf(status + strlen(status),"Current Font Size = %d", 
current_fitting_fontsize);
-   }
+   if (current_fitting_fontsize == -1)
+ {
+sprintf(status + strlen(status),"Current Font Size = No Fitting");
+ }
+   else
+ {
+sprintf(status + strlen(status),"Current Font Size = %d", 
current_fitting_fontsize);
+ }
 
 
return status;

-- 




[EGIT] [core/efl] master 01/01: evas_object_textblock: update documentation, setting color part

2019-07-14 Thread Ali Alzyod
xartigas pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=7ad0dda73d19cd0c951c9c260b9f39e24fa8d5b3

commit 7ad0dda73d19cd0c951c9c260b9f39e24fa8d5b3
Author: Ali Alzyod 
Date:   Tue Jul 9 19:31:44 2019 +0200

evas_object_textblock: update documentation, setting color part

Summary: Now Textblock has the ability to parse color names same as hex 
value strings.

Reviewers: segfaultxavi, woohyun, bowonryu

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9250
---
 src/lib/evas/canvas/evas_object_textblock.c | 10 ++
 1 file changed, 10 insertions(+)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 87dc57fa65..2210c958b0 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -1952,6 +1952,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * color=
   * @endcode
@@ -1970,6 +1971,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * underline_color=
   * @endcode
@@ -1989,6 +1991,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * underline2_color=
   * @endcode
@@ -2007,6 +2010,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * underline_dash_color=
   * @endcode
@@ -2026,6 +2030,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * outline_color=
   * @endcode
@@ -2045,6 +2050,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * shadow_color=
   * @endcode
@@ -2064,6 +2070,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * glow_color=
   * @endcode
@@ -2083,6 +2090,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * glow2_color=
   * @endcode
@@ -2102,6 +2110,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * backing_color=
   * @endcode
@@ -2121,6 +2130,7 @@ _format_command(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const ch
   * @li "#RRGGBBAA"
   * @li "#RGB"
   * @li "#RGBA"
+  * @li "color_name"  like "red"
   * @code
   * strikethrough_color=
   * @endcode

-- 




[EGIT] [core/efl] master 01/01: efl_gfx_color: fix color_code_set

2019-09-15 Thread Ali Alzyod
xartigas pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=1c0a459293981ef9691b9bb5acd468ba84e502b4

commit 1c0a459293981ef9691b9bb5acd468ba84e502b4
Author: Ali Alzyod 
Date:   Mon Jul 29 12:10:18 2019 +0200

efl_gfx_color: fix color_code_set

Summary:
There are two parts for this patch:
1- Fix sigmentation fault when using (efl_gfx_color_color_code_set).  // It 
try to modify const variable
2- Remove unnecessary code. // why would user pass slash or back slash as 
color code format.

Test Plan:
```
#define EFL_EO_API_SUPPORT 1
#define EFL_BETA_API_SUPPORT 1

#include 
#include 
#include 

static void
_gui_quit_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
{
   efl_exit(0);
}

static void
_gui_setup()
{
   Eo *win, *rect;

   win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
 efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
 efl_text_set(efl_added, "Hello World"),
 efl_ui_win_autodel_set(efl_added, EINA_TRUE));

   // when the user clicks "close" on a window there is a request to delete
   efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, 
_gui_quit_cb, NULL);
   rect = efl_add(EFL_CANVAS_RECTANGLE_CLASS,win);
   const char *color = "#FFFF";
   efl_gfx_color_code_set(rect,color);
   evas_object_resize(rect,250,250);
   evas_object_resize(win,250,250);
   evas_object_move(rect,0,0);
   evas_object_show(rect);
   evas_object_show(win);
}

EAPI_MAIN void
efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
   _gui_setup();
}
EFL_MAIN()
```

Reviewers: zmike, cedric, segfaultxavi, woohyun

Reviewed By: segfaultxavi

Subscribers: singh.amitesh, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9422
---
 src/lib/efl/interfaces/efl_gfx_color.c | 20 +---
 1 file changed, 1 insertion(+), 19 deletions(-)

diff --git a/src/lib/efl/interfaces/efl_gfx_color.c 
b/src/lib/efl/interfaces/efl_gfx_color.c
index 92c1f07483..fe35d92cc7 100644
--- a/src/lib/efl/interfaces/efl_gfx_color.c
+++ b/src/lib/efl/interfaces/efl_gfx_color.c
@@ -1,24 +1,6 @@
 #include "config.h"
 #include "Efl.h"
 
-static int
-_format_clean_param(Eina_Tmpstr *s)
-{
-   Eina_Tmpstr *ss;
-   char *ds;
-   int len = 0;
-
-   ds = (char*) s;
-   for (ss = s; *ss; ss++, ds++, len++)
- {
-if ((*ss == '\\') && *(ss + 1)) ss++;
-if (ds != ss) *ds = *ss;
- }
-   *ds = 0;
-
-   return len;
-}
-
 static int
 _hex_string_get(char ch, Eina_Bool *ok)
 {
@@ -102,7 +84,7 @@ _efl_gfx_color_color_code_set(Eo *obj, void *_pd 
EINA_UNUSED, const char *colorc
 int len;
 unsigned char r, g, b, a;
 
-len = _format_clean_param(colorcode);
+len = (size_t) strlen(colorcode);
 
 _format_color_parse(colorcode, len, &r, &g, &b, &a);
 efl_gfx_color_set(obj, r, g, b, a);

-- 




[EGIT] [core/efl] master 01/01: evas_textblock: fix compilation without harfbuzz

2019-09-15 Thread Ali Alzyod
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=155f2f98af9f006c9a47f0a2a436b13c1ab78c26

commit 155f2f98af9f006c9a47f0a2a436b13c1ab78c26
Author: Ali Alzyod 
Date:   Thu Sep 5 08:26:57 2019 +

evas_textblock: fix compilation without harfbuzz

Differential Revision: https://phab.enlightenment.org/D9845
---
 src/lib/evas/canvas/evas_object_textblock.c | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 90561f4f90..08fad5e92e 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -9728,7 +9728,7 @@ 
_evas_textblock_cursor_cluster_pos_get(Evas_Textblock_Cursor *cur, Eina_Bool inc
 
free(grapheme_breaks);
 }
-
+#ifdef OT_SUPPORT
   if (is_single_glyph)
 {
Evas_Object_Textblock_Text_Item *ti = 
_ITEM_TEXT(last_it);
@@ -9786,6 +9786,9 @@ 
_evas_textblock_cursor_cluster_pos_get(Evas_Textblock_Cursor *cur, Eina_Bool inc
 is_single_glyph = EINA_FALSE;
  }
 }
+#else//#ifdef OT_SUPPORT
+  (void)is_single_glyph;
+#endif//#ifdef OT_SUPPORT
}
   }
  }

-- 




[EGIT] [core/efl] master 01/01: evas_text: backward compatibility for setting text size

2019-09-15 Thread Ali Alzyod
woohyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=eee58425eae4253abe16e86718fb08afc221a1b9

commit eee58425eae4253abe16e86718fb08afc221a1b9
Author: Ali Alzyod 
Date:   Wed Aug 7 20:39:33 2019 +0900

evas_text: backward compatibility for setting text size

Summary: This is for backward compatibility for TIZEN Test cases for legacy

Reviewers: woohyun

Reviewed By: woohyun

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9519
---
 src/lib/evas/canvas/evas_object_text.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/lib/evas/canvas/evas_object_text.c 
b/src/lib/evas/canvas/evas_object_text.c
index 1f8f340f89..1a97af9f4c 100644
--- a/src/lib/evas/canvas/evas_object_text.c
+++ b/src/lib/evas/canvas/evas_object_text.c
@@ -2336,6 +2336,7 @@ evas_object_text_font_source_get(const Eo *obj)
 EAPI void
 evas_object_text_font_set(Eo *obj, const char *font, Evas_Font_Size size)
 {
+   if (!font || size <= 0) return; /*Condition for legacy object*/
efl_text_font_set((Eo *) obj, font, size);
 }
 

-- 




[EGIT] [core/efl] master 01/01: evas_textblock: markup: handle invalid/missing escape characters

2019-09-15 Thread Ali Alzyod
xartigas pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0bab8be791b7454f19d6b813fb005cd78333bd67

commit 0bab8be791b7454f19d6b813fb005cd78333bd67
Author: Ali Alzyod 
Date:   Mon Jul 29 14:00:04 2019 +0200

evas_textblock: markup: handle invalid/missing escape characters

Summary:
T8088

if escape character sequence not found for example **&123;** :
* (Old Behaviour)  : Draw nothing
* (New Behaviour)  : Draw Text like it plain text

I think this is the right behaviour since:
1- We print output as it is, so user can detect what was the problem.
   For example user write &gf; (by mistake, he wanted to write >)
   == if we nothing is printed he would not know exactly where is the real 
problem.
  it can be font file, textblock is not visible, he may think bug in efl
   == if we printed &gf; as it is, it will direclty show that this is not 
valid escape char.
2- If user made mistake in text, it is better to show it instead of hide 
it, maybe there are new sequences that we do not know about.

This behaviour was checked on multible systems:
1- Web Browsers like chrome
2- Qt
3- Android

They all have same as our new behaviour

Example :
markup text =  ">&gf;
Old  : >
New: >&gf;

Test Plan:
```
#define EFL_EO_API_SUPPORT 1
#define EFL_BETA_API_SUPPORT 1

#include 
#include 
#include 

static void
_gui_quit_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
{
   efl_exit(0);
}

static void
_gui_setup()
{
   Eo *win, *box;

   win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
 efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
 efl_text_set(efl_added, "Hello World"),
 efl_ui_win_autodel_set(efl_added, EINA_TRUE));

   // when the user clicks "close" on a window there is a request to delete
   efl_event_callback_add(win, EFL_UI_WIN_EVENT_DELETE_REQUEST, 
_gui_quit_cb, NULL);

   box = efl_add(EFL_UI_BOX_CLASS, win,
efl_content_set(win, efl_added),
efl_gfx_hint_size_min_set(efl_added, EINA_SIZE2D(360, 
240)));

   efl_add(EFL_UI_TEXT_CLASS, box,
   efl_text_markup_set(efl_added,
   ">&gf;"),
   efl_text_interactive_selection_allowed_set(efl_added, 
EINA_FALSE),
   efl_gfx_hint_weight_set(efl_added, 1.0, 0.9),
   efl_gfx_hint_align_set(efl_added, 0.5, 0.5),
   efl_text_multiline_set(efl_added,EINA_FALSE),
   efl_pack(box, efl_added));

   efl_add(EFL_UI_BUTTON_CLASS, box,
   efl_text_set(efl_added, "Quit"),
   efl_gfx_hint_weight_set(efl_added, 1.0, 0.1),
   efl_pack(box, efl_added),
   efl_event_callback_add(efl_added, EFL_UI_EVENT_CLICKED,
  _gui_quit_cb, efl_added));
}

EAPI_MAIN void
efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
   _gui_setup();
}
EFL_MAIN()
```

Reviewers: woohyun, bowonryu, segfaultxavi, bu5hm4n

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9428
---
 src/lib/evas/canvas/evas_object_textblock.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 2210c958b0..510f6ce05a 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -7931,6 +7931,8 @@ _prepend_escaped_char(Efl_Text_Cursor_Cursor *cur_obj, 
const char *s,
escape = _escaped_char_get(s, s_end);
if (escape)
  evas_textblock_cursor_text_prepend(cur_obj, escape);
+   else /* Use same text input if no escape was found */
+ _prepend_text_run(cur_obj, s, s_end);
 }
 
 

-- 




[EGIT] [core/efl] master 01/03: evas_textblock: reduce _evas_textblock_changed calls with markup_text_append

2019-09-15 Thread Ali Alzyod
cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=1d76452aa964c93cd7b8ea343f918866bf9cacb8

commit 1d76452aa964c93cd7b8ea343f918866bf9cacb8
Author: Ali Alzyod 
Date:   Mon Jul 22 15:25:17 2019 +

evas_textblock: reduce _evas_textblock_changed calls with markup_text_append

**_evas_textblock_changed** is internal function that mark that the 
textblock has changed.

When make call for
evas_object_textblock_text_markup_set(txtblock,"This is LineTHis is 
other Line");

Old behaviour:
multible calles for _evas_textblock_changed will happend, for each 
text/format appended.

New behaviour:
Single call for _evas_textblock_changed will happend.

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D9376
---
 src/lib/evas/canvas/evas_object_textblock.c | 12 ++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 6ecc9b1112..0ffcaf72e9 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -657,6 +657,7 @@ struct _Evas_Object_Textblock
} gfx_filter;
Eina_Bool   redraw : 1;
Eina_Bool   changed : 1;
+   Eina_Bool   pause_change : 1;
Eina_Bool   obstacle_changed : 1;
Eina_Bool   content_changed : 1;
Eina_Bool   format_changed : 1;
@@ -8075,6 +8076,10 @@ _evas_object_textblock_text_markup_prepend(Eo *eo_obj,
Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, 
EFL_CANVAS_OBJECT_CLASS);
evas_object_async_block(obj);
TB_HEAD();
+
+   /* Stop calls for _evas_textblock_changed for each cursor_text_append or 
cursor_format_append
+* this should be done once, when markup_prepend finished */
+   o->pause_change = EINA_TRUE;
if (text)
  {
 char *s, *p;
@@ -8189,6 +8194,7 @@ _evas_object_textblock_text_markup_prepend(Eo *eo_obj,
  p++;
   }
  }
+   o->pause_change = EINA_FALSE;
_evas_textblock_changed(o, eo_obj);
 }
 
@@ -10996,7 +11002,8 @@ 
_evas_textblock_cursor_text_append(Efl_Text_Cursor_Cursor *cur, const char *_tex
/* Update all the cursors after our position. */
_evas_textblock_cursors_update_offset(cur, cur->node, cur->pos, len);
 
-   _evas_textblock_changed(o, cur->obj);
+   if (!o->pause_change)
+ _evas_textblock_changed(o, cur->obj);
n->dirty = EINA_TRUE;
free(text);
 
@@ -11342,7 +11349,8 @@ 
_evas_textblock_cursor_format_append(Efl_Text_Cursor_Cursor *cur,
 o->format_changed = EINA_TRUE;
  }
 
-   _evas_textblock_changed(o, cur->obj);
+   if (!o->pause_change)
+ _evas_textblock_changed(o, cur->obj);
 
Efl_Text_Cursor_Cursor *ocur = o->cursor;
if (!ocur->node)

-- 




[EGIT] [core/efl] master 01/01: elm_entry: handle cursor delete/backspace with clusters consist of one or multible glyphs

2019-09-15 Thread Ali Alzyod
woohyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=7a05d8d76997399bb55893d4b456b24e65a223cc

commit 7a05d8d76997399bb55893d4b456b24e65a223cc
Author: Ali Alzyod 
Date:   Thu Sep 5 14:52:51 2019 +0900

elm_entry: handle cursor delete/backspace with clusters consist of one or 
multible glyphs

Summary:
Cluster consist of one glyph, expected to be removed on backspace or delete 
key.
Cluster consist of multible glyph, expectd to remove part of on backspace 
or delete key.

This is behaviour founded in Android. (our current way of handling similar 
to Qt)

**New Behaviour**
{F3750386}

**Old Behaviour**
{F3750387}

Test Plan:
Auto Testing is challenging because there are no easy way to emulate 
keyboard down on elm_entry
```
#include 

EAPI_MAIN int
elm_main(int argc, char **argv)
{
   Evas_Object *win,*box,*entry;

   elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);

   win = elm_win_util_standard_add("", "");
   elm_win_autodel_set(win, EINA_TRUE);

   box = elm_box_add(win);
   entry = elm_entry_add(box);

   evas_object_size_hint_weight_set(box,EVAS_HINT_EXPAND,EVAS_HINT_EXPAND);
   evas_object_size_hint_align_set(box,EVAS_HINT_FILL,EVAS_HINT_FILL);

   elm_entry_entry_set(entry,"🇧🇬อั🇧🇬อั😀อั");
   evas_object_size_hint_weight_set(entry,EVAS_HINT_EXPAND,0.9);
   evas_object_size_hint_align_set(entry,EVAS_HINT_FILL,EVAS_HINT_FILL);
   evas_object_show(entry);
   evas_object_show(box);

   elm_box_pack_end(box,entry);
   elm_win_resize_object_add(win,box);
   evas_object_resize(win,320,480);

   evas_object_size_hint_weight_set(entry,EVAS_HINT_EXPAND,0.1);
   evas_object_size_hint_align_set(entry,EVAS_HINT_FILL,EVAS_HINT_FILL);

   evas_object_show(win);
   elm_run();

   return 0;
}
ELM_MAIN()

```

Reviewers: tasn, woohyun, bowonryu

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9628
---
 src/lib/edje/edje_entry.c   | 52 +---
 src/lib/evas/Evas_Internal.h| 11 +
 src/lib/evas/canvas/evas_object_textblock.c | 76 +++--
 3 files changed, 128 insertions(+), 11 deletions(-)

diff --git a/src/lib/edje/edje_entry.c b/src/lib/edje/edje_entry.c
index 2363c4b2d3..a15bd64678 100644
--- a/src/lib/edje/edje_entry.c
+++ b/src/lib/edje/edje_entry.c
@@ -1600,11 +1600,23 @@ static void
 _delete_emit(Edje *ed, Evas_Textblock_Cursor *c, Entry *en, size_t pos,
  Eina_Bool backspace)
 {
-   if (!evas_textblock_cursor_char_next(c))
+
+   if (backspace)
  {
-return;
+if (!evas_textblock_cursor_char_prev(c))
+  {
+ return;
+  }
+evas_textblock_cursor_char_next(c);
+ }
+   else
+ {
+if (!evas_textblock_cursor_char_next(c))
+  {
+ return;
+  }
+evas_textblock_cursor_char_prev(c);
  }
-   evas_textblock_cursor_char_prev(c);
 
Edje_Entry_Change_Info *info = calloc(1, sizeof(*info));
if (!info)
@@ -1617,16 +1629,40 @@ _delete_emit(Edje *ed, Evas_Textblock_Cursor *c, Entry 
*en, size_t pos,
info->insert = EINA_FALSE;
if (backspace)
  {
-info->change.del.start = pos - 1;
+
+Evas_Textblock_Cursor *cc = 
evas_object_textblock_cursor_new(en->rp->object);
+evas_textblock_cursor_copy(c, cc);
+Eina_Bool remove_cluster = 
evas_textblock_cursor_at_cluster_as_single_glyph(cc,EINA_FALSE);
+if (remove_cluster)
+  {
+ evas_textblock_cursor_cluster_prev(cc);
+  }
+else
+  {
+ evas_textblock_cursor_char_prev(cc);
+  }
+
+info->change.del.start = evas_textblock_cursor_pos_get(cc);
 info->change.del.end = pos;
-tmp = evas_textblock_cursor_content_get(c);
-evas_textblock_cursor_char_delete(c);
+
+tmp = evas_textblock_cursor_range_text_get(c, cc, 
EVAS_TEXTBLOCK_TEXT_MARKUP);
+evas_textblock_cursor_range_delete(c, cc);
+evas_textblock_cursor_free(cc);
  }
else
  {
 Evas_Textblock_Cursor *cc = 
evas_object_textblock_cursor_new(en->rp->object);
 evas_textblock_cursor_copy(c, cc);
-evas_textblock_cursor_cluster_next(cc);
+
+Eina_Bool remove_cluster = 
evas_textblock_cursor_at_cluster_as_single_glyph(cc,EINA_TRUE);
+if (remove_cluster)
+  {
+ evas_textblock_cursor_cluster_next(cc);
+  }
+else
+  {
+ evas_textblock_cursor_char_next(cc);
+  }
 
 info->change.del.start = evas_textblock_cursor_pos_get(cc)

[EGIT] [core/efl] master 01/08: evas_object_textblock: add support for variation sequences

2019-09-15 Thread Ali Alzyod
cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f7ce771e3243e19f8a12672ea2be752dedccbcf6

commit f7ce771e3243e19f8a12672ea2be752dedccbcf6
Author: Ali Alzyod 
Date:   Thu Jul 18 08:51:28 2019 +

evas_object_textblock: add support for variation sequences

update font processing to handle variation sequences unicodes to select 
proper glypg in respect to variation seqences

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D9053
---
 src/bin/elementary/test.c |   2 +
 src/bin/elementary/test_label.c   |  24 +++
 src/lib/evas/common/evas_font.h   |  53 +-
 src/lib/evas/common/evas_font_load.c  |   6 +-
 src/lib/evas/common/evas_font_main.c  | 296 ++
 src/lib/evas/common/evas_font_query.c |  54 +--
 src/lib/evas/common/evas_text_utils.c |   6 +-
 src/tests/evas/evas_test_textblock.c  |  19 ++-
 8 files changed, 411 insertions(+), 49 deletions(-)

diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index 8856c7cab1..adae27b52c 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -243,6 +243,7 @@ void test_label_wrap(void *data, Evas_Object *obj, void 
*event_info);
 void test_label_ellipsis(void *data, Evas_Object *obj, void *event_info);
 void test_label_colors(void *data, Evas_Object *obj, void *event_info);
 void test_label_emoji(void *data, Evas_Object *obj, void *event_info);
+void test_label_variation_sequence(void *data, Evas_Object *obj, void 
*event_info);
 void test_conformant(void *data, Evas_Object *obj, void *event_info);
 void test_conformant2(void *data, Evas_Object *obj, void *event_info);
 void test_conformant_indicator(void *data, Evas_Object *obj, void *event_info);
@@ -1198,6 +1199,7 @@ add_tests:
ADD_TEST(NULL, "Text", "Label Ellipsis", test_label_ellipsis);
ADD_TEST(NULL, "Text", "Label Colors", test_label_colors);
ADD_TEST(NULL, "Text", "Label Emoji", test_label_emoji);
+   ADD_TEST(NULL, "Text", "Label Variation Sequnece", 
test_label_variation_sequence);
ADD_TEST_EO(NULL, "Text", "Efl.Ui.Textpath", test_ui_textpath);
 
//--//
diff --git a/src/bin/elementary/test_label.c b/src/bin/elementary/test_label.c
index c00ae7986e..f49255f21e 100644
--- a/src/bin/elementary/test_label.c
+++ b/src/bin/elementary/test_label.c
@@ -401,6 +401,30 @@ test_label_colors(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
evas_object_show(win);
 }
 
+/*** Label variation sequence 
**/
+void
+test_label_variation_sequence(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_info EINA_UNUSED)
+{
+   Evas_Object *win, *lb;
+
+   win = elm_win_util_standard_add("label-variation sequence", "Label 
variation sequnece");
+   elm_win_autodel_set(win, EINA_TRUE);
+
+   lb = elm_label_add(win);
+   elm_object_text_set(lb,
+   "You need to have at least on font contains variation 
sequence"
+   "Three different 8 glyphs : "
+   "88️8️⃣"
+   "line with 3 variation glyphs : "
+   
"8️⃣☪️AAA☪︎1234567️⃣"
+   );
+   evas_object_size_hint_weight_set(lb, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+   elm_win_resize_object_add(win, lb);
+   evas_object_show(lb);
+
+   evas_object_show(win);
+}
+
 /*** Label Emoji */
 static char *
 _fontlist_text_get(void *data, Evas_Object *obj EINA_UNUSED, const char *part 
EINA_UNUSED)
diff --git a/src/lib/evas/common/evas_font.h b/src/lib/evas/common/evas_font.h
index ab6e6fbd17..5e79026ca3 100644
--- a/src/lib/evas/common/evas_font.h
+++ b/src/lib/evas/common/evas_font.h
@@ -56,7 +56,32 @@ typedef unsigned long longDATA64;
 #define LKU(x) eina_lock_release(&(x))
 #define LKDBG(x) eina_lock_debug(&(x))
 
+/**
+ * See explanation of variation_sequences at:
+ * https://unicode.org/Public/UCD/latest/ucd/StandardizedVariants.txt
+ * https://unicode.org/reports/tr37/
+ * https://unicode.org/ivd/
+ * https://www.freetype.org/freetype2/docs/reference/ft2-glyph_variants.html
+*/
+#define VAR_SEQ(x) GENERIC_VARIATION_SEQUENCES(x) | 
IDEOGRAPHICS_VARIATION_SEQUENCES(x) | MANGOLIAN_VARIATION_SEQUENCES(x)
+#define GENERIC_VARIATION_SEQUENCES(x) (x>=0xFE00 && x<=0xFE0F) ? x : 0
+#define IDEOGRAPHICS_VARIATION_SEQUENCES(x) (x>=0xE0100 && x<=0xE01EF) ? x : 0
+#define MANGOLIAN_VARIATION_SEQUENCES(x) (x>=0x180B && x<=0x180D) ? x : 0
+/**
+ * http://unicode.org/emoji/charts/emoji-variants.html
+*/
+#define  VARIATION_EMOJI_PRESENTATION  0xFE0F
+#define  VARIATION_TEXT_PRES

[EGIT] [core/efl] master 01/01: eina_test: resolve build warning

2019-09-15 Thread Ali Alzyod
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=080f75e8c9fe420d081d5d77b5822939cbd0f9d6

commit 080f75e8c9fe420d081d5d77b5822939cbd0f9d6
Author: Ali Alzyod 
Date:   Thu Aug 29 07:44:22 2019 +

eina_test: resolve build warning

Differential Revision: https://phab.enlightenment.org/D9781
---
 src/tests/eina/eina_test_array.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/tests/eina/eina_test_array.c b/src/tests/eina/eina_test_array.c
index fbe7966af0..de58cdfaec 100644
--- a/src/tests/eina/eina_test_array.c
+++ b/src/tests/eina/eina_test_array.c
@@ -177,7 +177,7 @@ EFL_END_TEST
 EFL_START_TEST(eina_array_find_test)
 {
Eina_Array sea;
-   unsigned int i;
+   unsigned long i;
unsigned int out = 0;
 
fail_if(eina_array_find(NULL, (void*)1, NULL) != EINA_FALSE);

-- 




[EGIT] [core/efl] master 01/01: evas_textblock: apply coding convention

2019-09-15 Thread Ali Alzyod
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f2937018910751a73bcf87448785d6f688e374a4

commit f2937018910751a73bcf87448785d6f688e374a4
Author: Ali Alzyod 
Date:   Tue Sep 3 11:05:08 2019 +

evas_textblock: apply coding convention

Reviewed-by: Tom Hacohen 
Differential Revision: https://phab.enlightenment.org/D9819
---
 src/lib/evas/canvas/evas_object_textblock.c | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 08fad5e92e..4b88d82ac8 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -7834,7 +7834,8 @@ _escaped_is_eq_and_advance(const char *s, const char 
*s_end,
  * @param escape_values array of Escape_Value to look inside, Sorted by Escape
  * @param escape_values_len is the len of Escape_Value array
  */
-int _escaped_string_search(const char * s, size_t s_len, const Escape_Value 
escape_values[], const size_t escape_values_len)
+static int
+_escaped_string_search(const char *s, size_t s_len, const Escape_Value 
escape_values[], const size_t escape_values_len)
 {
int l = 0;
int r = escape_values_len - 1;
@@ -7868,7 +7869,8 @@ int _escaped_string_search(const char * s, size_t s_len, 
const Escape_Value esca
  * @param escape_values array of Escape_Value to look inside, Sorted by Value
  * @param escape_values_len is the len of Escape_Value array
  */
-int _escaped_value_search(const char * s, const Escape_Value escape_values[], 
const size_t escape_values_len)
+static int
+_escaped_value_search(const char *s, const Escape_Value escape_values[], const 
size_t escape_values_len)
 {
int l = 0;
int r = escape_values_len - 1;

-- 




[EGIT] [tools/examples] master 01/01: example: fix compilation error

2019-09-16 Thread Ali Alzyod
xartigas pushed a commit to branch master.

http://git.enlightenment.org/tools/examples.git/commit/?id=17609ba6bf8bea42e121f742fceea77308e50d5d

commit 17609ba6bf8bea42e121f742fceea77308e50d5d
Author: Ali Alzyod 
Date:   Mon Sep 2 16:18:27 2019 +0200

example: fix compilation error

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi

Differential Revision: https://phab.enlightenment.org/D9815
---
 unsorted/elementary/efl_ui_list_example_1.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/unsorted/elementary/efl_ui_list_example_1.c 
b/unsorted/elementary/efl_ui_list_example_1.c
index b289ed5d..424044c6 100644
--- a/unsorted/elementary/efl_ui_list_example_1.c
+++ b/unsorted/elementary/efl_ui_list_example_1.c
@@ -302,14 +302,14 @@ elm_main(int argc, char **argv)
efl_text_set(scrl_btn, "Scroll Item");
efl_gfx_hint_align_set(scrl_btn, 0.5, 0.5);
efl_gfx_hint_size_min_set(scrl_btn, EINA_SIZE2D(200, 25));
-   efl_event_callback_add(scrl_btn, EFL_UI_EVENT_CLICKED, _scrl_btn_clicked, 
NULL);
+   efl_event_callback_add(scrl_btn, EFL_INPUT_EVENT_CLICKED, 
_scrl_btn_clicked, NULL);
efl_pack_end(rbox, scrl_btn);
 
scrl_btn  = efl_add(EFL_UI_BUTTON_CLASS, rbox);
efl_text_set(scrl_btn, "Scroll Item Align");
efl_gfx_hint_align_set(scrl_btn, 0.5, 0.5);
efl_gfx_hint_size_min_set(scrl_btn, EINA_SIZE2D(200, 25));
-   efl_event_callback_add(scrl_btn, EFL_UI_EVENT_CLICKED, 
_scrl_align_btn_clicked, NULL);
+   efl_event_callback_add(scrl_btn, EFL_INPUT_EVENT_CLICKED, 
_scrl_align_btn_clicked, NULL);
efl_pack_end(rbox, scrl_btn);
 
efl_pack_end(bbox, rbox);

-- 




[EGIT] [core/efl] master 01/01: evas_textblock: allocator use same heap if it is large enough

2019-09-16 Thread Ali Alzyod
sanghyeonlee pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f7cfd0f8339bcfa13a89a7ce0a1c005c77bf05c7

commit f7cfd0f8339bcfa13a89a7ce0a1c005c77bf05c7
Author: Ali Alzyod 
Date:   Thu Aug 29 18:43:00 2019 +0900

evas_textblock: allocator use same heap if it is large enough

Summary:
allocator use same heap if it is large enough

I am also think to move this struct/functionality into common place, I 
think we can use it in other parts too

Reviewers: smohanty, Hermet, bowonryu, SanghyeonLee

Reviewed By: smohanty, SanghyeonLee

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9770
---
 src/lib/evas/canvas/evas_object_textblock.c | 30 -
 1 file changed, 25 insertions(+), 5 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 433597fa27..5f8ae177fc 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -2897,12 +2897,17 @@ typedef struct _Allocator
 {
char   stack[ALLOCATOR_SIZE];
char  *heap;
+   size_t heap_size;
 } Allocator;
 
 static inline void
 _allocator_init(Allocator* allocator)
 {
-   if (allocator) allocator->heap = NULL;
+   if (allocator)
+ {
+allocator->heap = NULL;
+allocator->heap_size = 0;
+ }
 }
 
 static inline void
@@ -2912,6 +2917,7 @@ _allocator_reset(Allocator* allocator)
  {
 free(allocator->heap);
 allocator->heap = NULL;
+allocator->heap_size = 0;
  }
 }
 
@@ -2928,11 +2934,24 @@ _allocator_make_string(Allocator* allocator, const 
char* str, size_t size)
 return allocator->stack;
  }
//fallback to heap
-   if (allocator->heap) free(allocator->heap);
+   if (allocator->heap && allocator->heap_size < (size + 1))
+ {
+free(allocator->heap);
+allocator->heap = NULL;
+allocator->heap_size = 0;
+ }
 
-   allocator->heap = malloc(size + 1);
+   if (!allocator->heap)
+ {
+allocator->heap = malloc(size + 1);
+allocator->heap_size = (size + 1);
+ }
 
-   if (!allocator->heap) return NULL;
+   if (!allocator->heap)
+ {
+allocator->heap_size = 0;
+return NULL;
+ }
 
memcpy(allocator->heap, str, size);
allocator->heap[size] = '\0';
@@ -3099,8 +3118,9 @@ _format_fill(Evas_Object *eo_obj, 
Evas_Object_Textblock_Format *fmt, const char
   {
  /* immediate - not handled here */
   }
-_allocator_reset(&allocator);
  }
+
+   _allocator_reset(&allocator);
 }
 
 /**

-- 




[EGIT] [admin/devs] master 01/01: update geodata

2021-12-23 Thread ali-alzyod
ali-alzyod pushed a commit to branch master.

http://git.enlightenment.org/admin/devs.git/commit/?id=12e5f9f2f3209849f84188e8bfd5fe5ca018922c

commit 12e5f9f2f3209849f84188e8bfd5fe5ca018922c
Author: ali-alzyod 
Date:   Fri Dec 24 09:28:49 2021 +0200

update geodata
---
 developers/ali-alzyod/info.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/developers/ali-alzyod/info.txt b/developers/ali-alzyod/info.txt
index 0637fee..a0a8a2d 100644
--- a/developers/ali-alzyod/info.txt
+++ b/developers/ali-alzyod/info.txt
@@ -6,4 +6,4 @@ E-Mail:   ali198...@gmail.com
 WWW:  None
 Contributing: evas, elementary
 Platform: Ubuntu (Linux), Mac OS X, Windows XP/7
-GeoData:  31.9685349 35.829811
+GeoData:  31.9685349 35.829810

-- 




[EGIT] [core/efl] master 01/01: remove space

2021-12-23 Thread ali-alzyod
ali-alzyod pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=57b2bedac3a55805155bfdbbf67036a029a99d60

commit 57b2bedac3a55805155bfdbbf67036a029a99d60
Author: ali-alzyod 
Date:   Fri Dec 24 09:34:46 2021 +0200

remove space
---
 src/lib/evas/canvas/evas_object_textblock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 12bcd38eda..63ab1f4fe0 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -18016,7 +18016,7 @@ EVAS_API int 
evas_textblock_fit_step_size_set(Evas_Object *obj,  unsigned int st
 {
EINA_SAFETY_ON_NULL_RETURN_VAL(obj, EVAS_ERROR_INVALID_PARAM);
Efl_Canvas_Textblock_Data *o = efl_data_scope_get(obj, MY_CLASS);
-   TEXT_FIT_CONTENT_CONFIG * fc = &o->fit_content_config;
+   TEXT_FIT_CONTENT_CONFIG *fc = &o->fit_content_config;
if (fc->step_size == step_size)
  return EVAS_ERROR_SUCCESS;
 

-- 




Re: [E-devel] Things I have encounter while making a keyboard

2019-11-24 Thread Ali Al-Zyoud
""e" us not valid in EFL you should use """ semicolon should be
part of the escape word.

On Sun, Nov 24, 2019 at 1:50 PM michael bouchaud 
wrote:

> If you want to save some of your time to create a virtual keyboard. You
> could take a look into https://git.enlightenment.org/libs/ekbd.git/. It's
> a
> library who provide a keyboard smart evas object.
> The keyboard layout is described by plain text .kbd and .tie files. An
> exemple of use is also provided. The theme is based on edge so easy to
> customize. The key pressed is just an evas event, if you are on X you could
> use the function provided by the library if not you could make your own.
>
> Regards
>
> Le ven. 22 nov. 2019 09:54, Pablo Muñiz Gadea  a
> écrit :
>
> > Thank you so so much Hermet for the reply.
> >
> > ""e" is the first thing I tried. It does not work :( . I did what you
> > suggest. I only send this because I think its a big gotcha that in
> > edje text.text:
> > "\"" works but emit("key_pressed", "\""); doesn't.
> >
> >
> >
> > On Fri, Nov 22, 2019 at 1:49 AM Hermet Park 
> wrote:
> >
> > > Seems edje compiler doesn't care of slash + symbols  moment, How about
> > > sending markup name instead? i.e ""e"
> > > Probably you can remap the signal source to actual key name in the
> code.
> > >
> > > On Thu, Nov 21, 2019 at 8:59 PM Pablo Muñiz Gadea <
> pablomu...@gmail.com>
> > > wrote:
> > >
> > > > Hi guys.
> > > >
> > > > I have 1 problem with EDJE and 2 weird things. I will link the videos
> > so
> > > > you can see what I mean.
> > > >
> > > > On EDJE, displaying quotations on a text with text.text: "\""; works
> > > fine.
> > > > But when I try to send the signal with
> > > > script{
> > > > if(get_int(toggle_shift_state) == 0) {
> > > > emit("key_pressed", "2");
> > > > }
> > > > else {
> > > > *emit("key_pressed", "\"");*
> > > > }
> > > > }
> > > >
> > > > I get the error:
> > > >
> > > > edje_cc: Error. Parse error keyboard.edc:7242. { marker does not have
> > > > matching } marker
> > > > edje_cc: Error. PARSE STACK:
> > > > collections.group.programs.program.script
> > > > edje_cc: Error. PARAMS:
> > > >
> > > > BTW its not a {} problem.
> > > >
> > > > How can I escape that key in that instance?
> > > >
> > > > Next 2 videos are not important for me but I think it might help you.
> > > >
> > > > https://youtu.be/Ci42xl16Fhw
> > > > https://youtu.be/vEc-Xwlk4zU
> > > >
> > > > ___
> > > > enlightenment-devel mailing list
> > > > enlightenment-devel@lists.sourceforge.net
> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> > > >
> > >
> > >
> > > --
> > > Regards, Hermet
> > >
> > > ___
> > > enlightenment-devel mailing list
> > > enlightenment-devel@lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> > >
> >
> > ___
> > enlightenment-devel mailing list
> > enlightenment-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >
>
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>

___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[E-devel] Developer access request

2020-03-16 Thread Ali Al-Zyoud
Dears,

I would like to request for developer access for myself.
I work mainly on text related stuff, and I think this request could help
the community to speed-up in this area.

If you agree please let me know with +1, and if you do not agree let me
know with -1
Also giving me your opinion if possible.


Have a nice day :)



*ThanksAli Alzyod*

___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] EFL 1.24 first abi checker results (beta2)

2020-04-23 Thread Ali Al-Zyoud
Hello,

For Efl_Canvas_Text and Efl_Text_Cursor_Cursor, I do not think they are
supposed to be used anyway especially in a Legacy application (also they
were beta anyway), but the defines leaked out from headers.

Thanks
Ali Alzyod

On Thu, Apr 23, 2020 at 12:16 PM Jean Rene Dawin <
jda...@math.uni-bielefeld.de> wrote:

> Jean Rene Dawin wrote on Wed 22/04/20 19:19:
> > Stefan Schmidt wrote on Wed 22/04/20 14:05:
> > > Hello Jean Rene.
> > >
> > > On 22.04.20 08:27, Jean Rene Dawin wrote:
> > > > Stefan Schmidt wrote on Wed 15/04/20 15:48:
> > > > > Hello.
> > > > >
> > > > If my code has this:
> > > >
> > > > Efl_Canvas_Text *bla;
> > > >
> > > > it compiles well with 1.23.3 but 1.24 gives
> > > >
> > > > unknown type name 'Efl_Canvas_Text'
> > > >
> > >
> > > Thanks a lot for bringing this to our attention. Sorry for missing it
> in the
> > > first place. After some discussion with Marcel Ali came up with a
> patch that
> > > should fix the problem for you.
> > >
> > > This should fix your problem:
> > > https://phab.enlightenment.org/D11744
> > >
> > > I am going to push this now. Please let us know if it is working
> correctly
> > > afterwards for you.
> > >
> > > regards
> > > Stefan Schmidt
> >
> > Thanks. Honestly I don't have code that is affected right now.
> > I just was curious if the warnings of the ABI checker were all harmless
> and did a test
> > with the code above.
> >
> > Regards,
> > Jean Rene
>
> Ok, with f619a2fbad2dcc81085f14cedaea4fc0df8f2837 Efl_Canvas_Text is
> fixed.
>
> I'm still not sure if a program is supposed to use these types directly
> in the first place.
>
> Similar issues occur with these types:
>Efl_Canvas_Vg_Container
>Efl_Canvas_Vg_Node
>Efl_Text_Cursor_Cursor
>
> Regards,
> Jean Rene
>
>
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>

___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Committer access proposal: ali.alzyod (Ali Alzyod)

2020-09-28 Thread Ali Al-Zyoud
Hi @raster

===
e.org moved from e6 back to e5 a few months ago as an emergency measure when
e.org broke again and i had to quickly move everything to e5 and set it all
up.
i spent a few days doing that but i didn't re-set up automatic developer
account management (it's a bit complicated :)). it's something still to do,
so
this will have to wait for some spare time for me to dig into that. it'
actually hasn't been necessary for quite a while which is why it was not
high
priority :)
===

Have these access rights have been granted? or still, it needs to be done
whenever I try to git push I get,
=

Total 6 (delta 5), reused 0 (delta 0)

remote: FATAL: W refs/heads/master core/efl ali-alzyod DENIED by fallthru

remote: error: hook declined to update refs/heads/master

To git+ssh://git.enlightenment.org/core/efl.git

 ! [remote rejected]   master -> master (hook declined)
error: failed to push some refs to 'git+ssh://git@
git.enlightenment.org/core/efl.git' 

Thanks
Ali Alzyod

On Tue, Mar 31, 2020 at 2:36 PM Jonathan Aquilina 
wrote:

> Hi Carsten,
>
> Not to hijack this thread but I still need to test out the vpn access you
> had requested for me. Infra wise where do we stand are we still on gentoo?
> Feel free to email me directly to discuss.
>
>
>
>
> -Original Message-
> From: Carsten Haitzler 
> Sent: Tuesday, 31 March 2020 13:32
> To: Enlightenment developer list <
> enlightenment-devel@lists.sourceforge.net>
> Subject: Re: [E-devel] Committer access proposal: ali.alzyod (Ali Alzyod)
>
> On Tue, 31 Mar 2020 20:02:05 +0900 woohyun said:
>
> > @raster
> > Woops !!  What happen  ?!?!
>
> bear wrestling! the bear came off second best of course! :)
>
> > Are you ok now ? I  really hope you will be recovered soon.
>
> well it'll take time. i'm told 6-12 months to be kind-of back to normal
> and in a few years i should be totally back, but i just went from "severely
> limited"
> last friday to "i have my arm back - but now with metal, screws and a scar
> and very limited movement in my wrist". i need to exercise movement to get
> it back but it can be a bit of a strain, so i can't do it as much as i used
> to.
>
> > Plus, I really appreciate for sharing the information in your worst
> > situation for typing.
>
> I'm back to typing again as of last friday - but am keeping myself to at
> most maybe ~8-9 keyboard hours a day (still need to work).
>
> e.org moved from e6 back to e5 a few months ago as an emergency measure
> when e.org broke again and i had to quickly move everything to e5 and set
> it all up.
> i spent a few days doing that but i didn't re-set up automatic developer
> account management (it's a bit complicated :)). it's something still to do,
> so this will have to wait for some spare time for me to dig into that. it'
> actually hasn't been necessary for quite a while which is why it was not
> high priority :)
>
> > -Original Message-
> > From: "Carsten Haitzler"
> > To: "Enlightenment developer
> > list";
> > Cc: "woohyun";
> > Sent: 2020-03-31 (화) 18:54:20 (GMT+09:00)
> > Subject: Re: [E-devel] Committer access proposal: ali.alzyod (Ali
> > Alzyod)
> >
> > On Tue, 31 Mar 2020 13:25:42 +0900 woohyun said:
> >
> > not so fast... :) no dev access changes happen unless i do them
> > manually currently. i've been essentially off unable to do much in the
> > past 6 weeks or so due to broken arm and wrist and surgery on my right
> > hand/arm. i just got out of the bandages and cast with my new
> > adamantine wolverine claws embedded in my right arm. :)
> >
> > > Since there has been no objection, I registered him as a EFL
> > > developer :)
> > >
> > > @ali.alzyod Welcome and Congrats :)
> > >
> > > -Original Message-
> > > From: "cnook"
> > > To: "Enlightenment developer
> > > list"; Cc:
> > > Sent: 2020-03-19 (목) 09:58:29 (GMT+09:00)
> > > Subject: Re: [E-devel] Committer access proposal: ali.alzyod (Ali
> > > Alzyod)
> > >
> > > +1
> > >
> > > Yes he is. I actually got valuable opinions regarding color related
> thing.
> > > Thank you.
> > >
> > > 2020년 3월 17일 (화) 오후 3:12, Hermet Park 님이 작성:
> > >
> > > > +1
> > > >
> > > > On Tue, Mar 17, 2020 at 2:11 PM woohyun 
> wrote:
> > > >
> > > > > Hello. Everyone here :)
> > > > >
> 

Re: [E-devel] Committer access proposal: ali.alzyod (Ali Alzyod)

2020-09-28 Thread Ali Al-Zyoud
Yes I am using the right keys,
Also when I am calling
ssh -T git@git.enlightenment.
it returns

hello ali-alzyod. this is git@e5 running  etc

So I think keys are fine, but there are some privilege that does not allow
me to push code there

On Mon, Sep 28, 2020 at 2:45 PM Carsten Haitzler 
wrote:

> On Mon, 28 Sep 2020 13:39:19 +0300 Ali Al-Zyoud 
> said:
>
> > Hi @raster
> >
> > ===
> > e.org moved from e6 back to e5 a few months ago as an emergency measure
> when
> > e.org broke again and i had to quickly move everything to e5 and set it
> all
> > up.
> > i spent a few days doing that but i didn't re-set up automatic developer
> > account management (it's a bit complicated :)). it's something still to
> do,
> > so
> > this will have to wait for some spare time for me to dig into that. it'
> > actually hasn't been necessary for quite a while which is why it was not
> > high
> > priority :)
> > ===
> >
> > Have these access rights have been granted? or still, it needs to be done
> > whenever I try to git push I get,
>
> yes. its' st up. the ssh pub key files that are in your devs dir are what
> are
> actively allowed. i checked already. are you using the private keys that
> match
> those pub keys?
>
> > =
> >
> > Total 6 (delta 5), reused 0 (delta 0)
> >
> > remote: FATAL: W refs/heads/master core/efl ali-alzyod DENIED by fallthru
> >
> > remote: error: hook declined to update refs/heads/master
> >
> > To git+ssh://git.enlightenment.org/core/efl.git
> >
> >  ! [remote rejected]   master -> master (hook declined)
> > error: failed to push some refs to 'git+ssh://git@
> > git.enlightenment.org/core/efl.git' 
> >
> > Thanks
> > Ali Alzyod
> >
> > On Tue, Mar 31, 2020 at 2:36 PM Jonathan Aquilina <
> jaquil...@eagleeyet.net>
> > wrote:
> >
> > > Hi Carsten,
> > >
> > > Not to hijack this thread but I still need to test out the vpn access
> you
> > > had requested for me. Infra wise where do we stand are we still on
> gentoo?
> > > Feel free to email me directly to discuss.
> > >
> > >
> > >
> > >
> > > -Original Message-
> > > From: Carsten Haitzler 
> > > Sent: Tuesday, 31 March 2020 13:32
> > > To: Enlightenment developer list <
> > > enlightenment-devel@lists.sourceforge.net>
> > > Subject: Re: [E-devel] Committer access proposal: ali.alzyod (Ali
> Alzyod)
> > >
> > > On Tue, 31 Mar 2020 20:02:05 +0900 woohyun
> said:
> > >
> > > > @raster
> > > > Woops !!  What happen  ?!?!
> > >
> > > bear wrestling! the bear came off second best of course! :)
> > >
> > > > Are you ok now ? I  really hope you will be recovered soon.
> > >
> > > well it'll take time. i'm told 6-12 months to be kind-of back to normal
> > > and in a few years i should be totally back, but i just went from
> "severely
> > > limited"
> > > last friday to "i have my arm back - but now with metal, screws and a
> scar
> > > and very limited movement in my wrist". i need to exercise movement to
> get
> > > it back but it can be a bit of a strain, so i can't do it as much as i
> used
> > > to.
> > >
> > > > Plus, I really appreciate for sharing the information in your worst
> > > > situation for typing.
> > >
> > > I'm back to typing again as of last friday - but am keeping myself to
> at
> > > most maybe ~8-9 keyboard hours a day (still need to work).
> > >
> > > e.org moved from e6 back to e5 a few months ago as an emergency
> measure
> > > when e.org broke again and i had to quickly move everything to e5 and
> set
> > > it all up.
> > > i spent a few days doing that but i didn't re-set up automatic
> developer
> > > account management (it's a bit complicated :)). it's something still
> to do,
> > > so this will have to wait for some spare time for me to dig into that.
> it'
> > > actually hasn't been necessary for quite a while which is why it was
> not
> > > high priority :)
> > >
> > > > -Original Message-
> > > > From: "Carsten Haitzler"
> > > > To: "Enlightenment developer
> > > > list";
> > > > Cc: "wooh

Re: [E-devel] [EGIT] [core/efl] master 01/01: evas_textblock: rainbow flag emoji treated as two clusters(update unibreak to version 4.2)

2020-10-04 Thread Ali Al-Zyoud
Hello,

Can we un-revert this patch now?

Thanks
Ali Alzyod

On Wed, Sep 2, 2020 at 9:56 AM Stefan Schmidt 
wrote:

> Hello.
>
> On 01.09.20 15:10, Ali Al-Zyoud wrote:
> > Dear Stefan,
> >
> >> Also, the static lib update should be a standalone patch and not mixed
> >> in with a evas feature.
> > Actually updating static library alone is not possible unless you made
> some
> > changes in Evas, since this will break compatibility (ninja test will
> fail
> > too), so evas feature is related to updating the lib, and they need to
> done
> > together.
>
> Fair enough. So the patch as-is can go in again after the freeze.
>
> regards
> Stefan Schmidt
>
>
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>

___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Detecting textblock reflow?

2024-02-05 Thread Ali Al-Zyoud
Hello David,

It has been ages since I touch text-block code :-) , so I will try to
remember things well.

TextBlock internally layout and calculates the text size, and how it will
fit internally.
there could be some conditions that prevent it from calculating, like if it
is visible or not (to save process time).
Also is there text.


So first question fo you see the text inside textBlock  ?
Also if you can share some code snippets or sample projects on get it might
help.

At anytime, you can check how these functions are used inside the test file
`src/tests/evas/evas_test_textblock.c`



*ThanksAli Alzyod*





On Mon, Feb 5, 2024 at 7:23 PM David Grubb 
wrote:

> Hi everybody,
>
> I'm hacking on a small project and I'm curious about some of the attributes
> of the TextBlock object that I'm not understanding from the documents. Is
> it possible to programmatically detect the geometry of the rendered text
> within a TextBlock?
>
> Say, I have a non-monospaced font, I've loaded some string content and want
> to know how much of the allotted TextBlock that's filled. Or, I want to
> know things like whether the text has overflowed and ellipsis are now being
> applied, that kind of thing.
>
> I thought that's what evas_object_textblock_size_formatted_get() and
> evas_object_textblock_size_native_get() were about but I just get values of
> zero for the Evas_Coords I pass in.
>
> Cheers,
> Dave.
>
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>

___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel