aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>2012-09-18 09:28:26 +0000
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>2012-09-18 09:28:26 +0000
commit34c247ee402ea5c9d5c70da0462544af4b40ac55 (patch)
tree7c8149f163af29ac48e1fe6e3bcb3c86dfb1b13b
parentd18751ac7f959d95d0981afeb33ab9fcc998299d (diff)
downloadenlightenment-34c247ee402ea5c9d5c70da0462544af4b40ac55.tar.gz
enlightenment-34c247ee402ea5c9d5c70da0462544af4b40ac55.tar.xz
enlightenment-34c247ee402ea5c9d5c70da0462544af4b40ac55.zip
escape textblock styles for file labels if label is a textblock
ticket #1527 SVN revision: 76792
-rw-r--r--src/bin/e_fm.c21
1 files changed, 14 insertions, 7 deletions
diff --git a/src/bin/e_fm.c b/src/bin/e_fm.c
index 160bc7f74..f4333ac48 100644
--- a/src/bin/e_fm.c
+++ b/src/bin/e_fm.c
@@ -4805,14 +4805,12 @@ _e_fm2_icon_label_set(E_Fm2_Icon *ic, Evas_Object *obj)
{
char buf[4096], *p;
int len;
+ const char *lbl, *type;
if (ic->info.label)
- {
- edje_object_part_text_set(obj, "e.text.label", ic->info.label);
- return;
- }
- if ((ic->sd->config->icon.extension.show) || ((!ic->info.link) && (S_ISDIR(ic->info.statinfo.st_mode))))
- edje_object_part_text_set(obj, "e.text.label", ic->info.file);
+ lbl = ic->info.label;
+ else if ((ic->sd->config->icon.extension.show) || ((!ic->info.link) && (S_ISDIR(ic->info.statinfo.st_mode))))
+ lbl = ic->info.file;
else
{
/* remove extension. handle double extensions like .tar.gz too
@@ -4831,8 +4829,17 @@ _e_fm2_icon_label_set(E_Fm2_Icon *ic, Evas_Object *obj)
p = strrchr(buf, '.');
if ((p) && ((len - (p - buf)) < 6)) *p = 0;
}
- edje_object_part_text_set(obj, "e.text.label", buf);
+ lbl = buf;
}
+ type = evas_object_type_get(edje_object_part_object_get(obj, "e.text.label"));
+ if (!e_util_strcmp(type, "textblock"))
+ {
+ p = evas_textblock_text_utf8_to_markup(NULL, lbl);
+ edje_object_part_text_set(obj, "e.text.label", p);
+ free(p);
+ }
+ else
+ edje_object_part_text_set(obj, "e.text.label", lbl);
}
static Evas_Object *