IK constraint and armature modifier layout tweaks
authorWilliam Reynish <william@reynish.com>
Mon, 10 Aug 2009 12:17:12 +0000 (12:17 +0000)
committerWilliam Reynish <william@reynish.com>
Mon, 10 Aug 2009 12:17:12 +0000 (12:17 +0000)
release/ui/buttons_data_modifier.py
release/ui/buttons_object_constraint.py

index 2b13034af9f9efb139829ca0055488c097309e1b..63204cfbc3dac76e43296d60b67437df7b3da01b 100644 (file)
@@ -30,15 +30,27 @@ class DATA_PT_modifiers(DataButtonsPanel):
        def ARMATURE(self, layout, ob, md):
                layout.itemR(md, "object")
                
        def ARMATURE(self, layout, ob, md):
                layout.itemR(md, "object")
                
-               row = layout.row()
-               row.item_pointerR(md, "vertex_group", ob, "vertex_groups")
-               row.itemR(md, "invert")
+               split = layout.split(percentage=0.5)
+               split.itemL(text="Vertex Group:")
+               sub = split.split(percentage=0.7)
+               sub.item_pointerR(md, "vertex_group", ob, "vertex_groups", text="")
+               subsub = sub.row()
+               subsub.active = md.vertex_group
+               subsub.itemR(md, "invert")
                
                
-               flow = layout.column_flow()
-               flow.itemR(md, "use_vertex_groups", text="Vertex Groups")
-               flow.itemR(md, "use_bone_envelopes", text="Bone Envelopes")
-               flow.itemR(md, "quaternion")
-               flow.itemR(md, "multi_modifier")
+               layout.itemS()
+               
+               split = layout.split()
+
+               col = split.column()
+               col.itemL(text="Bind To:")
+               col.itemR(md, "use_vertex_groups", text="Vertex Groups")
+               col.itemR(md, "use_bone_envelopes", text="Bone Envelopes")
+               
+               col = split.column()
+               col.itemL(text="Deformation:")
+               col.itemR(md, "quaternion")
+               col.itemR(md, "multi_modifier")
                
        def ARRAY(self, layout, ob, md):
                layout.itemR(md, "fit_type")
                
        def ARRAY(self, layout, ob, md):
                layout.itemR(md, "fit_type")
index 5606c6c258af11e3de0bf3188c2470b6bd22d724..5ee6aba1f0589000b515172738e450af37deeeae 100644 (file)
@@ -94,21 +94,29 @@ class ConstraintButtonsPanel(bpy.types.Panel):
                self.target_template(layout, con)
                
                layout.itemR(con, "pole_target")
                self.target_template(layout, con)
                
                layout.itemR(con, "pole_target")
+       
                if con.pole_target and con.pole_target.type == 'ARMATURE':
                        layout.item_pointerR(con, "pole_subtarget", con.pole_target.data, "bones", text="Bone")
                
                if con.pole_target and con.pole_target.type == 'ARMATURE':
                        layout.item_pointerR(con, "pole_subtarget", con.pole_target.data, "bones", text="Bone")
                
-               flow = layout.column_flow()
-               flow.itemR(con, "iterations")
-               flow.itemR(con, "pole_angle")
-               flow.itemR(con, "weight")
-               flow.itemR(con, "orient_weight")
-               flow.itemR(con, "chain_length")
-               
-               flow = layout.column_flow()
-               flow.itemR(con, "tail")
-               flow.itemR(con, "rotation")
-               flow.itemR(con, "targetless")
-               flow.itemR(con, "stretch")
+               split = layout.split()
+       
+               col = split.column()
+               col.itemR(con, "iterations")
+               col.itemR(con, "chain_length")
+               sub = col.column()
+               sub.active = con.pole_target
+               sub.itemR(con, "pole_angle")
+               col.itemL(text="Weight:")
+               col.itemR(con, "weight", text="Position", slider=True)
+               sub = col.column()
+               sub.active = con.rotation
+               sub.itemR(con, "orient_weight", text="Rotation", slider=True)
+               
+               col = split.column()
+               col.itemR(con, "tail")
+               col.itemR(con, "rotation")
+               col.itemR(con, "targetless")
+               col.itemR(con, "stretch")
                
        def FOLLOW_PATH(self, layout, con):
                self.target_template(layout, con)
                
        def FOLLOW_PATH(self, layout, con):
                self.target_template(layout, con)