Results 1 to 4 of 4

Thread: QMessageBox missing icon

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Apr 2008
    Posts
    2
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11

    Question QMessageBox missing icon

    Hi,

    I'm brand new to Qt programming and of course to this forum. So, greetings one and all.

    I am simply trying to display a QMessageBox but the "standard" icon is not showing. In its place is the default Mac Application icon (a sheet of paper with a pencil, brush, and ruler forming an 'A' for those familiar with Mac OSX).

    Here is the very simple code snippet:
    Qt Code:
    1. QMessageBox::warning((QWidget *)0, "Test", "Testing");
    To copy to clipboard, switch view to plain text mode 

    I also tried this code to manually load the icon with the same result:
    Qt Code:
    1. qmbox.setIcon(QMessageBox::Warning);
    2. qmbox.setText("Testing");
    3. qmbox.exec();
    To copy to clipboard, switch view to plain text mode 
    However, if I change the code to use the "Critical" message icon (using either of the above 2 methods) the "Warning" message icon appears.

    QMessageBox::Question and QMessageBox::Information behave the same as QMessageBox::Warning ... ie: no standard message icon is display. QMessageBox::NoIcon works properly and does not display any icon.

    I am programming on Mac OSX using Qt 4.3.3

    TIA
    Last edited by jpn; 12th April 2008 at 11:42. Reason: missing [code] tags
    Zanth

Similar Threads

  1. Couple of questions: main window icon + toolbar icon
    By bpackard in forum Qt Programming
    Replies: 0
    Last Post: 20th March 2008, 19:03
  2. Mac application and the Dock Icon
    By sekelsenmat in forum Qt Programming
    Replies: 3
    Last Post: 26th September 2007, 10:23
  3. QMessageBox Icon Issue and How to add a dir to Qt Resources File
    By vishal.chauhan in forum Qt Programming
    Replies: 19
    Last Post: 25th March 2007, 00:13
  4. customize the Icon QMessageBox
    By QiT in forum Newbie
    Replies: 1
    Last Post: 26th August 2006, 10:40
  5. Missing action icons
    By ReilenBlaeyze in forum KDE Forum
    Replies: 4
    Last Post: 20th February 2006, 12:05

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.