Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
#include <QmitkPythonVariableStackTableModel.h>
Public Member Functions | |
QmitkPythonVariableStackTableModel (QObject *parent=0) | |
virtual | ~QmitkPythonVariableStackTableModel () |
int | rowCount (const QModelIndex &parent=QModelIndex()) const |
int | columnCount (const QModelIndex &parent=QModelIndex()) const |
QVariant | data (const QModelIndex &index, int role=Qt::DisplayRole) const |
Qt::ItemFlags | flags (const QModelIndex &index) const |
virtual QVariant | headerData (int section, Qt::Orientation orientation, int role) const |
QStringList | mimeTypes () const |
bool | dropMimeData (const QMimeData *, Qt::DropAction, int, int, const QModelIndex &) |
Qt::DropActions | supportedDropActions () const |
void | CommandExecuted (const std::string &pythonCommand) |
std::vector< mitk::PythonVariable > | GetVariableStack () const |
Static Public Attributes | |
static const QString | MITK_IMAGE_VAR_NAME |
static const QString | MITK_SURFACE_VAR_NAME |
implements a table model to show the variables of the Python "__main__" dictionary furthermore implements dragging and dropping of datanodes (conversion from and to python)
Definition at line 31 of file QmitkPythonVariableStackTableModel.h.
QmitkPythonVariableStackTableModel::QmitkPythonVariableStackTableModel | ( | QObject * | parent = 0 | ) |
Definition at line 29 of file QmitkPythonVariableStackTableModel.cpp.
References mitk::IPythonService::AddPythonCommandObserver(), and us::GetModuleContext().
|
virtual |
Definition at line 38 of file QmitkPythonVariableStackTableModel.cpp.
References us::GetModuleContext(), and mitk::IPythonService::RemovePythonCommandObserver().
int QmitkPythonVariableStackTableModel::columnCount | ( | const QModelIndex & | parent = QModelIndex() | ) | const |
Definition at line 177 of file QmitkPythonVariableStackTableModel.cpp.
|
virtual |
Implements mitk::PythonCommandObserver.
Definition at line 214 of file QmitkPythonVariableStackTableModel.cpp.
References mitk::IPythonService::GetVariableStack(), and MITK_DEBUG.
Referenced by QmitkPythonVariableStackTableView::QmitkPythonVariableStackTableView().
QVariant QmitkPythonVariableStackTableModel::data | ( | const QModelIndex & | index, |
int | role = Qt::DisplayRole |
||
) | const |
Definition at line 182 of file QmitkPythonVariableStackTableModel.cpp.
References mitk::PythonVariable::m_Name, mitk::PythonVariable::m_Type, and mitk::PythonVariable::m_Value.
bool QmitkPythonVariableStackTableModel::dropMimeData | ( | const QMimeData * | data, |
Qt::DropAction | action, | ||
int | row, | ||
int | column, | ||
const QModelIndex & | parent | ||
) |
Definition at line 45 of file QmitkPythonVariableStackTableModel.cpp.
References mitk::IPythonService::CopyToPythonAsCvImage(), mitk::IPythonService::CopyToPythonAsSimpleItkImage(), mitk::IPythonService::CopyToPythonAsVtkPolyData(), QmitkMimeTypes::DataNodePtrs, mitk::DataNode::GetData(), mitk::Image::GetDimension(), mitk::DataNode::GetName(), mitk::IPythonService::IsOpenCvPythonWrappingAvailable(), mitk::IPythonService::IsSimpleItkPythonWrappingAvailable(), mitk::IPythonService::IsVtkPythonWrappingAvailable(), MITK_DEBUG, MITK_ERROR, MITK_IMAGE_VAR_NAME, MITK_SURFACE_VAR_NAME, and QmitkMimeTypes::ToDataNodePtrList().
Qt::ItemFlags QmitkPythonVariableStackTableModel::flags | ( | const QModelIndex & | index | ) | const |
Definition at line 162 of file QmitkPythonVariableStackTableModel.cpp.
std::vector< mitk::PythonVariable > QmitkPythonVariableStackTableModel::GetVariableStack | ( | ) | const |
Definition at line 222 of file QmitkPythonVariableStackTableModel.cpp.
Referenced by QmitkPythonVariableStackTableView::OnVariableStackDoubleClicked().
|
virtual |
Definition at line 139 of file QmitkPythonVariableStackTableModel.cpp.
QStringList QmitkPythonVariableStackTableModel::mimeTypes | ( | ) | const |
Definition at line 200 of file QmitkPythonVariableStackTableModel.cpp.
int QmitkPythonVariableStackTableModel::rowCount | ( | const QModelIndex & | parent = QModelIndex() | ) | const |
Definition at line 172 of file QmitkPythonVariableStackTableModel.cpp.
Qt::DropActions QmitkPythonVariableStackTableModel::supportedDropActions | ( | ) | const |
Definition at line 209 of file QmitkPythonVariableStackTableModel.cpp.
|
static |
Definition at line 36 of file QmitkPythonVariableStackTableModel.h.
Referenced by dropMimeData().
|
static |
Definition at line 37 of file QmitkPythonVariableStackTableModel.h.
Referenced by dropMimeData().