Autoscale: Textbox with fixed width and dynamic height, and responsive text.
Please note that I have a learning disability: I have dyslexia. Forgive me if you notice grammar errors etc. I try my best to ask good questions, but I am limited in terms of my disability to write things correctly.
I have been using this expression to create an autoscale text box:
//size
s=thisComp.layer("asfdaf dfghf ");
w=s.sourceRectAtTime().width;
h=s.sourceRectAtTime().height;
[w,h]
//Box
s=thisComp.layer("asfdaf dfghf ");
w=s.sourceRectAtTime().width/2;
h=s.sourceRectAtTime().height/2;
l=s.sourceRectAtTime().left;
t=s.sourceRectAtTime().top;
[w+l,h+t]However, thus code scales my textbox both length and width. What I am looking for is to have a fixed maximum width, with no spillover. If the text reaches the width it scales downward to fill in space otherwise, if you press enter the text goes to a new line and auto-scales to a maximum height. The box itself is responsive but only through its height.
Is this possible? I did see a plugin called pins and boxes, however, I don't have the budget to buy the pluggin at the moment.
