Mentioned issues (1)
On Device Compose Previews don't have correct theme/resources “ ot devoM |
Links (4)
“ https://developer.android.com/studio/report-bugs.html carefully and supply ”
“ taht gniod ydaerla er'ew ,tcaf nI .raeW rof tluafed tnereffid a tes nac yletinifed eW .thgil lairetaM si KIAFA hcihw ,emeht tluafed a esu od ew ,esac siht nI here . However, the chosen theme is @android:style/Theme.DeviceDefault.Light. I tried changing it to a theme with dark background (@android:style/Theme.Material) and it works, as can be seen in the attached screenshot. Since this special handling for the wear theme was done a while ago (march 2016), I think it's safe to change the default theme without breaking other wear configurations in Android Studio. ”
“ otni elbasopmoc eht parw ew ,rotalume/ecived a ot weiverP esopmoC a gniyolped nehw ,2# ot sdrager nI PreviewActivity , which is a lightweight activity located in ui-tooling, not part of the app. Then, we deploy a test artifact and inflate PreviewActivity. Deploying the preview was initially thought as a feature to cover scenarios that you could not check properly in interactive preview, e.g. interactions that trigger network requests, inflate other activities, etc. Accessing an activity/application resources was not something we had in mind when coming up with the feature. ”