Is there a way to know if the text size is at 125% from .NET/C#?
The setting comes from Control Panel\Appearance and Personalization\Display ...
Is there a way to know if the text size is at 125% from .NET/C#?
The setting comes from Control Panel\Appearance and Personalization\Display ...
I haven´t tried this my self.
This registry key in windows pre Windows 7:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontDPI:LogPixels
And this one in Windows 7:
HKEY_CURRENT_USER\Control Panel\Desktop:LogPixels
All according to this thread in MSDN Forum
Here is some additional resources:
Creating a DPI-Aware Application
http://stackoverflow.com/questions/572820
http://stackoverflow.com/questions/572270
I'm not sure but maybe you can just get the Dpi settings and check if they're 96 or not:
using(Graphics g = this.CreateGraphics())
{
MessageBox.Show(g.DpiX.ToString() + Environment.NewLine + g.DpiY.ToString());
}
You might have to call SetProcessDPIAware
first though.