WPF: Windows 7 vs Windows 10 Appearance -


i have annoying appearance differences between windows 10 devices , windows 7 devices.

i using windowstyle="none" , dockpanel directly inside window element.

what don't why there still border? why borders on buttons, textboxes, comboboxes, etc. rounded?

it seems related aero. there way can stop application using aero? i'm assuming there presentation framework related windows 10 not know called force it.

would borderbrush easiest way resolve this?

<window x:class="cbd.presentation.mainwindow"         xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"         xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"         xmlns:local="clr-namespace:cbd.presentation"         title="cbd" height="760" width="944" windowstartuplocation="centerscreen"         windowstyle="none" sizechanged="window_sizechanged" minwidth="944" minheight="760"         icon="favicon.ico">     <dockpanel x:name="root_window" background="black">         <!--application stuff here -->     </dockpanel> </window> 

windows 7 display: windows 7 display

windows 10 display:

windows 10 display

everything still functions way textboxes , buttons setup, parts of letters missing.

i think both these lot of people going stumble upon when start customizing style of applications. there's established shortcuts both problems, such using existing style/libraries wpf:

there's few common window , style libraries see:

  • mahapps.metro great library i've used long time getting clean windows , interfaces (especially 'dark' themes customers love).
  • modern ui. little personal experience, it's similar in has more modern window designs, big style set. i've seen used frequently.
  • elysium. again, not experience, seems active. i've not seen used as other two.

these, of course, include lot of other metro theming. there other theme packs available, i've found material design in xaml toolkit great if client want's cutting edge of modern design (also recognizable, being google).

it looks you're making style scratch, above might still useful use windows. if want go @ there's lengthy discussion lot's of answers here.

for curved corners, discussed in comments, result of wpf's default behavior on different operating systems. attempts select default style blend in best current operating system. applications use default theme, doesn't matter.

when you're styling though, plays havoc have manually configured, because properties work theme set things on might different - rounded corners.

there's 2 options.

  1. explicitly set properties, looks how want it. doing means if 'base' theme changes, still good. how libraries above things - define style completely. problem have test on different themes manually , it's bit of work.
  2. manually set base theme. (can used testing in option 1!) can override theme app uses manually rather letting use default operating system in same way apply other custom themes, or maybe own:
<app.resources>   <resourcedictionary source="/presentationframework.aero, version=3.0.0.0,       culture=neutral, publickeytoken=31bf3856ad364e35,       processorarchitecture=msil;component/themes/aero.normalcolor.xaml"/> </app.resources> 

for reason above not appear code unless encased in quotes...


Comments

Popular posts from this blog

Spring Boot + JPA + Hibernate: Unable to locate persister -

go - Golang: panic: runtime error: invalid memory address or nil pointer dereference using bufio.Scanner -

c - double free or corruption (fasttop) -