Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6188099
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T02:10:17+00:00 2026-05-24T02:10:17+00:00

I’m developping a Java/Swing application with a menu using JMenuBar, JMenu and JMenuItem. System

  • 0

I’m developping a Java/Swing application with a menu using JMenuBar, JMenu and JMenuItem.

System look and fell is applied to the UI.

UIManager.setLookAndFeel( UIManager.getSystemLookAndFeelClassName() );

I have several top level elements for my menu :

  • The JMenu “File” works fine and allows the user to select submenus like JMenuItems “New”, “Open”…

  • Then, I wanna add a second top level element “About” (same level as “File”) that displays a popup when clicking on it.

The issue is quite simple: how to make this JMenu “About” element clickable?

I try several ways:

  1. Set the “About” element as a JMenuItem. However, this element has not the same UI that the other JMenu items like “File”

  2. Set the “About” element as a JMenu and add a MouseListener and a KeyListener on it. This element will have the same UI that others but I have to click twice on the “Ok” button of the “About” popup to catch this event.

Any other solutions ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T02:10:18+00:00Added an answer on May 24, 2026 at 2:10 am

    My first suggestion would be to just add a single JMenuItem inside the JMenu “About” menu. As this would match how the other menus operate and would look the same. It would also not be surprising when a user clicks on “About” expecting a menu but sees a popup instead. It is fairly common for applications to have a “Help” menu on the end of a menu bar that has a menu item named “About” that shows a popup. It is not common for the menu title to open a popup when clicked on.

    If you really have to do what your propose then either:

    • Specify a Look and Feel (like Nimbus), and modify a JMenuItem to look like a Menu Item.

    or

    • Find a way for your second option to work. This sounds doable, but might take some more tweaking and would be more difficult to get the UI to work right with the System Look and Feels.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have thousands of HTML files to process using Groovy/Java and I need to
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
We're building an app, our first using Rails 3, and we're having to build
We are using XSLT to translate a RIXML file to XML. Our RIXML contains
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I am reading a book about Javascript and jQuery and using one of the
I am using Paperclip to handle profile photo uploads in my app. They upload

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.