Stay organized with collections
Save and categorize content based on your preferences.
Interfaces
SemanticsPropertyReceiver |
SemanticsPropertyReceiver is the scope provided by semantics {} blocks, letting you set key/value pairs primarily via extension functions.
|
Classes
SemanticsConfiguration |
Describes the semantics information associated with the owning component.
|
SemanticsPropertyKey |
SemanticsPropertyKey is the infrastructure for setting key/value pairs inside semantics block in a type-safe way.
|
Objects
Extension functions summary
GlanceModifier |
Add semantics for use in testing, accessibility and similar use cases.
|
Extension properties summary
String |
Developer-set content description of the semantics node, for use in testing, accessibility and similar use cases.
|
String |
Test tag attached to this Glance composable node.
|
Extension functions
Extension properties
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-05-15 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-15 UTC."],[],[],null,["# androidx.glance.semantics\n=========================\n\nInterfaces\n----------\n\n|----------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------|\n| [SemanticsPropertyReceiver](/reference/kotlin/androidx/glance/semantics/SemanticsPropertyReceiver) | SemanticsPropertyReceiver is the scope provided by semantics {} blocks, letting you set key/value pairs primarily via extension functions. |\n\nClasses\n-------\n\n|----------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|\n| [SemanticsConfiguration](/reference/kotlin/androidx/glance/semantics/SemanticsConfiguration) | Describes the semantics information associated with the owning component. |\n| [SemanticsPropertyKey](/reference/kotlin/androidx/glance/semantics/SemanticsPropertyKey) | SemanticsPropertyKey is the infrastructure for setting key/value pairs inside semantics block in a type-safe way. |\n\nObjects\n-------\n\n|----------------------------------------------------------------------------------------|--------------------------------------------------------------------------|\n| [SemanticsProperties](/reference/kotlin/androidx/glance/semantics/SemanticsProperties) | General semantics properties, mainly used for accessibility and testing. |\n\nExtension functions summary\n---------------------------\n\n|--------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [GlanceModifier](/reference/kotlin/androidx/glance/GlanceModifier) | [GlanceModifier](/reference/kotlin/androidx/glance/GlanceModifier)`.`[semantics](/reference/kotlin/androidx/glance/semantics/package-summary#(androidx.glance.GlanceModifier).semantics(kotlin.Function1))`(properties: `[SemanticsPropertyReceiver](/reference/kotlin/androidx/glance/semantics/SemanticsPropertyReceiver)`.() `-\u003e` `[Unit](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html)`)` Add semantics for use in testing, accessibility and similar use cases. |\n\nExtension properties summary\n----------------------------\n\n|-----------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | [SemanticsPropertyReceiver](/reference/kotlin/androidx/glance/semantics/SemanticsPropertyReceiver)`.`[contentDescription](/reference/kotlin/androidx/glance/semantics/package-summary#(androidx.glance.semantics.SemanticsPropertyReceiver).contentDescription()) Developer-set content description of the semantics node, for use in testing, accessibility and similar use cases. |\n| [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | [SemanticsPropertyReceiver](/reference/kotlin/androidx/glance/semantics/SemanticsPropertyReceiver)`.`[testTag](/reference/kotlin/androidx/glance/semantics/package-summary#(androidx.glance.semantics.SemanticsPropertyReceiver).testTag()) Test tag attached to this Glance composable node. |\n\nExtension functions\n-------------------\n\n### semantics\n\nArtifact: [androidx.glance:glance](/jetpack/androidx/releases/glance) \n[View Source](https://cs.android.com/search?q=file:androidx/glance/semantics/SemanticsModifier.kt+function:semantics) \nAdded in [1.0.0](/jetpack/androidx/releases/glance#1.0.0) \n\n```\nfun GlanceModifier.semantics(properties: SemanticsPropertyReceiver.() -\u003e Unit): GlanceModifier\n```\n\nAdd semantics for use in testing, accessibility and similar use cases.\n\nExtension properties\n--------------------\n\n### contentDescription\n\nArtifact: [androidx.glance:glance](/jetpack/androidx/releases/glance) \n[View Source](https://cs.android.com/search?q=file:androidx/glance/semantics/SemanticsProperties.kt+symbol:contentDescription) \nAdded in [1.0.0](/jetpack/androidx/releases/glance#1.0.0) \n\n```\nvar SemanticsPropertyReceiver.contentDescription: String\n```\n\nDeveloper-set content description of the semantics node, for use in testing, accessibility and similar use cases. \n\n### testTag\n\nArtifact: [androidx.glance:glance](/jetpack/androidx/releases/glance) \n[View Source](https://cs.android.com/search?q=file:androidx/glance/semantics/SemanticsProperties.kt+symbol:testTag) \nAdded in [1.1.0](/jetpack/androidx/releases/glance#1.1.0) \n\n```\nvar SemanticsPropertyReceiver.testTag: String\n```\n\nTest tag attached to this Glance composable node.\n\nThis is a free form String and can be used to find nodes in testing frameworks."]]