Maintain the Line thickness throughout zoom


In the default zoom the nodes and the links look fine but when I zoom out the diagram the visibility of lines (nodes and links) becomes way too thin and its very difficult to visualize it. Is there any way to keep the line thickness same throughout the zoom.

Please refer the image below:

Without zoom



“Zooming” just changes the DiagramPanel.Scale and Position.

You could implement a Diagram.ViewportBoundsChanged event handler to modify the stroke thicknesses of various Shapes when the Scale changes.

Thanks Walter,

But in our application there are some links which are combination of multiple link shapes. This is done to achieve desired link shape. Also there could be more than 600 links and nodes with multiple diagram instances in a single application. The above approach could affect the application performance in adverse way. Is there any work around for the above question?

That is the only way. Regarding performance, you do not have to change any thicknesses upon every tiny change in DiagramPanel.Scale. Only when the scale crosses certain boundaries.