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

*HELP* How to align one text line to another using script?

New Here ,
Nov 21, 2018 Nov 21, 2018

I'm trying to build a fairly basic whatsapp template for a commissioned video.

would love to understand how to tell AE: "always align the time to the content text above it"

In the picture I placed the time by hand. my goal is to automate this proccess.

Thanks!

TOPICS
Scripting
285
Translate
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
Community Expert ,
Nov 21, 2018 Nov 21, 2018

The best way is to do this with expressions. You need to write an expression on the position of the "time" text layer that measures the width of the other text (using sourceRectAtTime) and then moves its own position accordingly. This is easier than doing it with a script and more interactive (also if you change the text manually in the project, everything updates).

Next week I am actually publishing a new extension called Pins & Boxes which makes this kind of automatic layout very easy to create - without the need to create your own expressions manually. The projects will also work on machines where "Pins & Boxes" is not installed, so perfect for templates, mogrts etc.

Here is a sample of what you can do with it easily:

sample_vertical_optimized.gif

We probably release it next Monday.

Mathias Möhl - Developer of tools like BeatEdit and Automation Blocks for Premiere Pro and After Effects
Translate
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
New Here ,
Nov 22, 2018 Nov 22, 2018
LATEST

This is exactly what I need!

Would you guide me step by step on how to use the SourceRectAtTime in order to align the time (18:30) to the text above it?

I get confused when it gets to AE scripts

Would get your plugin but i need this to work by Saturday

Thanks!

Translate
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