diff options
Diffstat (limited to 'media-gfx/gnome-screenshot')
3 files changed, 108 insertions, 0 deletions
diff --git a/media-gfx/gnome-screenshot/Manifest b/media-gfx/gnome-screenshot/Manifest index 12ea9c96d28c..a1db98c83d59 100644 --- a/media-gfx/gnome-screenshot/Manifest +++ b/media-gfx/gnome-screenshot/Manifest @@ -1,3 +1,5 @@ +AUX gnome-screenshot-40.0-fix-hidpi.patch 1351 BLAKE2B a94ce580d6f4af9e7945bdb13b3ba5b13787b564954e0933f9324c9d086e04f6efcb0affafc8775d2b41004f9c501edbe380e869723e038355c6c6ce7cb8b43b SHA512 68e8d178800036025a03786e8842aadfce0eaec61e36405406909ba8055db86d31350bae201226e54e667879da4610d5ea94df05fcf419f6609202a8c00d9c64 DIST gnome-screenshot-40.0.tar.xz 358088 BLAKE2B cad407f471e953667946b741ed59fe210d7ba3d079f2db8101974e565a1d0bfaec0cb1b40791be0e183dd399a82db5f15bbbec741ef16b4b572b043fcaf8ea8e SHA512 0889d7701711f17de68f8a55f512b7764fed087b1b2f86b372d1a38ee956f05ca8c833ca16a1de2396b07c01de79204d988192036780f521b82733436d019cb0 +EBUILD gnome-screenshot-40.0-r1.ebuild 1402 BLAKE2B 62a8e7629339554173a4313d0a27db22ad15d9885b7b12dda4bdaac25cfd7aad40dcb07593d8f16cdd18cd3e7535acb416b8552a47545cb9bbaec48032a5237c SHA512 8966c62edda0d1657a201b05adf5d185c69c8ac9c2e696e240aa5649c125aaa63b2cd49bdc73a560ea6fdce4dedbcf8bd7595cfb897c462529b1ecfe87005bc1 EBUILD gnome-screenshot-40.0.ebuild 1243 BLAKE2B 63b06fb6a2e40510e5d8301744eb8a3bb860fd36c46e546dba6ea78dd72017574d8ec78efdf33c731f5f0f34258617c656039dc7f9052dafb8e87c9bbb1308f2 SHA512 ad608f1e60dd59631895a0868e9a4ebbfb9cd063c45db01e1f72eeb29611828b153edf7dcc796efc571531a2dd5402eb7be017dd642d5ba21a5b5adcec02b262 MISC metadata.xml 249 BLAKE2B e71e1b95fee768c696704acbf7e3cf0e599ed2bc8de92bae0141d1194ef9e842bdc292798904487a9b90ddfda9b0e84abd3b76b1518576c1d288240e4e46f110 SHA512 c40662134899a5c9f0369a1017806f35adf3280a0b3c91726f7a8ca6012a073a8b471583f5bfb6fe95faac1dcf607e8e2e43f8c91d48ec46f4a8824e2f551506 diff --git a/media-gfx/gnome-screenshot/files/gnome-screenshot-40.0-fix-hidpi.patch b/media-gfx/gnome-screenshot/files/gnome-screenshot-40.0-fix-hidpi.patch new file mode 100644 index 000000000000..6b493ae6d260 --- /dev/null +++ b/media-gfx/gnome-screenshot/files/gnome-screenshot-40.0-fix-hidpi.patch @@ -0,0 +1,40 @@ +From f29aceacbd99fc905ac6d871351505e8d9aa7264 Mon Sep 17 00:00:00 2001 +From: Alexander Mikhaylenko <alexm@gnome.org> +Date: Sun, 25 Apr 2021 20:00:58 +0000 +Subject: [PATCH] Revert "backend-x11: Use pixbuf dimensions when masking" + +This reverts commit f53d720c7d9199075369f085cf5a39a6b53268bc +--- + src/screenshot-backend-x11.c | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/src/screenshot-backend-x11.c b/src/screenshot-backend-x11.c +index 990e715..bf32de8 100644 +--- a/src/screenshot-backend-x11.c ++++ b/src/screenshot-backend-x11.c +@@ -206,18 +206,20 @@ mask_monitors (GdkPixbuf *pixbuf, + GdkWindow *root_window) + { + GdkDisplay *display; ++ GdkScreen *screen; + cairo_region_t *region_with_monitors; + cairo_region_t *invisible_region; + cairo_rectangle_int_t rect; + + display = gdk_window_get_display (root_window); ++ screen = gdk_display_get_default_screen (display); + + region_with_monitors = make_region_with_monitors (display); + + rect.x = 0; + rect.y = 0; +- rect.width = gdk_pixbuf_get_width (pixbuf); +- rect.height = gdk_pixbuf_get_height (pixbuf); ++ rect.width = gdk_screen_get_width (screen); ++ rect.height = gdk_screen_get_height (screen); + + invisible_region = cairo_region_create_rectangle (&rect); + cairo_region_subtract (invisible_region, region_with_monitors); +-- +GitLab + diff --git a/media-gfx/gnome-screenshot/gnome-screenshot-40.0-r1.ebuild b/media-gfx/gnome-screenshot/gnome-screenshot-40.0-r1.ebuild new file mode 100644 index 000000000000..530e596f46da --- /dev/null +++ b/media-gfx/gnome-screenshot/gnome-screenshot-40.0-r1.ebuild @@ -0,0 +1,66 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +inherit gnome.org gnome2-utils meson readme.gentoo-r1 xdg + +DESCRIPTION="Screenshot utility for GNOME" +HOMEPAGE="https://gitlab.gnome.org/GNOME/gnome-screenshot" + +LICENSE="GPL-2+" +SLOT="0" +IUSE="X" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux" + +DEPEND=" + X? ( + x11-libs/libX11 + x11-libs/libXext + ) + >=dev-libs/glib-2.35.1:2[dbus] + >=x11-libs/gtk+-3.12.0:3 + >=gui-libs/libhandy-1:1= +" +RDEPEND="${DEPEND} + >=gnome-base/gsettings-desktop-schemas-0.1.0 +" +BDEPEND=" + dev-libs/appstream-glib + dev-libs/libxml2:2 + >=sys-devel/gettext-0.19.8 + virtual/pkgconfig + x11-base/xorg-proto +" + +PATCHES=( + # Fix HiDPI handling in X11 fallback + # https://gitlab.gnome.org/GNOME/gnome-screenshot/-/issues/128 + "${FILESDIR}"/${PN}-40.0-fix-hidpi.patch +) + +DOC_CONTENTS="${P} saves screenshots in ~/Pictures/ and defaults to + non-interactive mode when launched from a terminal. If you want to choose + where to save the screenshot, run 'gnome-screenshot --interactive'" + +src_configure() { + local emesonargs=( + $(meson_feature X x11) + ) + meson_src_configure +} + +src_install() { + meson_src_install + readme.gentoo_create_doc +} + +pkg_postinst() { + xdg_pkg_postinst + gnome2_schemas_update + readme.gentoo_print_elog +} + +pkg_postrm() { + xdg_pkg_postrm + gnome2_schemas_update +} |