freelanceprogrammers.org Forum Index » Java

how do i get the icon in place of the c


View user's profile Post To page top
mwaqqas Posted: Sun Feb 03, 2002 11:55 pm


Joined: 03 Feb 2002

Posts: 9
how do i get the icon in place of the c
how can i get my icon on the top left side of the application?
Reply with quote
Send private message
View user's profile Post To page top
mcconnell_stephen Posted: Tue Feb 05, 2002 9:23 pm


Joined: 01 Feb 2002

Posts: 73
how do i get the icon in place of the c
The first thing you have to do is load an
image....<br><br>There are all kinds of ways to do this. I do this in a
java Application like this....<br><br><br>Toolkit kit
= Toolkit.getDefaultToolkit();<br>Image image =
kit.getImage(url);<br>Image image = kit.getImage(filename);<br><br>Next,
there is a method in the JFrame or awt Frame<br>class
(which should be the base class for your applications`
frame) called <br><br>setIconImage(image);<br><br>Use
that and it should set your Icon in the upper left
corner... It will also be use for the icon when you
minumize it....<br><br>Stephen
McConnell<br><a href=http://www.crosslogic.com
target=new>http://www.crosslogic.com</a>
Reply with quote
Send private message
View user's profile Post To page top
mwaqqas Posted: Fri Feb 08, 2002 6:22 pm


Joined: 03 Feb 2002

Posts: 9
how do i get the icon in place of the c
thanks for the help<br><br>i have got my image as
the icon using the code you have told but there is
this one slight problem that the image is not
transparent.......i mean the image shows the whole image in the
taskbar with the background of anyother color than
gray(the default windows color). <br><br>my question is:
how do i make the icon transparent so that it shows
only the icons useful picture, not the background of
the icon?<br><br>thank you for your help
Reply with quote
Send private message
View user's profile Post To page top
mcconnell_stephen Posted: Fri Feb 08, 2002 9:58 pm


Joined: 01 Feb 2002

Posts: 73
how do i get the icon in place of the c
You are actually loading an "icon" as the thing
in the upper left hand corner!<br><br>I`ve never
used an .icon file, I`ve been using .jpg or .gif files
as my image. The thing is going to display what you
load. It`s designed to be OS independent and a .icon
image is basically "Windoz" specific.<br><br>Stephen
McConnell<br><a href=http://www.crosslogic.com
target=new>http://www.crosslogic.com</a>
Reply with quote
Send private message
View user's profile Post To page top
mwaqqas Posted: Sun Feb 10, 2002 2:25 am


Joined: 03 Feb 2002

Posts: 9
how do i get the icon in place of the c
how do i load an .icon file??
Reply with quote
Send private message
Post new topic Reply to topic
Display posts from previous:   
 

All times are GMT
Page 1 of 1
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Freelace Website Designer - Customer web design and software building.
Booking Calendar - reservation calendar script
Land Surveying - total station instruments and equipments
China Wholesale - Electronics Products
Character Studio - Tutorials and Help