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;
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;
相关文章推荐
- UITableView下拉刷新
- UI:归档、反归档、数据持久化
- gui画线和绘制鼠标
- UIDatePicker的用法
- 源码推荐(9.29):几十种效果的图片滤镜,快速集成可拉伸头部图片的UITableView
- 【Espruino】NO.03 从点灯开始
- UI10_tableView的HeaderView
- UI10_快捷菜单
- UI10_3个tableView的省市区联动
- UI10_UITableViewCell自适应高度
- UI_导航视图控制器
- drupal markdown editor for BUEditor
- UGUI学习笔记1——Canvas
- NGUI之按钮置灰
- HDU 3177 Crixalis's Equipment 贪心
- [转自codeforces] How to come up with the solutions: techniques
- Druid 导致图标字体文件不能加载的问题
- UITextField基础属性
- UITextField Delegate 键盘弹起
- 隐藏UIScrollView的滚动条的方法