VirtualBox 上で Ubuntu 20.04.1 LTS の ISO を用いて作業する際に、起動直後の解像度が 800x600 なのをいちいち、右上の「電源」アイコン→「Settings」で gnome-control-center 開いて、「Display」→Resolution「1920x1200(16:10)」みたいに選択するの面倒くさいなと。
「Ubuntu desktop resolution change command」でググったら以下のページを見つけた。
- StackExchange / ask ubuntu / 2013-04-14: How do I change the screen resolution using Ubuntu command line?
xrandr [-d <DISPLAY>] -qで調べて
xrandr [-d <DISPLAY>] --output <OUTPUT> --mode <RESOLUTION>で設定しろと。
ubuntu@ubuntu:~$ xrandr -q Screen 0: minimum 1 x 1, current 1920 x 1200, maximum 8192 x 8192 Virtual1 connected primary 1920x1200+0+0 (normal left inverted right x axis y axis) 0mm x 0mm 800x600 60.00 + 60.32 2560x1600 59.99 1920x1440 60.00 1856x1392 60.00 1792x1344 60.00 1920x1200 59.88* 1600x1200 60.00 1680x1050 59.95 1400x1050 59.98 1280x1024 60.02 1440x900 59.89 1280x960 60.00 1360x768 60.02 1280x800 59.81 1152x864 75.00 1280x768 59.87 1024x768 60.00 640x480 59.94 Virtual2 disconnected (normal left inverted right x axis y axis) Virtual3 disconnected (normal left inverted right x axis y axis) Virtual4 disconnected (normal left inverted right x axis y axis) Virtual5 disconnected (normal left inverted right x axis y axis) Virtual6 disconnected (normal left inverted right x axis y axis) Virtual7 disconnected (normal left inverted right x axis y axis) Virtual8 disconnected (normal left inverted right x axis y axis)
$ xrandr --output Virtual1 --mode 1920x1200
$ xrandr -d :0 -q Screen 0: minimum 320 x 200, current 2560 x 1440, maximum 16384 x 16384 VGA-1 disconnected (normal left inverted right x axis y axis) HDMI-1 disconnected (normal left inverted right x axis y axis) HDMI-2 disconnected (normal left inverted right x axis y axis) DP-1 connected primary 2560x1440+0+0 (normal left inverted right x axis y axis) 597mm x 336mm 2560x1440 59.95*+ 1920x1200 59.88 1920x1080 60.00 60.00 50.00 59.94 24.00 23.98 1920x1080i 60.00 50.00 59.94 1600x1200 60.00 1680x1050 59.95 1280x1024 75.02 60.02 1280x800 59.81 1152x864 75.00 1280x720 60.00 50.00 59.94 1024x768 75.03 60.00 800x600 75.00 60.32 720x576 50.00 720x480 60.00 59.94 640x480 75.00 60.00 59.94 720x400 70.08 HDMI-3 disconnected (normal left inverted right x axis y axis)
タグ
コメントをかく