PDA

View Full Version : adding a panel to hide the content pane



hbarakat
05-02-2003, 08:24 AM
For some reason, my post disappeared. Here it is again.

The following code adds a panel to a custom wizard panel content pane. But, the panel doesn't completely hide the pane underneath, and in my case, the color of the panel is a different color from the pane. I am not sure how to get rid of the border that is appearing when I try this. (I suppose I could change the color of the content pane to match my panel, but I really want to understand why the pane is imposing a border at all).


public class IntroPage extends DefaultSwingWizardPanelImpl {

public void initialize( WizardBeanEvent evt ) {
super.initialize(evt);
getContentPane().setLayout(new ColumnLayout());
getContentPane().add(getMainPanel());
}

/**
* method getMainPanel() creates and populates a JPanel
*/
private JPanel getMainPanel() {
// etc ...
}
}