Einzelnen Beitrag anzeigen

WojTec

Registriert seit: 17. Mai 2007
480 Beiträge
 
Delphi XE6 Professional
 
#5

Re: AW: Get font name stored in stream

  Alt 14. Sep 2014, 14:00
Are you sure with Delphi 5 as you flagged this thread or Delphi XE6 as your profile state?
Website marked themself, I forgot change to higher version

How do you read the name from the file?

Mostly the file is opend as a stream and then the information is read from the stream
If it will be native Delphi code, then probably will no problem read stream, but I'm using GDI32.DLL@GetFontResourceInfoW:

function GetFontResourceInfoW(lpszFilename: PWideChar; var cbBuffer: DWORD; lpBuffer: PWideChar; dwQueryType: DWORD): DWORD; stdcall;

This is working for both TTF and FON. But they want to see file path, not data pointer.

Yap, I have routines to load not installed fonts at runtime, but now I want to get name from font stream (stored in some TStream descent). Or in this way can get loaded font name

Geändert von WojTec (14. Sep 2014 um 14:21 Uhr)
  Mit Zitat antworten Zitat