With JDeveloper tools, you can visually design and program Java classes to produce new compound or complex components.
JDeveloper UI design tools include the following:
A Java Visual Editor in which you create and arrange panels and other UI components inside a frame or other UI container. You access the Java Visual Editor by right clicking the file in the Navigator and choosing Open. Click the Design tab to work the visual editor.
A Menu Editor in which you create and edit a menu bar, menus, menu items, and popup menu components. You access the Menu Editor when you have the Java Visual Editor open by dropping a menu component into your UI container from the Component Palette. You can also edit an existing menu component by clicking the menu component in the Structure window.
A Component Palette containing visual and nonvisual components. You
display the Component Palette for components that you select in the
Java Visual Editor. To display the Component Palette for an open
file, choose View
Component Palette.
A Structure window that displays a hierarchical view of all the
components in your source file, and their relationships. You access
the Structure window below the Navigator window or if docked, by
choosing View
Structure.
Requirements for Visually Designing a Class in JDeveloper
If you want to use the UI design tools on a file, it must meet the following requirements:
It must be a Java file.
It must be free from syntax errors.
It must contain a public class (the file name must be the same as the name of the public class).
All UI controls are declared as class members or as local
variables within jbInit()
.
All UI property settings done in jbInit()
. This is
necessary in order for the JDeveloper Java Visual Editor and
Property Inspector to reflect the settings.
All property settings set as expressions involve only member UI controls or static values.
It must have a default constructor.
Any file that meets the above requirements can be visually designed using the Java Visual Editor and the Property Inspector. You can also visually design a non-UI class.
Note: These requirements are satisfied when you create your files with any of the JDeveloper dialogs.
When you first add a component to your design, the JDeveloper Java
Visual Editor ensures that your class has a default constructor, a
private jbInit()
method, and that this jbInit()
method is called correctly from the default constructor. If JDeveloper
does not find this code, it will add it. It will also add any imports
needed by the component.
When you open the file in the Java Visual Editor, JDeveloper updates the Structure window tree. For example, if your class has a frame and a menu, there will be subtrees for UI and Menu. If you drop any other JavaBeans components into the Structure window, an 'Others' folder appears so you can select and edit these components in the Property Inspector.
About Java Visual Editor Proxy Classes
Customizing the IDE
Customizing the Component Palette
Customizing the Code Editor Environment
Copyright © 1997, 2004, Oracle. All rights reserved.