Skip to content

Commit

Permalink
Increase chances of finding the ellipsis glyph in elided text
Browse files Browse the repository at this point in the history
The glyph for the ellipsis could be absent in the main font, so we should
try to find it in a fallback font; otherwise fall back to "...".

Change-Id: Ic53060ed42f3c800aba055d2be2a1c7c3cfeec64
Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
  • Loading branch information
KonstantinRitt committed Mar 7, 2016
1 parent 393f096 commit 229c519
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/gui/text/qtextengine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2747,8 +2747,7 @@ QString QTextEngine::elidedText(Qt::TextElideMode mode, const QFixed &width, int
QFixed ellipsisWidth;
QString ellipsisText;
{
QFontEngine *fe = fnt.d->engineForScript(QChar::Script_Common);
QFontEngine *engine = fe->type() == QFontEngine::Multi ? static_cast<QFontEngineMulti *>(fe)->engine(0) : fe;
QFontEngine *engine = fnt.d->engineForScript(QChar::Script_Common);

QChar ellipsisChar(0x2026);

Expand Down

0 comments on commit 229c519

Please sign in to comment.