# TextAppearanceInfo.Builder

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)

# Builder

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/android/view/inputmethod/TextAppearanceInfo.Builder "View this page in Java")  

```
class Builder
```

|---|------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)                                                                             ||
| ↳ | [android.view.inputmethod.TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) |

Builder for[TextAppearanceInfo](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo).

## Summary

|                                                          Public constructors                                                          ||
|------------------------------------------------------------------------------------------------------------------------------------|---|
| [Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#Builder())`()` <br /> |

|                                                                                                                                                                                                                                                                                              Public methods                                                                                                                                                                                                                                                                                              ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [TextAppearanceInfo](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo)                  | [build](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#build())`()` Returns[TextAppearanceInfo](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo)using parameters in this[TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#).                                                             |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setAllCaps](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setAllCaps(kotlin.Boolean))`(`allCaps:` `[Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)`)` Set whether the transformation method applied to the current editor is set to all caps.                                                                                                                                |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setElegantTextHeight](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setElegantTextHeight(kotlin.Boolean))`(`elegantTextHeight:` `[Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)`)` Set the elegant height metrics flag.                                                                                                                                                     |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setFallbackLineSpacing](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setFallbackLineSpacing(kotlin.Boolean))`(`fallbackLineSpacing:` `[Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)`)` Set whether to expand linespacing based on fallback fonts.                                                                                                                         |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setFontFeatureSettings](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setFontFeatureSettings(kotlin.String))`(`fontFeatureSettings:` `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?`)` Set the font feature settings.                                                                                                                                                       |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setFontVariationSettings](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setFontVariationSettings(kotlin.String))`(`fontVariationSettings:` `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?`)` Set the font variation settings.                                                                                                                                               |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setHighlightTextColor](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setHighlightTextColor(kotlin.Int))`(`highlightTextColor:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the color of the text selection highlight.                                                                                                                                                    |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setHintTextColor](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setHintTextColor(kotlin.Int))`(`hintTextColor:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the current color of the hint text.                                                                                                                                                                          |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setLetterSpacing](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setLetterSpacing(kotlin.Float))`(`letterSpacing:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Set the text letter-spacing, which determines the spacing between characters.                                                                                                                              |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setLineBreakStyle](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setLineBreakStyle(kotlin.Int))`(`lineBreakStyle:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the line-break strategies for text wrapping.                                                                                                                                                              |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setLineBreakWordStyle](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setLineBreakWordStyle(kotlin.Int))`(`lineBreakWordStyle:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the line-break word strategies for text wrapping.                                                                                                                                             |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setLinkTextColor](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setLinkTextColor(kotlin.Int))`(`linkTextColor:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the text color used to paint the links in the editor.                                                                                                                                                        |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setShadowColor](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setShadowColor(kotlin.Int))`(`shadowColor:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the color of the text shadow.                                                                                                                                                                                      |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setShadowDx](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setShadowDx(kotlin.Float))`(`shadowDx:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Set the horizontal offset (in pixels) of the text shadow.                                                                                                                                                                 |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setShadowDy](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setShadowDy(kotlin.Float))`(`shadowDy:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Set the vertical offset (in pixels) of the text shadow.                                                                                                                                                                   |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setShadowRadius](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setShadowRadius(kotlin.Float))`(`shadowRadius:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Set the blur radius (in pixels) of the text shadow.                                                                                                                                                           |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setSystemFontFamilyName](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setSystemFontFamilyName(kotlin.String))`(`systemFontFamilyName:` `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?`)` Set the system font family name if the[Typeface](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#)of the text is created from a system font family. |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setTextColor](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setTextColor(kotlin.Int))`(`textColor:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the current text color of the editor.                                                                                                                                                                                    |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setTextFontWeight](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setTextFontWeight(kotlin.Int))`(`textFontWeight:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the weight of the text.                                                                                                                                                                                   |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setTextLocales](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setTextLocales(android.os.LocaleList))`(`textLocales:` `[LocaleList](https://developer.android.com/reference/kotlin/android/os/LocaleList.html#)`)` Set the[LocaleList](https://developer.android.com/reference/kotlin/android/os/LocaleList.html#)of the text.                                                                                   |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setTextScaleX](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setTextScaleX(kotlin.Float))`(`textScaleX:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Set the extent by which text should be stretched horizontally.                                                                                                                                                      |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setTextSize](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setTextSize(kotlin.Float))`(`textSize:` `[Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html)`)` Set the text size (in pixels) obtained from the current editor.                                                                                                                                                           |
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | [setTextStyle](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#setTextStyle(kotlin.Int))`(`textStyle:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`)` Set the style (normal, bold, italic, bold\|italic) of the text.                                                                                                                                                              |

## Public constructors

### Builder

```
Builder()
```

## Public methods

### build

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun build(): TextAppearanceInfo
```

Returns[TextAppearanceInfo](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo)using parameters in this[TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#).

|                                                                    Return                                                                     ||
|------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo) | This value cannot be`null`. |

### setAllCaps

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setAllCaps(allCaps: Boolean): TextAppearanceInfo.Builder
```

Set whether the transformation method applied to the current editor is set to all caps.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#setAllCaps(boolean)](https://developer.android.com/reference/kotlin/android/widget/TextView.html#setAllCaps(kotlin.Boolean))
- [android.widget.TextView#setTransformationMethod(TransformationMethod)](https://developer.android.com/reference/kotlin/android/widget/TextView.html#setTransformationMethod(android.text.method.TransformationMethod))  

### setElegantTextHeight

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setElegantTextHeight(elegantTextHeight: Boolean): TextAppearanceInfo.Builder
```

Set the elegant height metrics flag. This setting selects font variants that have not been compacted to fit Latin-based vertical metrics, and also increases top and bottom bounds to provide more space.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Paint#isElegantTextHeight()](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#isElegantTextHeight())  

### setFallbackLineSpacing

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setFallbackLineSpacing(fallbackLineSpacing: Boolean): TextAppearanceInfo.Builder
```

Set whether to expand linespacing based on fallback fonts.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#setFallbackLineSpacing(boolean)](https://developer.android.com/reference/kotlin/android/widget/TextView.html#setFallbackLineSpacing(kotlin.Boolean))  

### setFontFeatureSettings

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setFontFeatureSettings(fontFeatureSettings: String?): TextAppearanceInfo.Builder
```

Set the font feature settings.

|                                                            Parameters                                                             ||
|-----------------------|------------------------------------------------------------------------------------------------------------|
| `fontFeatureSettings` | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?:This value may be`null`. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Paint#getFontFeatureSettings()](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#getFontFeatureSettings())  

### setFontVariationSettings

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setFontVariationSettings(fontVariationSettings: String?): TextAppearanceInfo.Builder
```

Set the font variation settings. Set`null`if no variation is specified.

|                                                             Parameters                                                              ||
|-------------------------|------------------------------------------------------------------------------------------------------------|
| `fontVariationSettings` | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?:This value may be`null`. |

**See Also**

- [android.graphics.Paint#getFontVariationSettings()](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#getFontVariationSettings())  

### setHighlightTextColor

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setHighlightTextColor(highlightTextColor: Int): TextAppearanceInfo.Builder
```

Set the color of the text selection highlight.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#getHighlightColor()](https://developer.android.com/reference/kotlin/android/widget/TextView.html#getHighlightColor())  

### setHintTextColor

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setHintTextColor(hintTextColor: Int): TextAppearanceInfo.Builder
```

Set the current color of the hint text.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#getCurrentHintTextColor()](https://developer.android.com/reference/kotlin/android/widget/TextView.html#getCurrentHintTextColor())  

### setLetterSpacing

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setLetterSpacing(letterSpacing: Float): TextAppearanceInfo.Builder
```

Set the text letter-spacing, which determines the spacing between characters. The value is in 'EM' units. Normally, this value is 0.0.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

### setLineBreakStyle

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setLineBreakStyle(lineBreakStyle: Int): TextAppearanceInfo.Builder
```

Set the line-break strategies for text wrapping.

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Parameters                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           ||
|------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `lineBreakStyle` | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html):Value is[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_NONE](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_NONE:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_LOOSE](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_LOOSE:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_NORMAL](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_NORMAL:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_STRICT](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_STRICT:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_UNSPECIFIED](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_UNSPECIFIED:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_NO_BREAK](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_NO_BREAK:kotlin.Int), or[android.graphics.text.LineBreakConfig#LINE_BREAK_STYLE_AUTO](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_STYLE_AUTO:kotlin.Int) |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#setLineBreakStyle(int)](https://developer.android.com/reference/kotlin/android/widget/TextView.html#setLineBreakStyle(kotlin.Int))  

### setLineBreakWordStyle

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setLineBreakWordStyle(lineBreakWordStyle: Int): TextAppearanceInfo.Builder
```

Set the line-break word strategies for text wrapping.

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Parameters                                                                                                                                                                                                                                                                                                                                                                                                                                                                   ||
|----------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `lineBreakWordStyle` | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html):Value is[android.graphics.text.LineBreakConfig#LINE_BREAK_WORD_STYLE_NONE](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_WORD_STYLE_NONE:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_WORD_STYLE_PHRASE](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_WORD_STYLE_PHRASE:kotlin.Int),[android.graphics.text.LineBreakConfig#LINE_BREAK_WORD_STYLE_UNSPECIFIED](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_WORD_STYLE_UNSPECIFIED:kotlin.Int), or[android.graphics.text.LineBreakConfig#LINE_BREAK_WORD_STYLE_AUTO](https://developer.android.com/reference/kotlin/android/graphics/text/LineBreakConfig.html#LINE_BREAK_WORD_STYLE_AUTO:kotlin.Int) |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#setLineBreakWordStyle(int)](https://developer.android.com/reference/kotlin/android/widget/TextView.html#setLineBreakWordStyle(kotlin.Int))  

### setLinkTextColor

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setLinkTextColor(linkTextColor: Int): TextAppearanceInfo.Builder
```

Set the text color used to paint the links in the editor.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#getLinkTextColors()](https://developer.android.com/reference/kotlin/android/widget/TextView.html#getLinkTextColors())  

### setShadowColor

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setShadowColor(shadowColor: Int): TextAppearanceInfo.Builder
```

Set the color of the text shadow.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Paint#setShadowLayer(float, float, float, int)](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#setShadowLayer(kotlin.Float,%20kotlin.Float,%20kotlin.Float,%20kotlin.Int))  

### setShadowDx

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setShadowDx(shadowDx: Float): TextAppearanceInfo.Builder
```

Set the horizontal offset (in pixels) of the text shadow.

|                                                           Parameters                                                           ||
|------------|--------------------------------------------------------------------------------------------------------------------|
| `shadowDx` | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The units of this value are pixels. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Paint#setShadowLayer(float, float, float, int)](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#setShadowLayer(kotlin.Float,%20kotlin.Float,%20kotlin.Float,%20kotlin.Int))  

### setShadowDy

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setShadowDy(shadowDy: Float): TextAppearanceInfo.Builder
```

Set the vertical offset (in pixels) of the text shadow.

|                                                           Parameters                                                           ||
|------------|--------------------------------------------------------------------------------------------------------------------|
| `shadowDy` | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The units of this value are pixels. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Paint#setShadowLayer(float, float, float, int)](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#setShadowLayer(kotlin.Float,%20kotlin.Float,%20kotlin.Float,%20kotlin.Int))  

### setShadowRadius

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setShadowRadius(shadowRadius: Float): TextAppearanceInfo.Builder
```

Set the blur radius (in pixels) of the text shadow.

|                                                             Parameters                                                             ||
|----------------|--------------------------------------------------------------------------------------------------------------------|
| `shadowRadius` | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The units of this value are pixels. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Paint#setShadowLayer(float, float, float, int)](https://developer.android.com/reference/kotlin/android/graphics/Paint.html#setShadowLayer(kotlin.Float,%20kotlin.Float,%20kotlin.Float,%20kotlin.Int))  

### setSystemFontFamilyName

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setSystemFontFamilyName(systemFontFamilyName: String?): TextAppearanceInfo.Builder
```

Set the system font family name if the[Typeface](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#)of the text is created from a system font family.

|                                                             Parameters                                                             ||
|------------------------|------------------------------------------------------------------------------------------------------------|
| `systemFontFamilyName` | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?:This value may be`null`. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Typeface#getSystemFontFamilyName()](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#getSystemFontFamilyName())  

### setTextColor

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setTextColor(textColor: Int): TextAppearanceInfo.Builder
```

Set the current text color of the editor.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.widget.TextView#getCurrentTextColor()](https://developer.android.com/reference/kotlin/android/widget/TextView.html#getCurrentTextColor())  

### setTextFontWeight

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setTextFontWeight(textFontWeight: Int): TextAppearanceInfo.Builder
```

Set the weight of the text.

|                                                                                                                                                                                                                                   Parameters                                                                                                                                                                                                                                    ||
|------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `textFontWeight` | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html):Value is between[android.graphics.fonts.FontStyle#FONT_WEIGHT_UNSPECIFIED](https://developer.android.com/reference/kotlin/android/graphics/fonts/FontStyle.html#FONT_WEIGHT_UNSPECIFIED:kotlin.Int)and[android.graphics.fonts.FontStyle#FONT_WEIGHT_MAX](https://developer.android.com/reference/kotlin/android/graphics/fonts/FontStyle.html#FONT_WEIGHT_MAX:kotlin.Int)inclusive |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

### setTextLocales

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setTextLocales(textLocales: LocaleList): TextAppearanceInfo.Builder
```

Set the[LocaleList](https://developer.android.com/reference/kotlin/android/os/LocaleList.html#)of the text.

|                                                             Parameters                                                              ||
|---------------|----------------------------------------------------------------------------------------------------------------------|
| `textLocales` | [LocaleList](https://developer.android.com/reference/kotlin/android/os/LocaleList.html#):This value cannot be`null`. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

### setTextScaleX

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setTextScaleX(textScaleX: Float): TextAppearanceInfo.Builder
```

Set the extent by which text should be stretched horizontally.

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

### setTextSize

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setTextSize(textSize: Float): TextAppearanceInfo.Builder
```

Set the text size (in pixels) obtained from the current editor.

|                                                           Parameters                                                           ||
|------------|--------------------------------------------------------------------------------------------------------------------|
| `textSize` | [Float](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-float/index.html):The units of this value are pixels. |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

### setTextStyle

Added in[API level 34](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)  

```
fun setTextStyle(textStyle: Int): TextAppearanceInfo.Builder
```

Set the style (normal, bold, italic, bold\|italic) of the text.

|                                                                                                                                                                                                                                                                                                                        Parameters                                                                                                                                                                                                                                                                                                                        ||
|-------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `textStyle` | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html):Value is[android.graphics.Typeface#NORMAL](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#NORMAL:kotlin.Int),[android.graphics.Typeface#BOLD](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#BOLD:kotlin.Int),[android.graphics.Typeface#ITALIC](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#ITALIC:kotlin.Int), or[android.graphics.Typeface#BOLD_ITALIC](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#BOLD_ITALIC:kotlin.Int) |

|                                                                             Return                                                                             ||
|-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| [TextAppearanceInfo.Builder](https://developer.android.com/reference/kotlin/android/view/inputmethod/TextAppearanceInfo.Builder#) | This value cannot be`null`. |

**See Also**

- [android.graphics.Typeface](https://developer.android.com/reference/kotlin/android/graphics/Typeface.html#)