https://kotlinlang.org logo
Title
z

Zoltan Demant

12/16/2021, 7:45 AM
Why would a
Text
composable misalign its text like this in some situations (seemingly, only on a Huawei P30 Pro)?
Ive already published a bug report (with the code), but fail to see how it can get fixed considering how rare it is. So I thought Id ask here!
c

Colton Idle

12/16/2021, 7:53 AM
What text are you talking about specifically. "Group 1"?
z

Zoltan Demant

12/16/2021, 7:55 AM
@Colton Idle The duration near the top, 1:13:04 and 08:58!
c

Colton Idle

12/16/2021, 8:08 AM
Whoops. Didn't even see that. šŸ‘
😁 1
t

tad

12/17/2021, 2:59 AM
Try wrapping the text in a SelectionContainer to see if it has some leading whitespace
z

Zoltan Demant

12/17/2021, 9:21 AM
@tad Thanks for the tip, Im unable to recreate the issue on any of my devices but Ill potentially push an update just to test it. Im using
DateUtils.formatElapsedTime
and I cant find any issues about additional whitespace being included (in the english locale) šŸ˜ž
c

Colton Idle

12/17/2021, 3:11 PM
What app is this. I have like two huaweis I could try lol
z

Zoltan Demant

12/17/2021, 4:06 PM
@Colton Idle Oh, I appreciate that! Which devices do you have? The release is available in the beta channel currently. You can open the screen above by tapping start workout and then the check-mark in the top bar!
c

Colton Idle

12/17/2021, 5:26 PM
I will try it when I'm back at my desk. I gotta make sure I can find the huawei devices (i definitely have them... somewhere)
z

Zoltan Demant

12/17/2021, 6:27 PM
@Colton Idle Great! No stress šŸ™‚
t

tad

12/17/2021, 9:03 PM
Wouldn't be the first time an OEM broke the framework.
Oh, your bug report says it didn't happen in earlier versions.
Another idea; is the user in a RTL locale?
z

Zoltan Demant

12/18/2021, 7:15 AM
Hes using LTR, English locale. I even rewrote the formatting logic for durations, just to be sure - no difference.
Since it worked in earlier compose releases, it has to be compose related - but I have no idea what could be causing it 🄲
@Colton Idle Just curious, did you embark on the quest to find two lucky Huawei phones? šŸŽ…šŸ½
c

Colton Idle

12/22/2021, 1:18 PM
Not yet. 😭 I'll look again today.
šŸ‘šŸ½ 1
@Zoltan Demant found it!
i will sign up for the beta later today and test it for you
z

Zoltan Demant

12/31/2021, 2:06 PM
@Colton Idle Yay, awesome! I really appreciate it, this is one of those scenarios where I wish I had access to literary every Android phone out there.
c

Colton Idle

12/31/2021, 3:27 PM
Seems fine to me?
z

Zoltan Demant

01/02/2022, 7:53 AM
@Colton Idle Yup, thats the way it should look! Thank you for checking, makes the other issue seem even more strange to me. Which phone was this on?
c

Colton Idle

01/02/2022, 3:34 PM
p30 lite
šŸ‘šŸ½ 1
z

Zoltan Demant

01/02/2022, 3:52 PM
@Colton Idle Gotcha, thanks again for testing it! Hopefully a future compose release sorts the underlying issue out, whatever it is.. šŸ™‚
c

Colton Idle

01/02/2022, 6:21 PM
yeah. very odd indeed.