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

Remove empty ShadowTextPaint #7250

Merged
merged 1 commit into from Apr 17, 2022

Conversation

utzcoz
Copy link
Member

@utzcoz utzcoz commented Apr 16, 2022

The implementation of ShadowPaint#measureText doesn't process text width correctly, and it can't be moved to ctesque. And
ShadowPaintTest#measureTextActuallyMeasuresLength tests does the same thing that ShadowTextPaintTest does, so it's safe to remove ShadowTextPaintTest.

The implementation of ShadowPaint#measureText doesn't process text width
correctly, and it can't be moved to ctesque. And
ShadowPaintTest#measureTextActuallyMeasuresLength tests does the same thing
that ShadowTextPaintTest does, so it's safe to remove
ShadowTextPaintTest.
@utzcoz
Copy link
Member Author

utzcoz commented Apr 16, 2022

@hoisie Looks like ShadowPaint#measureText doesn't behavior as AOSP: https://cs.android.com/android/platform/superproject/+/master:frameworks/base/graphics/java/android/graphics/Paint.java;l=2245-2266?q=Paint.java&ss=android. The ShadowPaint#measureText only care about text length, but doesn't care about text size.

@utzcoz
Copy link
Member Author

utzcoz commented Apr 16, 2022

And self-hosted runner broken again.

@utzcoz utzcoz requested a review from hoisie April 17, 2022 03:37
Copy link
Contributor

@hoisie hoisie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Weird how it was just an empty shadow.

@utzcoz utzcoz merged commit c808c0d into robolectric:master Apr 17, 2022
@utzcoz utzcoz deleted the remove-ShadowTextPaint branch April 17, 2022 06:25
@utzcoz
Copy link
Member Author

utzcoz commented Apr 17, 2022

Thanks! Weird how it was just an empty shadow.

The commit 4dda01d added ShadowTextPaint with measureText implementation. But I don't find relate commit to remove this implementation with git blame $(find . -iname ShadowTextPaint.java) and git log -- $(ind . -iname ShadowTextPaint.java). The ShadowPaint#measureText implementation has the same function as old ShadowTextPaint one. Maybe one folk found this behavior, and remove it from ShadowTextPaint or move it to ShadowPaint.

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.

None yet

2 participants