Ticket #532 (closed defect: fixed)
[PATCH] GUI resolution incorrect when screen smaller than requested window size
| Reported by: | Philip | Owned by: | sergiovier |
|---|---|---|---|
| Priority: | Nice to Have | Milestone: | Alpha 4 |
| Component: | Core engine | Keywords: | simple, review |
| Cc: |
Description
Steps to reproduce:
- Optionally set up a .cfg file to start the game in windowed mode with a certain xres/yres (else the default is 1024x768).
- Set display resolution to smaller than that size.
- Start the game.
The initial window is shrunk to fit on the screen, but the game renders everything at the configured size instead (so the menu screen is partially off the side of the screen). It should detect this kind of situation and update things to fit.
(ps/VideoMode.cpp is probably a relevant place to look for this.)
Attachments
Change History
comment:2 Changed 3 years ago by anonymous
- Milestone Unclassified deleted
Milestone Unclassified deleted
comment:8 Changed 2 years ago by sergiovier
- Keywords simple, review added; simple removed
if not misunderstood, this patch fix the resolution problem (i've tested in linux)
Changed 2 years ago by sergiovier
- Attachment incorrect-resolution.patch added
fix resolution when we have wrong values
comment:9 Changed 2 years ago by k776
- Summary changed from GUI resolution incorrect when screen smaller than requested window size to [PATCH] GUI resolution incorrect when screen smaller than requested window size
comment:10 follow-up: ↓ 11 Changed 2 years ago by Philip
Hrm... Were you able to reproduce the bug before applying this patch? I tried it on Linux and Windows and couldn't get this bug - the window was shrunk to fit the screen and the main menu GUI rendered correctly. It's possible it was fixed by r8072 from #544. Did you still get that problem? (Or maybe a slightly different problem where the window wasn't shrunk to fit, or something? I don't know why that would happen but it looks like the patch would fix that too.)
comment:11 in reply to: ↑ 10 Changed 2 years ago by sergiovier
When i set up my desktop resolution to 960x600, config the game to start in windowed mode and default resolution is 1024x768, I get this at just the start of the game (it's a capture of all my desktop, without touch anything).
Replying to Philip:
Hrm... Were you able to reproduce the bug before applying this patch? I tried it on Linux and Windows and couldn't get this bug - the window was shrunk to fit the screen and the main menu GUI rendered correctly. It's possible it was fixed by r8072 from #544. Did you still get that problem? (Or maybe a slightly different problem where the window wasn't shrunk to fit, or something? I don't know why that would happen but it looks like the patch would fix that too.)
comment:12 Changed 2 years ago by philip
- Status changed from new to closed
- Resolution set to fixed

This may have been fixed in #544.