@@ -24,6 +24,7 @@ import androidx.compose.runtime.saveable.Saver
2424import androidx.compose.runtime.saveable.listSaver
2525import androidx.compose.runtime.saveable.rememberSaveable
2626import androidx.compose.runtime.setValue
27+ import androidx.compose.ui.ExperimentalComposeUiApi
2728import androidx.compose.ui.awt.toAwtRectangleRounded
2829import androidx.compose.ui.unit.Dp
2930import androidx.compose.ui.unit.isSpecified
@@ -75,6 +76,7 @@ fun rememberWindowStateWithBounds(
7576 * @param initialBoundsProvider Provides the initial bounds of the window.
7677 * @param initiallyMinimized Whether the window is initially minimized.
7778 */
79+ @ExperimentalComposeUiApi
7880@Composable
7981fun rememberWindowState (
8082 initialScreenProvider : WindowScreenProvider = WindowScreenProvider .Default ,
@@ -105,6 +107,7 @@ fun rememberWindowState(
105107 * [DpOffset.isSpecified].
106108 * @param initiallyMinimized Whether the window is initially minimized.
107109 */
110+ @ExperimentalComposeUiApi
108111fun WindowStateWithBounds (
109112 initialPosition : DpOffset ? = null,
110113 initialSize : DpSize ? = null,
@@ -128,6 +131,7 @@ fun WindowStateWithBounds(
128131 * @param initialBoundsProvider Provides the initial bounds of the window.
129132 * @param initiallyMinimized Whether the window is initially minimized.
130133 */
134+ @ExperimentalComposeUiApi
131135fun WindowState (
132136 initialScreenProvider : WindowScreenProvider = WindowScreenProvider .Default ,
133137 initialPlacement : WindowPlacement = WindowPlacement .Floating ,
@@ -151,6 +155,7 @@ fun WindowState(
151155 * @param bounds the initial value for [WindowState._bounds]
152156 */
153157@Stable
158+ @ExperimentalComposeUiApi
154159class WindowState private constructor(
155160 isInitialized : Boolean ,
156161 screenId : String? ,
@@ -331,6 +336,7 @@ class WindowState private constructor(
331336 )
332337 }
333338
339+ @ExperimentalComposeUiApi
334340 companion object {
335341 /* *
336342 * A [Saver] implementation for [WindowState].
@@ -371,6 +377,7 @@ class WindowState private constructor(
371377 * Returns the bounds of the window, as an AWT [Rectangle]; throws [IllegalStateException] if the
372378 * window is not yet [isInitialized].
373379 */
380+ @ExperimentalComposeUiApi
374381val WindowState .awtBounds: Rectangle
375382 get() = bounds.toAwtRectangleRounded()
376383
0 commit comments