https://bugs.kde.org/show_bug.cgi?id=465972

            Bug ID: 465972
           Summary: Spectacle copy uses a BMP instead of PNG with a manual
                    copy, but only on Wayland
    Classification: Applications
           Product: Spectacle
           Version: 21.12.3
          Platform: Kubuntu
                OS: Linux
            Status: REPORTED
          Severity: minor
          Priority: NOR
         Component: General
          Assignee: m...@baloneygeek.com
          Reporter: incom...@frogg.ie
                CC: k...@david-redondo.de
  Target Milestone: ---

SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug
symbols.
See
https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. Take any screenshot while on Wayland, using Spectacle
2. Press the "Copy to clipboard" button
3. Attempt something such as `wl-paste | xxd | head -n 1` to view the actual
container that the file is saved in.
4. You will get an output with a magic byte starting with `424d`, which is a PC
bitmap, Windows 3.x format.
5. Now attempt to save the same screenshot to a file manually, and run
something such as `cat image | xxd | head -n 1`.
5. You will get an output with a magic byte starting with `8950 4e47 0d0a
1a0a`, which is a "real" PNG. 
6. Repeating the same test while running X11 instead of wayland will result in
a PNG for both files.

This behavior is also reproducible when trying to use the spectacle commandline
options to copy the image to clipboard, or the automatic image copy that
happens on a successful screenshot.
I have also tested with multiple modes, and background screenshots, and dbus
mode, this behavior is entirely specific to the "Copy to clipboard"
functionality *as a whole*, on Wayland.
I have tried this on the same system using Xorg.

OBSERVED RESULT

The copied image is a BMP image, which does not display properly or paste
properly in some applications (especially when a png is expected, and it is
called a .png).

EXPECTED RESULT

The copied image is a PNG image.

SOFTWARE/OS VERSIONS

Operating System: Kubuntu 22.04
KDE Plasma Version: 5.24.7
KDE Frameworks Version: 5.92.0
Qt Version: 5.15.3
Kernel Version: 5.15.0-60-generic (64-bit)
Graphics Platform: Wayland
Processors: 16 × 12th Gen Intel® Core™ i7-1260P
Memory: 15.3 GiB of RAM
Graphics Processor: Mesa Intel® Graphics

ADDITIONAL INFORMATION

wayland package versions:
kwayland-data/jammy,jammy,now 4:5.92.0-0ubuntu1 all [installed,automatic]
kwayland-integration/jammy,now 4:5.24.4-0ubuntu1 amd64 [installed,automatic]
kwin-wayland-backend-drm/jammy-updates,now 4:5.24.7-0ubuntu0.1 amd64
[installed,automatic]
kwin-wayland/jammy-updates,now 4:5.24.7-0ubuntu0.1 amd64 [installed,automatic]
libkf5waylandclient5/jammy,now 4:5.92.0-0ubuntu1 amd64 [installed,automatic]
libkf5waylandserver5/jammy,now 4:5.92.0-0ubuntu1 amd64 [installed,automatic]
libkwaylandserver5/jammy-updates,now 5.24.6-0ubuntu0.1 amd64
[installed,automatic]
libqt5waylandclient5/jammy,now 5.15.3-1 amd64 [installed,automatic]
libqt5waylandcompositor5/jammy,now 5.15.3-1 amd64 [installed,automatic]
libva-wayland2/jammy,now 2.14.0-1 amd64 [installed,automatic]
libwayland-bin/jammy-updates,jammy-security,now 1.20.0-1ubuntu0.1 amd64
[installed,automatic]
libwayland-client0/jammy-updates,jammy-security,now 1.20.0-1ubuntu0.1 amd64
[installed,automatic]
libwayland-cursor0/jammy-updates,jammy-security,now 1.20.0-1ubuntu0.1 amd64
[installed,automatic]
libwayland-dev/jammy-updates,jammy-security,now 1.20.0-1ubuntu0.1 amd64
[installed,automatic]
libwayland-egl1/jammy-updates,jammy-security,now 1.20.0-1ubuntu0.1 amd64
[installed,automatic]
libwayland-server0/jammy-updates,jammy-security,now 1.20.0-1ubuntu0.1 amd64
[installed,automatic]
plasma-workspace-wayland/jammy-updates,now 4:5.24.7-0ubuntu0.1 amd64
[installed]
qtwayland5/jammy,now 5.15.3-1 amd64 [installed,automatic]
wayland-protocols/jammy,jammy,now 1.25-1 all [installed,automatic]
xwayland/jammy-updates,jammy-security,now 2:22.1.1-1ubuntu0.5 amd64
[installed,automatic]

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to