Merge pull request #31420 from ChengCat/chengcat

vista-fonts-chs: init at 1
This commit is contained in:
Franz Pletz 2017-11-14 12:21:33 +01:00 committed by GitHub
commit 6806dd36e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 48 additions and 0 deletions

View File

@ -111,6 +111,7 @@
changlinli = "Changlin Li <mail@changlinli.com>";
chaoflow = "Florian Friesdorf <flo@chaoflow.net>";
chattered = "Phil Scott <me@philscotted.com>";
ChengCat = "Yucheng Zhang <yu@cheng.cat>";
choochootrain = "Hurshal Patel <hurshal@imap.cc>";
chpatrick = "Patrick Chilton <chpatrick@gmail.com>";
chris-martin = "Chris Martin <ch.martin@gmail.com>";

View File

@ -0,0 +1,36 @@
{stdenv, fetchzip, cabextract}:
# Modified from vista-fonts
fetchzip {
name = "vista-fonts-chs-1";
url = http://download.microsoft.com/download/d/6/e/d6e2ff26-5821-4f35-a18b-78c963b1535d/VistaFont_CHS.EXE;
postFetch = ''
${cabextract}/bin/cabextract --lowercase --filter '*.TTF' $downloadedFile
mkdir -p $out/share/fonts/truetype
cp *.ttf $out/share/fonts/truetype
# Set up no-op font configs to override any aliases set up by
# other packages.
mkdir -p $out/etc/fonts/conf.d
substitute ${./no-op.conf} $out/etc/fonts/conf.d/30-msyahei.conf \
--subst-var-by fontname "Microsoft YaHei"
'';
sha256 = "1zwrgck84k80gpg7493jdnxnv9ajxk5c7qndinnmqydnrw239zbw";
meta = {
description = "TrueType fonts from Microsoft Windows Vista For Simplified Chinese (Microsoft YaHei)";
homepage = https://www.microsoft.com/typography/fonts/family.aspx?FID=350;
license = stdenv.lib.licenses.unfree;
maintainers = [ stdenv.lib.maintainers.ChengCat ];
# Set a non-zero priority to allow easy overriding of the
# fontconfig configuration files.
priority = 5;
platforms = stdenv.lib.platforms.all;
};
}

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!-- This configuation is intentionally left empty in order to
override any other font package that may wish to set up an
alias for the @fontname@ font. If you actually do
want to have the alias then please change the priority of that
package; see the Nix manual page for nix-env for details. -->
</fontconfig>

View File

@ -13636,6 +13636,8 @@ with pkgs;
vistafonts = callPackage ../data/fonts/vista-fonts { };
vistafonts-chs = callPackage ../data/fonts/vista-fonts-chs { };
wireless-regdb = callPackage ../data/misc/wireless-regdb { };
wqy_microhei = callPackage ../data/fonts/wqy-microhei { };