X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=automated-tests%2Fsrc%2Fdali-toolkit-internal%2Fdali-toolkit-test-utils%2Ftoolkit-text-utils.cpp;h=924815156e8d081d99a340e432eeb5444faac761;hp=31d81af5de2bf1156054d330464bd951c19ce4c0;hb=6c456bd91c102985503b651e4734c5d82221c941;hpb=534e542d7dcc1a1507a0e5e6845d49c06a15d326 diff --git a/automated-tests/src/dali-toolkit-internal/dali-toolkit-test-utils/toolkit-text-utils.cpp b/automated-tests/src/dali-toolkit-internal/dali-toolkit-test-utils/toolkit-text-utils.cpp index 31d81af..9248151 100644 --- a/automated-tests/src/dali-toolkit-internal/dali-toolkit-test-utils/toolkit-text-utils.cpp +++ b/automated-tests/src/dali-toolkit-internal/dali-toolkit-test-utils/toolkit-text-utils.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -269,7 +269,7 @@ void CreateTextModel( const std::string& text, // Set the layout parameters. const Vector& charactersToGlyph = visualModel->mCharactersToGlyph; const Vector& glyphsPerCharacter = visualModel->mGlyphsPerCharacter; - + float outlineWidth = visualModel->GetOutlineWidth(); Layout::Parameters layoutParameters( textArea, utf32Characters.Begin(), lineBreakInfo.Begin(), @@ -281,7 +281,9 @@ void CreateTextModel( const std::string& text, charactersToGlyph.Begin(), glyphsPerCharacter.Begin(), numberOfGlyphs, - Layout::HORIZONTAL_ALIGN_BEGIN ); + Text::HorizontalAlignment::BEGIN, + Text::LineWrap::WORD, + outlineWidth ); Vector& lines = visualModel->mLines; @@ -334,11 +336,13 @@ void CreateTextModel( const std::string& text, if( options.align ) { + float alignmentOffset = 0.f; layoutEngine.Align( textArea, 0u, numberOfCharacters, - Layout::HORIZONTAL_ALIGN_BEGIN, - lines ); + Text::HorizontalAlignment::BEGIN, + lines, + alignmentOffset ); } }