On Sun, Aug 8, 2010 at 2:37 PM, Tom Hacohen <tom.haco...@partner.samsung.com> wrote: > On Sun, 2010-08-08 at 09:33 +0800, Brian Wang wrote: >> Hello Tom, >> >> Thanks for looking into this problem. >> >> Is r50887 fresh enough? r50887 is what I first tried and failed. >> I reverted evas to r50594 and r50595 (while all other EFL libraries >> stay at r50887) to confirm it's the r50595 commit the causes this >> problem. >> METRIC_CACHE and WORD_CACHE are not enabled in all cases (they're >> disabled by default, I believe). >> >> I am not sure if you performed the same test I did. If you use the >> source code attached previously, you have to click on elm_entry and >> check the stdout output (preferably with gdb to show the returned >> strings in bytes). > > It seems I didn't perform the same test, mind explaining exactly what > you did? I just tried entering chinese characters and saw everything is > fine. :)
Hello Tom, Please use the test source code I previously attached. ** Within the elm_entry object (three chinese characters in the front, followed by some english letters), click with your mouse on any of the chinese characters at the start of the string and check stdout. There are garbage characters returned. I guess the problem is somehow with the usage of Eina_Unicode. Are Eina_Unicode strings the same as the usual UTF-8 strings? Please find below the backtrace of gdb (r50595 evas) for your investigation. The new evas_common_font_query_char_at_coords() returns the INDEX of the CHARACTER, while the old evas_common_font_query_text_at_pos() returns the INDEX of the BYTE of the start of the character. This returned value is kept as _Evas_Textblock_Cursor's pos. Does 'pos' mean the number of bytes into the string or the number of character into the string? I guess the recent discussion of the docs would help here. :-) ----------------------------------------------- Breakpoint 1, evas_common_font_query_char_at_coords (fn=0x80e7f20, in_text=0x8176dd8 L"中英混合 english mixed with c", intl_props=0x80da6e4, x=68, y=0, cx=0xbfffef94, cy=0xbfffef90, cw=0xbfffef8c, ch=0xbfffef88) at evas_font_query.c:466 466 int char_index = 0; /* the index of the current char */ (gdb) bt #0 evas_common_font_query_char_at_coords (fn=0x80e7f20, in_text=0x8176dd8 L"中英混合 english mixed with c", intl_props=0x80da6e4, x=68, y=0, cx=0xbfffef94, cy=0xbfffef90, cw=0xbfffef8c, ch=0xbfffef88) at evas_font_query.c:466 #1 0xb7fc52c2 in eng_font_char_at_coords_get (data=0x807a200, font=0x80e7f20, text=0x8176dd8 L"中英混合 english mixed with c", intl_props=0x80da6e4, x=68, y=0, cx=0xbfffef94, cy=0xbfffef90, cw=0xbfffef8c, ch=0xbfffef88) at evas_engine.c:1024 #2 0xb7f32e4b in evas_textblock_cursor_char_coord_set (cur=0x80e5a30, x=68, y=11) at evas_object_textblock.c:5195 #3 0xb792424f in _edje_part_mouse_up_cb (data=0x80c6640, e=0x8077488, obj=0x80e58f8, event_info=0xbffff094) at edje_entry.c:1687 #4 0xb7ef41d9 in evas_object_event_callback_call (obj=0x80e58f8, type=EVAS_CALLBACK_MOUSE_UP, event_info=0xbffff094) at evas_callbacks.c:220 #5 0xb7ef6e4f in evas_event_feed_mouse_up (e=0x8077488, b=1, flags=EVAS_BUTTON_NONE, timestamp=976110, data=0x0) at evas_events.c:412 #6 0xb7943962 in _ecore_event_evas_mouse_button (e=0x817cac0, press=ECORE_UP) at ecore_input_evas.c:161 #7 0xb7943bfc in ecore_event_evas_mouse_button_up (data=0x0, type=21, event=0x817cac0) at ecore_input_evas.c:203 #8 0xb7ebaffe in _ecore_event_call () at ecore_events.c:577 #9 0xb7ec0e39 in _ecore_main_loop_iterate_internal (once_only=0) at ecore_main.c:1031 #10 0xb7ebfd5c in ecore_main_loop_begin () at ecore_main.c:275 #11 0xb7dff68f in elm_run () at elm_main.c:862 #12 0x08048e00 in elm_main (argc=1, argv=0xbffff354) at elm-entry.c:74 #13 0x08048e39 in main (argc=1, argv=0xbffff354) at elm-entry.c:80 ----------------------------------------------- > > -- > Tom. > > -- brian ------------------ Cool-Karaoke - The smallest recording studio, in your palm, open-sourced http://cool-idea.com.tw/ iMaGiNaTiOn iS mOrE iMpOrTaNt tHaN kNoWlEdGe ------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel