So, I just switched to Windows 10 and I noticed all my desktop WPF
applications are noticeably "uglier" than they where on Win7/Win8.
I know this sounds subjective/pointless, but let me be more precise. Here's some examples of objective degradation of the UI's usability/clarity:
button
s do not get flattened (again, see image) ListView
items are not highlighted on mouseOver ProgressBar
s have the "blue segments" pre-XP look EDIT:
After testing on another machine, turns out the problem had nothing to do with WPF or Windows.
Just DON'T apply any tweaks for win10 you find on the internet to restore the coloring on windows borders. It messes up the WPF theme engine.
Sorry for wasting your time guys.
Well, I found out how to fix it (thanks to gix for pointing me in the right direction):
First step: reference the PresentationFramework.Aero2
assembly in your projectSecond step: add the following to your App.xaml
<Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="/PresentationFramework.Aero2;component/themes/Aero2.NormalColor.xaml" /> </ResourceDictionary.MergedDictionaries> </ResourceDictionary> </Application.Resources>
Now it looks like it does in Windows 8. Note that you can also use Aero
instead of Aero2
if you want the Windows 7 look (also change the referenced dll of course!), but I think Aero2
looks much more "native" on Win10.
EDIT: After further testing, turns out this is not 100% perfect, although it's close enough. For example: disabled text boxes are not grayed out, and ListView
s seems to not be affected at all, they still look like they crawled out of Windows 98's ass... if anyone has a clue on how to make the Aero2 style stick to them as well it would be great
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.