public static double GetWindowsScaling() { var mainForm = System.Windows.Forms.Application.OpenForms[0]; return (mainForm?.DeviceDpi ?? 96) / 96.0; }
852600cookie-checkC# Get Windows Screen Scaling
public static double GetWindowsScaling() { var mainForm = System.Windows.Forms.Application.OpenForms[0]; return (mainForm?.DeviceDpi ?? 96) / 96.0; }