To make a window that is dependent on another window � disappearing when the other window is iconified, for example � use a dialog instead of frame. Applications with a GUI usually include at least one frame.
JFrame class, is a window that has decorations such as a border, a title, and supports button components that close or iconify the window. Since the border area is included in the overall size of the frame, the border effectively obscures a portion of the frame, constraining the area available for rendering and/or displaying subcomponents to the rectangle which has an upper-left corner location of (insets.left, insets.top), and has a size of width - (insets.left + insets.right) by height - (insets.top + insets.bottom).Ī frame, implemented as an instance of the The dimensions of the border area may be obtained using the getInsets method.
The size of the frame includes any area designated for the border.
A Frame is a top-level window with a title and a border.