MColorPickerCallback Class Reference

#include <MColorPickerUtilities.h>

Class Description

Helper class for the color picking mechanism.

When using the Color Picking mechanism one should create a callback class inhereting from MColorPickerCallback in order to implement the pure virtual method getcolor(). By having a class (instead of a plain function callback), some custom data could be added to the callback instance.

Public Member Functions

 MColorPickerCallback (QWidget *key)
 Constructor. More...
 
virtual ~MColorPickerCallback ()
 Default Destructor.
 
virtual MColor getColor (QWidget *, const QPoint &, bool) const =0
 
QWidget * getKey () const
 Returns the widget used for the registration. More...
 

Static Public Member Functions

static const char * className ()
 Returns the name of this class. More...
 

Constructor & Destructor Documentation

OPENMAYA_MAJOR_NAMESPACE_OPEN MColorPickerCallback ( QWidget *  key)
explicit

Constructor.

Parameters
[in]keyThe widget used as a key for the registration
Returns
the registered widget

Member Function Documentation

virtual MColor getColor ( QWidget *  ,
const QPoint &  ,
bool   
) const
pure virtual
Note
The widget is the picked widget, the point is the mouse position in global window coordinate and the boolean indicates to compute the color in the view transform or in the rendering color space.
QWidget * getKey ( ) const

Returns the widget used for the registration.

Returns
the registered widget
const char * className ( )
static

Returns the name of this class.

Returns
The name of this class.

The documentation for this class was generated from the following files:
  • MColorPickerUtilities.h
  • MColorPickerUtilities.cpp