… OK i figured it out myself; this in Rectangle 1>Rectangle Path 1>Size will make the box resizing happen before the round corners and other effects. 🙂
t = thisComp.layer(“tessssstr”);
tRect = t.sourceRectAtTime(time,false);
tUL = t.toComp([tRect.left,tRect.top]);
tLR = t.toComp([tRect.left+tRect.width,tRect.top+tRect.height]);
myRect = sourceRectAtTime(time,false);
myUL = toComp([myRect.left,myRect.top]);
myLR = toComp([myRect.left+myRect.width,myRect.top+myRect.height]);
margin = 10;
[(tLR[0]-tUL[0] + 2*margin),(tLR[1]-tUL[1]+ 2*margin)]
Thanks again Dan for another great solution 🙂