FS#642 - 0.5.0-RC5 Resolution doubled in cfg file when fullscreen mode used

Attached to Project: OpenTTD
Opened by Mardu (Mardu) - Wednesday, 21 February 2007, 22:15 GMT
Type Bug
Category Core
Status Closed
Assigned To No-one
Operating System Windows
Severity Medium
Priority Normal
Reported Version trunk
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No


I have a resolution of 1280x1024. Whenever I start the game, it starts in windowed mode. Every time I have to change the resolution in-game to 1280x1024, and click the fullscreen button, to make the game go fullscreen. When I exit the game, and start it again, it uses windowed mode again, and window is positioned in the upper left corner of the display, with about a half of it being not visible. Then the resolution has to be changed and fullscreen button pressed again.

When I look in the openttd.cfg file, the resolution is doubled - fullscreen = true; resolution = 2560,2048.
When fullscreen mode is NOT used, it saves the max resolution the window is allowed to have to be visible, that is almost 1280x1024, into the configuration file.
When using resolutions lower than mine
a) if fullscreen is used, saves double resolution again
b) if fullscreen is not used, saves the normal resolution
The problem started when I upgraded to 0.5.0-RC5 from 0.4.8.

It is pretty annoying to change the resolution every time I start the game.
This task depends upon

Closed by  Darkvater (Darkvater)
Saturday, 03 March 2007, 13:07 GMT
Reason for closing:  Fixed
Additional comments about closing:  fixed, thank you for your report.
Comment by Mardu (Mardu) - Friday, 23 February 2007, 00:32 GMT
Found out what was causing this - double size.
As I have understood, double size should only work in windowed mode, well, it does, but the wrong resolution is saved when in fullscreen mode.