> On 27 Feb 2016, at 00:31, Jens Alfke <[email protected]> wrote:
> 
> If this functionality exists it would probably be down in the CoreText 
> framework. Take a look there. 
> 
> —Jens 

As Ken Thomases kindly told me it does exist exactly there: 
CTFontManagerCreateFontDescriptorsFromURL.

Kind regards,

Gerriet.

> 
>> On Feb 26, 2016, at 2:16 AM, Gerriet M. Denkmann <[email protected]> 
>> wrote:
>> 
>> I have a file “Some Font.ttf” and I want to know the displayName of this 
>> font, which might be “Some-Font” or “Nice Font” or anything else.
>> Or nil if this is not a well-formatted font file.
>> I do NOT want to install the font nor do anything with it.
>> 
>> Short of reverse-engeneering the ttf format (which probably would be rather 
>> too much): is there a way to get this?
>> 
>> Ideally I would line to do:
>> NSFont *font = [ NSFont fontFromFilePath: @“/path/to/Some Font.ttf” ];
>> NSString *displayName = font.displayName;    //    font.fontName would 
>> probably also do
>> 
>> but this seems not to exist.
>> 
>> Gerriet.

_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to