IntelliJ IDEA
 
Get IntelliJ IDEA
You are viewing the documentation for an earlier version of IntelliJ IDEA.

Wrapping/Unwrapping Components

Last modified: 10 August 2022

The Surround With feature is available in the GUI Designer, as well is in the editor. In the GUI Designer, you can wrap a container of your choice around one or more components, and remove wrapping.

When reasonable, IntelliJ IDEA smartly suggests to wrap a component into a container. This is done with the help of intention action. For example, IntelliJ IDEA suggests to wrap a JList into a JScrollPane:

img