I looked at the RadDiagram options, but it doesn't have anything that compares to a circular relationship chart. Here's an example:
https://www.codeproject.com/KB/silverlight/342715/screenshot2.png
Part of this article:
https://www.codeproject.com/Articles/342715/Plotting-Circular-Relationship-Graphs-with-Silverl
I gave some thought at trying to rewrite the code into WPF, but I've got too many other irons in the fire. Figured I'd ask as this sort of visualization control doesn't appear in your current collection. I have a project that could benefit from displaying weighted relationships in such a manner, but my choices are either do something sub-par with the RadDiagram option, write one myself, find another controls collection and port everything, or leave the feature out for now. I'm going for the leave it out option for the moment, and see if your UI wizards can come up with something...
Just as a use case, one of the reasons for wanting this is to diagram conversations between individuals in email messages. Being able to show who's talking to whom and how frequently using one of these charts for visualization allows you to quickly find patterns...
While performing Cut operation inside RadDiagram, an exception in the MS Clipboard occurs with the following message:
System.Runtime.InteropServices.COMException: 'OpenClipboard Failed (Exception from HRESULT: 0x800401D0 (CLIPBRD_E_CANT_OPEN))'
If we have a custom shape that derives from RadDiagramShapeBase and we rotate it at some degree (90) for example, and then resize it the diagram's selection adorner is misplaced with the shape. Workaround:
Set RenderTransofrmOrigin = new Point(0.5, 0.5) to the shape.
Other workaround: Derive the custom shape from RadDiagramShape, instead of RadDiagramShapeBase.
To reproduce this use the following code snippet:
<
telerik:RadDiagram
>
<
telerik:RadDiagramShape
Content
=
"Shape 1"
Position
=
"100, 100"
/>
<
telerik:RadDiagramShape
Content
=
"Shape 2"
UseGlidingConnector
=
"True"
Position
=
"300, 100"
/>
</
telerik:RadDiagram
>
Steps to reproduce:
1. Start a new connection from Shape 1, by dragging one of its connectors.
2. Drag the connection over Shape 2.
Expected: The connector closest to the mouse should get highlighted and when you drop the connection it should get attached to the shape.
Actual: The closest connector is not highlighted. Also, when you drop the connection over the target shape it doesn't get attached.
The exception is thrown for the RotationAngle property.
The issue can be observed also in the opposite direction - the diagram is serialized on a machine with some culture (for example Portugal Porguese - pt-PT) and then restored on a machine with an English culture.
The issue reproduces only when saving and loading between cultures which numeric separators are different. For example, with Bulgarian culture, the number 4.5 is represented as 4,5 (with a comma). With English culture the number will be represented as 4.5 (with a period).
To work this around, create a custom RadDiagramShape and override its Deserialize() method. Then parse the RotationAngle manually, and set it to the RotationAngle property of the shape. After this, set the RotationAngle of the SerializationInfo to null, in order to prevent the default restoring of the property.
public
partial
class
CustomShape : RadDiagramShape, IEquatable<BaseShape>
{
public
override
void
Deserialize(SerializationInfo info)
{
if
(info[
"RotationAngle"
] !=
null
)
{
var angle = Convert.ToDouble(info[
"RotationAngle"
].ToString(), CultureInfo.InvariantCulture);
this
.RotationAngle = angle;
info[
"RotationAngle"
] =
null
;
}
base
.Deserialize(info);
}
}
Research and improve the virtualization performance. Currently, the virtualization in the diagram creates containers for all shapes and sets the Visibility of the containers outside of the viewport to Collapsed. This saves from the layout and rendering performance, but it is not optimal. Consider implementing a standard virtualization mechanism which adds containers in the visual tree only for the shapes within the viewport.
User scenario:
When zooming out on more than 500-600 shapes and then panning, if telerik:DiagramSurface.IsVirtualizing="True", the performance is slower. When virtualization is off, the performance is a little better.
Connect the Diagrams BackgroundGrid to the Ruler's Measurement Unit and ScaleDefinitions. Currently only in DPI measurement unit the scaledefinitions and diagram background grid look good and consistent.
A possible workaround is to use an attached property. Basically, we've added ConnectionPointsProperty in AttachedProperties class and added binding to this new property in the style of the connection. public class AttachedProperties { public static RadDiagram Diagram { get; set; } public static readonly DependencyProperty ConnectionPointsProperty = DependencyProperty.RegisterAttached("ConnectionPoints", typeof(List<Point>), typeof(AttachedProperties), new PropertyMetadata(null, OnConnectionPointsChanged)); public static IEnumerable<Point> GetConnectionPoints(DependencyObject obj) { return (IEnumerable<Point>)obj.GetValue(ConnectionPointsProperty); } public static void SetConnectionPoints(DependencyObject obj, IEnumerable<Point> value) { obj.SetValue(ConnectionPointsProperty, value); } private static void OnConnectionPointsChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { var connection = d as RadDiagramConnection; var connectionPoints = e.NewValue as List<Point>; if (connection != null && connectionPoints != null) { for (int i = 0; i < connectionPoints.ToList().Count; i++) { connection.ConnectionPoints.Add(connectionPoints.ToList()[i]); } connection.IsModified = true; (connection as IConnection).Update(); } } } <telerik:RadDiagram.ConnectionStyle> <Style TargetType="telerik:RadDiagramConnection"> <Setter Property="ConnectionType" Value="Polyline"/> <Setter Property="local:AttachedProperties.ConnectionPoints" Value="{Binding MyConnectionPoints}"/> </Style> </telerik:RadDiagram.ConnectionStyle>
You should be able to prevent the horizontal/vertical overlapping of routed connections . This way the connections should be easier to differentiate. To better differentiate connections, users might: --- use labels on the connections --- use bezier connections --- use different colors for different connections --- use more custom connectors and attach the connections to not used connectors -- use AStartRouter instead of the default one (Grid Router)
Be able to pre-select, printer, page size and page orientation in the RadDiagramPrintPreview. By default, RadDiagramPrintPreview set the printing orientation in landscape even if we created a diagram in portrait.
A small glitch appears when the pencil tool is used. The glitch is demonstrated in the attached image.
RadDiagramShape has NULL content but has DataContext and ContentTemplate. In the ContentTemplate there are UIElements defined. Their automation peers are not added in the automation tree. This can be observed in UIVerify tools.