diff options
Diffstat (limited to 'src/plugins/platforms')
4 files changed, 0 insertions, 55 deletions
diff --git a/src/plugins/platforms/windows/qwindowsfontengine.cpp b/src/plugins/platforms/windows/qwindowsfontengine.cpp index a2f65c766d..264c22f47e 100644 --- a/src/plugins/platforms/windows/qwindowsfontengine.cpp +++ b/src/plugins/platforms/windows/qwindowsfontengine.cpp @@ -777,35 +777,6 @@ const char *QWindowsFontEngine::name() const return 0; } -bool QWindowsFontEngine::canRender(const QChar *string, int len) -{ - if (symbol) { - for (int i = 0; i < len; ++i) { - unsigned int uc = getChar(string, i, len); - if (getTrueTypeGlyphIndex(cmap, uc) == 0) { - if (uc < 0x100) { - if (getTrueTypeGlyphIndex(cmap, uc + 0xf000) == 0) - return false; - } else { - return false; - } - } - } - } else if (ttf) { - for (int i = 0; i < len; ++i) { - unsigned int uc = getChar(string, i, len); - if (getTrueTypeGlyphIndex(cmap, uc) == 0) - return false; - } - } else { - while(len--) { - if (tm.tmFirstChar > string->unicode() || tm.tmLastChar < string->unicode()) - return false; - } - } - return true; -} - QFontEngine::Type QWindowsFontEngine::type() const { return QFontEngine::Win; diff --git a/src/plugins/platforms/windows/qwindowsfontengine.h b/src/plugins/platforms/windows/qwindowsfontengine.h index 390de1d16e..89ad08f689 100644 --- a/src/plugins/platforms/windows/qwindowsfontengine.h +++ b/src/plugins/platforms/windows/qwindowsfontengine.h @@ -112,8 +112,6 @@ public: virtual const char *name() const; - bool canRender(const QChar *string, int len); - Type type() const; virtual QImage alphaMapForGlyph(glyph_t t) { return alphaMapForGlyph(t, QTransform()); } diff --git a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp index cd5defdfea..744058279e 100644 --- a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp +++ b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp @@ -647,29 +647,6 @@ const char *QWindowsFontEngineDirectWrite::name() const return 0; } -bool QWindowsFontEngineDirectWrite::canRender(const QChar *string, int len) -{ - QVarLengthArray<UINT32> codePoints(len); - int actualLength = 0; - for (int i=0; i<len; ++i, actualLength++) - codePoints[actualLength] = getChar(string, i, len); - - QVarLengthArray<UINT16> glyphIndices(actualLength); - HRESULT hr = m_directWriteFontFace->GetGlyphIndices(codePoints.data(), actualLength, - glyphIndices.data()); - if (FAILED(hr)) { - qErrnoWarning("%s: GetGlyphIndices failed", __FUNCTION__); - return false; - } - - for (int i = 0; i < actualLength; ++i) { - if (glyphIndices.at(i) == 0) - return false; - } - - return true; -} - QFontEngine::Type QWindowsFontEngineDirectWrite::type() const { return QFontEngine::DirectWrite; diff --git a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h index aacdcd5a89..070adfcbde 100644 --- a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h +++ b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h @@ -99,7 +99,6 @@ public: QFontEngine *cloneWithSize(qreal pixelSize) const; - bool canRender(const QChar *string, int len); Type type() const; const QSharedPointer<QWindowsFontEngineData> &fontEngineData() const { return m_fontEngineData; } |