2008-07-03 16:27:19 +02:00
|
|
|
<?xml version="1.0"?>
|
|
|
|
|
|
|
|
<!--
|
|
|
|
This script copies the original fonts.conf from the fontconfig
|
|
|
|
distribution, but replaces all <dir> entries with the directories
|
|
|
|
specified in the $fontDirectories parameter.
|
|
|
|
-->
|
|
|
|
|
|
|
|
<xsl:stylesheet version="1.0"
|
|
|
|
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
|
|
|
xmlns:str="http://exslt.org/strings"
|
|
|
|
extension-element-prefixes="str"
|
|
|
|
>
|
|
|
|
|
|
|
|
<xsl:output method='xml' encoding="UTF-8" doctype-system="fonts.dtd" />
|
|
|
|
|
|
|
|
<xsl:param name="fontDirectories" />
|
|
|
|
<xsl:param name="fontconfig" />
|
|
|
|
|
|
|
|
<xsl:template match="/fontconfig">
|
|
|
|
|
|
|
|
<fontconfig>
|
|
|
|
<xsl:copy-of select="child::node()[name() != 'dir' and name() != 'cachedir' and name() != 'include']" />
|
|
|
|
|
2014-02-04 20:02:51 +01:00
|
|
|
<include ignore_missing="yes">/etc/fonts/conf.d</include>
|
|
|
|
<include><xsl:value-of select="$fontconfig" />/etc/fonts/conf.d</include>
|
2013-06-27 13:31:35 +02:00
|
|
|
|
2014-02-04 20:02:51 +01:00
|
|
|
<cachedir>/var/cache/fontconfig</cachedir>
|
|
|
|
<cachedir>~/.fontconfig</cachedir>
|
2013-06-27 13:31:35 +02:00
|
|
|
|
2008-07-03 16:27:19 +02:00
|
|
|
<xsl:for-each select="str:tokenize($fontDirectories)">
|
|
|
|
<dir><xsl:value-of select="." /></dir>
|
|
|
|
<xsl:text>
</xsl:text>
|
|
|
|
</xsl:for-each>
|
2014-04-28 19:23:23 +02:00
|
|
|
<dir prefix="xdg">fonts</dir>
|
|
|
|
<!-- the following element will be removed in the future -->
|
|
|
|
<dir>~/.fonts</dir>
|
2013-06-27 13:31:35 +02:00
|
|
|
|
2008-07-03 16:27:19 +02:00
|
|
|
</fontconfig>
|
|
|
|
|
|
|
|
</xsl:template>
|
2013-06-27 13:31:35 +02:00
|
|
|
|
2008-07-03 16:27:19 +02:00
|
|
|
</xsl:stylesheet>
|