2019独角兽企业重金招聘Python工程师标准>>>
1. UIViewContentMode
typedef NS_ENUM(NSInteger, UIViewContentMode) {
UIViewContentModeScaleToFill,
UIViewContentModeScaleAspectFit,
UIViewContentModeScaleAspectFill,
UIViewContentModeRedraw,
UIViewContentModeCenter,
UIViewContentModeTop,
UIViewContentModeBottom,
UIViewContentModeLeft,
UIViewContentModeRight,
UIViewContentModeTopLeft,
UIViewContentModeTopRight,
UIViewContentModeBottomLeft,
UIViewContentModeBottomRight,
};
2.各种模式的图示
原图比例:
▽UIViewContentModeScaleToFill
▽UIViewContentModeScaleAspectFit
▽UIViewContentModeScaleAspectFill
▽UIViewContentModeLeft
==============================================
//用于视图的缩放或重设尺寸
//会强制调用drawRect:方法来相应视图变化
//不应该在标准视图中使用该模式
UIViewContentModeRedraw,