0

I have a simple (I believe) setup.

Scroll view constraints set to 0, 0, 0, 0.

Content View inside set to 0, 0, 0, 0 and vertically/horizontally align center. Inside the Content View I want to have scrolling enabled for a bunch of labels lets say.

The problem I'm having is the ScrollView section does scroll, however does not fill the entire view. I've seen suggestions to set automaticallyAdjustsScrollViewInsets = NO however in the below scenario that completely disables any kind of scrolling.

What am I doing wrong here? All I'm trying to do is having a full scroll matching the view size with a bunch of different elements inside.

enter image description here

aherrick
  • 19,799
  • 33
  • 112
  • 188
  • what is your scroll view size and content view size ? – Teja Nandamuri Nov 19 '15 at 23:54
  • pls note that scrollview will ponly scroll if its content is larger than the scrollview frame!!! if your scrollview height is 300, then your content view should be atleast 400 – Teja Nandamuri Nov 19 '15 at 23:55
  • The ScrollView is would be just the height of the View itself. The Label I'm updating dynamically when the view loads with multi line text that extends past the View. Do I need to somehow "refresh" the ScrollView size? Something like this: http://stackoverflow.com/questions/2944294/how-i-auto-size-a-uiscrollview-to-fit-the-content – aherrick Nov 20 '15 at 11:41
  • if u have only image view and label, y don't u use table view for that, scrolling is handled by table view well!!! You can constraint the label to table cell, so that table cell gets expanded based on label text!!! – Teja Nandamuri Nov 20 '15 at 11:44
  • u need to update the scrollview content size!!! – Teja Nandamuri Nov 20 '15 at 13:32

0 Answers0