VAPOR3 3.9.4
Public Slots | Signals | Public Member Functions | Protected Member Functions | Friends | List of all members
TFMap Class Referenceabstract

#include <TFMapWidget.h>

Inheritance diagram for TFMap:
TFColorMap TFHistogramMap TFIsoValueMap TFOpacityMap

Public Slots

void update ()
 These map to the QWidget counterparts.
 
void show ()
 
void hide ()
 

Signals

void Activated (TFMap *who)
 Emittend when focus was gained.
 

Public Member Functions

 TFMap (const std::string &variableNameTag, TFMapWidget *parent=nullptr)
 
TFInfoWidgetGetInfoWidget ()
 
void Update (VAPoR::DataMgr *dataMgr, VAPoR::ParamsMgr *paramsMgr, VAPoR::RenderParams *rParams)
 
bool HasValidParams () const
 
bool IsShown () const
 
virtual void LostFocus ()=0
 
virtual QSize minimumSizeHint () const =0
 
virtual void PopulateContextMenu (QMenu *menu, const glm::vec2 &p)
 (Right-click menu)
 
virtual void PopulateSettingsMenu (QMenu *menu) const
 
int width () const
 
int height () const
 
void resize (int width, int height)
 
bool isLargeEnoughToPaint () const
 Sometimes Qt tries painting a 0 sized widget.
 
QRect paddedRect () const
 Returns the rect of the internal padded area.
 
QRect rect () const
 
const QFont getFont () const
 
virtual void paintEvent (QPainter &p)=0
 These map to the QWidget counterparts.
 
virtual void mousePressEvent (QMouseEvent *event)
 
virtual void mouseReleaseEvent (QMouseEvent *event)
 
virtual void mouseMoveEvent (QMouseEvent *event)
 
virtual void mouseDoubleClickEvent (QMouseEvent *event)
 

Protected Member Functions

virtual void paramsUpdate ()=0
 
VAPoR::DataMgrgetDataMgr () const
 
VAPoR::ParamsMgrgetParamsMgr () const
 
VAPoR::RenderParamsgetRenderParams () const
 
VAPoR::MapperFunctiongetMapperFunction () const
 
std::string getVariableName () const
 
const std::string & getVariableNameTag () const
 
void drawControl (QPainter &p, const QPointF &pos, bool selected=false) const
 
virtual TFInfoWidgetcreateInfoWidget ()=0
 
glm::vec2 NDCToPixel (const glm::vec2 &v) const
 
QPointF NDCToQPixel (const glm::vec2 &v) const
 
QPointF NDCToQPixel (float x, float y) const
 
glm::vec2 PixelToNDC (const QPointF &p) const
 
glm::vec2 PixelToNDC (const glm::vec2 &p) const
 
virtual QMargins GetPadding () const
 
int GetControlPointRadius () const
 
void BeginSaveStateGroup (VAPoR::ParamsMgr *paramsMgr, const std::string &description="")
 
void EndSaveStateGroup (VAPoR::ParamsMgr *paramsMgr)
 
void CancelSaveStateGroup (VAPoR::ParamsMgr *paramsMgr)
 

Friends

class TFMapWidget
 

Detailed Description

A widget for editing a transfer function mapped value, for example opacity or color. They are not QWidgets because of limitations in Qt which do not allow widgets to be stacked on top of another with passthrough mouse events. Because of this, TFMapWidget manually holds TFMaps and manages such events.

Definition at line 24 of file TFMapWidget.h.

Constructor & Destructor Documentation

◆ TFMap()

TFMap::TFMap ( const std::string &  variableNameTag,
TFMapWidget parent = nullptr 
)

Member Function Documentation

◆ Activated

void TFMap::Activated ( TFMap who)
signal

Emittend when focus was gained.

◆ BeginSaveStateGroup()

void TFMap::BeginSaveStateGroup ( VAPoR::ParamsMgr paramsMgr,
const std::string &  description = "" 
)
protected

◆ CancelSaveStateGroup()

void TFMap::CancelSaveStateGroup ( VAPoR::ParamsMgr paramsMgr)
protected

◆ createInfoWidget()

virtual TFInfoWidget * TFMap::createInfoWidget ( )
protectedpure virtual

◆ drawControl()

void TFMap::drawControl ( QPainter &  p,
const QPointF &  pos,
bool  selected = false 
) const
protected

◆ EndSaveStateGroup()

void TFMap::EndSaveStateGroup ( VAPoR::ParamsMgr paramsMgr)
protected

◆ GetControlPointRadius()

int TFMap::GetControlPointRadius ( ) const
protected

◆ getDataMgr()

VAPoR::DataMgr * TFMap::getDataMgr ( ) const
inlineprotected

Definition at line 80 of file TFMapWidget.h.

◆ getFont()

const QFont TFMap::getFont ( ) const

◆ GetInfoWidget()

TFInfoWidget * TFMap::GetInfoWidget ( )

◆ getMapperFunction()

VAPoR::MapperFunction * TFMap::getMapperFunction ( ) const
protected

◆ GetPadding()

virtual QMargins TFMap::GetPadding ( ) const
protectedvirtual

Reimplemented in TFIsoValueMap.

◆ getParamsMgr()

VAPoR::ParamsMgr * TFMap::getParamsMgr ( ) const
inlineprotected

Definition at line 81 of file TFMapWidget.h.

◆ getRenderParams()

VAPoR::RenderParams * TFMap::getRenderParams ( ) const
inlineprotected

Definition at line 82 of file TFMapWidget.h.

◆ getVariableName()

std::string TFMap::getVariableName ( ) const
protected

◆ getVariableNameTag()

const std::string & TFMap::getVariableNameTag ( ) const
protected

◆ HasValidParams()

bool TFMap::HasValidParams ( ) const

◆ height()

int TFMap::height ( ) const
inline

Definition at line 53 of file TFMapWidget.h.

◆ hide

void TFMap::hide ( )
slot

◆ isLargeEnoughToPaint()

bool TFMap::isLargeEnoughToPaint ( ) const

Sometimes Qt tries painting a 0 sized widget.

◆ IsShown()

bool TFMap::IsShown ( ) const

◆ LostFocus()

virtual void TFMap::LostFocus ( )
pure virtual

◆ minimumSizeHint()

virtual QSize TFMap::minimumSizeHint ( ) const
pure virtual

◆ mouseDoubleClickEvent()

virtual void TFMap::mouseDoubleClickEvent ( QMouseEvent *  event)
virtual

Reimplemented in TFColorMap, TFIsoValueMap, and TFOpacityMap.

◆ mouseMoveEvent()

virtual void TFMap::mouseMoveEvent ( QMouseEvent *  event)
virtual

◆ mousePressEvent()

virtual void TFMap::mousePressEvent ( QMouseEvent *  event)
virtual

◆ mouseReleaseEvent()

virtual void TFMap::mouseReleaseEvent ( QMouseEvent *  event)
virtual

◆ NDCToPixel()

glm::vec2 TFMap::NDCToPixel ( const glm::vec2 &  v) const
protected

◆ NDCToQPixel() [1/2]

QPointF TFMap::NDCToQPixel ( const glm::vec2 &  v) const
protected

◆ NDCToQPixel() [2/2]

QPointF TFMap::NDCToQPixel ( float  x,
float  y 
) const
protected

◆ paddedRect()

QRect TFMap::paddedRect ( ) const

Returns the rect of the internal padded area.

◆ paintEvent()

virtual void TFMap::paintEvent ( QPainter &  p)
pure virtual

These map to the QWidget counterparts.

Implemented in TFHistogramMap, TFColorMap, TFIsoValueMap, and TFOpacityMap.

◆ paramsUpdate()

virtual void TFMap::paramsUpdate ( )
protectedpure virtual

◆ PixelToNDC() [1/2]

glm::vec2 TFMap::PixelToNDC ( const glm::vec2 &  p) const
protected

◆ PixelToNDC() [2/2]

glm::vec2 TFMap::PixelToNDC ( const QPointF &  p) const
protected

◆ PopulateContextMenu()

virtual void TFMap::PopulateContextMenu ( QMenu *  menu,
const glm::vec2 &  p 
)
inlinevirtual

(Right-click menu)

Reimplemented in TFColorMap, TFIsoValueMap, and TFOpacityMap.

Definition at line 49 of file TFMapWidget.h.

◆ PopulateSettingsMenu()

virtual void TFMap::PopulateSettingsMenu ( QMenu *  menu) const
inlinevirtual

Reimplemented in TFHistogramMap, TFColorMap, and TFOpacityMap.

Definition at line 50 of file TFMapWidget.h.

◆ rect()

QRect TFMap::rect ( ) const

◆ resize()

void TFMap::resize ( int  width,
int  height 
)

◆ show

void TFMap::show ( )
slot

◆ update

void TFMap::update ( )
slot

These map to the QWidget counterparts.

◆ Update()

void TFMap::Update ( VAPoR::DataMgr dataMgr,
VAPoR::ParamsMgr paramsMgr,
VAPoR::RenderParams rParams 
)

◆ width()

int TFMap::width ( ) const
inline

Definition at line 52 of file TFMapWidget.h.

Friends And Related Function Documentation

◆ TFMapWidget

friend class TFMapWidget
friend

Definition at line 69 of file TFMapWidget.h.


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