* Provide a few fonts in a purely functional way, i.e., as part of the
system configuration. svn path=/nixos/trunk/; revision=7748
This commit is contained in:
parent
6db2c1814e
commit
eddd3a7e11
@ -81,15 +81,26 @@ import ../helpers/make-etc.nix {
|
|||||||
# (X11) client-rendered fonts.
|
# (X11) client-rendered fonts.
|
||||||
source = pkgs.substituteAll {
|
source = pkgs.substituteAll {
|
||||||
src = ./etc/fonts/fonts.conf;
|
src = ./etc/fonts/fonts.conf;
|
||||||
fontDirectories = map (dir: "<dir>${dir}</dir>")
|
fontDirectories =
|
||||||
[ # Search for fonts in...
|
let
|
||||||
# - the user's .fonts directory
|
# Search for fonts in...
|
||||||
"~/.fonts"
|
runtimeDirs = [
|
||||||
# - the user's current profile
|
# - the user's .fonts directory
|
||||||
"~/.nix-profile/lib/X11/fonts"
|
"~/.fonts"
|
||||||
# - the default profile
|
# - the user's current profile
|
||||||
"/nix/var/nix/profiles/default/lib/X11/fonts"
|
"~/.nix-profile/lib/X11/fonts"
|
||||||
];
|
# - the default profile
|
||||||
|
"/nix/var/nix/profiles/default/lib/X11/fonts"
|
||||||
|
];
|
||||||
|
systemFonts = [
|
||||||
|
# - a few statically built locations
|
||||||
|
pkgs.xorg.fontbhttf
|
||||||
|
pkgs.xorg.fontbh100dpi
|
||||||
|
pkgs.xorg.fontbhlucidatypewriter100dpi
|
||||||
|
pkgs.freefont_ttf
|
||||||
|
];
|
||||||
|
in
|
||||||
|
map (dir: "<dir>${dir}</dir>") (runtimeDirs ++ systemFonts);
|
||||||
};
|
};
|
||||||
target = "fonts/fonts.conf";
|
target = "fonts/fonts.conf";
|
||||||
}
|
}
|
||||||
|
@ -4,5 +4,5 @@
|
|||||||
<fontconfig>
|
<fontconfig>
|
||||||
|
|
||||||
@fontDirectories@
|
@fontDirectories@
|
||||||
|
|
||||||
</fontconfig>
|
</fontconfig>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user