🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #12130

JTabbedPane freaky Bug???

#12130
From: Jonathan
Date: Tue, 16 Feb 1999 00:00
57 lines
2254 bytes
Is it just me, or is the JTabbedPane right out there?

Creating a real simple d&d JTabbed pane with one button & 1 panel, all is
OK, and it runs fine. (Or is subclassed OK).

When I switch back to JBuilder, I can see the source pane fine.
When I switch to Design mode- ka-boooom.

The Class (window?) displays itself in a "phantom" Appletviewer- which is
not available on the windows task bar- and the design panel is empty. (You
can sort of select "invisible" objects in the design window though).

Is this a known bug? Have I selected some weird "floating in the ether"
option on the JBuilder parameters?

Cheers, Jon.

(PS- minimum code required to cause the above pasted below).
package practice;

import java.awt.*;
import com.sun.java.swing.*;
import java.awt.event.*;

public class SwingTabbedPages extends JFrame {
  JTabbedPane jTabbedPane1 = new JTabbedPane();
  JButton exitBut = new JButton();


  public SwingTabbedPages() {
    try  {
      jbInit();
    }
    catch (Exception e) {
      e.printStackTrace();
    }
  }

  private void jbInit() throws Exception {
    exitBut.setText("Exit");
    exitBut.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(ActionEvent e) {
        exitBut_actionPerformed(e);
      }
    });
    this.getContentPane().add(jTabbedPane1, BorderLayout.CENTER);
    jTabbedPane1.addTab("jButton1", exitBut);
    this.setSize(400,400);
    this.setVisible(true);
    this.setSize(new Dimension(327, 388));
  }

  void exitBut_actionPerformed(ActionEvent e) {
    setVisible(false);
    dispose();
  }
}
Technical Details
Message-ID: <7ac0tk$6t1$1@news6.svr.pol.co.uk>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,fce05596df16908,start
X-Google-Attributes: gid111d45,public
From: "Jonathan" <j_ryan@jres.freeserve.co.uk>
Subject: JTabbedPane freaky Bug???
Date: 1999/02/16
Message-ID: <7ac0tk$6t1$1@news6.svr.pol.co.uk>
X-Deja-AN: 444951941
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
X-Complaints-To: abuse@theplanet.net
X-Trace: news6.svr.pol.co.uk 919176948 7073 62.136.63.228 (16 Feb 1999 14:55:48 GMT)
Organization: Customer of Planet Online
NNTP-Posting-Date: 16 Feb 1999 14:55:48 GMT
Newsgroups: borland.public.jbuilder.java.swing