UIElement UIElement UIElement UIElement Class


Some information relates to pre-released product which may be substantially modified before it’s commercially released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Prerelease APIs are identified by a Prerelease label.

[Contains prerelease APIs.]
UIElement is a base class for most of the Windows Runtime UI objects that have visual appearance and can process basic input as part of your app's user interface.

public : class UIElement : DependencyObject, IUIElement, IUIElement2, IUIElement3, IUIElement4, IUIElement5, IUIElement7, IUIElementOverrides
struct winrt::Windows::UI::Xaml::UIElement : DependencyObject, IUIElement, IUIElement2, IUIElement3, IUIElement4, IUIElement5, IUIElement7, IUIElementOverrides
public class UIElement : DependencyObject, IUIElement, IUIElement2, IUIElement3, IUIElement4, IUIElement5, IUIElement7, IUIElementOverrides
Public Class UIElement Inherits DependencyObject Implements IUIElement, IUIElement2, IUIElement3, IUIElement4, IUIElement5, IUIElement7, IUIElementOverrides
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)


UIElement is a base element: it's a class that many other Windows Runtime classes inherit from in order to support the XAML UI element model. Properties, methods and events that UIElement defines are inherited by hundreds of other Windows Runtime classes.

Although UIElement defines the events for focus reporting (GotFocus, LostFocus ), UIElement does not define an API for programmatically setting the focus. This capability is defined by the Control class.

UIElement does not expose a public constructor. Typically, you don't derive classes from either UIElement or FrameworkElement directly. More typically used base classes for derived custom classes are these classes:

The UIElement class is used as the type parameter of many properties and methods in the Windows Runtime API. For example, the Child property of Border takes a single UIElement, which represents the element that the Border is drawn around. You can provide any UIElement -derived element for such a property, including custom controls that you define.

The UIElementCollection class provides a strongly typed collection of UIElement items. UIElementCollection is used as a type for properties of objects that contain several child elements, for example for the Children property of any Panel class.

UIElement API and features

UIElement extends DependencyObject, which is another base element, and adds support for various Windows Runtime feature areas.

Input, and events for responding to user interaction

Much of the input behavior for visible elements in a UI is defined in the UIElement class. This includes the events for keyboard, mouse, touch, drag-drop, and focus interactions. For more info, see Handle pointer input, Keyboard interactions, and Custom user interactions.

Prominent API of UIElement that support input and user interaction:

Gestures and manipulations

Gestures and manipulations are also a way to handle input and user interaction. The API are listed out separately here because these events represent how the system interacts with device-level input actions and interprets them as a user interaction. Manipulations are a way to handle dynamic multi-touch interactions such as pinching and stretching. Together, the gestures and manipulations provide the touch patterns for touch interaction with UWP app. For more info, see Custom user interactions and Touch interaction design.

Prominent API of UIElement that support gestures and manipulations:

Basic appearance

The Visibility and Opacity properties are frequently used to adjust the appearance of an element in your UI, especially within styles, templates, and visual states. The Clip, RenderTransform, and Transitions properties are each useful for producing interactions and different looks for your UI elements.

Basic layout

The UIElement class provides a starting point for layout characteristics with properties such as DesiredSize and the Arrange and Measure methods. FrameworkElement adds more layout capabilities. For more info, see Define layouts with XAML and FrameworkElement.

Routed events

Most of the input events of UIElement are routed events. A routed event enables a built-in event handling notification system, so that a parent object can handle input events from child objects in the object tree if the event remains unhandled. This input event behavior is useful for input area grouping, and for control compositing. For more info, see Events and routed events overview.

Prominent API of UIElement that support routed events: AddHandler, RemoveHandler, **Event* properties.

Other platform support

UIElement dependency properties

Many of the read-write properties of the UIElement base element class are dependency properties. Dependency properties support some of the basic programming model features for a UWP app using C++, C#, or Visual Basic, such as styles and templates, data binding, XAML resource references, and property-changed logic. For more info on dependency properties and the features they support, see Dependency properties overview.

UIElement derived classes

The only Windows Runtime class that derives directly from UIElement is FrameworkElement. For a list of the classes that derive from FrameworkElement, see the "FrameworkElement derived classes" section of the FrameworkElement reference topic.


AccessKey AccessKey AccessKey AccessKey

Gets or sets the access key (mnemonic) for this element.

AccessKeyProperty AccessKeyProperty AccessKeyProperty AccessKeyProperty

Identifies for the AccessKey dependency property.

AccessKeyScopeOwner AccessKeyScopeOwner AccessKeyScopeOwner AccessKeyScopeOwner

Gets or sets a source element that provides the access key scope for this element, even if it's not in the visual tree of the source element.

AccessKeyScopeOwnerProperty AccessKeyScopeOwnerProperty AccessKeyScopeOwnerProperty AccessKeyScopeOwnerProperty

Identifies for the AccessKeyScopeOwner dependency property.

AllowDrop AllowDrop AllowDrop AllowDrop

Gets or sets a value that determines whether this UIElement can be a drop target for purposes of drag-and-drop operations.

AllowDropProperty AllowDropProperty AllowDropProperty AllowDropProperty

Identifies the AllowDrop dependency property.

BringIntoViewRequestedEvent BringIntoViewRequestedEvent BringIntoViewRequestedEvent BringIntoViewRequestedEvent

Gets the identifier for the BringIntoViewRequested routed event.

CacheMode CacheMode CacheMode CacheMode

Gets or sets a value that indicates that rendered content should be cached as a composited bitmap when possible.

CacheModeProperty CacheModeProperty CacheModeProperty CacheModeProperty

Identifies the CacheMode dependency property.

CanDrag CanDrag CanDrag CanDrag

Gets or sets a value that indicates whether the element can be dragged as data in a drag-and-drop operation.

CanDragProperty CanDragProperty CanDragProperty CanDragProperty

Identifies the CanDrag dependency property.

CharacterReceivedEvent CharacterReceivedEvent CharacterReceivedEvent CharacterReceivedEvent

Gets the identifier for the CharacterReceived routed event.

Clip Clip Clip Clip

Gets or sets the RectangleGeometry used to define the outline of the contents of a UIElement.

ClipProperty ClipProperty ClipProperty ClipProperty

Identifies the Clip dependency property.

CompositeMode CompositeMode CompositeMode CompositeMode

Gets or sets a property that declares alternate composition and blending modes for the element in its parent layout and window. This is relevant for elements that are involved in a mixed XAML / Microsoft DirectX UI.

CompositeModeProperty CompositeModeProperty CompositeModeProperty CompositeModeProperty

Identifies the CompositeMode dependency property.

ContextFlyout ContextFlyout ContextFlyout ContextFlyout

Gets or sets the flyout associated with this element.

ContextFlyoutProperty ContextFlyoutProperty ContextFlyoutProperty ContextFlyoutProperty

Identifies for the ContextFlyout dependency property.

ContextRequestedEvent ContextRequestedEvent ContextRequestedEvent ContextRequestedEvent

Gets the identifier for the ContextRequested routed event.

DesiredSize DesiredSize DesiredSize DesiredSize

Gets the size that this UIElement computed during the measure pass of the layout process.

Dispatcher Dispatcher Dispatcher Dispatcher

Gets the CoreDispatcher that this object is associated with. The CoreDispatcher represents a facility that can access the DependencyObject on the UI thread even if the code is initiated by a non-UI thread.

(Inherited from DependencyObject)
DoubleTappedEvent DoubleTappedEvent DoubleTappedEvent DoubleTappedEvent

Gets the identifier for the DoubleTapped routed event.

DragEnterEvent DragEnterEvent DragEnterEvent DragEnterEvent

Gets the identifier for the DragEnter routed event.

DragLeaveEvent DragLeaveEvent DragLeaveEvent DragLeaveEvent

Gets the identifier for the DragLeave routed event.

DragOverEvent DragOverEvent DragOverEvent DragOverEvent

Gets the identifier for the DragOver routed event.

DropEvent DropEvent DropEvent DropEvent

Gets the identifier for the Drop routed event.

ExitDisplayModeOnAccessKeyInvoked ExitDisplayModeOnAccessKeyInvoked ExitDisplayModeOnAccessKeyInvoked ExitDisplayModeOnAccessKeyInvoked

Gets or sets a value that specifies whether the access key display is dismissed when an access key is invoked.

ExitDisplayModeOnAccessKeyInvokedProperty ExitDisplayModeOnAccessKeyInvokedProperty ExitDisplayModeOnAccessKeyInvokedProperty ExitDisplayModeOnAccessKeyInvokedProperty

Identifies the ExitDisplayModeOnAccessKeyInvoked dependency property.

GettingFocusEvent GettingFocusEvent GettingFocusEvent GettingFocusEvent

Gets the identifier for the GettingFocus routed event.

HighContrastAdjustment HighContrastAdjustment HighContrastAdjustment HighContrastAdjustment

Gets or sets a value that indicates whether the framework automatically adjusts the element's visual properties when high contrast themes are enabled.

HighContrastAdjustmentProperty HighContrastAdjustmentProperty HighContrastAdjustmentProperty HighContrastAdjustmentProperty

Identifies the HighContrastAdjustment dependency property.

HoldingEvent HoldingEvent HoldingEvent HoldingEvent

Gets the identifier for the Holding routed event.

IsAccessKeyScope IsAccessKeyScope IsAccessKeyScope IsAccessKeyScope

Gets or sets a value that indicates whether an element defines its own access key scope.

IsAccessKeyScopeProperty IsAccessKeyScopeProperty IsAccessKeyScopeProperty IsAccessKeyScopeProperty

Identifies for the IsAccessKeyScope dependency property.

IsDoubleTapEnabled IsDoubleTapEnabled IsDoubleTapEnabled IsDoubleTapEnabled

Gets or sets a value that determines whether the DoubleTapped event can originate from that element.

IsDoubleTapEnabledProperty IsDoubleTapEnabledProperty IsDoubleTapEnabledProperty IsDoubleTapEnabledProperty

Identifies the IsDoubleTapEnabled dependency property.

IsHitTestVisible IsHitTestVisible IsHitTestVisible IsHitTestVisible

Gets or sets whether the contained area of this UIElement can return true values for hit testing.

IsHitTestVisibleProperty IsHitTestVisibleProperty IsHitTestVisibleProperty IsHitTestVisibleProperty

Identifies the IsHitTestVisible dependency property.

IsHoldingEnabled IsHoldingEnabled IsHoldingEnabled IsHoldingEnabled

Gets or sets a value that determines whether the Holding event can originate from that element.

IsHoldingEnabledProperty IsHoldingEnabledProperty IsHoldingEnabledProperty IsHoldingEnabledProperty

Identifies the IsHoldingEnabled dependency property.

IsRightTapEnabled IsRightTapEnabled IsRightTapEnabled IsRightTapEnabled

Gets or sets a value that determines whether the RightTapped event can originate from that element.

IsRightTapEnabledProperty IsRightTapEnabledProperty IsRightTapEnabledProperty IsRightTapEnabledProperty

Identifies the IsRightTapEnabled dependency property.

IsTapEnabled IsTapEnabled IsTapEnabled IsTapEnabled

Gets or sets a value that determines whether the Tapped event can originate from that element.

IsTapEnabledProperty IsTapEnabledProperty IsTapEnabledProperty IsTapEnabledProperty

Identifies the IsTapEnabled dependency property.

KeyboardAcceleratorPlacementMode KeyboardAcceleratorPlacementMode KeyboardAcceleratorPlacementMode KeyboardAcceleratorPlacementMode

Gets or sets a value that indicates whether the control tooltip displays the key combination for it's associated keyboard accelerator.

KeyboardAcceleratorPlacementModeProperty KeyboardAcceleratorPlacementModeProperty KeyboardAcceleratorPlacementModeProperty KeyboardAcceleratorPlacementModeProperty

Identifies the KeyboardAcceleratorPlacementMode dependency property.

KeyboardAcceleratorPlacementTarget KeyboardAcceleratorPlacementTarget KeyboardAcceleratorPlacementTarget KeyboardAcceleratorPlacementTarget

Gets or sets a value that indicates the control tooltip that displays the accelerator key combination.

KeyboardAcceleratorPlacementTargetProperty KeyboardAcceleratorPlacementTargetProperty KeyboardAcceleratorPlacementTargetProperty KeyboardAcceleratorPlacementTargetProperty

Identifies the KeyboardAcceleratorPlacementTarget dependency property.

KeyboardAccelerators KeyboardAccelerators KeyboardAccelerators KeyboardAccelerators

Gets the the collection of key combinations that invoke an action using the keyboard.

Accelerators are typically assigned to buttons or menu items.

Example of a menu showing keyboard accelerators for various menu items

Example of a menu showing keyboard accelerators for various menu items

KeyDownEvent KeyDownEvent KeyDownEvent KeyDownEvent

Gets the identifier for the KeyDown routed event.

KeyTipHorizontalOffset KeyTipHorizontalOffset KeyTipHorizontalOffset KeyTipHorizontalOffset

Gets or sets a value that indicates how far left or right the Key Tip is placed in relation to the UIElement.

KeyTipHorizontalOffsetProperty KeyTipHorizontalOffsetProperty KeyTipHorizontalOffsetProperty KeyTipHorizontalOffsetProperty

Identifies the KeyTipHorizontalOffset dependency property.

KeyTipPlacementMode KeyTipPlacementMode KeyTipPlacementMode KeyTipPlacementMode

Gets or sets a value that indicates where the access key Key Tip is placed in relation to the boundary of the UIElement.

KeyTipPlacementModeProperty KeyTipPlacementModeProperty KeyTipPlacementModeProperty KeyTipPlacementModeProperty

Identifies the KeyTipPlacementMode dependency property.

KeyTipTarget KeyTipTarget KeyTipTarget KeyTipTarget

Gets or sets a value that indicates the element targeted by the access key Key Tip.

KeyTipTargetProperty KeyTipTargetProperty KeyTipTargetProperty KeyTipTargetProperty

Identifies the KeyTipTarget dependency property.

KeyTipVerticalOffset KeyTipVerticalOffset KeyTipVerticalOffset KeyTipVerticalOffset

Gets or sets a value that indicates how far up or down the Key Tip is placed in relation to the UI element.

KeyTipVerticalOffsetProperty KeyTipVerticalOffsetProperty KeyTipVerticalOffsetProperty KeyTipVerticalOffsetProperty

Identifies the KeyTipVerticalOffset dependency property.

KeyUpEvent KeyUpEvent KeyUpEvent KeyUpEvent

Gets the identifier for the KeyUp routed event.

Lights Lights Lights Lights

Gets the collection of XamlLight objects attached to this element.

LightsProperty LightsProperty LightsProperty LightsProperty

Identifies the Lights dependency property.

LosingFocusEvent LosingFocusEvent LosingFocusEvent LosingFocusEvent

Gets the identifier for the LosingFocus routed event.

ManipulationCompletedEvent ManipulationCompletedEvent ManipulationCompletedEvent ManipulationCompletedEvent

Gets the identifier for the ManipulationCompleted routed event.

ManipulationDeltaEvent ManipulationDeltaEvent ManipulationDeltaEvent ManipulationDeltaEvent

Gets the identifier for the ManipulationDelta routed event.

ManipulationInertiaStartingEvent ManipulationInertiaStartingEvent ManipulationInertiaStartingEvent ManipulationInertiaStartingEvent

Gets the identifier for the ManipulationInertiaStarting routed event.

ManipulationMode ManipulationMode ManipulationMode ManipulationMode

Gets or sets the ManipulationModes value used for UIElement behavior and interaction with gestures. Setting this value enables handling the manipulation events from this element in app code.

ManipulationModeProperty ManipulationModeProperty ManipulationModeProperty ManipulationModeProperty

Identifies the ManipulationMode dependency property.

ManipulationStartedEvent ManipulationStartedEvent ManipulationStartedEvent ManipulationStartedEvent

Gets the identifier for the ManipulationStarted routed event.

ManipulationStartingEvent ManipulationStartingEvent ManipulationStartingEvent ManipulationStartingEvent

Gets the identifier for the ManipulationStarting routed event.

NoFocusCandidateFoundEvent NoFocusCandidateFoundEvent NoFocusCandidateFoundEvent NoFocusCandidateFoundEvent

Gets the identifier for the NoFocusCandidateFound routed event.

Opacity Opacity Opacity Opacity

Gets or sets the degree of the object's opacity.

OpacityProperty OpacityProperty OpacityProperty OpacityProperty

Identifies the IsHitTestVisible dependency property.

PointerCanceledEvent PointerCanceledEvent PointerCanceledEvent PointerCanceledEvent

Gets the identifier for the PointerCanceled routed event.

PointerCaptureLostEvent PointerCaptureLostEvent PointerCaptureLostEvent PointerCaptureLostEvent

Gets the identifier for the PointerCaptureLost routed event.

PointerCaptures PointerCaptures PointerCaptures PointerCaptures

Gets the set of all captured pointers, represented as Pointer values.

PointerCapturesProperty PointerCapturesProperty PointerCapturesProperty PointerCapturesProperty

Identifies the PointerCaptures dependency property.

PointerEnteredEvent PointerEnteredEvent PointerEnteredEvent PointerEnteredEvent

Gets the identifier for the PointerEntered routed event.

PointerExitedEvent PointerExitedEvent PointerExitedEvent PointerExitedEvent

Gets the identifier for the PointerExited routed event.

PointerMovedEvent PointerMovedEvent PointerMovedEvent PointerMovedEvent

Gets the identifier for the PointerMoved routed event.

PointerPressedEvent PointerPressedEvent PointerPressedEvent PointerPressedEvent

Gets the identifier for the PointerPressed routed event.

PointerReleasedEvent PointerReleasedEvent PointerReleasedEvent PointerReleasedEvent

Gets the identifier for the PointerReleased routed event.

PointerWheelChangedEvent PointerWheelChangedEvent PointerWheelChangedEvent PointerWheelChangedEvent

Gets the identifier for the PointerWheelChanged routed event.

PreviewKeyDownEvent PreviewKeyDownEvent PreviewKeyDownEvent PreviewKeyDownEvent

Gets the identifier for the PreviewKeyDown routed event.

PreviewKeyUpEvent PreviewKeyUpEvent PreviewKeyUpEvent PreviewKeyUpEvent

Gets the identifier for the PreviewKeyUp routed event.

Projection Projection Projection Projection

Gets or sets the perspective projection (3-D effect) to apply when rendering this element.

ProjectionProperty ProjectionProperty ProjectionProperty ProjectionProperty

Identifies the Projection dependency property.

RenderSize RenderSize RenderSize RenderSize

Gets the final render size of a UIElement. Use is not recommended, see Remarks.

RenderTransform RenderTransform RenderTransform RenderTransform

Gets or sets transform information that affects the rendering position of a UIElement.

RenderTransformOrigin RenderTransformOrigin RenderTransformOrigin RenderTransformOrigin

Gets or sets the origin point of any possible render transform declared by RenderTransform, relative to the bounds of the UIElement.

RenderTransformOriginProperty RenderTransformOriginProperty RenderTransformOriginProperty RenderTransformOriginProperty

Identifies the RenderTransformOrigin dependency property.

RenderTransformProperty RenderTransformProperty RenderTransformProperty RenderTransformProperty

Identifies the RenderTransform dependency property.

RightTappedEvent RightTappedEvent RightTappedEvent RightTappedEvent

Gets the identifier for the RightTapped routed event.

TabFocusNavigation TabFocusNavigation TabFocusNavigation TabFocusNavigation

Gets or sets a value that modifies how tabbing and TabIndex work for this control.


For Windows 10 Creators Update (build 10.0.15063) and newer, use this property of the UIElement base class instead of the TabNavigation property of a Control object.

TabFocusNavigationProperty TabFocusNavigationProperty TabFocusNavigationProperty TabFocusNavigationProperty

Identifies the TabFocusNavigation dependency property.

TappedEvent TappedEvent TappedEvent TappedEvent

Gets the identifier for the Tapped routed event.

Transform3D Transform3D Transform3D Transform3D

Gets or sets the 3-D transform effect to apply when rendering this element.

Transform3DProperty Transform3DProperty Transform3DProperty Transform3DProperty

Identifies the Transform3D dependency property.

Transitions Transitions Transitions Transitions

Gets or sets the collection of Transition style elements that apply to a UIElement.

TransitionsProperty TransitionsProperty TransitionsProperty TransitionsProperty

Identifies the Transitions dependency property.

UseLayoutRounding UseLayoutRounding UseLayoutRounding UseLayoutRounding

Gets or sets a value that determines whether rendering for the object and its visual subtree should use rounding behavior that aligns rendering to whole pixels.

UseLayoutRoundingProperty UseLayoutRoundingProperty UseLayoutRoundingProperty UseLayoutRoundingProperty

Identifies the UseLayoutRounding dependency property.

Visibility Visibility Visibility Visibility

Gets or sets the visibility of a UIElement. A UIElement that is not visible is not rendered and does not communicate its desired size to layout.

VisibilityProperty VisibilityProperty VisibilityProperty VisibilityProperty

Identifies the Visibility dependency property.

XYFocusDownNavigationStrategy XYFocusDownNavigationStrategy XYFocusDownNavigationStrategy XYFocusDownNavigationStrategy

Gets or sets a value that specifies the strategy used to determine the target element of a down navigation.

XYFocusDownNavigationStrategyProperty XYFocusDownNavigationStrategyProperty XYFocusDownNavigationStrategyProperty XYFocusDownNavigationStrategyProperty

Identifies the XYFocusDownNavigationStrategy dependency property.

XYFocusKeyboardNavigation XYFocusKeyboardNavigation XYFocusKeyboardNavigation XYFocusKeyboardNavigation

Gets or sets a value that enables or disables navigation using the keyboard directional arrows.

XYFocusKeyboardNavigationProperty XYFocusKeyboardNavigationProperty XYFocusKeyboardNavigationProperty XYFocusKeyboardNavigationProperty

Identifies the XYFocusKeyboardNavigation dependency property.

XYFocusLeftNavigationStrategy XYFocusLeftNavigationStrategy XYFocusLeftNavigationStrategy XYFocusLeftNavigationStrategy

Gets or sets a value that specifies the strategy used to determine the target element of a left navigation.

XYFocusLeftNavigationStrategyProperty XYFocusLeftNavigationStrategyProperty XYFocusLeftNavigationStrategyProperty XYFocusLeftNavigationStrategyProperty

Identifies the XYFocusLeftNavigationStrategy dependency property.

XYFocusRightNavigationStrategy XYFocusRightNavigationStrategy XYFocusRightNavigationStrategy XYFocusRightNavigationStrategy

Gets or sets a value that specifies the strategy used to determine the target element of a right navigation.

XYFocusRightNavigationStrategyProperty XYFocusRightNavigationStrategyProperty XYFocusRightNavigationStrategyProperty XYFocusRightNavigationStrategyProperty

Identifies the XYFocusRightNavigationStrategy dependency property.

XYFocusUpNavigationStrategy XYFocusUpNavigationStrategy XYFocusUpNavigationStrategy XYFocusUpNavigationStrategy

Gets or sets a value that specifies the strategy used to determine the target element of an up navigation.

XYFocusUpNavigationStrategyProperty XYFocusUpNavigationStrategyProperty XYFocusUpNavigationStrategyProperty XYFocusUpNavigationStrategyProperty

Identifies the XYFocusUpNavigationStrategy dependency property.


AddHandler(RoutedEvent, Object, Boolean) AddHandler(RoutedEvent, Object, Boolean) AddHandler(RoutedEvent, Object, Boolean) AddHandler(RoutedEvent, Object, Boolean)

Adds a routed event handler for a specified routed event, adding the handler to the handler collection on the current element. Specify handledEventsToo as true to have the provided handler be invoked even if the event is handled elsewhere.

Arrange(Rect) Arrange(Rect) Arrange(Rect) Arrange(Rect)

Positions child objects and determines a size for a UIElement. Parent objects that implement custom layout for their child elements should call this method from their layout override implementations to form a recursive layout update.

CancelDirectManipulations() CancelDirectManipulations() CancelDirectManipulations() CancelDirectManipulations()

Cancels ongoing direct manipulation processing (system-defined panning/zooming) on any ScrollViewer parent that contains the current UIElement.

CapturePointer(Pointer) CapturePointer(Pointer) CapturePointer(Pointer) CapturePointer(Pointer)

Sets pointer capture to a UIElement. Once captured, only the element that has capture will fire pointer-related events.

ClearValue(DependencyProperty) ClearValue(DependencyProperty) ClearValue(DependencyProperty) ClearValue(DependencyProperty)

Clears the local value of a dependency property.

(Inherited from DependencyObject)
FindSubElementsForTouchTargeting(Point, Rect) FindSubElementsForTouchTargeting(Point, Rect) FindSubElementsForTouchTargeting(Point, Rect) FindSubElementsForTouchTargeting(Point, Rect)

Enables a UIElement subclass to expose child elements that assist with resolving touch targeting.

GetAnimationBaseValue(DependencyProperty) GetAnimationBaseValue(DependencyProperty) GetAnimationBaseValue(DependencyProperty) GetAnimationBaseValue(DependencyProperty)

Returns any base value established for a dependency property, which would apply in cases where an animation is not active.

(Inherited from DependencyObject)
GetChildrenInTabFocusOrder() GetChildrenInTabFocusOrder() GetChildrenInTabFocusOrder() GetChildrenInTabFocusOrder()

Enables a UIElement subclass to expose child elements that take part in Tab focus.

GetValue(DependencyProperty) GetValue(DependencyProperty) GetValue(DependencyProperty) GetValue(DependencyProperty)

Returns the current effective value of a dependency property from a DependencyObject.

(Inherited from DependencyObject)
InvalidateArrange() InvalidateArrange() InvalidateArrange() InvalidateArrange()

Invalidates the arrange state (layout) for a UIElement. After the invalidation, the UIElement will have its layout updated, which will occur asynchronously.

InvalidateMeasure() InvalidateMeasure() InvalidateMeasure() InvalidateMeasure()

Invalidates the measurement state (layout) for a UIElement.

Measure(Size) Measure(Size) Measure(Size) Measure(Size)

Updates the DesiredSize of a UIElement. Typically, objects that implement custom layout for their layout children call this method from their own MeasureOverride implementations to form a recursive layout update.

OnBringIntoViewRequested(BringIntoViewRequestedEventArgs) OnBringIntoViewRequested(BringIntoViewRequestedEventArgs) OnBringIntoViewRequested(BringIntoViewRequestedEventArgs) OnBringIntoViewRequested(BringIntoViewRequestedEventArgs)

Called before the BringIntoViewRequested event occurs.

OnCreateAutomationPeer() OnCreateAutomationPeer() OnCreateAutomationPeer() OnCreateAutomationPeer()

When implemented in a derived class, returns class-specific AutomationPeer implementations for the Microsoft UI Automation infrastructure.

OnDisconnectVisualChildren() OnDisconnectVisualChildren() OnDisconnectVisualChildren() OnDisconnectVisualChildren()

Override this method to implement how layout and logic should behave when items are removed from a class-specific content or children property.

OnKeyboardAcceleratorInvoked(KeyboardAcceleratorInvokedEventArgs) OnKeyboardAcceleratorInvoked(KeyboardAcceleratorInvokedEventArgs) OnKeyboardAcceleratorInvoked(KeyboardAcceleratorInvokedEventArgs) OnKeyboardAcceleratorInvoked(KeyboardAcceleratorInvokedEventArgs)

Called when a keyboard shortcut (or accelerator) is processed in your app. Override this method to handle how your app responds when a keyboard accelerator is invoked.

OnProcessKeyboardAccelerators(ProcessKeyboardAcceleratorEventArgs) OnProcessKeyboardAccelerators(ProcessKeyboardAcceleratorEventArgs) OnProcessKeyboardAccelerators(ProcessKeyboardAcceleratorEventArgs) OnProcessKeyboardAccelerators(ProcessKeyboardAcceleratorEventArgs)

Called just before a keyboard shortcut (or accelerator) is processed in your app. Invoked whenever application code or internal processes call ProcessKeyboardAccelerators. Override this method to influence the default accelerator handling.

ReadLocalValue(DependencyProperty) ReadLocalValue(DependencyProperty) ReadLocalValue(DependencyProperty) ReadLocalValue(DependencyProperty)

Returns the local value of a dependency property, if a local value is set.

(Inherited from DependencyObject)
RegisterAsScrollPort(UIElement) RegisterAsScrollPort(UIElement) RegisterAsScrollPort(UIElement) RegisterAsScrollPort(UIElement)

Registers an element as representing a scrollable viewport.

RegisterPropertyChangedCallback(DependencyProperty,DependencyPropertyChangedCallback) RegisterPropertyChangedCallback(DependencyProperty,DependencyPropertyChangedCallback) RegisterPropertyChangedCallback(DependencyProperty,DependencyPropertyChangedCallback) RegisterPropertyChangedCallback(DependencyProperty,DependencyPropertyChangedCallback)

Registers a notification function for listening to changes to a specific DependencyProperty on this DependencyObject instance.

(Inherited from DependencyObject)
ReleasePointerCapture(Pointer) ReleasePointerCapture(Pointer) ReleasePointerCapture(Pointer) ReleasePointerCapture(Pointer)

Releases pointer captures for capture of one specific pointer by this UIElement.

ReleasePointerCaptures() ReleasePointerCaptures() ReleasePointerCaptures() ReleasePointerCaptures()

Releases all pointer captures held by this element.

RemoveHandler(RoutedEvent, Object) RemoveHandler(RoutedEvent, Object) RemoveHandler(RoutedEvent, Object) RemoveHandler(RoutedEvent, Object)

Removes the specified routed event handler from this UIElement. Typically the handler in question was added by AddHandler.

SetValue(DependencyProperty,Object) SetValue(DependencyProperty,Object) SetValue(DependencyProperty,Object) SetValue(DependencyProperty,Object)

Sets the local value of a dependency property on a DependencyObject.

(Inherited from DependencyObject)
StartBringIntoView() StartBringIntoView() StartBringIntoView() StartBringIntoView()

Initiates a request to the XAML framework to bring the element into view within any scrollable regions it is contained within.

StartBringIntoView(BringIntoViewOptions) StartBringIntoView(BringIntoViewOptions) StartBringIntoView(BringIntoViewOptions) StartBringIntoView(BringIntoViewOptions)

Initiates a request to the XAML framework to bring the element into view using the specified options.

StartDragAsync(PointerPoint) StartDragAsync(PointerPoint) StartDragAsync(PointerPoint) StartDragAsync(PointerPoint)

Initiates a drag-and-drop operation.

TransformToVisual(UIElement) TransformToVisual(UIElement) TransformToVisual(UIElement) TransformToVisual(UIElement)

Returns a transform object that can be used to transform coordinates from the UIElement to the specified object.

TryInvokeKeyboardAccelerator(ProcessKeyboardAcceleratorEventArgs) TryInvokeKeyboardAccelerator(ProcessKeyboardAcceleratorEventArgs) TryInvokeKeyboardAccelerator(ProcessKeyboardAcceleratorEventArgs) TryInvokeKeyboardAccelerator(ProcessKeyboardAcceleratorEventArgs)

Attempts to invoke a keyboard shortcut (or accelerator) by searching the entire visual tree of the UIElement for the shortcut.

TryStartDirectManipulation(Pointer) TryStartDirectManipulation(Pointer) TryStartDirectManipulation(Pointer) TryStartDirectManipulation(Pointer)

Resumes direct manipulation processing (system-defined panning/zooming) on any ScrollViewer parent that contains the current UIElement.

UnregisterPropertyChangedCallback(DependencyProperty,Int64) UnregisterPropertyChangedCallback(DependencyProperty,Int64) UnregisterPropertyChangedCallback(DependencyProperty,Int64) UnregisterPropertyChangedCallback(DependencyProperty,Int64)

Cancels a change notification that was previously registered by calling RegisterPropertyChangedCallback.

(Inherited from DependencyObject)
UpdateLayout() UpdateLayout() UpdateLayout() UpdateLayout()

Ensures that all positions of child objects of a UIElement are properly updated for layout.


AccessKeyDisplayDismissed AccessKeyDisplayDismissed AccessKeyDisplayDismissed AccessKeyDisplayDismissed

Occurs when the access key sequence is complete to notify controls that they should hide access key visuals.

AccessKeyDisplayRequested AccessKeyDisplayRequested AccessKeyDisplayRequested AccessKeyDisplayRequested

Occurs when the access key sequence is started to notify controls that they should show access key visuals.

AccessKeyInvoked AccessKeyInvoked AccessKeyInvoked AccessKeyInvoked

Occurs when a user completes an access key sequence to notify the element that the access key action should be invoked.

BringIntoViewRequested BringIntoViewRequested BringIntoViewRequested BringIntoViewRequested

Occurs when StartBringIntoView is called on this element or one of its descendants.

CharacterReceived CharacterReceived CharacterReceived CharacterReceived

Occurs when a single, composed character is received by the input queue.

ContextCanceled ContextCanceled ContextCanceled ContextCanceled

Occurs when a context input gesture continues into a manipulation gesture, to notify the element that the context flyout should not be opened.

ContextRequested ContextRequested ContextRequested ContextRequested

Occurs when the user has completed a context input gesture, such as a right-click.

DoubleTapped DoubleTapped DoubleTapped DoubleTapped

Occurs when an otherwise unhandled DoubleTap interaction occurs over the hit test area of this element.

DragEnter DragEnter DragEnter DragEnter

Occurs when the input system reports an underlying drag event with this element as the target.

DragLeave DragLeave DragLeave DragLeave

Occurs when the input system reports an underlying drag event with this element as the origin.

DragOver DragOver DragOver DragOver

Occurs when the input system reports an underlying drag event with this element as the potential drop target.

DragStarting DragStarting DragStarting DragStarting

Occurs when a drag operation is initiated.

Drop Drop Drop Drop

Occurs when the input system reports an underlying drop event with this element as the drop target.

DropCompleted DropCompleted DropCompleted DropCompleted

Occurs when a drag-and-drop operation is ended.

GettingFocus GettingFocus GettingFocus GettingFocus

Occurs before a UIElement receives focus.

GotFocus GotFocus GotFocus GotFocus

Occurs when a UIElement receives focus.

Holding Holding Holding Holding

Occurs when an otherwise unhandled Hold interaction occurs over the hit test area of this element.

KeyDown KeyDown KeyDown KeyDown

Occurs when a keyboard key is pressed while the UIElement has focus.

KeyUp KeyUp KeyUp KeyUp

Occurs when a keyboard key is released while the UIElement has focus.

LosingFocus LosingFocus LosingFocus LosingFocus

Occurs before a UIElement loses focus.

LostFocus LostFocus LostFocus LostFocus

Occurs when a UIElement loses focus.

ManipulationCompleted ManipulationCompleted ManipulationCompleted ManipulationCompleted

Occurs when a manipulation on the UIElement is complete.

ManipulationDelta ManipulationDelta ManipulationDelta ManipulationDelta

Occurs when the input device changes position during a manipulation.

ManipulationInertiaStarting ManipulationInertiaStarting ManipulationInertiaStarting ManipulationInertiaStarting

Occurs when the input device loses contact with the UIElement object during a manipulation and inertia begins.

ManipulationStarted ManipulationStarted ManipulationStarted ManipulationStarted

Occurs when an input device begins a manipulation on the UIElement.

ManipulationStarting ManipulationStarting ManipulationStarting ManipulationStarting

Occurs when the manipulation processor is first created.

NoFocusCandidateFound NoFocusCandidateFound NoFocusCandidateFound NoFocusCandidateFound

Occurs when a user attempts to move focus (via tab or directional arrows), but focus doesn't move because no focus candidate is found in the direction of movement.

PointerCanceled PointerCanceled PointerCanceled PointerCanceled

Occurs when a pointer that made contact abnormally loses contact.

PointerCaptureLost PointerCaptureLost PointerCaptureLost PointerCaptureLost

Occurs when pointer capture previously held by this element moves to another element or elsewhere.

PointerEntered PointerEntered PointerEntered PointerEntered

Occurs when a pointer enters the hit test area of this element.

PointerExited PointerExited PointerExited PointerExited

Occurs when a pointer leaves the hit test area of this element.

PointerMoved PointerMoved PointerMoved PointerMoved

Occurs when a pointer moves while the pointer remains within the hit test area of this element.

PointerPressed PointerPressed PointerPressed PointerPressed

Occurs when the pointer device initiates a Press action within this element.

PointerReleased PointerReleased PointerReleased PointerReleased

Occurs when the pointer device that previously initiated a Press action is released, while within this element. Note that the end of a Press action is not guaranteed to fire a PointerReleased event; other events may fire instead. For more info, see Remarks.

PointerWheelChanged PointerWheelChanged PointerWheelChanged PointerWheelChanged

Occurs when the delta value of a pointer wheel changes.

PreviewKeyDown PreviewKeyDown PreviewKeyDown PreviewKeyDown

Occurs when a keyboard key is pressed while the UIElement has focus.

PreviewKeyUp PreviewKeyUp PreviewKeyUp PreviewKeyUp

Occurs when a keyboard key is released while the UIElement has focus.

ProcessKeyboardAccelerators ProcessKeyboardAccelerators ProcessKeyboardAccelerators ProcessKeyboardAccelerators

Occurs when a keyboard shortcut (or accelerator) is pressed.

RightTapped RightTapped RightTapped RightTapped

Occurs when a right-tap input stimulus happens while the pointer is over the element.

Tapped Tapped Tapped Tapped

Occurs when an otherwise unhandled Tap interaction occurs over the hit test area of this element.

See Also