27 explicit Demux(QGraphicsItem *parent =
nullptr);
35 void paint(QPainter *painter,
const QStyleOptionGraphicsItem *option, QWidget *widget)
override;
47 void generatePixmap();
51 void drawBody(QPainter *painter);
54 void setInputSize(
const int size)
override;
60 static int calculateSelectLines(
int dataCount);
Abstract base class for all graphical circuit elements.
void updateLogic() override
Routes the data input to the output selected by the select lines.
QRectF boundingRect() const override
void updatePortsProperties() override
Recalculates port positions for the current port count.
void setOutputSize(const int size) override
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) override
Demux(QGraphicsItem *parent=nullptr)
Constructs the element with optional parent.
GraphicElement(ElementType type, QGraphicsItem *parent=nullptr)
Constructs a graphic element of the given type, fetching all properties from the metadata registry.