clip圓角

Clip圓角的作用區域

1
.clip(RoundedCornerShape(topStart = 16.dp, topEnd = 16.dp))//頂端二邊有圓角

要放在

.fillMaxSize()與.background()之前
1
2
3
4
5
6
7
Column(modifier = Modifier
    .clip(RoundedCornerShape(topStart = 16.dp, topEnd = 16.dp))//頂端二邊有圓角
    .fillMaxSize() //填滿
    .background(Color.White)//白色
){
Text(text = "明細")
}

img

results matching ""

    No results matching ""