forked from roycms/RCalendarPicker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
params.json
6 lines (6 loc) · 4.22 KB
/
params.json
1
2
3
4
5
6
{
"name": "Rcalendarpicker",
"tagline": "RCalendarPicker 日历控件 ,日历选择控件,日历,日期选择",
"body": "\r\n# RCalendarPicker\r\n\r\nRCalendarPicker Calendar calendar control, select control, calendar, date selection, the clock selection control. 日历控件 ,日历选择控件,日历,日期选择,时钟选择控件\r\n\r\n# Preview\r\n\r\n![预览1](https://roycms.github.io/RCalendarPicker/RCalendarPicker/Resource/calendar.jpg) \r\n![预览2](https://roycms.github.io/RCalendarPicker/RCalendarPicker/Resource/clock.jpg)\r\n\r\n# cocoapods\r\n\r\n```\r\npod 'RCalendarPicker'\r\n```\r\n\r\n# Use \r\n\r\ndefault: MainScreenWidth = 360 MainScreenHeight = 960\r\n```\r\n RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)];\r\n calendarPicker.today = [NSDate date]; //现在时间\r\n calendarPicker.date = calendarPicker.today; //选择时间\r\n calendarPicker.complete = ^(NSInteger day, NSInteger month, NSInteger year, NSDate *date){\r\n NSLog(@\"%d-%d-%d\", (int)year,(int)month,(int)day);\r\n };\r\n [self.view addSubview:calendarPicker];\r\n```\r\n\r\n# The lunar calendar \r\n```\r\nRCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)];\r\n calendarPicker.isZn = YES; //开启农历\r\n calendarPicker.today = [NSDate date]; //现在时间\r\n calendarPicker.date = calendarPicker.today; //选择时间\r\n calendarPicker.complete = ^(NSInteger day, NSInteger month, NSInteger year, NSDate *date){\r\n NSLog(@\"%d-%d-%d\", (int)year,(int)month,(int)day);\r\n };\r\n [self.view addSubview:calendarPicker];\r\n```\r\n\r\n# A clock dial effect\r\n```\r\n RClockPickerView *rClockPickerView = [[RClockPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)\r\n clockRadius:140\r\n clockCalibrationRadius:130];\r\n rClockPickerView.date = [NSDate date];\r\n rClockPickerView.complete = ^(NSInteger hours, NSInteger minutes, NSInteger noon){\r\n NSLog(@\"%d-%d-%d\", (int)hours,(int)minutes,(int)noon);\r\n \r\n };\r\n [self.view addSubview:rClockPickerView];\r\n```\r\n\r\n# calendar + clock use\r\n```\r\nRCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)];\r\n calendarPicker.today = [NSDate date]; //现在时间\r\n calendarPicker.date = calendarPicker.today; //选择时间\r\n [self.view addSubview:calendarPicker];\r\n \r\n calendarPicker.complete = ^(NSInteger day, NSInteger month, NSInteger year, NSDate *date){\r\n NSLog(@\"%d-%d-%d\", (int)year,(int)month,(int)day);\r\n \r\n RClockPickerView *rClockPickerView = [[RClockPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)\r\n clockRadius:140\r\n clockCalibrationRadius:130];\r\n rClockPickerView.date = [NSDate date];\r\n rClockPickerView.complete = ^(NSInteger hours, NSInteger minutes, NSInteger noon){\r\n NSLog(@\"%d-%d-%d\", (int)hours,(int)minutes,(int)noon);\r\n \r\n NSDate *selectDate = [DateHelper dateInDate:date Hours:hours>12?hours%12:hours minutes:minutes];\r\n \r\n NSLog(@\"selectDate: %@\",selectDate);\r\n \r\n };\r\n [self.view addSubview:rClockPickerView];\r\n };\r\n\r\n```\r\n\r\n# TODO\r\n\r\n* 增加上下午的判断和参数处理\r\n* 增加主题定义\r\n* 增加选择年月的切换形式\r\n\r\n",
"note": "Don't delete this file! It's used internally to help with page regeneration."
}