https://kotlinlang.org logo
#compose
Title
# compose
c

Christian Meese

06/21/2022, 1:24 PM
We have some problems with the statusbarpadding appearing to be 0 only on some devices… so far only observed on Android 10 (Pixel XL Emulator and Xiaomi real device) but not on higher APIs … has anybody come across this / is this a known issue?
👀 2
a

Alex Vanyo

06/21/2022, 6:28 PM
Can you report this as a bug, preferably with a sample and the emulator setup you’re using to reproduce? Feel free to link here when created! https://issuetracker.google.com/issues/new?component=612128 I’ve seen some similar looking issues in this area, and there’s also been a few changes in Compose itself that might impact what you’re seeing.
c

Christian Meese

06/21/2022, 6:37 PM
I’ll try to make a sample 👍
a

Alex

06/22/2022, 7:41 AM
@Simon Hardt ⬆️
👍 1
It seems to work correctly when using the paddings inside of
Copy code
setContent { ... }
in an
Activity
but breaks when using a
ComposeView
inside of a
Fragment
to host the compose content
c

Christian Meese

06/23/2022, 12:22 PM
@Alex Vanyo https://issuetracker.google.com/236862874 Inconsistent fitsSystemWindows Behaviour across API Levels / statusBarsPadding not working under all circumstances / https://github.com/meesec/TestApplication
a

Alex Vanyo

06/23/2022, 4:17 PM
Thanks for the issue! There’s not really anything Compose can do here, I’ve more detailed explanation in the issue, as you’ve discovered into how funky insets can be with the
fitsSystemWindows
tag.
@Alex Fragments add a whole extra layer of fun, which might be different than the above issue. Is there a sample/issue that you’ve reported for that?
c

Christian Meese

06/24/2022, 6:58 AM
@Alex Vanyo thanks for the detailed explanation 👍 @Alex is on my team, he was also speculating on a possible root cause before we extracted the sample 👍
a

Alex Vanyo

06/24/2022, 4:32 PM
Phew, good to hear, and hope that helps! Every time I hear about an insets issue I have the fear that there’s some new edge case that isn’t properly handled or mitigated 😅
35 Views