UI: Reorganize 'Select' menus in 3D Viewport
Reorganizes the "Select" menus in all 3D Viewport modes to create more consistency and sort/group operators according to logic laid out in #121337 More details and images in the pull request. Pull Request: https://projects.blender.org/blender/blender/pulls/121521
This commit is contained in:
parent
4f2f97d498
commit
4dbca26b5c
@ -1818,17 +1818,17 @@ class VIEW3D_MT_select_object(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator_menu_enum("object.select_by_type", "type", text="Select All by Type")
|
||||
layout.operator("object.select_camera", text="Select Active Camera")
|
||||
layout.operator("object.select_mirror")
|
||||
layout.operator("object.select_random", text="Select Random")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_select_object_more_less")
|
||||
layout.menu("VIEW3D_MT_select_object_more_less", text="More/Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator_menu_enum("object.select_by_type", "type", text="Select All by Type")
|
||||
layout.operator_menu_enum("object.select_grouped", "type", text="Select Grouped")
|
||||
layout.operator_menu_enum("object.select_linked", "type", text="Select Linked")
|
||||
layout.operator("object.select_pattern", text="Select Pattern...")
|
||||
@ -1881,18 +1881,18 @@ class VIEW3D_MT_select_pose(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("pose.select_constraint_target", text="Constraint Target")
|
||||
layout.operator("pose.select_linked", text="Linked")
|
||||
layout.menu("VIEW3D_MT_select_pose_more_less", text="More/Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_select_pose_more_less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator_menu_enum("pose.select_grouped", "type", text="Grouped")
|
||||
layout.operator_menu_enum("pose.select_grouped", "type", text="Select Grouped")
|
||||
layout.operator("pose.select_linked", text="Select Linked")
|
||||
layout.operator("object.select_pattern", text="Select Pattern...")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("pose.select_constraint_target", text="Constraint Target")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_particle(Menu):
|
||||
bl_label = "Select"
|
||||
@ -1912,19 +1912,19 @@ class VIEW3D_MT_select_particle(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("particle.select_linked", text="Select Linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("particle.select_more")
|
||||
layout.operator("particle.select_less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("particle.select_random")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("particle.select_more", text="More")
|
||||
layout.operator("particle.select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("particle.select_linked", text="Select Linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("particle.select_roots", text="Roots")
|
||||
layout.operator("particle.select_tips", text="Tips")
|
||||
|
||||
@ -2012,51 +2012,36 @@ class VIEW3D_MT_select_edit_mesh(Menu):
|
||||
layout.operator("mesh.select_all", text="None").action = 'DESELECT'
|
||||
layout.operator("mesh.select_all", text="Invert").action = 'INVERT'
|
||||
|
||||
# gesture
|
||||
layout.separator()
|
||||
|
||||
layout.operator("view3d.select_box")
|
||||
layout.operator("view3d.select_circle")
|
||||
layout.operator_menu_enum("view3d.select_lasso", "mode")
|
||||
|
||||
layout.separator()
|
||||
|
||||
# numeric
|
||||
layout.separator()
|
||||
layout.operator("mesh.select_mirror")
|
||||
layout.operator("mesh.select_random", text="Select Random")
|
||||
layout.operator("mesh.select_nth")
|
||||
|
||||
# more/less
|
||||
layout.separator()
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_more_less", text="More/Less")
|
||||
|
||||
# geometric
|
||||
layout.operator("mesh.edges_select_sharp", text="Select Sharp Edges")
|
||||
|
||||
# grouped
|
||||
layout.separator()
|
||||
|
||||
# other ...
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_similar")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_by_trait")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_more_less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_linked")
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_loops")
|
||||
|
||||
# geometric
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_edit_mesh_select_linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("mesh.edges_select_sharp", text="Sharp Edges")
|
||||
layout.operator("mesh.select_axis", text="Side of Active")
|
||||
layout.operator("mesh.select_mirror")
|
||||
|
||||
# attribute
|
||||
layout.separator()
|
||||
|
||||
layout.operator("mesh.select_by_attribute", text="By Attribute")
|
||||
|
||||
layout.template_node_operator_asset_menu_items(catalog_path=self.bl_label)
|
||||
@ -2082,8 +2067,16 @@ class VIEW3D_MT_select_edit_curve(Menu):
|
||||
|
||||
layout.operator("curve.select_random")
|
||||
layout.operator("curve.select_nth")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_more", text="More")
|
||||
layout.operator("curve.select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_linked", text="Select Linked")
|
||||
layout.operator("curve.select_similar", text="Select Similar")
|
||||
layout.operator_menu_enum("curve.select_similar", "type")
|
||||
|
||||
layout.separator()
|
||||
|
||||
@ -2092,11 +2085,6 @@ class VIEW3D_MT_select_edit_curve(Menu):
|
||||
layout.operator("curve.select_next")
|
||||
layout.operator("curve.select_previous")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_more")
|
||||
layout.operator("curve.select_less")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_edit_surface(Menu):
|
||||
bl_label = "Select"
|
||||
@ -2118,17 +2106,20 @@ class VIEW3D_MT_select_edit_surface(Menu):
|
||||
|
||||
layout.operator("curve.select_random")
|
||||
layout.operator("curve.select_nth")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_more", text="More")
|
||||
layout.operator("curve.select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_linked", text="Select Linked")
|
||||
layout.operator("curve.select_similar", text="Select Similar")
|
||||
layout.operator_menu_enum("curve.select_similar", "type")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_row")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curve.select_more")
|
||||
layout.operator("curve.select_less")
|
||||
layout.operator("curve.select_row", text="Control Point Row")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_edit_text(Menu):
|
||||
@ -2187,7 +2178,7 @@ class VIEW3D_MT_select_edit_metaball(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator_menu_enum("mball.select_similar", "type", text="Similar")
|
||||
layout.operator_menu_enum("mball.select_similar", "type")
|
||||
|
||||
|
||||
class VIEW3D_MT_edit_lattice_context_menu(Menu):
|
||||
@ -2228,8 +2219,8 @@ class VIEW3D_MT_select_edit_lattice(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("lattice.select_more")
|
||||
layout.operator("lattice.select_less")
|
||||
layout.operator("lattice.select_more", text="More")
|
||||
layout.operator("lattice.select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
@ -2263,7 +2254,9 @@ class VIEW3D_MT_select_edit_armature(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("armature.select_linked", text="Linked")
|
||||
layout.operator("armature.select_linked", text="Select Linked")
|
||||
layout.operator_menu_enum("armature.select_similar", "type")
|
||||
layout.operator("object.select_pattern", text="Select Pattern...")
|
||||
|
||||
layout.separator()
|
||||
|
||||
@ -2275,8 +2268,6 @@ class VIEW3D_MT_select_edit_armature(Menu):
|
||||
props.extend = False
|
||||
props.direction = 'CHILD'
|
||||
|
||||
layout.separator()
|
||||
|
||||
props = layout.operator("armature.select_hierarchy", text="Extend Parent")
|
||||
props.extend = True
|
||||
props.direction = 'PARENT'
|
||||
@ -2285,9 +2276,6 @@ class VIEW3D_MT_select_edit_armature(Menu):
|
||||
props.extend = True
|
||||
props.direction = 'CHILD'
|
||||
|
||||
layout.operator_menu_enum("armature.select_similar", "type", text="Similar")
|
||||
layout.operator("object.select_pattern", text="Select Pattern...")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_edit_grease_pencil(Menu):
|
||||
bl_label = "Select"
|
||||
@ -2301,9 +2289,17 @@ class VIEW3D_MT_select_edit_grease_pencil(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("grease_pencil.select_linked", text="Linked")
|
||||
layout.operator("grease_pencil.select_alternate", text="Alternated")
|
||||
layout.operator("grease_pencil.select_random", text="Random")
|
||||
layout.operator("grease_pencil.select_random")
|
||||
layout.operator("grease_pencil.select_alternate")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("grease_pencil.select_more", text="More")
|
||||
layout.operator("grease_pencil.select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("grease_pencil.select_linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
@ -2314,11 +2310,6 @@ class VIEW3D_MT_select_edit_grease_pencil(Menu):
|
||||
props.amount_start = 0
|
||||
props.amount_end = 1
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("grease_pencil.select_more")
|
||||
layout.operator("grease_pencil.select_less")
|
||||
|
||||
|
||||
class VIEW3D_MT_paint_grease_pencil(Menu):
|
||||
bl_label = "Draw"
|
||||
@ -2371,23 +2362,23 @@ class VIEW3D_MT_select_edit_gpencil(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("gpencil.select_linked", text="Linked")
|
||||
layout.operator("gpencil.select_alternate")
|
||||
layout.operator("gpencil.select_random")
|
||||
layout.operator_menu_enum("gpencil.select_grouped", "type", text="Grouped")
|
||||
|
||||
if context.mode == 'VERTEX_GPENCIL':
|
||||
layout.operator("gpencil.select_vertex_color", text="Color Attribute")
|
||||
layout.operator("gpencil.select_random", text="Select Random")
|
||||
layout.operator("gpencil.select_alternate", text="Select Alternated")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("gpencil.select_first")
|
||||
layout.operator("gpencil.select_last")
|
||||
layout.operator("gpencil.select_more", text="More")
|
||||
layout.operator("gpencil.select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("gpencil.select_more")
|
||||
layout.operator("gpencil.select_less")
|
||||
layout.operator_menu_enum("gpencil.select_grouped", "type")
|
||||
layout.operator("gpencil.select_linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("gpencil.select_first", text="First")
|
||||
layout.operator("gpencil.select_last", text="Last")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_paint_mask(Menu):
|
||||
@ -2400,9 +2391,6 @@ class VIEW3D_MT_select_paint_mask(Menu):
|
||||
layout.operator("paint.face_select_all", text="None").action = 'DESELECT'
|
||||
layout.operator("paint.face_select_all", text="Invert").action = 'INVERT'
|
||||
|
||||
layout.operator("paint.face_select_more")
|
||||
layout.operator("paint.face_select_less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("view3d.select_box")
|
||||
@ -2411,7 +2399,12 @@ class VIEW3D_MT_select_paint_mask(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("paint.face_select_linked", text="Linked")
|
||||
layout.operator("paint.face_select_more", text="More")
|
||||
layout.operator("paint.face_select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("paint.face_select_linked")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_paint_mask_vertex(Menu):
|
||||
@ -2424,9 +2417,6 @@ class VIEW3D_MT_select_paint_mask_vertex(Menu):
|
||||
layout.operator("paint.vert_select_all", text="None").action = 'DESELECT'
|
||||
layout.operator("paint.vert_select_all", text="Invert").action = 'INVERT'
|
||||
|
||||
layout.operator("paint.vert_select_more")
|
||||
layout.operator("paint.vert_select_less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("view3d.select_box")
|
||||
@ -2435,9 +2425,17 @@ class VIEW3D_MT_select_paint_mask_vertex(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("paint.vert_select_ungrouped", text="Ungrouped Vertices")
|
||||
layout.operator("paint.vert_select_more", text="More")
|
||||
layout.operator("paint.vert_select_less", text="Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("paint.vert_select_linked", text="Select Linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("paint.vert_select_ungrouped", text="Ungrouped Vertices")
|
||||
|
||||
|
||||
class VIEW3D_MT_select_edit_point_cloud(Menu):
|
||||
bl_label = "Select"
|
||||
@ -2469,13 +2467,19 @@ class VIEW3D_MT_select_edit_curves(Menu):
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curves.select_random", text="Random")
|
||||
layout.operator("curves.select_ends", text="Endpoints")
|
||||
layout.operator("curves.select_linked", text="Linked")
|
||||
layout.operator("curves.select_random")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("VIEW3D_MT_edit_curves_select_more_less")
|
||||
layout.menu("VIEW3D_MT_edit_curves_select_more_less", text="More/Less")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curves.select_linked")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curves.select_ends", text="Endpoints")
|
||||
|
||||
layout.template_node_operator_asset_menu_items(catalog_path=self.bl_label)
|
||||
|
||||
@ -2489,9 +2493,15 @@ class VIEW3D_MT_select_sculpt_curves(Menu):
|
||||
layout.operator("curves.select_all", text="All").action = 'SELECT'
|
||||
layout.operator("curves.select_all", text="None").action = 'DESELECT'
|
||||
layout.operator("curves.select_all", text="Invert").action = 'INVERT'
|
||||
layout.operator("sculpt_curves.select_random", text="Random")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("sculpt_curves.select_random")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator("curves.select_ends", text="Endpoints")
|
||||
layout.operator("sculpt_curves.select_grow", text="Grow")
|
||||
layout.operator("sculpt_curves.select_grow", text="Grow Selection")
|
||||
|
||||
layout.template_node_operator_asset_menu_items(catalog_path="Select")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user