[gimp] Bug 795899 - "Some fonts failed to load" error when missing fonts/...



commit 962b8496fcaeda55e99b1a4b16243aa3212a1674
Author: Jehan <jehan girinstud io>
Date:   Wed May 9 14:17:13 2018 +0200

    Bug 795899 - "Some fonts failed to load" error when missing fonts/...
    
    ... directory in the configuration folder.
    This subfolder should have been created already. Just in case it is not
    (for any reason), just recreate it rather than popping up an error.

 app/text/gimp-fonts.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/app/text/gimp-fonts.c b/app/text/gimp-fonts.c
index 2f66030..0f042d3 100644
--- a/app/text/gimp-fonts.c
+++ b/app/text/gimp-fonts.c
@@ -249,6 +249,9 @@ gimp_fonts_add_directories (Gimp      *gimp,
 
   for (list = path; list; list = list->next)
     {
+      /* The configured directories must exist or be created. */
+      g_file_make_directory_with_parents (list->data, NULL, NULL);
+
       /* Do not use FcConfigAppFontAddDir(). Instead use
        * FcConfigAppFontAddFile() with our own recursive loop.
        * Otherwise, when some fonts fail to load (e.g. permission


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]