Re: Fonts in Projects
Re: Fonts in Projects
- Subject: Re: Fonts in Projects
- From: Darrin Cardani <email@hidden>
- Date: Fri, 29 Sep 2017 11:44:38 -0700
I’m told they can go into any of these folders:
> /System//Library/Fonts/
> /Library/Fonts/
> ~/Library/Fonts/
> (and /Network//Library/Fonts/ for systems connected to an administered
> network)
I would think you could use the standard OS installer to install them. You
should be able to make one with the command line tools pkgbuild and
productbuild. See their man pages for more details.
Darrin
> On Sep 29, 2017, at 8:35 AM, Darrin Cardani <email@hidden> wrote:
>
> Oh, I see what you’re saying. Let me ask internally about the best way to do
> that. Sorry for the confusion.
>
> Darrin
>
>> On Sep 29, 2017, at 6:43 AM, Fred <email@hidden
>> <mailto:email@hidden>> wrote:
>>
>> Thanks Darrin! I'm using that method for actual plugins, but... If all I'm
>> distributing is a Titles pack to be used in FCPX (doesn't require an FXPlug)
>> but it has custom fonts, do you recommend compiling some sort of a "dummy"
>> FXPlug that just provides the fonts or should I just be copying the fonts to
>> the user's "/Users/username/Library/Fonts" directory (possibly posing issues
>> if they already have the font installed).
>>
>> Is there a better place to copy fonts for a specific Motion project that is
>> only a Titles or Generator template made for FCPX and not an actual plugin?
>> Thanks!!
>>
>> Fred
>>
>>
>>
>> On Thu, Sep 28, 2017, at 02:19 PM, Darrin Cardani wrote:
>>> Fred,
>>>
>>> I’m not entirely sure I understand all your needs here. If you just need
>>> the font for your own plug-in, you can load it from your plug-in’s bundle
>>> in its Fonts directory like this:
>>>
>>>> NSBundle *bundle = [NSBundle bundleWithIdentifier:
>>>> @"com.apple.motion.TextFramework"];
>>>> NSArray *fontPaths = [bundle pathsForResourcesOfType:nil
>>>> inDirectory:@"Fonts"];
>>>> for (NSString *fontPath in fontPaths)
>>>> {
>>>> CFURLRef url = CFURLCreateWithFileSystemPath(NULL,
>>>> (CFStringRef)fontPath,
>>>> kCFURLPOSIXPathStyle,
>>>> false);
>>>> if (url)
>>>> {
>>>> CFErrorRef error = NULL;
>>>> bool succ = CTFontManagerRegisterFontsForURL(url,
>>>> kCTFontManagerScopeProcess, &error);
>>>>
>>>> if (!succ)
>>>> {
>>>> //Handle the error here
>>>> }
>>>> CFRelease(url);
>>>> }
>>>> }
>>>
>>> That’s the code we use to load custom fonts from Motion’s TextFramework
>>> bundle that lives inside the app. (You’ll obviously want to load from your
>>> own bundle, not from Motion's TextFramework bundle.)
>>>
>>> I’m not sure what the implications would be if the plug-in was loaded
>>> out-of-process, as we hope to be able to do one day. If you’re just using
>>> the fonts for rendering, I think that would be fine. But if the user wants
>>> to be able to use the fonts in other ways within the app, they won’t show
>>> up in the app’s UI if the plug-in is out-of-process. But of course, that’s
>>> not how it works today, so probably not a problem for the near term.
>>>
>>> Darrin
>>>
>>>> On Sep 28, 2017, at 12:56 PM, email@hidden
>>>> <mailto:email@hidden> wrote:
>>>>
>>>> I'm curious as to the recommended method of including fonts with a
>>>> pluging (especially one that's Motion only). Having an installer install
>>>> to the user directory's font directory can sometimes pose issues if it's
>>>> installed somewhere else like the system font directory. Do you
>>>> recommend compiling a .app just to provide the fonts? Thanks for any
>>>> suggestions!
>>>>
>>>> Fred
>>>> _______________________________________________
>>>> Do not post admin requests to the list. They will be ignored.
>>>> Pro-apps-dev mailing list (email@hidden
>>>> <mailto:email@hidden>)
>>>> Help/Unsubscribe/Update your Subscription:
>>>>
>>>> This email sent to email@hidden <mailto:email@hidden>
>>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Pro-apps-dev mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden