[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [23957] trunk/blender/release/scripts/ui: Moved some tool settings (mirror, auto-IK) to the tools pane.

William Reynish william at reynish.com
Mon Oct 19 15:24:18 CEST 2009


Revision: 23957
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=23957
Author:   billrey
Date:     2009-10-19 15:24:18 +0200 (Mon, 19 Oct 2009)

Log Message:
-----------
Moved some tool settings (mirror, auto-IK) to the tools pane.

Modified Paths:
--------------
    trunk/blender/release/scripts/ui/buttons_data_armature.py
    trunk/blender/release/scripts/ui/buttons_data_mesh.py
    trunk/blender/release/scripts/ui/space_view3d_toolbar.py

Modified: trunk/blender/release/scripts/ui/buttons_data_armature.py
===================================================================
--- trunk/blender/release/scripts/ui/buttons_data_armature.py	2009-10-19 13:21:37 UTC (rev 23956)
+++ trunk/blender/release/scripts/ui/buttons_data_armature.py	2009-10-19 13:24:18 UTC (rev 23957)
@@ -47,9 +47,6 @@
 		col.itemR(arm, "layer", text="")
 		col.itemL(text="Protected Layers:")
 		col.itemR(arm, "layer_protection", text="")
-		col.itemL(text="Edit Options:")
-		col.itemR(arm, "x_axis_mirror")
-		col.itemR(arm, "auto_ik")
 		
 		col = split.column()
 		col.itemL(text="Deform:")

Modified: trunk/blender/release/scripts/ui/buttons_data_mesh.py
===================================================================
--- trunk/blender/release/scripts/ui/buttons_data_mesh.py	2009-10-19 13:21:37 UTC (rev 23956)
+++ trunk/blender/release/scripts/ui/buttons_data_mesh.py	2009-10-19 13:24:18 UTC (rev 23957)
@@ -60,9 +60,6 @@
 		
 		col = split.column()
 		col.itemR(mesh, "texture_mesh")
-		
-		col = split.column()
-		col.itemR(mesh, "use_mirror_x")
 
 class DATA_PT_vertex_groups(DataButtonsPanel):
 	__label__ = "Vertex Groups"

Modified: trunk/blender/release/scripts/ui/space_view3d_toolbar.py
===================================================================
--- trunk/blender/release/scripts/ui/space_view3d_toolbar.py	2009-10-19 13:21:37 UTC (rev 23956)
+++ trunk/blender/release/scripts/ui/space_view3d_toolbar.py	2009-10-19 13:24:18 UTC (rev 23957)
@@ -38,11 +38,11 @@
 		col.itemO("anim.insert_keyframe_menu", text="Insert")
 		col.itemO("anim.delete_keyframe_v3d", text="Remove")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
@@ -91,18 +91,30 @@
 		col.itemO("mesh.uvs_rotate")
 		col.itemO("mesh.uvs_mirror")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
 		col.itemO("screen.repeat_last")
 		col.itemO("screen.repeat_history", text="History...")
 		col.itemO("screen.redo_last", text="Tweak...")
+		
+class VIEW3D_PT_tools_mesheditoptions(View3DPanel):
+	__context__ = "mesh_edit"
+	__label__ = "Mesh Options"
 
+	def draw(self, context):
+		layout = self.layout
+	
+		mesh = context.active_object.data
+		
+		col = layout.column(align=True)
+		col.itemR(mesh, "use_mirror_x")
+
 # ********** default tools for editmode_curve ****************
 
 class VIEW3D_PT_tools_curveedit(View3DPanel):
@@ -138,11 +150,11 @@
 		col.itemO("curve.extrude")
 		col.itemO("curve.subdivide")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
@@ -177,11 +189,11 @@
 		col.itemO("curve.extrude")
 		col.itemO("curve.subdivide")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
@@ -240,18 +252,21 @@
 		col.itemL(text="Modeling:")
 		col.itemO("armature.extrude")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
 		col.itemO("screen.repeat_last")
 		col.itemO("screen.repeat_history", text="History...")
 		col.itemO("screen.redo_last", text="Tweak...")
+		
 
+
+
 # ********** default tools for editmode_mball ****************
 
 class VIEW3D_PT_tools_mballedit(View3DPanel):
@@ -267,11 +282,11 @@
 		col.itemO("tfm.rotate")
 		col.itemO("tfm.resize", text="Scale")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
@@ -294,11 +309,11 @@
 		col.itemO("tfm.rotate")
 		col.itemO("tfm.resize", text="Scale")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
@@ -344,18 +359,31 @@
 		col.itemO("pose.push", text="Push")
 		col.itemO("pose.breakdown", text="Breakdowner")
 		
-		col = layout.column(align=True)
-		col.itemL(text="Grease Pencil:")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
-		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
-		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
+#		col = layout.column(align=True)
+#		col.itemL(text="Grease Pencil:")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW', text="Draw Freehand")
+#		col.item_enumO("gpencil.draw", "mode", 'DRAW_STRAIGHT', text="Straight Line")
+#		col.item_enumO("gpencil.draw", "mode", 'ERASER', text="Eraser")
 		
 		col = layout.column(align=True)
 		col.itemL(text="Repeat:")
 		col.itemO("screen.repeat_last")
 		col.itemO("screen.repeat_history", text="History...")
 		col.itemO("screen.redo_last", text="Tweak...")
+		
+class VIEW3D_PT_tools_posemode_options(View3DPanel):
+	__context__ = "posemode"
+	__label__ = "Pose Options"
 
+	def draw(self, context):
+		layout = self.layout
+		
+		arm = context.active_object.data
+
+		col = layout.column(align=True)
+		col.itemR(arm, "x_axis_mirror")
+		col.itemR(arm, "auto_ik")
+
 # ********** default tools for paint modes ****************
 
 class PaintPanel(bpy.types.Panel):
@@ -449,7 +477,7 @@
 					col.row().itemR(brush, "direction", expand=True)
 
 				if brush.sculpt_tool == 'LAYER':
-					col.itemR(brush, "use_persistent")
+					col.itemR(brush, "persistent")
 					col.itemO("sculpt.set_persistent_base")
 
 		# Texture Paint Mode #
@@ -775,6 +803,7 @@
 
 bpy.types.register(VIEW3D_PT_tools_objectmode)
 bpy.types.register(VIEW3D_PT_tools_meshedit)
+bpy.types.register(VIEW3D_PT_tools_mesheditoptions)
 bpy.types.register(VIEW3D_PT_tools_curveedit)
 bpy.types.register(VIEW3D_PT_tools_surfaceedit)
 bpy.types.register(VIEW3D_PT_tools_textedit)
@@ -782,6 +811,7 @@
 bpy.types.register(VIEW3D_PT_tools_mballedit)
 bpy.types.register(VIEW3D_PT_tools_latticeedit)
 bpy.types.register(VIEW3D_PT_tools_posemode)
+bpy.types.register(VIEW3D_PT_tools_posemode_options)
 bpy.types.register(VIEW3D_PT_tools_brush)
 bpy.types.register(VIEW3D_PT_tools_brush_stroke)
 bpy.types.register(VIEW3D_PT_tools_brush_curve)





More information about the Bf-blender-cvs mailing list