On Tue, Jun 23, 2009 at 4:13 PM, Atton Jonathan<jonathan.at...@gmail.com> wrote:
> If someone find how to set both items to the top, I ll give him a cookie !
>
> Test apps: http://watchwolf.fr/public/test_box.tar.gz

no time to test it now, but it should be a matter of setting weight =
0 (no weight, no expand) and align.y = 0.0


> 2009/6/23 Gustavo Sverzut Barbieri <barbi...@profusion.mobi>
>>
>> On Mon, Jun 22, 2009 at 5:49 PM, Atton Jonathan<jonathan.at...@gmail.com>
>> wrote:
>> > hey,
>> >
>> > In eyelight I use some vertical layout but I don't get what I want. The
>> > items are not set to the top but are placed to fill all the box. It
>> > seems
>> > than the layout does:
>> > the layout height / number of items = height of an item, each item has
>> > the
>> > same height !
>> >
>> > My items are created  from an edje group with a textblock inside.
>> >
>> > I have attached a screenshot of the pb, each item has the same height,
>> > consequently the last item (the bigger item) is not completely display !
>> > The
>> > vertical layout is not supposed to fit the item list to the top ?
>> >
>> > With the help of Sachiel I have made some tests, especially try to set
>> > the
>> > max size with the result of evas_object_geometry_get() but the result is
>> > 0
>> > :/
>> >
>> > Currently my code is:
>> >
>> >    Evas_Object *o_text = edje_object_add(pres->evas);
>> >    edje_object_file_set(o_text, pres->theme,
>> > "eyelight/item_simple_text") ;
>> >    edje_object_part_text_set(o_text,"object.text",text);
>> >    evas_object_size_hint_align_set(o_text, -1, -1);
>> >    evas_object_size_hint_weight_set(o_text, -1, -1);
>> >    evas_object_show(o_text);
>> >    evas_object_move(o_text, 0, 0);
>> >    edje_object_part_box_append(o_area,buf,o_text);
>>
>>
>> check out documentation at
>>
>> http://docs.enlightenment.org/api/evas/html/group__Evas__Object__Box.html#g3aebf02a2e87e43f9dcba5e73291234c
>> and the other layout functions. They say what properties they expect
>> from child.
>>
>> As for the space allocated to items: depends on your layout. If you
>> choose "homogeneous" (not the "max_size" variant), that is correct. If
>> you choose the "max_size" homogeneous, it will query the maximum
>> min_size and allocate it to everyone.
>>
>> As for alignment within the allocated space, that's depend on the
>> o_text "align" hint, in your case you use "-1" that means "justify"
>> (align to both top and bottom, or left and right... either centers the
>> object or resize it to use the area, depends on min/max hints).
>>
>> Layout is complex, sorry... we tried to document it, but we could use
>> some test cases and examples on various types. Anyone willing to write
>> them? :-)
>>
>> --
>> Gustavo Sverzut Barbieri
>> http://profusion.mobi embedded systems
>> --------------------------------------
>> MSN: barbi...@gmail.com
>> Skype: gsbarbieri
>> Mobile: +55 (19) 9225-2202
>
>
>
> --
> Regards.
>



-- 
Gustavo Sverzut Barbieri
http://profusion.mobi embedded systems
--------------------------------------
MSN: barbi...@gmail.com
Skype: gsbarbieri
Mobile: +55 (19) 9225-2202

------------------------------------------------------------------------------
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to