NAME

xrandr - primitive command line interface to RandR extension

SYNOPSIS

xrandr [-help] [-display _d_i_s_p_l_a_y] [-q] [-v] [--verbose] [--dryrun] [--screen _s_n_u_m] [--q1] [--q12]
RandR version 1.3 options
[--current] [--noprimary]
Per-output options
[--panning _w_i_d_t_hx_h_e_i_g_h_t[+_x+_y[/_t_r_a_c_k___w_i_d_t_hx_t_r_a_c_k___h_e_i_g_h_t+_t_r_a_c_k___x+_t_r_a_c_k___y[/_b_o_r_d_e_r___l_e_f_t/_b_o_r_d_e_r___t_o_p/_b_o_r_d_e_r___r_i_g_h_t/_b_o_r_d_e_r___b_o_t_t_o_m]]]] [--scale _xx_y] [--transform _a,_b,_c,_d,_e,_f,_g,_h,_i] [--primary]
RandR version 1.2 options
[--prop] [--fb _w_i_d_t_hx_h_e_i_g_h_t] [--fbmm _w_i_d_t_hx_h_e_i_g_h_t] [--dpi _d_p_i] [--newmode _n_a_m_e _m_o_d_e] [--rmmode _n_a_m_e] [--addmode _o_u_t_p_u_t _n_a_m_e] [--delmode _o_u_t_p_u_t _n_a_m_e]
Per-output options
[--output _o_u_t_p_u_t] [--auto] [--mode _m_o_d_e] [--preferred] [--pos _xx_y] [--rate _r_a_t_e] [--reflect _r_e_f_l_e_c_t_i_o_n] [--rotate _o_r_i_e_n_t_a_t_i_o_n] [--left-of _o_u_t_p_u_t] [--right-of _o_u_t_p_u_t] [--above _o_u_t_p_u_t] [--below _o_u_t_p_u_t] [--same-as _o_u_t_p_u_t] [--set _p_r_o_p_e_r_t_y _v_a_l_u_e] [--off] [--crtc _c_r_t_c] [--gamma _r_e_d:_g_r_e_e_n:_b_l_u_e]


RandR version 1.0 and version 1.1 options
[-o _o_r_i_e_n_t_a_t_i_o_n] [-s _s_i_z_e] [-r _r_a_t_e] [-x] [-y]

DESCRIPTION

Xrandr is used to set the size, orientation and/or reflection of the outputs for a screen. It can also set the screen size.

If invoked without any option, it will dump the state of the outputs, showing the existing modes for each of them, with a '+' after the preferred mode and a '*' after the current mode.

There are a few global options. Other options modify the last output that is specified in earlier parameters in the command line. Multiple outputs may be modified at the same time by passing multiple --output options followed immediately by their corresponding modifying options.

-help Print out a summary of the usage and exit.
-v, --version Print out the RandR version reported by the X server and exit.
--verbose Causes xrandr to be more verbose. When used with -q (or without other
options), xrandr will display more information about the server state. When used along with options that reconfigure the system, progress will be reported while executing the configuration changes.
-q, --query When this option is present, or when no configuration changes are requested,
xrandr will display the current state of the system.
--dryrun Performs all the actions specified except that no changes are made.
--nograb Apply the modifications without grabbing the screen. It avoids to block other
applications during the update but it might also cause some applications that detect screen resize to receive old values.
-d, -display _n_a_m_e This option selects the X display to use. Note this refers to the X
screen abstraction, not the monitor (or output).
--screen _s_n_u_m This option selects which screen to manipulate. Note this refers to the X
screen abstraction, not the monitor (or output).
--q1 Forces the usage of the RandR version 1.1 protocol, even if a higher version
is available.
--q12 Forces the usage of the RandR version 1.2 protocol, even if the display does
not report it as supported or a higher version is available.

RandR version 1.3 options

Options for RandR 1.3 are used as a superset of the options for RandR 1.2.

--current Return the current screen configuration, without polling for hardware changes.
--noprimary Don't define a primary output.

Per-output options

--panning _w_i_d_t_hx_h_e_i_g_h_t[+_x+_y[/_t_r_a_c_k___w_i_d_t_hx_t_r_a_c_k___h_e_i_g_h_t+_t_r_a_c_k___x+_t_r_a_c_k___y[/_b_o_r_d_e_r___l_e_f_t/_b_o_r_d_e_r___t_o_p/_b_o_r_d_e_r___r_i_g_h_t/_b_o_r_d_e_r___b_o_t_t_o_m]]] This option sets the panning parameters. As soon as panning is
enabled, the CRTC position can change with every pointer move. The first four parameters specify the total panning area, the next four the pointer tracking area (which defaults to the same area). The last four parameters specify the border and default to 0. A width or height set to zero disables panning on the according axis. You typically have to set the screen size with _-_-_f_b simultaneously.
--transform _a,_b,_c,_d,_e,_f,_g,_h,_i Specifies a transformation matrix to apply on the output. Automatically a bilinear filter is selected.
The mathematical form corresponds to: a b c
d e f
g h i The transformation matrix multiplied by a coordinate vector of a pixel of the output (extended to 3 values) gives the approximate coordinate vector of a pixel in the graphic buffer. Typically, _a and _e corresponds to the scaling on the X and Y axes, _c and _f corresponds to the tranlastion on those axes, and _g, _h, and _i are respectively 0, 0 and 1. It also allows to express a rotation of an angle T with: cos T -sin T 0
sin T cos T 0
0 0 1 As a special argument, instead of passing a matrix, one can pass the string _n_o_n_e, in which case the default values are used (a unit matrix without filter).
--scale _xx_y Changes the dimensions of the output picture. Values superior to 1 will lead to
a compressed screen (screen dimension bigger than the dimension of the output mode), and values below 1 leads to a zoom in on the output. This option is actually a shortcut version of the _-_-_t_r_a_n_s_f_o_r_m option.
--primary Set the output as primary.
It will be sorted first in Xinerama and RANDR geometry requests.

RandR version 1.2 options

These options are only available for X server supporting RandR version 1.2 or newer.
--prop, --properties This option causes xrandr to display the contents of properties for each
output. --verbose also enables --prop.
--fb _w_i_d_t_hx_h_e_i_g_h_t Reconfigures the screen to the specified size. All configured monitors must
fit within this size. When this option is not provided, xrandr computes the smallest screen size that will hold the set of configured outputs; this option provides a way to override that behaviour.
--fbmm _w_i_d_t_hx_h_e_i_g_h_t Sets the reported values for the physical size of the screen. Normally,
xrandr resets the reported physical size values to keep the DPI constant. This overrides that computation.
--dpi _d_p_i This also sets the reported physical size values of the screen, it uses the
specified DPI value to compute an appropriate physical size using whatever pixel size will be set.
--newmode _n_a_m_e _m_o_d_e New modelines can be added to the server and then associated with outputs.
This option does the former. The _m_o_d_e is specified using the ModeLine syntax for xorg.conf: hdisp hsyncstart hsyncend htotal vdisp vsyncstart vsyncend vtotal _f_l_a_g_s. _f_l_a_g_s can be zero or more of +HSync, -HSync, +VSync, -VSync, Interlace, DoubleScan, CSync, +CSync, -CSync. Several tools permit to compute the usual modeline from a height, width, and refresh rate, for instance you can use ccvvtt.
--rmmode _n_a_m_e This removes a mode from the server if it is otherwise unused.
--addmode _o_u_t_p_u_t _n_a_m_e Add a mode to the set of valid modes for an output.
--delmode _o_u_t_p_u_t _n_a_m_e Remove a mode from the set of valid modes for an output.

Per-output options

--output _o_u_t_p_u_t Selects an output to reconfigure. Use either the name of the output or the
XID.
--auto For connected but disabled outputs, this will enable them using their
preferred mode (or, something close to 96dpi if they have no preferred mode). For disconnected but enabled outputs, this will disable them.
--mode _m_o_d_e This selects a mode. Use either the name or the XID for _m_o_d_e
--preferred This selects the same mode as --auto, but it doesn't automatically enable or
disable the output.
--pos _xx_y Position the output within the screen using pixel coordinates. In case reflection
or rotation is applied, the translation is applied after the effects.
--rate _r_a_t_e This marks a preference for refresh rates close to the specified value, when
multiple modes have the same name, this will select the one with the nearest refresh rate.
--reflect _r_e_f_l_e_c_t_i_o_n Reflection can be one of 'normal' 'x', 'y' or 'xy'. This causes the output
contents to be reflected across the specified axes.
--rotate _r_o_t_a_t_i_o_n Rotation can be one of 'normal', 'left', 'right' or 'inverted'. This causes
the output contents to be rotated in the specified direction. 'right' specifies a clockwise rotation of the picture and 'left' specifies a counter-clockwise rotation.
--left-of, --right-of, --above, --below, --same-as _a_n_o_t_h_e_r_-_o_u_t_p_u_t Use one of these options to position the output relative to the position of
another output. This allows convenient tiling of outputs within the screen. The position is always computed relative to the new position of the other output, so it is not valid to say --output a --left-of b --output b --left-of a.
--set _p_r_o_p_e_r_t_y _v_a_l_u_e Sets an output property. Integer properties may be specified as a valid
(see --prop) decimal or hexadecimal (with a leading 0x) value. Atom properties may be set to any of the valid atoms (see --prop). String properties may be set to any value.
--off Disables the output.
--crtc _c_r_t_c Uses the specified crtc (either as an index in the list of CRTCs or XID).
In normal usage, this option is not required as xrandr tries to make sensible choices about which crtc to use with each output. When that fails for some reason, this option can override the normal selection.
--gamma _r_e_d:_g_r_e_e_n:_b_l_u_e Set the specified floating point values as gamma correction on the crtc
currently attached to this output. Note that you cannot get two different values for cloned outputs and that switching an output to another crtc doesn't change the crtc gamma corrections at all.

RandR version 1.1 options

These options are available for X servers supporting RandR version 1.1 or older. They are still valid for newer X servers, but they don't interact sensibly with version 1.2 options on the same command line.
-s, --size _s_i_z_e_-_i_n_d_e_x or --size _w_i_d_t_hx_h_e_i_g_h_t This sets the screen size, either matching by size or using the index into
the list of available sizes.
-r, --rate, --refresh _r_a_t_e This sets the refresh rate closest to the specified value.
-o, --orientation _r_o_t_a_t_i_o_n This specifies the orientation of the screen,
and can be one of normal, inverted, left or right.
-x Reflect across the X axis.
-y Reflect across the Y axis.

EXAMPLES

Sets an output called LVDS to its preferred mode, and on its right put an output called VGA to preferred mode of a screen which has been physically rotated clockwise: xrandr --output LVDS --auto --rotate normal --pos 0x0 --output VGA --auto --rotate left --right-of LVDS

Forces to use a 1024x768 mode on an output called VGA: xrandr --newmode "1024x768" 63.50 1024 1072 1176 1328 768 771 775 798 -hsync +vsync
xrandr --addmode VGA 1024x768
xrandr --output VGA --mode 1024x768

Enables panning on a 1600x768 desktop while displaying 1024x768 mode on an output called VGA: xrandr --fb 1600x768 --output VGA --mode 1024x768 --panning 1600x0

Have one small 1280x800 LVDS screen showing a small version of a huge 3200x2000 desktop, and have a big VGA screen display the surrounding of the mouse at normal size. xrandr --fb 3200x2000 --output LVDS --scale 2.5x2.5 --output VGA --pos 0x0 --panning 3200x2000+0+0/3200x2000+0+0/64/64/64/64

SEE ALSO

Xrandr(3), cvt(1)

AUTHORS

Keith Packard, Open Source Technology Center, Intel Corporation. and Jim Gettys, Cambridge Research Laboratory, HP Labs, HP.