Skip to content
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

Arrow definitions are now set with an enum. #3

Merged
merged 2 commits into from
Apr 5, 2012
Merged

Arrow definitions are now set with an enum. #3

merged 2 commits into from
Apr 5, 2012

Conversation

markrickert
Copy link
Contributor

Gives the user the ability to specify arrow position when initializing the view controller.

Plus the ability to set the position when initializing the object using the enum.
ocrickard added a commit that referenced this pull request Apr 5, 2012
Arrow definitions are now set with an enum.
@ocrickard ocrickard merged commit 9b0ea72 into ocrickard:master Apr 5, 2012
@ocrickard
Copy link
Owner

This is great, I'll see if I can update the positioning so it'll put the box at the correct location based on the arrow position.

@markrickert
Copy link
Contributor Author

I think what would be MORE fantastic would be if it could auto-calculate its position based on the anchor point and the "allowed directions" like a UIPopoverController.

That way, it could have the arrow below as well as above and on the sides.

Unfortunately, we can't subclass UIPopoverController if we want to retain iPhone compatibility (which I do)

@ocrickard
Copy link
Owner

Yeah... It wouldn't be TOO hard, but would take some time messing with the path drawing to relocate the arrow on different sides. I don't think I have time for that today. Maybe tomorrow...

@markrickert
Copy link
Contributor Author

Ahh - yeah, i see now that you're creating the arrow as a part of the outline of the actual object.

https://github.com/ocrickard/OCCalendar/blob/master/OCCalendarView/OCCalendarView.m#L283

I thought maybe they were two separate objects - a rounded rect and a triangle.

@ocrickard
Copy link
Owner

I thought of doing that, but all of the shadows and strokes didn't match perfectly. Instead, I just specify it as part of the path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants