1. 03 Apr, 2019 1 commit
    • Keith Packard's avatar
      Replace UUID file mechanism with per-directory 'map' attribute [v2] · c4324f54
      Keith Packard authored
      The UUID files would be placed in each font directory to provide the
      unique cache name, independent of path, for that directory. The UUID
      files are undesireable for a couple of reasons:
       1) They must be placed in the font directories to be useful. This
          requires modifying the font directories themselves, introducing
          potential visible timestamp changes when running multiple
          applications, and makes the cache processing inconsistent between
          applications with permission to write to the font directories and
          applications without such permission.
       2) The UUID contents were generated randomly, which makes the font
          cache not reproducible across multiple runs.
      One proposed fix for 2) is to make the UUID dependent on the font
      directory path, but once we do that, we can simply use the font
      directory path itself as the key as the original MD5-based font cache
      naming mechanism did.
      The goal of the UUID file mechanism was to fix startup time of
      flatpaks; as the font path names inside the flatpak did not match the
      font path names in the base system, the font cache would need to be
      reconstructed the first time the flatpak was launched.
      The new mechanism for doing this is to allow each '<dir>' element in
      the configuration include a 'map' attribute. When looking for a cache
      file for a particular directory, if the directory name starts with the
      contents of the <dir> element, that portion of the name will be
      replaced with the value of the 'map' attribute.
      Outside of the flatpak, nothing need change -- fontconfig will build
      cache files using real directory names.
      Inside the flatpak, the custom fonts.conf file will now include
      mappings such as this:
      	<dir map="/usr/share/fonts">/run/host/fonts</dir>
      When scanning the directory /run/host/fonts/ttf, fontconfig will
      use the name /usr/share/fonts/ttf as the source for building the cache
      file name.
      The existing FC_FILE replacement code used for the UUID-based
      implementation continues to correctly adapt font path names seen by
      	Leave FcDirCacheCreateUUID stub around to avoid removing
      	public API function.
      	Document 'map' attribute of <dir> element in
      Suggested-by: Akira TAGOH's avatarAkira TAGOH <akira@tagoh.org>
      Signed-off-by: Keith Packard's avatarKeith Packard <keithp@keithp.com>
  2. 15 Nov, 2018 1 commit
  3. 04 Oct, 2018 1 commit
  4. 16 May, 2018 1 commit
    • Chris Lamb's avatar
      Ensure cache checksums are deterministic · f098adac
      Chris Lamb authored
      Whilst working on the Reproducible Builds[0] effort, we noticed that
      fontconfig generates unreproducible cache files.
      This is due to fc-cache uses the modification timestamps of each
      directory in the "checksum" and "checksum_nano" members of the _FcCache
      struct. This is so that it can identify which cache files are valid
      and/or require regeneration.
      This patch changes the behaviour of the checksum calculations to prefer
      the value of the SOURCE_DATE_EPOCH[1] environment variable over the
      directory's own mtime. This variable can then be exported by build
      systems to ensure reproducible output.
      If SOURCE_DATE_EPOCH is not set or is newer than the mtime of the
      directory, the existing behaviour is unchanged.
      This work was sponsored by Tails[2].
       [0] https://reproducible-builds.org/
       [1] https://reproducible-builds.org/specs/source-date-epoch/
       [2] https://tails.boum.org/
  5. 05 May, 2018 1 commit
  6. 19 Apr, 2018 1 commit
  7. 24 Mar, 2017 1 commit
  8. 15 Aug, 2016 1 commit
  9. 08 Jun, 2015 1 commit
    • Akira TAGOH's avatar
      Add one more debugging option to see transformation on font-matching · 10a57edd
      Akira TAGOH authored
      just setting FC_MATCH=3 shows a lot of information and hard to keep on track for informamtion
      which is really necessary to see. to use this more effectively, added FC_DBG_MATCH_FILTER to
      see for what one really want to see. it takes a comma-separated-list of object names.
      If you want to see family name only, try like this:
      FC_DBG_MATCH_FILTER=family FC_DEBUG=4096 fc-match
      debugging output will be filtered out and see family only in the result.
  10. 12 May, 2015 1 commit
  11. 22 Apr, 2015 1 commit
  12. 20 Apr, 2015 1 commit
  13. 19 Jan, 2015 1 commit
  14. 06 Jan, 2015 1 commit
  15. 25 Jul, 2014 2 commits
  16. 10 Sep, 2013 1 commit
  17. 01 Feb, 2013 1 commit
    • Akira TAGOH's avatar
      Bug 23757 - Add mode="delete" to <edit> · 20191810
      Akira TAGOH authored
      Add two edit mode, "delete" and "delete_all".
      what values are being deleted depends on <test> as documented.
      if the target object is same to what is tested, matching value there
      will be deleted. otherwise all of values in the object will be deleted.
      so this would means both edit mode will not take any expressions.
      Given that the testing is always true here, the following rules:
          <test name="foo" compare="eq">
          <edit name="foo" mode="delete"/>
      will removes "bar" string from "foo" object. and:
          <test name="foo" compare="eq">
          <edit name="bar" mode="delete"/>
      will removes all of values in "bar" object.
  18. 16 Jan, 2013 2 commits
  19. 01 Jan, 2013 1 commit
  20. 22 Jun, 2012 1 commit
  21. 11 Jun, 2012 1 commit
  22. 25 May, 2012 1 commit
    • Akira TAGOH's avatar
      Bug 33644 - Fontconfig doesn't match correctly in <test> · 2837c638
      Akira TAGOH authored
      Warn if the multiple values is set to <test>, including the case of
      in <alias> because the behavior isn't intuitive since so many users
      is asking for a help to get things working for their expectation.
      Use multiple <match>s or <alias>es for OR operator and
      multiple <test>s for AND operator.
  23. 21 May, 2012 1 commit
  24. 18 May, 2012 1 commit
  25. 14 May, 2012 1 commit
    • Akira TAGOH's avatar
      Bug 19128 - Handling whitespace in aliases · bc4517d8
      Akira TAGOH authored
      Add a new attribute `ignore-blanks' to <test>.
      When this is set to "true", any blanks in the string will be ignored
      on comparison.  This takes effects for compare="eq" or "not_eq" only.
      Also changed the behavior of the comparison on <alias> too.
  26. 25 Apr, 2012 1 commit
    • Akira TAGOH's avatar
      Bug 39278 - make usage of mmap optional · 7d65f9f5
      Akira TAGOH authored
      Stop using mmap() if the cache file is stored on NFS.
      also added FONTCONFIG_USE_MMAP environment variable to enforce the use of
      or not the use of mmap(2) regardless of what the filesystem the cache files
      are stored on.
  27. 30 Mar, 2012 1 commit
  28. 12 Mar, 2012 2 commits
  29. 11 Mar, 2011 1 commit
  30. 09 Dec, 2010 2 commits
  31. 10 Nov, 2010 1 commit
  32. 27 Jul, 2009 1 commit
  33. 13 Mar, 2009 1 commit
  34. 14 Feb, 2009 1 commit
  35. 04 May, 2008 1 commit
    • Sylvain Pasche's avatar
      Fontconfig options for freetype sub-pixel filter configuration · 53aec111
      Sylvain Pasche authored
      David Turner has modified FreeType to be able to render sub-pixel decimated
      glyphs using different methods of filtering. Fontconfig needs new
      configurables to support selecting these new filtering options. A patch
      follows that would correspond to one available for Cairo in bug 10301.
  36. 02 Dec, 2006 1 commit