您的位置:首页 > 产品设计 > UI/UE

UIViewContentMode各种模式的样式

2015-09-29 09:32 585 查看
参考文章地址:http://blog.csdn.net/iunion/article/details/7494511

UIViewContentMode主要是给view类型对象设置样式,很多朋友对每种模式具体什么效果还不是很清楚,下面我就用一个简单的例子来给大家说明一下。



UIViewContentMode

typedef enum {

    UIViewContentModeScaleToFill,

    UIViewContentModeScaleAspectFit,      // contents scaled to fit with fixed aspect. remainder is transparent

    UIViewContentModeScaleAspectFill,     // contents scaled to fill with fixed aspect. some portion of content may be clipped.

    UIViewContentModeRedraw,              // redraw on bounds change (calls -setNeedsDisplay)

    UIViewContentModeCenter,              // contents remain same size. positioned adjusted.

    UIViewContentModeTop,

    UIViewContentModeBottom,

    UIViewContentModeLeft,

    UIViewContentModeRight,

    UIViewContentModeTopLeft,

    UIViewContentModeTopRight,

    UIViewContentModeBottomLeft,

    UIViewContentModeBottomRight,

} UIViewContentMode; 

 

 

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: