Author: Jeremy Ernst
ART_AddModuleToCanvas(animPickerUI, modulesToAdd, parent=None)¶
This tool presents a UI that lists all modules not currently on the animation picker canvas, and allows the user to choose modules from the list to add to the animation picker canvas. This is an animator-facing tool.
__init__(animPickerUI, modulesToAdd, parent=None)¶
initialize the class, get the QSettings for the tool, and call on buildUI.
- animPickerUI – the instance of the animation picker class that launched this class.
- modulesToAdd – A list of the modules to add, which is a list of modules currently not on the animPickerUI
Take the modules passed into the class, and if the modules do not already exist on the canvas, add them to the list widget.
Takes the selected module in the list widget and adds it to the picker canvas. The picker UI is contained in the self.pickerUI.
Builds the interface for the tool, showing a list of modules not currently displayed on the picker.
deletes the UI.
Get the current tab of the current character of the animation picker. :return: returns the QGraphicsScene that items can then be added to.
Find all existing modules on the canvas and return those modules as a list. :return: List of modules whose picker exists on the canvas.
Take the passed in children and mirror the item so the text is not backwards. When a module is added to the canvas, if it was a right side module, it will be mirrored. This then unmirrors the text.
Parameters: children – List of QGraphicsSimpleTextItems that need to be mirrored.