2011/03/10

Making QT behave properly on Mac.

Couple of things I found out that helped porting a QT application to Mac:

The QMainWindow you create does not look like a native Cocoa window. The status bar is there, no matter what you request, the menu doesn't port and the icon is yucky.
Here's what you can do:

Remove status bar/resize grip:


Don't show unneeded icon in the title bar and move a QAction to Mac's main menu:

1 comment:

  1. I've tried using this in my app to hide the status bar, and it doesn't work. (I had been using the main window's own status bar, but it was too big and unsightly on the Mac, and seemed to be causing problems resizing the main windows.) What it does is to make the background to the window (i.e. apart from the labels and text-entry widgets) totally transparent. The default status bar (with the size grip) is still there.

    ReplyDelete