macOS: copied captures paste as TIFF, not PNG
Flameshot Version
Flameshot v14.0.0 (Homebrew cask, 14.0.0)
Installation Type
homebrew
Operating System type and version
macOS 26.6.2 (25G83), Apple Silicon
Description
On macOS a copied capture pastes as TIFF into every app I use - Discord, Telegram, etc. land as .tiff, and they are far larger than the same image as PNG. One capture here: 1,369,284 bytes as TIFF, 35,387 bytes as PNG.
The PNG is already on the pasteboard. It just carries a UTI that only Qt apps can read:
public.tiff bytes=1369284
com.trolltech.anymime.application--x-qt-image bytes=0
com.trolltech.anymime.image--png bytes=35387 <- intact PNG, unreachableThat comes from the macOS branch in saveToClipboardMime(), added in #4629:
mimeData->setImageData(formattedPixmap.toImage());
mimeData->setData("image/" + imageType, array);setImageData is what makes the capture pasteable at all, and it works. The line under it is commented "Also include the original format bytes for apps that prefer PNG/JPEG", and that is the half that never arrives: Qt publishes any mime type it has no native mapping for under com.trolltech.anymime.*, so no app outside Qt can ask for it.
Writing those same bytes to the pasteboard as public.png through AppKit would let apps pick the PNG, with TIFF still there as the fallback.
Steps to reproduce
flameshot gui, select a region, copy- paste into any non-Qt app - e.g. Telegram, choose no compression
- the image arrives as TIFF
System Information
macOS 26.6.2 (25G83), Apple Silicon. Flameshot 14.0.0 from the Homebrew cask, bundled Qt 6.11.
Source: flameshot-org/flameshot