-
Notifications
You must be signed in to change notification settings - Fork 653
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added a method to customise the marker colours via the data source delegate and to detect long press in the calendar #192
base: master
Are you sure you want to change the base?
Conversation
You have to put this codeline in src/TapkuLibrary/TKCalendarMonthView.h otherwise it doesn't know the instance method for the selector TKCalendarMonthView.h
|
Can you add an Example how to use this? I get errors. |
Right you are, I forgot to commit that file On 10-Oct-2012, at 6:23 PM, Fokke Vermeulen [email protected] wrote:
|
I'm adding a bit more to customize the type of marker also, will upload a demo soon On 10-Oct-2012, at 7:14 PM, Fokke Vermeulen [email protected] wrote:
|
Hey thank you. I think i only need to know, what i have to put in the array. |
UIColor object On 15-Oct-2012, at 3:45 PM, Fokke Vermeulen [email protected] wrote:
|
Thank you. It works ;) |
…t's datasource delegate -(void)calendarMonthView:(TKCalendarMonthView *)monthView didLongPressDate:(NSDate *)date;
|
||
if(markColor) | ||
{ | ||
attrsDictionary = [NSDictionary dictionaryWithObjectsAndKeys:f2,NSFontAttributeName, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Attributes for NSAttributedString such as NSFontAttributeName are available only for iOS 6 or newer. If one needs to use NSAttributedString for iOS 5 or older, it must be done by using CoreText (kCTFontAttributeName and such).
Method is - (NSArray ) calendarMonthView:(TKCalendarMonthView)monthView colorsForMarksFromDate:(NSDate )startDate toDate:(NSDate)lastDate
-(void)calendarMonthView:(TKCalendarMonthView *)monthView didLongPressDate:(NSDate *)date;