Fill panel content automatically

Hi,

I have a UI panel that should look like the following:

41786-screen.jpg

The green one is the UIPanel. The blue box should contain the title and the red box the content. However, the Panel will be stretched to the height of the window. The red box should also be stretched 100% - title height and 10 space (like the screenshot). So it the height of the window will be increased the red box should also be increased the same. How can I realize this (in the inspector)?

Set the Pixel Inset to:
X:0
Y:0
W:0
H:0
The position:
X:0.5
Y:0.5
Z:0
The Scale:
X:1
Y:1
Z:1

This is how I solved the problem: Define the element to “stretch”. After that you define how many pixels from top are space and then you get it.