15 #ifndef BORNAGAIN_GUI_VIEW_MATERIALEDITOR_MATERIALEDITORDIALOG_H
16 #define BORNAGAIN_GUI_VIEW_MATERIALEDITOR_MATERIALEDITORDIALOG_H
44 const QString& identifierOfPreviousMaterial);
79 Ui::MaterialEditorDialog*
m_ui;
Defines class MaterialItems.
Dialog to select a material and also to edit the list of existing materials. The dialog operates on a...
void removeCurrentMaterial()
MaterialItems m_tmpMaterialItems
void cloneCurrentMaterial()
static QString chooseMaterial(QWidget *parent, MultiLayerItem *sample, const QString &identifierOfPreviousMaterial)
Use this to choose a material. identifierOfPreviousMaterial is the material which should be selected ...
QAction * m_cloneMaterialAction
Materials for working within this dialog.
void setCurrentMaterial(const MaterialItem *m)
MaterialEditorDialog(MultiLayerItem *sample, QWidget *parent=nullptr)
MaterialItem * currentMaterial()
Ui::MaterialEditorDialog * m_ui
void addRefractiveMaterial()
~MaterialEditorDialog() override
QModelIndex currentIndex() const
MaterialEditorModel * m_model
QAction * m_removeMaterialAction
MultiLayerItem * m_sample
Model for the left list. Works on m_tmpMaterialItems.
QStringList identifiersOfUsedMaterials() const
Returns the list of material identifiers of the materials currently used in the sample....
static void editMaterials(QWidget *parent, MultiLayerItem *sample)
Use this to edit the list of existing materials.
void updateActionEnabling()
void accept() override
updates original material model with the edited model
Model for list of materials, used in MaterialEditorDialog.