Modifying Components in the Grid
This section explains how to:
To copy a component to another cell:
- Select the component.
- Choose GUI -> Copy Component.
- Click in the cell in which you want to paste a copy of the
component.
- Choose GUI -> Paste Component.
A shortcut to copying and pasting components is to select the
component then while holding the Control key down, click in the grid
cells where you want to place the component.
To delete a component:
- Select the component.
- Choose GUI -> Delete Component.
You can also choose GUI -> Cut Component to remove the
component and place it on the clipboard. Click on a cell
and choose GUI -> Paste Component to paste the component
into the selected cell.
To change a component's attributes:
- Open the attribute editor by
selecting a component in the gridbag and clicking on its button in the
main toolbar.
A shortcut method for opening the attribute editor is to
double-click while the cursor is positioned
in the area between the component and its cell border.
- Changes the values for the attributes you want to modify.
- Click OK to establish the changes.
Component attributes vary, depending on the function of the component.
Not all characteristics of a component can be modified. The attribute
editor displays only those aspects of a component that you can
change. Specialized attributes are explained with the description of
their associated components; for a list of the palette components, see
GUI Builder Palette. General attributes
that apply to most of the components are described in Attribute Editor.
For more details about component attributes, see the API documentation.
To customize a bean:
- Select a bean that you've placed in the gridbag.
- Open the attribute editor by clicking on its button in the main toolbar.
- Click the Customizer button to open the Customizer dialog box.
- Set the attributes you want to change (attributes displayed in the
dialog box are specific for the actual bean).
- Click OK to close the dialog box, then click OK in the attribute
editor to establish the changes.
You can modify a bean if the bean contains a customizer in its JAR
file. No action results if you click the Customizer button for a bean
without a customizer in its JAR file.
See also:
- Generating Java Source Code
- Adding a Menu Bar and Menus
- Adding Behavior to Components
- Adding Custom Components and Windows
- GUI Builder Palette
- Visual Java GUI Builder API Documentation
- Visual Java GUI Builder
Runtime Packages
- Class Hierarchy
- Index of
All Fields and Methods