dorche
11/22/2023, 6:43 PMdorche
11/22/2023, 6:43 PM@Preview(widthDp = 225)
@Composable
fun TextPadding() = PreviewSurface {
Column(
horizontalAlignment = Alignment.CenterHorizontally,
verticalArrangement = Arrangement.Center
) {
Text("Column Centered")
Row(
verticalAlignment = Alignment.CenterVertically,
horizontalArrangement = Arrangement.Center
) {
IconButton(onClick = { }) {
Icon(Icons.Default.AccountBox, contentDescription = "")
}
Text(
text = "Your new Account Value",
textAlign = TextAlign.Center,
fontSize = 24.sp,
modifier = Modifier.weight(1f, false)
)
IconButton(onClick = { }) {
Icon(Icons.Default.AccountBox, contentDescription = "")
}
}
}
}
dorche
11/22/2023, 6:44 PMdorche
11/22/2023, 6:45 PMdorche
11/22/2023, 6:46 PMIntrinsicSize.Min
to the Text doesn't solve it either, as that forces it to go on new line for each word:dorche
11/22/2023, 6:47 PMdorche
11/22/2023, 7:52 PMZach Klippenstein (he/him) [MOD]
11/22/2023, 8:41 PMdorche
11/22/2023, 8:43 PMdorche
11/22/2023, 8:46 PM