30 lines
No EOL
655 B
C++
30 lines
No EOL
655 B
C++
#pragma once
|
|
|
|
#include "QuantumCircuitElementNode.h"
|
|
|
|
class QuantumTerminal;
|
|
class EquationNode;
|
|
class LatexMathExpression;
|
|
|
|
class QuantumTerminalNode : public QuantumCircuitElementNode
|
|
{
|
|
public:
|
|
QuantumTerminalNode(const Transform& transform);
|
|
|
|
Point2 getConnectionLocation(AbstractQuantumWire* wire) const override;
|
|
|
|
void setContent(QuantumTerminal* terminal);
|
|
|
|
void update(SceneInfo* sceneInfo);
|
|
private:
|
|
void createOrUpdateGeometry(SceneInfo* sceneInfo);
|
|
|
|
QuantumTerminal* mContent{ nullptr };
|
|
bool mContentDirty{ true };
|
|
|
|
double mWidth = 20.0;
|
|
double mHeight = 10.0;
|
|
|
|
Ptr<LatexMathExpression> mLabelExpression;
|
|
Ptr<EquationNode> mLabel;
|
|
}; |