Fixed an incorrect ellipsis
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / internal / text / rendering / view-model.cpp
index 7c2d156..70b642f 100755 (executable)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2018 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.
@@ -71,6 +71,11 @@ VerticalAlignment::Type ViewModel::GetVerticalAlignment() const
   return mModel->GetVerticalAlignment();
 }
 
+DevelText::VerticalLineAlignment::Type ViewModel::GetVerticalLineAlignment() const
+{
+  return mModel->GetVerticalLineAlignment();
+}
+
 bool ViewModel::IsTextElideEnabled() const
 {
   return mModel->IsTextElideEnabled();
@@ -163,6 +168,11 @@ const Vector4& ViewModel::GetShadowColor() const
   return mModel->GetShadowColor();
 }
 
+const float& ViewModel::GetShadowBlurRadius() const
+{
+  return mModel->GetShadowBlurRadius();
+}
+
 const Vector4& ViewModel::GetUnderlineColor() const
 {
   return mModel->GetUnderlineColor();
@@ -198,6 +208,16 @@ float ViewModel::GetOutlineWidth() const
   return mModel->GetOutlineWidth();
 }
 
+const Vector4& ViewModel::GetBackgroundColor() const
+{
+  return mModel->GetBackgroundColor();
+}
+
+bool ViewModel::IsBackgroundEnabled() const
+{
+  return mModel->IsBackgroundEnabled();
+}
+
 void ViewModel::ElideGlyphs()
 {
   mIsTextElided = false;
@@ -312,12 +332,6 @@ 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;