Transfer old user window size settings to new system

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: Transfer old user window size settings to new system

Re: Transfer old user window size settings to new system

by Graf Zahl » Sun Mar 15, 2020 2:31 am

I don't think that after almost two years with the new windowing system there's any need for this left.

Re: Transfer old user window size settings to new system

by Graf Zahl » Sun Jul 22, 2018 11:03 am

Yes, they include the window borders.

Re: Transfer old user window size settings to new system

by Kinsie » Sun Jul 22, 2018 10:09 am

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

by Graf Zahl » Sun Jul 22, 2018 9:19 am

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.

Transfer old user window size settings to new system

by Kinsie » Sun Jul 22, 2018 7:08 am

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?)

Top