Search Unity

Issues with the spacing on Grid Layout Group

Discussion in 'UGUI & TextMesh Pro' started by PaperMouseGames, Aug 20, 2019.

  1. PaperMouseGames

    PaperMouseGames

    Joined:
    Jul 31, 2018
    Posts:
    434
    Hi there, sorry if this isn't the right place to ask this, but I'm having issues with a couple of elements of my UI that use the Grid Layout Group.

    So here is what my UI looks like:

    Capture 02.PNG

    Ignore my crappy art haha. So the light grey panels are Scroll Views where the Content object holds the Grid Layout Group. Inside the content are these item slots I created, and all of that seems to work well, but the issue is I really dislike how there is no spacing between the very top of the content panel and the slots.

    I tried putting in a panel just for looks behind the content panel and making the content panel transparent, but then the scroll bar only stretches as far as the content panel and that also looks bad.

    Any ideas on how to get around this? I just want some spacing between the slots and the content panel that has the Grid Layout Group.

    If this isn't clear, let me know and I'll try to add more info, and thanks in advance!