DataGridEnumColumn Class
Represents a data-bound column for use in a DataGrid that utilizes the EnumEditBox control.
public class DataGridEnumColumn : DataGridPartEditBoxColumnBase<object>
- Inheritance:
- object DataGridColumn DataGridBoundColumn DataGridBoundColumnBase DataGridPartEditBoxColumnBase<object> object
Constructors
DataGridEnumColumn()
Initializes an instance of the class.
public DataGridEnumColumn()
Properties
EnumSortComparer
The IComparer<T> used to sort the enumeration values.
public IComparer<Enum>? EnumSortComparer { get; set; }
Property Value
- IComparer<Enum>:
The IComparer<T> used to sort the enumeration values; otherwise
nullto indicate no sorting, which will use the order the enumeration values are defined.
EnumType
The enumeration type.
IsArrowKeyPartNavigationEnabled
Indicates whether the left/right arrow keys can be used to move between and select editable parts.
public bool IsArrowKeyPartNavigationEnabled { get; set; }
Property Value
- bool:
trueif the left/right arrow keys can be used to move between and select editable parts; otherwisefalse. The default value isfalse.
IsEditable
Indicates whether the edit box's text area is editable.
public bool IsEditable { get; set; }
Property Value
- bool:
trueif the edit box's text area is editable; otherwisefalse. The default value isfalse.
Remarks
When false, the edit box behaves more like a ComboBox.
SpinWrapping
The wrapping behavior used when spinning past a minimum or maximum value in the active part.
public SpinWrapping SpinWrapping { get; set; }
Property Value
- SpinWrapping:
The default value is SimpleWrap.
UseDisplayAttributes
A value indicating whether enumeration values should be displayed using an associated DisplayAttribute, if any.
public bool UseDisplayAttributes { get; set; }
Property Value
- bool:
trueif enumeration values should be displayed using an associatedDisplayAttribute, if any; otherwisefalse. The default value isfalse.
Methods
ApplyStandardValues(FrameworkElement)
Applies standard values to the specified target element.
protected override void ApplyStandardValues(FrameworkElement targetElement)
| Parameter | Type | Description |
|---|---|---|
| targetElement | FrameworkElement | The target element. |
GetEditBoxType()
The type of the associated PartEditBoxBase-derived control.
Fields
EnumSortComparerProperty
Defines the EnumSortComparer property.
public static readonly DependencyProperty EnumSortComparerProperty
EnumTypeProperty
Defines the EnumType property.
public static readonly DependencyProperty EnumTypeProperty
UseDisplayAttributesProperty
Defines the UseDisplayAttributes property.
public static readonly DependencyProperty UseDisplayAttributesProperty
Inherited Members
- DataGridPartEditBoxColumnBase<object>.CommitTriggersProperty
- DataGridPartEditBoxColumnBase<object>.HasPopupProperty
- DataGridPartEditBoxColumnBase<object>.IsArrowKeyPartNavigationEnabledProperty
- DataGridPartEditBoxColumnBase<object>.IsEditableProperty
- DataGridPartEditBoxColumnBase<object>.IsNullAllowedProperty
- DataGridPartEditBoxColumnBase<object>.IsUndoEnabledProperty
- DataGridPartEditBoxColumnBase<object>.PlaceholderTextProperty
- DataGridPartEditBoxColumnBase<object>.SpinnerVisibilityProperty
- DataGridPartEditBoxColumnBase<object>.SpinWrappingProperty
- DataGridPartEditBoxColumnBase<object>.TextAlignmentProperty
- DataGridPartEditBoxColumnBase<object>.GenerateEditBox(bool, DataGridCell)
- DataGridPartEditBoxColumnBase<object>.GenerateEditingElement(DataGridCell, object)
- DataGridPartEditBoxColumnBase<object>.GenerateElement(DataGridCell, object)
- DataGridPartEditBoxColumnBase<object>.PrepareCellForEdit(FrameworkElement, RoutedEventArgs)
- DataGridPartEditBoxColumnBase<object>.DefaultEditingElementStyle
- DataGridPartEditBoxColumnBase<object>.DefaultElementStyle
- DataGridPartEditBoxColumnBase<object>.CommitTriggers
- DataGridPartEditBoxColumnBase<object>.HasPopup
- DataGridPartEditBoxColumnBase<object>.IsNullAllowed
- DataGridPartEditBoxColumnBase<object>.IsUndoEnabled
- DataGridPartEditBoxColumnBase<object>.PlaceholderText
- DataGridPartEditBoxColumnBase<object>.SpinnerVisibility
- DataGridPartEditBoxColumnBase<object>.TextAlignment
- DataGridBoundColumnBase.ApplyBinding(FrameworkElement, DependencyProperty)
- DataGridBoundColumnBase.ApplyValue(DependencyProperty, FrameworkElement, DependencyProperty)
- DataGridBoundColumnBase.RefreshCellContent(FrameworkElement, string)