The API is going to change in versions 2.0-alpha+ until there will be stable 2.0 version.
For version 1.+ please check the original repository.
This is improved Material CalendarView from Prolific Interactive. My version 2+ has some breaking changes to the core, so the API is not backward compatible with prolific version.
The artifact is available on jcenter.
- Add library as dependency in your module build.gradle file.
compile 'com.ptrstovka.calendarview2:calendarview2:[latest version]'
- You are done, now you can use
CalendarView2
in your code & layouts.
Example:
<com.ptrstovka.calendarview2.CalendarView2
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:mcv_weekDayTextAppearance="@style/CustomWeekTextAppearance"
app:mcv_selectionColor="#4DB9C8"
app:mcv_circlePadding="5dp"
app:mcv_showOtherDates="all"
/>
Make sure to check all the documentation available here.
Javadoc is available here.
More docs will be available on 2.0 release.
One of the aims of this library is to be customizable. The many options include:
- Define the view's width and height in terms of tile size
- Single or Multiple date selection, or disabling selection entirely
- Showing dates from other months or those out of range
- Setting the first day of the week
- Show only a range of dates
- Customize the top bar
- Custom labels for the header, weekdays, or individual days
All of this and more can be done via the decorator api. Please check out the decorator documentation.
If you provide custom drawables or colors, you'll want to make sure they respond to state. Check out the documentation for custom states.
Would you like to contribute? Fork us and send a pull request! Be sure to checkout our issues first.
Material Calendar View is Copyright (c) 2017 Prolific Interactive. It may be redistributed under the terms specified in the LICENSE file.
Version 1.+ is maintained and funded by Prolific Interactive. The names and logos are trademarks of Prolific Interactive.