25 qDeleteAll( mMetadata );
30 if ( !metadata || mMetadata.contains( metadata->
type() ) )
33 mMetadata[metadata->
type()] = metadata;
34 mMaterialsOrder << metadata->
type();
40 if ( !mMetadata.contains( type ) )
43 return mMetadata[type]->create();
48 return mMetadata.value( type );
54 for (
const QString &material : mMaterialsOrder )
56 if ( mMetadata.value( material ) )
bool addMaterialSettingsType(QgsMaterialSettingsAbstractMetadata *metadata)
Registers a new material settings type. Takes ownership of the metadata instance.
QgsMaterialSettingsAbstractMetadata * materialSettingsMetadata(const QString &type) const
Returns metadata for specified material settings type. Returns nullptr if not found.
QgsAbstractMaterialSettings * createMaterialSettings(const QString &type) const
Creates a new instance of the material settings of the specified type.
QStringList materialSettingsTypes() const
Returns a list of all available material settings types.