Page 1 of 1

BUG: TokenTool saves window coordinates off the screen

Posted: Sun Mar 10, 2019 12:03 pm
by RevenantBob
Infrequently (And I'm not sure how I manage to recreate it) token tool will save window coordinates in the windows registry way off the screen. Fixing it requires me to go into the registry and update the values so it will load back on screen again. I have a Windows 10 machine with dual monitors. Not sure if that has anything to do with it (My Java knowledge is limited) but maybe some check to ensure the window is within the desktop area when it loads is in order?

The registry values that get saved are in the key: HKEY_CURRENT_USER\Software\JavaSoft\Prefs\net\rptools\tokentool\client
window_x = -32000.0
window_y = -32000.0

So maybe that can help track the issue.

Re: BUG: TokenTool saves window coordinates off the screen

Posted: Sun Mar 10, 2019 1:13 pm
by Full Bleed
RevenantBob wrote:
Sun Mar 10, 2019 12:03 pm
Infrequently (And I'm not sure how I manage to recreate it) token tool will save window coordinates in the windows registry way off the screen...

I have a Windows 10 machine with dual monitors. Not sure if that has anything to do with it...
Do you *always* have both monitors on and in the same configuration when using the app?

Also, take note of what other apps you have running when the issue occurs (and note if they are windowed or full screen, etc.)

Re: BUG: TokenTool saves window coordinates off the screen

Posted: Sun Apr 07, 2019 3:20 am
by RevenantBob
I don't reconfigure monitors, no. And I do tend to use it maximized, yes. The coordinates that I see in registry are not valid. Even if my monitor were moving. 1080p monitors won't come up with a value of -32000 as valid coordinates. I'm trying to figure out the alchemy that causes the problem because it's not every time.

Re: BUG: TokenTool saves window coordinates off the screen

Posted: Sun Apr 07, 2019 9:35 am
by Phergus
But opened on GitHub.

https://github.com/RPTools/TokenTool/issues/35

Add any other comments you feel are relevant.

Re: BUG: TokenTool saves window coordinates off the screen

Posted: Mon Oct 07, 2019 12:49 am
by RevenantBob
This is still happening. I'm going to dig through the source code and see if I can't figure out why it's happening. Maybe make a PR or something for it.

Re: BUG: TokenTool saves window coordinates off the screen

Posted: Mon Oct 07, 2019 9:53 am
by Phergus
Have at it!