Repository navigation
Windows: Alt+Enter toggles fullscreen, as on Linux - #405
Merged
Merged
Conversation
The window procedure only handled F11; Alt+Enter arrives as WM_SYSKEYDOWN and went to DefWindowProc. It now toggles the borderless fullscreen (other Alt keys such as Alt+F4 still reach Windows), and its WM_SYSCHAR no longer beeps. Enter held with Alt no longer also presses Plus (both platforms). Closes NotRexed#390 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ows) The keyboard map's Alt+Enter rule moves to nn_hid.c's kmap_down, which tests/test_alt_enter.py compiles alone against fake key states. It also checks that both window procedures toggle on Alt+Enter, and that the Windows one passes other Alt keys on and takes the WM_SYSCHAR beep. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Wpaif
force-pushed
the
feat/alt-enter-fullscreen
branch
from
November 8, 2026 00:09
ff67966 to
347a899
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #390
What
host/display.c): Alt+Enter now toggles the borderless fullscreen, the same setting as F11 and the Insert menu's Fullscreen row. It arrives asWM_SYSKEYDOWNand used to go straight toDefWindowProc. Other Alt keys (Alt+F4 among them) still reach Windows, a held key toggles once (repeat bit), and Alt+Enter'sWM_SYSCHARis taken so Windows does not beep.host/nn_hid.c): Enter is mapped to Plus, so Alt+Enter also pressed Plus (it opened the pause menu while going fullscreen; Linux'sdisplay_sdl.calready had Alt+Enter and showed this). Enter held with Alt is no longer Plus. The rule is a small helper,kmap_down.tests/test_alt_enter.py): game-free, in the source-regressions workflow. It compileskmap_downalone against fake key states, and checks both window procedures for the Alt+Enter toggle (and, on Windows, for Alt+F4 passing on and the beep being taken).Testing
python -I -B tests/test_alt_enter.pypasses, and fails when either the Alt rule or the Alt+F4 pass-through is removed.host/nn_hid.ccompiles on Linux (clang,-fsyntax-only).display.cchange is small, but a Windows build and a quick Alt+Enter / Alt+F4 check by someone on Windows would be appreciated.🤖 Generated with Claude Code