Author Topic: ScrollView auto height to fill rest of screen  (Read 2903 times)

tracerstevens

  • Guest
ScrollView auto height to fill rest of screen
« on: November 10, 2013, 07:54:13 PM »
I'd like to have two scrollviews one on top of the other.  The bottom scrollview (anchored to the bottom and stretched horizontally) would be set at a fixed height, how do I auto size the height of the top scrollview to fill in the rest of the space?

Thank you
« Last Edit: November 10, 2013, 08:02:12 PM by tracerstevens »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: ScrollView auto height to fill rest of screen
« Reply #1 on: November 11, 2013, 12:23:58 PM »
By using UIStretch component. Modular UI video tutorial might help you here.

murteas

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 4
    • View Profile
Re: ScrollView auto height to fill rest of screen
« Reply #2 on: February 13, 2014, 05:53:22 PM »
Is this advice still valid after the latest release?  UIStretch is deprecated right?   so how would one do this now?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: ScrollView auto height to fill rest of screen
« Reply #3 on: February 14, 2014, 05:31:54 AM »
Yup, it's deprecated as of 3.0.7 (a month after this post).

You can use the new layout system. Scroll views go on clipped panels, and clipped panels can be anchored.