10 , enableWlrSupport ? false
15 # wlr screenshotting is currently only available on unstable version (>12.1.0)
16 version = "12.1.0-unstable-2024-07-02";
18 src = fetchFromGitHub {
19 owner = "flameshot-org";
21 rev = "ccb5a27b136a633911b3b1006185530d9beeea5d";
22 hash = "sha256-JIXsdVUR/4183aJ0gvNGYPTyCzX7tCrk8vRtR8bcdhE=";
26 # https://github.com/flameshot-org/flameshot/pull/3166
27 # fixes fractional scaling calculations on wayland
29 name = "10-fix-wayland.patch";
30 url = "https://github.com/flameshot-org/flameshot/commit/5fea9144501f7024344d6f29c480b000b2dcd5a6.patch";
31 hash = "sha256-SnjVbFMDKD070vR4vGYrwLw6scZAFaQA4b+MbI+0W9E=";
36 updateScript = nix-update-script {
37 extraArgs = [ "--version=branch" ];
42 (lib.cmakeBool "USE_WAYLAND_CLIPBOARD" true)
43 (lib.cmakeBool "USE_WAYLAND_GRIM" enableWlrSupport)
50 libsForQt5.wrapQtAppsHook
59 dontWrapQtApps = true;
62 wrapProgram $out/bin/flameshot \
63 ${lib.optionalString enableWlrSupport "--prefix PATH : ${lib.makeBinPath [ grim ]}"} \
68 description = "Powerful yet simple to use screenshot software";
69 homepage = "https://github.com/flameshot-org/flameshot";
70 mainProgram = "flameshot";
71 maintainers = with maintainers; [ scode oxalica ];
72 license = licenses.gpl3Plus;
73 platforms = platforms.linux ++ platforms.darwin;