小编Chu*_*bae的帖子

如何仅在jetpack compose中更改特定侧的边框宽度?

我正在尝试实现以下布局

在此输入图像描述

无法在jetpack compose中设置单独的边框宽度

这是我的代码

            Row(
                modifier = Modifier
                    .border(width = 1.dp, shape = RoundedCornerShape(4.dp), color = Purple3)
                    .padding(10.dp),
                verticalAlignment = Alignment.CenterVertically
            ) {
                Image(
                    painter = painterResource(id = R.drawable.info),
                    contentDescription = stringResource(id = R.string.long_press_an_item),
                )
                Text(
                    text = stringResource(id = R.string.long_press_an_item),
                    fontFamily = FontFamily(Font(R.font.inter_medium)),
                    fontSize = 12.sp,
                    color = Gray5,
                    modifier = Modifier.padding(horizontal = 10.dp)
                )
            }
Run Code Online (Sandbox Code Playgroud)

android kotlin android-jetpack-compose

3
推荐指数
1
解决办法
1551
查看次数

标签 统计

android ×1

android-jetpack-compose ×1

kotlin ×1