Lilly
10/03/2021, 11:14 PMBox
with a vector image on various devices. I would like to scale the image to FillWidth
but this has the side effect that the height is different on various devices and so the bottom padding too. How can I arrange the text in the center of the gray area so it has the same position on all devices? What I also don't understand is why the smaller preview looks different on real device, although the given specs and the specs of device are the same (device = "spec:Normal;480;800;px;320dpi").Jan Bína
10/04/2021, 1:38 PMModifier.align()
on your Text composable with something like BiasAlignment(horizontalBias = 0F, verticalBias = 0.5F)
, where you tweak the 0.5F
value to fit your image.Lilly
10/05/2021, 2:45 PM