Show / Hide Table of Contents

Class FrameworkElementAutomationPeer

Exposes FrameworkElement types (including controls) to UI automation.

Inheritance
System.Object
DependencyObject
AutomationPeer
FrameworkElementAutomationPeer
AccordionItemAutomationPeer
AutoCompleteBoxAutomationPeer
ButtonBaseAutomationPeer
CalendarAutomationPeer
CalendarButtonAutomationPeer
CalendarDayButtonAutomationPeer
ChildWindowAutomationPeer
DataFormAutomationPeer
DataGridAutomationPeer
DataGridCellAutomationPeer
DataGridColumnHeaderAutomationPeer
DataGridColumnHeadersPresenterAutomationPeer
DataGridDetailsPresenterAutomationPeer
DataGridGroupItemAutomationPeer
DataGridItemAutomationPeer
DataGridRowAutomationPeer
DataGridRowGroupHeaderAutomationPeer
DataGridRowHeaderAutomationPeer
DataGridRowsPresenterAutomationPeer
DataPagerAutomationPeer
DatePickerAutomationPeer
DescriptionViewerAutomationPeer
ExpanderAutomationPeer
FrameAutomationPeer
GlobalCalendarAutomationPeer
GlobalCalendarButtonAutomationPeer
GlobalCalendarDayButtonAutomationPeer
GridSplitterAutomationPeer
ImageAutomationPeer
ItemAutomationPeer
ItemsControlAutomationPeer
MediaElementAutomationPeer
PasswordBoxAutomationPeer
PickerAutomationPeer
RangeBaseAutomationPeer
RatingItemAutomationPeer
RichTextBoxAutomationPeer
ScrollViewerAutomationPeer
TextBlockAutomationPeer
TextBoxAutomationPeer
ThumbAutomationPeer
TimePickerPopupAutomationPeer
TreeViewAutomationPeer
TreeViewItemAutomationPeer
UpDownBaseAutomationPeer<T>
ValidationSummaryAutomationPeer
Inherited Members
AutomationPeer.EventsSource
AutomationPeer.ListenerExists(AutomationEvents)
AutomationPeer.GetAcceleratorKey()
AutomationPeer.GetAccessKey()
AutomationPeer.GetAutomationControlType()
AutomationPeer.GetAutomationId()
AutomationPeer.GetBoundingRectangle()
AutomationPeer.GetChildren()
AutomationPeer.GetClassName()
AutomationPeer.GetClickablePoint()
AutomationPeer.GetHelpText()
AutomationPeer.GetItemStatus()
AutomationPeer.GetItemType()
AutomationPeer.GetLabeledBy()
AutomationPeer.GetLocalizedControlType()
AutomationPeer.GetName()
AutomationPeer.GetOrientation()
AutomationPeer.HasKeyboardFocus()
AutomationPeer.IsContentElement()
AutomationPeer.IsControlElement()
AutomationPeer.IsEnabled()
AutomationPeer.IsKeyboardFocusable()
AutomationPeer.IsOffscreen()
AutomationPeer.IsPassword()
AutomationPeer.IsRequiredForForm()
AutomationPeer.SetFocus()
AutomationPeer.InvalidatePeer()
AutomationPeer.GetParent()
AutomationPeer.RaiseAutomationEvent(AutomationEvents)
AutomationPeer.RaisePropertyChangedEvent(AutomationProperty, Object, Object)
AutomationPeer.PeerFromProvider(IRawElementProviderSimple)
AutomationPeer.ProviderFromPeer(AutomationPeer)
DependencyObject.GetValue(DependencyProperty)
DependencyObject.SetCurrentValue(DependencyProperty, Object)
DependencyObject.ReadLocalValue(DependencyProperty)
DependencyObject.SetValue(DependencyProperty, Object)
DependencyObject.SetValue(DependencyPropertyKey, Object)
DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs)
DependencyObject.CoerceValue(DependencyProperty)
DependencyObject.Dispatcher
DependencyObject.INTERNAL_OnAttachedToVisualTree()
DependencyObject.INTERNAL_OnDetachedFromVisualTree()
DependencyObject.ClearValue(DependencyProperty)
DependencyObject.ClearValue(DependencyPropertyKey)
DependencyObject.CheckAccess()
DependencyObject.GetAnimationBaseValue(DependencyProperty)
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: System.Windows.Automation.Peers
Assembly: OpenSilver.dll
Syntax
public class FrameworkElementAutomationPeer : AutomationPeer, IDependencyObject

Constructors

| Improve this Doc View Source

FrameworkElementAutomationPeer(FrameworkElement)

Initializes a new instance of the FrameworkElementAutomationPeer class.

Declaration
public FrameworkElementAutomationPeer(FrameworkElement owner)
Parameters
Type Name Description
FrameworkElement owner

The FrameworkElement that is associated with this FrameworkElementAutomationPeer.

Exceptions
Type Condition
System.ArgumentNullException

owner is null.

Properties

| Improve this Doc View Source

Owner

Gets the UIElement that is associated with this FrameworkElementAutomationPeer.

Declaration
public UIElement Owner { get; }
Property Value
Type Description
UIElement

The element that owns this peer class.

Methods

| Improve this Doc View Source

CreatePeerForElement(UIElement)

Creates a FrameworkElementAutomationPeer for the specified UIElement.

Declaration
public static AutomationPeer CreatePeerForElement(UIElement element)
Parameters
Type Name Description
UIElement element

The UIElement that is associated with this FrameworkElementAutomationPeer.

Returns
Type Description
AutomationPeer

The FrameworkElementAutomationPeer for the specified UIElement.

Exceptions
Type Condition
System.ArgumentNullException

element is null.

| Improve this Doc View Source

FromElement(UIElement)

Returns the FrameworkElementAutomationPeer for the specified UIElement.

Declaration
public static AutomationPeer FromElement(UIElement element)
Parameters
Type Name Description
UIElement element

The UIElement that is associated with this FrameworkElementAutomationPeer.

Returns
Type Description
AutomationPeer

The FrameworkElementAutomationPeer, or null if the FrameworkElementAutomationPeer was not created by the CreatePeerForElement(UIElement) method.

Exceptions
Type Condition
System.ArgumentNullException

element is null.

| Improve this Doc View Source

GetAcceleratorKeyCore()

Returns the accelerator key for the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetAcceleratorKey().

Declaration
protected override string GetAcceleratorKeyCore()
Returns
Type Description
System.String

The System.Windows.Automation.AutomationProperties.AcceleratorKey that is returned by GetAcceleratorKey(DependencyObject).

Overrides
AutomationPeer.GetAcceleratorKeyCore()
| Improve this Doc View Source

GetAccessKeyCore()

Returns the access key for the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetAccessKey().

Declaration
protected override string GetAccessKeyCore()
Returns
Type Description
System.String

The access key for the element that is associated with this FrameworkElementAutomationPeer.

Overrides
AutomationPeer.GetAccessKeyCore()
| Improve this Doc View Source

GetAutomationControlTypeCore()

Returns the control type for the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetAutomationControlType().

Declaration
protected override AutomationControlType GetAutomationControlTypeCore()
Returns
Type Description
AutomationControlType

A value of the enumeration.

Overrides
AutomationPeer.GetAutomationControlTypeCore()
| Improve this Doc View Source

GetAutomationIdCore()

Returns the string that uniquely identifies the FrameworkElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetAutomationId().

Declaration
protected override string GetAutomationIdCore()
Returns
Type Description
System.String

The automation identifier for the element associated with the FrameworkElementAutomationPeer, or System.String.Empty if there is no automation identifier.

Overrides
AutomationPeer.GetAutomationIdCore()
| Improve this Doc View Source

GetBoundingRectangleCore()

Returns the Rect that represents the bounding rectangle of the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetBoundingRectangle().

Declaration
[NotImplemented]
protected override Rect GetBoundingRectangleCore()
Returns
Type Description
Rect

The Rect that contains the coordinates of the element.

Overrides
AutomationPeer.GetBoundingRectangleCore()
| Improve this Doc View Source

GetChildrenCore()

Returns the collection of child elements of the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetChildren().

Declaration
protected override List<AutomationPeer> GetChildrenCore()
Returns
Type Description
System.Collections.Generic.List<AutomationPeer>

A list of child AutomationPeer elements.

Overrides
AutomationPeer.GetChildrenCore()
| Improve this Doc View Source

GetClassNameCore()

Returns the name of the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetClassName().

Declaration
protected override string GetClassNameCore()
Returns
Type Description
System.String

The name of the owner type that is associated with this FrameworkElementAutomationPeer. See "Notes for Inheritors".

Overrides
AutomationPeer.GetClassNameCore()
Remarks

Notes to Inheritors

The return value for this method in the FrameworkElementAutomationPeer implementation comes from an internal property store, and it returns an empty string. Specific subclasses generally override this method again and return the class name of the owner type for the automation peer. There are two general patterns: return a string that is coded into the implementation, for example "Button"; call Owner.GetType().Name. The latter approach is appropriate if your peer is otherwise suitable for use on subclasses of its primary owner control type. In this case the dynamic value for ClassName saves the control subclasser from having to re-implement that aspect of the automation peer.

| Improve this Doc View Source

GetClickablePointCore()

Returns a Point that represents the clickable space that is on the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetClickablePoint().

Declaration
[NotImplemented]
protected override Point GetClickablePointCore()
Returns
Type Description
Point

The Point on the element that allows a click.

Overrides
AutomationPeer.GetClickablePointCore()
| Improve this Doc View Source

GetHelpTextCore()

Returns the string that describes the functionality of the FrameworkElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetHelpText().

Declaration
protected override string GetHelpTextCore()
Returns
Type Description
System.String

The help text, or System.String.Empty if there is no help text.

Overrides
AutomationPeer.GetHelpTextCore()
| Improve this Doc View Source

GetItemStatusCore()

Returns a string that communicates the visual status of the UIElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetItemStatus().

Declaration
protected override string GetItemStatusCore()
Returns
Type Description
System.String

The string that contains the System.Windows.Automation.AutomationProperties.ItemStatus that is returned by GetItemStatus(DependencyObject).

Overrides
AutomationPeer.GetItemStatusCore()
| Improve this Doc View Source

GetItemTypeCore()

Returns a human-readable string that contains the item type that the UIElement for this FrameworkElementAutomationPeer represents. This method is called by GetItemType().

Declaration
protected override string GetItemTypeCore()
Returns
Type Description
System.String

The string that contains the System.Windows.Automation.AutomationProperties.ItemType that is returned by GetItemType(DependencyObject).

Overrides
AutomationPeer.GetItemTypeCore()
| Improve this Doc View Source

GetLabeledByCore()

Returns the AutomationPeer for the UIElement that targets the FrameworkElement that is associated with this FrameworkElementAutomationPeer. This method is called by GetLabeledBy().

Declaration
protected override AutomationPeer GetLabeledByCore()
Returns
Type Description
AutomationPeer

The AutomationPeer for the element that is targeted by the UIElement.

Overrides
AutomationPeer.GetLabeledByCore()
| Improve this Doc View Source

GetLocalizedControlTypeCore()

Returns a localized human-readable string that identifies a control type. The control type is for the owner type that is associated with this FrameworkElementAutomationPeer. This method is called by GetLocalizedControlType().

Declaration
protected override string GetLocalizedControlTypeCore()
Returns
Type Description
System.String

A localized string that contains the type name of the owner control.

Overrides
AutomationPeer.GetLocalizedControlTypeCore()
| Improve this Doc View Source

GetNameCore()

Returns the UI Automation Name from the element that is associated with this FrameworkElementAutomationPeer. This method is called by GetName().

Declaration
protected override string GetNameCore()
Returns
Type Description
System.String

The UI Automation Name from the element that is associated with this automation peer.

Overrides
AutomationPeer.GetNameCore()
| Improve this Doc View Source

GetOrientationCore()

Returns a value that indicates whether the element that is associated with this FrameworkElementAutomationPeer is laid out in a specific direction. This method is called by GetOrientation().

Declaration
protected override AutomationOrientation GetOrientationCore()
Returns
Type Description
AutomationOrientation

The None enumeration value.

Overrides
AutomationPeer.GetOrientationCore()
| Improve this Doc View Source

GetPattern(PatternInterface)

Returns an object that supports the requested pattern, based on the patterns supported by this FrameworkElementAutomationPeer.

Declaration
public override object GetPattern(PatternInterface patternInterface)
Parameters
Type Name Description
PatternInterface patternInterface

One of the enumeration values.

Returns
Type Description
System.Object

See Remarks.

Overrides
AutomationPeer.GetPattern(PatternInterface)
Remarks

The return value for this method in the FrameworkElementAutomationPeer implementation returns null in all cases. Override this method to report a specific pattern.

| Improve this Doc View Source

HasKeyboardFocusCore()

Returns a value that indicates whether the UIElement that is associated with this FrameworkElementAutomationPeer currently has keyboard input focus. This method is called by HasKeyboardFocus().

Declaration
[NotImplemented]
protected override bool HasKeyboardFocusCore()
Returns
Type Description
System.Boolean

true if the element has keyboard input focus; otherwise, false.

Overrides
AutomationPeer.HasKeyboardFocusCore()
| Improve this Doc View Source

IsContentElementCore()

Returns a value that indicates whether the element that is associated with this FrameworkElementAutomationPeer is an element that contains data that is presented to the user. This method is called by IsContentElement().

Declaration
protected override bool IsContentElementCore()
Returns
Type Description
System.Boolean

true if the element contains data for the user to read; otherwise, false.

Overrides
AutomationPeer.IsContentElementCore()
| Improve this Doc View Source

IsControlElementCore()

Returns a value that indicates whether the object that is associated with this FrameworkElementAutomationPeer is understood by the end user as interactive. Optionally, the user might understand the object as contributing to the logical structure of the control in the GUI. This method is called by IsControlElement().

Declaration
protected override bool IsControlElementCore()
Returns
Type Description
System.Boolean

true if the object is interactive; otherwise, false.

Overrides
AutomationPeer.IsControlElementCore()
| Improve this Doc View Source

IsEnabledCore()

Returns a value that indicates whether the UIElement that is associated with this FrameworkElementAutomationPeer is enabled. This method is called by IsEnabled().

Declaration
protected override bool IsEnabledCore()
Returns
Type Description
System.Boolean

true if the element is enabled; otherwise, false.

Overrides
AutomationPeer.IsEnabledCore()
| Improve this Doc View Source

IsKeyboardFocusableCore()

Returns a value that indicates whether the element that is associated with this FrameworkElementAutomationPeer can accept keyboard focus. This method is called by IsKeyboardFocusable().

Declaration
protected override bool IsKeyboardFocusableCore()
Returns
Type Description
System.Boolean

true if the element is focusable by the keyboard; otherwise, false.

Overrides
AutomationPeer.IsKeyboardFocusableCore()
| Improve this Doc View Source

IsOffscreenCore()

Returns a value that indicates whether the UIElement that is associated with this FrameworkElementAutomationPeer is off the screen. This method is called by IsOffscreen().

Declaration
protected override bool IsOffscreenCore()
Returns
Type Description
System.Boolean

true if the element is not on the screen; otherwise, false.

Overrides
AutomationPeer.IsOffscreenCore()
| Improve this Doc View Source

IsPasswordCore()

Returns a value that indicates whether the element that is associated with this FrameworkElementAutomationPeer contains protected content. This method is called by IsPassword().

Declaration
protected override bool IsPasswordCore()
Returns
Type Description
System.Boolean

true if the element contains sensitive content; otherwise, false.

Overrides
AutomationPeer.IsPasswordCore()
| Improve this Doc View Source

IsRequiredForFormCore()

Returns a value that indicates whether the element that is associated with this FrameworkElementAutomationPeer is required to be completed on a form. This method is called by IsRequiredForForm().

Declaration
protected override bool IsRequiredForFormCore()
Returns
Type Description
System.Boolean

The value that is returned by GetIsRequiredForForm(DependencyObject), if the value is set; otherwise, false.

Overrides
AutomationPeer.IsRequiredForFormCore()
| Improve this Doc View Source

SetFocusCore()

Sets the keyboard input focus on the element that is associated with this FrameworkElementAutomationPeer. This method is called by SetFocus().

Declaration
protected override void SetFocusCore()
Overrides
AutomationPeer.SetFocusCore()

Extension Methods

DependencyObjectHelper.GetSelfAndAncestors(DependencyObject)
VisualTreeExtensions.GetVisualAncestors(DependencyObject)
VisualTreeExtensions.GetVisualAncestorsAndSelf(DependencyObject)
VisualTreeExtensions.GetVisualChildren(DependencyObject)
VisualTreeExtensions.GetVisualChildrenAndSelf(DependencyObject)
VisualTreeExtensions.GetVisualDescendants(DependencyObject)
VisualTreeExtensions.GetVisualDescendantsAndSelf(DependencyObject)
VisualTreeExtensions.GetVisualSiblings(DependencyObject)
VisualTreeExtensions.GetVisualSiblingsAndSelf(DependencyObject)
  • Improve this Doc
  • View Source