workaround: hardcoding size to display nicely on tizen/generic 06/20906/2
authorPhilippe Coval <philippe.coval@open.eurogiciel.org>
Thu, 13 Mar 2014 09:23:24 +0000 (10:23 +0100)
committerPhilippe Coval <philippe.coval@open.eurogiciel.org>
Wed, 28 May 2014 16:24:24 +0000 (09:24 -0700)
should be proportional to fonts size

Bug-Tizen: TC-22
Change-Id: I4d52ba07649f9bf21f3bdf931a64e152844084c5
Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
src/calc-main.c

index 6349da8..1903c2e 100644 (file)
@@ -49,6 +49,10 @@ Evas_Object *load_edj(Evas_Object * parent, const char *file, const char *group)
                }
                evas_object_size_hint_weight_set(eo, EVAS_HINT_EXPAND,
                                                 EVAS_HINT_EXPAND);
+               {
+                 static const int h=2*300,w=2*200;
+                 evas_object_size_hint_min_set(eo, w, h);
+               }
        }
        CALC_FUN_END();
        return eo;
@@ -237,6 +241,11 @@ static Evas_Object *_create_win(const char *name)
                evas_object_smart_callback_add(eo, "delete,request", _win_del,
                                               NULL);
        elm_win_screen_size_get(eo, NULL, NULL, &w, &h);
+       {
+         h /=2;
+         int t = h * 3. / 4.;
+         w = ( t < w ) ? t : w;
+       }
        evas_object_resize(eo, w, h);
        }
        CALC_FUN_END();