X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Finternal%2Ftext%2Fvisual-model-impl.cpp;h=c79e5a964208b75773acb47849c8031cd00ef93b;hb=HEAD;hp=490bae3b82746f2c5bd9f08f32d7875464edb4a2;hpb=38f0ea9fcdf1dc5037144fa19c8a52316c8af763;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 490bae3..3fdd6b8 100644 --- a/dali-toolkit/internal/text/visual-model-impl.cpp +++ b/dali-toolkit/internal/text/visual-model-impl.cpp @@ -340,6 +340,16 @@ const Vector2& VisualModel::GetLayoutSize() const return mLayoutSize; } +void VisualModel::SetHeightForWidth(const Vector2& size) +{ + mHeightForWidth = size; +} + +const Vector2& VisualModel::GetHeightForWidth() const +{ + return mHeightForWidth; +} + void VisualModel::SetTextColor(const Vector4& textColor) { mTextColor = textColor; @@ -371,11 +381,21 @@ void VisualModel::SetUnderlineColor(const Vector4& color) mUnderlineColorSet = true; } +void VisualModel::SetOutlineOffset(const Vector2& outlineOffset) +{ + mOutlineOffset = outlineOffset; +} + void VisualModel::SetOutlineColor(const Vector4& color) { mOutlineColor = color; } +void VisualModel::SetOutlineBlurRadius(const float& outlineBlurRadius) +{ + mOutlineBlurRadius = outlineBlurRadius; +} + void VisualModel::SetUnderlineEnabled(bool enabled) { mUnderlineEnabled = enabled; @@ -496,11 +516,21 @@ const Vector4& VisualModel::GetUnderlineColor() const return mUnderlineColor; } +const Vector2& VisualModel::GetOutlineOffset() const +{ + return mOutlineOffset; +} + const Vector4& VisualModel::GetOutlineColor() const { return mOutlineColor; } +const float& VisualModel::GetOutlineBlurRadius() const +{ + return mOutlineBlurRadius; +} + bool VisualModel::IsUnderlineEnabled() const { return mUnderlineEnabled; @@ -635,6 +665,36 @@ const Vector& VisualModel::GetGlyphsToCharacters() const return mGlyphsToCharacters; } +void VisualModel::SetCutoutEnabled(bool enable) +{ + mCutoutEnabled = enable; +} + +bool VisualModel::IsCutoutEnabled() const +{ + return mCutoutEnabled; +} + +void VisualModel::SetBackgroundWithCutoutEnabled(bool enable) +{ + mBackgroundWithCutoutEnabled = enable; +} + +bool VisualModel::IsBackgroundWithCutoutEnabled() const +{ + return mBackgroundWithCutoutEnabled; +} + +void VisualModel::SetBackgroundColorWithCutout(const Vector4& color) +{ + mBackgroundColorWithCutout = color; +} + +const Vector4& VisualModel::GetBackgroundColorWithCutout() const +{ + return mBackgroundColorWithCutout; +} + VisualModel::~VisualModel() { } @@ -655,15 +715,18 @@ VisualModel::VisualModel() mStrikethroughColor(Color::BLACK), mControlSize(), mShadowOffset(), + mOutlineOffset(), mUnderlineHeight(0.0f), mStrikethroughHeight(0.0f), mUnderlineType(Text::Underline::SOLID), mDashedUnderlineWidth(2.0f), mDashedUnderlineGap(1.0f), mShadowBlurRadius(0.0f), + mOutlineBlurRadius(0.0f), mOutlineWidth(0u), mNaturalSize(), mLayoutSize(), + mHeightForWidth(0.0f, 0.0f), mCachedLineIndex(0u), mEllipsisPosition(DevelText::EllipsisPosition::END), mStartIndexOfElidedGlyphs(0u), @@ -676,8 +739,9 @@ VisualModel::VisualModel() mBackgroundEnabled(false), mMarkupProcessorEnabled(false), mStrikethroughEnabled(false), - mCharacterSpacing(0.0f) - + mCharacterSpacing(0.0f), + mCutoutEnabled(false), + mBackgroundWithCutoutEnabled(false) { }