Fixes #4250. Add a v2unix driver (#4251)

* Implement Unix driver

* Add more sequences related with macOS

* Helper method to map char to control keys

* Add DriverName property

* Fix error on Unix unit tests

* Fix Non-nullable property 'DriverName' must contain a non-null value when exiting constructor.

* Fix Ctrl being ignored in the range \u0001-\u001a

* Add unit test for the MapChar method

* Fix cursor visibility and cursor styles

* Avoid sometimes error when running gnome-terminal

* Captures Ctrl+Shift+Alt+D7

* Captures Ctrl+D4, Ctrl+D5, Ctrl+D6 and Ctrl+D7

* Add unit test for Ctrl+Shift+Alt+7

* Fix issue on Windows where sending AltGr+some key fail assertion

* Exclude Oem1 from assertion

* Fix regex pattern

* Remove driverName from the constructor

* Revert "Remove driverName from the constructor"

This reverts commit 004e9f9588.

* Remove driverName from the constructor

* Add generic CreateSubcomponents method avoiding redundancy

* Add v2unix profiles

* Replace with hexadecimal values

---------

Co-authored-by: Tig <tig@users.noreply.github.com>
This commit is contained in:
BDisp
2025-10-02 15:51:05 +01:00
committed by GitHub
parent 4c6145cee9
commit 9d34e2792c
20 changed files with 700 additions and 63 deletions

View File

@@ -42,6 +42,12 @@
"commandLineArgs": "dotnet UICatalog.dll --driver v2",
"distributionName": ""
},
"WSL: UICatalog --driver v2unix": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "dotnet UICatalog.dll --driver v2unix",
"distributionName": ""
},
"WSL: UICatalog --driver v2net": {
"commandName": "Executable",
"executablePath": "wsl",
@@ -63,13 +69,19 @@
"WSL-Gnome: UICatalog --driver v2": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "bash -c 'while [ ! -e \"$XDG_RUNTIME_DIR/bus\" ]; do sleep 0.1; done; gnome-terminal --wait -- bash -l -c \"dotnet UICatalog.dll --driver v2; exec bash\"'",
"commandLineArgs": "bash -c 'dbus-run-session -- gnome-terminal --wait -- bash -l -c \"dotnet UICatalog.dll --driver v2; exec bash\"'",
"distributionName": ""
},
"WSL-Gnome: UICatalog --driver v2unix": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "bash -c 'dbus-run-session -- gnome-terminal --wait -- bash -l -c \"dotnet UICatalog.dll --driver v2unix; exec bash\"'",
"distributionName": ""
},
"WSL-Gnome: UICatalog --driver v2net": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "bash -c 'while [ ! -e \"$XDG_RUNTIME_DIR/bus\" ]; do sleep 0.1; done; gnome-terminal --wait -- bash -l -c \"dotnet UICatalog.dll --driver v2net; exec bash\"'",
"commandLineArgs": "bash -c 'dbus-run-session -- gnome-terminal --wait -- bash -l -c \"dotnet UICatalog.dll --driver v2net; exec bash\"'",
"distributionName": ""
},
"Benchmark All": {
@@ -94,6 +106,24 @@
"commandLineArgs": "dotnet UICatalog.dll --benchmark",
"distributionName": ""
},
"WSL: Benchmark All --driver v2": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "dotnet UICatalog.dll --driver v2 --benchmark",
"distributionName": ""
},
"WSL: Benchmark All --driver v2unix": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "dotnet UICatalog.dll --driver v2unix --benchmark",
"distributionName": ""
},
"WSL: Benchmark All --driver v2net": {
"commandName": "Executable",
"executablePath": "wsl",
"commandLineArgs": "dotnet UICatalog.dll --driver v2net --benchmark",
"distributionName": ""
},
"Docker": {
"commandName": "Docker"
},