picoe / Eto

Cross platform GUI framework for desktop and mobile applications in .NET
Other
3.62k stars 328 forks source link

[WPF on Win7] Dialogs appear with negative location #2613

Open Serg-Norseman opened 8 months ago

Serg-Norseman commented 8 months ago

Expected Behavior

The dialog appears centered relative to the parent window or screen.

Actual Behavior

Dialogs appear with negative location on Win7. And exactly so that half the height and width are outside the upper left corner.

Maybe this will tell you something: when debugging, the width and height of the dialog are equal to 0, not only during OnLoad, OnLoadComplete, etc. - as in other Windows, but also after OnShown (when testing on Windows 10, the correct width and height are already present in the OnShown event).

Steps to Reproduce the Problem

Show any dialog on Windows 7.

Specifications

cwensley commented 8 months ago

Hm, Windows 7 hasn't been supported by Microsoft since 2020. I'll accept PR's but I can't quite support this myself as I don't even have access to a Windows 7 machine or VM anymore.

Serg-Norseman commented 8 months ago

Yes, I know about the end of support. But:

  1. Users write despite this. I can’t explain to everyone and point out that Microsoft has decided something there. And many people continue to work on 7 (3% is still a bit much)...
  2. The problem itself is strange, that after any event there is no real size of the window or dialog. They are already displayed here - right before eyes, only with an offset. And zeros are written to the event log.

I have been fighting off users with this problem for a long time, more than a year. I couldn't test it myself for a long time. I had to fix my old travel laptop, which had Win7 :)