VivoQuant 6.4.0
Loading...
Searching...
No Matches
VisibilityManager Class Reference

Description

Manage hiding and disabling of widgets, actions, operators, and views that are in the VivoQuant UI.

Public Member Functions

void setVisible (QObject *object, bool visible, bool perm=false)
 Sets an object's visibility.
void setEnabled (QObject *object, bool enabled, bool perm=false)
 Sets whether an object (a widget or an action) is enabled.
void setViewEnabled (string view, bool enabled, bool perm=false)
 Sets whether a view is enabled.
void setDataMenuOptionEnabled (string name, bool enabled, bool perm=false)
 Sets whether an option in the data menu is enabled or disabled. These options are available when you right click on data in the data list.
void setOperatorVisible (string opStr, bool vis, bool perm=false)
 Sets whether an operator is visible.
void setOperatorEnabled (string opStr, bool en, bool perm=false)
 Sets whether an operator is enabled.
void reset ()
 Resets the non-permanent changes made by the visibility manager.

Member Function Documentation

◆ setDataMenuOptionEnabled()

void setDataMenuOptionEnabled ( string name,
bool enabled,
bool perm = false )

Sets whether an option in the data menu is enabled or disabled. These options are available when you right click on data in the data list.

Parameters
nameThe name of the option as it appears in the menu
enabledWhether the option will be enabled or disabled
perm(optional, default is false) Whether this change will persist after the script ends.

◆ setEnabled()

void setEnabled ( QObject * object,
bool enabled,
bool perm = false )

Sets whether an object (a widget or an action) is enabled.

Parameters
objectThe object. See VQ.getWidget() and VQ.getAction() for how to lookup a QObject by name
enabledWhether the object will be enabled or disabled
perm(optional, default is false) Whether this change will persist after the script ends.

◆ setOperatorEnabled()

void setOperatorEnabled ( string opStr,
bool en,
bool perm = false )

Sets whether an operator is enabled.

Parameters
opStrThe name of the operator, either "Operator" or "View|Operator" (If View is not provided, the operator is assumed to be in the current view)
enWhether the operator will be enabled
perm(optional, default is false) Whether this change will persist after the script ends.

◆ setOperatorVisible()

void setOperatorVisible ( string opStr,
bool vis,
bool perm = false )

Sets whether an operator is visible.

Parameters
opStrThe name of the operator, either "Operator" or "View|Operator" (If View is not provided, the operator is assumed to be in the current view)
visWhether the operator will be visible
perm(optional, default is false) Whether this change will persist after the script ends.

◆ setViewEnabled()

void setViewEnabled ( string view,
bool enabled,
bool perm = false )

Sets whether a view is enabled.

Parameters
viewThe name of the view
enabledWhether the view will be enabled or disabled
perm(optional, default is false) Whether this change will persist after the script ends.

◆ setVisible()

void setVisible ( QObject * object,
bool visible,
bool perm = false )

Sets an object's visibility.

Parameters
objectThe object. See VQ.getWidget() and VQ.getAction() for how to lookup a QObject by name.
visibleThe desired visibility of the object
perm(optional, default is false) Whether this change will persist after the script ends.