jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=5bf1f0c9187525cf40782b26d7fa49d2676f91bb

commit 5bf1f0c9187525cf40782b26d7fa49d2676f91bb
Author: Jean-Philippe Andre <[email protected]>
Date:   Tue May 13 11:22:22 2014 +0900

    edje_calc: Don't add padding twice to text objects
    
    Text objects declared in Edje will see their padding added twice,
    as the Evas_Object_Text itself contains the padding already.
    
    This WILL break some EDC files. It's a bug nonetheless.
    
    Should this be backported?
---
 src/lib/edje/edje_calc.c | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index bbc398b..202bfd7 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -1478,7 +1478,7 @@ _edje_part_recalc_single_text(FLOAT_T sc EINA_UNUSED,
  * -- Gustavo Barbieri at 20-Aug-2011
  */
 {
-   int tw, th, mw, mh, l, r, t, b, size;
+   int mw, mh,size;
    char *sfont = NULL;
 
    _edje_text_class_font_get(ed, desc, &size, &sfont);
@@ -1492,12 +1492,8 @@ _edje_part_recalc_single_text(FLOAT_T sc EINA_UNUSED,
         (!chosen_desc->text.max_x) && (!chosen_desc->text.max_y)))
      return;
 
-   eo_do(ep->object,
-         evas_obj_size_get(&tw, &th),
-         evas_obj_text_style_pad_get(&l, &r, &t, &b));
-
-   mw = tw + l + r;
-   mh = th + t + b;
+   // Note: No need to add padding to that, it's already in the geometry
+   eo_do(ep->object, evas_obj_size_get(&mw, &mh));
 
    if (chosen_desc->text.max_x)
      {

-- 


Reply via email to