Android 12 Developer Preview is here! Try it out, and give us your feedback!

androidx.compose.foundation.text

Interfaces

KeyboardActionScope

This scope can be used to execute the default action implementation.

Classes

InlineTextContent

A data class that stores a composable to be inserted into the text layout.

KeyboardActions

The KeyboardActions class allows developers to specify actions that will be triggered in response to users triggering IME action on the software keyboard.

KeyboardOptions

The keyboard configuration options for TextFields.

Annotations

InternalFoundationTextApi

Top-level functions summary

Unit
BasicText(text: String, modifier: Modifier = Modifier, style: TextStyle = TextStyle.Default, onTextLayout: (TextLayoutResult) -> Unit = {}, overflow: TextOverflow = TextOverflow.Clip, softWrap: Boolean = true, maxLines: Int = Int.MAX_VALUE)

Basic element that displays text and provides semantics / accessibility information.

Unit
BasicText(text: AnnotatedString, modifier: Modifier = Modifier, style: TextStyle = TextStyle.Default, onTextLayout: (TextLayoutResult) -> Unit = {}, overflow: TextOverflow = TextOverflow.Clip, softWrap: Boolean = true, maxLines: Int = Int.MAX_VALUE, inlineContent: Map<String, InlineTextContent> = mapOf())

Basic element that displays text and provides semantics / accessibility information.

Unit
BasicTextField(value: String, onValueChange: (String) -> Unit, modifier: Modifier = Modifier, enabled: Boolean = true, readOnly: Boolean = false, textStyle: TextStyle = TextStyle.Default, keyboardOptions: KeyboardOptions = KeyboardOptions.Default, keyboardActions: KeyboardActions = KeyboardActions.Default, singleLine: Boolean = false, maxLines: Int = Int.MAX_VALUE,