From e006624a4212f670540af8fbd21ea5a116b8ccfc Mon Sep 17 00:00:00 2001 From: Konstantin Ritt Date: Sat, 23 Mar 2013 20:19:54 +0200 Subject: Improve shapeTextWithHarfbuzz() logic a bit * Move non-specific code to shapeText(); * Make shapeTextWithHarfbuzz() re-use variables obtained in shapeText(); * Make shapeTextWithHarfbuzz() return amount of shaped glyphs instead of nothing. Right now, this is not about error reporting, since failed shaping causes assertion/crash in most cases. Change-Id: I2e0c91b9e5de8b19e0bc22ca60add1b1fc6ebdb0 Reviewed-by: Lars Knoll --- src/gui/text/qtextengine_p.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/gui/text/qtextengine_p.h') diff --git a/src/gui/text/qtextengine_p.h b/src/gui/text/qtextengine_p.h index 29f44ef9bd..6d46231c67 100644 --- a/src/gui/text/qtextengine_p.h +++ b/src/gui/text/qtextengine_p.h @@ -699,7 +699,7 @@ private: void setBoundary(int strPos) const; void addRequiredBoundaries() const; void shapeText(int item) const; - void shapeTextWithHarfbuzz(int item) const; + int shapeTextWithHarfbuzz(QScriptItem &si, const ushort *string, int itemLength, QFontEngine *fontEngine, bool kerningEnabled) const; void splitItem(int item, int pos) const; int endOfLine(int lineNum); -- cgit v1.2.3