|
Computer Assited Medical Intervention Tool Kit
version 5.0
|
|
Go to the documentation of this file.
26 #ifndef MESH_SELECTION_MODEL_H
27 #define MESH_SELECTION_MODEL_H
29 #include <QAbstractTableModel>
31 #include<vtkSmartPointer.h>
33 class vtkSelectionNode;
34 class vtkAbstractArray;
65 int rowCount(
const QModelIndex& parent = QModelIndex())
const override;
70 int columnCount(
const QModelIndex& parent = QModelIndex())
const override;
75 QVariant
data(
const QModelIndex& index,
int role = Qt::DisplayRole)
const override;
80 QVariant
headerData(
int section, Qt::Orientation orientation,
int role = Qt::DisplayRole)
const override;
92 bool setData(
const QModelIndex& index,
const QVariant& value,
int role)
override;
94 Qt::ItemFlags
flags(
const QModelIndex& index)
const override;
int removeSelection(const QString &name)
Definition: MeshSelectionModel.cpp:294
MeshComponent * meshComponent
Definition: MeshSelectionModel.h:99
int columnCount(const QModelIndex &parent=QModelIndex()) const override
Number of selection columns.
Definition: MeshSelectionModel.cpp:85
InsertionPolicy
Definition: MeshSelectionModel.h:50
@ DISCARD
Definition: MeshSelectionModel.h:54
int insertSelection(const QString &name, int fieldType, int contentType, vtkSmartPointer< vtkAbstractArray > array, InsertionPolicy policy=REPLACE)
Insert a selection.
Definition: MeshSelectionModel.cpp:183
QMap< int, QString > fieldName
The component where the selection are stored.
Definition: MeshSelectionModel.h:100
@ REPLACE
Definition: MeshSelectionModel.h:51
Qt::ItemFlags flags(const QModelIndex &index) const override
Definition: MeshSelectionModel.cpp:330
int rowCount(const QModelIndex &parent=QModelIndex()) const override
Number of selection.
Definition: MeshSelectionModel.cpp:77
QVariant headerData(int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override
Data header.
Definition: MeshSelectionModel.cpp:157
@ SUBTRACT
Definition: MeshSelectionModel.h:53
QSizePolicy policy(QSizePolicy::Expanding, QSizePolicy::Expanding)
MeshSelectionModel(MeshComponent *const meshComp)
Constructor.
Definition: MeshSelectionModel.cpp:68
@ MERGE
Definition: MeshSelectionModel.h:52
QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const override
Model data.
Definition: MeshSelectionModel.cpp:90
Qt model for mesh selection This class use the Qt model/view design.
Definition: MeshSelectionModel.h:44
Basic component to manage any kind of mesh.
Definition: MeshComponent.h:53
QMap< int, QString > contentName
Definition: MeshSelectionModel.h:101
bool setData(const QModelIndex &index, const QVariant &value, int role) override
Edit selection data.
Definition: MeshSelectionModel.cpp:307
Definition: Action.cpp:35