Answer the question
In order to leave comments, you need to log in
How to overcome the loss of text sharpness in WinForms when scaling?
I have a program in C#.
Through the screen settings, increase the scaling to 150%.
Texts with WinForms become blurry while the font of native Windows windows remains sharp. Is it possible to make the texts in the application also not lose clarity when zoomed?
Answer the question
In order to leave comments, you need to log in
Can. For starters, it's a good idea to read this "Difficulties of modern scaling":
Part 1
Part 2
Part 3
Part 4
Part 5
For the rest - you need to put a sign that the application is DpiAware
stackoverflow.com/a/13228495/4758517
stackoverflow.com/questions/4075802/creating -a-dpi...
www.telerik.com/blogs/winforms-scaling-at-large-dp...
well, if you have .NET 4.5.2, then you are more lucky:
www.infoq.com/news /2014/05/DotNet-4-5-2
I solved the problem globally. Added explorer to blur scaling exceptions. At the same time, scaling is also disabled in all other applications.
This is done with the following registry tweak
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers]
"C:\\Windows\\explorer.exe"="~ HIGHDPIAWARE"
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question