After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 645904 - black rectangle on alt+prtscrn for triple monitor setup
black rectangle on alt+prtscrn for triple monitor setup
Status: RESOLVED DUPLICATE of bug 587101
Product: gnome-utils
Classification: Deprecated
Component: screenshot
2.30.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-utils Maintainers
gnome-utils Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-03-28 08:24 UTC by mihai.draghicioiu
Modified: 2011-09-17 03:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description mihai.draghicioiu 2011-03-28 08:24:54 UTC
Hi guys. I have a triple monitor setup, with the leftmost and rightmost monitors being smaller than the middle monitor. They are, from left to right:

Screen 1: 1024x768, offset from the top 196px to match the physical position
Screen 0: 1280x1024
Screen 2: 1024x768, same as Screen 1.

See http://img819.imageshack.us/img819/5999/triplehead.png

See here for my xorg.conf: http://lists.freedesktop.org/archives/xorg/2011-January/052383.html

When taking a screenshot of the whole screen (Print Screen key), the screenshot tool correctly places four black rectangles on the top left, bottom left, top right and bottom right areas of the screenshot. The rectangular areas are 1024 pixels in width, and 196 (top areas) and (1024 - 768 - 196) 60 pixels (bottom areas) in height respectively.

The problem occurs when using alt+prtscrn, the top left black area is superimposed on the current window. So in my screenshot i see the window that was focused when i pressed alt+prtscrn, but i also see the 1024x196px black area that would normally go at the top left of a full-desktop screenshot.

My guess the bug occurs because the alt+prtscrn version simply forgets that it has to do some extra calculations (intersect window region with black regions). Furthermore, the black regions are not even necessary, because even if part of the window is in the unseen areas of the screen, it might still be in video memory, intact, so one could rely solely on full-desktop clipping of the window. Let me try to give an example. With the setup described above, imagine a window with top left corner at (512, 0) and bottom right corner at (1200, 600). If we consider a bounding box of the entire desktop, it would be 3328x1024px. The window would be entirely within this bounding box. However, if we were to intersect it with each screen individually, its top left  area would be above the leftmost 1024x768 screen. The two options we have is either ignore Xinerama information and act as if the screen was 3328x1024 (remember, we're taking a screenshot of a single window, not the whole screen), or take into account the list of screen rectangles, and make black areas on the screenshot where the window is out of the screen. I suppose the most correct and safe way is the latter, because you never know what the screenshot will look like when looking at the darkened areas, if you don't darken them.

But anyway, this renders alt+prtscrn unusable currently.
Comment 1 Cosimo Cecchi 2011-09-17 03:47:10 UTC
Thanks for the bug report. This particular bug has already been reported into our bug tracking system, but please feel free to report any further bugs you find.

*** This bug has been marked as a duplicate of bug 587101 ***