Copied some TextInput grab/selection handle code
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / text / rendering / basic / text-basic-renderer.cpp
index aecb6d7..5cd608f 100644 (file)
@@ -279,6 +279,8 @@ Text::RendererPtr BasicRenderer::New()
 
 RenderableActor BasicRenderer::Render( Text::ViewInterface& view )
 {
+  UnparentAndReset( mImpl->mActor );
+
   Text::Length numberOfGlyphs = view.GetNumberOfGlyphs();
 
   if( numberOfGlyphs > 0 )
@@ -286,11 +288,11 @@ RenderableActor BasicRenderer::Render( Text::ViewInterface& view )
     Vector<GlyphInfo> glyphs;
     glyphs.Resize( numberOfGlyphs );
 
-    view.GetGlyphs( 0, &glyphs[0], numberOfGlyphs );
+    view.GetGlyphs( &glyphs[0], 0, numberOfGlyphs );
 
     std::vector<Vector2> positions;
     positions.resize( numberOfGlyphs );
-    view.GetGlyphPositions( 0, &positions[0], numberOfGlyphs );
+    view.GetGlyphPositions( &positions[0], 0, numberOfGlyphs );
 
     Atlas atlas = mImpl->CreateAtlas( glyphs );