Created
July 8, 2013 15:29
-
-
Save rkmax/5949843 to your computer and use it in GitHub Desktop.
Arregla la mala configuración en pantallas externas con resolucion poco regulares por parte de xrandr
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# usar el comando 'gtf vres hres hfreq' para obtener la configuracion adecuada | |
# Ejemplo: | |
# | |
# monitor de 1920 x 1200 de 60 Hz | |
# | |
# $ gtf 1920 1200 60 | |
# 1920x1200 @ 60.00 Hz (GTF) hsync: 74.52 kHz; pclk: 193.16 MHz | |
# Modeline "1920x1200_60.00" 193.16 1920 2048 2256 2592 1200 1201 1204 1242 -HSync +Vsync | |
# | |
# El monitor interno del portatil no necesita configuracion | |
# Regularmente el monitor Externo se llama VGA1 | |
# Regularmente el monito interno del portatil se llama LVDS1 | |
MODE_SETUP="193.16 1920 2048 2256 2592 1200 1201 1204 1242 -HSync +Vsync" | |
MODE_NAME="1920x1200_60.00" | |
OUTPUT=VGA1 | |
xrandr --newmode $MODE_NAME $MODE_SETUP | |
xrandr --addmode $OUTPUT $MODE_NAME | |
xrandr --output $OUTPUT --mode $MODE_NAME | |
# esto indica en que lado queires la pantalla externa | |
# xrandr --output $OUTPUT --right-of LVDS1 | |
xrandr --output $OUTPUT --left-of LVDS1 | |
# Esta linea indica cual quieres que sea tu monitor primario | |
# si queires que tu monitor primario sea el interno comenta la siguiente linea | |
xrandr --output $OUTPUT --primary |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment