mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-17 22:19:57 -04:00
Make the SDL window honour monitor, --monitor and --list-monitors.
On Linux the window ignored NX2NAVI_MONITOR (the log said it had no effect) and --list-monitors only printed that monitor selection is Win32-only. The SDL window now picks a monitor with the same rules as the Win32 one: auto (the system places it), primary, a 1-based index in listing order, or part of the monitor's name, ignoring case, the first match in list order winning. The monitors are SDL's displays; --list-monitors prints their index, name (the make and model, with the connector on Wayland and X11), pixel size and position, primary flag and display scale, then what NX2NAVI_MONITOR would pick, and the log says the same when the window opens. The window is created centred on the chosen monitor and centred again at its final size, and that position also names the display the fullscreen setting covers, which is how a Wayland window, which a client cannot move, opens fullscreen on the chosen output. On Wayland a windowed window opens where the compositor puts it; the log says so once. With a chosen monitor, the size widescreen.c reads for fullscreen before the window exists is that monitor's. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
committed by
chrg6
parent
4d41188d8b
commit
a103673341
@@ -8,9 +8,10 @@
|
||||
// show which device NX2NAVI_AUDIO_DEVICE picks; needs no game files
|
||||
// --monitor VALUE open the game window on one monitor: sets NX2NAVI_MONITOR before the settings are read, so it wins
|
||||
// over nx2navi.ini's `monitor =`. VALUE is auto (default), primary, a 1-based index as --list-monitors
|
||||
// prints it, or part of a GDI device name (DISPLAY3) or of a monitor's name, case-insensitive
|
||||
// --list-monitors print each monitor's index, GDI device name, name, desktop rectangle, primary flag and DPI;
|
||||
// needs no game files
|
||||
// prints it, or part of a monitor's name (on Windows also of its GDI device name, DISPLAY3),
|
||||
// case-insensitive. Wayland places a windowed window itself: only fullscreen opens on the monitor
|
||||
// --list-monitors print each monitor's index, name (on Windows also its GDI device name), desktop rectangle,
|
||||
// primary flag and DPI; needs no game files
|
||||
// --selftest layout, dispatch table and host-function registry; needs no game files
|
||||
// --probe-mods the mods folder scan, order and switches (mods.c); needs no game files
|
||||
// --probe-loader load and relocate the modules, check them against the measured 1.2.1 values
|
||||
|
||||
Reference in New Issue
Block a user