When running XnView MP on modern Linux desktop environments (in my case under Flatpak / Wayland / KDE Plasma 6.7.5 on Fedora 44), enabling system file dialogs (XDG_PORTAL / QXdgDesktopPortalFileDialog) causes file-saving to fail.
Issue
The xdg-desktop-portal service cannot parse XnView MP's current QFileDialog filter strings (it returns empty () extension fields to the portal), which breaks MIME type detection and prevents image writing modules (e.g., PNG/JPEG) from initializing on save.
Request / Proposed Solution
- Standardize Filter Strings: Ensure QFileDialog invocations on Linux use standard Qt formatting (e.g., PNG image (*.png) or QMimeDatabase MIME-based filtering) so QXdgDesktopPortalFileDialog can map them to system portals.
- Native Dialog Flag: Make sure the QFileDialog::DontUseNativeDialog is not hardcoded on Linux builds when the user checks "Use system file dialog".
- Optional Build/Compiler Flag: If necessary, expose a build flag/macro for Linux releases so native portal dialogs work out-of-the-box in Flatpak packages.
Thank you for your hard work on XnView MP!