Skip to content

Commit 01c7503

Browse files
ktfdavidrohr
authored andcommitted
DPL GUI: improve display of many devices
1 parent 675b5c9 commit 01c7503

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Framework/GUISupport/src/FrameworkGUIDevicesGraph.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ void showTopologyNodeGraph(WorkspaceGUIState& state,
290290
auto& node = sortedNodes[si];
291291
assert(node.index == si);
292292
int xpos = 40 + 240 * node.layer;
293-
int ypos = 300 + (600 / (layerMax[node.layer] + 1)) * (layerEntries[node.layer] - layerMax[node.layer] / 2);
293+
int ypos = 300 + (std::max(600, 60 * (int)layerMax[node.layer]) / (layerMax[node.layer] + 1)) * (layerEntries[node.layer] - layerMax[node.layer] / 2);
294294
positions.push_back(NodePos{ImVec2(xpos, ypos)});
295295
layerEntries[node.layer] += 1;
296296
}

0 commit comments

Comments
 (0)