Export (0) Print
Expand All

Text Attribute Identifiers

This topic describes the named constants used to identify text attributes of a Microsoft UI Automation text range. These constants are used with the following methods:

Constant/valueDescription
UIA_AnimationStyleAttributeId
40000

Identifies the AnimationStyle text attribute, which specifies the type of animation applied to the text. This attribute is specified as a value from the AnimationStyle enumerated type.

Variant type: VT_I4

Default value: AnimationStyle_None

UIA_AnnotationObjectsAttributeId
40032

Identifies the AnnotationObjects text attribute, which maintains an array of IUIAutomationElement2 interfaces, one for each element in the current text range that implements the Annotation control pattern. Each element might also implement other control patterns as needed to describe the annotation. For example, an annotation that is a comment would also support the Text control pattern. Supported starting with Windows 8.

Variant type: VT_ARRAY | VT_UNKNOWN

Default value: empty array

UIA_AnnotationTypesAttributeId
40031

Identifies the AnnotationTypes text attribute, which maintains a list of annotation type identifiers for a range of text. For a list of possible values, see Annotation Type Identifiers. Supported starting with Windows 8.

Variant type: VT_ARRAY | VT_I4

Default value: empty array

UIA_BackgroundColorAttributeId
40001

Identifies the BackgroundColor text attribute, which specifies the background color of the text. This attribute is specified as a COLORREF; a 32-bit value used to specify an RGB or RGBA color.

Variant type: VT_I4

Default value: 0

UIA_BulletStyleAttributeId
40002

Identifies the BulletStyle text attribute, which specifies the style of bullets used in the text range. This attribute is specified as a value from the BulletStyle enumerated type.

Variant type: VT_I4

Default value: BulletStyle_None

UIA_CapStyleAttributeId
40003

Identifies the CapStyle text attribute, which specifies the capitalization style for the text. This attribute is specified as a value from the CapStyle enumerated type.

Variant type: VT_I4

Default value: CapStyle_None

UIA_CaretBidiModeAttributeId
40039

Identifies the CaretBidiMode text attribute, which indicates the direction of text flow in the text range. This attribute is specified as a value from the CaretBidiMode enumerated type. Supported starting with Windows 8.

Variant type: VT_I4

Default value: CaretBidiMode_LTR

UIA_CaretPositionAttributeId
40038

Identifies the CaretPosition text attribute, which indicates whether the caret is at the beginning or the end of a line of text in the text range. This attribute is specified as a value from the CaretPosition enumerated type. Supported starting with Windows 8.

Variant type: VT_I4

Default value: CaretPosition_Unknown

UIA_CultureAttributeId
40004

Identifies the Culture text attribute, which specifies the locale of the text by locale identifier (LCID).

Variant type: VT_I4

Default value: locale of the application UI

UIA_FontNameAttributeId
40005

Identifies the FontName text attribute, which specifies the name of the font. Examples: "Arial Black"; "Arial Narrow". The font name string is not localized.

Variant type: VT_BSTR

Default value: empty string

UIA_FontSizeAttributeId
40006

Identifies the FontSize text attribute, which specifies the point size of the font.

Variant type: VT_R8

Default value: 0

UIA_FontWeightAttributeId
400007

Identifies the FontWeight text attribute, which specifies the relative stroke, thickness, or boldness of the font. The FontWeight attribute is modeled after the lfWeight member of the GDI LOGFONT structure, and related standards, and can be one of the following values:

  • 0 = DontCare
  • 100 = Thin
  • 200 = ExtraLight or UltraLight
  • 300 = Light
  • 400 = Normal or Regular
  • 500 = Medium
  • 600 = SemiBold
  • 700 = Bold
  • 800 = ExtraBold or UltraBold
  • 900 = Heavy or Black

Variant type: VT_I4

Default value: 0

UIA_ForegroundColorAttributeId
40008

Identifies the ForegroundColor text attribute, which specifies the foreground color of the text. This attribute is specified as a COLORREF, a 32-bit value used to specify an RGB or RGBA color.

Variant type: VT_I4

Default value: 0

UIA_HorizontalTextAlignmentAttributeId
40009

Identifies the HorizontalTextAlignment text attribute, which specifies how the text is aligned horizontally. This attribute is specified as a value from the HorizontalTextAlignmentEnum enumerated type.

Variant type: VT_I4

Default value: HorizontalTextAlignment_Left

UIA_IndentationFirstLineAttributeId
40010

Identifies the IndentationFirstLine text attribute, which specifies how far, in points, to indent the first line of a paragraph.

Variant type: VT_R8

Default value: 0

UIA_IndentationLeadingAttributeId
40011

Identifies the IndentationLeading text attribute, which specifies the leading indentation, in points.

Variant type: VT_R8

Default value: 0

UIA_IndentationTrailingAttributeId
40012

Identifies the IndentationTrailing text attribute, which specifies the trailing indentation, in points.

Variant type: VT_R8

Default value: 0

UIA_IsActiveAttributeId
40036

Identifies the IsActive text attribute, which indicates whether the control that contains the text range has the keyboard focus (TRUE) or not (FALSE). Supported starting with Windows 8.

Variant type: VT_BOOL

Default value: FALSE

UIA_IsHiddenAttributeId
40013

Identifies the IsHidden text attribute, which indicates whether the text is hidden (TRUE) or visible (FALSE).

Variant type: VT_BOOL

Default value: FALSE

UIA_IsItalicAttributeId
40014

Identifies the IsItalic text attribute, which indicates whether the text is italic (TRUE) or not (FALSE).

Variant type: VT_BOOL

Default value: FALSE

UIA_IsReadOnlyAttributeId
40015

Identifies the IsReadOnly text attribute, which indicates whether the text is read-only (TRUE) or can be modified (FALSE).

Variant type: VT_BOOL

Default value: FALSE

UIA_IsSubscriptAttributeId
40016

Identifies the IsSubscript text attribute, which indicates whether the text is subscript (TRUE) or not (FALSE).

Variant type: VT_BOOL

Default value: FALSE

UIA_IsSuperscriptAttributeId
40017

Identifies the IsSuperscript text attribute, which indicates whether the text is subscript (TRUE) or not (FALSE).

Variant type: VT_BOOL

Default value: FALSE

UIA_LinkAttributeId
40035

Identifies the Link text attribute, which contains the IUIAutomationTextRange interface of the text range that is the target of an internal link in a document. Supported starting with Windows 8.

Variant type: VT_UNKNOWN

Default value: NULL

UIA_MarginBottomAttributeId
40018

Identifies the MarginBottom text attribute, which specifies the size, in points, of the bottom margin applied to the page associated with the text range.

Variant type: VT_R8

Default value: 0

UIA_MarginLeadingAttributeId
40019

Identifies the MarginLeading text attribute, which specifies the size, in points, of the leading margin applied to the page associated with the text range.

Variant type: VT_R8

Default value: 0

UIA_MarginTopAttributeId
40020

Identifies the MarginTop text attribute, which specifies the size, in points, of the top margin applied to the page associated with the text range.

Variant type: VT_R8

Ddefault value: 0

UIA_MarginTrailingAttributeId
40021

Identifies the MarginTrailing text attribute, which specifies the size, in points, of the trailing margin applied to the page associated with the text range.

Variant type: VT_R8

Default value: 0

UIA_OutlineStylesAttributeId
40022

Identifies the OutlineStyles text attribute, which specifies the outline style of the text. This attribute is specified as a value from the OutlineStyles enumerated type.

Variant type: VT_I4

Default value: OutlineStyles_None

UIA_OverlineColorAttributeId
40023

Identifies the OverlineColor text attribute, which specifies the color of the overline text decoration. This attribute is specified as a COLORREF, a 32-bit value used to specify an RGB or RGBA color.

Variant type: VT_I4

Default value: 0

UIA_OverlineStyleAttributeId
40024

Identifies the OverlineStyle text attribute, which specifies the style of the overline text decoration. This attribute is specified as a value from the TextDecorationLineStyleEnum enumerated type.

Variant type: VT_I4

Default value: TextDecorationLineStyle_None

UIA_SelectionActiveEndAttributeId
40037

Identifies the SelectionActiveEnd text attribute, which indicates the location of the caret relative to a text range that represents the currently selected text. This attribute is specified as a value from the ActiveEnd enumeration. Supported starting with Windows 8.

Variant type: VT_I4

Default value: ActiveEnd_None

UIA_StrikethroughColorAttributeId
40025

Identifies the StrikethroughColor text attribute, which specifies the color of the strikethrough text decoration. This attribute is specified as a COLORREF, a 32-bit value used to specify an RGB or RGBA color.

Variant type: VT_I4

Default value: 0

UIA_StrikethroughStyleAttributeId
40026

Identifies the StrikethroughStyle text attribute, which specifies the style of the strikethrough text decoration. This attribute is specified as a value from the TextDecorationLineStyleEnum enumerated type.

Variant type: VT_I4

Default value: TextDecorationLineStyle_None

UIA_StyleIdAttributeId
40034

Identifies the StyleId text attribute, which indicates the text styles in use for a text range. For a list of possible values, see Style Identifiers. Supported starting with Windows 8.

Variant type: VT_I4

Default value: 0

UIA_StyleNameAttributeId
40033

Identifies the StyleName text attribute, which identifies the localized name of the text style in use for a text range. Supported starting with Windows 8.

Variant type: VT_BSTR

Default value: empty string

UIA_TabsAttributeId
40027

Identifies the Tabs text attribute, which is an array specifying the tab stops for the text range. Each array element specifies a distance, in points, from the leading margin.

Variant type: VT_ARRAY | VT_R8

Default value: empty array

UIA_TextFlowDirectionsAttributeId
40028

Identifies the TextFlowDirections text attribute, which specifies the direction of text flow. This attribute is specified as a combination of values from the FlowDirections enumerated type.

Variant type: VT_I4

Default value: FlowDirections_Default

UIA_UnderlineColorAttributeId
40029

Identifies the UnderlineColor text attribute, which specifies the color of the underline text decoration. This attribute is specified as a COLORREF, a 32-bit value used to specify an RGB or RGBA color.

Variant type: VT_I4

Default value: 0

UIA_UnderlineStyleAttributeId
40030

Identifies the UnderlineStyle text attribute, which specifies the style of the underline text decoration. This attribute is specified as a value from the TextDecorationLineStyleEnum enumerated type.

Variant type: VT_I4

Default value: TextDecorationLineStyle_None

Requirements

Minimum supported client

Windows XP [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2003 [desktop apps | Windows Store apps]

Header

UIAutomationClient.h

See also

Reference
ITextRangeProvider::FindAttribute
ITextRangeProvider::GetAttributeValue
IUIAutomation::FindAttribute
IUIAutomation::GetAttributeValue
Conceptual
UI Automation Support for Textual Content

 

 

Community Additions

ADD
Show:
© 2014 Microsoft