Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Automatically scale text layer to accomodate the length of text

  • Dan Ebberts

    September 23, 2023 at 6:56 pm

    Try it this way:

    maxW = thisComp.width*0.9;
    maxH = thisComp.height*0.15;
    r = sourceRectAtTime(time);
    w = r.width;
    h = r.height;
    s = h > 0 ? (w/h > maxW/maxH ? maxW/w : maxH/h) : 0;
    [100,100]*s
  • George Henderson

    October 3, 2023 at 3:36 am

    Amazing! This worked exactly as I had hoped. Thank you so much, sir!

  • Brie Clayton

    October 4, 2023 at 3:05 am

    Thank you for your solve, Dan!

Page 2 of 2

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