fix: preserve PNG transparency in chat wallpapers#30698
Conversation
Remove .forceOpaque = true from ChooseFromFile in settings_chat.cpp and BackgroundBox::chooseFromFile in background_box.cpp, which was compositing transparent pixels against white via Opaque() for all non-JPEG files before the image reached the wallpaper pipeline.
|
Did you actually test it? The server accepts only jpegs so it will lose the transparency anyway, all you likely did is that the transparency will turn black instead of white. |
yes i tested it, the chat backround wallpaper is chosen through the chat settings,
Here is the image, a fully transparent png which was used for testing. Here is the result: half screenshot of chat window. here is the compiled app (linux)+ the transparent png used: https://gofile.io/d/30Ludp |



Respect the user's chosen image as-is without forcing opacity, which naturally enables transparent chat background support.
fixes #29773