Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity › Forums › Adobe After Effects Expressions › Text Position for Essential Graphics

  • Text Position for Essential Graphics

    Posted by Andrew Ross on September 15, 2026 at 11:20 am

    Hello. I want to set up a .mogrt and would like the editor to be able to reposition multiple layers of text easily.

    I have 5 layers of text in a row and when updated, these could be anything from 5 letters to 20 letters. Without an expression, when the text is short there is too much space in between and when the text is long, the layers overlap.

    Is there an expression to use to keep the distance of the layers the same no matter what the size of the text layer is?

    OR

    Is it possible to create something like the video attached but with text? Where the layers would be linked to a slider so the editor can easily manipulate spacing with one control.

    Thanks in advance

    Dan Ebberts replied 1 week, 6 days ago 2 Members · 1 Reply
  • 1 Reply
  • Dan Ebberts

    September 15, 2026 at 4:53 pm

    Try this simple setup. Make your text layers the first 5 layers in your comp’s layer stack. Add a null named “control” below the text layers. Add a slider named “gap” to the control layer and set it to the horizontal distance you want between text layers. Add this expression to each text layer’s Position property:

    if (index > 1){
    gap = thisComp.layer("control").effect("gap")("Slider");
    L = thisComp.layer(index-1);
    r = L.sourceRectAtTime(0);
    p = L.toComp([r.left + r.width, r.top]);
    x = p[0] + gap;
    [x,value[1]]
    }else
    value

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