I like my resolution lower than Sabayon's default

If you are new to Linux or new to Sabayon Linux and just not sure where to post, here ya go. Post without fear of being told to RTFM :-)

Moderator: Moderators

I like my resolution lower than Sabayon's default

Postby Trespasser » Sat Feb 13, 2010 1:50

Hi,
I'm relatively new to Sabayon (I tried it about a year ago) but not to Linux (5 years and counting). I download 5.1 and installed it today on my Lenovo G530 laptop and everything's fine except for my screen resolution. The default resolution is 1280x800 but my wife and like it at 800x600. The only problem is when I set it at 800x600 I get these 2 to 3 inch black bars or borders on either side of the main screen. In other words, the screen draws in from the side. My lspci graphics card info is as follows....

00:00.0 Host bridge: Intel Corporation Mobile 4 Series Chipset Memory Controller Hub (rev 09)
00:02.0 VGA compatible controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 09)
00:02.1 Display controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 09)

My xorg.conf shows that it is using an intel driver.

Is there anything I can do or adjust to get a fully utilized screen? I don't have this problem in Ubuntu. BTW, the same problem on the 1024x768 setting as well. Only the 1280x800 setting functions as I would term normally.

Thanks for any help on this matter.

Later...
Trespasser
Baby Hen
 
Posts: 3
Joined: Sat Oct 10, 2009 15:32

Re: I like my resolution lower than Sabayon's default

Postby Fitzcarraldo » Mon Feb 15, 2010 18:47

You don't mention whether you are using KDE or GNOME. Which one is it? And, if the former, which version?

Anyway, if you are having no joy using the KDE System Settings > Display (or whatever the equivalent is in GNOME, as I can't recall now) to adjust monitor resolution, you might like to try doing it using the xrandr command. To give you some examples of how the xrandr command is used, I'll explain how I use it for my own purposes:

I need to use different external monitors at home and at the various offices I visit, so I have created three Desktop Config files on my KDE 4.3.3 Desktop, together with three corresponding Bash scripts. These are all shown below. In my case VGA-0 is the external monitor (CRT or LCD), and LVDS is my laptop's built-in LCD display.

Desktop Config File named Switch_OFF_laptop_monitor_if_external_monitor_is_connected.desktop:
Code: Select all
[Desktop Entry]
Comment[en_GB]=switch off laptop monitor if external monitor is connected
Comment=switch off laptop monitor if external monitor is connected
Exec=sh /home/fitzcarraldo/switch_off_laptop_monitor_if_external_monitor_is_connected.sh
GenericName[en_GB]=switch off laptop monitor if external monitor is connected
GenericName=switch off laptop monitor if external monitor is connected
Icon=video-display
MimeType=
Name[en_GB]=switch_OFF_laptop_monitor_if_external_monitor_is_connected
Name=switch_OFF_laptop_monitor_if_external_monitor_is_connected
Path=
StartupNotify=true
Terminal=true
TerminalOptions=
Type=Application
X-DBUS-ServiceName=
X-DBUS-StartupType=none
X-KDE-SubstituteUID=false
X-KDE-Username=

The Bash script switch_off_laptop_monitor_if_external_monitor_is_connected.sh which it calls:
Code: Select all
#!/bin/bash
echo -n "Enter resolution width of external monitor (hint 1920 office1, 1440 home): "
read EXTERNAL_WIDTH
echo -n "Enter resoluton height of external monitor (hint 1080 office1, 900 home): "
read EXTERNAL_HEIGHT
if xrandr -q | grep -q  "VGA-0 connected"; then
  xrandr --output LVDS --off
  xrandr --output VGA-0 --off
  xrandr --output VGA-0 --mode $EXTERNAL_WIDTH"x"$EXTERNAL_HEIGHT
else
  xrandr --output VGA-0 --off
  xrandr --output LVDS --off
  xrandr --output LVDS --mode 1680x1050
fi


Desktop Config File named switch_ON_laptop_monitor_and_external_monitor.desktop:
Code: Select all
[Desktop Entry]
Comment[en_GB]=switch_ON_laptop_monitor_and_external_monitor
Comment=switch_ON_laptop_monitor_and_external_monitor
Exec=sh /home/fitzcarraldo/switch_on_laptop_monitor_and_external_monitor.sh
GenericName[en_GB]=switch_ON_laptop_monitor_and_external_monitor
GenericName=switch_ON_laptop_monitor_and_external_monitor
Icon=video-display
MimeType=
Name[en_GB]=switch_ON_laptop_monitor_and_external_monitor
Name=switch_ON_laptop_monitor_and_external_monitor
Path=
StartupNotify=true
Terminal=true
TerminalOptions=
Type=Application
X-DBUS-ServiceName=
X-DBUS-StartupType=none
X-KDE-SubstituteUID=false
X-KDE-Username=

The Bash script switch_on_laptop_monitor_and_external_monitor.sh which it calls:
Code: Select all
#!/bin/bash
# Note that the resolution specified must be the same for both monitors, and must be achievable on both monitors.
echo -n "Enter resolution width of external monitor (hint 1280 office1, 1440 home): "
read EXTERNAL_WIDTH
echo -n "Enter resoluton height of external monitor (hint 960 office1, 900 home): "
read EXTERNAL_HEIGHT
#xrandr --output LVDS --off
xrandr --output LVDS --mode $EXTERNAL_WIDTH"x"$EXTERNAL_HEIGHT
xrandr --output VGA-0 --off
xrandr --output VGA-0 --mode $EXTERNAL_WIDTH"x"$EXTERNAL_HEIGHT


Desktop Config File named Switch_ON_laptop_monitor_if_external_monitor_is_connected.desktop:
Code: Select all
[Desktop Entry]
Comment[en_GB]=switch on laptop monitor if external monitor is connected
Comment=switch on laptop monitor if external monitor is connected
Exec=sh /home/fitzcarraldo/switch_on_laptop_monitor_if_external_monitor_is_connected.sh
GenericName[en_GB]=switch on laptop monitor if external monitor is connected
GenericName=switch on laptop monitor if external monitor is connected
Icon=computer-laptop
MimeType=
Name[en_GB]=switch_ON_laptop_monitor_if_external_monitor_is_connected
Name=switch_ON_laptop_monitor_if_external_monitor_is_connected
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
X-DBUS-ServiceName=
X-DBUS-StartupType=
X-KDE-SubstituteUID=false
X-KDE-Username=

The Bash script switch_on_laptop_monitor_if_external_monitor_is_connected.sh which it calls:
Code: Select all
#!/bin/bash
xrandr --output VGA-0 --off
xrandr --output LVDS --on
xrandr --output LVDS --mode 1680x1050


I have configured the three Desktop Config Files to have nice-looking icons, and I just need to double-click on the one I want in order to select the relevant monitor configuration I desire and enter the resolution of the external monitor. Hopefully the above examples will point you in the right direction. Note that there seems to be a bug in the xrandr behaviour, so the above Bash scripts are more convoluted then would first appear to be necessary. I needed to experiment with the commands in order to get the behaviour I desired. Note also that you can simply type xrandr commands directly on the command line; you don't need to create scripts to do it. However I like things to be simple. Also note that the xrandr command does not stick when you reboot, so if you make a mistake and cannot see your GUI screen any more then just reboot (Ctrl-Alt_F1-F6 will get you to a console where you can log-in and type "reboot" or "shutdown now"). There are ways to embed the xrandr command in a file so that it is executed automatically upon boot, but that's for another day.


EDIT (March 3, 2010): Modified script switch_on_laptop_monitor_and_external_monitor.sh as the one I originally posted did not work as intended.
User avatar
Fitzcarraldo
Sagely Hen
 
Posts: 7977
Joined: Sat Mar 10, 2007 5:40
Location: United Kingdom


Return to Beginners|Newbies Area

Who is online

Users browsing this forum: No registered users and 3 guests

cron