[Bf-committers] [Bf-blender-cvs] SVN commit: /data/svn/bf-blender [53355] trunk/blender: This commit frees list ui items from their dependencies to Panel, and hence from all the limitations this implied (mostly, the " only one list per panel" one).

Bastien Montagne montagne29 at wanadoo.fr
Sat Dec 29 19:51:07 CET 2012


Nah, that page is for history now :)

UI_UL_list is just a py wrapper around default template_list (i.e. the 
one displaying icon+name of the items). If you want more, you can either 
re-use one of the already defined UIList classes (in UI code, like e.g. 
MESH_UL_vgroups for vertex groups…), or create your own (using 
bpy.types.UIList as base).

All in all, lists are now handled pretty much like panels or menus! 
Again, having a look at ui code of properties_data_mesh & co should make 
things easy to grasp! ;)

On 29/12/2012 19:23, Bassam Kurdali wrote:
> I'm a little bit confused about the changes also. This page:
> http://wiki.blender.org/index.php/User:Mont29/Dev/UI_Template_List_Enhancement
> states that generic templates in the old system, i.e. the non-hardcoded
> ones, display only the name of each item - but I have working lists
> where you can also edit a property value in each item (what I wanted).
>
> Can I inherit from "UI_UL_list" ? or do I have to create and register a
> new one?
>
> -thanks,
> Bassam
>
> On Sat, 2012-12-29 at 11:36 +1100, Matt Ebb wrote:
>> On Sat, Dec 29, 2012 at 10:36 AM, Bastien Montagne<montagne29 at wanadoo.fr>wrote:
>>
>>> Yes, all lists now use it… See e.g. the 'properties_material.py',
>>> 'properties_data_mesh.py', etc
>>>
>> Oh, I see... So this breaks API compatibility, and all scripts will need to
>> be updated?
>> _______________________________________________
>> Bf-committers mailing list
>> Bf-committers at blender.org
>> http://lists.blender.org/mailman/listinfo/bf-committers
>
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at blender.org
> http://lists.blender.org/mailman/listinfo/bf-committers



More information about the Bf-committers mailing list