I prefer to build Qt from source. I have been trying to build Qt 4.8.5 on Mac OS X 10.9 (Mavericks). I managed in the end, but it took a few tweaks. Online information about how to do this was fragmentary, so I am documenting it here in case it is useful to someone else.
1. Webkit doesn’t build. I don’t need it so I disabled it using configure option:
Mac OS X 10.9 (Mavericks) was released yesterday. And those nice people at Apple made it free, so you can be sure lots of people are downloading it. However Qt 4 apps look at bit strange on the new OS. Look at the text alignment in these buttons:
The text isn’t centre aligned. It doesn’t look like much of an issue out of context. But it looks wrong when you look at a whole UI. The good news is that there is a simple fix:
if ( QSysInfo::MacintoshVersion > QSysInfo::MV_10_8 )
// fix Mac OS X 10.9 (mavericks) font issue
QFont::insertSubstitution(".Lucida Grande UI", "Lucida Grande");
You need to place this code in your main() before creating your QApplication. For more details see this bug report.
With the fix the buttons look like this:
Much better! There are some console warnings:
CoreText performance note: Client called CTFontCreateWithName() using
name "Lucida Grande" and got font with PostScript name "LucidaGrande".
For best performance, only use PostScript names when calling this API.
I am not sure how how significant these are.
I have also found that updating to Qt 4.8.5 fixes a printing crash bug in my table plan software. This crash happened when rotated pixmaps were printed from Mac OS X 10.8.
I have seen on forums that Qt 5 is completely broken on 10.9. But I don’t know if that is true.