procedure ConfigureSystemFontCacheGovernor(Governor: TPdfCacheGovernor);
เรียกโพรซีเยอร์นี้ตอนที่ยังไม่ได้โหลด PDFium
การเปลี่ยน governor จะล้างผลลัพธ์ system font ที่เก็บไว้และคืน token เดิม
การส่ง nil จะกลับไปจำกัด cache ของ system font ด้วยจำนวน entry อย่างเดียว
หากเรียกโพรซีเยอร์นี้ตอนที่ PDFium โหลดอยู่ จะ raise EPdfError
ผู้เรียกเป็นเจ้าของ governor
governor ต้องมีอายุยาวกว่า cache ของ system font ที่ตั้งค่าไว้
ก่อนปล่อยมัน ให้เรียก UnloadLibrary แล้วตามด้วย ConfigureSystemFontCacheGovernor(nil)
var
Governor: TPdfCacheGovernor;
begin
Governor := TPdfCacheGovernor.Create(Int64(64) * 1024 * 1024);
try
UnloadLibrary;
ConfigureSystemFontCacheGovernor(Governor);
LoadLibrary;
RunDocumentWork;
UnloadLibrary;
ConfigureSystemFontCacheGovernor(nil);
finally
Governor.Free;
end;
end;