summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib/evas/canvas/evas_object_textblock.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/src/lib/evas/canvas/evas_object_textblock.c b/src/lib/evas/canvas/evas_object_textblock.c
index d371ab00a9..60d2ff0545 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -3032,25 +3032,22 @@ _layout_item_ascent_descent_adjust(Evas_Object_Protected_Data *obj,
3032 } 3032 }
3033 } 3033 }
3034 3034
3035 if (fmt)
3036 {
3037 asc = ENFN->font_ascent_get(ENC, fmt->font.font);
3038 desc = ENFN->font_descent_get(ENC, fmt->font.font);
3039
3040 if (asc > *ascent) *ascent = asc;
3041 if (desc > *descent) *descent = desc;
3042 }
3043
3044 if (fi) 3035 if (fi)
3045 { 3036 {
3046 asc = evas_common_font_instance_ascent_get(fi); 3037 asc = evas_common_font_instance_ascent_get(fi);
3047 desc = evas_common_font_instance_descent_get(fi); 3038 desc = evas_common_font_instance_descent_get(fi);
3039 }
3048 3040
3049 if (asc > *ascent) *ascent = asc; 3041 else if (fmt)
3050 if (desc > *descent) *descent = desc; 3042 {
3043 asc = ENFN->font_ascent_get(ENC, fmt->font.font);
3044 desc = ENFN->font_descent_get(ENC, fmt->font.font);
3051 } 3045 }
3052 3046
3053 if (fmt) _layout_format_ascent_descent_adjust(obj, ascent, descent, fmt); 3047 if (fmt) _layout_format_ascent_descent_adjust(obj, &asc, &desc, fmt);
3048
3049 if (asc > *ascent) *ascent = asc;
3050 if (desc > *descent) *descent = desc;
3054} 3051}
3055 3052
3056/** 3053/**