setBounds

context(env: JniEnv)
fun Awt.setBounds(embeddedFrame: JAwtFrame, x: Int, y: Int, w: Int, h: Int)(source)

Moves and resizes the embedded frame. The new location of the top-left corner is specified by x and y parameters relative to the native parent component. The new size is specified by width and height.

The embedded frame should be created by createEmbeddedFrame method, or this function will not have any effect.

java.awt.Component.setLocation() and java.awt.Component.setBounds() for EmbeddedFrame really don't move it within the native parent. These methods always locate the embedded frame at (0, 0) for backward compatibility. To allow moving embedded frames this method was introduced, and it works just the same way as setLocation() and setBounds() for usual, non-embedded components.

Using usual get/setLocation() and get/setBounds() together with this new method is not recommended.

Since

9