21#ifndef __qMRMLNodeComboBox_h
22#define __qMRMLNodeComboBox_h
29#include "qMRMLWidgetsExport.h"
31class qMRMLNodeComboBoxPrivate;
145 const QString& attributeName,
146 const QVariant& attributeValue = QVariant());
150 const QString& attributeName);
157 QString
baseName(const QString& nodeType =
"")const;
395 QScopedPointer<qMRMLNodeComboBoxPrivate>
d_ptr;
402 void createNodeAs(const QString& nodeTypeName);
408 virtual QString getNameFromDialog(const QString& dialogTitle, const QString& defaultName,
bool* ok);
Q_INVOKABLE void addAttribute(const QString &nodeType, const QString &attributeName, const QVariant &attributeValue=QVariant())
Q_INVOKABLE vtkMRMLScene * mrmlScene() const
void currentNodeRenamed(const QString &newName)
Signal emitted when the current node is renamed.
void changeEvent(QEvent *event) override
void emitCurrentNodeChanged()
void setCurrentNodeID(const QString &nodeID)
void setNoneDisplay(const QString &displayName)
Q_INVOKABLE qMRMLSortFilterProxyModel * sortFilterProxyModel() const
void setNodeTypes(const QStringList &nodeTypes)
virtual void setMRMLScene(vtkMRMLScene *scene)
QList< vtkMRMLNode * > nodes() const
Return a list of all the nodes that are displayed in the combo box.
QString interactionNodeSingletonTag
void emitNodesAboutToBeRemoved(const QModelIndex &parent, int start, int end)
void nodeAddedByUser(vtkMRMLNode *node)
Signal emitted when node is added by the user.
virtual void editCurrentNode()
Edits the currently selected node.
virtual void removeCurrentNode()
void nodeActivated(vtkMRMLNode *node)
Q_INVOKABLE int nodeCount() const
void refreshIfCurrentNodeHidden()
void setShowChildNodeTypes(bool show)
void setCurrentNodeIndex(int index)
void setComboBox(QComboBox *comboBox)
void setRenameEnabled(bool enable)
void currentNodeIDChanged(const QString &id)
void setNoneEnabled(bool enable)
QScopedPointer< qMRMLNodeComboBoxPrivate > d_ptr
void setAddEnabled(bool enable)
qMRMLNodeComboBox(QWidget *parent=nullptr)
bool selectNodeUponCreation
QStringList hideChildNodeTypes
Q_INVOKABLE void removeAttribute(const QString &nodeType, const QString &attributeName)
void setSelectNodeUponCreation(bool value)
QComboBox::SizeAdjustPolicy sizeAdjustPolicy
QAbstractItemModel * model() const
void currentNodeChanged(vtkMRMLNode *node)
void setBaseName(const QString &baseName, const QString &nodeType="")
Q_INVOKABLE vtkMRMLNode * currentNode() const
Return the currently selected node. 0 if no node is selected.
Q_INVOKABLE vtkMRMLNode * nodeFromIndex(int index) const
Q_INVOKABLE QString nodeTypeLabel(const QString &nodeType) const
QComboBox * comboBox() const
void emitNodesAdded(const QModelIndex &parent, int start, int end)
void nodeAboutToBeEdited(vtkMRMLNode *node)
Signal emitted when edit node menu action is selected.
virtual void renameCurrentNode()
void activateExtraItem(const QModelIndex &index)
virtual void setInteractionNodeSingletonTag(const QString &tag)
Q_INVOKABLE void setNodeTypeLabel(const QString &label, const QString &nodeType)
void nodeAboutToBeRemoved(vtkMRMLNode *node)
void setRemoveEnabled(bool enable)
QAbstractItemModel * rootModel() const
virtual Q_INVOKABLE void addMenuAction(QAction *newAction)
void setEditEnabled(bool enable)
qMRMLSceneModel * sceneModel() const
void nodeAdded(vtkMRMLNode *node)
void setCurrentNode(vtkMRMLNode *node)
Select the node to be current.
void setSizeAdjustPolicy(QComboBox::SizeAdjustPolicy policy)
void emitNodeActivated(int currentIndex)
qMRMLNodeFactory * nodeFactory() const
void setHideChildNodeTypes(const QStringList &nodeTypes)
virtual vtkMRMLNode * addNode(QString nodeType)
Creates a node of the same type as in the "node types" property.
Abstract Superclass for all specific types of MRML nodes.
A set of MRML Nodes that supports serialization and undo/redo.