Gallal
Gallal

Reputation: 4262

Detect if "Large Text" accessibility option is enabled on Android

How can I programatically detect if "Large Text" accessibility option is enabled on Android?

Upvotes: 18

Views: 4346

Answers (1)

nandeesh
nandeesh

Reputation: 24820

if Large Text is set, android changes the font scale , so you can detect using

Configuration c = getResources().getConfiguration();
float scale = c.fontScale;

if scale is greater than 1 then it is large text.

Upvotes: 38

Related Questions