forked from enlightenment/efl
parent
5856cddd6f
commit
24cb66cd71
|
@ -7,7 +7,7 @@ Release: 1
|
|||
License: BSD
|
||||
Group: System Environment/Libraries
|
||||
URL: http://www.enlightenment.org/
|
||||
Source: %{name}-%{version}_pre13.tar.gz
|
||||
Source: %{name}-%{version}.tar.gz
|
||||
Packager: %{?_packager:%{_packager}}%{!?_packager:Michael Jennings <mej@eterm.org>}
|
||||
Vendor: %{?_vendorinfo:%{_vendorinfo}}%{!?_vendorinfo:The Enlightenment Project (http://www.enlightenment.org/)}
|
||||
Distribution: %{?_distribution:%{_distribution}}%{!?_distribution:%{_vendor}}
|
||||
|
|
|
@ -974,6 +974,7 @@ evas_object_textblock_layout_internal(Evas_Object *obj, int w, int h, int *forma
|
|||
int pad_l = 0, pad_r = 0, pad_t = 0, pad_b = 0;
|
||||
int marginl = 0, marginr = 0;
|
||||
int ww, hh;
|
||||
int just_wrapped = 0;
|
||||
|
||||
o = (Evas_Object_Textblock *)(obj->object_data);
|
||||
ww = w;
|
||||
|
@ -1266,6 +1267,16 @@ evas_object_textblock_layout_internal(Evas_Object *obj, int w, int h, int *forma
|
|||
|
||||
text = strdup(node->text);
|
||||
new_node:
|
||||
if (just_wrapped)
|
||||
{
|
||||
int pos, chr;
|
||||
|
||||
pos = 0;
|
||||
chr = evas_common_font_utf8_get_next(text, &pos);
|
||||
if (evas_object_textblock_char_is_white(chr))
|
||||
strcpy(text, text + pos);
|
||||
}
|
||||
just_wrapped = 0;
|
||||
/* FIXME: we cant do this - we need to be able to qury text
|
||||
* overflow amounts */
|
||||
/*
|
||||
|
@ -1406,12 +1417,20 @@ evas_object_textblock_layout_internal(Evas_Object *obj, int w, int h, int *forma
|
|||
chrpos = 0;
|
||||
nchrpos = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ppos == 0)
|
||||
{
|
||||
nchrpos = 0;
|
||||
chrpos--;
|
||||
}
|
||||
else
|
||||
{
|
||||
chr = evas_common_font_utf8_get_next(text, &ppos);
|
||||
if (ppos < 0) ppos = 0;
|
||||
chrpos = ppos;
|
||||
while ((evas_object_textblock_char_is_white(chr))
|
||||
while
|
||||
((evas_object_textblock_char_is_white(chr))
|
||||
&&
|
||||
(pos >= 0) &&
|
||||
(chr > 0))
|
||||
|
@ -1425,6 +1444,8 @@ evas_object_textblock_layout_internal(Evas_Object *obj, int w, int h, int *forma
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
just_wrapped = 1;
|
||||
/* if the first char in the line can't fit!!! */
|
||||
if ((chrpos == 0) && (lnode == line_start))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue