Article View: borland.public.jbuilder.java.api
Article #837Re: ImageIcon equivalent in AWT
From: John McGrath TeamB
Date: Sat, 14 Sep 2002 23:07
Date: Sat, 14 Sep 2002 23:07
23 lines
1892 bytes
1892 bytes
On Sat, 14 Sep 2002 17:18:59 -0500, George Boutwell wrote:
> But every attempt I made at trying to use Image complained
> about it being an abstract class, or plain old didn't work.
> I guess I'll go bang my head against the wall some more.
The implementations of Image are platform-specific, so you do not
instantiate them in your code. You use the createImage() factory
method in the Toolkit class to create them.
Depending on how you are using the image, you may need to use a
MediaTracker to ensure that the image has been loaded. This does
not happen when you create the image -- the image data is loaded
when needed.
--
Regards,
John McGrath [TeamB]
---------------------------------------------------
Before sending me e-mail, please read:
http://www.JPMcGrath.net/newsgroups/e-mail.html
Technical Details
Message-ID:
<MPG.17ed8b28445cbaec98b9f9@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!newsswitch.lcs.mit.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.freenet.de!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<3D83765D.1030609@netscape.net> <MPG.17ed4ff5883305e098b9f7@newsgroups.borland.com> <3D83B5D3.6050504@netscape.net>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,89e330da565ac5e7 X-Google-Attributes: gid1089d0,public X-Google-ArrivalTime: 2002-09-14 16:34:06 PST From: John McGrath [TeamB] <ng-b@JPMcGrath.net> Newsgroups: borland.public.jbuilder.java.api Subject: Re: ImageIcon equivalent in AWT Date: Sat, 14 Sep 2002 19:07:05 -0400 Message-ID: <MPG.17ed8b28445cbaec98b9f9@newsgroups.borland.com> References: <3D83765D.1030609@netscape.net> <MPG.17ed4ff5883305e098b9f7@newsgroups.borland.com> <3D83B5D3.6050504@netscape.net> X-Newsreader: MicroPlanet Gravity v2.60 NNTP-Posting-Host: 151.197.230.97 X-Trace: newsgroups.borland.com 1032044820 151.197.230.97 (14 Sep 2002 16:07:00 -0700) Lines: 23 X-Authenticated-User: jpmcgrath Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!newsswitch.lcs.mit.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.freenet.de!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail