aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes how to tile image on jlabel? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "how to tile image on jlabel?" Watch "how to tile image on jlabel?" New topic
Author

how to tile image on jlabel?

dragon ji
Ranch Hand

Joined: Oct 31, 2002
Posts: 110
Hi, guys,

I want to make a label using 3 images,two for top and tail,one for middle.and I want to tile the middle image.

How can I get it?

thanx a lot

Best Regards

Dragon


scjp 1.4<br />challenge haven't limit!
Tommy Greenberg
Greenhorn

Joined: Jul 30, 2004
Posts: 15
Make a class that extends a JLabel and overwrite the paint method. I would use photoshop or some other graphic editor to make the image you require and would just use that. Or make a JPanel and use the GridBagLayout to place each of them as separate labels in the arrangement you want.
dragon ji
Ranch Hand

Joined: Oct 31, 2002
Posts: 110
thanx,Tommy Greenberg
I will try it.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to tile image on jlabel?
 
Similar Threads
Tile Game
Using Tiles and html:img tag
BufferedImage and scanning pixels
Image effects...
tiles struts