PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Tuesday, September 13, 2022

[FIXED] How to add "About" action to app on OS X?

 September 13, 2022     about-box, cross-platform, desktop-application, macos, qt     No comments   

Issue

In almost every application on OS X, if you click on the name of application, one of the actions is "About". I understand how I can do this in QMenuBar, but seems like it is not a part of it.

The second question is how this will be shown on Windows?

I don't use QML - how to do this in code? Like this way:

QMenu *fileMenu = menuBar->addMenu("File");

QAction *newFile = new QAction("New", fileMenu);
QAction *openProjectAction = new QAction("Open project", fileMenu);

So how I add "About" action to group of actions of application? Screenshot addedGoogle Chrome about


Solution

You can simply add your action as Help --> About.

  • On macOS the action will be automatically moved to the needed section, as on your screenshot.
  • On Windows this action will remain as is (in the Help section).

You may also want to take a look at the macOS QAction roles.



Answered By - kefir500
Answer Checked By - Mary Flores (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing