[Bf-extensions-cvs] [17abf4e] master: Update Mesh Extra Tools: T48120 menu redesign, new features, remove old broken feature

meta-androcto noreply at git.blender.org
Tue Apr 19 05:51:27 CEST 2016


Commit: 17abf4e927bdc185cca6dac6d2ef677956979a0b
Author: meta-androcto
Date:   Tue Apr 19 13:50:48 2016 +1000
Branches: master
https://developer.blender.org/rBAC17abf4e927bdc185cca6dac6d2ef677956979a0b

Update Mesh Extra Tools: T48120 menu redesign, new features, remove old broken feature

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

M	mesh_extra_tools/__init__.py
M	mesh_extra_tools/face_inset_fillet.py
D	mesh_extra_tools/mesh_bevel_witold.py
D	mesh_extra_tools/mesh_bump.py
A	mesh_extra_tools/mesh_cut_faces.py
A	mesh_extra_tools/mesh_edge_roundifier.py
A	mesh_extra_tools/mesh_edges_length.py
D	mesh_extra_tools/mesh_extras.py
A	mesh_extra_tools/mesh_fastloop.py
M	mesh_extra_tools/mesh_mextrude_plus.py
D	mesh_extra_tools/mesh_normal_smooth.py
A	mesh_extra_tools/mesh_offset_edges.py
D	mesh_extra_tools/mesh_polyredux.py
A	mesh_extra_tools/mesh_to_wall.py
A	mesh_extra_tools/pkhg_faces.py
A	mesh_extra_tools/random_vertices.py
A	mesh_extra_tools/split_solidify.py

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

diff --git a/mesh_extra_tools/__init__.py b/mesh_extra_tools/__init__.py
index 41de6d9..97c6bbd 100644
--- a/mesh_extra_tools/__init__.py
+++ b/mesh_extra_tools/__init__.py
@@ -16,72 +16,161 @@
 #
 # ##### END GPL LICENSE BLOCK #####
 # Contributed to by
-# meta-androcto #
+# 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 #
 
 bl_info = {
-    "name": "Extra Tools",
+    "name": "Edit Tools",
     "author": "various",
     "version": (0, 1),
-    "blender": (2, 71, 0),
-    "location": "View3D > Toolshelf > Tools Tab & Specials (W-key)",
+    "blender": (2, 76, 0),
+    "location": "View3D > Toolshelf > Tools & Specials (W-key)",
     "description": "Add extra mesh edit tools",
     "warning": "",
-    "wiki_url": "",
-    "tracker_url": "https://developer.blender.org/maniphest/task/create/?project=3&type=Bug",
+    "wiki_url": "https://github.com/meta-androcto/blenderpython/wiki/AF_Edit_Tools",
+    "tracker_url": "https://developer.blender.org/maniphest/project/3/type/Bug/",
     "category": "Mesh"}
 
 
+
 if "bpy" in locals():
-    import imp
-    imp.reload(mesh_bump)
-    imp.reload(face_inset_fillet)
-    imp.reload(mesh_bevel_witold)
-    imp.reload(mesh_filletplus)
-    imp.reload(mesh_normal_smooth)
-    imp.reload(mesh_polyredux)
-    imp.reload(mesh_vertex_chamfer)
-    imp.reload(mesh_mextrude_plus)
+    import importlib
+    importlib.reload(face_inset_fillet)
+    importlib.reload(mesh_filletplus)
+    importlib.reload(mesh_vertex_chamfer)
+    importlib.reload(mesh_mextrude_plus)
+    importlib.reload(mesh_offset_edges)
+    importlib.reload(pkhg_faces)
+    importlib.reload(mesh_edge_roundifier)
+    importlib.reload(mesh_cut_faces)
+    importlib.reload(split_solidify)
+    importlib.reload(mesh_to_wall)
+    importlib.reload(mesh_edges_length)
+    importlib.reload(random_vertices)
+    importlib.reload(mesh_fastloop)
 
 else:
-    from . import mesh_bump
     from . import face_inset_fillet
-    from . import mesh_bevel_witold
     from . import mesh_filletplus
-    from . import mesh_normal_smooth
-    from . import mesh_polyredux
     from . import mesh_vertex_chamfer
     from . import mesh_mextrude_plus
+    from . import mesh_offset_edges
+    from . import pkhg_faces
+    from . import mesh_edge_roundifier
+    from . import mesh_cut_faces
+    from . import split_solidify
+    from . import mesh_to_wall
+    from . import mesh_edges_length
+    from . import random_vertices
+    from . import mesh_fastloop
 
-import bpy
+import bpy 
+from bpy.props import BoolProperty
+### ------ MENUS ====== ###
 
 class VIEW3D_MT_edit_mesh_extras(bpy.types.Menu):
     # Define the "Extras" menu
     bl_idname = "VIEW3D_MT_edit_mesh_extras"
-    bl_label = "Extra Tools"
+    bl_label = "Edit Tools"
 
     def draw(self, context):
         layout = self.layout
         layout.operator_context = 'INVOKE_REGION_WIN'
-        layout.operator("faceinfillet.op0_id",
-            text="Face Inset Fillet")
-        layout.operator("fillet.op0_id",
-            text="Edge Fillet Plus")
-        layout.operator("object.mextrude",
-            text="Multi Extrude")
-        layout.operator("mesh.bump",
-            text="Inset Extrude Bump")
-        layout.operator("mesh.mbevel",
-            text="Bevel Selected")
-        layout.operator("mesh.vertex_chamfer",
-            text="Vertex Chamfer")
-        layout.operator("mesh.polyredux",
-            text="Poly Redux")
-        layout.operator("normal.smooth",
-            text="Normal Smooth")
-
-
-class ExtrasPanel(bpy.types.Panel):
-    bl_label = 'Mesh Extra Tools'
+        mode = context.tool_settings.mesh_select_mode
+        if mode[0]: 	
+            split = layout.split()		
+            col = split.column()
+            col.label(text="Vert")
+            col.operator("mesh.vertex_chamfer",
+                text="Vertex Chamfer")
+            col.operator("mesh.random_vertices",
+                text="Random Vertices")
+
+            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()		
+            col = split.column()
+            col.label(text="Edge")
+            col.operator("fillet.op0_id",
+                text="Edge Fillet Plus")
+            col.operator("mesh.offset_edges",
+                text="Offset Edges")
+            col.operator("mesh.edge_roundifier",
+                text="Edge Roundify")
+            col.operator("object.mesh_edge_length_set",
+                text="Set Edge Length")
+            col.operator("bpt.mesh_to_wall",
+                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()		
+            col = split.column()
+            col.label(text="Face")
+            col.operator("object.mextrude",
+                text="Multi Extrude")
+            col.operator("faceinfillet.op0_id",
+                text="Face Inset Fillet")
+            col.operator("mesh.add_faces_to_object",
+                text="PKHG Faces")
+            col.operator("mesh.ext_cut_faces",
+                text="Cut Faces")
+            col.operator("sp_sol.op0_id",
+                text="Split Solidify")
+
+            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)
+
+
+class EditToolsPanel(bpy.types.Panel):
+    bl_label = 'Mesh Edit Tools'
     bl_space_type = 'VIEW_3D'
     bl_region_type = 'TOOLS'
     bl_context = 'mesh_edit'
@@ -89,52 +178,149 @@ class ExtrasPanel(bpy.types.Panel):
     bl_options = {'DEFAULT_CLOSED'}
 
     def draw(self, context):
+
         layout = self.layout
-        row = layout.split(0.80)
-        row.operator('faceinfillet.op0_id', text = 'Face Inset Fillet', icon = 'PLUGIN')
-        row.operator('help.face_inset', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('fillet.op0_id', text = 'Edge Fillet plus', icon = 'PLUGIN')
-        row.operator('help.edge_fillet', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('object.mextrude', text = 'Multi Face Extrude', icon = 'PLUGIN')
-        row.operator('help.mextrude', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('mesh.bump', text = 'Inset Bump', icon = 'PLUGIN')
-        row.operator('help.bump', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('mesh.mbevel', text = 'Bevel Selected', icon = 'PLUGIN')
-        row.operator('help.edge_bevel', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('mesh.vertex_chamfer', text = 'Vertex Chamfer' , icon = 'PLUGIN')
-        row.operator('help.vertexchamfer', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('mesh.polyredux', text = 'Poly Redux', icon = 'PLUGIN')
-        row.operator('help.polyredux', text = '', icon = 'INFO')
-        row = layout.split(0.80)
-        row.operator('normal.smooth', text = 'Normal Smooth', icon = 'PLUGIN')
-        row.operator('help.normal_smooth', text = '', icon = 'INFO')
-        row = layout.split(0.50)
-        row.operator('mesh.flip_normals', text = 'Normals Flip')
-        row.operator('mesh.remove_doubles', text = 'Remove Doubles')
+        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()
+            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 = layout.split(0.70)
+            row.operator('mesh.random_vertices', text = 'Random Vertices')
+            row.operator('help.random_vert', text = '?')
+            row = layout.row()
+
+        # Edge options
+        box = layout.box()
+        col = box.column(align=True)
+        if wm.edit_tools_settings.edge_settings:
+            modifier_i

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-extensions-cvs mailing list