C# WPF VS2017 - Forcing Aero theme -


i'm trying fix rendering issue wpf app (a screensaver) wrote using vs2015 on windows 7.

on windows 10, config window looks totally different and, more importantly, it's useless because of how renders in windows 10.

here screenshots. first, windows 7

enter image description here

and windows 10

enter image description here

while there lots of little differences, , expect that, what's unforgivable coloring , cut off controls. check boxes checked , can't tell. radio buttons selected , can't tell. can't see bottom control. it's garbage.

i did research , found override theme, forcing use of aero. don't know if fix problem , i'm having trouble making work.

according research, if add following app.xaml, may fix things.

<application.resources>      <resourcedictionary source="/presentationframework.aero;component/themes/aero.normalcolor.xaml" />      <resourcedictionary source="pack://application:,,,/wpftoolkit;component/themes/aero.normalcolor.xaml" /> </application.resources> 

but, doing gives me warning in vs2017:

the property "resources" can set once.

so, can't test it. have yet find way around this. how make work?

---------- update 1 ----------

with comments got to:

<application.resources>     <resourcedictionary>         <resourcedictionary.mergeddictionaries>             <resourcedictionary source="/presentationframework.aero;component/themes/aero.normalcolor.xaml" />         </resourcedictionary.mergeddictionaries>     </resourcedictionary> </application.resources> 

however, app not run @ all.

your app has entered break state, there no code show because threads executing external code (typically system or framework code).

original source on github

you hard coding size of config window.

 height="358" width="300" 

that's not going render correctly on modern os's, user has changed dpi scaling.

in case might better use window sizetocontent property

sizetocontent="widthandheight" 

sizetocontent documentation


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -