Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Function keys on a T2 MacBook Pro running Ubuntu 20.04 #155

Open
pajatopmr opened this issue Mar 10, 2022 · 3 comments
Open

Function keys on a T2 MacBook Pro running Ubuntu 20.04 #155

pajatopmr opened this issue Mar 10, 2022 · 3 comments

Comments

@pajatopmr
Copy link

Using only the configuration shown below I cannot use any function keys. The alternate hardware controls on the touch-bar are shown (brightness, audio) and the fn key (Key.FN) when held down does not switch the touch-bar to function keys, the expected behavior.

# -*- coding: utf-8 -*-

import re
from xkeysnail.transform import *

# define timeout for multipurpose_modmap
define_timeout(1)

# [Multipurpose modmap] Give a key two meanings. A normal key when pressed and
# released, and a modifier key when held down with another key. See Xcape,
# Carabiner and caps2esc for ideas and concept.
define_multipurpose_modmap(
    # Enter is enter when pressed and released. Control when held down.
    {Key.ENTER: [Key.ENTER, Key.RIGHT_CTRL],
    Key.CAPSLOCK: [Key.F13, Key.LEFT_CTRL]}
    # Capslock is escape when pressed and released. Control when held down.
    # {Key.CAPSLOCK: [Key.ESC, Key.LEFT_CTRL]
    # To use this example, you can't remap capslock with define_modmap.
)
@joshgoebel
Copy link

joshgoebel commented May 28, 2022

and the fn key (Key.FN) when held down does not switch the touch-bar to function keys, the expected behavior.

Is that hardware expected to actually work in other operating systems than Mac OS? I wouldn't automatically assume that...

Not sure this has anything to do with us?

@cosmonaut-laika
Copy link

I have the same problem on lenovo x1 carbon 6th gen running arch linux.
Function keys stopped working as they're supposed to. They're now outputing different keys, for instance f6 outputs tilde

@joshgoebel
Copy link

Can either of you run evtest and show us what output those keys even produce? If a key isn't a modifier it should just "pass thru" at a low-level... ie the key you type is the key we pass on... (and then try again and show us the xkeysnail log) Though I can't remember what detail it logs normal keystrokes (if at all)... my fork https://github.com/joshgoebel/keyszer logs plenty when in verbose mode, so that might be worth a try if you get nowhere with xkeysnails logging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants