anatomist  5.0.5
3D neuroimaging data viewer
GradientWidget Class Reference

#include <anatomist/gradientwidget/gradwidget.h>

Inheritance diagram for GradientWidget:
Collaboration diagram for GradientWidget:

Public Slots

void setGradient (const Gradient &gradient)
 Set the gradient to edit. More...
 
void newRgb ()
 Set a default RGB gradient. More...
 
void newHsv ()
 Set a default HSV gradient. More...
 
void invert ()
 Invert the current gradient. More...
 

Signals

void gradientChanged (QString s)
 

Public Member Functions

 GradientWidget (QWidget *parent=0, const char *name=0, const QString &gradString="", double vMin=0, double vMax=1.)
 Constructor. More...
 
 ~GradientWidget ()
 Destructor. More...
 
QSize minimumSizeHint () const
 Return the minimum size of the widget. More...
 
QSize sizeHint () const
 Return the recommended size of the widget. More...
 
const GradientgetGradient () const
 Get the current gradient. More...
 
QString getGradientString () const
 
void setGradient (const QString &s)
 
bool hasAlpha () const
 
void setHasAlpha (bool x)
 
void setBounds (double vMin=0, double vMax=1.)
 
double minBound () const
 
double maxBound () const
 

Detailed Description

Definition at line 24 of file gradwidget.h.

Constructor & Destructor Documentation

◆ GradientWidget()

GradientWidget::GradientWidget ( QWidget *  parent = 0,
const char *  name = 0,
const QString &  gradString = "",
double  vMin = 0,
double  vMax = 1. 
)

Constructor.

◆ ~GradientWidget()

GradientWidget::~GradientWidget ( )

Destructor.

Member Function Documentation

◆ getGradient()

const Gradient& GradientWidget::getGradient ( ) const
inline

Get the current gradient.

Returns
The gradient object.

Definition at line 57 of file gradwidget.h.

References getGradientString(), and setGradient().

◆ getGradientString()

QString GradientWidget::getGradientString ( ) const

Referenced by getGradient().

◆ gradientChanged

void GradientWidget::gradientChanged ( QString  s)
signal

Referenced by maxBound().

◆ hasAlpha()

bool GradientWidget::hasAlpha ( ) const
inline

Definition at line 65 of file gradwidget.h.

References setBounds(), and setHasAlpha().

◆ invert

void GradientWidget::invert ( )
slot

Invert the current gradient.

Referenced by maxBound().

◆ maxBound()

double GradientWidget::maxBound ( ) const
inline

Definition at line 70 of file gradwidget.h.

References gradientChanged(), invert(), newHsv(), newRgb(), setGradient(), and slots.

◆ minBound()

double GradientWidget::minBound ( ) const
inline

Definition at line 69 of file gradwidget.h.

◆ minimumSizeHint()

QSize GradientWidget::minimumSizeHint ( ) const

Return the minimum size of the widget.

◆ newHsv

void GradientWidget::newHsv ( )
slot

Set a default HSV gradient.

Referenced by maxBound().

◆ newRgb

void GradientWidget::newRgb ( )
slot

Set a default RGB gradient.

Referenced by maxBound().

◆ setBounds()

void GradientWidget::setBounds ( double  vMin = 0,
double  vMax = 1. 
)

Referenced by hasAlpha().

◆ setGradient() [1/2]

void GradientWidget::setGradient ( const QString &  s)

Referenced by getGradient(), and maxBound().

◆ setGradient [2/2]

void GradientWidget::setGradient ( const Gradient gradient)
slot

Set the gradient to edit.

Parameters
gradientThe gradient object.

◆ setHasAlpha()

void GradientWidget::setHasAlpha ( bool  x)

Referenced by hasAlpha().

◆ sizeHint()

QSize GradientWidget::sizeHint ( ) const

Return the recommended size of the widget.


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