Skip to main content
zaka2868632
Participant
August 16, 2018
Answered

Resize Text Box in Motion Graphics Template

  • August 16, 2018
  • 2 replies
  • 2447 views

Hey all,

I'm working with some text callouts, built in after effects and imported into premiere as motion graphics templates. They are shape layers and a text layer. Using sourceRectAtTime I have the shape layer box adjust automatically to the text, but the width of the box never changes. Sometimes this creates an "orphaned" word on the last line.

Is it possible to code so that I can adjust the text box size in premiere so that the text flows more naturally for each graphic? Thanks!

    This topic has been closed for replies.
    Correct answer Mylenium

    Simply use line text and manually wrap the lines. You cannot mess with paragraph text using expressions.

    Mylenium

    2 replies

    foughtthelaw
    Inspiring
    August 17, 2018

    what Mylenium said. there's no access to the box text dimensions via expressions, just do it the old fashioned way and manually break the lines.

    Mylenium
    MyleniumCorrect answer
    Legend
    August 16, 2018

    Simply use line text and manually wrap the lines. You cannot mess with paragraph text using expressions.

    Mylenium

    Participant
    August 25, 2022

    Hi @Mylenium However, accessing the text box via expression would be extremely helpful. We build templates with variable text boxes. If the box is made smaller, the text should wrap differently. Up to now, this has only been possible by scaling the box smaller and offsetting the font size for the text. It creates complicated solutions. Direct access to the bounding box of the text would be much simpler! Look this Post too:

    https://adobe-video.uservoice.com/forums/911311-after-effects/suggestions/42422542-expose-paragraph-text-box-width-height-for-express
    Best regards, Philippe

    Community Expert
    August 25, 2022

    You cannot access the Text Area dimensions with sourceRectAtTime(), but you can scale or size the font to fit the shape layer box. I don't know how to achieve automated widow and orphan control, but you could add a slider that changed the global kerning or scaled the font so the Premiere Pro UI could control the text size/leading and kerning to prevent orphans.