biome: 1.9.2 -> 1.9.3
[NixPkgs.git] / pkgs / tools / misc / ksnip / default.nix
blob05920cb7c79040f196b4a322ed98b23ae5563361
1 { stdenv
2 , lib
3 , cmake
4 , extra-cmake-modules
5 , fetchFromGitHub
6 , fetchpatch
7 , kcolorpicker
8 , kimageannotator
9 , wrapQtAppsHook
10 , qtsvg
11 , qttools
12 , qtx11extras
15 stdenv.mkDerivation rec {
16   pname = "ksnip";
17   version = "1.10.1";
19   src = fetchFromGitHub {
20     owner = "ksnip";
21     repo = "ksnip";
22     rev = "v${version}";
23     sha256 = "sha256-n7YwDXd73hyrzb6L8utZFuHh9HnjVtkU6CC4jfWPj/I=";
24   };
26   patches = [
27     # Fix build with latest kImageAnnotator
28     (fetchpatch {
29       url = "https://github.com/ksnip/ksnip/commit/76f4b381971eead6ff31b8bf3bb64bb5717469c3.patch";
30       hash = "sha256-JWoI974qDNZIzr/8oksI8m6g3XNWEaQRGsqSfvQrmao=";
31     })
32   ];
34   nativeBuildInputs = [
35     cmake
36     extra-cmake-modules
37     wrapQtAppsHook
38     qttools
39   ];
41   buildInputs = [
42     kcolorpicker
43     kimageannotator
44     qtsvg
45     qtx11extras
46   ];
48   meta = with lib; {
49     homepage = "https://github.com/ksnip/ksnip";
50     description = "Cross-platform screenshot tool with many annotation features";
51     longDescription = ''
52       Features:
54       - Supports Linux (X11, Plasma Wayland, GNOME Wayland and xdg-desktop-portal Wayland), Windows and macOS.
55       - Screenshot of a custom rectangular area that can be drawn with mouse cursor.
56       - Screenshot of last selected rectangular area without selecting again.
57       - Screenshot of the screen/monitor where the mouse cursor is currently located.
58       - Screenshot of full-screen, including all screens/monitors.
59       - Screenshot of window that currently has focus.
60       - Screenshot of window under mouse cursor.
61       - Screenshot with or without mouse cursor.
62       - Capture mouse cursor as annotation item that can be moved and deleted.
63       - Customizable capture delay for all capture options.
64       - Upload screenshots directly to imgur.com in anonymous or user mode.
65       - Upload screenshots via custom user defined scripts.
66       - Command-line support, for capturing screenshots and saving to default location, filename and format.
67       - Filename wildcards for Year ($Y), Month ($M), Day ($D), Time ($T) and Counter (multiple # characters for number with zero-leading padding).
68       - Print screenshot or save it to PDF/PS.
69       - Annotate screenshots with pen, marker, rectangles, ellipses, texts and other tools.
70       - Annotate screenshots with stickers and add custom stickers.
71       - Obfuscate image regions with blur and pixelate.
72       - Add effects to image (Drop Shadow, Grayscale, invert color or Border).
73       - Add watermarks to captured images.
74       - Global hotkeys for capturing screenshots (currently only for Windows and X11).
75       - Tabs for screenshots and images.
76       - Open existing images via dialog, drag-and-drop or paste from clipboard.
77       - Run as single instance application (secondary instances send cli parameter to primary instance).
78       - Pin screenshots in frameless windows that stay atop other windows.
79       - User-defined actions for taking screenshot and post-processing.
80       - Many configuration options.
81     '';
82     license = licenses.gpl2Plus;
83     maintainers = with maintainers; [ x3ro ];
84     platforms = platforms.linux;
85     mainProgram = "ksnip";
86   };