awaitWindowSystemIdle

suspend fun awaitWindowSystemIdle(quietPeriod: Duration = 250.milliseconds, timeout: Duration = 10.seconds): SwingWindowInteraction<T>

Suspends until the window system has sent this window no move, resize or paint event for quietPeriod, and returns this interaction. Use it before recording what a window paints.

To read or change geometry, wait for the expected value with org.jetbrains.compose.swing.test.ComposeSwingTest.waitUntil instead.

Both durations use wall-clock time. The composition clock does not advance during the wait.

Parameters

quietPeriod

how long the window must go without a move, resize or paint event.

timeout

the wall-clock deadline after which a window that keeps receiving them fails the wait.

Throws

if the query does not match exactly one realized window.