Is it possible to enable rules only for specific keyboard layout (karabiner)?

五迷三道 提交于 2020-03-04 15:37:46

问题


On Karabiner I am enabling multiples rules under its complex modifications setup, such as Emacs key bindings.

I was wondering is it possible to use those enables rules only for a specific keyboard layout such as U.S. and automatically disable those rules when I switch to an another keyboard layout.


回答1:


It's not possible to turn existing imported rules to be device specific. However if you make or modify those rules you can.

https://pqrs.org/osx/karabiner/json.html#condition-definition-device

The gist of how to make your own rules is making a json file inside

~/.config/karabiner/assets/complex_modifications/

You can name the json file whatever you want. you can even symlink it from another place if you prefer.

So if you have a rule you want to make device specific, copy paste it inside your json file and modify it from type: "basic" to to type: "device_if" and fill up your device id etc. which you can get from the Karabiner EventViewer app under devices tab.



来源:https://stackoverflow.com/questions/60329520/is-it-possible-to-enable-rules-only-for-specific-keyboard-layout-karabiner

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!