Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Linux Archive
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-18-2008, 08:47 PM
teo teo is offline
Member
 
Join Date: Jun 2008
Posts: 3
teo is on a distinguished road
[SOLVED] MenuButton
Hi,

i am not new to java but new to swing. I have had no problems till now in doing buttons or textfields or menus but now even internet doesn't find what i want I am trying to make a button with a menu (like the create new class button in eclipse or profile main project in NetBeans) That is a button in two pieces where one piece has an arrow and through clicking this arrow it opens a menu.
Can someone please help me with the code for that.

Thanks
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-19-2008, 01:52 AM
Fubarable's Avatar
Senior Member
 
Join Date: Jun 2008
Posts: 900
Fubarable is on a distinguished road
Cross-posted in the Sun java forum.

Please don't cross-post questions in multiple forums. Imagine how frustrating it is for a volunteer to work towards an answer, post it, only to find that the answer was already provided in a cross-post. For this reason, many refuse to help habitual cross-posters.
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 06-19-2008, 02:17 AM
teo teo is offline
Member
 
Join Date: Jun 2008
Posts: 3
teo is on a distinguished road
Sorry
Ok Sorry i just wanted more people to read it cause some people use one forum some others another one.
Bookmark Post in Technorati
Reply With Quote
  #4 (permalink)  
Old 06-19-2008, 02:27 AM
Fubarable's Avatar
Senior Member
 
Join Date: Jun 2008
Posts: 900
Fubarable is on a distinguished road
I understand, but please understand it from our point of view. It also is a violation of the forum rules that you agreed to on joining this forum.
Bookmark Post in Technorati
Reply With Quote
  #5 (permalink)  
Old 06-19-2008, 02:28 AM
Senior Member
 
Join Date: Jul 2007
Posts: 1,222
hardwired is on a distinguished road
like the create new class button in eclipse or profile main project in NetBeans
I don't have access to these.
Here's a link to something I did some time ago (OptionComponent); maybe you can get some ideas from it.
Drop Down Menu Buttons
Bookmark Post in Technorati
Reply With Quote
  #6 (permalink)  
Old 06-19-2008, 02:33 PM
teo teo is offline
Member
 
Join Date: Jun 2008
Posts: 3
teo is on a distinguished road
Thanks
Thank you for your help.
As i see you have written the code for every line that should be visible if the element is activated and you have also calculated the coordinates of the place where the arrow should be placed. This is also what i wanted but doesn't java have an element like this?
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +3. The time now is 02:38 AM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org