Added memory consumption test for small text in large TextLabel 16/164916/3
authorRichard Huang <r.huang@samsung.com>
Thu, 21 Dec 2017 18:18:25 +0000 (18:18 +0000)
committerRichard Huang <r.huang@samsung.com>
Tue, 2 Jan 2018 10:44:54 +0000 (10:44 +0000)
Change-Id: Ibbc99557b52a033632fb90358ba6d205fd5bd662

examples/text-memory-profiling/text-memory-profiling-example.cpp

index 09e6f69..eae8319 100644 (file)
@@ -45,6 +45,7 @@ enum TextType
   MULTI_COLOR_TEXT_WITH_STYLE,
   MULTI_COLOR_TEXT_WITH_EMOJI,
   MULTI_COLOR_TEXT_WITH_STYLE_EMOJI,
+  SMALL_TEXT_IN_LARGE_TEXT_LABEL,
   NUMBER_OF_TYPES
 };
 
@@ -57,7 +58,8 @@ std::string TEXT_TYPE_STRING[ NUMBER_OF_TYPES ] =
   "Multi color text",
   "Multi color text with style",
   "Multi color text with emoji",
-  "Multi color text with style and emoji"
+  "Multi color text with style and emoji",
+  "Small text in large Text Label"
 };
 
 const int NUMBER_OF_LABELS = 500;
@@ -156,6 +158,13 @@ public:
         label.SetProperty( TextLabel::Property::SHADOW_OFFSET, Vector2( 2.0f, 2.0f ) );
         break;
       }
+      case SMALL_TEXT_IN_LARGE_TEXT_LABEL:
+      {
+        label.SetProperty( TextLabel::Property::TEXT, "A Quick Brown Fox Jumps Over The Lazy Dog" );
+        label.SetProperty( TextLabel::Property::SHADOW_OFFSET, Vector2( 0.0f, 0.0f ) );
+        label.SetSize(stageSize.x, stageSize.y * 0.25f); // Set the text label in larger size
+        break;
+      }
       default:
         break;
     }