summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYakov Goldberg <yakov.g@samsung.com>2013-04-11 19:47:51 +0300
committerYakov Goldberg <yakov.g@samsung.com>2013-04-14 18:04:26 +0300
commit3468b9ffc39d80aa61cc497f37514c81148b3679 (patch)
treef32ca3b01ee639254d0cf0ac5967c4af7dd4932b
parent5ba104b46e2e0f2e3f47e924d75799907cb73ab3 (diff)
downloadefl-3468b9ffc39d80aa61cc497f37514c81148b3679.tar.gz
Evas textblock: fix tests, disabled in 0d68ffbe
- change "fail_if" to "ck_assert_int_*", because it prints error message with values - fixing usage of embedding LTR/RTL codes Signed-off-by: Yakov Goldberg <yakov.g@samsung.com>
-rw-r--r--src/tests/evas/evas_test_textblock.c240
1 files changed, 116 insertions, 124 deletions
diff --git a/src/tests/evas/evas_test_textblock.c b/src/tests/evas/evas_test_textblock.c
index 173b85df7a..07d288f521 100644
--- a/src/tests/evas/evas_test_textblock.c
+++ b/src/tests/evas/evas_test_textblock.c
@@ -26,7 +26,7 @@ _evas_textblock_format_offset_get(const Evas_Object_Textblock_Node_Format *n);
#define TEST_FONT "font=TEST_FONT fount_source" TESTS_SRC_DIR "./DejaVuSans.eet"
static const char *style_buf =
- "DEFAULT='" TEST_FONT " font_size=10 color=#000 text_class=entry'"
+ "DEFAULT='" TEST_FONT " font_size=40 color=#000 text_class=entry'"
"newline='br'"
"b='+ font=Sans:style=bold'";
@@ -612,105 +612,105 @@ START_TEST(evas_textblock_cursor)
for (i = 0 ; i < 2 ; i++)
{
evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
- ck_assert_int_eq(w, 3);
+ ck_assert_int_eq(w, 13);
evas_textblock_cursor_char_next(cur);
}
evas_textblock_cursor_char_next(cur);
- for (i = 0 ; i < 3 ; i++)
+ for (i = 0 ; i < 2 ; i++)
{
evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
- ck_assert_int_eq(w, 3);
+ ck_assert_int_eq(w, 13);
evas_textblock_cursor_char_next(cur);
}
+ evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
+ ck_assert_int_eq(w, 12);
#else
-/* FIXME: Disabled because fails on jenkins */
-#if 0
evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
- ck_assert_int_eq(w, 4);
+ ck_assert_int_eq(w, 15);
evas_textblock_cursor_char_next(cur);
evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
- ck_assert_int_eq(w, 3);
+ ck_assert_int_eq(w, 12);
evas_textblock_cursor_pos_set(cur, 3);
evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
- ck_assert_int_eq(w, 4);
+ ck_assert_int_eq(w, 15);
for (i = 0 ; i < 2 ; i++)
{
evas_textblock_cursor_char_next(cur);
evas_textblock_cursor_pen_geometry_get(cur, NULL, NULL, &w, NULL);
- ck_assert_int_eq(w, 3);
+ ck_assert_int_eq(w, 12);
}
#endif
-#endif
}
END_TB_TEST();
}
END_TEST
-/* FIXME: Disabled because fails on jenkins */
-#if 0
+#ifdef HAVE_FRIBIDI
START_TEST(evas_textblock_split_cursor)
{
-#ifdef HAVE_FRIBIDI
START_TB_TEST();
Evas_Coord x, w, x2, w2;
Evas_Coord nw, nh;
Evas_Coord cx, cy, cx2, cy2;
- /* Split cursor in LTR paragraph. */
- /*0123456789 10 123 14 5678901234 */
- evas_object_textblock_text_markup_set(tb, "test נסיון\u202babc\u202cנסיון bang");
+ /* Split cursor in LTR paragraph.
+ * Russian 't' in the beginnning to create additional item.*/
+ /*01234 5 6789012345678 19 01234 */
+ evas_object_textblock_text_markup_set(tb, "тest \u202bנסיוןabcנסיון\u202c bang");
evas_object_textblock_size_native_get(tb, &nw, &nh);
evas_object_resize(tb, nw, nh);
/* Logical cursor after "test " */
- evas_textblock_cursor_pos_set(cur, 5);
+ evas_textblock_cursor_pos_set(cur, 6);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 4);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
- evas_textblock_cursor_pos_set(cur, 5);
- evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
- fail_if(cx != (x + w));
- fail_if(cx2 != (x2 + w2));
-
- /* Logical cursor before " bang" */
- evas_textblock_cursor_pos_set(cur, 20);
+ evas_textblock_cursor_pos_set(cur, 18);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
- NULL, &cx2, NULL, NULL, NULL,
- EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 19);
+ evas_textblock_cursor_pos_set(cur, 20);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
- fail_if(cx != x);
- fail_if(cx2 != x2);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
/* Logical cursor before "a" */
evas_textblock_cursor_pos_set(cur, 11);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 9);
+ evas_textblock_cursor_pos_set(cur, 11);
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
+ evas_textblock_cursor_pos_set(cur, 10);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
- fail_if(cx != x);
- fail_if(cx2 != x2);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
/* Logical cursor after "c" */
- evas_textblock_cursor_pos_set(cur, 15);
- evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
+ evas_textblock_cursor_pos_set(cur, 14);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 13);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
- fail_if(cx != (x + w));
- fail_if(cx2 != (x2 + w2));
+ evas_textblock_cursor_pos_set(cur, 10);
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
+ evas_textblock_cursor_pos_set(cur, 11);
+ evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
+
+ /* Logical cursor before " bang" */
+ evas_textblock_cursor_pos_set(cur, 20);
+ fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
+ NULL, &cx2, NULL, NULL, NULL,
+ EVAS_TEXTBLOCK_CURSOR_BEFORE));
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
+ evas_textblock_cursor_pos_set(cur, 19);
+ evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
/* Logical cursor in the beginning */
evas_textblock_cursor_line_char_first(cur);
@@ -718,80 +718,77 @@ START_TEST(evas_textblock_split_cursor)
NULL, NULL, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
/* Logical cursor in the end */
evas_textblock_cursor_line_char_last(cur);
fail_if(evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, NULL, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 24);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
- fail_if(cx != (x + w));
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
+ ck_assert_int_eq(cx, x);
- /* Logical cursor on the first pos */
- evas_textblock_cursor_pos_set(cur, 1);
+ /* Logical cursor on the second pos */
+ evas_textblock_cursor_pos_set(cur, 2);
fail_if(evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, NULL, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
/* Split cursor in RTL paragraph. */
- /* 1 2
- 0123456789 0 12345 6 7890123456 */
- evas_object_textblock_text_markup_set(tb, "שלום test \u202aעברית\u202c efl נסיון");
+ /* 1 2
+ 01234 5 67890123456789 0 123456 */
+ evas_object_textblock_text_markup_set(tb, "שלום \u202atest עברית efl\u202c נסיון");
evas_object_textblock_size_native_get(tb, &nw, &nh);
evas_object_resize(tb, nw, nh);
/* Logical cursor before "test" */
- evas_textblock_cursor_pos_set(cur, 4);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
- evas_textblock_cursor_pos_set(cur, 5);
-
+ evas_textblock_cursor_pos_set(cur, 6);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 5);
- evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
- fail_if(cx != x);
- fail_if(cx2 != x2);
-
- /* Logical cursor after " efl" */
- evas_textblock_cursor_pos_set(cur, 21);
+ evas_textblock_cursor_pos_set(cur, 4);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
+ evas_textblock_cursor_pos_set(cur, 6);
+ evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
+ /* Logical cursor after "test " */
+ evas_textblock_cursor_pos_set(cur, 11);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 20);
+ evas_textblock_cursor_pos_set(cur, 16);
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
+ evas_textblock_cursor_pos_set(cur, 15);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
- fail_if(cx != (x + w));
- fail_if(cx2 != (x2 + w2));
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
/* Logical cursor before " efl" */
- evas_textblock_cursor_pos_set(cur, 17);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
-
+ evas_textblock_cursor_pos_set(cur, 16);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
evas_textblock_cursor_pos_set(cur, 15);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
fail_if(cx != x2);
fail_if(cx2 != x);
- /* Logical cursor after "test " */
- evas_textblock_cursor_pos_set(cur, 11);
- evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
-
+ /* Logical cursor after " efl" */
+ evas_textblock_cursor_pos_set(cur, 21);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 9);
- evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
- fail_if(cx != (x + w));
- fail_if(cx2 != (x2 + w2));
+ evas_textblock_cursor_pos_set(cur, 6);
+ evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
+ evas_textblock_cursor_pos_set(cur, 4);
+ evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
/* Logical cursor in the beginning */
evas_textblock_cursor_line_char_first(cur);
@@ -808,16 +805,14 @@ START_TEST(evas_textblock_split_cursor)
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_pos_set(cur, 26);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
/* Corner cases for split cursor. */
- /* End of line in LTR paragraph */
- /* 1
- 01234567890123 4 567 */
- evas_object_textblock_text_markup_set(tb, "test נסיוןشسيب\u202babc");
- evas_textblock_cursor_line_char_last(cur);
- evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
+ /* End of line in LTR paragraph with embedding*/
+ /* 1
+ 01234 5 678901234567 */
+ evas_object_textblock_text_markup_set(tb, "test \u202bנסיוןشسيبabc");
evas_object_textblock_size_native_get(tb, &nw, &nh);
evas_object_resize(tb, nw, nh);
@@ -825,17 +820,17 @@ START_TEST(evas_textblock_split_cursor)
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, &cx2, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
- evas_textblock_cursor_pos_set(cur, 4);
- evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
- evas_textblock_cursor_pos_set(cur, 5);
+ evas_textblock_cursor_pos_set(cur, 15);
+ evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
+ evas_textblock_cursor_pos_set(cur, 6);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
fail_if(cx != (x + w));
- fail_if(cx2 != (x2 + w2));
+ ck_assert_int_eq(cx2, x2);
/* End of line in RTL paragraph */
- /* 1 2
- 0123456789012345678 9 0123 */
- evas_object_textblock_text_markup_set(tb, "נסיוןشسي testпривет\u202aשלום");
+ /* 1 2
+ 012345678 9 01234567890123 */
+ evas_object_textblock_text_markup_set(tb, "נסיוןشسي \u202atestприветשלום");
evas_object_textblock_size_native_get(tb, &nw, &nh);
evas_object_resize(tb, nw, nh);
@@ -845,18 +840,18 @@ START_TEST(evas_textblock_split_cursor)
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_pos_set(cur, 8);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
- evas_textblock_cursor_pos_set(cur, 9);
+ evas_textblock_cursor_pos_set(cur, 10);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
- fail_if(cx2 != x2);
+ ck_assert_int_eq(cx, x);
+ ck_assert_int_eq(cx2, x2);
/* Cursor is between items of the same direction */
- evas_textblock_cursor_pos_set(cur, 13);
+ evas_textblock_cursor_pos_set(cur, 14);
fail_if(evas_textblock_cursor_geometry_bidi_get(cur, &cx, NULL, NULL,
NULL, NULL, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
/* Cursor type is UNDER */
evas_textblock_cursor_pos_set(cur, 0);
@@ -864,7 +859,7 @@ START_TEST(evas_textblock_split_cursor)
NULL, NULL, NULL, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_UNDER));
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
/* Multiline */
Evas_Coord ly;
@@ -884,14 +879,14 @@ START_TEST(evas_textblock_split_cursor)
NULL, &cx2, &cy2, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy != ly);
+ ck_assert_int_eq(cy, ly);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
evas_textblock_cursor_pos_set(cur, 11);
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy2 != ly);
+ ck_assert_int_eq(cy2, ly);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
- fail_if(cx2 != x2);
+ ck_assert_int_eq(cx2, x2);
}
/* 01234567890123456789 */
evas_object_textblock_text_markup_set(tb, "<wrap=char>נסיוןhelloприветשלום");
@@ -902,18 +897,17 @@ START_TEST(evas_textblock_split_cursor)
for (i = 0; i < nw; i++)
{
evas_object_resize(tb, i, nh);
-
evas_textblock_cursor_pos_set(cur, 16);
fail_if(!evas_textblock_cursor_geometry_bidi_get(cur, &cx, &cy, NULL,
NULL, &cx2, &cy2, NULL, NULL,
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy != ly);
+ ck_assert_int_eq(cy, ly);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
fail_if(cx != (x + w));
evas_textblock_cursor_pos_set(cur, 15);
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy2 != ly);
+ ck_assert_int_eq(cy2, ly);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
fail_if(cx2 != (x2 + w2));
}
@@ -938,13 +932,13 @@ START_TEST(evas_textblock_split_cursor)
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, &w, NULL);
fail_if(cx != (x + w));
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy != ly);
+ ck_assert_int_eq(cy, ly);
evas_textblock_cursor_pos_set(cur, 23);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, NULL, NULL);
- fail_if(cx2 != x2);
+ ck_assert_int_eq(cx2, x2);
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy2 != ly);
+ ck_assert_int_eq(cy2, ly);
/* Testing multiline, when only LTR item is in the line. */
/* 012345678901234567890123 */
@@ -964,18 +958,17 @@ START_TEST(evas_textblock_split_cursor)
EVAS_TEXTBLOCK_CURSOR_BEFORE));
evas_textblock_cursor_pos_set(cur, 16);
evas_textblock_cursor_pen_geometry_get(cur, &x, NULL, NULL, NULL);
- fail_if(cx != x);
+ ck_assert_int_eq(cx, x);
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy != ly);
+ ck_assert_int_eq(cy, ly);
- evas_textblock_cursor_pos_set(cur, 23);
+ evas_textblock_cursor_line_char_last(cur);
evas_textblock_cursor_pen_geometry_get(cur, &x2, NULL, &w2, NULL);
- fail_if(cx2 != (x2 + w2));
+ ck_assert_int_eq(cx2, x2);
evas_textblock_cursor_line_geometry_get(cur, NULL, &ly, NULL, NULL);
- fail_if(cy2 != ly);
+ ck_assert_int_eq(cy2, ly);
END_TB_TEST();
-#endif
}
END_TEST
#endif
@@ -1439,21 +1432,21 @@ START_TEST(evas_textblock_items)
/* Relsize */
/* relsize means it should adjust itself to the size of the line */
- buf = "This is an <item relsize=93x152 vsize=full></>.";
+ buf = "This is an <item relsize=330x152 vsize=full></>.";
evas_object_textblock_text_markup_set(tb, buf);
evas_object_textblock_size_formatted_get(tb, &w, &h);
- fail_if((w >= 93) || (h >= 152));
+ fail_if((w >= 330) || (h >= 152));
evas_textblock_cursor_pos_set(cur, 11);
evas_textblock_cursor_format_item_geometry_get(cur, NULL, NULL, &w, &ih);
- fail_if((w > 90) || (h != ih));
+ fail_if((w > 108) || (h != ih));
- buf = "This is an <item relize=93x152 vsize=ascent></>.";
+ buf = "This is an <item relize=330x152 vsize=ascent></>.";
evas_object_textblock_text_markup_set(tb, buf);
evas_object_textblock_size_formatted_get(tb, &w, &h);
- fail_if((w >= 93) || (h >= 152));
+ fail_if((w >= 330) || (h >= 152));
evas_textblock_cursor_pos_set(cur, 11);
evas_textblock_cursor_format_item_geometry_get(cur, NULL, NULL, &w, &ih);
- fail_if((w > 90) || (h <= ih));
+ fail_if((w > 108) || (h <= ih));
/* Relsize and abs size in the same line, all should be the same size */
buf = "<item relsize=64x64 vsize=ascent href=emoticon/knowing-grin></item><item absize=64x64 vsize=ascent href=emoticon/knowing-grin></item><item relsize=64x64 vsize=ascent href=emoticon/knowing-grin></item>";
@@ -2313,7 +2306,7 @@ START_TEST(evas_textblock_formats)
evas_object_textblock_text_markup_set(tb, "Test");
evas_object_textblock_size_formatted_get(tb, &w, &h);
evas_textblock_cursor_paragraph_first(cur);
- evas_textblock_cursor_format_prepend(cur, "+ font_size=40");
+ evas_textblock_cursor_format_prepend(cur, "+ font_size=50");
evas_object_textblock_size_formatted_get(tb, &nw, &nh);
fail_if((w >= nw) || (h >= nh));
}
@@ -2428,7 +2421,7 @@ START_TEST(evas_textblock_style)
newst = evas_textblock_style_new();
fail_if(!newst);
evas_textblock_style_set(newst,
- "DEFAULT='" TEST_FONT " font_size=20 color=#000 text_class=entry'"
+ "DEFAULT='" TEST_FONT " font_size=50 color=#000 text_class=entry'"
"br='\n'"
"ps='ps'"
"tab='\t'");
@@ -2650,8 +2643,7 @@ void evas_test_textblock(TCase *tc)
{
tcase_add_test(tc, evas_textblock_simple);
tcase_add_test(tc, evas_textblock_cursor);
-/* FIXME: Disabled because fails on jenkins */
-#if 0
+#ifdef HAVE_FRIBIDI
tcase_add_test(tc, evas_textblock_split_cursor);
#endif
tcase_add_test(tc, evas_textblock_size);