Commit b698c1c3 authored by Naohiro KORIYAMA's avatar Naohiro KORIYAMA Committed by Jean-Baptiste Kempf

Freetype: Scan fonts from not only /System/Library/Fonts but also other...

Freetype: Scan fonts from not only /System/Library/Fonts but also other system-wide directories on OS X

Close #5491
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent 46be9840
...@@ -434,7 +434,7 @@ static void FontConfig_BuildCache( filter_t *p_filter ) ...@@ -434,7 +434,7 @@ static void FontConfig_BuildCache( filter_t *p_filter )
mtime_t t1, t2; mtime_t t1, t2;
t1 = mdate(); t1 = mdate();
#ifdef WIN32 #if defined( WIN32 ) || defined( __APPLE__ )
dialog_progress_bar_t *p_dialog = NULL; dialog_progress_bar_t *p_dialog = NULL;
FcConfig *fcConfig = FcInitLoadConfig(); FcConfig *fcConfig = FcInitLoadConfig();
...@@ -447,6 +447,15 @@ static void FontConfig_BuildCache( filter_t *p_filter ) ...@@ -447,6 +447,15 @@ static void FontConfig_BuildCache( filter_t *p_filter )
dialog_ProgressSet( p_dialog, NULL, 0.5 ); */ dialog_ProgressSet( p_dialog, NULL, 0.5 ); */
FcConfigBuildFonts( fcConfig ); FcConfigBuildFonts( fcConfig );
#if defined( __APPLE__ )
// By default, scan only the directory /System/Library/Fonts.
// So build the set of available fonts under another directories,
// and add the set to the current configuration.
FcConfigAppFontAddDir( NULL, "~/Library/Fonts" );
FcConfigAppFontAddDir( NULL, "/Library/Fonts" );
FcConfigAppFontAddDir( NULL, "/Network/Library/Fonts" );
//FcConfigAppFontAddDir( NULL, "/System/Library/Fonts" );
#endif
if( p_dialog ) if( p_dialog )
{ {
// dialog_ProgressSet( p_dialog, NULL, 1.0 ); // dialog_ProgressSet( p_dialog, NULL, 1.0 );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment