1

I'm trying to use an elementhost in my child form but it distorts my parent form. Tried to refresh and minimize/maximize the parent form but doesn't work. Take note this only happens when I'm in 150% display resolution. (you will need to change to 150% display then restart in order for this to replicate.)

Parent form being distorted when opening child form with element host enter image description here

Ric
  • 11
  • 5
  • How is it distorted exactly? Can you post an image of what you are expecting it to look like? – vesan Jun 14 '18 at 04:48
  • @vesan the parent form(smaller window) supposed to have the same font size as the child form (Front window) – Ric Jun 14 '18 at 06:28
  • Hosting Wpf controls (thus referencing Wpf assemblies), can cause you application to become Dpi Aware. And since it can... I wrote a description of this behaviour [in this SO question](https://stackoverflow.com/questions/50239138/dpi-awareness-unaware-in-one-release-system-aware-in-the-other?answertab=active#tab-top). See also the duplicate question marked by Hans Passant for handling it. – Jimi Jun 14 '18 at 06:39
  • @Jimi Cool! the manifest or pinvoke works! Thanks a lot! – Ric Jun 14 '18 at 06:51

0 Answers0