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. Set Mac Native Menus at Runtime

Set Mac Native Menus at Runtime

Scheduled Pinned Locked Moved Solved General and Desktop
osxmacmenuruntime
4 Posts 2 Posters 1.8k 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.
  • M Offline
    M Offline
    maximo
    wrote on last edited by
    #1

    Is there a way to set the native menus on Mac OSX at runtime without having to change the TARGET variable in the .pro file?

    See, I may need to whitelabel my project multiple times, and it would be great to simply copy in a new settings.ini file rather than have to edit that variable and recompile again.

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

      Hi,

      You would have to provide your own .plist file and customize the CFBundleName value.

      Hope it helps

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      M 1 Reply Last reply
      1
      • SGaistS SGaist

        Hi,

        You would have to provide your own .plist file and customize the CFBundleName value.

        Hope it helps

        M Offline
        M Offline
        maximo
        wrote on last edited by
        #3

        @SGaist Is there any way to intercept the menu paint event and swap out "app" with some other phrase? (Note, I have TARGET variable set to "app", currently.)

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          No, that's the native OS X menu so you can't modify it. Again: use the Info.plist file, it's also explained in QMenuBar's documentation

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          1

          • Login

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