• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

is it possible to design your own background 4 jbuttons

 
Ranch Hand
Posts: 331
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I was wondering if it was possible to design
a background for JButton; that way I can use
it as a parameter to setBackground. Because I
want to design a metal look and place this as
backgroung rather than using the plain colours
eg black, red. And also I dont want to use setIcon
because I would like to place an Icon on top eg
an arrow for previous or next
Thank u for your time
 
Bartender
Posts: 4121
IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I got this to work...

Here's the class....


And here's a tester to show how it works...


Hope this helps,
-nate
 
john mattucci
Ranch Hand
Posts: 331
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank u so much for your time
Yesterday I went to this site http://www.izforge.com/izpack
and downloaded free software and I was really impressed with his
L & F . At first I thought he used a gif for his buttons ,but when I unzipped the jar there was no gif that matched his background for his buttons. Would someone have a minute to look at the programme? Is there a L& F which produces such an affect or is it something he customized himself.
Thanx s again
 
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The following was taken from the creators source code. It is on your hard drive in the folder where you installed the program. This came from the file "installer.java".


------------------
Happy Coding,
Gregg Bolinger
 
You didn't tell me he was so big. Unlike this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic