summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2020-05-01 12:50:53 +0100
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2020-05-01 12:50:53 +0100
commitb2a2ba39af00ed4443367ef7f2e2ffa31c0f9977 (patch)
tree17f60bb20d9b5af45560530793d02ca4e0f39387
parent36dbaa707cdf07dd97c5e7a890f77f78dba2e3e8 (diff)
edje - don't set font sizes less than 1
this makes evas unhappy and results in noise. @fix
-rw-r--r--src/lib/edje/edje_text.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/lib/edje/edje_text.c b/src/lib/edje/edje_text.c
index ef1b149c75..f245c9d04b 100644
--- a/src/lib/edje/edje_text.c
+++ b/src/lib/edje/edje_text.c
@@ -367,14 +367,15 @@ _edje_text_recalc_apply(Edje *ed, Edje_Real_Part *ep,
367 */ 367 */
368 if (!chosen_desc->text.fit_x) size = sh; 368 if (!chosen_desc->text.fit_x) size = sh;
369 369
370 if (inlined_font) efl_text_font_source_set(ep->object, ed->path); 370 if (size < 1) size = 1;
371 else efl_text_font_source_set(ep->object, NULL); 371 if (inlined_font) efl_text_font_source_set(ep->object, ed->path);
372 else efl_text_font_source_set(ep->object, NULL);
372 373
373 if (ep->part->scale) efl_gfx_entity_scale_set(ep->object, TO_DOUBLE(sc)); 374 if (ep->part->scale) efl_gfx_entity_scale_set(ep->object, TO_DOUBLE(sc));
374 375
375 efl_text_font_family_set(ep->object, font); 376 efl_text_font_family_set(ep->object, font);
376 efl_text_font_size_set(ep->object, size); 377 efl_text_font_size_set(ep->object, size);
377 efl_text_set(ep->object, text); 378 efl_text_set(ep->object, text);
378 part_get_geometry(ep, &tw, &th); 379 part_get_geometry(ep, &tw, &th);
379 380
380 /* only grow the font size if we didn't already reach the max size 381 /* only grow the font size if we didn't already reach the max size