WPF › Control Visual Sizer › ResizerGripElementCursorConverter
ResizerGripElementCursorConverter
class.NET 6 / 8 / 10.NET Framework 4.8Binarymission.WPF.Controls.Containers
Turns a Direction into the mouse pointer shown over the resize grip of a
ControlVisualResizer.
public sealed class ResizerGripElementCursorConverter : IValueConverter
Inherits from / implements: IValueConverter
Remarks
The default template binds the grip's FrameworkElement.Cursor through it. It
is public so that a template of your own can do the same.
Members at a glance
| Methods | |
|---|---|
Convert | Returns the mouse pointer for the given resize direction. |
ConvertBack | Not supported: a mouse pointer cannot be turned back into a direction. |
Methods
Convert
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
Returns the mouse pointer for the given resize direction.
Parameters
value- The resizer's
Direction. targetType- Not used.
parameter- Not used.
culture- Not used.
Returns
SizeNWSE (the diagonal double arrow) for
Direction.SouthEast; None, which hides the pointer, for
Direction.None.
Exceptions
System.InvalidCastExceptionvalueis not aDirection.System.NullReferenceExceptionvalueisnull.
ConvertBack
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
Not supported: a mouse pointer cannot be turned back into a direction.
Parameters
value- Not used.
targetType- Not used.
parameter- Not used.
culture- Not used.
Returns
Always DependencyProperty.UnsetValue.