X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;ds=inline;f=dali-toolkit%2Finternal%2Ftext%2Frendering%2Fview-model.cpp;h=83a518bd89c0a8407333c4b25be32a55896bb680;hb=ca8b48b0711b574b7ad36a7630b352001dee37d2;hp=0a977f331cf065596c4783b01a0ebf33a15fe36c;hpb=d68a6075c205713640ae01d589d71e7c28275fb2;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/internal/text/rendering/view-model.cpp b/dali-toolkit/internal/text/rendering/view-model.cpp index 0a977f3..83a518b 100755 --- a/dali-toolkit/internal/text/rendering/view-model.cpp +++ b/dali-toolkit/internal/text/rendering/view-model.cpp @@ -297,7 +297,7 @@ void ViewModel::ElideGlyphs() // Need to reshape the glyph as the font may be different in size. const GlyphInfo& ellipsisGlyph = fontClient.GetEllipsisGlyph( fontClient.GetPointSize( glyphToRemove.fontId ) ); - if( !firstPenSet ) + if( !firstPenSet || glyphToRemove.advance == 0.f ) { const Vector2& position = *( elidedPositionsBuffer + index ); @@ -332,6 +332,11 @@ void ViewModel::ElideGlyphs() glyphInfo = ellipsisGlyph; // Change the 'x' and 'y' position of the ellipsis glyph. + if( position.x > firstPenX ) + { + position.x = firstPenX + removedGlypsWidth - ellipsisGlyphWidth; + } + position.x += ellipsisGlyph.xBearing; position.y = penY - ellipsisGlyph.yBearing;