ubuntu18.04下禁用Ctrl+Alt+Left/Right的方式(解决IDEA后退、前进快捷键的冲突)
1.查看是否被系统组合键占用
- gsettings get org.gnome.desktop.wm.keybindings switch-to-workspace-left
返回:[‘
Left‘] 结果:说明被 Control + Alt + Left 组合键占用
- gsettings get org.gnome.desktop.wm.keybindings switch-to-workspace-right
返回:[‘
Right‘] 结果:说明被 Control + Alt + Right 组合键占用
2.解除系统组合键占用
下面分别是针对:Ctrl+Alt+Left和Ctrl+Alt+Right
gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-left "[]"
gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-right "[]"
错误记录
按照上述的命令进行解决的时候我是报了以下的错误:
1. 问题描述
如题,设置gsetting时遇到错误Using the ‘memory‘ GSettings backend. Your settings will not be saved or shared with other applications.
,如下图所示:
2. 解决方法
S1. 用文本编辑器打开环境变量配置:
sudo gedit ~/.bashrc
S2. 修改环境变量,在环境变量末尾添加:
# for GIO
export GIO_EXTRA_MODULES=/usr/lib/x86_64-linux-gnu/gio/modules/
S3. 保存环境变量文件,关闭gedit编辑器,然后运行下面的命令立即生效:
source ~/.bashrc
S4. 至此,问题得到解决。