Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Bolding specific words from dynamically sourced text

  • Bolding specific words from dynamically sourced text

    Posted by Matt Miller on May 15, 2019 at 8:50 pm

    I am using a plug-in that references an external text file to dynamically populate different text fields in an After Effects composition. I need to be able to bold specific words within a text field and I was hoping I could do it using an expression or a script.

    I was hoping specifically that I could use some type of identifier in my text file to let the expression/script know what words to bold.

    Example Text: Available on new 2019 Santa Fe vehicles purchased from dealer stock between *5/1/19 and 6/3/19.*

    Available on new 2019 Santa Fe vehicles purchased from dealer stock between 5/1/19 and 6/3/19.

    In this case, everything between the asterisks would be bolded.

    Does anyone have any experience with something like this?

    Thanks!

    Malcolm Ricci replied 3 years, 8 months ago 5 Members · 5 Replies
  • 5 Replies
  • Dan Ebberts

    May 15, 2019 at 9:29 pm

    Unfortunately, expressions and scripts don’t have access to per-character formatting, and if the text is modified by a script or expression, all characters acquire the attributes of the first character.

    You could do your example with a script, if the script created a separate layer for the bold part, applied the bold font to that part, and then aligned the two pieces, but it would probably get messy if you had a bunch of bold sections.

    Dan

  • Oleg Pirogov

    May 16, 2019 at 12:20 am

    As Dan have said, you can’t set part of a text to bold through expressions. You may, however, apply different stroke width to different parts of the text through text animator.

    Increasing stroke width will get you “kinda bold” look, which may or may not be a suitable workaround for you, depending on how much you care about font neatness.

  • Tomas Bumbulevičius

    May 16, 2019 at 11:53 am

    Totally agree. What helps in relation with a stroke width though – applying a bit of tracking to selected/highlighted portion of text, which allows to give some breathing space.

    Find out more:
    After Effects Tutorials: motion design, expressions, scripting.

  • Malcolm Ricci

    September 6, 2022 at 2:07 pm

    Hey all,

    I’ve come across a similar problem and was wondering whether you could explain the whole stroke width with expressions solution in a bit more detail please.

    Thanks.

  • Malcolm Ricci

    September 6, 2022 at 4:52 pm

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy