20#ifndef LIBREPCB_CORE_COMPONENTSYMBOLVARIANT_H
21#define LIBREPCB_CORE_COMPONENTSYMBOLVARIANT_H
26#include "../../serialization/serializablekeyvaluemap.h"
27#include "../../serialization/serializableobjectlist.h"
71 const QString& desc_en_US)
noexcept;
87 bool setNorm(
const QString& norm)
noexcept;
89 bool setDescription(
const QString& locale,
const QString& desc)
noexcept;
117 return !(*
this == rhs);
124 const std::shared_ptr<const ComponentSymbolVariantItem>& item,
143 static constexpr const char*
tagname =
"variant";
The ComponentSymbolVariant class represents a symbol variant of a component.
Definition: componentsymbolvariant.h:53
const QString & getNorm() const noexcept
Definition: componentsymbolvariant.h:77
const LocalizedNameMap & getNames() const noexcept
Definition: componentsymbolvariant.h:81
ComponentSymbolVariantItemList & getSymbolItems() noexcept
Definition: componentsymbolvariant.h:94
ComponentSymbolVariant & operator=(const ComponentSymbolVariant &rhs) noexcept
Definition: componentsymbolvariant.cpp:164
const ComponentSymbolVariantItemList & getSymbolItems() const noexcept
Definition: componentsymbolvariant.h:97
Signal< ComponentSymbolVariant, Event > onEdited
Definition: componentsymbolvariant.h:63
const ElementName & getName() const noexcept
Definition: componentsymbolvariant.h:78
Uuid mUuid
Definition: componentsymbolvariant.h:128
bool setDescriptions(const LocalizedDescriptionMap &descriptions) noexcept
Definition: componentsymbolvariant.cpp:123
bool setDescription(const QString &locale, const QString &desc) noexcept
Definition: componentsymbolvariant.cpp:102
Event
Definition: componentsymbolvariant.h:56
Slot< ComponentSymbolVariant, Event > OnEditedSlot
Definition: componentsymbolvariant.h:64
~ComponentSymbolVariant() noexcept
Definition: componentsymbolvariant.cpp:74
LocalizedDescriptionMap mDescriptions
Definition: componentsymbolvariant.h:131
ComponentSymbolVariant()=delete
ComponentSymbolVariantItemList mSymbolItems
Definition: componentsymbolvariant.h:132
bool operator!=(const ComponentSymbolVariant &rhs) const noexcept
Definition: componentsymbolvariant.h:116
QSet< Uuid > getAllSymbolUuids() const noexcept
Definition: componentsymbolvariant.h:100
bool setNorm(const QString &norm) noexcept
Definition: componentsymbolvariant.cpp:81
bool setName(const QString &locale, const ElementName &name) noexcept
Definition: componentsymbolvariant.cpp:91
void itemsEdited(const ComponentSymbolVariantItemList &list, int index, const std::shared_ptr< const ComponentSymbolVariantItem > &item, ComponentSymbolVariantItemList::Event event) noexcept
Definition: componentsymbolvariant.cpp:181
LocalizedNameMap mNames
Definition: componentsymbolvariant.h:130
QString mNorm
Definition: componentsymbolvariant.h:129
void serialize(SExpression &root) const
Serialize into librepcb::SExpression node.
Definition: componentsymbolvariant.cpp:138
const LocalizedDescriptionMap & getDescriptions() const noexcept
Definition: componentsymbolvariant.h:82
const Uuid & getUuid() const noexcept
Definition: componentsymbolvariant.h:76
ComponentSymbolVariantItemList::OnEditedSlot mOnItemsEditedSlot
Definition: componentsymbolvariant.h:135
bool setNames(const LocalizedNameMap &names) noexcept
Definition: componentsymbolvariant.cpp:113
bool operator==(const ComponentSymbolVariant &rhs) const noexcept
Definition: componentsymbolvariant.cpp:154
static QSet< Uuid > getAllSymbolUuids(const ComponentSymbolVariantItemList &list) noexcept
Definition: componentsymbolvariantitem.h:160
The SExpression class.
Definition: sexpression.h:69
const T::ValueType & getDefaultValue() const noexcept
Definition: serializablekeyvaluemap.h:105
Event
Definition: serializableobjectlist.h:126
The Signal class is used to emit signals on non-QObject derived classes.
Definition: signalslot.h:65
The Slot class is used to receive signals from non-QObject derived classes.
Definition: signalslot.h:170
The Uuid class is a replacement for QUuid to get UUID strings without {} braces.
Definition: uuid.h:58
Definition: occmodel.cpp:77
type_safe::constrained_type< QString, ElementNameConstraint, ElementNameVerifier > ElementName
Definition: elementname.h:84
Definition: componentsymbolvariant.h:142
static constexpr const char * tagname
Definition: componentsymbolvariant.h:143