zoukankan      html  css  js  c++  java
  • 修改自定义大小的桌面屏幕分辨率

    在ubuntu14.04虚拟机上修改自定义大小的桌面屏幕分辨率,使用的命令:cvt,xrandr

    0、首先查看下当前已经提供的分辨率设置: -q

    root@xxx:/home/xxx/Desktop# xrandr -q
    Screen 0: minimum 1 x 1, current 1504 x 768, maximum 8192 x 8192
    Virtual1 connected primary 1504x768+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
       800x600        60.0 +   60.3  
       2560x1600      60.0  
       1920x1440      60.0  
       1856x1392      60.0  
       1792x1344      60.0  
       1920x1200      59.9  
       1600x1200      60.0  
       1680x1050      60.0  
       1400x1050      60.0  
       1280x1024      60.0  
       1440x900       59.9  
       1280x960       60.0  
       1360x768       60.0  
       1280x800       59.8  
       1152x864       75.0  
       1280x768       59.9  
       1024x768       60.0  
       640x480        59.9  
       1504x768_60.00   59.9* 
    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)

    红色部分是我标明的,Virtual1 设备名称,后面会用到,maximum 8192 x 8192最大支持分辨率;

    1、在终端输入:cvt 1920 1080,显示如下:

    root@xxx:/home/xxx/Desktop# cvt 1920 1080
    # 1920x1080 59.96 Hz (CVT 2.07M9) hsync: 67.16 kHz; pclk: 173.00 MHz
    Modeline "1920x1080_60.00"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync

    红色部分会在--newmode命令中用到,直接复制即可。

      

    2、接下来通过--newmode、--addmode、--output命令即可完成,如下:

    root@xxx:/home/xxx/Desktop# xrandr --newmode "1920x1080_60.00"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
    root@xxx:/home/xxx/Desktop# xrandr --addmode Virtual1 "1920x1080_60.00"
    root@xxx:/home/xxx/Desktop# xrandr --output Virtual1 --mode "1920x1080_60.00"

    此时,屏幕分辨率已经改变了。

     
    简化版本:
    1, xrandr -q 查看VGA名字
    2,xrandr --output Virtual1 --mode "1920x1080" 即可设置分辨率。
     
  • 相关阅读:
    新手ui设计师必备——切图规范
    django1.4日志模块配置及使用
    linux chmod命令和chown命令
    python log
    python curses使用
    css3中变形与动画(三)
    django静态文件配置
    centos7 apache httpd安装和配置django项目
    apache httpd服务器403 forbidden的问题
    centos7 mysql数据库安装和配置
  • 原文地址:https://www.cnblogs.com/soul-stone/p/7967688.html
Copyright © 2011-2022 走看看