ParaView
Public Slots | Signals | Public Member Functions | Protected Slots | Properties | List of all members
pqColorOpacityEditorWidget Class Reference

pqColorOpacityEditorWidget provides an in-line editor widget for editing the color and opacity transfer functions. More...

#include <pqColorOpacityEditorWidget.h>

Inheritance diagram for pqColorOpacityEditorWidget:
Inheritance graph
[legend]
Collaboration diagram for pqColorOpacityEditorWidget:
Collaboration graph
[legend]

Public Slots

void setXvmsPoints (const QList< QVariant > &)
 Sets the xvmsPoints that control the opacity transfer function. More...
 
void setXrgbPoints (const QList< QVariant > &)
 Sets the xrgbPoints that control the color transfer function. More...
 
void setUseLogScale (bool value)
 Set whether to use-log scale. More...
 
void setLockScalarRange (bool val)
 Set whether the color map range should be locked. More...
 
void setScalarOpacityFunctionProxy (pqSMProxy sofProxy)
 Set the scalar opacity function (or PiecewiseFunction) proxy to use. More...
 
void resetRangeToData ()
 Reset the transfer function ranges to active data source. More...
 
void resetRangeToCustom ()
 Reset the transfer function ranges to custom values. More...
 
void resetRangeToCustom (double min, double max)
 
void resetRangeToDataOverTime ()
 Reset the transfer function ranges to temporal range for active data source. More...
 
void resetRangeToVisibleData ()
 Reset the transfer function ranges to visible range for active data source. More...
 
void invertTransferFunctions ()
 Inverts the transfer functions. More...
 
void choosePreset (const char *presetName=NULL)
 pick a preset. More...
 
void saveAsPreset ()
 save current transfer function as preset. More...
 
- Public Slots inherited from pqPropertyWidget
virtual void setView (pqView *)
 called to set the active view. This will fire the viewChanged() signal. More...
 

Signals

void xrgbPointsChanged ()
 Signal fired when the xrgbPoints change. More...
 
void xvmsPointsChanged ()
 Signal fired when the xvmsPoints change. More...
 
void useLogScaleChanged ()
 Signal fired when useLogScale changes. More...
 
void lockScalarRangeChanged ()
 Signal fired when lockScalarRange changes. More...
 
void scalarOpacityFunctionProxyChanged ()
 This signal is never really fired since this widget doesn't have any UI to allow users to changes the ScalarOpacityFunction proxy used. More...
 
- Signals inherited from pqPropertyWidget
void viewChanged (pqView *view)
 This signal is emitted when the current view changes. More...
 
void changeAvailable ()
 This signal is fired as soon as the user starts editing in the widget. More...
 
void changeFinished ()
 This signal is fired as soon as the user is done with making an atomic change. More...
 
void restartRequired ()
 Indicates that a restart of the program is required for the setting to take effect. More...
 

Public Member Functions

 pqColorOpacityEditorWidget (vtkSMProxy *proxy, vtkSMPropertyGroup *smgroup, QWidget *parent=0)
 
virtual ~pqColorOpacityEditorWidget ()
 
QList< QVariant > xrgbPoints () const
 Returns the current list of control points for the color transfer function. More...
 
QList< QVariant > xvmsPoints () const
 Returns the current list of control points for the opacity function. More...
 
bool useLogScale () const
 Returns the value for use-log-scale. More...
 
bool lockScalarRange () const
 Returns true if the color map range is locked. More...
 
pqSMProxy scalarOpacityFunctionProxy () const
 Returns the scalar opacity function (i.e. More...
 
- Public Member Functions inherited from pqPropertyWidget
 pqPropertyWidget (vtkSMProxy *proxy, QWidget *parent=0)
 
virtual ~pqPropertyWidget ()
 
virtual void apply ()
 
virtual void reset ()
 
virtual void select ()
 These methods are called by pqPropertiesPanel when the panel for proxy becomes active/deactive. More...
 
virtual void deselect ()
 
bool isSelected () const
 
virtual void updateWidget (bool showing_advanced_properties)
 
pqViewview () const
 
vtkSMProxy * proxy () const
 
vtkSMProperty * property () const
 
virtual char * panelVisibility () const
 Forward calls to vtkSMProperty. More...
 
virtual void setPanelVisibility (const char *vis)
 
bool showLabel () const
 
const QList< QPointer< pqPropertyWidgetDecorator > > & decorators () const
 Provides access to the decorators for this widget. More...
 
void setProperty (vtkSMProperty *property)
 

Protected Slots

void opacityCurrentChanged (vtkIdType)
 slots called when the current point changes on the two internal pqTransferFunctionWidget widgets. More...
 
void colorCurrentChanged (vtkIdType)
 
void updatePanel ()
 updates the panel to show/hide advanced settings More...
 
void updateCurrentData ()
 updates the text shown in the "current data" input. More...
 
void currentDataEdited ()
 update the transfer function with the text in CurrentDataValue text field. More...
 
void presetApplied ()
 called when a preset is applied. More...
 
void updateIndexedLookupState ()
 Ensures that the color-swatches for indexedColors are shown only when this is set to true. More...
 
void useLogScaleClicked (bool)
 called when the use-log-scale checkbox is clicked by the user. More...
 
void updateButtonEnableState ()
 called when the active representation or view changes. More...
 

Properties

QList< QVariant > xrgbPoints
 
QList< QVariant > xvmsPoints
 
bool useLogScale
 
bool lockScalarRange
 
pqSMProxy scalarOpacityFunctionProxy
 

Additional Inherited Members

- Static Public Member Functions inherited from pqPropertyWidget
template<class T >
static QString getXMLName (T *object)
 Description: This static utility method returns the XML name for an object as a QString. More...
 
static QString getTooltip (vtkSMProperty *property)
 Returns the tooltip to use for the property. May return an empty string. More...
 
- Protected Member Functions inherited from pqPropertyWidget
void addPropertyLink (QObject *qobject, const char *qproperty, const char *qsignal, vtkSMProperty *smproperty, int smindex=-1)
 
void addPropertyLink (QObject *qobject, const char *qproperty, const char *qsignal, vtkSMProxy *smproxy, vtkSMProperty *smproperty, int smindex=-1)
 
void removePropertyLink (QObject *qobject, const char *qproperty, const char *qsignal, vtkSMProperty *smproperty, int smindex=-1)
 
void removePropertyLink (QObject *qobject, const char *qproperty, const char *qsignal, vtkSMProxy *smproxy, vtkSMProperty *smproperty, int smindex=-1)
 
void setShowLabel (bool show)
 
void setChangeAvailableAsChangeFinished (bool status)
 For most pqPropertyWidget subclasses a changeAvailable() signal, corresponds to a changeFinished() signal. More...
 
void addDecorator (pqPropertyWidgetDecorator *)
 Register a decorator. More...
 
pqPropertyLinkslinks ()
 Provides access to the pqPropertyLinks instance. More...
 

Detailed Description

pqColorOpacityEditorWidget provides an in-line editor widget for editing the color and opacity transfer functions.

The property group is expected to have properties with the following functions. If any of the optional properties are missing, then the corresponding widgets are hidden.

Definition at line 68 of file pqColorOpacityEditorWidget.h.

Constructor & Destructor Documentation

§ pqColorOpacityEditorWidget()

pqColorOpacityEditorWidget::pqColorOpacityEditorWidget ( vtkSMProxy *  proxy,
vtkSMPropertyGroup *  smgroup,
QWidget *  parent = 0 
)

§ ~pqColorOpacityEditorWidget()

virtual pqColorOpacityEditorWidget::~pqColorOpacityEditorWidget ( )
virtual

Member Function Documentation

§ xrgbPoints()

QList<QVariant> pqColorOpacityEditorWidget::xrgbPoints ( ) const

Returns the current list of control points for the color transfer function.

This a list of 4-tuples.

§ xvmsPoints()

QList<QVariant> pqColorOpacityEditorWidget::xvmsPoints ( ) const

Returns the current list of control points for the opacity function.

This a list of 4-tuples.

§ useLogScale()

bool pqColorOpacityEditorWidget::useLogScale ( ) const

Returns the value for use-log-scale.

§ lockScalarRange()

bool pqColorOpacityEditorWidget::lockScalarRange ( ) const

Returns true if the color map range is locked.

§ scalarOpacityFunctionProxy()

pqSMProxy pqColorOpacityEditorWidget::scalarOpacityFunctionProxy ( ) const

Returns the scalar opacity function (i.e.

PiecewiseFunction) proxy used, if any.

§ setXvmsPoints

void pqColorOpacityEditorWidget::setXvmsPoints ( const QList< QVariant > &  )
slot

Sets the xvmsPoints that control the opacity transfer function.

§ setXrgbPoints

void pqColorOpacityEditorWidget::setXrgbPoints ( const QList< QVariant > &  )
slot

Sets the xrgbPoints that control the color transfer function.

§ setUseLogScale

void pqColorOpacityEditorWidget::setUseLogScale ( bool  value)
slot

Set whether to use-log scale.

§ setLockScalarRange

void pqColorOpacityEditorWidget::setLockScalarRange ( bool  val)
slot

Set whether the color map range should be locked.

§ setScalarOpacityFunctionProxy

void pqColorOpacityEditorWidget::setScalarOpacityFunctionProxy ( pqSMProxy  sofProxy)
slot

Set the scalar opacity function (or PiecewiseFunction) proxy to use.

§ resetRangeToData

void pqColorOpacityEditorWidget::resetRangeToData ( )
slot

Reset the transfer function ranges to active data source.

§ resetRangeToCustom [1/2]

void pqColorOpacityEditorWidget::resetRangeToCustom ( )
slot

Reset the transfer function ranges to custom values.

§ resetRangeToCustom [2/2]

void pqColorOpacityEditorWidget::resetRangeToCustom ( double  min,
double  max 
)
slot

§ resetRangeToDataOverTime

void pqColorOpacityEditorWidget::resetRangeToDataOverTime ( )
slot

Reset the transfer function ranges to temporal range for active data source.

§ resetRangeToVisibleData

void pqColorOpacityEditorWidget::resetRangeToVisibleData ( )
slot

Reset the transfer function ranges to visible range for active data source.

§ invertTransferFunctions

void pqColorOpacityEditorWidget::invertTransferFunctions ( )
slot

Inverts the transfer functions.

§ choosePreset

void pqColorOpacityEditorWidget::choosePreset ( const char *  presetName = NULL)
slot

pick a preset.

§ saveAsPreset

void pqColorOpacityEditorWidget::saveAsPreset ( )
slot

save current transfer function as preset.

§ xrgbPointsChanged

void pqColorOpacityEditorWidget::xrgbPointsChanged ( )
signal

Signal fired when the xrgbPoints change.

§ xvmsPointsChanged

void pqColorOpacityEditorWidget::xvmsPointsChanged ( )
signal

Signal fired when the xvmsPoints change.

§ useLogScaleChanged

void pqColorOpacityEditorWidget::useLogScaleChanged ( )
signal

Signal fired when useLogScale changes.

§ lockScalarRangeChanged

void pqColorOpacityEditorWidget::lockScalarRangeChanged ( )
signal

Signal fired when lockScalarRange changes.

§ scalarOpacityFunctionProxyChanged

void pqColorOpacityEditorWidget::scalarOpacityFunctionProxyChanged ( )
signal

This signal is never really fired since this widget doesn't have any UI to allow users to changes the ScalarOpacityFunction proxy used.

§ opacityCurrentChanged

void pqColorOpacityEditorWidget::opacityCurrentChanged ( vtkIdType  )
protectedslot

slots called when the current point changes on the two internal pqTransferFunctionWidget widgets.

§ colorCurrentChanged

void pqColorOpacityEditorWidget::colorCurrentChanged ( vtkIdType  )
protectedslot

§ updatePanel

void pqColorOpacityEditorWidget::updatePanel ( )
protectedslot

updates the panel to show/hide advanced settings

§ updateCurrentData

void pqColorOpacityEditorWidget::updateCurrentData ( )
protectedslot

updates the text shown in the "current data" input.

§ currentDataEdited

void pqColorOpacityEditorWidget::currentDataEdited ( )
protectedslot

update the transfer function with the text in CurrentDataValue text field.

§ presetApplied

void pqColorOpacityEditorWidget::presetApplied ( )
protectedslot

called when a preset is applied.

§ updateIndexedLookupState

void pqColorOpacityEditorWidget::updateIndexedLookupState ( )
protectedslot

Ensures that the color-swatches for indexedColors are shown only when this is set to true.

§ useLogScaleClicked

void pqColorOpacityEditorWidget::useLogScaleClicked ( bool  )
protectedslot

called when the use-log-scale checkbox is clicked by the user.

We then add extra logic to valid ranges convert the color map to log/linear space.

§ updateButtonEnableState

void pqColorOpacityEditorWidget::updateButtonEnableState ( )
protectedslot

called when the active representation or view changes.

We then change the enabled/disabled state of the buttons. Some actions require a valid representation or view, so disable them if there isn't one.

Property Documentation

§ xrgbPoints

QList<QVariant> pqColorOpacityEditorWidget::xrgbPoints
readwrite

Definition at line 72 of file pqColorOpacityEditorWidget.h.

§ xvmsPoints

QList<QVariant> pqColorOpacityEditorWidget::xvmsPoints
readwrite

Definition at line 73 of file pqColorOpacityEditorWidget.h.

§ useLogScale

bool pqColorOpacityEditorWidget::useLogScale
readwrite

Definition at line 74 of file pqColorOpacityEditorWidget.h.

§ lockScalarRange

bool pqColorOpacityEditorWidget::lockScalarRange
readwrite

Definition at line 75 of file pqColorOpacityEditorWidget.h.

§ scalarOpacityFunctionProxy

pqSMProxy pqColorOpacityEditorWidget::scalarOpacityFunctionProxy
readwrite

Definition at line 77 of file pqColorOpacityEditorWidget.h.


The documentation for this class was generated from the following file: