Hallo,
dafür gibt es die beiden Funktionen
AddFontResource und
RemoveFontResource. So kannst Du das verwenden (WideChar-Version):
Delphi-Quellcode:
procedure AddFontRes(const FileName: WideString);
begin
AddFontResourceW(PWideChar(FileName));
SendMessage(HWND_BROADCAST, WM_FONTCHANGE, 0, 0);
end;
procedure RemoveFontRes(const FileName: WideString);
begin
if RemoveFontResourceW(PWideChar(FileName)) then
SendMessage(HWND_BROADCAST, WM_FONTCHANGE, 0, 0);
end;
Gruß
xaromz