Miscellaneous shared functions for Vuo Editor.
Definition at line 19 of file VuoEditorUtilities.hh.
Static Public Member Functions | |
static QPixmap | vuoLogoForDialogs () |
Returns a retina-compatible logo of the appropriate size for popup dialog windows. More... | |
static Q_INVOKABLE QString | getHTMLForSVG (QString svgPath, int pointsWide, int pointsHigh) |
Returns a data-URI-encoded rendering of an SVG (since Qt fails to render inline SVGs at Retina resolution). More... | |
static void | openUserModulesFolder () |
Opens the user's Modules folder in Finder. More... | |
static void | openSystemModulesFolder () |
Opens the system's Modules folder in Finder. More... | |
static bool | optionKeyPressedForEvent (QEvent *event) |
Returns a boolean indicating whether the "Option" key was pressed in conjunction with the provided event . More... | |
static bool | isNodeClassEditable (VuoNodeClass *nodeClass, QString &editLabel, QString &sourcePath) |
Checks if the node class has source code that the user can edit, and if so, provides some information about it. More... | |
static bool | isNodeClassSuccessorTo (QString oldNodeClass, QString newNodeClass) |
Checks whether a given node class is the recommended replacement for another given node class. More... | |
static QList< QMainWindow * > | getOpenEditingWindows () |
Returns a list of currently open composition- and code-editing windows, sorted case-insensitively by window title. More... | |
static QList< VuoEditorWindow * > | getOpenCompositionEditingWindows () |
Returns a list of currently open composition-editing windows, sorted case-insensitively by window title. More... | |
static QList< QMainWindow * > | getOpenEditingWindowsStacked () |
Returns a list of currently open composition- and code-editing windows, sorted by stacking order (frontmost first). More... | |
static QMainWindow * | existingWindowWithFile (const QString &filename) |
Returns an open composition- or code-editing window editing filename, if one exists. More... | |
static QAction * | getRaiseDocumentActionForWindow (QMainWindow *window) |
Returns VuoEditorWindow::getRaiseDocumentAction or VuoCodeWindow::getRaiseDocumentAction. More... | |
static VuoRecentFileMenu * | getRecentFileMenuForWindow (QMainWindow *window) |
Hack in place of proper polymorphism. More... | |
static QMenu * | getFileMenuForWindow (QMainWindow *window) |
Hack in place of proper polymorphism. More... | |
static void | setWindowAsActiveWindow (QMainWindow *window) |
Hack in place of proper polymorphism. More... | |
static void | setWindowOpacity (QMainWindow *window, int opacity) |
Sets the canvas opacity level to the provided opacity value, where a value of 0 means that the canvas should be fully transparent and 255 means that it should be fully opaque. More... | |
|
static |
Returns an open composition- or code-editing window editing filename, if one exists.
Otherwise returns NULL.
Definition at line 313 of file VuoEditorUtilities.cc.
|
static |
Hack in place of proper polymorphism.
Definition at line 368 of file VuoEditorUtilities.cc.
|
static |
Returns a data-URI-encoded rendering of an SVG (since Qt fails to render inline SVGs at Retina resolution).
Definition at line 41 of file VuoEditorUtilities.cc.
|
static |
Returns a list of currently open composition-editing windows, sorted case-insensitively by window title.
Definition at line 278 of file VuoEditorUtilities.cc.
|
static |
Returns a list of currently open composition- and code-editing windows, sorted case-insensitively by window title.
Definition at line 261 of file VuoEditorUtilities.cc.
|
static |
Returns a list of currently open composition- and code-editing windows, sorted by stacking order (frontmost first).
Definition at line 291 of file VuoEditorUtilities.cc.
|
static |
Returns VuoEditorWindow::getRaiseDocumentAction or VuoCodeWindow::getRaiseDocumentAction.
A hack in place of proper polymorphism.
Definition at line 328 of file VuoEditorUtilities.cc.
|
static |
Hack in place of proper polymorphism.
Definition at line 348 of file VuoEditorUtilities.cc.
|
static |
Checks if the node class has source code that the user can edit, and if so, provides some information about it.
nodeClass | The node class to check. | |
[out] | editLabel | Translated text for a link or action to edit the source code, customized to the type of source code. |
[out] | sourcePath | Path of the source code file. |
Definition at line 164 of file VuoEditorUtilities.cc.
|
static |
Checks whether a given node class is the recommended replacement for another given node class.
oldNodeClass | The node class to be replaced. |
newNodeClass | The potential replacement node class. |
newNodeClass
is the successor to oldNodeClass
, false otherwise. Definition at line 196 of file VuoEditorUtilities.cc.
|
static |
Opens the system's Modules folder in Finder.
Definition at line 81 of file VuoEditorUtilities.cc.
|
static |
Opens the user's Modules folder in Finder.
Definition at line 65 of file VuoEditorUtilities.cc.
|
static |
Returns a boolean indicating whether the "Option" key was pressed in conjunction with the provided event
.
This method works reliably even when the event originated from another application while the Vuo Editor was inactive, e.g., when dragging and dropping files from the Finder.
Definition at line 143 of file VuoEditorUtilities.cc.
|
static |
Hack in place of proper polymorphism.
Definition at line 388 of file VuoEditorUtilities.cc.
|
static |
Sets the canvas opacity level to the provided opacity
value, where a value of 0 means that the canvas should be fully transparent and 255 means that it should be fully opaque.
Definition at line 408 of file VuoEditorUtilities.cc.
|
static |
Returns a retina-compatible logo of the appropriate size for popup dialog windows.
Definition at line 28 of file VuoEditorUtilities.cc.