[GH-ISSUE #403] Possible wrong case for key symbols in release_bind option? #208

Open
opened 2026-05-05 22:14:02 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @vinivosh on GitHub (Mar 26, 2026).
Original GitHub issue: https://github.com/feschber/lan-mouse/issues/403

Using the latest release, 0.10.0, in Arch Linux via the extra/lan-mouse package.

I got this config parsing error when trying to use the CLI interface. Seems like the camel case used in the scan codes isn't consistent, leading to confusion. Shouldn't KeyLeftBrace stay that way in Linux as it is in Windows? Instead, it expects KeyLeftbrace.

[2026-03-26T13:16:27Z INFO  lan_mouse::config] using config: "/home/vini/.config/lan-mouse/config.toml"
[2026-03-26T13:16:27Z WARN  lan_mouse::config] /home/vini/.config/lan-mouse/config.toml: TOML parse error at line 2, column 18
      |
    2 | release_bind = [ "KeyLeftBrace", "KeyRightBrace", "KeyBackslash" ]
      |                  ^^^^^^^^^^^^^^
    unknown variant `KeyLeftBrace`, expected one of `KeyReserved`, `KeyEsc`, `Key1`, `Key2`, `Key3`, `Key4`, `Key5`, `Key6`, `Key7`, `Key8`, `Key9`, `Key0`, `KeyMinus`, `KeyEqual`, `KeyBackspace`, `KeyTab`, `KeyQ`, `KeyW`, `KeyE`, `KeyR`, `KeyT`, `KeyY`, `KeyU`, `KeyI`, `KeyO`, `KeyP`, `KeyLeftbrace`, `KeyRightbrace`, `KeyEnter`, `KeyLeftCtrl`, `KeyA`, `KeyS`, `KeyD`, `KeyF`, `KeyG`, `KeyH`, `KeyJ`, `KeyK`, `KeyL`, `KeySemicolon`, `KeyApostrophe`, `KeyGrave`, `KeyLeftShift`, `KeyBackslash`, `KeyZ`, `KeyX`, `KeyC`, `KeyV`, `KeyB`, `KeyN`, `KeyM`, `KeyComma`, `KeyDot`, `KeySlash`, `KeyRightShift`, `KeyKpAsterisk`, `KeyLeftAlt`, `KeySpace`, `KeyCapsLock`, `KeyF1`, `KeyF2`, `KeyF3`, `KeyF4`, `KeyF5`, `KeyF6`, `KeyF7`, `KeyF8`, `KeyF9`, `KeyF10`, `KeyNumlock`, `KeyScrollLock`, `KeyKp7`, `KeyKp8`, `KeyKp9`, `KeyKpMinus`, `KeyKp4`, `KeyKp5`, `KeyKp6`, `KeyKpplus`, `KeyKp1`, `KeyKp2`, `KeyKp3`, `KeyKp0`, `KeyKpDot`, `Invalid`, `KeyZenkakuhankaku`, `Key102nd`, `KeyF11`, `KeyF12`, `KeyRo`, `KeyKatakana`, `KeyHiragana`, `KeyHenkan`, `KeyKatakanahiragana`, `KeyMuhenkan`, `KeyKpJpComma`, `KeyKpEnter`, `KeyRightCtrl`, `KeyKpslash`, `KeySysrq`, `KeyRightalt`, `KeyLinefeed`, `KeyHome`, `KeyUp`, `KeyPageup`, `KeyLeft`, `KeyRight`, `KeyEnd`, `KeyDown`, `KeyPagedown`, `KeyInsert`, `KeyDelete`, `KeyMacro`, `KeyMute`, `KeyVolumeDown`, `KeyVolumeUp`, `KeyPower`, `KeyKpequal`, `KeyKpplusminus`, `KeyPause`, `KeyScale`, `KeyKpcomma`, `KeyHanguel`, `KeyHanja`, `KeyYen`, `KeyLeftMeta`, `KeyRightmeta`, `KeyCompose`, `KeyStop`, `KeyAgain`, `KeyProps`, `KeyUndo`, `KeyFront`, `KeyCopy`, `KeyOpen`, `KeyPaste`, `KeyFind`, `KeyCut`, `KeyHelp`, `KeyMenu`, `KeyCalc`, `KeySetup`, `KeySleep`, `KeyWakeup`, `KeyFile`, `KeySendfile`, `KeyDeletefile`, `KeyXfer`, `KeyProg1`, `KeyProg2`, `KeyWww`, `KeyMsdos`, `KeyCoffee`, `KeyRotateDisplay`, `KeyCyclewindows`, `KeyMail`, `KeyBookmarks`, `KeyComputer`, `KeyBack`, `KeyForward`, `KeyClosecd`, `KeyEjectcd`, `KeyEjectclosecd`, `KeyNextsong`, `KeyPlaypause`, `KeyPrevioussong`, `KeyStopcd`, `KeyRecord`, `KeyRewind`, `KeyPhone`, `KeyIso`, `KeyConfig`, `KeyHomepage`, `KeyRefresh`, `KeyExit`, `KeyMove`, `KeyEdit`, `KeyScrollup`, `KeyScrolldown`, `KeyKpleftparen`, `KeyKprightparen`, `KeyNew`, `KeyRedo`, `KeyF13`, `KeyF14`, `KeyF15`, `KeyF16`, `KeyF17`, `KeyF18`, `KeyF19`, `KeyF20`, `KeyF21`, `KeyF22`, `KeyF23`, `KeyF24`, `Invalid1`, `Invalid2`, `Invalid3`, `Invalid4`, `Invalid5`, `KeyPlaycd`, `KeyPausecd`, `KeyProg3`, `KeyProg4`, `KeyAllApplications`, `KeySuspend`, `KeyClose`, `KeyPlay`, `KeyFastforward`, `KeyBassboost`, `KeyPrint`, `KeyHp`, `KeyCamera`, `KeySound`, `KeyQuestion`, `KeyEmail`, `KeyChat`, `KeySearch`, `KeyConnect`, `KeyFinance`, `KeySport`, `KeyShop`, `KeyAlterase`, `KeyCancel`, `KeyBrightnessdown`, `KeyBrightnessup`, `KeyMedia`, `KeySwitchvideomode`, `KeyKbdillumtoggle`, `KeyKbdillumdown`, `KeyKbdillumup`, `KeySend`, `KeyReply`, `KeyForwardmail`, `KeySave`, `KeyDocuments`, `KeyBattery`, `KeyBluetooth`, `KeyWlan`, `KeyUwb`, `KeyUnknown`, `KeyVideoNext`, `KeyVideoPrev`, `KeyBrightnessCycle`, `KeyBrightnessAuto`, `KeyDisplayOff`, `KeyWwan`, `KeyRfkill`, `KeyMicmute`, `KeyCount`

Sorry if this is some implementation limitation that I don't know of.

Originally created by @vinivosh on GitHub (Mar 26, 2026). Original GitHub issue: https://github.com/feschber/lan-mouse/issues/403 Using the latest release, [`0.10.0`](https://github.com/feschber/lan-mouse/tree/v0.10.0), in Arch Linux via the `extra/lan-mouse` package. I got this config parsing error when trying to use the CLI interface. Seems like the camel case used in the [scan codes](https://github.com/feschber/lan-mouse/blob/v0.10.0/input-event/src/scancode.rs#L466) isn't consistent, leading to confusion. Shouldn't `KeyLeftBrace` stay that way in Linux as it is in Windows? Instead, it expects `KeyLeftbrace`. ```log [2026-03-26T13:16:27Z INFO lan_mouse::config] using config: "/home/vini/.config/lan-mouse/config.toml" [2026-03-26T13:16:27Z WARN lan_mouse::config] /home/vini/.config/lan-mouse/config.toml: TOML parse error at line 2, column 18 | 2 | release_bind = [ "KeyLeftBrace", "KeyRightBrace", "KeyBackslash" ] | ^^^^^^^^^^^^^^ unknown variant `KeyLeftBrace`, expected one of `KeyReserved`, `KeyEsc`, `Key1`, `Key2`, `Key3`, `Key4`, `Key5`, `Key6`, `Key7`, `Key8`, `Key9`, `Key0`, `KeyMinus`, `KeyEqual`, `KeyBackspace`, `KeyTab`, `KeyQ`, `KeyW`, `KeyE`, `KeyR`, `KeyT`, `KeyY`, `KeyU`, `KeyI`, `KeyO`, `KeyP`, `KeyLeftbrace`, `KeyRightbrace`, `KeyEnter`, `KeyLeftCtrl`, `KeyA`, `KeyS`, `KeyD`, `KeyF`, `KeyG`, `KeyH`, `KeyJ`, `KeyK`, `KeyL`, `KeySemicolon`, `KeyApostrophe`, `KeyGrave`, `KeyLeftShift`, `KeyBackslash`, `KeyZ`, `KeyX`, `KeyC`, `KeyV`, `KeyB`, `KeyN`, `KeyM`, `KeyComma`, `KeyDot`, `KeySlash`, `KeyRightShift`, `KeyKpAsterisk`, `KeyLeftAlt`, `KeySpace`, `KeyCapsLock`, `KeyF1`, `KeyF2`, `KeyF3`, `KeyF4`, `KeyF5`, `KeyF6`, `KeyF7`, `KeyF8`, `KeyF9`, `KeyF10`, `KeyNumlock`, `KeyScrollLock`, `KeyKp7`, `KeyKp8`, `KeyKp9`, `KeyKpMinus`, `KeyKp4`, `KeyKp5`, `KeyKp6`, `KeyKpplus`, `KeyKp1`, `KeyKp2`, `KeyKp3`, `KeyKp0`, `KeyKpDot`, `Invalid`, `KeyZenkakuhankaku`, `Key102nd`, `KeyF11`, `KeyF12`, `KeyRo`, `KeyKatakana`, `KeyHiragana`, `KeyHenkan`, `KeyKatakanahiragana`, `KeyMuhenkan`, `KeyKpJpComma`, `KeyKpEnter`, `KeyRightCtrl`, `KeyKpslash`, `KeySysrq`, `KeyRightalt`, `KeyLinefeed`, `KeyHome`, `KeyUp`, `KeyPageup`, `KeyLeft`, `KeyRight`, `KeyEnd`, `KeyDown`, `KeyPagedown`, `KeyInsert`, `KeyDelete`, `KeyMacro`, `KeyMute`, `KeyVolumeDown`, `KeyVolumeUp`, `KeyPower`, `KeyKpequal`, `KeyKpplusminus`, `KeyPause`, `KeyScale`, `KeyKpcomma`, `KeyHanguel`, `KeyHanja`, `KeyYen`, `KeyLeftMeta`, `KeyRightmeta`, `KeyCompose`, `KeyStop`, `KeyAgain`, `KeyProps`, `KeyUndo`, `KeyFront`, `KeyCopy`, `KeyOpen`, `KeyPaste`, `KeyFind`, `KeyCut`, `KeyHelp`, `KeyMenu`, `KeyCalc`, `KeySetup`, `KeySleep`, `KeyWakeup`, `KeyFile`, `KeySendfile`, `KeyDeletefile`, `KeyXfer`, `KeyProg1`, `KeyProg2`, `KeyWww`, `KeyMsdos`, `KeyCoffee`, `KeyRotateDisplay`, `KeyCyclewindows`, `KeyMail`, `KeyBookmarks`, `KeyComputer`, `KeyBack`, `KeyForward`, `KeyClosecd`, `KeyEjectcd`, `KeyEjectclosecd`, `KeyNextsong`, `KeyPlaypause`, `KeyPrevioussong`, `KeyStopcd`, `KeyRecord`, `KeyRewind`, `KeyPhone`, `KeyIso`, `KeyConfig`, `KeyHomepage`, `KeyRefresh`, `KeyExit`, `KeyMove`, `KeyEdit`, `KeyScrollup`, `KeyScrolldown`, `KeyKpleftparen`, `KeyKprightparen`, `KeyNew`, `KeyRedo`, `KeyF13`, `KeyF14`, `KeyF15`, `KeyF16`, `KeyF17`, `KeyF18`, `KeyF19`, `KeyF20`, `KeyF21`, `KeyF22`, `KeyF23`, `KeyF24`, `Invalid1`, `Invalid2`, `Invalid3`, `Invalid4`, `Invalid5`, `KeyPlaycd`, `KeyPausecd`, `KeyProg3`, `KeyProg4`, `KeyAllApplications`, `KeySuspend`, `KeyClose`, `KeyPlay`, `KeyFastforward`, `KeyBassboost`, `KeyPrint`, `KeyHp`, `KeyCamera`, `KeySound`, `KeyQuestion`, `KeyEmail`, `KeyChat`, `KeySearch`, `KeyConnect`, `KeyFinance`, `KeySport`, `KeyShop`, `KeyAlterase`, `KeyCancel`, `KeyBrightnessdown`, `KeyBrightnessup`, `KeyMedia`, `KeySwitchvideomode`, `KeyKbdillumtoggle`, `KeyKbdillumdown`, `KeyKbdillumup`, `KeySend`, `KeyReply`, `KeyForwardmail`, `KeySave`, `KeyDocuments`, `KeyBattery`, `KeyBluetooth`, `KeyWlan`, `KeyUwb`, `KeyUnknown`, `KeyVideoNext`, `KeyVideoPrev`, `KeyBrightnessCycle`, `KeyBrightnessAuto`, `KeyDisplayOff`, `KeyWwan`, `KeyRfkill`, `KeyMicmute`, `KeyCount` ``` Sorry if this is some implementation limitation that I don't know of.
Author
Owner

@feschber commented on GitHub (Mar 26, 2026):

no this doesn't have a technical reason, its just inconsistent

<!-- gh-comment-id:4135038311 --> @feschber commented on GitHub (Mar 26, 2026): no this doesn't have a technical reason, its just inconsistent
Author
Owner

@vinivosh commented on GitHub (Mar 30, 2026):

Maybe it'd be ideal to add some kind of alias to some keys, to deal with these inconsistencies? Or maybe even compare the keycode in lowercase, if no ambiguity arises with this approach?

<!-- gh-comment-id:4155756526 --> @vinivosh commented on GitHub (Mar 30, 2026): Maybe it'd be ideal to add some kind of alias to some keys, to deal with these inconsistencies? Or maybe even compare the keycode in lowercase, if no ambiguity arises with this approach?
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/lan-mouse#208
No description provided.