How to make a WPF application the same in both Windows classic style and windows XP style?
I have written a app in WPF. And I am using standard BlueTheme available on microsoft website for my application. The application looks great in Windows XP which is having Windows XP style. In the screenshot below we can see the buttons with round edges and evrything.
开发者_StackOverflow社区Screenshot 1 (Windows XP style):
I then right clciked on my desktop and went to appearance and chose windows classic style. Then the application looks crap. All the buttons are now having square edges.
Screenshot 2 (Windows classic style):
I think searched in internet and people had suggested to include PresentationFramework.Aero theme. But still the problem persists.
[Edits] I have added the below line. Still it doesn't work !
<Window.Resources>
<ResourceDictionary Source="/PresentationFramework.Aero, Version=3.0.0.0, Culture=neutral,
PublicKeyToken=31bf3856ad364e35, ProcessorArchitecture=MSIL;component/themes/aero.normalcolor.xaml" />
</Window.Resources>
My question is How to make a WPF application the same in both Windows classic style and windows XP style ?
Put this into your Window/Application resources:
<Window.Resources>
<ResourceDictionary Source="/PresentationFramework.Aero, Version=3.0.0.0, Culture=neutral,
PublicKeyToken=31bf3856ad364e35, ProcessorArchitecture=MSIL;component/themes/aero.normalcolor.xaml" />
</Window.Resources>
It will enable Aero style with other Windows themes (XP/Classic).
精彩评论