Introduction

Flatpak, formerly known as xdg-app, is a utility for software deployment and package management for Linux.

Flatpak is:

  • simple by default
  • built for every distro
  • more up-to-date

Compared with other packaging formats

Distro Packages: Flatpak is generally more up-to-date.

Snap: Flatpak does not use a hard-coded proprietary backend.

AppImage: Flatpak provides sandboxes and better system integration.

Appearance

Fonts

Flatpak Applications may not follow your system’s font settings.

To pass your fontconfig to Flatpak Applications, copy it to ${XDG_CONFIG_DIR}/fontconfig/fonts.conf and execute

1
flatpak override --filesystem=xdg-config/fontconfig:ro

Theming

GTK

Passing xdg-config/gtk-3.0 xdg-config/gtk-4.0 to Flatpak Applications should make them follow your GTK theme.

1
2
flatpak override --filesystem=xdg-config/gtk-3.0:ro
flatpak override --filesystem=xdg-config/gtk-4.0:ro

Window Decorations (Qt)

Install QAdwaitaDecorations to enable libadwaita-like window decorations for Qt Applications:

1
flatpak install org.kde.WaylandDecoration.QAdwaitaDecorations

Hardware Video Acceleration

GStreamer

Install gstreamer-vaapi:

1
flatpak install org.freedesktop.Platform.GStreamer.gstreamer-vaapi

Others

runtime/org.freedesktop.Platform.VAAPI.Intel is needed, applications may depend on it.

NVIDIA Optimus

Environment Variables

Unset __EGL_VENDOR_LIBRARY_FILENAMES and VK_ICD_FILENAMES using:

1
2
flatpak override --unset-env=__EGL_VENDOR_LIBRARY_FILENAMES
flatpak override --unset-env=VK_ICD_FILENAMES

NVIDIA runtimes

Mask any NVIDIA runtime:

1
2
flatpak mask 'org.freedesktop.Platform.GL32.nvidia*'
flatpak mask 'org.freedesktop.Platform.GL32.nvidia*'

Then remove any existing NVIDIA runtime.

Caveats

Hybrid graphics with proper powersave features is not possible right now. __EGL_VENDOR_LIBRARY_FILENAMES doesn’t work with Flatpak.