Merge pull request #67663 from jtojnar/fc-joypixels

fontconfig: add support for JoyPixels font
This commit is contained in:
Jan Tojnar 2019-08-30 00:30:13 +02:00 committed by GitHub
commit 3665a31a4a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 28 additions and 9 deletions

View File

@ -1,13 +1,7 @@
{ stdenv, fetchurl }:
let
fontconfig = fetchurl {
name = "75-joypixels.conf";
url = "https://git.archlinux.org/svntogit/community.git/plain/trunk/75-joypixels.conf?h=packages/ttf-joypixels&id=b2b38f8393ec56ed7338c256f5b85f3439a2dfc3";
sha256 = "065y2fmf86zzvna1hrvcg46cnr7a76xd2mwa26nss861dsx6pnd6";
};
in stdenv.mkDerivation rec {
pname = "emojione";
stdenv.mkDerivation rec {
pname = "joypixels";
version = "5.0.2";
src = fetchurl {
@ -19,7 +13,6 @@ in stdenv.mkDerivation rec {
installPhase = ''
install -Dm644 $src $out/share/fonts/truetype/joypixels.ttf
install -Dm644 ${fontconfig} $out/etc/fonts/conf.d/75-joypixels.conf
'';
meta = with stdenv.lib; {

View File

@ -30,6 +30,9 @@ stdenv.mkDerivation rec {
src = ./config-compat.patch;
inherit configVersion;
})
# https://gitlab.freedesktop.org/fontconfig/fontconfig/merge_requests/67
./fix-joypixels.patch
];
outputs = [ "bin" "dev" "lib" "out" ]; # $out contains all the config

View File

@ -0,0 +1,23 @@
--- a/conf.d/45-generic.conf
+++ b/conf.d/45-generic.conf
@@ -5,6 +5,10 @@
<!-- Emoji -->
+ <alias binding="same">
+ <family>JoyPixels</family>
+ <default><family>emoji</family></default>
+ </alias>
<alias binding="same">
<family>Emoji Two</family>
<default><family>emoji</family></default>
--- a/conf.d/60-generic.conf
+++ b/conf.d/60-generic.conf
@@ -29,6 +29,7 @@
<alias binding="same">
<family>emoji</family>
<prefer>
+ <family>JoyPixels</family>
<family>Emoji Two</family>
<family>Emoji One</family>
<!-- System fonts -->