Fix T97100: Fix ordering in color attribute list items
The new tab in the properties panel for "Color Attributes" shows the data type and domain, just like the Attributes tab. The issue is that the UI does not scale well and can only display the full names when dragged to an extreme width. This is due to the inclusion of the render icon in between the attribute name and attribute type description. This patch changes the order that items are displayed in the Color Attributes Panel. Moving the render icon to the very right. The result is consistent with other parts of the Blender UI and does not take as much space to display the full text. Reviewed By: @jbakker Differential Revision: https://developer.blender.org/D14567 Ref D14567
This commit is contained in:
parent
d683ea4862
commit
4a3bcfa102
Notes:
blender-bot
2023-02-14 04:31:04 +01:00
Referenced by issue #97100, Color Attribute tab: Type and domain don't scale correctly
|
@ -1 +1 @@
|
|||
Subproject commit 63699f968344db7dc853d2c5972325beea44900c
|
||||
Subproject commit 716dc02ec30c0810513f7b4adc4ae865ae50c4e6
|
|
@ -1 +1 @@
|
|||
Subproject commit 4d53ec76a3d8b0a72fcc7a795067a159ce6dcd2c
|
||||
Subproject commit 787ea78f7fa6f0373d80ba1247768402df93f8ad
|
|
@ -599,21 +599,22 @@ class MESH_UL_color_attributes(UIList, ColorAttributesListBase):
|
|||
split.emboss = 'NONE'
|
||||
split.prop(attribute, "name", text="")
|
||||
|
||||
active_render = _index == data.color_attributes.render_color_index
|
||||
|
||||
props = split.operator(
|
||||
"geometry.color_attribute_render_set",
|
||||
text="",
|
||||
icon='RESTRICT_RENDER_OFF' if active_render else 'RESTRICT_RENDER_ON',
|
||||
)
|
||||
|
||||
props.name = attribute.name
|
||||
|
||||
sub = split.row()
|
||||
sub.alignment = 'RIGHT'
|
||||
sub.active = False
|
||||
sub.label(text="%s ▶ %s" % (domain_name, data_type.name))
|
||||
|
||||
active_render = _index == data.color_attributes.render_color_index
|
||||
|
||||
row = layout.row()
|
||||
row.emboss = 'NONE'
|
||||
prop = row.operator(
|
||||
"geometry.color_attribute_render_set",
|
||||
text="",
|
||||
icon='RESTRICT_RENDER_OFF' if active_render else 'RESTRICT_RENDER_ON',
|
||||
)
|
||||
prop.name = attribute.name
|
||||
|
||||
|
||||
class MESH_UL_color_attributes_selector(UIList, ColorAttributesListBase):
|
||||
def draw_item(self, _context, layout, data, attribute, _icon, _active_data, _active_propname, _index):
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit f4af5ed5a705c5d048b137ba56a6cf9295681ec5
|
||||
Subproject commit 1e658ca996f11e5ff3398d89bd81f5b719304a57
|
Loading…
Reference in New Issue