我使用 dconf-editor 编辑 org.gnome.settings-daemon.plugins.power 中的睡眠按钮选项,但它什么也没做,我所要做的就是用关闭显示器来替换让 Ubuntu 进入睡眠状态的所有内容,而这个过程的最后一步是更改设置,我知道问题不在于 dconf-editor,因为 gsettings 显示设置已更改为我想要的。
我的键盘是一个旧的廉价 emachines 键盘,使用 ps/2 端口,如果有区别的话。
澄清:我想要的是将按钮睡眠设置为“空白”,但当我将其设置为“空白”时,按下睡眠键时它不会使屏幕变黑,而是会暂停计算机
cat /etc/systemd/logind.conf 的输出:
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See logind.conf(5) for details.
[Login]
#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=no
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
HandleSuspendKey=ignore
#HandleHibernateKey=hibernate
#HandleLidSwitch=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#HoldoffTimeoutSec=30s
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RemoveIPC=yes
#InhibitorsMax=8192
#SessionsMax=8192
#UserTasksMax=33%