WeirdTreeThing / cros-keyboard-map

Utility to generate keyd configurations for use on Chromebooks
BSD 3-Clause "New" or "Revised" License
43 stars 10 forks source link

F5 broken on devices with a screenshot key #26

Closed gdbaldw closed 3 weeks ago

gdbaldw commented 1 month ago

The top row keys work as intended. But, the Meta Key does not change their behavior. No function keys.

How can I help debug this issue?

gdbaldw commented 1 month ago

Trying different key combinations, I stumbled on <CTRL><ALT><META><top row key> from the left gives tty1, tty2, tty3, tty4, but not tty5+. And, I can't return to the graphical display from the tty.

WeirdTreeThing commented 1 month ago

If you let go of every mod key, press them again, and then press f6+, will that work? I've noticed that f5 seems to not work as intended on newer devices, not yet sure why though.

gdbaldw commented 1 month ago

Yes! Letting go and pressing again gives me f6 and for f7, returns to graphic mode. Very good.

Can we debug the <CTRL><ALT> modifier needed for <META>? How about f5?

It all works ok for my needs, however if we can debug further, I'm game.

WeirdTreeThing commented 1 month ago

I have a device affected by this, so I can debug whenever I have the time to.

ChocolateLoverRaj commented 3 weeks ago

I'm not using this script, but F5 (and other Meta+top row keys) is working perfectly on my jinlon on NixOS with keyd v2.4.3. I am not switching ttys though. That might be part of the problem.

WeirdTreeThing commented 3 weeks ago

This issue only affects devices that have a screenshot key where the default behavior is to act like the printscreen (sysrq) key. I have no clue if that's how jinlon behaves. I suspect the issue is related to sysrq being treated special by linux and/or keyd.

WeirdTreeThing commented 3 weeks ago

This also makes me realize that jinlon is probably another edge case device where I can't detect the layout.

ChocolateLoverRaj commented 3 weeks ago

Oh yeah I started having a problem with the screenshot key being "sysreq". I updated my keyd config so that Super+Screenshot does F5. I didn't have to include it in main since "sysreq" takes a screenshot OOTB anyways.

WeirdTreeThing commented 3 weeks ago

Sure enough, replacing print with sysrq fixes this issue.