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

Brian Donovan

12/29/2021, 8:06 PM
Hi all, how do I move the text “Blog” to the middle of this white box?
k

Kirill Grouchnikov

12/29/2021, 8:13 PM
Copy code
horizontalArrangement = Arrangement.Center
b

Brian Donovan

12/29/2021, 8:14 PM
inside the Row?
I tried that before and now, didn’t work
trying to get it like this
with the rounded corners
l

Lokesh

12/29/2021, 8:20 PM
Instead of Row, can you can use Box and set
contentAlignment
as
Center
? For Row, you probably need both
horizontalArrangement
and
verticalAlignment
to be centered.
k

Kirill Grouchnikov

12/29/2021, 8:21 PM
That's the bottom padding on your row. Make top and bottom paddings use the same value, let's say 36.dp.
b

Brian Donovan

12/29/2021, 9:11 PM
thanks guys, it worked