Post #185:
fj
π Metadata
- Author: roaoao
- Date: 2016-06-02 03:44:11
- Type:
answer - Quality Score: 8/10
- Reply to: post_00184
- Replies (2): post_00186, post_02769
π·οΈ Tags
pie-menu popup-dialog scripting intermediate solved
βοΈ Related PME Features
- Pie Menu Editor
- Popup Dialog Editor
- Custom scripting
- Command tab
- Property tab
π¬ Content
fjg3d:
Hi - Setting up some pies, but canβt get the split/join area commands to work. Iβm grabbing them directly from the info window with the debug. Any suggestions on how to properly assign that command?
Hi, fjg3d. Good commands for pies. Yes you can use them.
To split area use this code in Command tab:
bpy.ops.screen.area_split('EXEC_DEFAULT', direction='HORIZONTAL', factor=0.5)
Or:
bpy.ops.screen.area_split('EXEC_DEFAULT', direction='VERTICAL', factor=0.5)
To join areas you have to use external script in Command tab. Download and extract it to pie_menu_editor/scripts folder.
execute_script("scripts/command_join_area.py")
fjg3d:
Also, the move to layer panel - can this be added to a pme panel?
Use this path in Property tab (works in Popup Dialogs only):
C.object.layers
If you want to use that command in pie menus use this code in Custom tab:
L.box().prop(C.object, "layers", "")
Attachments
command_join_area.zip (423 Bytes)