• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Jj Roberts
  • Tim Holloway
  • Piet Souris
Bartenders:
  • Himai Minh
  • Carey Brown
  • salvin francis

JButton Shapes

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it possible to have different shapes of buttons in Swing ?
[ Using ButtonUI ]
------------------
Vijay Anand
 
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Vijay,
Please see this link regarding the JavaRanch's official naming policy. 'Just Java' does not meet the naming policy guidelines. Please reregister with a name that conforms to the naming policy.
 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Vijay
Button itself means it has its own specific graphical representation. So, u can't get buttons in different shapes. But u can arrange them in a container in different ways.
Hope this can help u
with regards
chak

Originally posted by Just Java:
Is it possible to have different shapes of buttons in Swing ?
[ Using ButtonUI ]


 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, you can make buttons of different shapes. Check out this link for an example of a round JButton.
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
U could try one more thing :
Add Round/Square/Any suitable shape gifs to the button.
In this way, the button appears to be Round/Square/Other suitable shape.
I guess the only prerequisite is that you have to prepare gifs.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic