! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
xfdesktop uses wrong monitor size & offset
Status:
RESOLVED: FIXED
Product:
Xfdesktop
Component:
General

Comments

Description sean-clancy 2011-11-26 19:13:48 CET
I use a Laptop (Linux Mint Debian Edition) with an external monitor. If I boot without the external monitor attached, my monitor size is 1440x900 with an offset +0+180. The offset confuses xfdesktop: It draws the background image with an y-offset of 0, but it should be 180. Also 180 lines of noise appear at the bottom of the screen.

I found the following code that causes the problem:
file src/xfce-desktop.c, line 337ff:

    if(desktop->priv->nbackdrops == 1) {
        /* single monitor */
        rect.x = rect.y = 0;
        rect.width = gdk_screen_get_width(gscreen);
        rect.height = gdk_screen_get_height(gscreen);
    } else
        gdk_screen_get_monitor_geometry(gscreen, monitor, &rect);

it works correct if I just ignore the test and only use this code:

    gdk_screen_get_monitor_geometry(gscreen, monitor, &rect);
Comment 1 Eric Koegel editbugs 2012-02-08 09:23:22 CET
Created attachment 4173 
[PATCH] Always use gdk_screen_get_monitor_geometry

Nice writeup, this patch implements the fix.
Comment 2 Nick Schermer editbugs 2012-02-19 17:16:09 CET
nbackdrops is equal to the number of monitors, so this should be safe (although a monitor offset when there is 1 monitor in the screen is a bit strange).

Bug #8195

Reported by:
sean-clancy
Reported on: 2011-11-26
Last modified on: 2012-03-07

People

Assignee:
Brian J. Tarricone (not reading bugmail)
CC List:
3 users

Version

Attachments

Additional information