Warzone2100 / old-trac-import

Archived Import of (old) Warzone 2100 Trac
0 stars 0 forks source link

Fullscreen mode is still windowed in QT #2711

Closed wzdev-ci closed 13 years ago

wzdev-ci commented 13 years ago

keyword_fullscreen_window resolution_fixed type_bug | by Dekker3D


Setting a git build to fullscreen mode in Ubuntu 11.04, running Gnome 2, still has the game running in windowed mode.


Issue migrated from trac:2711 at 2022-04-16 08:08:15 -0700

wzdev-ci commented 13 years ago

Per commented


Do other fullscreen apps work? Does a simple fullscreen Qt test program work?

wzdev-ci commented 13 years ago

anonymous commented


A version of Warzone that I grabbed off a PPA, last updated in late 2010 or something, does work in fullscreen. It's hard to make it do anything else, really. Sauerbraten also works in fullscreen by default. I don't have any QT test app to try fullscreen with at the moment though.

wzdev-ci commented 13 years ago

Dekker3D commented


Replying to Warzone2100/old-trac-import#2711 (comment:2):

A version of Warzone that I grabbed off a PPA, last updated in late 2010 or something, does work in fullscreen. It's hard to make it do anything else, really. Sauerbraten also works in fullscreen by default. I don't have any QT test app to try fullscreen with at the moment though.

Comment made by me. I didn't notice I had been logged out again.

wzdev-ci commented 13 years ago

Dekker3D commented


I have found the problem: mainwindow.setMaximumSize(w, h); is called right before showFullScreen(); preventing the screen from reaching the appropriate size and thus, going fullscreen. setMinimumSize(w, h); is also called, most likely causing showFullScreen(); to also fail when the window resolution equals the desktop resolution. Not sure how that would work, but it could be the problem.

One remaining problem is that this fullscreen mode does not respect secondary monitors. This may be fixed using QApplication::desktop()->getNumScreens(); and similar functions for finding out the total screen space available.

wzdev-ci commented 13 years ago

Fastdeath changed status from new to closed

wzdev-ci commented 13 years ago

Fastdeath changed resolution from ` tofixed`

wzdev-ci commented 13 years ago

dak180 changed _comment0 which not transferred by tractive

wzdev-ci commented 13 years ago

Fastdeath commented


Dekker3D fixed it, see:

https://github.com/Warzone2100/warzone2100/commit/b808220f9b9338605ac1765640d5ce5a0ff5f6b9 and https://github.com/Warzone2100/warzone2100/commit/a0ed219ad70608ae6e7a4d45ed5de032625416ac

wzdev-ci commented 13 years ago

aberent changed status from closed to reopened

wzdev-ci commented 13 years ago

aberent changed resolution from fixed to ``

wzdev-ci commented 13 years ago

aberent changed _comment0 which not transferred by tractive

wzdev-ci commented 13 years ago

aberent changed _comment1 which not transferred by tractive

wzdev-ci commented 13 years ago

aberent changed _comment2 which not transferred by tractive

wzdev-ci commented 13 years ago

aberent commented


This still isn't working correctly on Ubuntu 11.04. With today's (3rd July) git/master I get a window whether or not I run in "fullscreen" mode. The problem seems to be that mainwindow.show() is called before mainwindow.showFullScreen(), and this causes the showFullScreen() to be ignored.

I have submitted a patch to fix this, and also ensuring that the resolution is correct in fullscreen mode, in pull request https://github.com/Warzone2100/warzone2100/pull/14

wzdev-ci commented 13 years ago

Anthony Berent changed status from reopened to closed

wzdev-ci commented 13 years ago

Anthony Berent changed resolution from ` tofixed`

wzdev-ci commented 13 years ago

Anthony Berent commented


Fix fullscreen display on Linux: 1) Avoid calling mainwindow.show() before mainwindow.showFullScreen() since the show() call seems to disable the showFullScreen() call. 2) resize the window before calling showFullScreen() since showFullScreen() takes the resolution from the size of the window, which is not yet set (and defaults to VGA size). 3) After showFullScreen() get back the actual size; I am not sure if this is necessary, but the resize() documentation suggests it may be.

Fixes #2711

wzdev-ci commented 13 years ago

Per Inge Mathisen commented


Merge pull request #14 from aberent/fullscreen

Fix fullscreen display on Linux. Patch by aberent. Closes #2711