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

Fixed truncation error for ASTextNode2. #1295

Closed
wants to merge 4 commits into from

Conversation

wanhmr
Copy link

@wanhmr wanhmr commented Dec 20, 2018

I got a truncation error for Kittens sample.

An error occurred when I set the NSLineBreakMode to NSLineBreakByTruncatingMiddle.

simulator screen shot - iphone xr - 2018-12-20 at 19 15 08

@CLAassistant
Copy link

CLAassistant commented Dec 20, 2018

CLA assistant check
All committers have signed the CLA.

@wanhmr wanhmr force-pushed the tpphha-fix-truncation branch from fd70d2e to 4b16e8f Compare December 20, 2018 14:06
@wiseoldduck
Copy link
Member

All bugfixes should be demonstrated with the kittens app 😸

Haha I discovered this lineBreakMode not working correctly basically just now adding some snapshot tests.

I think the bug can be fixed with a smaller change than this, but maybe this PR makes it more readable? I will review it more carefully tomorrow. 👍

@wanhmr
Copy link
Author

wanhmr commented Dec 21, 2018

@wiseoldduck I've added some screenshots of the kittens app and I think my current implementation is much cleaner.

I have added detailed comments to the code for this PR .

Thank you for review.

head

truncation-head

middle

truncation-middle

end

truncation-tail

@Adlai-Holler
Copy link
Member

@wanhmr Thanks for the diff and the detailed screenshots. #1297 got in there first and should fix this. Let me know if not!

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.

4 participants