1)首先看显示信息
$ xrandr
显示:
DP1 disconnected (normal left inverted right x axis y axis)
DP2 connected (normal left inverted right x axis y axis)
1920x1080 59.93 +
HDMI1 disconnected (normal left inverted right x axis y axis)
HDMI2 disconnected (normal left inverted right x axis y axis)
VGA1 connected primary 1440x900+0+0 (normal left inverted right x axis y axis) 410mm x 256mm
1440x900 59.89*+
1280x1024 75.02 60.02
1280x960 60.00
1152x864 75.00
1024x768 75.08 60.00
832x624 74.55
800x600 75.00 60.32
640x480 75.00 60.00
720x400 70.08
VIRTUAL1 disconnected (normal left inverted right x axis y axis)
2)设置主屏
$ xrandr --output VGA1 --auto --primary
我这里是VGA为我想只显示的
3)删除其它屏
rosfun@sugar-desktop:~$ xrandr --output DP2 --off
rosfun@sugar-desktop:~$ xrandr --output DP1 --off
rosfun@sugar-desktop:~$ xrandr --output HDMI1 --off
rosfun@sugar-desktop:~$ xrandr --output HDMI2 --off