码迷,mamicode.com
首页 >  
搜索关键字:cgrect    ( 583个结果
在控制器上加一个遮盖
先见一个遮盖类1.h文件#import CGPoint CGRectGetCenter(CGRect rect);CGRect CGRectMoveToCenter(CGRect rect, CGPoint center);@interface UIView (ViewFrameGeometry)@...
分类:其他好文   时间:2015-04-17 17:56:28    阅读次数:146
UI UIView进度条,模拟手机充电功能
#import "JRProgres.h" @implementation JRProgres {     UIView * _contentView; } - (instancetype)initWithFrame:(CGRect)frame{// 重写构造方法一次创建3个视图,分别为最外层的绿框、子1白底、子2红条     self = [super init...
分类:移动开发   时间:2015-04-17 11:28:26    阅读次数:184
oc UI输入数字n创建n条彩虹 IMP
RainBow.m #import "RainBow.h" @implementation RainBow {     NSArray * _colorArray; } -(instancetype)initWithFrame:(CGRect)frame withNum:(NSInteger) num{...
分类:其他好文   时间:2015-04-16 20:01:29    阅读次数:120
图片分割
- (UIImage *)clipImage: (UIImage *)image inRect: (CGRect) rect{//返回image中rect范围内的图片 CGImageRef imageRef = CGImageCreateWithImageInRect(image.CGImage,....
分类:其他好文   时间:2015-04-16 19:24:00    阅读次数:94
初识UI
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {     UIWindow * window = [[UIWindow alloc]initWithFrame:[UIScreen mainScreen].bound...
分类:其他好文   时间:2015-04-16 12:29:26    阅读次数:111
IOS UISwitch 用法总结
IOS 系统开关控件简单使用总结: 初始化: - (instancetype)initWithFrame:(CGRect)frame;? 这个frame是没有意义的,系统的开关控件大小是确定的。 设置开关开启状态时的颜色 @property(nonatomic, retain) UIC...
分类:移动开发   时间:2015-04-15 17:20:45    阅读次数:148
iOS开发--截图UIImage的一部分
不废话,贴代码.这里对图片进行了旋转操作 方法写在UIImage的类别里 - (UIImage *) croppedImage:(CGRect)cropRect { CGImageRef croppedCGImage = CGImageCreateWithImageInRect(self.CGImage ,cropRect); UIImage *croppedImage = [...
分类:移动开发   时间:2015-04-15 17:10:22    阅读次数:135
[UIScreen mainScreen].bounds;与[UIScreen mainScreen].applicationFrame;的区别
经测试,发现:[UIScreen mainScreen].bounds;返回的CGRect,包含状态栏20的高度。[UIScreen mainScreen].applicationFrame;返回的CGRect,不包含状态栏20的高度。在此记录下,方便以后查阅。不要笑我菜鸟!
分类:移动开发   时间:2015-04-14 19:35:41    阅读次数:161
[iOS 前端笔记+小技巧]
我决定倒着写了。。。7.给collectioncell加边框 或者给任何view加边框的方法- (id)initWithFrame:(CGRect)frame{ self = [super initWithFrame:frame]; if (self) { // 初始...
分类:移动开发   时间:2015-04-12 19:07:45    阅读次数:132
foundation基本用法
1* OC中的结构体lNSRange(location length)lNSPoint \ CGPointlNSSize \ CGSizelNSRect \ CGRect (CGPoint CGSize)使用CG.. 结构体需要添加CoreGraphiceNS…. 是一个框架Foundation ,...
分类:其他好文   时间:2015-04-09 15:15:55    阅读次数:283
583条   上一页 1 ... 38 39 40 41 42 ... 59 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!