• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Using a font without installing it
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using a font without installing it


  • Subject: Re: Using a font without installing it
  • From: daniel <email@hidden>
  • Date: Sat, 15 Jan 2005 10:34:59 -0800

I don't think you can get NSFont to recognize a font that isn't installed in a standard location. Perhaps you could install it at launch time and remove it at quit time?

I wonder what your reasons are for not wanting to install it. If it's a licensing issue, then I suggest there might be an issue in your including the font within your app package, as well.

On the other hand, I could see a reason for a developer wanting to keep their privately developed fonts out of the standard font directory for user convenience. For example, Finale installs a bunch of music notation fonts that I'd just as soon it kept inside its own application, if it were possible.

It looks like if you step outside of Cocoa-proper, you may be able to achieve what you want by using ATS:

http://developer.apple.com/documentation/Carbon/Reference/ATS/ atsfontsref_Reference/function_group_1.html#//apple_ref/doc/c_ref/ ATSFontActivateFromFileSpecification

Might be able to make a nice category method on NSFont using ATS to work its magic...

Daniel

On Jan 15, 2005, at 9:38 AM, Peter Karlsson wrote:

Dear list!

I want to use a font in my app without installing it. Can I make the font a
part of my app, so I can use it in the same way as for example a picture?


Best regards Peter

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
sweater.com


This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Using a font without installing it (From: "Peter Karlsson" <email@hidden>)

  • Prev by Date: Re: Extending already loaded objects using plugins?
  • Next by Date: Cocoa & NS ??
  • Previous by thread: Using a font without installing it
  • Next by thread: Re: Using a font without installing it
  • Index(es):
    • Date
    • Thread