| 829 | } |
| 830 | |
| 831 | void LayoutHelper::increaseHorizontalSpacing(std::vector<Node*>& nodes, float theSpacing) |
| 832 | { |
| 833 | if (nodes.size() < 2) |
| 834 | return; |
| 835 | |
| 836 | std::sort(nodes.begin(), nodes.end(), |
| 837 | [](Node* const left, Node* const right) -> bool { return getNodeLeft(left) < getNodeLeft(right); }); |
| 838 | |
| 839 | for (size_t idx = 1; idx < nodes.size(); ++idx) |
| 840 | { |
| 841 | nodes[idx]->setPositionX(nodes[idx]->getPositionX() + theSpacing * idx); |
| 842 | } |
| 843 | } |
| 844 | |
| 845 | void LayoutHelper::increaseVerticalSpacing(std::vector<Node*>& nodes, float theSpacing) |
| 846 | { |
nothing calls this directly
no test coverage detected