fractional scaling in X11

This commit is contained in:
Daniel Langbein 2023-09-07 21:48:23 +02:00
parent b7e13bfd6d
commit 42d601e935
Signed by: langfingaz
GPG Key ID: 6C47C753F0823002

View File

@ -10,6 +10,7 @@
# Overlays. # Overlays.
# https://nixos.wiki/wiki/Overlays#In_NixOS # https://nixos.wiki/wiki/Overlays#In_NixOS
# https://discourse.nixos.org/t/use-specific-pkg-version-in-overlay/32741/3
nixpkgs.overlays = [ nixpkgs.overlays = [
( (
# Patched version of mutter 44.2. # Patched version of mutter 44.2.
@ -32,7 +33,9 @@
final: prev: { final: prev: {
# Elements of pkgs.gnome must be taken from gfinal and gprev. # Elements of pkgs.gnome must be taken from gfinal and gprev.
gnome = prev.gnome.overrideScope' (gfinal: gprev: { gnome = prev.gnome.overrideScope' (gfinal: gprev: {
mutter = gprev.mutter.overrideAttrs (oldAttrs: { mutter = gprev.mutter.overrideAttrs (oldAttrs:
if oldAttrs.version == "44.2" then
{
patches = (oldAttrs.patches or []) ++ [ patches = (oldAttrs.patches or []) ++ [
(prev.fetchpatch { (prev.fetchpatch {
url = "https://salsa.debian.org/gnome-team/mutter/-/raw/ubuntu/44.2-3ubuntu1/debian/patches/ubuntu/x11-Add-support-for-fractional-scaling-using-Randr.patch"; url = "https://salsa.debian.org/gnome-team/mutter/-/raw/ubuntu/44.2-3ubuntu1/debian/patches/ubuntu/x11-Add-support-for-fractional-scaling-using-Randr.patch";
@ -40,7 +43,9 @@
hash = "sha256-GCtz87C1NgxenYE5nbxcIIxqNhutmdngscnlK10fRyQ="; hash = "sha256-GCtz87C1NgxenYE5nbxcIIxqNhutmdngscnlK10fRyQ=";
}) })
]; ];
}); }
else throw "Mutter version mismatch. Please update patch."
);
}); });
} }
) )