πŸš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.api
Article #2117

Re: Placing an image on a JPanel

#2117
From: Joi Ellis [TeamB]
Date: Wed, 23 May 2001 12:53
16 lines
1523 bytes
"SοΏ½ren Hanisch" <soeren.hanisch@gwi-ag.com> wrote:
> Hi,

> is it possible to place images ( *.gif) on a JPanel ?
> I mean without a creating a JButton and placing the image on this one and
> the placing the JButton on the JPanel.

I stick it in a JLabel and add that to the JPanel.  As I understand it,
JPanel is just a dumb container, it can't display text, images, etc itself,
but it can hold other components which can.

-- 
Joi Ellis (TeamB) 
No direct email, please.
For best results, post on news server newsgroups.borland.com!
Newsgroup Info: http://www.borland.com/newsgroups/guide.html
Technical Details
Message-ID: <3b0bb2bd_1@dnews>
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-03!supernews.com!cyclone2.usenetserver.com!news-out.usenetserver.com!btnet-peer0!btnet!newscore.univie.ac.at!newsfeed1.uni2.dk!newssuck.uni2.dk!dnews!not-for-mail
References: <3b0b6b6e@news.gwi-ag.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 1089d0,9279ad3f53b831ad
X-Google-Attributes: gid1089d0,public
X-Google-ArrivalTime: 2001-05-23 06:12:05 PST
Message-ID: <3b0bb2bd_1@dnews>
From: "Joi Ellis [TeamB]" <joi@aravox.com>
Subject: Re: Placing an image on a JPanel
Newsgroups: borland.public.jbuilder.java.api
References: <3b0b6b6e@news.gwi-ag.com>
User-Agent: tin/1.4.2-20000205 ("Possession") (UNIX) (Linux/2.2.16-3 (i686))
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
NNTP-Posting-Host: 209.46.41.66
Date: 23 May 2001 05:53:17 -0700
X-Trace: dnews 990622397 209.46.41.66 (23 May 2001 05:53:17 -0700)
Lines: 16
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-03!supernews.com!cyclone2.usenetserver.com!news-out.usenetserver.com!btnet-peer0!btnet!newscore.univie.ac.at!newsfeed1.uni2.dk!newssuck.uni2.dk!dnews!not-for-mail