- Home /
Question by
ReDarkTechnology · May 19 at 12:28 PM ·
uirecttransformrect
Changing the size of the RectTransform's rect
I was trying to copy another UI's rect from it's RectTransform in a different parent, unfortunately the rect property is read-only. I tried sizeDelta but it's relative to it's parents and it doesn't really work for me.
And here's the result when trying to use SizeDelta - the code is
sceneScaler.sizeDelta = viewportManager.sizeDelta
Is there anyway for me to be able to do this? [I need both of them to be the same size]
unknown.png
(18.6 kB)
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220613060739im_/https://answers.unity.com/themes/thub/images/avi.jpg)