Colors and rearrange

This commit is contained in:
Joey Yakimowich-Payne 2026-01-29 22:22:47 -07:00
commit 2edd7a366a
4 changed files with 58 additions and 14 deletions

View file

@ -69,7 +69,8 @@ private:
static QString captionForNode(const warppipe::NodeInfo &info);
static WarpNodeType classifyNode(const warppipe::NodeInfo &info);
static QVariant styleForNode(WarpNodeType type, bool ghost);
QPointF nextPosition() const;
QPointF nextPosition(const WarpNodeData &data);
static QSize estimateNodeSize(const WarpNodeData &data);
warppipe::Client *m_client = nullptr;
QtNodes::NodeId m_nextNodeId = 1;
@ -83,4 +84,11 @@ private:
std::unordered_map<QtNodes::NodeId, QPointF> m_positions;
std::unordered_map<QtNodes::NodeId, QSize> m_sizes;
std::unordered_set<QtNodes::NodeId> m_ghostNodes;
static constexpr double kHorizontalGap = 40.0;
static constexpr double kVerticalGap = 30.0;
static constexpr double kMaxRowWidth = 1400.0;
double m_nextX = 0.0;
double m_nextY = 0.0;
double m_rowMaxHeight = 0.0;
};