Avoid crash when getting bearings from fallback font engine
When accessing a fallback engine, we always need to call ensureEngineAt() to make sure it's loaded. Change-Id: Ib27e34137cfe8a3dd2b358aef3b3296a4ca52478 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
This commit is contained in:
parent
6f540691c4
commit
28826fe463
@ -1489,6 +1489,7 @@ glyph_metrics_t QFontEngineMulti::boundingBox(const QGlyphLayout &glyphs)
|
||||
void QFontEngineMulti::getGlyphBearings(glyph_t glyph, qreal *leftBearing, qreal *rightBearing)
|
||||
{
|
||||
int which = highByte(glyph);
|
||||
ensureEngineAt(which);
|
||||
engine(which)->getGlyphBearings(stripped(glyph), leftBearing, rightBearing);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user