## Creating a Window Component

See Also

A window component creates a window (also known as 'view') for a module. The IDE provides the Window Component wizard to simplify the initial creation process.

To create a new window component:

1. Right-click a module project and choose New > Window Component.
2. In the Basic Settings page, you set the following:
   - Window Position. Specifies the location of the window component when open in the IDE. Choose one of the following:
     - `output.` The default position of the IDE's Output window.
     - `explorer.` The default position of the IDE's Projects window.
     - `editor.` The default position of the IDE's Source Editor.
     - `properties.` The default position of the IDE's Properties window. This is on the right side of the Source Editor.
     - `leftSlidingSide.` The window component will be available as a button on the left sidebar of the IDE.
     - `rightSlidingSide.` The window component will be available as a button on the right sidebar of the IDE.
     - `bottomSlidingSide.` The window component will be available as a button on the bottom bar of the IDE.

     For modules that belong to a module suite which includes the `ide7` cluster in the Module List, the following positions are also available:

     - `commonpalette.` The default position of the IDE's Palette for HTML/JSP code snippets.
     - `debugger.` The default position of the IDE's Debugger.
     - `navigator.` The default position of the IDE's Navigator.
   - Open on Application Start. Specifies whether the window component is open by default or not.
3. In the Name, Icon, and Location page, you have to set the following:
   - Class Name. Specifies the name of the new `Action` and `TopComponent` classes.
   - Icon. Specifies the icon that will accompany the window component. For example, you will see the icon in the label of the window component. (Optional)
   - Package. Specifies the name of the package where the class will be housed.
4. After completing the wizard, you can do one or more of the following:
   - Use the Form editor to design the window.
   - Place the window component in a different position. In the `layer.xml` file, tweak the Modes section.
   - Add your own code to `componentOpened()` and `componentClosed()` to specify what will happen when the window opens and closes.

See Also
  About NetBeans Platform and Module Development
  About the NetBeans Platform

Legal Notices