TheInfiniteKind / moneydance_open

17 stars 12 forks source link

Fix saved window positions offscreen (left) with negative values #89

Closed yogi1967 closed 9 months ago

yogi1967 commented 2 years ago

Recently you’ve fixed several offscreen and invalid (too small) window size issues (that cause users’ screens to ‘freeze’)… There is still one last issue that is plaguing windows/Linux users (Mac/VAQua copes with it and doesn’t present the issue)… seems to have impacted several users in the last few weeks. When reconciling (for example), the window is off-screen and appears frozen. An example set of keys that cause this are: "gui.is_maximized-reconcile_win" = "n" "gui.prereconcile_location" = "-1429x-77" "gui.prereconcile_size" = "399x213" "gui.winloc-reconcile_win" = "-1900x-108" "gui.winsize-reconcile_win" = "932x1026" So the one issue remaining is NEGATIVE positions.. (The lockup won’t happen on Mac)…. The fixes made thus far are positive positions offscreen right, these are negative positions offscreen left….. So the fixed code: com.moneydance.awt.AwtUtil.setupWindow(Window, int, int, int, int, Component) : void needs tweaking to also check for something like:

if (x < virtualBounds.x or y < virtualBounds.y)

too. The existing checks are fine, so this is an additional test…. Possible..? It would be good to finalise this issue for once and for all. It's very easy to test with the keys I provided above on Windows (not Mac).

yogi1967 commented 9 months ago

Hmmm, appears the code was fixed 6th August 2022... Needs retesting.....

yogi1967 commented 9 months ago

Closing this (for now), as I think it's resolved.. Let's see if anyone else gets this when using 2023 or later....