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 create custom menu
Forum Updated to NodeBB v4.3 + New Features

How to create custom menu

Scheduled Pinned Locked Moved Solved General and Desktop
2 Posts 2 Posters 681 Views 1 Watching
  • 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.
  • A Offline
    A Offline
    amansinha
    wrote on 16 Mar 2019, 12:24 last edited by
    #1

    Hello Everyone,

    I want to create a well designed menu in qt widget, I have found various links in which they are explaining like how we can create menus using qmenubar, But that will not help me to design my menu bar.
    My menu will look some thing like this "https://prnt.sc/myat23". There will be several sub-menus between them.
    Can any one help me to design the menus some thing like on the screenshot.

    Also,How we can embed 2 ui file and show into third file.

    Thanks

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mrjj
      Lifetime Qt Champion
      wrote on 16 Mar 2019, 22:07 last edited by
      #2

      Hi and welcome to the forums.
      You can maybe find inspiration in this one.
      https://github.com/chrisaverage/burger-menu

      Regarding UI files.
      Creator can create 2 kinds.
      One is just the UI file. There is no .h and .cpp created for it.
      Those you can use via https://doc.qt.io/qt-5/quiloader.html
      The other kind of UI files it can create, has .h and .cpp file also and a class that uses
      the UI. This you can embed using the promotion feature
      https://doc.qt.io/qt-5/designer-using-custom-widgets.html
      It's not as complicated it might look like.
      Say you made a class called MyMenu
      you would simply tell it class name MyMenu and MyMenu.h
      (in which file to find class)
      Then click, add and then promote.

      1 Reply Last reply
      3

      1/2

      16 Mar 2019, 12:24

      • Login

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