ContentElement Class
Provides a WPF core-level base class for content elements. Content elements are designed for flow-style presentation, using an intuitive markup-oriented layout model and a deliberately simple object model.
System.Windows.Threading::DispatcherObject
System.Windows::DependencyObject
System.Windows::ContentElement
System.Windows::FrameworkContentElement
Assembly: PresentationCore (in PresentationCore.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation
The ContentElement type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | AllowDrop | Gets or sets a value that indicates whether this element can be used as the target of a drag-and-drop operation. |
![]() | AreAnyTouchesCaptured | Gets a value that indicates whether at least one touch is captured to this element. |
![]() | AreAnyTouchesCapturedWithin | Gets a value that indicates whether at least one touch is captured to this element or to any child elements in its visual tree. |
![]() | AreAnyTouchesDirectlyOver | Gets a value that indicates whether at least one touch is pressed over this element. |
![]() | AreAnyTouchesOver | Gets a value that indicates whether at least one touch is pressed over this element or any child elements in its visual tree. |
![]() | CommandBindings | Gets a collection of CommandBinding objects that are associated with this element. |
![]() | DependencyObjectType | Gets the DependencyObjectType that wraps the CLR type of this instance. (Inherited from DependencyObject.) |
![]() | Dispatcher | Gets the Dispatcher this DispatcherObject is associated with. (Inherited from DispatcherObject.) |
![]() | Focusable | Gets or sets a value that indicates whether the element can receive focus. |
![]() | HasAnimatedProperties | Gets a value that indicates whether this element has any animated properties. |
![]() | InputBindings | Gets the collection of input bindings that are associated with this element. |
![]() | IsEnabled | Gets or sets a value that indicates whether this element is enabled in the user interface (UI). |
![]() | IsEnabledCore | Gets a value that becomes the return value of IsEnabled in derived classes. |
![]() | IsFocused | Gets a value that determines whether this element has logical focus. |
![]() | IsInputMethodEnabled | Gets a value that indicates whether an input method system, such as an Input Method Editor (IME), is enabled for processing the input to this element. |
![]() | IsKeyboardFocused | Gets a value that indicates whether this element has keyboard focus. |
![]() | IsKeyboardFocusWithin | Gets a value that indicates whether keyboard focus is anywhere within the element or child elements. |
![]() | IsMouseCaptured | Gets a value that indicates whether the mouse is captured by this element. |
![]() | IsMouseCaptureWithin | Gets a value that determines whether mouse capture is held by this element or by child elements in its element tree. |
![]() | IsMouseDirectlyOver | Gets a value that indicates whether the position of the mouse pointer corresponds to hit test results, which take element compositing into account. |
![]() | IsMouseOver | Gets a value that indicates whether the mouse pointer is located over this element (including visual child elements, or its control compositing). |
![]() | IsSealed | Gets a value that indicates whether this instance is currently sealed (read-only). (Inherited from DependencyObject.) |
![]() | IsStylusCaptured | Gets a value that indicates whether the stylus is captured to this element. |
![]() | IsStylusCaptureWithin | Gets a value that determines whether stylus capture is held by this element, including child elements and control compositing. |
![]() | IsStylusDirectlyOver | Gets a value that indicates whether the stylus position corresponds to hit test results, which take element compositing into account. |
![]() | IsStylusOver | Gets a value that indicates whether the stylus is located over this element (including visual child elements). |
![]() | TouchesCaptured | Gets all touch devices that are captured to this element. |
![]() | TouchesCapturedWithin | Gets all touch devices that are captured to this element or any child elements in its visual tree. |
![]() | TouchesDirectlyOver | Gets all touch devices that are over this element. |
![]() | TouchesOver | Gets all touch devices that are over this element or any child elements in its visual tree. |
| Name | Description | |
|---|---|---|
![]() | AddHandler(RoutedEvent, Delegate) | Adds a routed event handler for a specified routed event, adding the handler to the handler collection on the current element. |
![]() | AddHandler(RoutedEvent, Delegate, 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 for routed event that had already been marked as handled by another element along the event route. |
![]() | AddToEventRoute | Adds handlers to the specified EventRoute for the current ContentElement event handler collection. |
![]() | ApplyAnimationClock(DependencyProperty, AnimationClock) | Applies an animation to a specified dependency property on this element. Any existing animations are stopped and replaced with the new animation. |
![]() | ApplyAnimationClock(DependencyProperty, AnimationClock, HandoffBehavior) | Applies an animation to a specified dependency property on this element, with the ability to specify what happens if the property already has a running animation. |
![]() | BeginAnimation(DependencyProperty, AnimationTimeline) | Starts an animation for a specified animated property on this element. |
![]() | BeginAnimation(DependencyProperty, AnimationTimeline, HandoffBehavior) | Starts a specific animation for a specified animated property on this element, with the option of specifying what happens if the property already has a running animation. |
![]() | CaptureMouse | Attempts to force capture of the mouse to this element. |
![]() | CaptureStylus | Attempts to force capture of the stylus to this element. |
![]() | CaptureTouch | Attempts to force capture of a touch to this element. |
![]() | CheckAccess | Determines whether the calling thread has access to this DispatcherObject. (Inherited from DispatcherObject.) |
![]() | ClearValue(DependencyProperty) | Clears the local value of a property. The property to be cleared is specified by a DependencyProperty identifier. (Inherited from DependencyObject.) |
![]() | ClearValue(DependencyPropertyKey) | Clears the local value of a read-only property. The property to be cleared is specified by a DependencyPropertyKey. (Inherited from DependencyObject.) |
![]() | CoerceValue | Coerces the value of the specified dependency property. This is accomplished by invoking any CoerceValueCallback function specified in property metadata for the dependency property as it exists on the calling DependencyObject. (Inherited from DependencyObject.) |
![]() | Equals | Determines whether a provided DependencyObject is equivalent to the current DependencyObject. (Inherited from DependencyObject.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
![]() | Focus | Attempts to set focus to this element. |
![]() | GetAnimationBaseValue | Returns the base property value for the specified property on this element, disregarding any possible animated value from a running or stopped animation. |
![]() | GetHashCode | Gets a hash code for this DependencyObject. (Inherited from DependencyObject.) |
![]() | GetLocalValueEnumerator | Creates a specialized enumerator for determining which dependency properties have locally set values on this DependencyObject. (Inherited from DependencyObject.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | GetUIParentCore | When overridden in a derived class, returns an alternative user interface (UI) parent for this element if no visual parent exists. |
![]() | GetValue | Returns the current effective value of a dependency property on this instance of a DependencyObject. (Inherited from DependencyObject.) |
![]() | InvalidateProperty | Re-evaluates the effective value for the specified dependency property (Inherited from DependencyObject.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | MoveFocus | Attempts to move focus from this element to another element. The direction to move focus is specified by a guidance direction, which is interpreted within the organization of the visual parent for this element. |
![]() | OnCreateAutomationPeer | Returns class-specific AutomationPeer implementations for the Windows Presentation Foundation (WPF) infrastructure. |
![]() | OnDragEnter | Invoked when an unhandled DragDrop::DragEnter attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnDragLeave | Invoked when an unhandled DragDrop::DragLeave attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnDragOver | Invoked when an unhandled DragDrop::DragOver attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnDrop | Invoked when an unhandled DragDrop::DragEnter attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnGiveFeedback | Invoked when an unhandled DragDrop::GiveFeedback attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnGotFocus | Raises the GotFocus routed event by using the event data provided. |
![]() | OnGotKeyboardFocus | Invoked when an unhandled Keyboard::GotKeyboardFocus attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnGotMouseCapture | Invoked when an unhandled Mouse::GotMouseCapture attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnGotStylusCapture | Invoked when an unhandled Stylus::GotStylusCapture attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnGotTouchCapture | Provides class handling for the GotTouchCapture routed event that occurs when a touch is captured to this element. |
![]() | OnIsKeyboardFocusedChanged | Invoked when an unhandled IsKeyboardFocusedChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnIsKeyboardFocusWithinChanged | Invoked just before the IsKeyboardFocusWithinChanged event is raised by this element. Implement this method to add class handling for this event. |
![]() | OnIsMouseCapturedChanged | Invoked when an unhandled IsMouseCapturedChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnIsMouseCaptureWithinChanged | Invoked when an unhandled IsMouseCaptureWithinChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnIsMouseDirectlyOverChanged | Invoked when an unhandled IsMouseDirectlyOverChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnIsStylusCapturedChanged | Invoked when an unhandled IsStylusCapturedChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnIsStylusCaptureWithinChanged | Invoked when an unhandled IsStylusCaptureWithinChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnIsStylusDirectlyOverChanged | Invoked when an unhandled IsStylusDirectlyOverChanged event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnKeyDown | Invoked when an unhandled Keyboard::KeyDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnKeyUp | Invoked when an unhandled Keyboard::KeyUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnLostFocus | Raises the LostFocus routed event by using the event data that is provided. |
![]() | OnLostKeyboardFocus | Invoked when an unhandled Keyboard::LostKeyboardFocus attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnLostMouseCapture | Invoked when an unhandled Mouse::LostMouseCapture attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnLostStylusCapture | Invoked when an unhandled Stylus::LostStylusCapture attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnLostTouchCapture | Provides class handling for the LostTouchCapture routed event that occurs when this element loses a touch capture. |
![]() | OnMouseDown | Invoked when an unhandled Mouse::MouseDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnMouseEnter | Invoked when an unhandled Mouse::MouseEnter attached event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnMouseLeave | Invoked when an unhandled Mouse::MouseLeave attached event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnMouseLeftButtonDown | Invoked when an unhandled MouseLeftButtonDown routed event is raised on this element. Implement this method to add class handling for this event. |
![]() | OnMouseLeftButtonUp | Invoked when an unhandled MouseLeftButtonUp routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnMouseMove | Invoked when an unhandled Mouse::MouseMove attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnMouseRightButtonDown | Invoked when an unhandled MouseRightButtonDown routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnMouseRightButtonUp | Invoked when an unhandled MouseRightButtonUp routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnMouseUp | Invoked when an unhandled Mouse::MouseUp routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnMouseWheel | Invoked when an unhandled Mouse::MouseWheel attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewDragEnter | Invoked when an unhandled DragDrop::PreviewDragEnter attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewDragLeave | Invoked when an unhandled DragDrop::PreviewDragLeave attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewDragOver | Invoked when an unhandled DragDrop::PreviewDragOver attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewDrop | Invoked when an unhandled DragDrop::PreviewDrop attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewGiveFeedback | Invoked when an unhandled DragDrop::PreviewGiveFeedback attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewGotKeyboardFocus | Invoked when an unhandled Keyboard::PreviewGotKeyboardFocus attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewKeyDown | Invoked when an unhandled Keyboard::PreviewKeyDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewKeyUp | Invoked when an unhandled Keyboard::PreviewKeyUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewLostKeyboardFocus | Invoked when an unhandled Keyboard::PreviewKeyDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseDown | Invoked when an unhandled Mouse::PreviewMouseDown attached routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseLeftButtonDown | Invoked when an unhandled PreviewMouseLeftButtonDown routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseLeftButtonUp | Invoked when an unhandled PreviewMouseLeftButtonUp routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseMove | Invoked when an unhandled Mouse::PreviewMouseMove attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseRightButtonDown | Invoked when an unhandled PreviewMouseRightButtonDown routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseRightButtonUp | Invoked when an unhandled PreviewMouseRightButtonUp routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseUp | Invoked when an unhandled Mouse::PreviewMouseUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewMouseWheel | Invoked when an unhandled Mouse::PreviewMouseWheel attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewQueryContinueDrag | Invoked when an unhandled DragDrop::PreviewQueryContinueDrag attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusButtonDown | Invoked when an unhandled Stylus::PreviewStylusButtonDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusButtonUp | Invoked when an unhandled Stylus::PreviewStylusButtonUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusDown | Invoked when an unhandled Stylus::PreviewStylusDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusInAirMove | Invoked when an unhandled Stylus::PreviewStylusInAirMove attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusInRange | Invoked when an unhandled Stylus::PreviewStylusInRange attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusMove | Invoked when an unhandled Stylus::PreviewStylusMove attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusOutOfRange | Invoked when an unhandled Stylus::PreviewStylusOutOfRange attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusSystemGesture | Invoked when an unhandled Stylus::PreviewStylusSystemGesture attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewStylusUp | Invoked when an unhandled Stylus::PreviewStylusUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewTextInput | Invoked when an unhandled TextCompositionManager::PreviewTextInput attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnPreviewTouchDown | Provides class handling for the PreviewTouchDown routed event that occurs when a touch presses this element. |
![]() | OnPreviewTouchMove | Provides class handling for the PreviewTouchMove routed event that occurs when a touch moves while inside this element. |
![]() | OnPreviewTouchUp | Provides class handling for the PreviewTouchUp routed event that occurs when a touch is released inside this element. |
![]() | OnPropertyChanged | Invoked whenever the effective value of any dependency property on this DependencyObject has been updated. The specific dependency property that changed is reported in the event data. (Inherited from DependencyObject.) |
![]() | OnQueryContinueDrag | Invoked when an unhandled DragDrop::QueryContinueDrag attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnQueryCursor | Invoked when an unhandled Mouse::QueryCursor attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusButtonDown | Invoked when an unhandled Stylus::StylusButtonDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusButtonUp | Invoked when an unhandled Stylus::StylusButtonUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusDown | Invoked when an unhandled Stylus::StylusDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusEnter | Invoked when an unhandled Stylus::StylusEnter attached event is raised by this element. Implement this method to add class handling for this event. |
![]() | OnStylusInAirMove | Invoked when an unhandled Stylus::StylusInAirMove attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusInRange | Invoked when an unhandled Stylus::StylusInRange attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusLeave | Invoked when an unhandled Stylus::StylusLeave attached event is raised by this element. Implement this method to add class handling for this event. |
![]() | OnStylusMove | Invoked when an unhandled Stylus::StylusMove attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusOutOfRange | Invoked when an unhandled Stylus::StylusOutOfRange attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusSystemGesture | Invoked when an unhandled Stylus::StylusSystemGesture attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnStylusUp | Invoked when an unhandled Stylus::StylusUp attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnTextInput | Invoked when an unhandled TextCompositionManager::TextInput attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event. |
![]() | OnTouchDown | Provides class handling for the TouchDown routed event that occurs when a touch presses inside this element. |
![]() | OnTouchEnter | Provides class handling for the TouchEnter routed event that occurs when a touch moves from outside to inside the bounds of this element. |
![]() | OnTouchLeave | Provides class handling for the TouchLeave routed event that occurs when a touch moves from inside to outside the bounds of this element. |
![]() | OnTouchMove | Provides class handling for the TouchMove routed event that occurs when a touch moves while inside this element. |
![]() | OnTouchUp | Provides class handling for the TouchUp routed event that occurs when a touch is released inside this element. |
![]() | PredictFocus | When overridden in a derived class, returns the element that would receive focus for a specified focus traversal direction, without actually moving focus to that element. |
![]() | RaiseEvent | Raises a specific routed event. The RoutedEvent to be raised is identified within the RoutedEventArgs instance that is provided (as the RoutedEvent property of that event data). |
![]() | ReadLocalValue | Returns the local value of a dependency property, if it exists. (Inherited from DependencyObject.) |
![]() | ReleaseAllTouchCaptures | Releases all captured touch devices from this element. |
![]() | ReleaseMouseCapture | Releases the mouse capture, if this element held the capture. |
![]() | ReleaseStylusCapture | Releases the stylus device capture, if this element held the capture. |
![]() | ReleaseTouchCapture | Attempts to release the specified touch device from this element. |
![]() | RemoveHandler | Removes the specified routed event handler from this element. |
![]() | SetCurrentValue | Sets the value of a dependency property without changing its value source. (Inherited from DependencyObject.) |
![]() | SetValue(DependencyProperty, Object) | Sets the local value of a dependency property, specified by its dependency property identifier. (Inherited from DependencyObject.) |
![]() | SetValue(DependencyPropertyKey, Object) | Sets the local value of a read-only dependency property, specified by the DependencyPropertyKey identifier of the dependency property. (Inherited from DependencyObject.) |
![]() | ShouldSerializeCommandBindings | Returns whether serialization processes should serialize the contents of the CommandBindings property on instances of this class. |
![]() | ShouldSerializeInputBindings | Returns whether serialization processes should serialize the contents of the InputBindings property on instances of this class. |
![]() | ShouldSerializeProperty | Returns a value that indicates whether serialization processes should serialize the value for the provided dependency property. (Inherited from DependencyObject.) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
![]() | VerifyAccess | Enforces that the calling thread has access to this DispatcherObject. (Inherited from DispatcherObject.) |
| Name | Description | |
|---|---|---|
![]() | DragEnter | Occurs when the input system reports an underlying drag event with this element as the drag target. |
![]() | DragLeave | Occurs when the input system reports an underlying drag event with this element as the drag origin. |
![]() | DragOver | Occurs when the input system reports an underlying drag event with this element as the potential drop target. |
![]() | Drop | Occurs when the input system reports an underlying drop event with this element as the drop target. |
![]() | FocusableChanged | Occurs when the value of the Focusable property changes. |
![]() | GiveFeedback | Occurs when the input system reports an underlying drag-and-drop event that involves this element. |
![]() | GotFocus | Occurs when this element gets logical focus. |
![]() | GotKeyboardFocus | Occurs when the keyboard is focused on this element. |
![]() | GotMouseCapture | Occurs when this element captures the mouse. |
![]() | GotStylusCapture | Occurs when this element captures the stylus. |
![]() | GotTouchCapture | Occurs when a touch is captured to this element. |
![]() | IsEnabledChanged | Occurs when the value of the IsEnabled property on this element changes. |
![]() | IsKeyboardFocusedChanged | Occurs when the value of the IsKeyboardFocused property changes on this element. |
![]() | IsKeyboardFocusWithinChanged | Occurs when the value of the IsKeyboardFocusWithinChanged property changes on this element. |
![]() | IsMouseCapturedChanged | Occurs when the value of the IsMouseCaptured property changes on this element. |
![]() | IsMouseCaptureWithinChanged | Occurs when the value of the IsMouseCaptureWithinProperty changes on this element. |
![]() | IsMouseDirectlyOverChanged | Occurs when the value of the IsMouseDirectlyOver property changes on this element. |
![]() | IsStylusCapturedChanged | Occurs when the value of the IsStylusCaptured property changes on this element. |
![]() | IsStylusCaptureWithinChanged | Occurs when the value of the IsStylusCaptureWithin property changes on this element. |
![]() | IsStylusDirectlyOverChanged | Occurs when the value of the IsStylusDirectlyOver property changes on this element. |
![]() | KeyDown | Occurs when a key is pressed while focus is on this element. |
![]() | KeyUp | Occurs when a key is released while focus is on this element. |
![]() | LostFocus | Occurs when this element loses logical focus. |
![]() | LostKeyboardFocus | Occurs when the keyboard is no longer focused on this element. |
![]() | LostMouseCapture | Occurs when this element loses mouse capture. |
![]() | LostStylusCapture | Occurs when this element loses stylus capture. |
![]() | LostTouchCapture | Occurs when this element loses a touch capture. |
![]() | MouseDown | Occurs when any mouse button is pressed while the pointer is over this element. |
![]() | MouseEnter | Occurs when the mouse pointer enters the bounds of this element. |
![]() | MouseLeave | Occurs when the mouse pointer leaves the bounds of this element. |
![]() | MouseLeftButtonDown | Occurs when the left mouse button is pressed while the mouse pointer is over this element. |
![]() | MouseLeftButtonUp | Occurs when the left mouse button is released while the mouse pointer is over this element. |
![]() | MouseMove | Occurs when the mouse pointer moves while over this element. |
![]() | MouseRightButtonDown | Occurs when the right mouse button is pressed while the mouse pointer is over this element. |
![]() | MouseRightButtonUp | Occurs when the right mouse button is released while the mouse pointer is over this element. |
![]() | MouseUp | Occurs when any mouse button is released over this element. |
![]() | MouseWheel | Occurs when the user rotates the mouse wheel while the mouse pointer is over this element. |
![]() | PreviewDragEnter | Occurs when the input system reports an underlying drag event with this element as the drag target. |
![]() | PreviewDragLeave | Occurs when the input system reports an underlying drag event with this element as the drag origin. |
![]() | PreviewDragOver | Occurs when the input system reports an underlying drag event with this element as the potential drop target. |
![]() | PreviewDrop | Occurs when the input system reports an underlying drop event with this element as the drop target. |
![]() | PreviewGiveFeedback | Occurs when a drag-and-drop operation is started. |
![]() | PreviewGotKeyboardFocus | Occurs when the keyboard is focused on this element. |
![]() | PreviewKeyDown | Occurs when a key is pressed while the keyboard is focused on this element. |
![]() | PreviewKeyUp | Occurs when a key is released while the keyboard is focused on this element. |
![]() | PreviewLostKeyboardFocus | Occurs when the keyboard is no longer focused on this element. |
![]() | PreviewMouseDown | Occurs when any mouse button is pressed while the pointer is over this element. |
![]() | PreviewMouseLeftButtonDown | Occurs when the left mouse button is pressed while the mouse pointer is over this element. |
![]() | PreviewMouseLeftButtonUp | Occurs when the left mouse button is released while the mouse pointer is over this element. |
![]() | PreviewMouseMove | Occurs when the mouse pointer moves while the mouse pointer is over this element. |
![]() | PreviewMouseRightButtonDown | Occurs when the right mouse button is pressed while the mouse pointer is over this element. |
![]() | PreviewMouseRightButtonUp | Occurs when the right mouse button is released while the mouse pointer is over this element. |
![]() | PreviewMouseUp | Occurs when any mouse button is released while the mouse pointer is over this element. |
![]() | PreviewMouseWheel | Occurs when the user rotates the mouse wheel while the mouse pointer is over this element. |
![]() | PreviewQueryContinueDrag | Occurs when there is a change in the keyboard or mouse button state during a drag-and-drop operation. |
![]() | PreviewStylusButtonDown | Occurs when the stylus button is pressed while the pointer is over this element. |
![]() | PreviewStylusButtonUp | Occurs when the stylus button is released while the pointer is over this element. |
![]() | PreviewStylusDown | Occurs when the stylus touches the digitizer while it is over this element. |
![]() | PreviewStylusInAirMove | Occurs when the stylus moves over an element without actually touching the digitizer. |
![]() | PreviewStylusInRange | Occurs when the stylus is close enough to the digitizer to be detected, while over this element. |
![]() | PreviewStylusMove | Occurs when the stylus moves while over the element. The stylus must move while being detected by the digitizer to raise this event, otherwise, PreviewStylusInAirMove is raised instead. |
![]() | PreviewStylusOutOfRange | Occurs when the stylus is too far from the digitizer to be detected. |
![]() | PreviewStylusSystemGesture | Occurs when a user performs one of several stylus gestures. |
![]() | PreviewStylusUp | Occurs when the user raises the stylus off the digitizer while the stylus is over this element. |
![]() | PreviewTextInput | Occurs when this element gets text in a device-independent manner. |
![]() | PreviewTouchDown | Occurs when a finger touches the screen while the finger is over this element. |
![]() | PreviewTouchMove | Occurs when a finger moves on the screen while the finger is over this element. |
![]() | PreviewTouchUp | Occurs when a finger is raised off of the screen while the finger is over this element. |
![]() | QueryContinueDrag | Occurs when there is a change in the keyboard or mouse button state during a drag-and-drop operation. |
![]() | QueryCursor | Occurs when the cursor is requested to display. This event is raised on an element each time that the mouse pointer moves to a new location, which means the cursor object might need to be changed based on its new position. |
![]() | StylusButtonDown | Occurs when the stylus button is pressed while the pointer is over this element. |
![]() | StylusButtonUp | Occurs when the stylus button is released while the pointer is over this element. |
![]() | StylusDown | Occurs when the stylus touches the digitizer while the stylus is over this element. |
![]() | StylusEnter | Occurs when the stylus enters the bounds of this element. |
![]() | StylusInAirMove | Occurs when the stylus moves over an element without actually touching the digitizer. |
![]() | StylusInRange | Occurs when the stylus is close enough to the digitizer to be detected, while over this element. |
![]() | StylusLeave | Occurs when the stylus leaves the bounds of the element. |
![]() | StylusMove | Occurs when the stylus moves over this element. The stylus must move while on the digitizer to raise this event. Otherwise, StylusInAirMove is raised instead. |
![]() | StylusOutOfRange | Occurs when the stylus is too far from the digitizer to be detected, while over this element. |
![]() | StylusSystemGesture | Occurs when a user performs one of several stylus gestures. |
![]() | StylusUp | Occurs when the user raises the stylus off the digitizer while it is over this element. |
![]() | TextInput | Occurs when this element gets text in a device-independent manner. |
![]() | TouchDown | Occurs when a finger touches the screen while the finger is over this element. |
![]() | TouchEnter | Occurs when a touch moves from outside to inside the bounds of this element. |
![]() | TouchLeave | Occurs when a touch moves from inside to outside the bounds of this element. |
![]() | TouchMove | Occurs when a finger moves on the screen while the finger is over this element. |
![]() | TouchUp | Occurs when a finger is raised off of the screen while the finger is over this element. |
ContentElement defines the following common content characteristics:
Input: All ContentElement derived classes provide support for basic input capture from keyboard, mouse, drag-and-drop operations, stylus controls, and accelerators.
Focus: All ContentElement derived classes are potentially focusable. (However, the default focusable state for the ContentElement base class is false. For details on how to make a ContentElement focusable, see Focusable.) In addition, this class contains APIs that you can use for traversing the focus across related elements.
Events: ContentElement includes events that are related to input and focus; it also includes events for changes in state. In many cases, the ContentElement events are routed events. In some cases, routed events have both tunneling and bubbling routing strategies, raised as separate events in response to the same state or condition. Also, ContentElement defines APIs that can raise routed events and that can add or remove handlers to events.
ContentElement shares many common APIs with UIElement. These common APIs do not come from a shared class inheritance. But they do share common naming, similar behavior, and similar internal implementation of APIs in each class. The similarity is because ContentElement and UIElement are each classes that are an element base, although each has different intentions for its markup object model behavior.
In particular, UIElement descends from Visual, which provides the lower-level graphics support for rendering a ContentElement to a rectangular region within a composited window, whereas ContentElement defers rendering so that concepts more common to document scenarios, such as flow and wrapping, are more easily supported. These two related classes also implement the common interfaces IInputElement and IAnimatable.
Notes to InheritorsThe ContentElement class does not yet define all aspects of a complete content element for flow-style presentation. FrameworkContentElement is an immediately derived class of ContentElement. FrameworkContentElement includes a more complete set of additional members that support rendering a FrameworkContentElement within a content host and using the WPF framework-level layout system.
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
