Bug 269930 - KSnapshot includes a black border when saving a window's snapshot in JPEG
Summary: KSnapshot includes a black border when saving a window's snapshot in JPEG
Status: RESOLVED UNMAINTAINED
Alias: None
Product: ksnapshot
Classification: Unmaintained
Component: general (other bugs)
Version First Reported In: unspecified
Platform: Chakra Linux
: NOR normal
Target Milestone: ---
Assignee: Pau Garcia i Quiles
URL:
Keywords:
: 272904 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-04-02 12:49 UTC by Daniele Cocca
Modified: 2018-09-04 04:19 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
Snapshot showing border with shadowing on (31.10 KB, image/png)
2012-04-03 11:11 UTC, Graeme Hewson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Daniele Cocca 2011-04-02 12:49:38 UTC
Version:           unspecified (using KDE 4.6.1) 
OS:                Linux

When taking a snapshot of a single window, the entire window area gets captured (both window contents and shadows). The shadows are semi-transparent image elements, which the JPEG format is not able to preserve. Thus, if you choose to save the captured image as JPEG, an opaque, black border appears.

Reproducible: Always

Steps to Reproduce:
1) take a snapshot of a window
2) save it in JPEG

Actual Results:  
The image includes a black border.
See this one as an example:
http://kde-apps.org/content/preview.php?preview=2&id=140409&file1=140409-1.jpeg&file2=140409-2.jpeg&file3=&name=RcConf+Settings+-+KCM

Expected Results:  
The snapshot should not include the black border.

This seems to be related to the shadow of the captured window: I cannot reproduce this bug when X.Org compositing is disabled, and it doesn't happen when X.Org compositing is enabled but you take a snapshot of the entire screen area.

This bug was tested on KSnapshot 0.8.2 - but I had to leave the version "unspecified" in this report, because the "Application Version" combo box only lets me choose between 0.5, 0.7, 0.7.1 and 3.0 (?).
Comment 1 Christoph Feck 2011-06-21 13:58:02 UTC
*** Bug 272904 has been marked as a duplicate of this bug. ***
Comment 2 Graeme Hewson 2012-04-03 11:11:43 UTC
Created attachment 70107 [details]
Snapshot showing border with shadowing on

I confirm this bug in Ksnapshot 0.8.2 under KDE 4.8.1.

In my case, I see a chequered border, which looks like a bare X desktop. If I turn desktop effects off with the Alt+Shift+F12 shortcut, there's no border around the snapshot.
Comment 3 Graeme Hewson 2012-04-03 11:21:30 UTC
I now see there's a tickbox for "Include window decorations". If I untick the box with desktop effects on, I don't get a border in the snapshot.

So the bug has changed, in that window decorations are not included when the box is ticked; instead, only the bare surround is included.
Comment 4 Andrew Crouthamel 2018-09-04 04:19:39 UTC
Hello! Sorry to be the bearer of bad news, but this project has been unmaintained for many years and I will be closing this bug. Spectacle is the replacement for ksnapshot now. Please test again and file a new bug for Spectacle if you still have issues. Thank you!