VTK  9.1.0
Public Member Functions | List of all members
vtkQtAnnotationLayersModelAdapter Class Reference

Adapts annotations to a Qt item model. More...

#include <vtkQtAnnotationLayersModelAdapter.h>

Inheritance diagram for vtkQtAnnotationLayersModelAdapter:
[legend]
Collaboration diagram for vtkQtAnnotationLayersModelAdapter:
[legend]

Public Member Functions

 vtkQtAnnotationLayersModelAdapter (QObject *parent=nullptr)
 
 vtkQtAnnotationLayersModelAdapter (vtkAnnotationLayers *ann, QObject *parent=nullptr)
 
 ~vtkQtAnnotationLayersModelAdapter () override
 
void SetKeyColumnName (const char *name) override
 
void SetColorColumnName (const char *name) override
 
void SetVTKDataObject (vtkDataObject *data) override
 Set/Get the VTK data object as input to this adapter.
 
vtkDataObjectGetVTKDataObject () const override
 Set/Get the VTK data object as input to this adapter.
 
virtual vtkAnnotationLayersQModelIndexListToVTKAnnotationLayers (const QModelIndexList qmil) const
 Selection conversion from VTK land to Qt land.
 
virtual QItemSelection VTKAnnotationLayersToQItemSelection (vtkAnnotationLayers *vtkann) const
 Selection conversion from VTK land to Qt land.
 
vtkSelectionQModelIndexListToVTKIndexSelection (const QModelIndexList qmil) const override
 Selection conversion from VTK land to Qt land.
 
QItemSelection VTKIndexSelectionToQItemSelection (vtkSelection *vtksel) const override
 Selection conversion from VTK land to Qt land.
 
void setAnnotationLayers (vtkAnnotationLayers *annotations)
 Set up the model based on the current table.
 
vtkAnnotationLayersannotationLayers () const
 Set up the model based on the current table.
 
QVariant data (const QModelIndex &index, int role=Qt::DisplayRole) const override
 Set up the model based on the current table.
 
bool setData (const QModelIndex &index, const QVariant &value, int role=Qt::EditRole) override
 Set up the model based on the current table.
 
Qt::ItemFlags flags (const QModelIndex &index) const override
 Set up the model based on the current table.
 
QVariant headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override
 Set up the model based on the current table.
 
QModelIndex index (int row, int column, const QModelIndex &parent=QModelIndex()) const override
 Set up the model based on the current table.
 
QModelIndex parent (const QModelIndex &index) const override
 Set up the model based on the current table.
 
int rowCount (const QModelIndex &parent=QModelIndex()) const override
 Set up the model based on the current table.
 
int columnCount (const QModelIndex &parent=QModelIndex()) const override
 Set up the model based on the current table.
 
- Public Member Functions inherited from vtkQtAbstractModelAdapter
 vtkQtAbstractModelAdapter (QObject *p)
 
virtual void SetViewType (int type)
 Set/Get the view type.
 
virtual int GetViewType ()
 
virtual void SetKeyColumn (int col)
 Set/Get the key column.
 
virtual int GetKeyColumn ()
 
virtual void SetKeyColumnName (const char *name)=0
 
virtual void SetColorColumn (int col)
 Set/Get the column storing the rgba color values for each row.
 
virtual int GetColorColumn ()
 
virtual void SetColorColumnName (const char *name)=0
 
virtual void SetDataColumnRange (int c1, int c2)
 Set the range of columns that specify the main data matrix.
 
void reset ()
 
void beginResetModel ()
 
void endResetModel ()
 

Additional Inherited Members

- Public Types inherited from vtkQtAbstractModelAdapter
enum  { FULL_VIEW , DATA_VIEW }
 
- Signals inherited from vtkQtAbstractModelAdapter
void modelChanged ()
 
- Protected Member Functions inherited from vtkQtAbstractModelAdapter
virtual int ModelColumnToFieldDataColumn (int col) const
 Map a column index in the QAbstractItemModel to a vtkTable column.
 
- Protected Attributes inherited from vtkQtAbstractModelAdapter
int ViewType
 
int KeyColumn
 
int ColorColumn
 
int DataStartColumn
 
int DataEndColumn
 

Detailed Description

Adapts annotations to a Qt item model.

vtkQtAnnotationLayersModelAdapter is a QAbstractItemModel with a vtkAnnotationLayers as its underlying data model.

See also
vtkQtAbstractModelAdapter vtkQtTableModelAdapter

Definition at line 41 of file vtkQtAnnotationLayersModelAdapter.h.

Constructor & Destructor Documentation

◆ vtkQtAnnotationLayersModelAdapter() [1/2]

vtkQtAnnotationLayersModelAdapter::vtkQtAnnotationLayersModelAdapter ( QObject *  parent = nullptr)

◆ vtkQtAnnotationLayersModelAdapter() [2/2]

vtkQtAnnotationLayersModelAdapter::vtkQtAnnotationLayersModelAdapter ( vtkAnnotationLayers ann,
QObject *  parent = nullptr 
)

◆ ~vtkQtAnnotationLayersModelAdapter()

vtkQtAnnotationLayersModelAdapter::~vtkQtAnnotationLayersModelAdapter ( )
override

Member Function Documentation

◆ SetVTKDataObject()

void vtkQtAnnotationLayersModelAdapter::SetVTKDataObject ( vtkDataObject data)
overridevirtual

Set/Get the VTK data object as input to this adapter.

Implements vtkQtAbstractModelAdapter.

◆ GetVTKDataObject()

vtkDataObject * vtkQtAnnotationLayersModelAdapter::GetVTKDataObject ( ) const
overridevirtual

Set/Get the VTK data object as input to this adapter.

Implements vtkQtAbstractModelAdapter.

◆ QModelIndexListToVTKAnnotationLayers()

virtual vtkAnnotationLayers * vtkQtAnnotationLayersModelAdapter::QModelIndexListToVTKAnnotationLayers ( const QModelIndexList  qmil) const
virtual

Selection conversion from VTK land to Qt land.

◆ VTKAnnotationLayersToQItemSelection()

virtual QItemSelection vtkQtAnnotationLayersModelAdapter::VTKAnnotationLayersToQItemSelection ( vtkAnnotationLayers vtkann) const
virtual

Selection conversion from VTK land to Qt land.

◆ QModelIndexListToVTKIndexSelection()

vtkSelection * vtkQtAnnotationLayersModelAdapter::QModelIndexListToVTKIndexSelection ( const QModelIndexList  qmil) const
overridevirtual

Selection conversion from VTK land to Qt land.

Implements vtkQtAbstractModelAdapter.

◆ VTKIndexSelectionToQItemSelection()

QItemSelection vtkQtAnnotationLayersModelAdapter::VTKIndexSelectionToQItemSelection ( vtkSelection vtksel) const
overridevirtual

Selection conversion from VTK land to Qt land.

Implements vtkQtAbstractModelAdapter.

◆ SetKeyColumnName()

void vtkQtAnnotationLayersModelAdapter::SetKeyColumnName ( const char *  name)
overridevirtual

◆ SetColorColumnName()

void vtkQtAnnotationLayersModelAdapter::SetColorColumnName ( const char *  name)
overridevirtual

◆ setAnnotationLayers()

void vtkQtAnnotationLayersModelAdapter::setAnnotationLayers ( vtkAnnotationLayers annotations)

Set up the model based on the current table.

◆ annotationLayers()

vtkAnnotationLayers * vtkQtAnnotationLayersModelAdapter::annotationLayers ( ) const
inline

Set up the model based on the current table.

Definition at line 77 of file vtkQtAnnotationLayersModelAdapter.h.

◆ data()

QVariant vtkQtAnnotationLayersModelAdapter::data ( const QModelIndex &  index,
int  role = Qt::DisplayRole 
) const
override

Set up the model based on the current table.

◆ setData()

bool vtkQtAnnotationLayersModelAdapter::setData ( const QModelIndex &  index,
const QVariant &  value,
int  role = Qt::EditRole 
)
override

Set up the model based on the current table.

◆ flags()

Qt::ItemFlags vtkQtAnnotationLayersModelAdapter::flags ( const QModelIndex &  index) const
override

Set up the model based on the current table.

◆ headerData()

QVariant vtkQtAnnotationLayersModelAdapter::headerData ( int  section,
Qt::Orientation  orientation,
int  role = Qt::DisplayRole 
) const
override

Set up the model based on the current table.

◆ index()

QModelIndex vtkQtAnnotationLayersModelAdapter::index ( int  row,
int  column,
const QModelIndex &  parent = QModelIndex() 
) const
override

Set up the model based on the current table.

◆ parent()

QModelIndex vtkQtAnnotationLayersModelAdapter::parent ( const QModelIndex &  index) const
override

Set up the model based on the current table.

◆ rowCount()

int vtkQtAnnotationLayersModelAdapter::rowCount ( const QModelIndex &  parent = QModelIndex()) const
override

Set up the model based on the current table.

◆ columnCount()

int vtkQtAnnotationLayersModelAdapter::columnCount ( const QModelIndex &  parent = QModelIndex()) const
override

Set up the model based on the current table.


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