- const Vector4 textColor = propertyValue.Get< Vector4 >();
- if( mController->GetTextColor() != textColor )
- {
- mController->SetTextColor( textColor );
- mRenderer.Reset();
- }
- break;
- }
- case Toolkit::TextVisual::Property::ENABLE_MARKUP:
- {
- const bool enableMarkup = propertyValue.Get<bool>();
- mController->SetMarkupProcessorEnabled( enableMarkup );
- break;
- }
- case Toolkit::TextVisual::Property::ENABLE_AUTO_SCROLL:
- {
- // nothing to do.
- break;
- }
- case Toolkit::TextVisual::Property::AUTO_SCROLL_SPEED:
- {
- // nothing to do.
- break;
- }
- case Toolkit::TextVisual::Property::AUTO_SCROLL_LOOP_COUNT:
- {
- // nothing to do.
- break;
- }
- case Toolkit::TextVisual::Property::AUTO_SCROLL_GAP:
- {
- // nothing to do.
- break;
- }
- case Toolkit::TextVisual::Property::LINE_SPACING:
- {
- const float lineSpacing = propertyValue.Get<float>();
- mController->SetDefaultLineSpacing( lineSpacing );
- mRenderer.Reset();
- break;
- }
- case Toolkit::TextVisual::Property::UNDERLINE:
- {
- // TODO : This switch can be removed when the deprecated SHADOW_OFFSET and SHADOW_COLOR properties are finally removed.
- // Only the code for the MAP case should be kept.
- switch( propertyValue.GetType() )
- {
- case Property::VECTOR4:
- {
- const Vector4 color = propertyValue.Get<Vector4>();
- if( mController->GetUnderlineColor() != color )
- {
- mController->SetUnderlineColor( color );
- mRenderer.Reset();
- }
- break;
- }
- case Property::FLOAT:
- {
- float height = propertyValue.Get<float>();
- if( fabsf( mController->GetUnderlineHeight() - height ) > Math::MACHINE_EPSILON_1000 )
- {
- mController->SetUnderlineHeight( height );
- mRenderer.Reset();
- }
- break;
- }
- case Property::BOOLEAN:
- {
- const bool enabled = propertyValue.Get<bool>();
- if( mController->IsUnderlineEnabled() != enabled )
- {
- mController->SetUnderlineEnabled( enabled );
- mRenderer.Reset();
- }
- break;
- }
- case Property::MAP:
- {
- const bool update = SetUnderlineProperties( mController, propertyValue, Text::EffectStyle::DEFAULT );
- if( update )
- {
- mRenderer.Reset();
- }
- break;
- }
- default:
- {
- // Nothing to do.
- break;
- }
- }
-
- break;
- }
- case Toolkit::TextVisual::Property::SHADOW:
- {
- // TODO : This switch can be removed when the deprecated SHADOW_OFFSET and SHADOW_COLOR properties are finally removed.
- // Only the code for the MAP case should be kept.
- switch( propertyValue.GetType() )
- {
- case Property::VECTOR2:
- {
- const Vector2 shadowOffset = propertyValue.Get<Vector2>();
- if( mController->GetShadowOffset() != shadowOffset )
- {
- mController->SetShadowOffset( shadowOffset );
- mRenderer.Reset();
- }
- break;
- }
- case Property::VECTOR4:
- {
- const Vector4 shadowColor = propertyValue.Get<Vector4>();
- if( mController->GetShadowColor() != shadowColor )
- {
- mController->SetShadowColor( shadowColor );
- mRenderer.Reset();
- }
- break;
- }
- case Property::MAP:
- {
- const bool update = SetShadowProperties( mController, propertyValue, Text::EffectStyle::DEFAULT );
- if( update )
- {
- mRenderer.Reset();
- }
- break;
- }
- default:
- {
- // Nothing to do.
- break;
- }
- }
- break;
- }
- case Toolkit::TextVisual::Property::EMBOSS:
- {
- const bool update = SetEmbossProperties( mController, propertyValue, Text::EffectStyle::DEFAULT );
- if( update )
- {
- mRenderer.Reset();
- }
- break;
- }
- case Toolkit::TextVisual::Property::OUTLINE:
- {
- const bool update = SetOutlineProperties( mController, propertyValue, Text::EffectStyle::DEFAULT );
- if( update )