The order of components in a container is the order in which components are added and the order in which they are selected when you press the Tab key.
If the layout manager for a container does not use constraints (properties that determine layout), the order of components determines how the components are arranged. Such layout managers include FlowLayout, BoxLayout, and GridLayout. With these layout managers, you can change the order of components by dragging them in the Form Editor or by reordering them in the Inspector window.
With layout managers that use constraints (BorderLayout, GridBagLayout, CardLayout, AbsoluteLayout, and Null Layout), the order of components in the container does not determine the order in which the components appear. For these containers, you can only rearrange the component order in the Inspector window.
To reorder the components in the Inspector window:
![]() |
Although GridBagLayout uses constraints to determine how components are arranged, component order determines layout when the Grid X and Grid Y constraints are not used. |
See Also | |
---|---|
Inspector Window
Moving or Copying a Component Setting Layout Properties GridBagLayout |