Linux设置屏幕不熄屏-全屏化运行时均有效

Linux设置屏幕不熄灭

通过xorg.conf方式设置屏幕不熄灭屏幕,尤其是对需要开机自动全屏化运行自己编写的Qt桌面程序时,可以保证Qt界面程序,运行时,屏幕常亮

建立xorg.conf文件,内容如下

Section "Device"
	Identifier	"Configured Video Device"
EndSection
Section "Monitor"
	Identifier	"Configured Monitor"
	HorizSync	30.0-62.0
	VertRefresh	50.0-70.0
EndSection

#屏幕熄屏设置,设置屏幕常亮,此段代码用来设置屏幕常亮
Section "ServerFlags"
	Option	"BlankTime" "0"
	Option	"StandbyTime" "0"
	Option	"SuspendTime" "0"
	Option	"OffTime" "0"
EndSection


#其它设置:分辨率设置
Section "Screen"
	Identifier	"Default Screen"
	Monitor	"Configured Monitor"
	Device	"Configured Video Device"
	DefaultDepth	24
	SubSection	"Display"
		Depth	24
		Modes	"1024x768"
	EndSubSection
EndSection

xorg.conf 拷贝到/etc/X11/ 目录下,赋予可执行权限

chmod +x xorg.conf

  • 6
    点赞
  • 20
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值