UIScrollView not scrolling after Unchecking “Adjust scroll view insets” xcode 6

前端 未结 3 835
一整个雨季
一整个雨季 2021-01-05 03:11

In my app, I tried to use scroll view. But I encountered an issue where the scroll view added space at the top and bottom, as mentioned in the following question.

Sc

3条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-01-05 03:32

    The way I solved the extra padding between the top label and the nav bar was by unchecking "Under Top Bars" in the attributes inspector, in the "Extended Edges" section. When you uncheck it, items on your storyboard may move around. Don't re-arrange them. Run simulator and it should work.

    Note: leave "Adjust Scroll View Insets" checked, otherwise nothing scrolls.

    My attributes:

提交回复
热议问题