Results 1 to 7 of 7

Thread: background color of menu bar

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #2
    Join Date
    May 2006
    Location
    Bangalore,India
    Posts
    235
    Thanks
    7
    Thanked 25 Times in 24 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Windows

    Default Re: background color of menu bar

    try same code as main window.
    change m_pMenu with your menu variable.
    Qt Code:
    1. QPalette palette;
    2. palette.setColor(m_pMenu->backgroundRole(), Qt::black);
    3. m_pMenu->setPalette(palette);
    To copy to clipboard, switch view to plain text mode 

  2. The following 2 users say thank you to rajesh for this useful post:

    ntp (23rd October 2007), sabeesh (25th July 2007)

Similar Threads

  1. Docked Widget Menu
    By Chuk in forum Qt Programming
    Replies: 6
    Last Post: 3rd July 2013, 14:12
  2. Menu bar background color focus
    By user_mail07 in forum Qt Tools
    Replies: 0
    Last Post: 18th May 2007, 01:25
  3. MainWindow Menu bug in Qt 4.2.3?
    By No-Nonsense in forum Qt Programming
    Replies: 4
    Last Post: 11th March 2007, 11:47
  4. Background image on popup menu item
    By MarkoSan in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 27th June 2006, 05:55
  5. Replies: 1
    Last Post: 5th April 2006, 16:44

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.