class Tools.Animation.ART_SelectionSetsUI.ART_SelectionSetsUI(parent=None)[source]

This class creates the selection sets interface tool. This tool allows the user to add and modify selection sets.


Instantiates the class, gets settings values from QSettings. Calls on building the interface. Lastly, populates the UI.

_add_button(objectName, tooltip)[source]

Adds toolbar buttons for the tangent tools.

  • image – the image to be used for QIcon
  • tooltip – the tooltip image path

returns the QPushButton created

See also


_add_selection_sets(data, path)[source]

Creates the selection set buttons in the UI.

  • data – The data from the selection set file (name, category, controls)
  • path

    The file path of the selectioh set file.


Clears the given layout of all child widgets

Parameters:layout – the layout to clear widgets from

Find the categories from all of the selection sets and compose a list.

Returns:A list of all categories from the selection sets.

Finds the index of the given text in the category combo box.

Parameters:text – the text to
Returns:returns the index of the text in the category combo box.

Populates the listWidget in the add/remove UI.

Parameters:path – Path to the selection set file.
Returns:returns a list of the controls to add to the list widget.

populate the categories comboBox with the categories found in the selection sets.


Populate the UI with buttons for each selection set. (If the category of the selection set matches the current category, or if the current category is all.)

See also



Takes the passed in controls and strips any namespaces.

Parameters:selection – objects to strip namespaces from
Returns:new list of controls without namespaces
add_remove_set_UI(add, remove, path)[source]

Creates the UI for adding new items to the selection set or removing items from the selection set.

  • add – If add is true, the UI functions will be changed to allow for adding items to the set.
  • remove – if remove is true, the UI functions will be changed to allow for removing items from the set.
  • path – the file path of the selection set
add_to_set(checkbox, path)[source]

Adds current selection to the selection set. Modifies the selection set file to reflect those changes.

  • checkbox – the checkbox widget to see if we should store namespaces or not.
  • path – the selection set file path

Builds the interface for the tool.

See also


See also


See also


createContextMenu(button, point)[source]

Creates a context menu for the selection set buttons.

  • button – Which button to create the context menu for.
  • point

    the cursor position.


Creates a new selection set. Called on from create_new_set_UI().

See also


See also



Builds an interface for creating a new selection set.


Deletes the selection set from disk.

Parameters:path – path of the file to delete.

Removes the selected listWidget items from the selection set, then modifies the selection set file to reflect those changes.

Parameters:path – selection set file path.
rename_set(path, button)[source]

Renames the selection set.

  • path – Selection set file path
  • button – the button widget whose context menu was called. Used to set text of button after the rename.

Selects the controls in the selection set. If shift is held down while selecting, it will append the selection.

Parameters:data – selection set file data (name, category, controls)

Sets the tangents of the selections’ keys to the given tangent type.

Parameters:tangentType – auto, spline, step, flat, etc..
write_set_to_file(file_name, category, selection)[source]

Writes the selection set to disk.

  • file_name – The name of the file and the selection set
  • category – The category name
  • selection – The controls for the selection set[source]

Deletes the UI if it exists, then instatiates the class, building the tool and the UI.

Returns:the instance of this tool