Under paragraph menu, there is an option to align text to the left, center or right. There is also an option to justify text.
How can this me done with expressions or Extendscript?
I noticed that if I set Anchor point to the top left, additional text added on the same line is left aligned. If I set anchor point to the left-center, all the lines added in the future are left justified, but current text remains as it is. Align options under paragraph don't move anchor point and also work for the text already typed.
I guess you could save the text, delete it, move anchor point, paste the text back and move anchor point back where it was to achieve the same effect. But there is probably a better way?
These options are not accessible with expressions. They are part of the text panel and stored in teh source text compound keyframes, not as separate properties. therefore the only way to address them programmatically is to use scripts. Check the script help for the various properties. Otherwise one would simply use text animators to create the illusion.
Hi Tim Sx
With Extendscript you can justify the following way:
var myLay = yourTextLayerGoesHere;
var txtProp = myLay.property("Source Text");
var txtDoc = txtProp.value;
txtDoc.justification = ParagraphJustification.CENTER_JUSTIFY; // change here to the value you need based on the list below
The justification can be any of the below options:
I hope this helps.
Thank you both. I am learning so much.
In Ae ver. 2020 some new text properties were added in the expressions menu:
I still can't find a way to control the paragraph direction via code 🤔
Am I missing something or is it still not possible?