Anim: bone color properties panel layout tweaks

More consistent layout for bone colors. The custom colors and regular
colors now have the layout in the UI.
This commit is contained in:
Sybren A. Stüvel
2023-09-28 11:19:53 +02:00
parent afeb3e7784
commit 4473bdc6ab
@@ -278,6 +278,9 @@ class BONE_PT_display(BoneButtonsPanel, Panel):
return
pose_bone = ob.pose.bones[bone.name]
# Allow the layout to use the space normally occupied by the 'set a key' diamond.
layout.use_property_decorate = False
layout.prop(bone.color, 'palette', text='Edit Bone Color')
self.draw_bone_color_ui(layout, bone.color)
layout.prop(pose_bone.color, 'palette', text='Pose Bone Color')
@@ -297,8 +300,7 @@ class BONE_PT_display(BoneButtonsPanel, Panel):
if not bone_color.is_custom:
return
layout.use_property_split = False
split = layout.split(factor=0.4)
split = layout.split(factor=0.401)
col = split.column()
row = col.row()
@@ -307,6 +309,7 @@ class BONE_PT_display(BoneButtonsPanel, Panel):
col = split.column(align=True)
row = col.row(align=True)
row.use_property_split = False
row.prop(bone_color.custom, "normal", text="")
row.prop(bone_color.custom, "select", text="")
row.prop(bone_color.custom, "active", text="")