iOS Text Size Change Notification


Example

You can register for notifications of when the device text size is changed.

Swift

NSNotificationCenter.defaultCenter().addObserver(self, selector: #selector(updateFont), name: name:UIContentSizeCategoryDidChangeNotification, object: nil)

Objective-C

[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(updateFont) name:UIContentSizeCategoryDidChangeNotification object:nil];

The notification userInfo object contains the new size under UIContentSizeCategoryNewValueKey.