3

I have a scroll rect that has input fields in it, and I would like it so that the user only sees things that are currently in it. Right now it is overflowing and has everything in it going out below it. I would like it so that these bottom fields do not show until the user scrolls down, the only thing in view should be what is currentlyenter image description here

1 Answer 1

10

Use a mask component with your Scroll Rect holding object. Either Rect Mask 2D or Mask.

enter image description here

Sign up to request clarification or add additional context in comments.

3 Comments

It works thank you so much! Also, for anyone else who has this problem in the future, the gameobject with the mask also needs an image on it
With RectMask2D you don't need an extra image.
Yes use RectMask2D, it has much better performance and should be the default option for 2D ui

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.