From a563a1802ef930374f88e6c7198e1b5ffe7582dd Mon Sep 17 00:00:00 2001 From: Akira TAGOH Date: Mon, 28 Jan 2019 09:59:29 +0000 Subject: [PATCH] Add new element remap-dir instead of extending dir element --- doc/fontconfig-user.sgml | 15 ++- fonts.dtd | 11 +- src/fcxml.c | 279 +++++++++++++++++++++++---------------- 3 files changed, 184 insertions(+), 121 deletions(-) diff --git a/doc/fontconfig-user.sgml b/doc/fontconfig-user.sgml index 92e3e5a5..f0833940 100644 --- a/doc/fontconfig-user.sgml +++ b/doc/fontconfig-user.sgml @@ -310,15 +310,9 @@ following structure: This is the top level element for a font configuration and can contain <dir>, <cachedir>, <include>, <match> and <alias> elements in any order. - <literal><dir prefix="default" map=""></literal> + <literal><dir prefix="default"></literal> This element contains a directory name which will be scanned for font files to include in the set of available fonts. If 'prefix' is set to "default" or "cwd", the current working directory will be added as the path prefix prior to the value. If 'prefix' is set to "xdg", the value in the XDG_DATA_HOME environment variable will be added as the path prefix. please see XDG Base Directory Specification for more details. If 'prefix' is set to "relative", the path of current file will be added prior to the value. - -If a 'map' attribute is specified, its value will replace the -directory path when matching cached information for fonts contained in -this directory. This is useful if the directory name is an alias -(via a bind mount or symlink) to another directory in the system for -which cached font information is likely to exist. <literal><cachedir prefix="default"></literal> This element contains a directory name that is supposed to be stored or read @@ -357,6 +351,13 @@ drawn as blanks on the screen. Within the <blank> elem Unicode characters which is supposed to be blank in an <int> element. Characters outside of this set which are drawn as blank will be elided from the set of characters supported by the font. + + <literal><remap-dir prefix="default" as-path=""<</literal> +This element contains a directory name where will be mapped +as the path 'as-path' in cached information. +This is useful if the directory name is an alias +(via a bind mount or symlink) to another directory in the system for +which cached font information is likely to exist. <literal><rescan></literal> The <rescan> element holds an <int> element which indicates the default diff --git a/fonts.dtd b/fonts.dtd index 8a95fa58..2323c464 100644 --- a/fonts.dtd +++ b/fonts.dtd @@ -7,6 +7,7 @@ dir | include | match | + remap-dir | selectfont)* > @@ -110,6 +110,15 @@ --> + + + +