码迷,mamicode.com
首页 >  
搜索关键字:uicolor uiimage    ( 1989个结果
Swift开发教程--设置UIViewController的背景透明
非常easy的一句代码 self.view.backgroundColor = UIColor.clearColor() 由此联想开来,非常多的控件想设置为背景透明都能够用UIColor.clearColor() 非常easy的一句代码 self.view.backgroundColor = UIC ...
分类:编程语言   时间:2017-08-12 10:19:05    阅读次数:180
[UIImage imageWithContentsOfFile:@""] 内存警告
You will want to use the [UIImage imageWithContentsOfFile:@""] method, as that doesn't cache images. imageNamed: caches any images that are loaded thr ...
分类:其他好文   时间:2017-08-04 20:32:47    阅读次数:113
(一二〇)CALayer的一些特性
1.每一个View都自带一个CALayer,称为rootLayer,layer能够和实现与View一样的显示功能,可是它不继承UIResponse,也就是说它无法处理事件,所以为了处理事件还是要用View,假设仅仅是显示,能够选择layer。 以下的代码实现了自己定义一个layer加入到控制器的ro ...
分类:其他好文   时间:2017-08-04 19:30:00    阅读次数:146
iOS 设置字体为渐变色
方法类 引用 ...
分类:移动开发   时间:2017-08-04 15:22:54    阅读次数:284
iOS图片加水印效果的实现并保存至相冊
图片加水印效果的实现并保存至相冊 实现效果如图: project下载:githubproject下载链接 代码: - (void)viewDidLoad { [super viewDidLoad]; UIImage *image = [UIImage imageNamed:@"pushu.jpg"] ...
分类:移动开发   时间:2017-08-04 10:10:28    阅读次数:271
loadNibNamed:(NSString *)name owner:(nullable id)owner options:(nullable NSDictionary *)options用法
1.name xib的名字 owner当前类对象 options初始参数 实际应用: nibs[0]是当前view的对象 nibs[1]当前view的背景 ,我们可以在init中对当前frame以及当前view的背景的frame进行赋值, nibs[1]的背景是半透明的,如果当前的xib是View, ...
分类:其他好文   时间:2017-08-03 12:30:45    阅读次数:485
core image几个滤镜样例 oc版本号和swift版本号
oc版本号 //万花筒模式 + (CGImageRef) getKaleidoscope:(CIContext *)context { CIImage * image = [CIImage imageWithCGImage:[UIImage imageNamed:@"Icon"].CGImage]; ...
分类:编程语言   时间:2017-07-31 12:31:48    阅读次数:225
Block系列2:Block内存管理
ViewController.h #import <UIKit/UIKit.h> @interface ViewController : UIViewController { UIImage *_image; NSInteger _index; } @endViewController.m #imp ...
分类:其他好文   时间:2017-07-25 16:00:52    阅读次数:127
iOS 获取图片某一点的颜色对象(UIColor*)。
- (UIColor *)colorAtPixel:(CGPoint)point { // Cancel if point is outside image coordinates if (!CGRectContainsPoint(CGRectMake(0.0f, 0.0f, self.size.w ...
分类:移动开发   时间:2017-07-24 10:06:43    阅读次数:198
UITabBarController ---- 标签视图控制器
直接上代码: // // AppDelegate.m // // #import "AppDelegate.h" #import "RootViewController.h" #import "FirstViewController.h" #import "SecnodViewController. ...
分类:其他好文   时间:2017-07-23 13:30:16    阅读次数:191
1989条   上一页 1 ... 14 15 16 17 18 ... 199 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!