Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Dinges <blender@dingto.org>2014-02-07 00:45:43 +0400
committerThomas Dinges <blender@dingto.org>2014-02-07 00:45:59 +0400
commit7692bf02e056f0a0d88e331461d6a9c815c43ec5 (patch)
tree553ff17304925ca2989c73abf7ed4e2481a36c99 /release/scripts/startup/bl_ui/properties_physics_cloth.py
parent0f8ad228c38a26f467c3ea5f2932f04247986f9f (diff)
UI: Fix Cloth panel after 28936a415076, was too large and looked bad.
* Move Sewing Springs to a dedicated panel, the "Cloth" panel is too crowded already, and the sewing springs feature is nicely isolated.
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_physics_cloth.py')
-rw-r--r--release/scripts/startup/bl_ui/properties_physics_cloth.py43
1 files changed, 33 insertions, 10 deletions
diff --git a/release/scripts/startup/bl_ui/properties_physics_cloth.py b/release/scripts/startup/bl_ui/properties_physics_cloth.py
index 4e382f23645..327ee4035ef 100644
--- a/release/scripts/startup/bl_ui/properties_physics_cloth.py
+++ b/release/scripts/startup/bl_ui/properties_physics_cloth.py
@@ -77,16 +77,6 @@ class PHYSICS_PT_cloth(PhysicButtonsPanel, Panel):
col.prop(cloth, "structural_stiffness", text="Structural")
col.prop(cloth, "bending_stiffness", text="Bending")
- col.label(text="Sewing:")
- col.prop(cloth, "use_sewing_springs", text="Use Sewing Springs")
- col.prop(cloth, "sewing_force_max", text="Sewing Force")
-
- sub = col.column()
- col.label(text="Shrinking:")
- col.prop_search(cloth, "vertex_group_shrink", ob, "vertex_groups", text="")
- col.prop(cloth, "shrink_min", text="Min")
- col.prop(cloth, "shrink_max", text="Max")
-
col = split.column()
col.label(text="Damping:")
@@ -201,6 +191,39 @@ class PHYSICS_PT_cloth_stiffness(PhysicButtonsPanel, Panel):
col.prop(cloth, "bending_stiffness_max", text="Max")
+class PHYSICS_PT_cloth_sewing(PhysicButtonsPanel, Panel):
+ bl_label = "Cloth Sewing Springs"
+ bl_options = {'DEFAULT_CLOSED'}
+
+ def draw_header(self, context):
+ cloth = context.cloth.settings
+
+ self.layout.active = cloth_panel_enabled(context.cloth)
+ self.layout.prop(cloth, "use_sewing_springs", text="")
+
+ def draw(self, context):
+ layout = self.layout
+
+ md = context.cloth
+ ob = context.object
+ cloth = context.cloth.settings
+
+ layout.active = (cloth.use_sewing_springs and cloth_panel_enabled(md))
+
+ layout.prop(cloth, "sewing_force_max", text="Sewing Force")
+
+ split = layout.split()
+
+ col = split.column(align=True)
+ col.label(text="Shrinking:")
+ col.prop_search(cloth, "vertex_group_shrink", ob, "vertex_groups", text="")
+
+ col = split.column(align=True)
+ col.label()
+ col.prop(cloth, "shrink_min", text="Min")
+ col.prop(cloth, "shrink_max", text="Max")
+
+
class PHYSICS_PT_cloth_field_weights(PhysicButtonsPanel, Panel):
bl_label = "Cloth Field Weights"
bl_options = {'DEFAULT_CLOSED'}