Forrest logo
back to the xrandr tool

xrandr:tldr:75584

xrandr: Set the resolution of HDMI2 to 1280x1024 and put it on the right of DP1.
$ xrandr --output ${HDMI2} --mode ${1280x1024} --right-of ${DP1}
try on your machine

This command is using the xrandr tool to configure the display settings for the two specified monitors.

Here is a breakdown of the command:

  • xrandr: This is the command line tool for configuring the display settings in X Window System.
  • --output ${HDMI2}: This specifies the output or monitor that will be configured. ${HDMI2} is a placeholder for the specific name or identifier of the HDMI2 monitor.
  • --mode ${1280x1024}: This sets the resolution mode for the specified output. ${1280x1024} is a placeholder for the desired resolution, in this case, 1280x1024 pixels.
  • --right-of ${DP1}: This sets the position of the specified output relative to another output. ${DP1} is a placeholder for the name or identifier of the DP1 monitor. In this case, the HDMI2 monitor will be positioned to the right of the DP1 monitor.

Overall, this command configures the HDMI2 monitor to use a resolution of 1280x1024 pixels and positions it to the right of the DP1 monitor.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the xrandr tool