Class InputExtensions
Defines extensions for the IInputElement interface.
public static class InputExtensions
- Inheritance
-
InputExtensions
- Inherited Members
Methods
GetInputElementsAt(IInputElement, Point)
Returns the active input elements at a point on an IInputElement.
public static IEnumerable<IInputElement> GetInputElementsAt(this IInputElement element, Point p)
Parameters
element
IInputElementThe element to test.
p
PointThe point on
element
.
Returns
- IEnumerable<IInputElement>
The active input elements found at the point, ordered topmost first.
GetInputElementsAt(IInputElement, Point, bool)
Returns the active input elements at a point on an IInputElement.
public static IEnumerable<IInputElement> GetInputElementsAt(this IInputElement element, Point p, bool enabledElementsOnly = true)
Parameters
element
IInputElementThe element to test.
p
PointThe point on
element
.enabledElementsOnly
boolWhether to only return elements for which IsEffectivelyEnabled is true.
Returns
- IEnumerable<IInputElement>
The active input elements found at the point, ordered topmost first.
InputHitTest(IInputElement, Point)
Returns the topmost active input element at a point on an IInputElement.
public static IInputElement? InputHitTest(this IInputElement element, Point p)
Parameters
element
IInputElementThe element to test.
p
PointThe point on
element
.
Returns
- IInputElement
The topmost IInputElement at the specified position.
InputHitTest(IInputElement, Point, bool)
Returns the topmost active input element at a point on an IInputElement.
public static IInputElement? InputHitTest(this IInputElement element, Point p, bool enabledElementsOnly = true)
Parameters
element
IInputElementThe element to test.
p
PointThe point on
element
.enabledElementsOnly
boolWhether to only return elements for which IsEffectivelyEnabled is true.
Returns
- IInputElement
The topmost IInputElement at the specified position.
InputHitTest(IInputElement, Point, Func<Visual, bool>)
Returns the topmost active input element at a point on an IInputElement.
public static IInputElement? InputHitTest(this IInputElement element, Point p, Func<Visual, bool> filter)
Parameters
element
IInputElementThe element to test.
p
PointThe point on
element
.filter
Func<Visual, bool>A filter predicate. If the predicate returns false then the visual and all its children will be excluded from the results.
Returns
- IInputElement
The topmost IInputElement at the specified position.
InputHitTest(IInputElement, Point, Func<Visual, bool>, bool)
Returns the topmost active input element at a point on an IInputElement.
public static IInputElement? InputHitTest(this IInputElement element, Point p, Func<Visual, bool> filter, bool enabledElementsOnly = true)
Parameters
element
IInputElementThe element to test.
p
PointThe point on
element
.filter
Func<Visual, bool>A filter predicate. If the predicate returns false then the visual and all its children will be excluded from the results.
enabledElementsOnly
boolWhether to only return elements for which IsEffectivelyEnabled is true.
Returns
- IInputElement
The topmost IInputElement at the specified position.