🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Inital display of a JTabbed Pane

#9319
From: Douglas Moffitt
Date: Thu, 27 Apr 2000 00:00
28 lines
2134 bytes
I am new at both Java and Swing but believe that I understand what I'm
doing, so here goes:
I have an applet, with JTabbedPane on the Component Pane.  Each tab has a
JPanel with a VerticalFlow Layout.   The objects in the Layout are JPanels
with Border Layouts.   This goes at least two layers deeper.

I have been careful to build the layers from lower levels toward higher.  I
mean, create a panel, add its layout manager, add its widgets, then add the
assembly to the next layer up, after creating its parent and the layout
manager for that.  [The notion of up and down seems to work badly here]

I have set the JTabbedPane to opaque=false but have not messed with any of
the other layers.

When the applet deploys, all of the widgets in all of the panels are layered
in a mess on the screen.  Further, they are active, in the sense that
clicking the fragment of a button visible on the screen performs its action.

If I cycle through the tabs once, the screen clears and is subsequently
perfect.  I have tried to do this programmatically in the applet's start()
function with no success; that is, the cycling occurs, but the screen
display is not cleaned up.

I believe the fact that the display corrects as the tabs are cycled
indicates that the underlying model is correct.  Do I need to pack,
validate, opacify, or cast incantations before the intial display?

Suggestions?
Technical Details
Message-ID: <V1_N4.648$x4.22857@newsread1.prod.itd.earthlink.net>
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,322fa9899579f742,start
X-Google-Attributes: gid111d45,public
From: "Douglas Moffitt" <dougmoffitt@earthlink.net>
Subject: Inital display of a JTabbed Pane 
Date: 2000/04/27
Message-ID: <V1_N4.648$x4.22857@newsread1.prod.itd.earthlink.net>
X-Deja-AN: 616407217
X-Priority: 3
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700
X-Complaints-To: abuse@earthlink.net
X-Trace: newsread1.prod.itd.earthlink.net 956853493 38.26.139.82 (Thu, 27 Apr 2000 09:38:13 PDT)
Organization: EarthLink Inc. -- http://www.EarthLink.net
X-MSMail-Priority: Normal
NNTP-Posting-Date: Thu, 27 Apr 2000 09:38:13 PDT
Newsgroups: borland.public.jbuilder.java.swing