Class VisualTreeExtensions
Represents a class to find visual tree children and parents elements of diagram control.
Inheritance
System.Object
VisualTreeExtensions
Namespace: Syncfusion.UI.Xaml.Diagram.Utility
Assembly: Syncfusion.SfDiagram.WPF.dll
Syntax
public static class VisualTreeExtensions : Object
Methods
FindVisualParent<T>(DependencyObject, MouseEventArgs)
Method to find dependency object type of visual parent based on mouse event arguments.
Declaration
public static T FindVisualParent<T>(this DependencyObject dobj, MouseEventArgs args = null)
where T : DependencyObject
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | dobj | Dependency object value. |
System.Windows.Input.MouseEventArgs | args | Mouse event arguments value. |
Returns
Type | Description |
---|---|
T | Returns visual objects value. |
Type Parameters
Name | Description |
---|---|
T | Dependency object value. |
FindVisualParent<T>(FrameworkElement, String)
Method to find framework type of visual parent based on elements name.
Declaration
public static T FindVisualParent<T>(this FrameworkElement dobj, string searchName)
where T : FrameworkElement
Parameters
Type | Name | Description |
---|---|---|
System.Windows.FrameworkElement | dobj | Framework element. |
System.String | searchName | Name of searching elements. |
Returns
Type |
---|
T |
Type Parameters
Name | Description |
---|---|
T | Framework element. |