Page 1 of 1

Transfer old user window size settings to new system

PostPosted: Sun Jul 22, 2018 8:08 am
by Kinsie
Now that the new devbuild is out I can confirm that vid_setsize works. However, I also noticed that since the old vid_defwidth/defheight settings no longer seem to be read or updated (beyond being set to defaults at startup if they don't exist), the window will still be tiny on first boot until a new size is setup, which likely won't please people who don't religiously browse the bugs forum and know what's up. Since these old CVars don't seem to be used anymore, there might be merit to checking the INI for their existence on startup, then using them as the base for a vid_setsize command so as to neatly transition the user's settings to the new system. That'd likely take a bit of twiddling to ensure it only happens once, though.

(Speaking of the new system, I couldn't see a place in the INI where the new settings are saved, and a quick glance over the commits didn't enlighten me. Is this a registry thing, or something more obvious that I'm somehow missing?)

Re: Transfer old user window size settings to new system

PostPosted: Sun Jul 22, 2018 10:19 am
by Graf Zahl
There is nothing new. It just uses the old win_x/y/w/h CVARs to store the non-fullscreen window size.
And yes, vid_defwidth/vid_defheight somehow need to be transferred but it's not that easy because it cannot be safely determined whether they just contain leftover data for fullscreen or an actual window size. Another problem with the old code was that although it saved the window size, the code was rather broken and tended to overwrite valid settings with invalid ones - and this is most likely the reason why you get that tiny window.

Re: Transfer old user window size settings to new system

PostPosted: Sun Jul 22, 2018 11:09 am
by Kinsie
Graf Zahl wrote:There is nothing new. It just uses the old win_x/y/w/h CVARs to store the non-fullscreen window size.
That'd explain why I couldn't find it - I was searching for my vertical windowed resolution (720) and seeing what popped up, and that's not how the win_ cvars seem to work. v :P v

Re: Transfer old user window size settings to new system

PostPosted: Sun Jul 22, 2018 12:03 pm
by Graf Zahl
Yes, they include the window borders.