All Projects → roycms → Rcalendarpicker

roycms / Rcalendarpicker

Licence: mit
RCalendarPicker A date picker control, Calendar calendar control, select control, calendar, date selection, the clock selection control. 日历控件 ,日历选择控件,日历,日期选择,时钟选择控件

Projects that are alternatives of or similar to Rcalendarpicker

Kvkcalendar
A most fully customization calendar and timeline library for iOS 📅
Stars: ✭ 160 (+32.23%)
Mutual labels:  cocoapods, calendar
Cornercal
A simple, clean calendar and clock app for macOS.
Stars: ✭ 213 (+76.03%)
Mutual labels:  calendar, clock
Calendarkit
📅 Calendar for Apple platforms in Swift
Stars: ✭ 2,049 (+1593.39%)
Mutual labels:  cocoapods, calendar
Datez
📆 Breeze through Date, DateComponents, and TimeInterval with Swift!
Stars: ✭ 254 (+109.92%)
Mutual labels:  cocoapods, calendar
Md Date Time Picker
An implementation of Material Design Picker components in vanilla CSS, JS, and HTML
Stars: ✭ 272 (+124.79%)
Mutual labels:  calendar, clock
Koyomi
Simple customizable calendar component in Swift 📆
Stars: ✭ 716 (+491.74%)
Mutual labels:  cocoapods, calendar
Timestamp
⏰ A better macOS menu bar clock.
Stars: ✭ 296 (+144.63%)
Mutual labels:  calendar, clock
Fscalendar
A fully customizable iOS calendar library, compatible with Objective-C and Swift
Stars: ✭ 9,829 (+8023.14%)
Mutual labels:  cocoapods, calendar
Swiftloader
A simple and beautiful activity indicator written in Swift
Stars: ✭ 116 (-4.13%)
Mutual labels:  cocoapods
Dddkit
360 video player for iOS written in swift - a subset of SceneKit that works
Stars: ✭ 118 (-2.48%)
Mutual labels:  cocoapods
Calendar
微信小程序日历 酒店日历选择 带公历节日
Stars: ✭ 116 (-4.13%)
Mutual labels:  calendar
Emspinnerbutton
UIButton sublcass with loading animation
Stars: ✭ 117 (-3.31%)
Mutual labels:  cocoapods
Calendar
📆 calendar 日历
Stars: ✭ 119 (-1.65%)
Mutual labels:  calendar
Rhythmbox
A Rhythm Box System for your iOS app written in Swift. 🎵
Stars: ✭ 116 (-4.13%)
Mutual labels:  cocoapods
Actionclosurable
Extensions which helps to convert objc-style target/action to swifty closures
Stars: ✭ 120 (-0.83%)
Mutual labels:  cocoapods
Foundationextension
Foundation/Cocoa/UIKit extension kit. Reference document:
Stars: ✭ 115 (-4.96%)
Mutual labels:  cocoapods
Compactcalendarview
An android library which provides a compact calendar view much like the one used in google calenders.
Stars: ✭ 1,504 (+1142.98%)
Mutual labels:  calendar
Yii2fullcalendar
JQuery Fullcalendar Yii2 Extension
Stars: ✭ 120 (-0.83%)
Mutual labels:  calendar
Swiftuiblurview
This view is also part of SwiftUIKit: https://github.com/danielsaidi/SwiftUIKit
Stars: ✭ 120 (-0.83%)
Mutual labels:  cocoapods
Chrono
Date and time library for Rust
Stars: ✭ 1,780 (+1371.07%)
Mutual labels:  calendar

logo

RCalendarPicker

RCalendarPicker Calendar calendar control, select control, calendar, date selection, the clock selection control. 日历控件 ,日历选择控件,日历,日期选择,时钟选择控件

CocoaPods Packagist email doc

Preview

预览1 预览1

cocoapods

Pod installation failure Please have a look at issues2 https://github.com/roycms/RCalendarPicker/issues/2

pod 'RCalendarPicker'
---or---
pod 'RCalendarPicker', :git => 'https://github.com/roycms/RCalendarPicker.git'

Run

cd myfinder
git clone https://github.com/roycms/RCalendarPicker.git
cd RCalendarPicker
run pod install
xcode open RCalendarPicker.xcworkspace

Use Introduce file

Introduce the head file

#import "RCalendarPickerView.h" // The calendar
#import "RClockPickerView.h" // A clock dial effect
#import "DateHelper.h" // Time processing with the help of the class

calendar

default: MainScreenWidth = 360 MainScreenHeight = 960

 RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)];
            calendarPicker.selectDate = [NSDate date]; //默认被选中时间
            calendarPicker.complete = ^(NSInteger day, NSInteger month, NSInteger year, NSDate *date){
                NSLog(@"%d-%d-%d", (int)year,(int)month,(int)day);
            };
            [self.view addSubview:calendarPicker];

The lunar calendar

Calendar lunar display forms

RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]init];
calendarPicker.isLunarCalendar = YES; //开启农历

The calendar dataSource

The days in the calendar display when binding event data

dataSource预览

RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]init];
calendarPicker.dataSource = self.dataSource;

self.dataSource is test data  for json file

[{"date":"2016-12-1","value":1},
{"date":"2016-12-3","value":1},
{"date":"2016-12-7","value":1},
{"date":"2016-12-19","value":1},
{"date":"2016-12-29","value":1}]

calendar Theme

Set the calendar theme colors

RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]init];
calendarPicker.thisTheme =[UIColor blackColor]; //设置主题颜色 缺省情况下随机显示

A clock dial effect

The effect of a similar watches and clocks, can drag pointer to set a time

 RClockPickerView *rClockPickerView = [[RClockPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)
                                                                            clockRadius:140
                                                                 clockCalibrationRadius:130];
            rClockPickerView.date = [NSDate date];
            rClockPickerView.complete = ^(NSInteger hours, NSInteger minutes, NSInteger noon,float clockDate){
                NSLog(@"%d-%d-%d   float clockDate:  -%f", (int)hours,(int)minutes,(int)noon,clockDate);

            };
            [self.view addSubview:rClockPickerView];

calendar + clock use

To choose the calendar (date) (month) (year) and the vehicle to choose the combination use of the clock

RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)];
            calendarPicker.selectDate = [NSDate date]; //默认被选中时间
            [self.view addSubview:calendarPicker];

            calendarPicker.complete = ^(NSInteger day, NSInteger month, NSInteger year, NSDate *date){
                NSLog(@"%d-%d-%d", (int)year,(int)month,(int)day);

                RClockPickerView *rClockPickerView = [[RClockPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)
                                                                                clockRadius:140
                                                                     clockCalibrationRadius:130];
                rClockPickerView.date = [NSDate date];
                rClockPickerView.complete = ^(NSInteger hours, NSInteger minutes, NSInteger noon,float clockDate){
                    NSLog(@"%d-%d-%d", (int)hours,(int)minutes,(int)noon);

                    NSDate *selectDate = [DateHelper dateInDate:date Hours:hours minutes:minutes];

                    NSLog(@"selectDate: %@",selectDate);

                };
                [self.view addSubview:rClockPickerView];
            };

pop-up window Gestures conflict bug

In the current UIView sliding gesture of conflicts between the pop-up window will open bugs can be directly in the new UIViewController

            UIViewController *viewController = [[UIViewController alloc]init];
            
            RCalendarPickerView *calendarPicker = [[RCalendarPickerView alloc]initWithFrame:CGRectMake(0, 0, MainScreenWidth, MainScreenHeight)];
            calendarPicker.selectDate = [NSDate date]; //默认被选中时间
            [viewController.view addSubview:calendarPicker];
            calendarPicker.complete = ^(NSInteger day, NSInteger month, NSInteger year, NSDate *date){
                NSLog(@"%d-%d-%d", (int)year,(int)month,(int)day);
                  [self.navigationController popViewControllerAnimated:YES];
            };
            [self.navigationController pushViewController:viewController animated:YES];

TODO

  • [x] 增加选择年月的切换形式
  • [x] 定义日期的可选择范围
  • [x] Tests

You may encounter problems

NSDate 8小时问题-没你想的那么简单!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].