Glow-Inc / GLCalendarView

A fully customizable calendar view acting as a date range picker
MIT License
855 stars 106 forks source link

"drawTodayCircle:" actually draws an oval in GLCalendarDayCellBackgroundCover.m #9

Closed jhergott closed 8 years ago

jhergott commented 8 years ago

I noticed "drawTodayCircle:" actually draws an oval in GLCalendarDayCellBackgroundCover.m. Is this a bug or the desired implementation?

ltebean commented 8 years ago

Usually you should adjust row height according to the screen width so that the layout looks well, like:

    NSInteger screenWidth = [UIScreen mainScreen].bounds.size.width;
    CGFloat paddingAll = screenWidth % 7 + 7;
    [GLCalendarView appearance].rowHeight = (screenWidth - paddingAll) / 7 + 3;
    [GLCalendarView appearance].padding = paddingAll / 2;