Sizing the font inside a
TextView is one issue that arises often when building an app. Since the app will run on many devices with various screen sizes, it could look awkward on some devices if we use the same font size for all the devices. There are many ways to set the size of the font inside a
TextView so that the text fits well. We explore how to set it so that the text fits in one line and the font size is maximal. We assume that there is no padding inside the
We build a utility class,
DynamicSizing, that includes ...