DiagramCustomGetEditableItemPropertiesEventArgs.CreateProxyProperty<TProperty>(String, Func<IDiagramItem, TProperty>, Action<IDiagramItem, TProperty>, IEnumerable<Attribute>) Method
Allows you to create a custom property descriptor.
Namespace: DevExpress.Xpf.Diagram
Assembly: DevExpress.Xpf.Diagram.v24.2.dll
NuGet Package: DevExpress.Wpf.Diagram
Declaration
public PropertyDescriptor CreateProxyProperty<TProperty>(
string name,
Func<IDiagramItem, TProperty> getter,
Action<IDiagramItem, TProperty> setter,
IEnumerable<Attribute> attributes = null
)
Parameters
Name | Type | Description |
---|---|---|
name | String | A string value that is the property’s name. |
getter | Func<DevExpress.Diagram.Core.IDiagramItem, TProperty> | A System.Func object specifying the function of the property getter. |
setter | Action<DevExpress.Diagram.Core.IDiagramItem, TProperty> | A System.Func object specifying the function of the property setter. |
Optional Parameters
Name | Type | Default | Description |
---|---|---|---|
attributes | IEnumerable<Attribute> | null | A collection of property attributes. |
Type Parameters
Name |
---|
TProperty |
Returns
Type | Description |
---|---|
PropertyDescriptor | The property descriptor that can be added to the Properties collection. |
Remarks
Use the CreateProxyProperty method to allow users to edit properties that are not defined directly at the diagram item level. This can be useful when your diagram is bound to a data source and you need to edit data item properties.
See Also