![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
iOS
Alta的木棉花
天下女子有情,宁有如杜丽娘者乎!梦其人即病,病即弥连,至手画形容传于世而后死。死三年矣,复能溟莫中求得其所梦者而生。如丽娘者,乃可谓之有情人耳。情不知所起,一往而深,生者可以死,死可以生。生而不可与死,死而不可复生者,皆非情之至也。梦中之情,何必非真,天下岂少梦中之人耶?必因荐枕而成亲,待挂冠而为密者,皆形骸之论也。
展开
-
UITextView文本居上显示
[_itv_textviewsetContentOffset:CGPointZero];原创 2014-07-17 11:51:25 · 1710 阅读 · 0 评论 -
CUICatalog: Invalid asset name supplied: , or invalid scale factor: 2.000000
在控制台中输出警告信息:CUICatalog: Invalid asset name supplied: , or invalid scale factor: 2.000000是因为image=[UIImageimageNamed:@""]; name为空了原创 2015-03-11 12:28:28 · 815 阅读 · 0 评论 -
IOS版本更新过程中遇到未能创建图标的问题
当我把我的项目由1.0版本更新成1.1版本,我填写完信息保存的时候,总出现“未能创建图标”的提示。原来是因为我的图标选取的是1.0版本原来的图标,名字没有变化,所有总是提示这个信息,只要把该图标变换个名称就可以了。原创 2015-04-14 15:17:58 · 853 阅读 · 0 评论 -
小知识点
_image.image=[UIImageimageNamed:@"Image"]; _image.layer.cornerRadius=_image.frame.size.width/2; _image.layer.masksToBounds=YES; _image.layer.borderColor=[UIColorredColor].CGCo原创 2015-06-16 14:08:20 · 398 阅读 · 0 评论 -
CocoaPods遇到的问题
/Library/Ruby/Gems/2.0.0/gems/cocoapods-core-0.37.2/lib/cocoapods-core/standard_error.rb:87:in `message': incompatible character encodings: ASCII-8BIT and UTF-8 (Encoding::CompatibilityError)from /L原创 2015-06-09 14:42:15 · 926 阅读 · 0 评论 -
设置字符串的属性
/** * 可以让一个label显示两种不同颜色,字体不同大小 * * @param parentString 父字符串 * @param subString 需要改变颜色的子字符串 * @param color 颜色 * @param size 字体大小 * * @return 处理后带原创 2015-06-10 12:22:51 · 678 阅读 · 0 评论 -
iOS 的几种数据持久化方案
引用:http://www.cocoachina.com/ios/20150720/12610.html //************************沙盒************************ //应用程序包,里面存放的是应用程序的源文件,包括资源文件和可执行文件 NSString *path=[[NSBu转载 2015-07-21 10:52:30 · 393 阅读 · 0 评论 -
给URL标示特别颜色
- (NSMutableAttributedString *)filterLinkWithContent:(NSString *)content { NSMutableAttributedString *attributedString = [[NSMutableAttributedStringalloc] initWithString:content]; NSE原创 2015-10-21 17:05:06 · 714 阅读 · 0 评论 -
更改Xcode工程名
1.将要旧的工程文件夹collectionView更名为TableViewDemo,并打开如图:2.将文件夹中的工程名改为TableViewDemo,如图所示:3.右键点击TableViewDemo.xcodeproj,选择显示包内容,打开如图:4.右键点击 project.pbxproj,,选择打开方式为文本编辑原创 2015-09-24 10:15:50 · 485 阅读 · 0 评论 -
Error Domain=WebKitErrorDomain Code=102 "Frame load interrupted" UserInfo=0x16dc65a0 {NSErrorFailing
使用webView加载百度网页的时候,加载失败,error为:Error Domain=WebKitErrorDomain Code=102 "Frame load interrupted" UserInfo=0x16dc65a0 {NSErrorFailingURLKey=file://www.baidu.com, NSErrorFailingURLStringKey=file://www.原创 2015-03-16 11:42:44 · 9940 阅读 · 0 评论 -
使用agvtool 自动化操作version and Build Numbers 的步骤
1.Build Numbers 存储在应用程序的Info.plist中,CFBundleVersion (Bundle version).2.先在Xcode project中设置agvtool工具可用,target ->Build Settings->combined->Versioning 2.1 Set Current Project Version to a value o原创 2015-02-12 15:16:32 · 2418 阅读 · 1 评论 -
Unable to boot the iOS Simulator
在我的mac中,安装了Xcode6 和Xcode5 ,当我两个版本的Xcode的模拟器都打开的时候,用Xcode5运行程序,则提示出错信息Unable to boot the iOS Simulator (不能引导启动IOS模拟器,因为不能区分要使用哪一个)原因:旧版本的模拟器与新版本的模拟器同时运行就会这样,解决办法:如果你想使用旧版本的xcode和模拟器就把新原创 2015-01-19 16:22:30 · 5088 阅读 · 0 评论 -
自定义cell上面,根据属性设置textview的可编辑状态
自定义一个UITableViewCell,cell里面有一个UITextView,原创 2014-07-17 18:01:31 · 1159 阅读 · 0 评论 -
ios7中使用ScrollView上方留空白
1.tableView中嵌入了scrollView,在ios7中使用的时候,yo原创 2014-05-29 12:05:11 · 1471 阅读 · 0 评论 -
Collection <__NSArrayM: 0xaf88c50> was mutated while being enumerated.的解决办法
这类的错误,是同时对一个数组进行了操作原创 2014-07-10 12:00:12 · 603 阅读 · 0 评论 -
objc-setassociatedobject-function-error-in-64bit-mode-not-in-32bit
ok guys , there is simple and elegant solution to solve this :) little explanation :On iOS for arm64, the isa field of Objective-C objects is no longer a pointer. Some of the bits still encode t转载 2014-08-08 09:25:03 · 807 阅读 · 0 评论 -
计算字符串的height
#define ISIOS7 ([[[UIDevice currentDevice] systemVersion] compare:@"7.0"] != NSOrderedAscending )-(CGFloat)fn_heightWithString:(NSString *)string font:(UIFont *)font constrainedToWidth:(CGF原创 2014-08-14 16:28:32 · 430 阅读 · 0 评论 -
Assertion failure in -[SKSTableView _configureCellForDisplay:forIndexPath:]
今天做项目的时候,在使用SKSTableView的时候,遇到这样子的问题Assertion failure in -[SKSTableView _configureCellForDisplay:forIndexPath:], /SourceCache/UIKit_Sim/UIKit-2935.137/UITableView.m:6509,经排查,是因为在-(UITableViewCell*原创 2014-12-04 11:39:16 · 986 阅读 · 0 评论 -
一次性取数组中的五个元素
NSArray *arr=@[@"1",@"2",@"3",@"4",@"5",@"6",@"7",@"8",@"9",@"10",@"11",@"12"]; NSIndexSet *indexs=[NSIndexSetindexSetWithIndexesInRange:NSMakeRange(0,5)]; NSArray *arr1=[arr object原创 2014-12-11 15:30:42 · 1164 阅读 · 0 评论 -
diff: /../Podfile.lock: No such file or directory diff: /Manifest.lock: No such file or directory er
下载带有cocoapods管理第三方库的工程,运行时会出现diff: /../Podfile.lock: No such file or directory diff: /Manifest.lock: No such file or directory error: The sandbox is not in sync with the Podfile.lock. Run 'pod insta原创 2015-02-04 23:24:48 · 5210 阅读 · 0 评论 -
给label加中划线
self.newpriceLabel.text = @"¥100"; NSString *oldStr = @"¥120"; //中划线 NSDictionary *attribtDic =@{NSStrikethroughStyleAttributeName: [NSNumbernumberWithInteger:NSUnderlineSt原创 2015-10-31 17:57:14 · 544 阅读 · 0 评论