+
+int UtcDaliToolkitTextlabelLastCharacterIndex(void)
+{
+ ToolkitTestApplication application;
+ tet_infoline(" UtcDaliToolkitTextlabelLastCharacterIndex");
+
+ Vector2 size( 300.0f, 100.0f );
+
+ Dali::Toolkit::DevelText::RendererParameters textParameters;
+ textParameters.text = "This is a sample text to get the last index.";
+ textParameters.layout = "multiLine";
+ textParameters.fontSize = 20.f;
+ textParameters.textWidth = 300u;
+ textParameters.textHeight = 100u;
+ textParameters.ellipsisEnabled = true;
+ Dali::Property::Array indexArray = Dali::Toolkit::DevelText::GetLastCharacterIndex( textParameters );
+
+ DALI_TEST_CHECK( !indexArray.Empty() );
+ DALI_TEST_EQUALS( indexArray.GetElementAt(0).Get<int>(), 10, TEST_LOCATION );
+
+ END_TEST;
+}
+
+int UtcDaliToolkitTextlabelFontSizeScale(void)
+{
+ ToolkitTestApplication application;
+ tet_infoline(" UtcDaliToolkitTextlabelFontSizeScale");
+
+ TextLabel label = TextLabel::New();
+ label.SetProperty( TextLabel::Property::POINT_SIZE, 30.f );
+ label.SetProperty( TextLabel::Property::TEXT, "Test" );
+ Vector3 nonScaledSize = label.GetNaturalSize();
+
+ TextLabel labelScaled = TextLabel::New();
+ labelScaled.SetProperty( TextLabel::Property::POINT_SIZE, 15.f );
+ labelScaled.SetProperty( Toolkit::DevelTextLabel::Property::FONT_SIZE_SCALE, 2.f );
+ labelScaled.SetProperty( TextLabel::Property::TEXT, "Test" );
+ Vector3 scaledSize = labelScaled.GetNaturalSize();
+
+ DALI_TEST_EQUALS( nonScaledSize, scaledSize, TEST_LOCATION );
+
+ label.SetProperty( TextLabel::Property::PIXEL_SIZE, 30.f );
+ label.SetProperty( TextLabel::Property::TEXT, "Test" );
+ nonScaledSize = label.GetNaturalSize();
+
+ labelScaled.SetProperty( TextLabel::Property::PIXEL_SIZE, 15.f );
+ labelScaled.SetProperty( Toolkit::DevelTextLabel::Property::FONT_SIZE_SCALE, 2.f );
+ labelScaled.SetProperty( TextLabel::Property::TEXT, "Test" );
+ scaledSize = labelScaled.GetNaturalSize();
+
+ DALI_TEST_EQUALS( nonScaledSize, scaledSize, TEST_LOCATION );
+
+ END_TEST;
+}