From d1414263fadf5330fd367907cdc9e0a26e471c87 Mon Sep 17 00:00:00 2001 From: Abdessamad Derraz <3028866+Abdess@users.noreply.github.com> Date: Fri, 23 Oct 2026 21:47:55 +0200 Subject: [PATCH] feat: name the pad inside muxterm gptokeyb2 owns the pad in muxterm on muOS with PortMaster, and muxterm keeps PgUp and PgDn for its scrollback. The launcher now says so with RETROBIOS_PAD=gptokeyb_muxterm, and the hints name the gptokeyb buttons with no paging key. --- install.ps1 | 2 +- install.py | 12 +- install.sh | 2 +- ports/shared/tui.txt | 1 + tests/fixtures/tui/route-gptokeyb_muxterm.txt | 1188 +++++++++++++++++ tests/test_handheld_launchers.py | 4 +- tests/test_install_tui.py | 10 +- wiki/installer.md | 5 +- 8 files changed, 1215 insertions(+), 9 deletions(-) create mode 100644 tests/fixtures/tui/route-gptokeyb_muxterm.txt diff --git a/install.ps1 b/install.ps1 index 821c2dc5..d7da0866 100644 --- a/install.ps1 +++ b/install.ps1 @@ -11,7 +11,7 @@ $ErrorActionPreference = "Stop" $defaultInstallUrl = "https://raw.githubusercontent.com/Abdess/retrobios/main/install.py" - $defaultInstallSha256 = "563ed14fea5ea54f5d6cb98311932293e714e9581014ea60c195325c20a587eb" + $defaultInstallSha256 = "0047a2f49b22271b69e9a4731165c3230fffa85fa0045a2f725a8bb8668ea9f5" $maximumInstallerBytes = 2MB $installerExit = 0 $installer = if ($PSScriptRoot) { Join-Path $PSScriptRoot "install.py" } else { $null } diff --git a/install.py b/install.py index 5d744967..9a8d3020 100644 --- a/install.py +++ b/install.py @@ -10039,7 +10039,7 @@ def plain_requested(args: argparse.Namespace, env: Mapping[str, str] | None = No # (ports/shared/tui.txt exports RB_PAD as this), so the bar names those # buttons and no others. TUI_PAD_ENV = "RETROBIOS_PAD" -TUI_PAD_ROUTES = ("gptokeyb", "muxterm", "evmapy", "miyoo") +TUI_PAD_ROUTES = ("gptokeyb", "gptokeyb_muxterm", "muxterm", "evmapy", "miyoo") # Set by Steam for what it starts, and by gamescope: a controller may be # all there is, mapped by Steam Input to keys nobody here can name. _STEAM_MARKERS = ("SteamGamepadUI", "SteamDeck", "SteamGameId", "GAMESCOPE_WAYLAND_DISPLAY") @@ -10251,6 +10251,7 @@ def _filter_row(state: TuiState) -> TuiRow: return TuiRow("filter", f"Filter: {text}") # A pad has no / and no letters: muxterm's own keyboard types. how = {"muxterm": "Select shows a keyboard", "gptokeyb": "with a keyboard", + "gptokeyb_muxterm": "with a keyboard", "evmapy": "with a keyboard", "miyoo": "with a keyboard"}.get(state.pad, "/ to type") return TuiRow("filter", f"Filter ({how})", style="dim") @@ -11280,6 +11281,9 @@ _ROUTE_KEYS: dict[str, dict[str, str | None]] = { "miyoo": {"A/Enter": "A", "B/Esc": "R2", "X/Space": "A", "Y/o": "L2", "?": None, "/": None, "Ctrl-C": None, "Enter": "Start", "Esc": None, "Ctrl-U": None}, } +# gptokeyb2 with retrobios.gptk inside muxterm, which no longer reads the pad: +# the gptokeyb buttons. +_ROUTE_KEYS["gptokeyb_muxterm"] = _ROUTE_KEYS["gptokeyb"] def _route_hint(state: TuiState, parts: tuple) -> tuple: @@ -11858,6 +11862,7 @@ _STOP_KEYS = { "both": ("B or Ctrl-C", "B, Ctrl-C or Start+Select"), "keys": ("Esc or Ctrl-C", "Esc or Ctrl-C"), "gptokeyb": ("B", "B or Start+Select"), + "gptokeyb_muxterm": ("B", "B or Start+Select"), "evmapy": ("B", "B"), "muxterm": ("B", "B"), "miyoo": ("R2", "R2"), @@ -12124,6 +12129,9 @@ _HELP_KEYS: dict[str, dict[str, str | None]] = { "back": "R2, Esc, Backspace", "stop": "R2, Esc, Ctrl-C", "kill": None, "enter": "Start, Enter", "esc": "Esc"}, } +# muxterm keeps PgUp and PgDn for its scrollback even when gptokeyb2 owns the +# pad, and the launcher sends nothing on L1 and R1 there. +_HELP_KEYS["gptokeyb_muxterm"] = {**_HELP_KEYS["gptokeyb"], "page": None} def _route_extras(state: TuiState) -> list[tuple[str, str]]: @@ -12140,7 +12148,7 @@ def _help_lines(state: TuiState) -> list[tuple[str, str]]: names = _HELP_KEYS.get(state.pad, _HELP_KEYS["both"]) # gptokeyb's kill: Start pressed first also chooses the row in focus. kill = ([(names["kill"], "Quit at once")] - if state.pad == "gptokeyb" else []) + if state.pad in ("gptokeyb", "gptokeyb_muxterm") else []) if screen == "installing": return [(names["stop"], "Stop: what is done stays done"), *([(names["kill"], "Stop")] if names["kill"] else []), diff --git a/install.sh b/install.sh index 8959bba1..c002ce0e 100755 --- a/install.sh +++ b/install.sh @@ -18,7 +18,7 @@ esac TEMP_INSTALLER="" TEMP_DIRECTORY="" DEFAULT_INSTALL_URL="https://raw.githubusercontent.com/Abdess/retrobios/main/install.py" -DEFAULT_INSTALL_SHA256="563ed14fea5ea54f5d6cb98311932293e714e9581014ea60c195325c20a587eb" +DEFAULT_INSTALL_SHA256="0047a2f49b22271b69e9a4731165c3230fffa85fa0045a2f725a8bb8668ea9f5" MAX_INSTALLER_BYTES=2097152 cleanup() { diff --git a/ports/shared/tui.txt b/ports/shared/tui.txt index 112be1f7..0686399a 100644 --- a/ports/shared/tui.txt +++ b/ports/shared/tui.txt @@ -437,6 +437,7 @@ rb_muxterm() { return 0 fi RB_TERMAPP=(env "SDL_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT=$RB_SDL_NO_PAD" "$1" --gl --) + RB_PAD="gptokeyb_muxterm" if awk '$1 == "l1" || $1 == "r1" { print $1 " = \\\""; next } { print }' \ "$RB_GPTK" > "$RB_STATE/muxterm.gptk" 2>> "$RB_LOG"; then RB_GPTK="$RB_STATE/muxterm.gptk" diff --git a/tests/fixtures/tui/route-gptokeyb_muxterm.txt b/tests/fixtures/tui/route-gptokeyb_muxterm.txt new file mode 100644 index 00000000..43ada349 --- /dev/null +++ b/tests/fixtures/tui/route-gptokeyb_muxterm.txt @@ -0,0 +1,1188 @@ +=== setup 40x12 + RetroBIOS: Where do you play? + + Found on this machine: + + > RetroArch + KNULLI (Batocera files) + Another setup or folder + + BIOS folder: + /home/user/.config/retroarch/system + ES-DE found: its BIOS files go to each + A Continue B Quit +=== setup 40x15 + RetroBIOS: Where do you play? + + Found on this machine: + + > RetroArch + KNULLI (Batocera files) + Another setup or folder + + BIOS folder: + /home/user/.config/retroarch/system + ES-DE found: its BIOS files go to each + emulator, not to ES-DE itself. + + + A Continue B Quit +=== setup 80x24 + RetroBIOS: Where do you play? + + Found on this machine: + + > RetroArch + KNULLI (Batocera files) + Another setup or folder + + BIOS folder: /home/user/.config/retroarch/system + ES-DE found: its BIOS files go to each emulator, not to ES-DE itself. + + + + + + + + + + + + + + A Continue B Quit +=== platforms 40x12 + RetroBIOS: Which setup? + + Filter (with a keyboard) + > RetroArch muOS, JE...firmware + Batocera + Recalbox + RetroBat + EmuDeck + Lakka + RetroDECK + 1-7 of 18 + A Choose B Back +=== platforms 40x15 + RetroBIOS: Which setup? + + Filter (with a keyboard) + > RetroArch muOS, JE...firmware + Batocera + Recalbox + RetroBat + EmuDeck + Lakka + RetroDECK + ROCKNIX + RomM + BizHawk + 1-10 of 18 + A Choose B Back +=== platforms 80x24 + RetroBIOS: Which setup? + + Choose the setup that will use the BIOS files. + + Filter (with a keyboard) + > RetroArch muOS, JELOS, KOLOS...nic stock firmware + Batocera + Recalbox + RetroBat + EmuDeck + Lakka + RetroDECK + ROCKNIX + RomM + BizHawk + MiSTer FPGA + RetroPie + AmberELEC PAN4ELEC + EmuELEC + KNULLI + MinUI + NextUI + MyMinUI + A Choose B Back +=== folder 40x12 + RetroBIOS: Which folder? + + RetroArch reads its BIOS files from: + /home/user/.config/retroarch/system + + > Use this folder + Browse for a folder + Type a path + + + + A Use this folder B Back +=== folder 40x15 + RetroBIOS: Which folder? + + RetroArch reads its BIOS files from: + /home/user/.config/retroarch/system + + > Use this folder + Browse for a folder + Type a path + + + + + + + A Use this folder B Back +=== folder 80x24 + RetroBIOS: Which folder? + + RetroArch reads its BIOS files from: + /home/user/.config/retroarch/system + + > Use this folder + Browse for a folder + Type a path + + + + + + + + + + + + + + + + A Use this folder B Back +=== folder-card 40x12 + RetroBIOS: Where is the SD card? + + NextUI keeps its BIOS files on its SD + card. Choose the card's root folder, + the one holding .system. + + > Browse for a folder + Type a path + + + + A Browse B Back +=== folder-card 40x15 + RetroBIOS: Where is the SD card? + + NextUI keeps its BIOS files on its SD + card. Choose the card's root folder, + the one holding .system. + + > Browse for a folder + Type a path + + + + + + + A Browse B Back +=== folder-card 80x24 + RetroBIOS: Where is the SD card? + + NextUI keeps its BIOS files on its SD card. Choose the card's root folder, the + one holding .system. + + > Browse for a folder + Type a path + + + + + + + + + + + + + + + + + A Browse B Back +=== browse 40x12 + RetroBIOS: Browse for a folder + + /home/user/.config/retroarch + + > Use this folder + .. + /media/user/SDCARD (NextUI card) + cores/ + system/ + + + A Use this folder B Back +=== browse 40x15 + RetroBIOS: Browse for a folder + + /home/user/.config/retroarch + + > Use this folder + .. + /media/user/SDCARD (NextUI card) + cores/ + system/ + + + + + + A Use this folder B Back +=== browse 80x24 + RetroBIOS: Browse for a folder + + /home/user/.config/retroarch + + > Use this folder + .. + /media/user/SDCARD (NextUI card) + cores/ + system/ + + + + + + + + + + + + + + + A Use this folder B Back +=== path 40x12 + RetroBIOS: Type a path + + The folder for RetroArch: + > ~/bios_ + + Ctrl-U clears. Quotes are removed, ~ + and variables are expanded. + + + + + A Use this folder B Back +=== path 40x15 + RetroBIOS: Type a path + + The folder for RetroArch: + > ~/bios_ + + Ctrl-U clears. Quotes are removed, ~ + and variables are expanded. + + + + + + + + A Use this folder B Back +=== path 80x24 + RetroBIOS: Type a path + + The folder for RetroArch: + > ~/bios_ + + Ctrl-U clears. Quotes are removed, ~ and variables are expanded. + + + + + + + + + + + + + + + + + + A Use this folder B Back +=== create 40x12 + RetroBIOS: Create the folder? + + /home/user/bios/new does not exist. + The nearest folder that does: + /home/user + + > Create it and continue + Choose another folder + + + + A Create B Back +=== create 40x15 + RetroBIOS: Create the folder? + + /home/user/bios/new does not exist. + The nearest folder that does: + /home/user + + > Create it and continue + Choose another folder + + + + + + + A Create B Back +=== create 80x24 + RetroBIOS: Create the folder? + + /home/user/bios/new does not exist. + The nearest folder that does: /home/user + + > Create it and continue + Choose another folder + + + + + + + + + + + + + + + + + A Create B Back +=== checking 40x12 + RetroBIOS: Checking + + RetroArch: ~/.config/retroarch/system + + File list: 5 files. + Reading the files already in the + folder... 0:04 + + + + + Start+Select Quit B Back +=== checking 40x15 + RetroBIOS: Checking + + RetroArch: ~/.config/retroarch/system + + File list: 5 files. + Reading the files already in the + folder... 0:04 + + + + + + + + Start+Select Quit B Back +=== checking 80x24 + RetroBIOS: Checking + + RetroArch: ~/.config/retroarch/system + + File list: 5 files. + Reading the files already in the folder... 0:04 + + + + + + + + + + + + + + + + + + Start+Select Quit B Back +=== plan 40x12 + RetroBIOS: RetroArch + + 4 files to download, 1.0 MB + BIOS folder: ~/.co.../retroarch/system + 1 in place, 3 missing, 1 wrong copy + Free space: 50.0 GB + > Install + Choose systems + Copy from your old card or a folder + Options + Quit + A Install B Back Y Options +=== plan 40x15 + RetroBIOS: RetroArch + + 4 files to download, 1.0 MB + BIOS folder: ~/.co.../retroarch/system + 1 in place, 3 missing, 1 wrong copy + Free space: 50.0 GB + They are replaced, and the old copies + are kept in a backup folder. + + > Install + Choose systems + Copy from your old card or a folder + Options + Quit + A Install B Back Y Options +=== plan 80x24 + RetroBIOS: RetroArch + + 4 files to download, 1.0 MB + BIOS folder: ~/.config/retroarch/system + 1 in place, 3 missing, 1 wrong copy + Free space: 50.0 GB + They are replaced, and the old copies are kept in a backup folder. + + > Install + Choose systems + Copy the BIOS files from your old card or a folder + Options + Quit + + + + + + + + + + + A Install B Back Y Options +=== plan-in-place 40x12 + RetroBIOS: RetroArch + + Everything is in place + BIOS folder: ~/.co.../retroarch/system + 5 in place, 0 missing, 0 wrong copies + Free space: 50.0 GB + + > Close + Options + + + A Close B Back Y Options +=== plan-in-place 40x15 + RetroBIOS: RetroArch + + Everything is in place + BIOS folder: ~/.co.../retroarch/system + 5 in place, 0 missing, 0 wrong copies + Free space: 50.0 GB + + > Close + Options + + + + + + A Close B Back Y Options +=== plan-in-place 80x24 + RetroBIOS: RetroArch + + Everything is in place + BIOS folder: ~/.config/retroarch/system + 5 in place, 0 missing, 0 wrong copies + Free space: 50.0 GB + + > Close + Options + + + + + + + + + + + + + + + A Close B Back Y Options +=== systems 40x12 + RetroBIOS: Choose systems + + All + None + Filter (with a keyboard) + > [x] nintendo-gba (gba) 16.0 KB + [x] sony-playstation 1.0 MB + [ ] nintendo-famicom-disk in place + + + 2 of 3 systems: 4 files, 1.0 MB + A Continue B Back X Tick +=== systems 40x15 + RetroBIOS: Choose systems + + All + None + Filter (with a keyboard) + > [x] nintendo-gba (gba) 16.0 KB + [x] sony-playstation 1.0 MB + [ ] nintendo-famicom-disk in place + + + + + + 2 of 3 systems: 4 files, 1.0 MB + A Continue B Back X Tick +=== systems 80x24 + RetroBIOS: Choose systems + + All + None + Filter (with a keyboard) + > [x] nintendo-gba (gba) 1 file, 16.0 KB + [x] sony-playstation 3 files, 1.0 MB + [ ] nintendo-famicom-disk (ファミコン) in place + + + + + + + + + + + + + + + 2 of 3 systems: 4 files, 1.0 MB + A Continue B Back X Tick +=== options 40x12 + RetroBIOS: Options + + > Preferred regions: North America, Ja + Game data: kept + Installed cores only: no (1 found) + Cores: all + Parallel downloads: 8 + BIOS folder: ~/.config...ch/system + Copy from: none + Preview the file list + Show the command line + A Open B Back Left/Right Set +=== options 40x15 + RetroBIOS: Options + + > Preferred regions: North America, Ja + Game data: kept + Installed cores only: no (1 found) + Cores: all + Parallel downloads: 8 + BIOS folder: ~/.config...ch/system + Copy from: none + Preview the file list + Show the command line + + Sets --region + + A Open B Back Left/Right Set +=== options 80x24 + RetroBIOS: Options + + Each row is an option of the command line, named on the right. + + > Preferred regions: North America, Japan --region + Game data: kept --no-game-data + Installed cores only: no (1 found) --installed-cores + Cores: all --core + Parallel downloads: 8 --jobs + BIOS folder: ~/.config/retroarch/system --dest + Copy from: none --from + Preview the file list --dry-run + Show the command line + + + + + + + + + + + A Open B Back Left/Right Set +=== regions 40x12 + RetroBIOS: Preferred regions + + Tick the regions to keep, best first. + Where a system has one BIOS per + region, the best one found is + installed. + + > [1] North America + [ ] Japan + + + A Tick B Done Left/Right Order +=== regions 40x15 + RetroBIOS: Preferred regions + + Tick the regions to keep, best first. + Where a system has one BIOS per + region, the best one found is + installed. + + > [1] North America + [ ] Japan + + + + + + A Tick B Done Left/Right Order +=== regions 80x24 + RetroBIOS: Preferred regions + + Tick the regions to keep, best first. Where a system has one BIOS per region, + the best one found is installed. + + > [1] North America + [ ] Japan + + + + + + + + + + + + + + + + + A Tick B Done Left/Right Order +=== cores 40x12 + RetroBIOS: Cores + + Tick the cores you use. With none + ticked, every core's files are kept. + + > Filter (with a keyboard) + [ ] mesen + [x] pcsx_rearmed + + + + A Filter B Back X Tick +=== cores 40x15 + RetroBIOS: Cores + + Tick the cores you use. With none + ticked, every core's files are kept. + + > Filter (with a keyboard) + [ ] mesen + [x] pcsx_rearmed + + + + + + + A Filter B Back X Tick +=== cores 80x24 + RetroBIOS: Cores + + Tick the cores you use. With none ticked, every core's files are kept. + + > Filter (with a keyboard) + [ ] mesen + [x] pcsx_rearmed + + + + + + + + + + + + + + + + + A Filter B Back X Tick +=== preview 40x12 + RetroBIOS: Preview + + 4 files to download, 1.0 MB. Nothing + is written. + + missing 512.0 KB scph5500.bin + wrong copy 512.0 KB scph5501.bin + missing 4 B pcsx/extra.bin + missing 16.0 KB gba_bios.bin + + + A Back Up/Down Scroll +=== preview 40x15 + RetroBIOS: Preview + + 4 files to download, 1.0 MB. Nothing + is written. + + missing 512.0 KB scph5500.bin + wrong copy 512.0 KB scph5501.bin + missing 4 B pcsx/extra.bin + missing 16.0 KB gba_bios.bin + + + + + + A Back Up/Down Scroll +=== preview 80x24 + RetroBIOS: Preview + + 4 files to download, 1.0 MB. Nothing is written. + + missing 512.0 KB scph5500.bin + wrong copy 512.0 KB scph5501.bin + missing 4 B pcsx/extra.bin + missing 16.0 KB gba_bios.bin + + + + + + + + + + + + + + + + A Back Up/Down Scroll +=== command 40x12 + RetroBIOS: Command line + + The same choice without questions: + + python3 install.py --platform + retroarch --dest + /home/user/.config/retroarch/system + --system nintendo-gba + + + + A Back +=== command 40x15 + RetroBIOS: Command line + + The same choice without questions: + + python3 install.py --platform + retroarch --dest + /home/user/.config/retroarch/system + --system nintendo-gba + + + + + + + A Back +=== command 80x24 + RetroBIOS: Command line + + The same choice without questions: + + python3 install.py --platform retroarch --dest + /home/user/.config/retroarch/system --system nintendo-gba + + + + + + + + + + + + + + + + + + A Back +=== confirm 40x12 + RetroBIOS: Confirm + + 1 file to download, 16.0 KB + BIOS folder: ~/.co.../retroarch/system + 0 in place, 1 missing, 0 wrong copies + Free space: 50.0 GB + + > Install + Back + + + A Install B Back +=== confirm 40x15 + RetroBIOS: Confirm + + 1 file to download, 16.0 KB + BIOS folder: ~/.co.../retroarch/system + 0 in place, 1 missing, 0 wrong copies + Free space: 50.0 GB + + > Install + Back + + + + + + A Install B Back +=== confirm 80x24 + RetroBIOS: Confirm + + 1 file to download, 16.0 KB + BIOS folder: ~/.config/retroarch/system + 0 in place, 1 missing, 0 wrong copies + Free space: 50.0 GB + + > Install + Back + + + + + + + + + + + + + + + A Install B Back +=== installing 40x12 + RetroBIOS: Installing + + [###############----------------] 50% + 528.0 KB of 1.0 MB + 128.9 KB/s, 0:04 left + 2 of 4 files + B or Start+Select stops. What is done + stays done. + + FAILED scph5500.bin (HTTP 404) + ok gba_bios.bin + B Stop +=== installing 40x15 + RetroBIOS: Installing + + [###############----------------] 50% + 528.0 KB of 1.0 MB + 128.9 KB/s, 0:04 left + 2 of 4 files + B or Start+Select stops. What is done + stays done. + + FAILED scph5500.bin (HTTP 404) + ok gba_bios.bin + + + + B Stop +=== installing 80x24 + RetroBIOS: Installing + + [####################################-----------------------------------] 50% + 528.0 KB of 1.0 MB + 128.9 KB/s, 0:04 left + 2 of 4 files + B or Start+Select stops. What is done stays done. + + FAILED scph5500.bin (HTTP 404) + ok gba_bios.bin + + + + + + + + + + + + + + B Stop +=== result 40x12 + RetroBIOS: Finished with errors + + 3 installed, 1 failed. + BIOS folder: + /home/user/.config/retroarch/system + failed: scph5500.bin (HTTP 404) + The files it replaced are kept in + /home/user/.config/retroarch/ + retrobios-backup/2026-10-23_1200 + To put them back: python3 install.py + 1-4 of 8 + A Exit Up/Down Scroll +=== result 40x15 + RetroBIOS: Finished with errors + + 3 installed, 1 failed. + BIOS folder: + /home/user/.config/retroarch/system + failed: scph5500.bin (HTTP 404) + The files it replaced are kept in + /home/user/.config/retroarch/ + retrobios-backup/2026-10-23_1200 + To put them back: python3 install.py + --restore + /home/user/.config/retroarch/ + retrobios-backup/2026-10-23_1200 + 1-5 of 8 + A Exit Up/Down Scroll +=== result 80x24 + RetroBIOS: Finished with errors + + 3 installed, 1 failed. + BIOS folder: /home/user/.config/retroarch/system + failed: scph5500.bin (HTTP 404) + The files it replaced are kept in + /home/user/.config/retroarch/retrobios-backup/2026-10-23_1200 + To put them back: python3 install.py --restore + /home/user/.config/retroarch/retrobios-backup/2026-10-23_1200 + Same choice without questions: + python3 install.py --platform retroarch --dest + /home/user/.config/retroarch/system + Details: /tmp/retrobios-x/install.log + + + + + + + + + + + A Exit Up/Down Scroll +=== error 40x12 + RetroBIOS: Something went wrong + + Could not fetch the file list for + retroarch after 3 attempts: [Errno + -2] Name or service not known + Address: + https://raw.githubusercontent.com/ + Abdess/retrobios/main/install/ + retroarch.json + > Choose another setup or folder + Quit + A Back B Back +=== error 40x15 + RetroBIOS: Something went wrong + + Could not fetch the file list for + retroarch after 3 attempts: [Errno + -2] Name or service not known + Address: + https://raw.githubusercontent.com/ + Abdess/retrobios/main/install/ + retroarch.json + + > Choose another setup or folder + Quit + + + A Back B Back +=== error 80x24 + RetroBIOS: Something went wrong + + Could not fetch the file list for retroarch after 3 attempts: [Errno -2] + Name or service not known + Address: https://raw.githubusercontent.com/Abdess/retrobios/main/install/ + retroarch.json + + > Choose another setup or folder + Quit + + + + + + + + + + + + + + + A Back B Back +=== quit 40x12 + RetroBIOS: Quit? + + Quit without installing? Nothing was + written. + + > Quit + Stay + + + + + A Quit B Stay +=== quit 40x15 + RetroBIOS: Quit? + + Quit without installing? Nothing was + written. + + > Quit + Stay + + + + + + + + A Quit B Stay +=== quit 80x24 + RetroBIOS: Quit? + + Quit without installing? Nothing was written. + + > Quit + Stay + + + + + + + + + + + + + + + + + + A Quit B Stay +=== help 40x12 + RetroBIOS: Keys + + D-pad, Up/Down Move + A, Start, Enter Install + Y, Tab, o Options + B, Select, Esc Back + q, Ctrl-C Quit + Select, then Start Quit at once + ?, F1 This help + + + Any key closes this help +=== help 40x15 + RetroBIOS: Keys + + D-pad, Up/Down Move + A, Start, Enter Install + Y, Tab, o Options + B, Select, Esc Back + q, Ctrl-C Quit + Select, then Start Quit at once + ?, F1 This help + + BIOS folder: + /home/user/.config/retroarch/system + + + Any key closes this help +=== help 80x24 + RetroBIOS: Keys + + D-pad, Up/Down Move + A, Start, Enter Install + Y, Tab, o Options + B, Select, Esc Back + q, Ctrl-C Quit + Select, then Start Quit at once + ?, F1 This help + + BIOS folder: /home/user/.config/retroarch/system + + + + + + + + + + + + + Any key closes this help diff --git a/tests/test_handheld_launchers.py b/tests/test_handheld_launchers.py index a9dc8756..5101c9cd 100644 --- a/tests/test_handheld_launchers.py +++ b/tests/test_handheld_launchers.py @@ -1151,7 +1151,7 @@ class ThePortMasterPort(unittest.TestCase): [hint] = device.lines("termapp.sdl") assert_muxterm_hides_every_pad(self, hint) assert_muxterm_mapping(self, device.mapper_args(), self.gamedir / "retrobios.gptk") - self.assertEqual(call["pad"], "gptokeyb") + self.assertEqual(call["pad"], "gptokeyb_muxterm") self.assertEqual(call["idle_exit"], "300") self.assertEqual(self.dialog(device), ["FINISH"]) @@ -1483,7 +1483,7 @@ class TheMuosApp(unittest.TestCase): self.assertRegex(args[1], r"^retrobios-stop-\d+x$") assert_muxterm_mapping(self, args, app / "retrobios.gptk") self.assertEqual(read_gptk(Path(args[-1]))["y"], ["tab"]) - self.assertEqual(call["pad"], "gptokeyb") + self.assertEqual(call["pad"], "gptokeyb_muxterm") self.assertEqual(call["idle_exit"], "300") device.assert_mapper_stopped() diff --git a/tests/test_install_tui.py b/tests/test_install_tui.py index d9a9fac8..5e59b0d4 100644 --- a/tests/test_install_tui.py +++ b/tests/test_install_tui.py @@ -60,7 +60,7 @@ except ImportError: GOLDEN = REPO_ROOT / "tests" / "fixtures" / "tui" SIZES = ((40, 12), (40, 15), (80, 24), (120, 40)) # RETROBIOS_PAD's values, and "keys" for a desktop that sets none. -ROUTES = ("keys", "gptokeyb", "evmapy", "muxterm", "miyoo") +ROUTES = ("keys", "gptokeyb", "gptokeyb_muxterm", "evmapy", "muxterm", "miyoo") UP, DOWN, RIGHT, LEFT = "\x1b[A", "\x1b[B", "\x1b[C", "\x1b[D" Key = install.TuiKey @@ -994,6 +994,7 @@ def _bar_keys(line: str) -> set: ROUTE_KEYS = { "keys": {"Enter", "Esc", "Space", "o", "?", "/", "Ctrl-C", "Ctrl-U"}, "gptokeyb": {"A", "B", "X", "Y", "Start+Select"}, + "gptokeyb_muxterm": {"A", "B", "X", "Y", "Start+Select"}, "evmapy": {"A", "B", "X", "Y"}, "muxterm": {"Start", "B", "Y", "Menu", "Select"}, "miyoo": {"A", "Start", "R2", "L2"}, @@ -1098,6 +1099,13 @@ class PadRoutes(unittest.TestCase): "Close the terminal"): self.assertIn(words, muxterm) self.assertNotIn("Start+Select", muxterm) + # gptokeyb2 owns the pad inside muxterm, which keeps PgUp and PgDn + # for its scrollback: the gptokeyb buttons, and no page key. + in_muxterm = help_text("gptokeyb_muxterm", "preview") + for words in ("A, Start, Enter", "Select, then Start"): + self.assertIn(words, in_muxterm) + self.assertNotIn("L1/R1", in_muxterm) + self.assertIn("L1/R1", help_text("gptokeyb", "preview")) # muxterm keeps PgUp and PgDn for its scrollback, and L1 and R1 # send nothing: no paging is offered there, on a list or a pager. for screen in ("systems", "result", "plan"): diff --git a/wiki/installer.md b/wiki/installer.md index ee12ed43..db937aa1 100644 --- a/wiki/installer.md +++ b/wiki/installer.md @@ -1081,7 +1081,8 @@ Each launcher tells the interface which buttons reach it, in | Value | Input | Set by | |-------|-------|--------| -| `gptokeyb` | gptokeyb or gptokeyb2 with `retrobios.gptk`, the table above | the PortMaster port, the Tools entry, the muOS app with PortMaster | +| `gptokeyb` | gptokeyb or gptokeyb2 with `retrobios.gptk`, the table above | the PortMaster port and the Tools entry | +| `gptokeyb_muxterm` | the same, inside muxterm, which keeps L1 and R1 for its scrollback: no button pages | the muOS app with PortMaster | | `muxterm` | muxterm's own keys: D-pad, Start as Enter, B as Backspace, Y as Space | the muOS app without PortMaster | | `evmapy` | `RetroBIOS.sh.keys`, the same buttons as the table | the Batocera and Knulli port | | `miyoo` | buttons that are already keys: A as Space, Start as Enter, L1 and R1 as E and T, L2 as Tab, R2 as Backspace | no launcher yet | @@ -1340,7 +1341,7 @@ RetroArch folder that holds only `scph5501.bin`, in the order written: | `FORCE_COLOR`, `CLICOLOR_FORCE` | Colour even when the output is a pipe or a file, set to any value but `0` or an empty one. `NO_COLOR` wins over both, and the progress line stays one line per file | | `SSL_CERT_FILE`, `SSL_CERT_DIR` | The trusted certificates to check servers with, for a Python that finds none of its own | | `RETROBIOS_PLAIN`, `ACCESSIBLE` | Set to anything but `0`: the questions come line by line, as with `--plain`, instead of the full-screen interface | -| `RETROBIOS_PAD` | The buttons a handheld launcher's mapper sends to the full screen (`gptokeyb`, `muxterm`, `evmapy`, `miyoo`), so its hints name them. See [On a handheld](#on-a-handheld-the-retrobios-port) | +| `RETROBIOS_PAD` | The buttons a handheld launcher's mapper sends to the full screen (`gptokeyb`, `gptokeyb_muxterm`, `muxterm`, `evmapy`, `miyoo`), so its hints name them. See [On a handheld](#on-a-handheld-the-retrobios-port) | | `RETROBIOS_IDLE_EXIT` | Seconds the full screen's first screen waits for a first button. With none pressed, it closes with exit status 0 | | `HTTPS_PROXY`, `NO_PROXY` | Honoured for every download through the standard library's default proxy handling: one names the proxy, the other the hosts to reach directly |