Quantcast
Channel: Adobe Community : Discussion List - After Effects Scripting
Viewing all articles
Browse latest Browse all 2143

Setting Source Text Resets Justification To Center

$
0
0

In simple terms, I am just trying to change the source text on a left justified text object.  However, it keeps resetting the justification to center, instead of just leaving it.  Even when I try to set it to left as part of the process, it doesn't listen.

 

var textProp = myComp.layer('myTextObject').property("Source Text");

var textDocument = textProp.value;

textDocument.text = strings["name"];

textDocument.justification = ParagraphJustification.LEFT_JUSTIFY;

textProp.setValue(textDocument);

textProp.setValue(textDocument);

 

I was trying to setValue twice because I found a thread about a bug that made you do it twice, but that doesn't work either.

 

I was doing it this way, but switched to the above when I found the issue.

myComp.layer('myTextObject').property("Source Text").setValue(strings["name"]);

 

Any help?  Thanks!


Viewing all articles
Browse latest Browse all 2143

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>