[Bf-extensions-cvs] [3e9f992] master: Update: mesh extra tools: T48592 new menu, merge select tools

meta-androcto noreply at git.blender.org
Sun Jun 12 07:32:06 CEST 2016


Commit: 3e9f9922d3f81995a080237293aafec95848a23b
Author: meta-androcto
Date:   Sun Jun 12 15:31:30 2016 +1000
Branches: master
https://developer.blender.org/rBAC3e9f9922d3f81995a080237293aafec95848a23b

Update: mesh extra tools: T48592 new menu, merge select tools

===================================================================

M	mesh_extra_tools/__init__.py
M	mesh_extra_tools/face_inset_fillet.py
M	mesh_extra_tools/mesh_cut_faces.py
M	mesh_extra_tools/mesh_edge_roundifier.py
M	mesh_extra_tools/mesh_edges_length.py
A	mesh_extra_tools/mesh_edgetools.py
M	mesh_extra_tools/mesh_fastloop.py
M	mesh_extra_tools/mesh_filletplus.py
M	mesh_extra_tools/mesh_mextrude_plus.py
M	mesh_extra_tools/mesh_offset_edges.py
A	mesh_extra_tools/mesh_pen_tool.py
A	mesh_extra_tools/mesh_select_tools/__init__.py
A	mesh_extra_tools/mesh_select_tools/mesh_index_select.py
A	mesh_extra_tools/mesh_select_tools/mesh_info_select.py
A	mesh_extra_tools/mesh_select_tools/mesh_select_by_direction.py
A	mesh_extra_tools/mesh_select_tools/mesh_select_by_edge_length.py
A	mesh_extra_tools/mesh_select_tools/mesh_select_by_pi.py
A	mesh_extra_tools/mesh_select_tools/mesh_select_by_type.py
A	mesh_extra_tools/mesh_select_tools/mesh_select_connected_faces.py
A	mesh_extra_tools/mesh_select_tools/mesh_selection_topokit.py
M	mesh_extra_tools/mesh_to_wall.py
M	mesh_extra_tools/mesh_vertex_chamfer.py
M	mesh_extra_tools/pkhg_faces.py
M	mesh_extra_tools/random_vertices.py
M	mesh_extra_tools/split_solidify.py
A	mesh_extra_tools/vfe_specials.py

===================================================================

diff --git a/mesh_extra_tools/__init__.py b/mesh_extra_tools/__init__.py
index 97c6bbd..49d4307 100644
--- a/mesh_extra_tools/__init__.py
+++ b/mesh_extra_tools/__init__.py
@@ -16,24 +16,33 @@
 #
 # ##### END GPL LICENSE BLOCK #####
 # Contributed to by
-# meta-androcto, pkhg, zmj100, Stanislav Blinov, Piotr Komisarczyk, #
-# Yi Danyang, Giuseppe De Marco, Andy Davies, Gert De Roost, liero, #
-# Hidesato Ikeya, luxuy_BlenderCN, Andrew Hale, Oscurart #
+# meta-androcto,  Hidesato Ikeya, zmj100, luxuy_BlenderCN, TrumanBlending, PKHG, #
+# Oscurart, Stanislav Blinov, komi3D, BlenderLab, Paul Marshall (brikbot), metalliandy, #
+# macouno, CoDEmanX, dustractor, Liero, #
 
 bl_info = {
-    "name": "Edit Tools",
-    "author": "various",
-    "version": (0, 1),
-    "blender": (2, 76, 0),
+    "name": "Edit Tools2",
+    "author": "meta-androcto",
+    "version": (0, 2, 0),
+    "blender": (2, 77, 0),
     "location": "View3D > Toolshelf > Tools & Specials (W-key)",
     "description": "Add extra mesh edit tools",
     "warning": "",
-    "wiki_url": "https://github.com/meta-androcto/blenderpython/wiki/AF_Edit_Tools",
-    "tracker_url": "https://developer.blender.org/maniphest/project/3/type/Bug/",
+    "wiki_url": "",
+    "tracker_url": "",
     "category": "Mesh"}
 
-
-
+# Import From Folder
+from .mesh_select_tools import mesh_select_by_direction
+from .mesh_select_tools import mesh_select_by_edge_length
+from .mesh_select_tools import mesh_select_by_pi
+from .mesh_select_tools import mesh_select_by_type
+from .mesh_select_tools import mesh_select_connected_faces
+from .mesh_select_tools import mesh_index_select
+from .mesh_select_tools import mesh_selection_topokit
+from .mesh_select_tools import mesh_info_select
+
+# Import From Files
 if "bpy" in locals():
     import importlib
     importlib.reload(face_inset_fillet)
@@ -49,6 +58,9 @@ if "bpy" in locals():
     importlib.reload(mesh_edges_length)
     importlib.reload(random_vertices)
     importlib.reload(mesh_fastloop)
+    importlib.reload(mesh_edgetools)
+    importlib.reload(mesh_pen_tool)
+    importlib.reload(vfe_specials)
 
 else:
     from . import face_inset_fillet
@@ -64,11 +76,16 @@ else:
     from . import mesh_edges_length
     from . import random_vertices
     from . import mesh_fastloop
+    from . import mesh_edgetools
+    from . import mesh_pen_tool
+    from . import vfe_specials
 
-import bpy 
+import bpy
 from bpy.props import BoolProperty
+from bpy_extras import view3d_utils
 ### ------ MENUS ====== ###
 
+
 class VIEW3D_MT_edit_mesh_extras(bpy.types.Menu):
     # Define the "Extras" menu
     bl_idname = "VIEW3D_MT_edit_mesh_extras"
@@ -78,96 +95,74 @@ class VIEW3D_MT_edit_mesh_extras(bpy.types.Menu):
         layout = self.layout
         layout.operator_context = 'INVOKE_REGION_WIN'
         mode = context.tool_settings.mesh_select_mode
-        if mode[0]: 	
-            split = layout.split()		
+        if mode[0]:
+            split = layout.split()
             col = split.column()
             col.label(text="Vert")
             col.operator("mesh.vertex_chamfer",
-                text="Vertex Chamfer")
+                         text="Vertex Chamfer")
             col.operator("mesh.random_vertices",
-                text="Random Vertices")
+                         text="Random Vertices")
 
-            row = split.row(align=True)		
+            row = split.row(align=True)
             col = split.column()
             col.label(text="Utilities")
             col.operator("object_ot.fastloop",
-                text="Fast loop")
-            col.operator('mesh.flip_normals', text = 'Normals Flip')
-            col.operator('mesh.remove_doubles', text = 'Remove Doubles')
-            col.operator('mesh.subdivide', text = 'Subdivide')
-            col.operator('mesh.dissolve_limited', text = 'Dissolve Limited')
-
-        elif mode[1]: 	
-            split = layout.split()		
+                         text="Fast loop")
+            col.operator('mesh.flip_normals', text='Normals Flip')
+            col.operator('mesh.remove_doubles', text='Remove Doubles')
+            col.operator('mesh.subdivide', text='Subdivide')
+            col.operator('mesh.dissolve_limited', text='Dissolve Limited')
+
+        elif mode[1]:
+            split = layout.split()
             col = split.column()
             col.label(text="Edge")
             col.operator("fillet.op0_id",
-                text="Edge Fillet Plus")
+                         text="Edge Fillet Plus")
             col.operator("mesh.offset_edges",
-                text="Offset Edges")
+                         text="Offset Edges")
             col.operator("mesh.edge_roundifier",
-                text="Edge Roundify")
+                         text="Edge Roundify")
             col.operator("object.mesh_edge_length_set",
-                text="Set Edge Length")
+                         text="Set Edge Length")
             col.operator("bpt.mesh_to_wall",
-                text="Edge(s) to Wall")
-				
-            row = split.row(align=True)		
+                         text="Edge(s) to Wall")
+            row = split.row(align=True)
             col = split.column()
             col.label(text="Utilities")
             col.operator("object_ot.fastloop",
-                text="Fast loop")
-            col.operator('mesh.flip_normals', text = 'Normals Flip')
-            col.operator('mesh.remove_doubles', text = 'Remove Doubles')
-            col.operator('mesh.remove_doubles', text = 'Remove Doubles')
-            col.operator('mesh.subdivide', text = 'Subdivide')
-            col.operator('mesh.dissolve_limited', text = 'Dissolve Limited')
-
-        elif mode[2]: 			
-            split = layout.split()		
+                         text="Fast loop")
+            col.operator('mesh.flip_normals', text='Normals Flip')
+            col.operator('mesh.remove_doubles', text='Remove Doubles')
+
+            col.operator('mesh.subdivide', text='Subdivide')
+            col.operator('mesh.dissolve_limited', text='Dissolve Limited')
+
+        elif mode[2]:
+            split = layout.split()
             col = split.column()
             col.label(text="Face")
             col.operator("object.mextrude",
-                text="Multi Extrude")
+                         text="Multi Extrude")
             col.operator("faceinfillet.op0_id",
-                text="Face Inset Fillet")
+                         text="Face Inset Fillet")
             col.operator("mesh.add_faces_to_object",
-                text="PKHG Faces")
+                         text="PKHG Faces")
             col.operator("mesh.ext_cut_faces",
-                text="Cut Faces")
+                         text="Cut Faces")
             col.operator("sp_sol.op0_id",
-                text="Split Solidify")
+                         text="Split Solidify")
 
-            row = split.row(align=True)		
+            row = split.row(align=True)
             col = split.column()
             col.label(text="Utilities")
             col.operator("object_ot.fastloop",
-                text="Fast loop")
-            col.operator('mesh.flip_normals', text = 'Normals Flip')
-            col.operator('mesh.remove_doubles', text = 'Remove Doubles')
-            col.operator('mesh.subdivide', text = 'Subdivide')
-            col.operator('mesh.dissolve_limited', text = 'Dissolve Limited')
-
-
-class EditToolsSettings(bpy.types.PropertyGroup):
-
-
-    vert_settings = BoolProperty(
-        name="Vert",
-        default=False)
-
-    edge_settings = BoolProperty(
-        name="Edge",
-        default=False)
-
-    face_settings = BoolProperty(
-        name="Face",
-        default=False)
-
-    utils_settings = BoolProperty(
-        name="Utils",
-        default=False)
-
+                         text="Fast loop")
+            col.operator('mesh.flip_normals', text='Normals Flip')
+            col.operator('mesh.remove_doubles', text='Remove Doubles')
+            col.operator('mesh.subdivide', text='Subdivide')
+            col.operator('mesh.dissolve_limited', text='Dissolve Limited')
 
 class EditToolsPanel(bpy.types.Panel):
     bl_label = 'Mesh Edit Tools'
@@ -178,149 +173,434 @@ class EditToolsPanel(bpy.types.Panel):
     bl_options = {'DEFAULT_CLOSED'}
 
     def draw(self, context):
-
+        scene = context.scene
+        VERTDROP = scene.UTVertDrop
+        EDGEDROP = scene.UTEdgeDrop
+        FACEDROP = scene.UTFaceDrop
+        UTILSDROP = scene.UTUtilsDrop
+        view = context.space_data
+        toolsettings = context.tool_settings
         layout = self.layout
-        wm = bpy.context.window_manager
 
         # Vert options
-        box = layout.box()
-        col = box.column(align=False)
-        if wm.edit_tools_settings.vert_settings:
-            file_icon = 'TRIA_DOWN'
-        else:
-            file_icon = 'TRIA_RIGHT'
-        col.prop(wm.edit_tools_settings, "vert_settings",
-                 icon=file_icon, toggle=True)
-        if wm.edit_tools_settings.vert_settings:
-            layout = self.layout
-            row = layout.row()
+        box1 = self.layout.box()
+        col = box1.column(align=True)
+        row = col.row(align=True)
+#        row.alignment = 'CENTER'
+        row.prop(scene, "UTVertDrop", icon="TRIA_DOWN")
+        if not VERTDROP:
+            row.menu("mesh.vert_select_tools", icon="RESTRICT_SELECT_OFF", text="")
+            row.menu("VIEW3D_MT_Select_Vert", icon="VERTEXSEL", text="")
+        if VERTDROP:
+            row = col.row(align=True)
             row.label(text="Vert Tools:", icon="VERTEXSEL")
             row = layout.split(0.70)
-            row.operator('mesh.vertex_chamfer', text = 'Chamfer')
-            row.operator('help.vertexchamfer', text = '?')
+            row.operator('mesh.vertex_chamfer', text='Chamfer')
+            row.operator('help.vertexchamfer', text='?')
             row = layout.split(0.70)
-            row.operator('mesh.random_vertices', text = 'Random Vertices')
-            row.operator('help.random_vert', text = '?')
-            row = layout.row()
+            row.operator('mesh.random_vertices', text='Random Vertices')
+            row.operator('help.random_vert', text=

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-extensions-cvs mailing list