🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: JMenuItem and Canvas

#1250
From: John McGrath [TeamB]
Date: Mon, 01 Mar 2004 05:37
18 lines
1404 bytes
On 2/28/2004 at 12:44:38 PM, J. Berg wrote:

> Why JMenuItem shows under Canvas?
> I'm using setJMenuBar method on frame.
> getContentPane().add() method don't work too.

Because Canvas is a heavyweight component and JMenuItem is lightweight.
You should generally avoid using heavyweight components along with
Swing.  So avoid the components in the package "java.awt".

-- 
Regards,

John McGrath [TeamB]

---------------------------------------------------
Before sending me e-mail, please read:
    http://www.JPMcGrath.net/newsgroups/e-mail.html
Technical Details
Message-ID: <4042cbfd$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!fu-berlin.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <4040d37c$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,b8df45e96a5c457a
X-Google-Attributes: gid111d45,public
X-Google-ArrivalTime: 2004-02-29 21:39:22 PST
From: "John McGrath  [TeamB]" <ng-b@JPMcGrath.net>
Subject: Re: JMenuItem and Canvas
Newsgroups: borland.public.jbuilder.java.swing
References: <4040d37c$1@newsgroups.borland.com>
User-Agent: XanaNews/1.16.1.11
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-15
NNTP-Posting-Host: 151.197.239.170
Message-ID: <4042cbfd$1@newsgroups.borland.com>
Date: 29 Feb 2004 21:37:01 -0800
X-Trace: newsgroups.borland.com 1078119421 151.197.239.170 (29 Feb 2004 21:37:01 -0800)
Lines: 18
X-Authenticated-User: jpmcgrath
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!fu-berlin.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail