We notice some fairly significant performance slow-down as we initialize our diagram (specifically when switching what the diagram shows and doing mass additions/removals). The Thumbnail seems to be creating lots of WriteableBitmaps over and over at that time (specifically in BitmapUtils.CreateWriteableBitmap). This seems to happen the first time we use the diagram (say, 40+ invocations of CreateWriteableBitmap) but only once thereafter when we do wholesale changes of what we show in the diagram.
I initially thought it's something we do, but I don't find any difference between the first time we populate the diagram with shapes and subsequent times.
The call to CreateWriteableBitmap is triggered (ultimately, through several steps) by RadDiagramThumbnail.DeferredRefresh.
1) Is there any built-in functionality to limit the rate at which Thumbnail updates itself? If not, do I read the documentation correctly that we should expect to be able to use IsAutoRefreshEnabled and RefreshThumbnail to rate-limit the Thumbnail refreshes ourselves?
2) Any advice for further tracing/debugging why we see so many calls only the first time we populate the Diagram? Or, other things that we might be doing differently between the first time we populate Diagram and subsequent times?
Hi!
On my RadDiagram control I have generated elements with connections. How to prevent moving connection?
I want to allow the user only to detach and attach the connection. Forbidden situation is visualised in forbiddenSituation.PNG. If the user unpin the connection and he/she doesn't drag connection to another item, the connection shouldn't be changed. So all connections should have Target and Source element.
I use ConnectionManipulationCompleted event. When ManipulationStatus is Moved I want to Undo this, but the truth is only the previous change will be undone, not current connection moving.
I was thinking I can cache previous state of connection (target and source) on ConnectionManipulationStared and set those if on ConnectionManipulationCompleted target or source are null. But it doesn't work.
Hi,
Is it possible to process this method in background using BackgroundWorker or some other method using code-behind? My UI seems to freeze when I perform this as I have this hooked up to Diagram_MouseLeave event. It takes time as I have image as item in the background that gets written to a property in Viewmodel.
Hi,
Can you make resizing behave more like Visio? For example:
Regards,
Bayram
I need to fix the connector of the links, but despite the actions I took, connections jumps to another connector while dragging the shape. My sample is a typical hiearchy view, and this makes the relationship is looking reversed.
This is my link
<
Setter
Property
=
"SourceConnectorPosition"
Value
=
"Bottom"
/>
<
Setter
Property
=
"TargetConnectorPosition"
Value
=
"Top"
/>
​
And I have only two connector.
<
core:ConnectorCollection
x:Key
=
"customConnectors"
>
<
telerik:RadDiagramConnector
Offset
=
"0.5 0"
Name
=
"Top"
Background
=
"MediumVioletRed"
/>
<
telerik:RadDiagramConnector
Offset
=
"0.5 1"
Name
=
"Bottom"
Background
=
"YellowGreen"
/>
</
core:ConnectorCollection
>
Defined in the Shape style setter.
<
Setter
Property
=
"clocLink:AttachedProperties.CustomConnectors"
Value
=
"{StaticResource customConnectors}"
/>
Thank you for your help.
Hello,
When I set the connector tool, then start to draw a connection between two nodes, diagram allows to select the first node(Source) from all of the shape body (No need to start from a connector) but it only allows to drop the connection to a connector in target side. Droping it over the shape ends with a connection with null target property.
Is there a way to achieve enable the connection creation when the line is ended over a shape?
Regards,