Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am making a script that needs to access the computer's monitor(s) configuration. How can I do that? Is there a command or a file I could read where I can access this information?

At the moment, I do

xwininfo -root

But I only have the total resolution and not the details (What I need is the resolution of each screen individually).


share|improve this question
do you have access to the xserver while executing the script? do you want to know the limits of the hardware (the monitors)? do you want to know what resolutions are configure in Xorg.conf? – akira Jan 19 '11 at 15:19
I want to know what resolutions are configured in Xorg.conf, except that as I am running Fedora 14, by default I don't have a Xorg.conf. – nbarraille Jan 19 '11 at 15:34
up vote 2 down vote accepted

If your video driver supports it, xrandr will display the available and current resolutions for all displays.

share|improve this answer
Exactly what I needed, thanks! – nbarraille Jan 19 '11 at 15:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .