WPF App window borders don't work properly on a 2nd monitor

  • Thread starter Thread starter K24A3
  • Start date Start date
K

K24A3

Guest
I have two WPF apps:

App using 4.6.1 - uses the standard WPF window.
When on the primary monitor the borders are visible on all four sides. (OK)
When on the secondary monitor and normal window, the borders are only visible at the top and left. (NG)
When on the secondary monitor and maximized, the borders are only visible at the top and left. (NG)

App using 4.5 - uses the WindowStyle.SingleBorderWindow style when normal, but when it goes fullscreen it changes to WindowStyle.None;
When on the primary monitor all four borders are visible when normal. (OK)
When on the primary monitor none of the four borders are visible when maximized. (OK)

When on the secondary monitor only the top and left borders are visible when normal. (NG)
When on the secondary monitor only the top border is visible when maximized. (NG)


I tried some of my other WPF apps, they are also missing the right and bottom border. I'm not using fancy skins or XAML resources styles in all these apps.
I tried Margin="-1,-2,0,0" on the main window grid but it made no difference.

I tested some other apps:

Handbrake = ok
Agent Ransack = same as my 4.6.1 app (is this also a WPF app?)
File Explorer = ok
Visual Studio = ok
Windows Calculator = ok
Audacity = ok

Can anyone else replicate this behavior using WPF apps?


Win 10 Pro v2004
nVidia RTX 2080, tried drivers 446.14 and 451.67 = latest
Primary = 3440x1440 Monitor
Secondary = 1920x1080 Projector

Continue reading...
 
Back
Top