See the question and my original answer on StackOverflow

For the "Make everything bigger" section, you can use GetScaleFactorForMonitor

Gets the scale factor of a specific monitor.

For the "Make text bigger" section, you can use a WinRT static property: UISettings.TextScaleFactor

Gets the value of the system text size setting.

Otherwise the latter can also be read using the TextScaleFactor DWORD attribute in the HKEY_CURRENT_USER\SOFTWARE\Microsoft\Accessibility registry key (but this is not officially documented).