上一页 1 2 3 4 5 6 7 8 9 ··· 12 下一页
摘要: 效果如下:ViewController.h1 #import 2 3 @interface ViewController : UITableViewController4 @property (strong, nonatomic) NSMutableDictionary *mDicFontName;... 阅读全文
posted @ 2015-06-15 10:37 KenmuHuang 阅读(346) 评论(0) 推荐(0) 编辑
摘要: 效果如下:ViewController.h1 #import 2 3 @interface ViewController : UIViewController4 @endViewController.m 1 #import "ViewController.h" 2 3 @interface Vie... 阅读全文
posted @ 2015-06-15 10:27 KenmuHuang 阅读(895) 评论(0) 推荐(0) 编辑
摘要: 效果如下:ViewController.h1 #import 2 3 @interface ViewController : UIViewController4 @property (nonatomic, strong) UILabel *lblParent;5 @property (nonatom... 阅读全文
posted @ 2015-06-14 23:29 KenmuHuang 阅读(235) 评论(0) 推荐(0) 编辑
摘要: 效果如下:ViewController.h 1 #import 2 3 @interface ViewController : UIViewController { 4 @private 5 UIImageView *imgVTransform; 6 CGFloat ro... 阅读全文
posted @ 2015-06-14 23:16 KenmuHuang 阅读(228) 评论(0) 推荐(0) 编辑
摘要: 效果如下:ViewController.h 1 #import 2 3 @interface ViewController : UIViewController { 4 @private 5 UILabel *lblMessage; 6 CGFloat colorRed;... 阅读全文
posted @ 2015-06-14 23:03 KenmuHuang 阅读(403) 评论(0) 推荐(0) 编辑
摘要: 为什么需要使用锁,当然熟悉多线程的你,自然不会感到陌生。那你在代码中是否很好的使用了锁的机制呢?你又知道几种实现锁的方法呢?main.m 1 int main(int argc, const char * argv[]) { 2 @autoreleasepool { 3 //... 阅读全文
posted @ 2015-06-14 21:41 KenmuHuang 阅读(12041) 评论(2) 推荐(0) 编辑
摘要: 设备对照表:https://www.theiphonewiki.com/wiki/Models获取设备和 App 信息代码: 1 NSLog(@"设备信息如下"); 2 NSLog(@"detailModel(详细型号): %@", [self detailModel]); //de... 阅读全文
posted @ 2015-06-14 19:30 KenmuHuang 阅读(802) 评论(0) 推荐(0) 编辑
摘要: 讲解 UICollectionView 的相关链接:http://blog.csdn.net/eqera/article/details/8134986关键操作:效果如下:KMCollectionViewCell.h1 #import 2 3 @interface KMCollectionViewC... 阅读全文
posted @ 2015-06-14 16:51 KenmuHuang 阅读(6340) 评论(0) 推荐(0) 编辑
摘要: 在图片处理时,我们总会遇到一些内存优化的问题。​这里介绍的是其中一种内存优化处理方式。场景:App 运行很卡,然后我用 Instruments中的相关工具查看对象的内存占用情况,发现当图片加载到 UICollectionView 容器时, 工具中 Allocations 内存分配栏目,lifespa... 阅读全文
posted @ 2015-06-14 16:26 KenmuHuang 阅读(1835) 评论(0) 推荐(0) 编辑
摘要: - (UIImage *)stretchableImageWithLeftCapWidth:(NSInteger)leftCapWidth topCapHeight:(NSInteger)topCapHeight这是 UIImage 的一个实例方法,它的功能是创建一个内容可拉伸,而边角不拉伸的图片,... 阅读全文
posted @ 2015-06-14 15:42 KenmuHuang 阅读(6292) 评论(0) 推荐(0) 编辑
摘要: 关键技能:使用故事板进行布局时,点击选中控件(组件)并按住 control 键向某个方向拖动,产生一条实线,然后弹出的窗口可以设置控件(组件)的布局约束条件;从而实现自动布局AutoLayout效果。效果如下:iPhone 5siPhone 6​iPhone 6 PlusViewController... 阅读全文
posted @ 2015-06-14 15:16 KenmuHuang 阅读(716) 评论(0) 推荐(0) 编辑
摘要: 效果如下:ViewController.h1 #import 2 @interface ViewController : UIViewController3 @property (strong, nonatomic) IBOutlet UIImageView *imgVQRCode;4 5 @end... 阅读全文
posted @ 2015-06-14 13:52 KenmuHuang 阅读(7146) 评论(0) 推荐(2) 编辑
摘要: Objective-C 2.0增加了Class Extension用于解决两个问题:可声明私有可读写的属性,而在类的声明中是同名的公开只读属性,从而来支持公开只读、私有可读写的属性可声明私有方法;允许一个对象可以拥有一个私有的@interface,且可由编译器验证公开只读、私有可写的属性(Publi... 阅读全文
posted @ 2015-06-13 20:19 KenmuHuang 阅读(2603) 评论(0) 推荐(0) 编辑
摘要: main.m 1 #import 2 #import "NSString+Trim.h" 3 int main(int argc, const char * argv[]) { 4 @autoreleasepool { 5 NSString *strSource = @" ... 阅读全文
posted @ 2015-06-13 20:15 KenmuHuang 阅读(5887) 评论(0) 推荐(0) 编辑
摘要: 可变参数的方法在Objective-C中不罕见,像Cocoa中的很多常见的方法都是可变参数的,如:1 NSLog(NSString *format, ...)2 + (id)arrayWithObjects:(id)firstObj, ...3 + (id)dictionaryWithObjects... 阅读全文
posted @ 2015-06-13 20:12 KenmuHuang 阅读(1147) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 12 下一页
如果您看完本篇博文,觉得对您有所收获,请点击右下角的 [推荐]
如果您想转载,请注明出处(原创内容,请尊重个人劳动成果)
如果您有任何意见或建议,欢迎留言
感谢您的阅读,敬请关注我的后续博客文章