CARVIEW |
Select Language
HTTP/2 200
date: Sat, 11 Oct 2025 09:46:21 GMT
content-type: text/html; charset=UTF-8
server: cloudflare
x-frame-options: DENY
x-content-type-options: nosniff
x-xss-protection: 1;mode=block
vary: accept-encoding
cf-cache-status: DYNAMIC
content-encoding: gzip
set-cookie: _csrf-frontend=55a3ecf693571f25477f984498ed08d1182ab6db13efd9f4ad5bd6583a2b1af7a%3A2%3A%7Bi%3A0%3Bs%3A14%3A%22_csrf-frontend%22%3Bi%3A1%3Bs%3A32%3A%22MJqCz1FxllKEQzl_0yH076Yp7DJIXjLv%22%3B%7D; HttpOnly; Path=/
cf-ray: 98cd6e0c8b86f424-BLR
Move/Rotate/Scale - Vertex/Edge/Face - Workspaces in Context Menu - Pastebin.com
SHARE
TWEET

Move/Rotate/Scale - Vertex/Edge/Face - Workspaces in Context Menu
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- bl_info = {
- 'name': 'Move/Rotate/Scale - Vertex/Edge/Face - Workspaces in Context Menu',
- 'author': 'TBussinger',
- 'version': (1, 0, 0),
- 'blender': (4, 0, 0),
- 'location': 'Right-Click in any 3D View',
- 'description': 'Adds Move/Rotate/Scale - Vertex/Edge/Face - Workspaces to the 3D View context menus',
- 'category': '3D View',
- }
- import bpy
- from bpy.props import StringProperty
- # --- Workspace switcher (flyout) ---
- WORKSPACES = [
- 'Layout', 'Modeling', 'Sculpting', 'UV Editing', 'Texture Paint',
- 'Shading', 'Animation', 'Rendering', 'Compositing', 'Geometry Nodes', 'Scripting'
- ]
- class WM_OT_switch_workspace_quick(bpy.types.Operator):
- bl_idname = 'wm.switch_workspace_quick'
- bl_label = 'Switch Workspace'
- bl_description = 'Switch the active workspace'
- bl_options = {'INTERNAL'}
- workspace: StringProperty(name='Workspace')
- @classmethod
- def description(cls, context, properties):
- ws = getattr(properties, 'workspace', '')
- return f'Switch to "{ws}" workspace' if ws else 'Switch the active workspace'
- def execute(self, context):
- ws = bpy.data.workspaces.get(self.workspace)
- if not ws:
- self.report({'WARNING'}, 'Workspace "%s" not found' % self.workspace)
- return {'CANCELLED'}
- context.window.workspace = ws
- return {'FINISHED'}
- class VIEW3D_MT_workspace_quick(bpy.types.Menu):
- bl_label = 'Workspaces'
- bl_idname = 'VIEW3D_MT_workspace_quick'
- def draw(self, context):
- layout = self.layout
- col = layout.column(align=True)
- for name in WORKSPACES:
- col.operator('wm.switch_workspace_quick', text=name).workspace = name
- # --- Context menu injection ---
- def draw_trs(self, context):
- layout = self.layout
- layout.separator()
- col = layout.column(align=True)
- col.label(text='Tools')
- col.operator('wm.tool_set_by_id', text='Move').name = 'builtin.move'
- col.operator('wm.tool_set_by_id', text='Rotate').name = 'builtin.rotate'
- col.operator('wm.tool_set_by_id', text='Scale').name = 'builtin.scale'
- col = layout.column(align=True)
- col.label(text='Select Mode')
- col.enabled = (context.mode == 'EDIT_MESH')
- col.operator('mesh.select_mode', text='Vertex', icon='VERTEXSEL').type = 'VERT'
- col.operator('mesh.select_mode', text='Edge', icon='EDGESEL').type = 'EDGE'
- col.operator('mesh.select_mode', text='Face', icon='FACESEL').type = 'FACE'
- layout.separator()
- op = layout.operator('wm.call_menu', text='Workspaces...')
- op.name = 'VIEW3D_MT_workspace_quick'
- MENUS = (
- 'VIEW3D_MT_object_context_menu',
- 'VIEW3D_MT_edit_mesh_context_menu',
- 'VIEW3D_MT_edit_curve_context_menu',
- 'VIEW3D_MT_edit_armature_context_menu',
- 'VIEW3D_MT_pose_context_menu',
- )
- classes = (
- WM_OT_switch_workspace_quick,
- VIEW3D_MT_workspace_quick,
- )
- def register():
- for c in classes:
- bpy.utils.register_class(c)
- for menu_id in MENUS:
- menu = getattr(bpy.types, menu_id, None)
- if menu:
- menu.prepend(draw_trs)
- def unregister():
- for menu_id in MENUS:
- menu = getattr(bpy.types, menu_id, None)
- if menu:
- try:
- menu.remove(draw_trs)
- except Exception:
- pass
- for c in reversed(classes):
- try:
- bpy.utils.unregister_class(c)
- except Exception:
- pass
- if __name__ == '__main__':
- try:
- unregister()
- except Exception:
- pass
- register()
Advertisement
Add Comment
Please, Sign In to add comment
-
⭐⭐⭐ G2A Payment Exploit ✅ NEVER SEEN BEFORE ⭐...
JavaScript | 5 sec ago | 0.24 KB
-
⭐✅ MAKE $2500 IN 15 MIN ✅ NEVER SEEN BEFORE ⭐...
JavaScript | 15 sec ago | 0.24 KB
-
⭐✅ Swapzone Glitch ✅ Working⭐⭐⭐ L
JavaScript | 16 sec ago | 0.24 KB
-
⭐✅ MAKE $2500 IN 15 MIN⭐⭐⭐ 4
JavaScript | 19 sec ago | 0.24 KB
-
⭐⭐⭐Make $15OO in 2O minutesV E⭐⭐
Java | 21 sec ago | 0.10 KB
-
⭐ ✅ Free Products Method ✅ ✅ NEVER SEEN BEFOR...
JavaScript | 24 sec ago | 0.24 KB
-
✅ Make $2500 in 20 minutes⭐⭐⭐ J
JavaScript | 27 sec ago | 0.24 KB
-
⭐✅ Exploit 2500$ in 15 Minutes⭐⭐⭐ T
JavaScript | 30 sec ago | 0.24 KB
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand