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

Support multiline squiggly #2636

Merged
merged 1 commit into from
Mar 26, 2024

Conversation

EpicDima
Copy link
Contributor

The problem is that ReplacementSpan does not support multiple lines, so the line cannot be wrapped by default. It is impossible to replace Span with another type, because we are drawing our own Path on Canvas.
The idea of the solution from the article https://medium.com/androiddevelopers/drawing-a-rounded-corner-background-on-text-5a610a95af5 and, accordingly, the code from https://github.com/googlearchive/android-text/tree/master/RoundedBackground-Kotlin.

I changed TextView to LeakCanaryTextView only in places where the text can now contain SquigglySpan.

Before:
After:

@pyricau pyricau merged commit cd462bc into square:main Mar 26, 2024
9 checks passed
@pyricau
Copy link
Member

pyricau commented Mar 26, 2024

wow, thank you!

@pyricau pyricau added this to the 3.0 milestone Mar 26, 2024
@EpicDima EpicDima deleted the epicdima/support_squiggly_multiline branch March 31, 2024 16:09
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