Skip to main content
Inspiring
Nov 3, 2022 12:02 AM UTC
Open for Voting

I wish that when Text layer gets its text via expression, that all formatting came with it

I have a project with many comps that have similar text in them. I wanted to use expressions to link each text layer to a Primary comp that would control all the other text layers. This way, all the comps automatically have the same text as the Primary comp, and if I fix a typo in the primary comp, all the layers pointing to it automatically update.

The expression I'm using on the "subscribing" text layer looks like this:

comp("PrimaryComp").layer("[TEXT LAYER] 04-TextLayer").text.sourceText

 It works to get the text from the 04-TextLayer in PrimaryComp, but the text formatting doesn't appear the same. 

Hence my wish that formatting would appear in the layers using this expression.

4 replies

Bruno Quintin
Inspiring
Nov 4, 2022 8:53 AM UTC

What is your version of after effects?

Translate
wesplateAuthor
Inspiring
Nov 3, 2022 6:23 PM UTC

I used your expression, however it does not help. It behaves the same way as when I use the pickwhip to create the expression in my original post. The Primary comp's text layer includes text of different font sizes. When I use expressions, either what AE generates or with yours, the different text sizes do not come across into the expressioned layer.

Translate
wesplateAuthor
Inspiring
Nov 3, 2022 6:20 PM UTC
Thank you, how can I get this via the pickwhip?
Translate
Bruno Quintin
Inspiring
Nov 3, 2022 9:54 AM UTC
var ref = comp("PrimaryComp").layer("[TEXT LAYER] 04-TextLayer").text.sourceText;
ref.style.setText(ref);
Translate