为什么/usr/share/X11/xkb/rules中的文件evdev与evdev.lst不匹配? [英] why does the file evdev in /usr/share/X11/xkb/rules not match with evdev.lst?

查看:348
本文介绍了为什么/usr/share/X11/xkb/rules中的文件evdev与evdev.lst不匹配?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

似乎evdev.lst中列出的setxkbmap的某些选项实际上未被随附的evdev文件支持.例如,如

it seems that some options to setxkbmap which are listed in evdev.lst are not actually supported by the accompanying evdev file. For example ctrl:nocaps is supported but ctrl:swap_lalt_lctl is not, as evidenced by

$ grep 'ctrl:nocaps' /usr/share/X11/xkb/rules/evdev{,.lst}
/usr/share/X11/xkb/rules/evdev:  ctrl:nocaps        =   +ctrl(nocaps)
/usr/share/X11/xkb/rules/evdev.lst:  ctrl:nocaps          Caps Lock as Ctrl
$ grep 'ctrl:swap_lalt_lctl_lwin' /usr/share/X11/xkb/rules/evdev{,.lst} 
/usr/share/X11/xkb/rules/evdev.lst:  ctrl:swap_lalt_lctl_lwin Left Alt as Ctrl, Left Ctrl as Win, Left Win as Alt
$

这使我无法使用缺少的选项,如我先前的问题中所述

This is causing me to be unable to use the missing options, as detailed in my earlier question Why are some setxkbmap options ignored? As a bonus question, is there any way in which I can cause these missing options to be supported?

推荐答案

我遇到了同样的问题,很高兴找到答案.

I am experiencing the same issue and would be happy to find the answer to this.

我正在Macbook 5,2(2009年初)上运行带有GNOME v3.14.1的最新Debian Jessie-到目前为止,我测试过的所有其他按键绑定似乎都奏效.我有一个猜测,原因是:

I am running recent Debian Jessie with GNOME v3.14.1 on a Macbook 5,2 (Early 2009) - all other keybindings I tested so far seem to work. I have a guess for the reason:

"gnome-tweak-tools > Typing > Alt/Win key behaviour"

只有这个选项"Ctrl is mapped to Win **keys** (And the Ctrl keys)"-也许这与问题有关,因为我在某处读到了GNOME覆盖其他键盘映射设置的信息...我试图在dconf-editor中添加键盘绑定;也-不起作用.

there is only this option "Ctrl is mapped to Win **keys** (And the Ctrl keys)" --maybe this is related to the problem because I read somehwhere that GNOME overrides other keymapping settings... I tried adding the keybindings in dconf-editor; also - not working.

编辑:我找到了一个临时解决方法: Superuser Xmodmap解决方法

I found a temporary workaround for this: Superuser Xmodmap Workaround

这是一个复制粘贴游戏,其后是命令

It's a copy&paste game followed by the command

# xmodmap /path/to/yoursavedfile

但是请注意,一旦您更改了GNOME中与快捷键或其他键绑定相关的任何键盘相关设置,它将覆盖此设置,因此您必须重新运行该命令.它可以立即运行,而无需重新登录.尚不知道它在下次启动时是否持久-如果不是,我将在这里报告!

But notice that once you alter any keyboard related settings in GNOME like shortcuts or other keybindings it will override this and you have to rerun the command. It works instantly without a relogin/restart for me though. Don't know yet if it's persistent upon next boot - I will report here if it isn't!

:重启并恢复后,GNOME会通过xmodmap覆盖键盘设置.

Upon reboot and resume GNOME overrides keyboard settings by xmodmap.

我找到了一种使键盘映射在重启,恢复&后永久显示的方法.登录,使用以下python脚本作为自动启动脚本: xmodmap-reload-script 此处

I found a way to make the keyboard mapping permanent after reboot, resume & login, using this python script as an autostart script: xmodmap-reload-script found here

在此模板的启发下,在〜/.config/autostart中创建一个新的.desktop文件 debian在启动时运行python脚本

by creating a new .desktop file in ~/.config/autostart inspired by this template debian run python script on startup

[Desktop Entry] 
Type=Application
Exec=python /path/to/your/application.py arguments

这篇关于为什么/usr/share/X11/xkb/rules中的文件evdev与evdev.lst不匹配?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆