All Projects → wenzhihao123 → Android Calendarview Master

wenzhihao123 / Android Calendarview Master

Android开发实现自定义日历、日期选择控件

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Android Calendarview Master

Calendarview2
Calendar view for Android. Pretty.
Stars: ✭ 72 (-17.24%)
Mutual labels:  calendar
Calendarsyncplus
This utility synchronizes Calendar entries between different calendar providers (Apps like Outlook,Services EWS/Google/Live).
Stars: ✭ 80 (-8.05%)
Mutual labels:  calendar
Tui.calendar
🍞📅A JavaScript calendar that has everything you need.
Stars: ✭ 9,537 (+10862.07%)
Mutual labels:  calendar
Calendar
Android日历 仿小米 华为 滴答清单 365日历(农历),周视图 月视图 平滑滚动 节假日 五六行周切换 week or month calendar
Stars: ✭ 1,183 (+1259.77%)
Mutual labels:  calendar
Dadadash
Office suite with file browser, document editor, spreadsheet editor, calendar and data tables with CRUDX API's ready to deploy
Stars: ✭ 78 (-10.34%)
Mutual labels:  calendar
React Datetimerange Picker
A datetime range picker for your React app.
Stars: ✭ 82 (-5.75%)
Mutual labels:  calendar
Dategrid
A customizable swiftui calendar
Stars: ✭ 71 (-18.39%)
Mutual labels:  calendar
Core Components
Accessible and lightweight Javascript components
Stars: ✭ 85 (-2.3%)
Mutual labels:  calendar
Vue Draggablecal
Not your ordinary datepicker. A Vuejs draggable date selector with a fresh responsive design, mobile ready and 0 dependencies, 17kb gzipped
Stars: ✭ 79 (-9.2%)
Mutual labels:  calendar
Tech Calendar
Calendar of technology and development events
Stars: ✭ 82 (-5.75%)
Mutual labels:  calendar
Simple calendar
A wonderfully simple calendar gem for Rails
Stars: ✭ 1,187 (+1264.37%)
Mutual labels:  calendar
Kirby Calendar Plugin
A plugin for the Kirby CMS to easily implement an event calendar.
Stars: ✭ 76 (-12.64%)
Mutual labels:  calendar
Jalali.py
Persian and Gregorian Date Converter for Python 2 and Python 3
Stars: ✭ 82 (-5.75%)
Mutual labels:  calendar
Church Calendar Api
API providing Roman Catholic church calendar data for your apps
Stars: ✭ 72 (-17.24%)
Mutual labels:  calendar
Jkcalendar
Calendar library for iOS
Stars: ✭ 83 (-4.6%)
Mutual labels:  calendar
Calendarview
Calendar View Library
Stars: ✭ 71 (-18.39%)
Mutual labels:  calendar
Kotlin Agendacalendarview
Android calendar library provides easy to use widget with events
Stars: ✭ 81 (-6.9%)
Mutual labels:  calendar
Persiandatepicker
An Android DatePicker for Persian Calendar
Stars: ✭ 86 (-1.15%)
Mutual labels:  calendar
React Native Persian Calendar Picker
Persian Calendar Picker Component for React Native
Stars: ✭ 83 (-4.6%)
Mutual labels:  calendar
Recyclercalendarandroid
A simple DIY library to generate your own custom Calendar View using RecyclerView, written in Kotlin
Stars: ✭ 83 (-4.6%)
Mutual labels:  calendar

Android-CalendarView-master

Android开发实现自定义日历、日期选择控件 最近项目需要日历效果,考虑用第三方的反而不太适合设计需求,修改复杂,与其这样不入自己重新写一个干净的控件。虽不是什么牛逼控件,但是也需要我们能按照设计自己写出来。在此记录一下实现思路。

效果图:

切换周

切换月份

实现思路

  • 头部是一个自定义组合控件;
  • 显示一周的日期部分用GridView 更加方便更新;
  • 切换月的部分是一个自定义PopupWindow;
  • GridView选中效果;
  • GridView根据手势GestureDetector监听左右滑动;
  • 核心其实还是Calendar类,根据这个类我们可以获取制定日期一周的日期集合、可以获取制定日期一月的日期集合等等;
  • 根据阳历日期获取阴历日期

使用

// xml布局引用
<com.wzh.calendar.view.DataView
        android:id="@+id/week"
        android:layout_width="match_parent"
        android:background="@color/color_ffffff"
        android:layout_height="wrap_content">
</com.wzh.calendar.view.DataView>

// 代码中,自定义回调监听选中的日期
dataView = (DataView) findViewById(R.id.week);
dataView.setOnSelectListener(new DataView.OnSelectListener() {
            @Override
            public void onSelected(DateEntity date) {
                info.setText("日期:"+ date.date+"\n"+
                             "周几:"+ date.weekName+"\n"+
                             "今日:"+ date.isToday+"\n"+
                             "时间戳:"+ date.million+"\n");
                Log.e("wenzhiao--------------",date.toString());
            }
 });
//需要传递此种格式的日期,不传默认是获取今日的日期
dataView.getData("2017-04-19");

博客详解地址

邮箱:[email protected]

QQ:821027320

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].