New 'X' icon in search buttons sometimes overlapped text, needs extra space.
authorTon Roosendaal <ton@blender.org>
Thu, 24 Jan 2013 13:02:00 +0000 (13:02 +0000)
committerTon Roosendaal <ton@blender.org>
Thu, 24 Jan 2013 13:02:00 +0000 (13:02 +0000)
source/blender/editors/interface/interface_layout.c

index e87c0ee1c9ba1441971a38c676f83a06321a9526..10375824518724b6a2e82b2cdfc74d6fd073ea81 100644 (file)
@@ -1463,6 +1463,7 @@ void uiItemPointerR(uiLayout *layout, struct PointerRNA *ptr, const char *propna
        block = uiLayoutGetBlock(layout);
 
        ui_item_rna_size(layout, name, icon, ptr, prop, 0, 0, &w, &h);
+       w += UI_UNIT_X; /* X icon needs more space */
        but = ui_item_with_label(layout, block, name, icon, ptr, prop, 0, 0, 0, w, h, 0);
 
        ui_but_add_search(but, ptr, prop, searchptr, searchprop);