compose-multiplatform
compose-multiplatform copied to clipboard
Preview tool. Resize of preview window doesn't force recomposition
0.5.0 - build 270.
@Preview //annotation that says that this function could be used
@Composable //Composable function
fun testUI() { //No parameters! Preview tool has no idea what to pass!
Box(Modifier.background(Color.LightGray).fillMaxSize()) {
Text("Hello World!!", Modifier.align(Alignment.Center).padding(10.dp))
}
}
Scenario:
- Run Preview
- Make preview window floating
- Resize preview window it. Issue 1->text will stay on the same position
- Modify text (e.g. remove one !) and rerun preview. Text and box again will keep their positions/sizes.
Making preview window pinned and floating again helps.
Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.