Is there a way to create/override the custom word wrap engine for Android TextView?
For example,
My name is Edwin (US:1113)
Should be displayed as
My name is Edwin
(US:1113)
Instead of
My name is Edwin (US:
1113)
Already tried changing all the possible value for the setting below but nothing good.
Android:maxLines
Android:setHorizontallyScrolling
Android:ellipsize
Android:singleLine
In my findings, word wrap in TextView does not include special characters such as :.
Updated 3.09AM 2/7/2018 UTC
As mentioned by @Umair, line breaking with "\n" is not possible because I don't know the length of the text before the colon :. This will line break the sentence too early before it reached the maximum width of the TextView.