user: Show practical ways to work with Bpy.Ops.Outliner in a Blender add-on or script – include code.

assistant:  internal clipboard bpy.ops.outliner. id_delete ( ) ¶ Delete the ID under cursor bpy.ops.outliner. id_linked_relocate ( ) ¶ Replace the active linked ID (and its dependencies if any) by another one, from the same or a different library bpy.ops.outliner. id_operation ( * , type = 'UNLINK' ) ¶ General data-block management operations Parameters : type (enum in [ 'UNLINK' , 'LOCAL' , 'SINGLE' , 'DELETE' , 'REMAP' , 'COPY' , 'PASTE' , 'ADD_FAKE' , 'CLEAR_FAKE' , 'RENAME' , 'SELECT_LINKED' ], (optional)) – ID Data Operation UNLINK Unlink. LOCAL Make Local. SINGLE Make Single User. DELETE Delete. REMAP Remap Users – Make all users of selected data-blocks to use instead current (clicked) one. COPY Copy. PASTE Paste. ADD_FAKE Add Fake User – Ensure data-block gets saved even if it isn’t in use (e.g. for motion and material libraries). CLEAR_FAKE Clear Fake User. RENAME Rename. SELECT_LINKED Select Linked. bpy.ops.outliner. id_paste ( ) ¶ Paste data-blocks from the internal clipboard bpy.ops.outliner. id_remap ( * , id_type = 'OBJECT' , old_id = '' , new_id = '' ) ¶ Undocumented, consider contributing . Parameters : id_type (enum in Id Type Items , (optional)) – ID Type old_id ( enum in [ ] , ( optional ) ) – Old ID, Old ID to replace new_id ( enum in [ ] , ( optional ) ) – New ID, New ID to remap all selected IDs’ users to bpy.ops.outliner. item_activate ( * , extend = False , extend_range = False , deselect_all = False , recurse = False ) ¶ Handle mouse clicks to select and activate items Parameters : extend ( boolean , ( optional ) ) – Extend, Extend selection for activation extend_range ( boolean , ( optional ) ) – Extend Range, Select a range from active element deselect_all ( boolean , ( optional ) ) – Deselect On Nothing, Deselect all when nothing under the cursor recurse ( boolean , ( optional ) ) – Recurse, Select objects recursively from active element bpy.ops.outliner. item_drag_drop ( ) ¶ Drag and drop element to another place bpy.ops.outliner. item_openclose ( * , all = False ) ¶ Toggle whether item under cursor is enabled or closed Parameters : all ( boolean , ( optional ) ) – All, Close or open all items bpy.ops.outliner. item_rename ( * , use_active = False ) ¶ Rename the active element Parameters : use_active ( boolean , ( optional ) ) – Use Active, Rename the active item, rather than the one the mouse is over bpy.ops.outliner. keyingset_add_selected ( ) ¶ Add selected items (blue-gray rows) to active Keying Set bpy.ops.outliner. keyingset_remove_selected ( ) ¶ Remove selected items (blue-gray rows) from active Keying Set bpy.ops.outliner. lib_operation ( * , type = 'DELETE' ) ¶ Undocumented, consider contributing . Parameters : type (enum in [ 'DELETE' , 'RELOCATE' , 'RELOAD' ], (optional)) – Library Operation DELETE Delete – Delete this library and all its items. RELOCATE Relocate – Select a new path for this library, and reload all its data. RELOAD Reload – Reload all data from this library. bpy.ops.outliner. lib_relocate ( ) ¶ Relocate the library under cursor bpy.ops.outliner. liboverride_operation ( * , type = 'OVERRIDE_LIBRARY_CREATE_HIERARCHY' , selection_set = 'SELECTED' ) ¶ Create, reset or clear library override hierarchies Parameters : type (enum in [ 'OVERRIDE_LIBRARY_CREATE_HIERARCHY' , 'OVERRIDE_LIBRARY_RESET' , 'OVERRIDE_LIBRARY_CLEAR_SINGLE' ], (optional)) – Library Override Operation OVERRIDE_LIBRARY_CREATE_HIERARCHY Make – Create a local override of the selected linked data-blocks, and their hierarchy of dependencies. OVERRIDE_LIBRARY_RESET Reset – Reset the selected local overrides to their linked references values. OVERRIDE_LIBRARY_CLEAR_SINGLE Clear – Delete the selected local overrides and relink their usages to the linked data-blocks if possible, else reset them and mark them as non editable. selection_set (enum in [ 'SELECTED' , 'CONTENT' , 'SELECTED_AND_CONTENT' ], (optional)) – Selection Set, Over which part of the tree items to apply the operation SELECTED Selected – Apply the operation over selected data-blocks only. CONTENT Content – Apply the operation over content of the selected items only (the data-blocks in their sub-tree). SELECTED_AND_CONTENT Selected & Content – Apply the operation over selected data-blocks and all their dependencies. bpy.ops.outliner. liboverride_troubleshoot_operation ( * , type = 'OVERRIDE_LIBRARY_RESYNC_HIERARCHY' , selection_set = 'SELECTED' ) ¶ Advanced operations over library override to help fix broken hierarchies Parameters : type (enum in [ 'OVERRIDE_LIBRARY_RESYNC_HIERARCHY' , 'OVERRIDE_LIBRARY_RESYNC_HIERARCHY_ENFORCE' , 'OVERRIDE_LIBRARY_DELETE_HIERARCHY' ], (optional)) – Library Override Troubleshoot Operation OVERRIDE_LIBRARY_RESYNC_HIERARCHY Resync – Rebuild the selected local overrides from their linked references, as well as their hierarchies of dependencies. OVERRIDE_LIBRARY_RESYNC_HIERARCHY_ENFORCE Resync Enforce – Rebuild the selected local overrides from their linked references, as well as their hierarchies of dependencies, enforcing these hierarchies to match the linked data (i.e. ignoring existing overrides on data-blocks pointer properties). OVERRIDE_LIBRARY_DELETE_HIERARCHY Delete – Delete the selected local overrides (including their hierarchies of override dependencies) and relink their usages to the linked data-blocks. selection_set (enum in [ 'SELECTED' , 'CONTENT' , 'SELECTED_AND_CONTENT' ], (optional)) – Selection Set, Over which part of the tree items to apply the operation SELECTED Selected – Apply the operation over selected data-blocks only. CONTENT Content – Apply the operation over content of the selected items only (the data-blocks in their sub-tree). SELECTED_AND_CONTENT Selected & Content – Apply the operation over selected data-blocks and all their dependencies. bpy.ops.outliner. material_drop ( ) ¶ Drag material to object in Outliner bpy.ops.outliner. modifier_operation ( * , type = 'APPLY' ) ¶ Undocumented, consider contributing . Parameters : type (enum in [ 'APPLY' , 'DELETE' , 'TOGVIS' , 'TOGREN' ], (optional)) – Modifier Operation bpy.ops.outliner. object_operation ( * , type = 'SELECT' ) ¶ Undocumented, consider contributing . Parameters : type (enum in [ 'SELECT' , 'DESELECT' , 'SELECT_HIERARCHY' , 'REMAP' , 'RENAME' ], (optional)) – Object Operation SELECT Select. DESELECT Deselect. SELECT_HIERARCHY Select Hierarchy. REMAP Remap Users – Make all users of selected data-blocks to use instead a new chosen one. RENAME Rename. bpy.ops.outliner. operation ( ) ¶ Context menu for item operations bpy.ops.outliner. orphans_manage ( ) ¶ Open a window to manage unused data bpy.ops.outliner. orphans_purge ( * , do_local_ids = True , do_linked_ids = True , do_recursive = True ) ¶ Clear all orphaned data-blocks without any users from the file Parameters : do_local_ids ( boolean , ( optional ) ) – Local Data-blocks, Include unused local data-blocks into deletion do_linked_ids ( boolean , ( optional ) ) – Linked Data-blocks, Include unused linked data-blocks into deletion do_recursive ( boolean , ( optional ) ) – Recursive Delete, Recursively check for indirectly unused data-blocks, ensuring that no orphaned data-blocks remain after execution bpy.ops.outliner. parent_clear ( ) ¶ Drag to clear parent in Outliner bpy.ops.outliner. parent_drop ( ) ¶ Drag to parent in Outliner bpy.ops.outliner. scene_drop ( ) ¶ Drag object to scene in Outliner bpy.ops.outliner. scene_operation ( * , type = 'DELETE' ) ¶ Context menu for scene operations Parameters : type (enum in [ 'DELETE' ], (optional)) – Scene Operation bpy.ops.outliner. scroll_page ( * , up = False ) ¶ Scroll page up or down Parameters : up ( boolean , ( optional ) ) – Up, Scroll up one page bpy.ops.outliner. select_all ( * , action = 'TOGGLE' ) ¶ Toggle the Outliner selection of items Parameters : action (enum in [ 'TOGGLE' , 'SELECT' , 'DESELECT' , 'INVERT' ], (optional)) – Action, Selection action to execute TOGGLE Toggle – Toggle selection for all elements. SELECT Select – Select all elements. DESELECT Deselect – Deselect all elements. INVERT Invert – Invert selection of all elements. bpy.ops.outliner. select_box ( * , tweak = False , xmin = 0 , xmax = 0 , ymin = 0 , ymax = 0 , wait_for_input = True , mode = 'SET' ) ¶ Use box selection to select tree elements Parameters : tweak ( boolean , ( optional ) ) – Tweak, Tweak gesture from empty space for box selection xmin ( int in [ -inf , inf ] , ( optional ) ) – X Min xmax ( int in [ -inf , inf ] , ( optional ) ) – X Max ymin ( int in [ -inf , inf ] , ( optional ) ) – Y Min ymax ( int in [ -inf , inf ] , ( optional ) ) – Y Max wait_for_input ( boolean , ( optional ) ) – Wait for Input mode (enum in [ 'SET' , 'ADD' , 'SUB' ], (optional)) – Mode SET Set – Set a new selection. ADD Extend – Extend existing selection. SUB Subtract – Subtract existing selection. bpy.ops.outliner. select_walk ( * , direction = 'UP' , extend = False , toggle_all = False ) ¶ Use walk navigation to select tree elements Parameters : direction (enum in [ 'UP' , 'DOWN' , 'LEFT' , 'RIGHT' ], (optional)) – Walk Direction, Select/Deselect element in this direction extend ( boolean , ( optional ) ) – Extend, Extend selection on walk toggle_all ( boolean , ( optional ) ) – Toggle All, Toggle open/close hierarchy bpy.ops.outliner. show_active ( ) ¶ Open up the tree and adjust the view so that the active object is shown centered bpy.ops.outliner. show_hierarchy ( ) ¶ Open all object entries and close all others bpy.ops.outliner. show_one_level ( * , open = True ) ¶ Expand/collapse all entries by one level Parameters : open ( boolean , ( optional ) ) – Open, Expand all entries one level deep bpy.ops.outliner. start_filter ( ) ¶ Start entering filter text bpy.ops.outliner. unhide_all ( ) ¶ Unhide all objects and collections Next Paint Operators Previous Object Operators Copyright &#169; Blender Authors Made with Furo Report issue on this page On this page Outliner Operators action_set() animdata_operation() clear_filter() collection_color_tag_set() collection_disable() collection_disable_render() collection_drop() collection_duplicate() collection_duplicate_linked() collection_enable() collection_enable_render() collection_exclude_clear() collection_exclude_set() collection_hide() collection_hide_inside() collection_hierarchy_delete() collection_holdout_clear() collection_holdout_set() collection_indirect_only_clear() collection_indirect_only_set() collection_instance() collection_isolate() collection_link() collection_new() collection_objects_deselect() collection_objects_select() collection_show() collection_show_inside() constraint_operation() data_operation() datastack_drop() delete() drivers_add_selected() drivers_delete_selected() expanded_toggle() hide() highlight_update() id_copy() id_delete() id_linked_relocate() id_operation() id_paste() id_remap() item_activate() item_drag_drop() item_openclose() item_rename() keyingset_add_selected() keyingset_remove_selected() lib_operation() lib_relocate() liboverride_operation() liboverride_troubleshoot_operation() material_drop() modifier_operation() object_operation() operation() orphans_manage() orphans_purge() parent_clear() parent_drop() scene_drop() scene_operation() scroll_page() select_all() select_box() select_walk() show_active() show_hierarchy() show_one_level() start_filter() unhide_all()