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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correcting location when tapping on the label #39

Merged
merged 2 commits into from Jan 5, 2016

Conversation

polqf
Copy link
Contributor

@polqf polqf commented Jan 4, 2016

馃帺 What? Why?

Since #35 , the location of the touch was not precise if the height of the label was bigger than the height of the text.

Thanks @dimanicholson for your patience and your videos explaining the issue ( #38 )

The reason why it is happening is that boundingRectForGlyphRange is returning a CGRect on the origin, so it is only working now for labels that have the same size as the bounding rect of the text.

This PR introduces a correction to the tap location in order to avoid this problem on that situation.

馃懟 GIF

Closes #38

@polqf polqf added the bug label Jan 4, 2016
@polqf polqf self-assigned this Jan 4, 2016
@polqf
Copy link
Contributor Author

polqf commented Jan 5, 2016

Confirmed by @dimanicholson that it is fixing the issue

polqf added a commit that referenced this pull request Jan 5, 2016
Correcting location when tapping on the label
@polqf polqf merged commit 29cc0c2 into master Jan 5, 2016
@polqf polqf deleted the feature/correctTapLocation branch January 5, 2016 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant