bvschaik / julius

An open source re-implementation of Caesar III
GNU Affero General Public License v3.0
2.82k stars 315 forks source link

When windowed is enabled once, it is always enabled #716

Closed dotnetCarpenter closed 8 months ago

dotnetCarpenter commented 8 months ago

Using Julius version 1.7.0-20240115-bd0d26f.

I have connected my laptop to a second monitor and to get C3 to display on the second monitor, I needed to use the --windowed mode. I started julius with ./julius --windowed

Unfortunately after that, C3 is always in windowed mode. Is there anyway to disable windowed mode or is it a bug?

OS: Linux Debian 6.5.6-1kali1 (2023-10-09) Display Server: X11 X.Org version: 21.1.10 SDL: libsdl2-2.0-0:amd64 2.28.5+dfsg-3

dotnetCarpenter commented 8 months ago

I guess this is a request for enhancement.

Currently, one can start/load a game, then choose Options- > Display settings -> Full screen.

Which is not the most convenient way but still very possible.

Perhaps a --fullscreen option to complement the current --windowed option?

crudelios commented 8 months ago

Yes, when using --windowed it will overwrite the setting.

I myself have nothing against adding both --fullscreen and --monitor and if the monitor id doesn't exist it will default to 0 and log the problem.

@bvschaik thoughts?

bvschaik commented 8 months ago

Currently, one can start/load a game, then choose Options- > Display settings -> Full screen.

There's also the hotkey for toggling fullscreen, which is F6 by default, alternative: Alt+Enter.

I don't mind adding --fullscreen.

For --monitor I'd like to keep in line with SDL terminology, which means naming it --display. The display ID is not well-defined though: SDL assigns 0 to what it thinks is the "primary display", any additional displays are numbered in an undefined order. I'll have a look how this works out in practice.