Skip to content

Android Oreo allows you to instruct a TextView to let the size of the text expand or contract automatically to fill its layout based on the TextView's characteristics and boundaries.

License

Notifications You must be signed in to change notification settings

1priyank1/AutosizingTextViews-Demo

Repository files navigation

AutosizingTextViews-Demo

Android Oreo (OS Version 8.0 & API level 26) allows you to instruct a TextView to let the size of the text expand or contract automatically to fill its layout based on the TextView's characteristics and boundaries. This setting makes it easier to optimize the text size on different screens with dynamic content.

Screenshot AutosizingTextViews-Demo

Setting up TextView autosize

You can set up the TextView autosizing in either code or XML. There are two ways you can set it up:

1. Granularity

Granularity AutosizingTextViews-Demo Granularity AutosizingTextViews-Demo

2. Preset Sizes

Preset Sizes AutosizingTextViews-Demo Granularity AutosizingTextViews-Demo

About

Android Oreo allows you to instruct a TextView to let the size of the text expand or contract automatically to fill its layout based on the TextView's characteristics and boundaries.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages