20#ifndef LIBREPCB_CORE_COMPONENTSYMBOLVARIANTITEM_H
21#define LIBREPCB_CORE_COMPONENTSYMBOLVARIANTITEM_H
26#include "../../serialization/serializableobjectlist.h"
27#include "../../types/angle.h"
28#include "../../types/point.h"
29#include "../../types/uuid.h"
62 SymbolPositionChanged,
63 SymbolRotationChanged,
75 const Uuid& uuid,
const Uuid& symbolUuid,
const Point& symbolPos,
116 return !(*
this == rhs);
124 const std::shared_ptr<const ComponentPinSignalMapItem>& item,
145 static constexpr const char*
tagname =
"gate";
163 for (
const auto& item : list) {
164 set.insert(item.getSymbolUuid());
The Angle class is used to represent an angle (for example 12.75 degrees)
Definition: angle.h:78
The ComponentSymbolVariantItem class represents one symbol of a component symbol variant.
Definition: componentsymbolvariantitem.h:54
~ComponentSymbolVariantItem() noexcept
Definition: componentsymbolvariantitem.cpp:86
ComponentSymbolVariantItemSuffix mSuffix
Definition: componentsymbolvariantitem.h:133
const ComponentSymbolVariantItemSuffix & getSuffix() const noexcept
Definition: componentsymbolvariantitem.h:87
bool setSymbolUuid(const Uuid &uuid) noexcept
Definition: componentsymbolvariantitem.cpp:93
Slot< ComponentSymbolVariantItem, Event > OnEditedSlot
Definition: componentsymbolvariantitem.h:69
Point mSymbolPos
Definition: componentsymbolvariantitem.h:130
bool setSuffix(const ComponentSymbolVariantItemSuffix &suffix) noexcept
Definition: componentsymbolvariantitem.cpp:133
bool setIsRequired(bool required) noexcept
Definition: componentsymbolvariantitem.cpp:123
ComponentSymbolVariantItem & operator=(const ComponentSymbolVariantItem &rhs) noexcept
Definition: componentsymbolvariantitem.cpp:178
bool operator!=(const ComponentSymbolVariantItem &rhs) const noexcept
Definition: componentsymbolvariantitem.h:115
Signal< ComponentSymbolVariantItem, Event > onEdited
Definition: componentsymbolvariantitem.h:68
Uuid mUuid
Definition: componentsymbolvariantitem.h:128
Event
Definition: componentsymbolvariantitem.h:59
bool setSymbolRotation(const Angle &rot) noexcept
Definition: componentsymbolvariantitem.cpp:113
const Point & getSymbolPosition() const noexcept
Definition: componentsymbolvariantitem.h:84
Uuid mSymbolUuid
Definition: componentsymbolvariantitem.h:129
bool mIsRequired
Definition: componentsymbolvariantitem.h:132
ComponentPinSignalMap & getPinSignalMap() noexcept
Definition: componentsymbolvariantitem.h:99
bool isRequired() const noexcept
Definition: componentsymbolvariantitem.h:86
const ComponentPinSignalMap & getPinSignalMap() const noexcept
Definition: componentsymbolvariantitem.h:100
Angle mSymbolRot
Definition: componentsymbolvariantitem.h:131
bool operator==(const ComponentSymbolVariantItem &rhs) const noexcept
Definition: componentsymbolvariantitem.cpp:166
ComponentSymbolVariantItem()=delete
void serialize(SExpression &root) const
Serialize into librepcb::SExpression node.
Definition: componentsymbolvariantitem.cpp:148
ComponentPinSignalMap mPinSignalMap
Definition: componentsymbolvariantitem.h:134
const Uuid & getUuid() const noexcept
Definition: componentsymbolvariantitem.h:82
const Uuid & getSymbolUuid() const noexcept
Definition: componentsymbolvariantitem.h:83
const Angle & getSymbolRotation() const noexcept
Definition: componentsymbolvariantitem.h:85
bool setSymbolPosition(const Point &pos) noexcept
Definition: componentsymbolvariantitem.cpp:103
void pinSignalMapEdited(const ComponentPinSignalMap &map, int index, const std::shared_ptr< const ComponentPinSignalMapItem > &item, ComponentPinSignalMap::Event event) noexcept
Definition: componentsymbolvariantitem.cpp:197
ComponentPinSignalMap::OnEditedSlot mOnPinSignalMapEditedSlot
Definition: componentsymbolvariantitem.h:137
Definition: componentsymbolvariantitem.h:156
static QSet< Uuid > getAllSymbolUuids(const ComponentSymbolVariantItemList &list) noexcept
Definition: componentsymbolvariantitem.h:160
ComponentSymbolVariantItemListHelpers()=delete
The Point class is used to represent a point/coordinate/vector, for example (1.2mm; 5....
Definition: point.h:79
The SExpression class.
Definition: sexpression.h:69
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, ComponentSymbolVariantItemSuffixConstraint, ComponentSymbolVariantItemSuffixVerifier > ComponentSymbolVariantItemSuffix
Definition: componentsymbolvariantitemsuffix.h:89
Definition: componentsymbolvariantitem.h:144
static constexpr const char * tagname
Definition: componentsymbolvariantitem.h:145