vtkQtAbstractModelAdapter Class Reference

#include <vtkQtAbstractModelAdapter.h>

Inheritance diagram for vtkQtAbstractModelAdapter:

Inheritance graph
[legend]

List of all members.


Detailed Description

Superclass for Qt model adapters.

vtkQtAbstractModelAdapter is the superclass for classes that adapt VTK objects to QAbstractItemModel. This class contains API for converting between QModelIndex and VTK ids, as well as some additional specialized functionality such as setting a column of data to use as the Qt header information.

See also:
vtkQtTableModelAdapter vtkQtTreeModelAdapter

Definition at line 44 of file vtkQtAbstractModelAdapter.h.


Public Types

enum  { FULL_VIEW, DATA_VIEW }

Signals

void modelChanged ()

Public Member Functions

 vtkQtAbstractModelAdapter (QObject *p)
void reset ()
virtual void SetVTKDataObject (vtkDataObject *data)=0
virtual vtkDataObjectGetVTKDataObject () const =0
virtual vtkSelectionQModelIndexListToVTKIndexSelection (const QModelIndexList qmil) const =0
virtual QItemSelection VTKIndexSelectionToQItemSelection (vtkSelection *vtksel) const =0
virtual void SetViewType (int type)
virtual int GetViewType ()
virtual void SetKeyColumn (int col)
virtual int GetKeyColumn ()
virtual void SetKeyColumnName (const char *name)=0
virtual void SetColorColumn (int col)
virtual int GetColorColumn ()
virtual void SetColorColumnName (const char *name)=0
virtual void SetDataColumnRange (int c1, int c2)

Protected Member Functions

virtual int ModelColumnToFieldDataColumn (int col) const

Protected Attributes

int ViewType
int KeyColumn
int ColorColumn
int DataStartColumn
int DataEndColumn

Member Enumeration Documentation

anonymous enum

Enumerator:
FULL_VIEW 
DATA_VIEW 

Definition at line 51 of file vtkQtAbstractModelAdapter.h.


Constructor & Destructor Documentation

vtkQtAbstractModelAdapter::vtkQtAbstractModelAdapter ( QObject *  p  )  [inline]

Definition at line 56 of file vtkQtAbstractModelAdapter.h.


Member Function Documentation

virtual void vtkQtAbstractModelAdapter::SetVTKDataObject ( vtkDataObject data  )  [pure virtual]

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

Implemented in vtkQtAnnotationLayersModelAdapter, vtkQtTableModelAdapter, and vtkQtTreeModelAdapter.

virtual vtkDataObject* vtkQtAbstractModelAdapter::GetVTKDataObject (  )  const [pure virtual]

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

Implemented in vtkQtAnnotationLayersModelAdapter, vtkQtTableModelAdapter, and vtkQtTreeModelAdapter.

virtual vtkSelection* vtkQtAbstractModelAdapter::QModelIndexListToVTKIndexSelection ( const QModelIndexList  qmil  )  const [pure virtual]

Selection conversion from VTK land to Qt land

Implemented in vtkQtAnnotationLayersModelAdapter, vtkQtTableModelAdapter, and vtkQtTreeModelAdapter.

virtual QItemSelection vtkQtAbstractModelAdapter::VTKIndexSelectionToQItemSelection ( vtkSelection vtksel  )  const [pure virtual]

Selection conversion from VTK land to Qt land

Implemented in vtkQtAnnotationLayersModelAdapter, vtkQtTableModelAdapter, and vtkQtTreeModelAdapter.

virtual void vtkQtAbstractModelAdapter::SetViewType ( int  type  )  [inline, virtual]

Set/Get the view type. FULL_VIEW gives access to all the data. DATA_VIEW gives access only to the data columns specified with SetDataColumnRange() The default is FULL_VIEW.

Definition at line 83 of file vtkQtAbstractModelAdapter.h.

virtual int vtkQtAbstractModelAdapter::GetViewType (  )  [inline, virtual]

Set/Get the view type. FULL_VIEW gives access to all the data. DATA_VIEW gives access only to the data columns specified with SetDataColumnRange() The default is FULL_VIEW.

Definition at line 84 of file vtkQtAbstractModelAdapter.h.

virtual void vtkQtAbstractModelAdapter::SetKeyColumn ( int  col  )  [inline, virtual]

Set/Get the key column. The key column is used as the row headers in a table view, and as the first column in a tree view. Set to -1 for no key column. The default is no key column.

Definition at line 91 of file vtkQtAbstractModelAdapter.h.

virtual int vtkQtAbstractModelAdapter::GetKeyColumn (  )  [inline, virtual]

Set/Get the key column. The key column is used as the row headers in a table view, and as the first column in a tree view. Set to -1 for no key column. The default is no key column.

Definition at line 92 of file vtkQtAbstractModelAdapter.h.

virtual void vtkQtAbstractModelAdapter::SetKeyColumnName ( const char *  name  )  [pure virtual]

Set/Get the key column. The key column is used as the row headers in a table view, and as the first column in a tree view. Set to -1 for no key column. The default is no key column.

Implemented in vtkQtAnnotationLayersModelAdapter, vtkQtTableModelAdapter, and vtkQtTreeModelAdapter.

virtual void vtkQtAbstractModelAdapter::SetColorColumn ( int  col  )  [inline, virtual]

Set/Get the column storing the rgba color values for each row. The color column is used as the row headers in a table view, and as the first column in a tree view. Set to -1 for no key column. The default is no key column.

Definition at line 101 of file vtkQtAbstractModelAdapter.h.

virtual int vtkQtAbstractModelAdapter::GetColorColumn (  )  [inline, virtual]

Set/Get the column storing the rgba color values for each row. The color column is used as the row headers in a table view, and as the first column in a tree view. Set to -1 for no key column. The default is no key column.

Definition at line 102 of file vtkQtAbstractModelAdapter.h.

virtual void vtkQtAbstractModelAdapter::SetColorColumnName ( const char *  name  )  [pure virtual]

Set/Get the column storing the rgba color values for each row. The color column is used as the row headers in a table view, and as the first column in a tree view. Set to -1 for no key column. The default is no key column.

Implemented in vtkQtAnnotationLayersModelAdapter, vtkQtTableModelAdapter, and vtkQtTreeModelAdapter.

virtual void vtkQtAbstractModelAdapter::SetDataColumnRange ( int  c1,
int  c2 
) [inline, virtual]

Set the range of columns that specify the main data matrix. The data column range should not include the key column. The default is no data columns.

Definition at line 110 of file vtkQtAbstractModelAdapter.h.

void vtkQtAbstractModelAdapter::reset (  )  [inline]

Definition at line 117 of file vtkQtAbstractModelAdapter.h.

void vtkQtAbstractModelAdapter::modelChanged (  )  [signal]

virtual int vtkQtAbstractModelAdapter::ModelColumnToFieldDataColumn ( int  col  )  const [protected, virtual]

Map a column index in the QAbstractItemModel to a vtkTable column. If the argument is out of range or cannot be mapped then this method may return -1.


Member Data Documentation

Definition at line 130 of file vtkQtAbstractModelAdapter.h.

Definition at line 131 of file vtkQtAbstractModelAdapter.h.

Definition at line 132 of file vtkQtAbstractModelAdapter.h.

Definition at line 133 of file vtkQtAbstractModelAdapter.h.

Definition at line 134 of file vtkQtAbstractModelAdapter.h.


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

Generated on Wed Aug 24 11:59:03 2011 for VTK by  doxygen 1.5.6