A: how to remove the add meshes panel from the tool shelf in edit mode? “unregister_class” dose not seem to remove it like it dose everything else
B: how to set the 3d viewport as the active context
C: how to remove the default shortcut keys
its for an addon some guy wants me to make so dont worry about why any one would ever want this… not my problem so please no “why would you do this”
for A i am useing
gpclasses = [c for c in dir(bpy.types)
if c.startswith("VIEW3D_PT_tools_add_object")
]
for c in gpclasses:
cls = getattr(bpy.types, c)
unregister_class(cls)
for C i can do it by importing a key config but i would be best if i did not need to have an extra file thats needed for the addon to work
ok update on B this seems to work to full screen it but it not setting it as active so other things still dont work… things like bpy.context.space_data.show_textured_solid = True
for area in bpy.context.screen.areas:
if area.type == 'VIEW_3D':
override = bpy.context.copy()
override['area'] = area
bpy.ops.screen.screen_full_area(override,use_hide_panels=True)
break
another update on B i think i worked out everything thats needed for it… this seems to work for all other code
for area in bpy.context.screen.areas:
if area.type == 'VIEW_3D':
override = bpy.context.copy()
override['area'] = area
area.spaces[0].viewport_shade = 'SOLID'
area.spaces[0].fx_settings.use_ssao = True
area.spaces[0].show_only_render = True
area.spaces[0].show_textured_solid = True
break
so now just A and C altho A could be because of a crazy addon thats not effected by restoring factory settings? dont know how to reinstall blender with out it using the meta from the other so i will just leave that for now