# UpdateAppearance

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

# UpdateAppearance

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/android/text/style/UpdateAppearance "View this page in Java")  

```
interface UpdateAppearance
```

|----------------------------------------------------------------------------------------------------------------------------|
| [android.text.style.UpdateAppearance](https://developer.android.com/reference/kotlin/android/text/style/UpdateAppearance#) |

|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Known Direct Subclasses [BackgroundColorSpan](https://developer.android.com/reference/kotlin/android/text/style/BackgroundColorSpan),[ClickableSpan](https://developer.android.com/reference/kotlin/android/text/style/ClickableSpan),[ForegroundColorSpan](https://developer.android.com/reference/kotlin/android/text/style/ForegroundColorSpan),[MaskFilterSpan](https://developer.android.com/reference/kotlin/android/text/style/MaskFilterSpan),[StrikethroughSpan](https://developer.android.com/reference/kotlin/android/text/style/StrikethroughSpan),[UnderlineSpan](https://developer.android.com/reference/kotlin/android/text/style/UnderlineSpan),[UpdateLayout](https://developer.android.com/reference/kotlin/android/text/style/UpdateLayout) |--------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------| | [BackgroundColorSpan](https://developer.android.com/reference/kotlin/android/text/style/BackgroundColorSpan) | Changes the background color of the text to which the span is attached.                                                                                         | | [ClickableSpan](https://developer.android.com/reference/kotlin/android/text/style/ClickableSpan)             | If an object of this type is attached to the text of a TextView with a movement method of LinkMovementMethod, the affected spans of text can be selected.       | | [ForegroundColorSpan](https://developer.android.com/reference/kotlin/android/text/style/ForegroundColorSpan) | Changes the color of the text to which the span is attached.                                                                                                    | | [MaskFilterSpan](https://developer.android.com/reference/kotlin/android/text/style/MaskFilterSpan)           | Span that allows setting a[MaskFilter](https://developer.android.com/reference/kotlin/android/graphics/MaskFilter.html#)to the text it's attached to.           | | [StrikethroughSpan](https://developer.android.com/reference/kotlin/android/text/style/StrikethroughSpan)     | A span that strikes through the text it's attached to.                                                                                                          | | [UnderlineSpan](https://developer.android.com/reference/kotlin/android/text/style/UnderlineSpan)             | A span that underlines the text it's attached to.                                                                                                               | | [UpdateLayout](https://developer.android.com/reference/kotlin/android/text/style/UpdateLayout)               | The classes that affect character-level text formatting in a way that triggers a text layout update when one is added or removed must implement this interface. | |

|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Known Indirect Subclasses [AbsoluteSizeSpan](https://developer.android.com/reference/kotlin/android/text/style/AbsoluteSizeSpan),[DynamicDrawableSpan](https://developer.android.com/reference/kotlin/android/text/style/DynamicDrawableSpan),[ImageSpan](https://developer.android.com/reference/kotlin/android/text/style/ImageSpan),[LocaleSpan](https://developer.android.com/reference/kotlin/android/text/style/LocaleSpan),[MetricAffectingSpan](https://developer.android.com/reference/kotlin/android/text/style/MetricAffectingSpan),[RelativeSizeSpan](https://developer.android.com/reference/kotlin/android/text/style/RelativeSizeSpan),[ReplacementSpan](https://developer.android.com/reference/kotlin/android/text/style/ReplacementSpan),[ScaleXSpan](https://developer.android.com/reference/kotlin/android/text/style/ScaleXSpan),[StyleSpan](https://developer.android.com/reference/kotlin/android/text/style/StyleSpan),[SubscriptSpan](https://developer.android.com/reference/kotlin/android/text/style/SubscriptSpan),[SuperscriptSpan](https://developer.android.com/reference/kotlin/android/text/style/SuperscriptSpan),[TextAppearanceSpan](https://developer.android.com/reference/kotlin/android/text/style/TextAppearanceSpan), and 3 others. |-----------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [AbsoluteSizeSpan](https://developer.android.com/reference/kotlin/android/text/style/AbsoluteSizeSpan)                            | A span that changes the size of the text it's attached to.                                                                                                                                                                              | | [DynamicDrawableSpan](https://developer.android.com/reference/kotlin/android/text/style/DynamicDrawableSpan)                      | Span that replaces the text it's attached to with a[Drawable](https://developer.android.com/reference/kotlin/android/graphics/drawable/Drawable.html#)that can be aligned with the bottom or with the baseline of the surrounding text. | | [ImageSpan](https://developer.android.com/reference/kotlin/android/text/style/ImageSpan)                                          | Span that replaces the text it's attached to with a[Drawable](https://developer.android.com/reference/kotlin/android/graphics/drawable/Drawable.html#)that can be aligned with the bottom or with the baseline of the surrounding text. | | [LocaleSpan](https://developer.android.com/reference/kotlin/android/text/style/LocaleSpan)                                        | Changes the[Locale](https://developer.android.com/reference/kotlin/java/util/Locale.html#)of the text to which the span is attached.                                                                                                    | | [MetricAffectingSpan](https://developer.android.com/reference/kotlin/android/text/style/MetricAffectingSpan)                      | The classes that affect character-level text formatting in a way that changes the width or height of characters extend this class.                                                                                                      | | [RelativeSizeSpan](https://developer.android.com/reference/kotlin/android/text/style/RelativeSizeSpan)                            | Uniformly scales the size of the text to which it's attached by a certain proportion.                                                                                                                                                   | | [ReplacementSpan](https://developer.android.com/reference/kotlin/android/text/style/ReplacementSpan)                              | <br />                                                                                                                                                                                                                                  | | [ScaleXSpan](https://developer.android.com/reference/kotlin/android/text/style/ScaleXSpan)                                        | Scales horizontally the size of the text to which it's attached by a certain factor.                                                                                                                                                    | | [StyleSpan](https://developer.android.com/reference/kotlin/android/text/style/StyleSpan)                                          | Span that allows setting the style of the text it's attached to.                                                                                                                                                                        | | [SubscriptSpan](https://developer.android.com/reference/kotlin/android/text/style/SubscriptSpan)                                  | The span that moves the position of the text baseline lower.                                                                                                                                                                            | | [SuperscriptSpan](https://developer.android.com/reference/kotlin/android/text/style/SuperscriptSpan)                              | The span that moves the position of the text baseline higher.                                                                                                                                                                           | | [TextAppearanceSpan](https://developer.android.com/reference/kotlin/android/text/style/TextAppearanceSpan)                        | Sets the text appearance using the given[TextAppearance](https://developer.android.com/reference/kotlin/android/R.styleable.html#TextAppearance:kotlin.IntArray)attributes.                                                             | | [TextLinks.TextLinkSpan](https://developer.android.com/reference/kotlin/android/view/textclassifier/TextLinks.TextLinkSpan.html#) | A ClickableSpan for a TextLink.                                                                                                                                                                                                         | | [TypefaceSpan](https://developer.android.com/reference/kotlin/android/text/style/TypefaceSpan)                                    | Span that updates the typeface of the text it's attached to.                                                                                                                                                                            | | [URLSpan](https://developer.android.com/reference/kotlin/android/text/style/URLSpan)                                              | Implementation of the[ClickableSpan](https://developer.android.com/reference/kotlin/android/text/style/ClickableSpan)that allows setting a url string.                                                                                  | |

The classes that affect character-level text in a way that modifies their appearance when one is added or removed must implement this interface. Note that if the class also impacts size or other metrics, it should instead implement[UpdateLayout](https://developer.android.com/reference/kotlin/android/text/style/UpdateLayout).

## Summary