Fonts question

  • Hey guys

    I want my app to use a font that isn't a standard Mac-included font.
    Is it possible to just include the font file as a resource and load it
    from there?

    Thank you
    AA
  • I *think* NSFontManager's -addCollection:options: method is what
    you're looking for. For options, pass
    NSFontCollectionApplicationOnlyMask ... See the NSFontManager
    documentation.

    --
    I.S.

    On Oct 13, 2006, at 1:33 PM, Aychamo Aychamo wrote:

    > Hey guys
    >
    > I want my app to use a font that isn't a standard Mac-included font.
    > Is it possible to just include the font file as a resource and load it
    > from there?
    >
    > Thank you
    > AA
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Cocoa-dev mailing list      (<Cocoa-dev...>)
    > Help/Unsubscribe/Update your Subscription:
    > http://lists.apple.com/mailman/options/cocoa-dev/idiotsavant2005%
    > 40gmail.com
    >
    > This email sent to <idiotsavant2005...>
  • I did this recently by reading the font data from file into memory,
    then using ATSFontActivateFromMemory with kATSFontContextLocal.

    On 10/13/06, Aychamo Aychamo <aychamo...> wrote:
    > Hey guys
    >
    > I want my app to use a font that isn't a standard Mac-included font.
    > Is it possible to just include the font file as a resource and load it
    > from there?
    >
    > Thank you
    > AA
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Cocoa-dev mailing list      (<Cocoa-dev...>)
    > Help/Unsubscribe/Update your Subscription:
    > http://lists.apple.com/mailman/options/cocoa-dev/<dan.bernstein...>
    >
    > This email sent to <dan.bernstein...>
    >
previous month october 2006 next month
MTWTFSS
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31          
Go to today