Post #3039: @roaoao Could I borrow a moment of your time ?

📋 Metadata

🏷️ Tags

macro hotkeys configuration intermediate unsolved

  • Macro Editor
  • Hotkey Configuration
  • Python Scripting

💬 Content

@roaoao Could I borrow a moment of your time ?
I am trying to assign hotkey 1, 2, 3 to switch between vert edge face selection in UV editor both in UV sync selection on and off.
while UV sync selection is off, I use command
bpy.context.scene.tool_settings.uv_select_mode = ‘VERTEX’ etc to switch
and while UV sync selection is on, I use command
bpy.context.tool_settings.mesh_select_mode = (True, False, False) etc to switch between vert edge and face.
but with the condition
bpy.context.scene.tool_settings.use_uv_select_sync = False
I can not piece them together to work. I got invalid syntax.

bpy.context.scene.tool_settings.uv_select_mode = ‘VERTEX’ if bpy.context.scene.tool_settings.use_uv_select_sync = False
else bpy.context.tool_settings.mesh_select_mode = (True, False, False)

currently I use 1,2,3 while uv sync selection is off and 4,5,6 while uv sync selection is on to switch between vert edge and face selection.


🔗 View on Blender Artists