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

Can F13- F24 as modify keys ? #89

Open
ifnk opened this issue Jun 9, 2020 · 8 comments
Open

Can F13- F24 as modify keys ? #89

ifnk opened this issue Jun 9, 2020 · 8 comments

Comments

@ifnk
Copy link

ifnk commented Jun 9, 2020

like this !
`import re
from xkeysnail.transform import *

define_multipurpose_modmap(
{Key.CAPSLOCK: [Key.ESC, Key.F14]}
)

define_keymap(None, {
#K("F13"): K("esc"),

    K("F14-l"): K("right"),
    K("F14-k"): K("up"),
    K("F14-h"): K("left"),
    K("F14-j"): K("down"),
    K("F14-p"): K("page_up"),
    K("F14-u"): K("home"),
    K("F14-o"): K("end"),

})`

@rbreaves
Copy link
Contributor

rbreaves commented Jun 14, 2020

You can do those keys, but be aware that some DEs do not like working with F keys above F12, specifically XFCE.

As a result I have had to use other keys such as a backslash to do what I needed done. The XFCE limitation was likely due more to the DE's ability to bind to those keys, the OS itself, according to xbindkeys could still sense and pass the F keys (as their media key value XF86Tools = F13, but as far as using it for certain keybindings in the actual DE.. that was not possible for whatever reason - but admittingly Alt-Tab is a very tricky one to remap in general.)

define_keymap(None,{
    # Basic App hotkey functions
    K("RC-Q"): K("Alt-F4"),
    K("RC-H"): K("Alt-F9"),
    # Cmd Tab - App Switching Default
    K("RC-Tab"): K("RC-F13"),                     # Default not-xfce4
    K("RC-Shift-Tab"): K("RC-Shift-F13"),         # Default not-xfce4
    K("RC-Grave"): K("M-F6"),                     # Default not-xfce4
    K("RC-Shift-Grave"): K("M-Shift-F6"),         # Default not-xfce4
    # K("RC-Tab"): K("RC-backslash"),               # xfce4
    # K("RC-Shift-Tab"): K("RC-Shift-backslash"),   # xfce4
    # K("RC-Grave"): K("RC-Shift-backslash"),       # xfce4

@iterating
Copy link

The only allowed modifier keys are Ctrl, Alt, Shift, and Super(Meta). F13 to F18 can be mapped as normal keys, as well as F21-23, SCALE DASHBOARD CALC, PROG2-4, phone, finance, shop, sport, and chat.

Alt tab and ctrl-f13 can flip windows.

@rbreaves
Copy link
Contributor

rbreaves commented Jul 4, 2020

Hmmm well my assumption is that they’d work, but perhaps xkeysnail might need those F keys to be added to a modifier key array now that I think about it.

@iterating
Copy link

Would window managers be able to use these new modifier keys?

@rbreaves
Copy link
Contributor

rbreaves commented Jul 4, 2020

Would window managers be able to use these new modifier keys?

Revising, I am not certain, but I wouldn’t expect xfce to. Also Mate on ARM may have difficulties from what RedBear has recently been reporting to me. The arm issue may be an issue w/ xkbcomp related files not covering/supporting the same keyboard layout as most distros. That’s what I suspect any ways, could be wrong on the reason.

It’s also very dependent on the DE, Budgie hard coded Alt-Tab to only use expected modifiers on Windows Switching, except for Ctrl & yet other parts of the DE I think could bind to any combo.

Note: redbear reports issues to me via my Kinto.sh project which uses xkeysnail.

@iterating
Copy link

iterating commented Jul 5, 2020 via email

@joshgoebel
Copy link

xkeysnail might need those F keys to be added to a modifier key array now that I think about it.

It would indeed [need them added to the Modifier class] to use them as modifiers in keymap combos...

Yes, it would helpful to have dedicated modifier keys for certain actions.

Can you provide a few specific example of "certain actions"?

@joshgoebel
Copy link

joshgoebel commented Jun 20, 2022

Yes, it would helpful to have dedicated modifier

@iterating My fork now allows adding new modifiers (from the keymappers perspective) - though it may still come down to whether the software you're using will properly support those keys or not. For example Fn can now be used as a modifier (for keyboards that support it... and I'm using a new Hyper modifier for all my WM key combos - though I did have to use xmodmap to tell X about the new modifier and assign it to the virtual mod3 key...

https://github.com/joshgoebel/keyszer

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

4 participants