• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Scripting question regarding font change

Explorer ,
Feb 09, 2023 Feb 09, 2023

Copy link to clipboard

Copied

Hey folks, a question. I have some text which I'm importing from csv data and some of it contains some glyphs which this font I'm using doesn't have. A perfect solution is done in after effects in a way that if you for example write this text "Kōṯah-ye ‘As̲h̲rō", and select the font I want to use (in this case "Bahnschrift Regular") it will not show ṯ or s̲h̲, because these glyphs don't exist in this font family.

If I however change it to Arial Regular and then back to Bahnschrift Regular in character panel, After Effects automatically leaves missing glyphs in Arial font, which is an ideal solution. The problem is, if you do this with script (.font = "Bahnschrift Regular"), this automatic replacement doesn't happen.

 

Anyone knows what's different when you manually change font in character panel in AE VS a script. Any help would be much appreciated, thanks.

TOPICS
Error or problem , Expressions , How to , Scripting

Views

228

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 09, 2023 Feb 09, 2023

Copy link to clipboard

Copied

It's probably a fallback mechanism in the Adobe font engine itself to retain the underlying input, but since it's a black box you won't have access to it.

 

Mylenium

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Feb 09, 2023 Feb 09, 2023

Copy link to clipboard

Copied

Thanks, I guessed so. So my next question then, is it possible with scripting to show a missing/undrawn glyph and then replace that individual character with desirable font. I couldn't find a method for showing if glyph is missing in a font...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 09, 2023 Feb 09, 2023

Copy link to clipboard

Copied

I don't think you'll have this kind of access. Again, this is probably an internal thing to Adobe's super-secret font engine and AE has its own limitations. I would imagine that you could do it e.g. in InDesign since it's much more advanced in that department so there may be a way to e.g. create a list of missing glyphs in ID with a script and use that as reference in AE, but I'm pretty sure there's no live checking in AE.

 

Mylenium

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Feb 09, 2023 Feb 09, 2023

Copy link to clipboard

Copied

Ok, thank you very much.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Feb 10, 2023 Feb 10, 2023

Copy link to clipboard

Copied

Just one more question, is there a method to return bool value whether character is visible on screen or not?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 10, 2023 Feb 10, 2023

Copy link to clipboard

Copied

LATEST

Nope, don't think so.

 

Mylenium

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines