contentInsetAdjustmentBehavior
iOS11后新增的属性。当UIScrollView超出safeAreaInsets的范围,需要适当调整scrollView的可视范围确保所有内容都能正常显示,通过这个属性指定周围增加可滚动区域的计算方式。
UIScrollViewContentInsetAdjustmentNever:不需要计算
UIScrollViewContentInsetAdjustmentAlways:总是计算
UIScrollViewContentInsetAdjustmentScrollableAxes:系统根据滚动方向计算
UIScrollViewContentInsetAdjustmentAutomatic:跟Axes相似,考虑兼容之前的情况。
automaticallyAdjustsScrollIndicatorInsets
默认:YES。是否允许系统自动偏移ScrollView的子视图。