-int QLFontInfo::width(Uchar val) const
+int QLFontInfo::width(Uchar val)
{
// Starting with version 3.1.0, Qt/X11 does its own caching of
// character width, so it is not necessary to provide ours.
{
// Starting with version 3.1.0, Qt/X11 does its own caching of
// character width, so it is not necessary to provide ours.
#include <qfont.h>
#include <qfontmetrics.h>
#include <qfont.h>
#include <qfontmetrics.h>
-#if QT_VERSION < 0x030100
+#if QT_VERSION < 0x030100 || defined(Q_WS_MACX)
#define USE_LYX_FONTCACHE
#endif
#define USE_LYX_FONTCACHE
#endif
QLFontInfo(LyXFont const & f);
/// Return pixel width for the given unicode char
QLFontInfo(LyXFont const & f);
/// Return pixel width for the given unicode char
- int width(Uchar val) const;
/// The font instance
QFont font;
/// The font instance
QFont font;