bgdev.utils.attribute¶
Attribute utilities.
- author
Benoit Gielly (benoit.gielly@gmail.com)
-
attributes_restore(node)[source]¶ Restore previously unlocked attributes to their default state.
- Parameters
node (str) – Node to restore attributes
- Returns
False if attribute doesn’t exists else True
- Return type
bool
-
attributes_toggle(nodes=None, attr_list=None)[source]¶ Toggle attributes between default and unlocked states.
- Parameters
nodes (list) – List of nodes to toggle. If not given, use viewport selection.
attr_list (list) – List of extra attributes to toggle
-
attributes_unlock(node, base=True, user=True, attr_list=None)[source]¶ Unlock attributes on given node
- Parameters
node (str) – Node to unlock attributes
attr_list (list) – List of extra attributes to toggle
base (bool) – If True, will toggle base attributes (translate, rotate, scale, visibility).
user (bool) – If True, will toggle user’s attributes.