NHFHorizontalPickerView 1.0.4

NHFHorizontalPickerView 1.0.4

测试已测试
Lang语言 Obj-CObjective C
许可证 MIT
发布最新发布2017年8月

牛宏飞 维护。



  • 作者
  • 牛宏飞

介绍

左右滑动选择文本数据

安装

  • pod 'NHFHorizontalPickerView'
  • 手动下载然后将文件夹拖至工程中即可

使用方法

NSMutableArray *array = [NSMutableArray new]; for (int i=1; i<200; i++) { [array addObject:[NSString stringWithFormat:@"%d", i]]; }

CGFloat offset = 49.f; HorizontalPickerView *horizontalPickerView = [[HorizontalPickerView alloc] initWithFrame:CGRectMake(offset, offset, CGRectGetWidth(self.view.frame)-2*offset, offset) minimumLineSpacing:8]; [horizontalPickerView setBackgroundColor:[UIColor grayColor]]; [horizontalPickerView setResource:array]; horizontalPickerView.horizontalPickerViewSelect = ^(NSString *object) { NSLog(@"object = %@", object); }; [self.view addSubview:horizontalPickerView];