mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-09 08:30:54 +02:00
* Do not load font config if it is already loaded
This commit is contained in:
parent
abf04f1086
commit
8702fc416b
@ -645,13 +645,11 @@ var
|
||||
FN : PFcChar8;
|
||||
lDir: string;
|
||||
config: PfcConfig;
|
||||
const
|
||||
is_fc_loaded:integer=0;
|
||||
{$endif}
|
||||
begin
|
||||
{$ifdef HasFontsConf} // Linux & BSD
|
||||
if (is_fc_loaded=0) then
|
||||
is_fc_loaded:=loadfontconfiglib('');
|
||||
if not FontConfigLibLoaded then
|
||||
loadfontconfiglib('');
|
||||
|
||||
config := FcInitLoadConfigAndFonts();
|
||||
|
||||
@ -894,8 +892,8 @@ begin
|
||||
Result:=false;
|
||||
res:='';
|
||||
|
||||
if (is_fc_loaded=0) then
|
||||
is_fc_loaded:=loadfontconfiglib('');
|
||||
if not FontConfigLibLoaded then
|
||||
loadfontconfiglib('');
|
||||
|
||||
config := FcInitLoadConfigAndFonts();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user