From 106843ad1afa2f5c0aedaa748088d4ebacd6d73d Mon Sep 17 00:00:00 2001 From: Konstantin Ritt Date: Mon, 9 Sep 2013 11:46:50 +0300 Subject: Make QFontEngine not derive from QObject Whilst having the objectName set for each engine is somewhat handy when debugging, deriving from QObject just for that is a wasting of memory in all other cases. This also broke the font engine abstraction by allowing qobject_cast() to access some private data; the only sane way to distinguish engines is querying their Type value. Change-Id: Ib1d195692859eb39089f6d8d9016cb8f9dcc0400 Reviewed-by: Friedemann Kleint Reviewed-by: Lars Knoll --- src/plugins/platforms/windows/qwindowsfontengine.h | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'src/plugins/platforms/windows/qwindowsfontengine.h') diff --git a/src/plugins/platforms/windows/qwindowsfontengine.h b/src/plugins/platforms/windows/qwindowsfontengine.h index 60ff61fcb9..d783b6048c 100644 --- a/src/plugins/platforms/windows/qwindowsfontengine.h +++ b/src/plugins/platforms/windows/qwindowsfontengine.h @@ -68,10 +68,7 @@ class QWindowsFontEngineData; class QWindowsFontEngine : public QFontEngine { - Q_OBJECT - Q_PROPERTY(HFONT hFont READ hFont STORED false) - Q_PROPERTY(LOGFONT logFont READ logFont STORED false) - Q_PROPERTY(bool trueType READ trueType STORED false) + friend class QWindowsMultiFontEngine; public: QWindowsFontEngine(const QString &name, HFONT, bool, LOGFONT, @@ -137,11 +134,6 @@ public: const QSharedPointer &fontEngineData() const { return m_fontEngineData; } - // Properties accessed by QWin32PrintEngine (Qt Print Support) - LOGFONT logFont() const { return m_logfont; } - HFONT hFont() const { return hfont; } - bool trueType() const { return ttf; } - void setUniqueFamilyName(const QString &newName) { uniqueFamilyName = newName; } private: -- cgit v1.2.3