Description: When I add a PNG image with transparent background (alpha channel) and black content into a LibreOffice document (e. g. Calc, Impress, Writer) and print that document, then the PNG image is printed with inverted colors. Surprisingly the print preview (icon with document and magnifier) shows everything correct. Steps to Reproduce: 1. Create a PNG with transparent background and black elements in it 2. Add the PNG to a new Writer document 3. Print the document Actual Results: The PNG is printed with inverted colors. Expected Results: The PNG is printed as shown in the LibreOffice's print preview and edit view. Reproducible: Always User Profile Reset: Yes Additional Info: Maybe related to #126876?
Created attachment 203825 [details] Example document with embedded PNG file This is the document I use to reproduce the issue
Created attachment 203826 [details] PNG file with transparent backgound and black context
Created attachment 203827 [details] macOS print preview (PNG is inverted)
Created attachment 203828 [details] LibreOffice print preview (PNG is NOT inverted)
Have you looked at Bug 98275: "PNG image with alpha channel pasted from clipboard has black background"? May be related.
I could not reproduce using your reproduction instructions. I tried both with your attached document (attachment 203825 [details]) and with a PNG image I created on my own using GIMP 3 and inserted into an empty Writer document. Tried with: Version: 25.2.5.2 (X86_64) / LibreOffice Community Build ID: 03d19516eb2e1dd5d4ccd751a0d6f35f35e08022 CPU threads: 4; OS: Linux 6.12; UI render: default; VCL: gtk3 Locale: en-IL (en_IL); UI: en-US Calc: threaded and: Version: 26.2.0.0.alpha0+ (X86_64) / LibreOffice Community Build ID: d2def868cb3ac5a7e538a911e83d7d907a2ec794 CPU threads: 4; OS: Linux 6.12; UI render: default; VCL: gtk3 Locale: en-IL (en_IL); UI: en-US Calc: CL threaded do you see this only when printing to a physical printer, or also when printing to file (e.g. PDF file)? If you also see this when printing to PDF files, can you please attach such a printed PDF? Also, what about Exporting rather printing to PDFs?
This also happens when I print to PDF. It does *not* happen when I export to PDF.
Created attachment 204020 [details] Test document exported to PDF
Created attachment 204021 [details] Test document printed to PDF
This is not related to bug #98275. The issue described there does not happen to me (no black background after copy/paste). I was wondering if this has something to do with MacOS printing system, so I created a document in Apple Pages and added the PNG. No black background there in the printing output. I also opened Wikipedia's demo file for PNG with transparency (https://en.wikipedia.org/wiki/File:PNG_transparency_demonstration_1.png) in my browser (Chrome) and printed it out and everything is fine. So this seems to be related to LibreOffice's print rendering.
Tested with Version: 25.8.3.2 (X86_64) Build ID: 8ca8d55c161d602844f5428fa4b58097424e324e CPU threads: 6; OS: Linux 6.4; UI render: default; VCL: kf5 (cairo+xcb) Locale: de-DE (de_DE.UTF-8); UI: de-DE Calc: threaded Couldn't reproduce with printing to PDF and the attached document. Might be a special MAC-bug?
I cannot reproduce this in either of the following macOS versions: Version: 25.2.7.2 (AARCH64) / LibreOffice Community Build ID: 5cbfd1ab6520636bb5f7b99185aa69bd7456825d CPU threads: 8; OS: macOS 26.1; UI render: Skia/Metal; VCL: osx Locale: en-CA (en_CA.UTF-8); UI: en-US Calc: threaded Version: 25.8.3.2 (AARCH64) Build ID: 8ca8d55c161d602844f5428fa4b58097424e324e CPU threads: 8; OS: macOS 26.1; UI render: Skia/Metal; VCL: osx Locale: en-CA (en_CA.UTF-8); UI: en-US Calc: threaded @Florian The "affected version" field for this bug is set to 25.2.6.2 but since I cannot reproduce it in 25.2.7.2, it might have already been fixed. Do you still see this bug in 25.2.7.2 or later versions?
@Patrick yes, I still can reproduce the issue using LibreOffice 25.8.3.2 (AARCH64)
Created attachment 204056 [details] Screenshot of LO 25.8.3.2 (AARCH64) showing the issue
Note: I had Skia disabled due to crashes I experienced when enabled. When Skia is enabled, the issue does not appear.
Confirming with Version: 25.8.1.1 (AARCH64) Build ID: 54047653041915e595ad4e45cccea684809c77b5 CPU threads: 8; OS: macOS 26.1; UI render: Skia/Metal; VCL: osx Locale: fr-FR (fr_FR.UTF-8); UI: fr-FR Calc: threaded Deactivated Skia rendering in LO Preferences Tested with OP's uploaded Writer document. Printed to Brother Laser MFC-L8690CDW Document prints out a black square with white text instead of the original black text on transparent background.