That red block is my `BasicTextField()` Is it poss...
# compose
i
That red block is my
BasicTextField()
Is it possible to center black indicator?
Copy code
BasicTextField(
    modifier = Modifier
        .fillMaxWidth()
        .align(Alignment.Center),
    value = value,
    onValueChange = { value = it },
    singleLine = true
)
n
I don't think there is anyway to do that, you can copy and modify the code of the BasicTextField/CoreTextField to do it, but know that you are probably in for a long adventure. And that you should probably backports any new changes to the class
❤️ 1
i
I"ve created my own style with
textAlign
and it works as expected
Copy code
val style = TextStyle(
    color = MaterialTheme.colors.primary,
    fontSize = 16.sp,
    fontWeight = FontWeight.SemiBold,
    textDecoration = TextDecoration.None,
    textAlign = TextAlign.Center
)
👍 1