X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Finternal%2Ftext%2Fvisual-model-impl.cpp;h=ce0fb7c692949bd7c4f8e81a733e4c891ed7cec2;hb=7946b5a1a7188e31803ac8de5c4a8ea3cbc560cc;hp=6c4ff9b87e3c4204c6343e56c1fb73dd75fa6b99;hpb=d52cfe949a764d4ab0584b99d1322f06c8acd92f;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/internal/text/visual-model-impl.cpp b/dali-toolkit/internal/text/visual-model-impl.cpp index 6c4ff9b..ce0fb7c 100644 --- a/dali-toolkit/internal/text/visual-model-impl.cpp +++ b/dali-toolkit/internal/text/visual-model-impl.cpp @@ -305,13 +305,13 @@ LineIndex VisualModel::GetLineOfCharacter(CharacterIndex characterIndex) return index; } -void VisualModel::GetUnderlineRuns(GlyphRun* underlineRuns, - UnderlineRunIndex index, - Length numberOfRuns) const +void VisualModel::GetUnderlineRuns(UnderlinedGlyphRun* underlineRuns, + UnderlineRunIndex index, + Length numberOfRuns) const { memcpy(underlineRuns, mUnderlineRuns.Begin() + index, - numberOfRuns * sizeof(GlyphRun)); + numberOfRuns * sizeof(UnderlinedGlyphRun)); } void VisualModel::SetNaturalSize(const Vector2& size) @@ -460,6 +460,11 @@ void VisualModel::SetStrikethroughHeight(float height) mStrikethroughHeight = height; } +void VisualModel::SetCharacterSpacing(float characterSpacing) +{ + mCharacterSpacing = characterSpacing; +} + const Vector4& VisualModel::GetTextColor() const { return mTextColor; @@ -525,6 +530,11 @@ const Vector4& VisualModel::GetBackgroundColor() const return mBackgroundColor; } +const float VisualModel::GetCharacterSpacing() const +{ + return mCharacterSpacing; +} + bool VisualModel::IsBackgroundEnabled() const { return mBackgroundEnabled; @@ -604,6 +614,11 @@ void VisualModel::ClearCaches() mCachedLineIndex = 0u; } +const Vector& VisualModel::GetGlyphsToCharacters() const +{ + return mGlyphsToCharacters; +} + VisualModel::~VisualModel() { } @@ -644,7 +659,8 @@ VisualModel::VisualModel() mUnderlineColorSet(false), mBackgroundEnabled(false), mMarkupProcessorEnabled(false), - mStrikethroughEnabled(false) + mStrikethroughEnabled(false), + mCharacterSpacing(0.0f) { }