xquartz: Allow extra font directories to be passed

This commit is contained in:
Quentin Smith 2023-04-26 02:08:44 -04:00
parent d018f767e1
commit 9ae8af51c5
No known key found for this signature in database
GPG key ID: 04EE05A8FCEFB697

View file

@ -2,6 +2,8 @@
, quartz-wm, fontconfig, xlsfonts, xfontsel , quartz-wm, fontconfig, xlsfonts, xfontsel
, ttf_bitstream_vera, freefont_ttf, liberation_ttf , ttf_bitstream_vera, freefont_ttf, liberation_ttf
, shell ? "${bashInteractive}/bin/bash" , shell ? "${bashInteractive}/bin/bash"
, unfreeFonts ? false
, extraFontDirs ? []
}: }:
# ------------ # ------------
@ -60,15 +62,16 @@ let
sudo launchctl load -w /Library/LaunchDaemons/$daemonName sudo launchctl load -w /Library/LaunchDaemons/$daemonName
''; '';
fontDirs = [ fontDirs = [
xorg.fontbhlucidatypewriter100dpi
xorg.fontbhlucidatypewriter75dpi
ttf_bitstream_vera ttf_bitstream_vera
freefont_ttf freefont_ttf
liberation_ttf liberation_ttf
xorg.fontbh100dpi
xorg.fontmiscmisc xorg.fontmiscmisc
xorg.fontcursormisc xorg.fontcursormisc
]; ] ++ lib.optionals unfreeFonts [
xorg.fontbhlucidatypewriter100dpi
xorg.fontbhlucidatypewriter75dpi
xorg.fontbh100dpi
] ++ extraFontDirs;
fontsConf = makeFontsConf { fontsConf = makeFontsConf {
fontDirectories = fontDirs ++ [ fontDirectories = fontDirs ++ [
"/Library/Fonts" "/Library/Fonts"