Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to assign a signal to a QMenu instead of QAction in Qt?
Forum Update on Monday, May 27th 2025

How to assign a signal to a QMenu instead of QAction in Qt?

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 258 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ManiRonM Offline
    ManiRonM Offline
    ManiRon
    wrote on last edited by
    #1

    i want a menu which when pressed has to trigger instead of creating a sub action menu i want to do those with the Qmenu how can this be done?

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by mrjj
      #2

      Hi
      There will still be an action.
      But you don't have to create submenus.
      https://stackoverflow.com/questions/6370793/how-to-assign-a-signal-to-a-qmenu-instead-of-qaction-in-qt

      But if you use top-level menus as buttons then consider using QToolBar instead.

      1 Reply Last reply
      3

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved