码迷,mamicode.com
首页 >  
搜索关键字:cgrect    ( 583个结果
iOS 通过颜色来生成一个纯色图片
//通过颜色来生成一个纯色图片- (UIImage *)buttonImageFromColor:(UIColor *)color{ CGRect rect = CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.he....
分类:移动开发   时间:2015-04-09 15:09:18    阅读次数:209
2015-4-9学习笔记:添加动画
1、动画(头部-开始动画)[UIView beginAnimations:nil context:nil];2、设置动画的执行时间[UIView setAnimationDuration:2.0]; // 默认时间是1/4秒,可根据自己需要设置3、设置向上移动CGRect temFrame = _b...
分类:其他好文   时间:2015-04-09 10:30:54    阅读次数:96
UILable常用属性和方法
·UILable是iPhone界面最基本的控件,主要用来显示文本信息。 ·常用属性和方法有: 1、创建 CGRect rect = CGRectMake(100, 200, 50, 50); UILabel *label = [[UILabel alloc] initWithFrame:rect]; 2、text //设置和读取文本内容,默认为nil label.text = @”文本...
分类:其他好文   时间:2015-04-08 16:31:25    阅读次数:193
Lable自适应高度方法的封装
ios7---Lable自适应高度封装 +(UILabel *)getInfoLabel:(UILabel *)label withText:(NSString *)ktext withFont:(CGFloat )kfont withtosize:(CGRect)krect withBackGroundColor:(UIColor *)kbackgroundColor { //内容显示 ...
分类:其他好文   时间:2015-04-08 16:29:35    阅读次数:94
根据size截取图片中间矩形区域的图片 这里的size是正方形
#pragma mark 根据size截取图片中间矩形区域的图片 这里的size是正方形-(UIImage *)cutCenterImage:(UIImage *)image size:(CGSize)size{ CGSize imageSize = image.size; CGRect...
分类:其他好文   时间:2015-04-06 15:34:55    阅读次数:132
【新浪微博项目】05--自定义TabBarButton
1.TabBar的层次结构 2.自定义TabBar的背景 可以将一个很短的图片拉长作为背景图片,方法: self.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageWithName:@"tabbar_background"]]; - (id)initWithFrame:(CGRect)f...
分类:其他好文   时间:2015-04-06 01:07:21    阅读次数:177
iOS UILabel详解1
·UILable是iPhone界面最基本的控件,主要用来显示文本信息。 ·常用属性和方法有: 1、创建 CGRect rect = CGRectMake(100, 200, 50, 50); UILabel *label = [[UILabel alloc] initWithFrame:rect]; 2、text //设置和读取文本内容,默认为nil label.text = @”文本...
分类:移动开发   时间:2015-04-04 15:15:07    阅读次数:104
计算UIWebView加载的网页内容高度
key code- (void)webViewDidFinishLoad:(UIWebView *)aWebView{ CGRect frame = aWebView.frame; frame.size.height = 1; aWebView.frame = frame; ...
分类:Web程序   时间:2015-04-02 18:36:26    阅读次数:192
定义参数不固定的方法
1-(id)initWithFrame:(CGRect )frame ImagesAndStringsOfObject:(id )image,...{ self=[super initWithFrame:frame]; if(self) { va_list argum...
分类:其他好文   时间:2015-03-30 15:49:42    阅读次数:226
iphone获取屏幕尺寸以及状态栏
获取状态栏的尺寸 CGRect rect; rect=[[UIApplication sharedApplication]statusBarFrame]; 获取屏幕尺寸 CGRect rect; rect=[[UIScreen mainScreen]bounds]; CGSize size=rect.size; CGFloat width=size.w...
分类:其他好文   时间:2015-03-30 09:29:48    阅读次数:101
583条   上一页 1 ... 39 40 41 42 43 ... 59 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!