1 NSArray * array = [UIFont familyNames]; 2 3 for( NSString *familyName in array ){ 4 printf( "Family: %s \n", [familyName UTF8String] ); 5 NSArray *f... ...
分类:
移动开发 时间:
2017-07-21 15:45:11
阅读次数:
236
//建立UISegmentedControl的数组 NSArray *segmentedArray = [NSArray arrayWithObjects:@"线下培训",@"在线培训",@"模拟面试",@"Marlin面试",nil]; UISegmentedControl *segmentedC ...
分类:
移动开发 时间:
2017-07-17 21:50:51
阅读次数:
295
#import <UIKit/UIKit.h> @interface ViewController : UIViewController<UIPickerViewDelegate,UIPickerViewDataSource>{ NSArray *_nameArray; } @property (s ...
分类:
移动开发 时间:
2017-07-10 14:33:26
阅读次数:
317
一、使用方式+ 如下代码块功能:判断字体,判断字体输入格式 NSString *firstStr = [name substringToIndex:1]; NSArray *num = @[@"0",@"1",@"2",@"3",@"4",@"5",@"6",@"7",@"8",@"9"]; if ... ...
分类:
移动开发 时间:
2017-07-08 00:18:02
阅读次数:
272
如果对象是NSString、NSDictionary、NSArray、NSData、NSNumber等类型,可以直接用NSKeyedArchiver进行归档和恢复 不是所有的对象都可以直接用这种方法进行归档,只有遵守了NSCoding协议的对象才可以 NSCoding协议有2个方法: encodeW ...
分类:
其他好文 时间:
2017-07-06 15:14:21
阅读次数:
257
NSArray *array = [[UIApplication sharedApplication] windows]; UIWindow* win=[array objectAtIndex:0]; [win setHidden:NO]; 在调用支付宝payOrder 之前,写上上面三行代码就可以 ...
分类:
移动开发 时间:
2017-07-04 20:20:35
阅读次数:
181
NSArray *windows = [[UIApplication sharedApplication] windows]; if ([windows lastObject] != warningAlertView) { [[windows lastObject] addSubview:warni ...
分类:
移动开发 时间:
2017-07-03 19:55:50
阅读次数:
201
createFileAtPath //创建文件 NSFileManager *fm = [NSFileManager defaultManager]; NSString *strpath = [NSString stringWithFormat:@"%@/file1.txt",NSHomeDirec ...
分类:
其他好文 时间:
2017-07-03 19:11:27
阅读次数:
106
//侧滑-(NSArray )tableView:(UITableView )tableView editActionsForRowAtIndexPath:(NSIndexPath )indexPath{NSStringindexPathRow = [NSString stringWithForma ...
分类:
其他好文 时间:
2017-06-29 19:10:28
阅读次数:
136
@implementation NSArray (Log) - (NSString *)descriptionWithLocale:(id)locale indent:(NSUInteger)level { NSMutableString *mStr = [NSMutableString strin... ...
分类:
编程语言 时间:
2017-06-29 12:37:17
阅读次数:
113