🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #17685

Re: Gif files

#17685
From: Vernon McPherron
Date: Sun, 18 Oct 1998 00:00
22 lines
999 bytes

"Ingo J. Timm" wrote:

> Hi there,
> How can I load a gif-file from a disk without using the applet class?
>
> Thanks
>
> Divo

well you could create a class that extends canvas, then in the init
function, do the:

      theImage = Toolkit.getDefaultToolkit().getImage( "picture.gif" );

then create a paint method...

  public void paint( Graphics g )
  {
    g.drawImage( theImage, 0, 0, this );
  }
Technical Details
Message-ID: <362A8D59.570DB2C6@xnote.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <36238DB8.98D812B0@tzi.uni-bremen.de>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,520080f95f3f4add
X-Google-Attributes: gidf74b3,public
From: Vernon McPherron <vernon@xnote.com>
Subject: Re: Gif files
Date: 1998/10/18
Message-ID: <362A8D59.570DB2C6@xnote.com>
X-Deja-AN: 402634153
Content-Transfer-Encoding: 7bit
References: <36238DB8.98D812B0@tzi.uni-bremen.de>
X-Accept-Language: en
Content-Type: text/plain; charset=us-ascii
Organization: Another Netscape Collabra Server User
Mime-Version: 1.0
Reply-To: vernon@xnote.com
Newsgroups: borland.public.jbuilder.java.language