tet_infoline(" UtcDaliToolkitTextEditorSetPropertyP");
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
// Note - we can't check the defaults since the stylesheets are platform-specific
application.GetGlAbstraction().SetCheckFramebufferStatusResult( GL_FRAMEBUFFER_COMPLETE );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
try
{
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
// connect to the text changed signal.
ConnectionTracker* testTracker = new ConnectionTracker();
bool inputStyleChangedSignal = false;
editor.ConnectSignal( testTracker, "inputStyleChanged", CallbackFunctor(&inputStyleChangedSignal) );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
// Render and notify
application.SendNotification();
bool inputStyleChangedSignal = false;
editor.ConnectSignal( testTracker, "inputStyleChanged", CallbackFunctor(&inputStyleChangedSignal) );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
// Render and notify
application.SendNotification();
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( Actor::Property::SIZE, Vector2( 300.f, 50.f ) );
editor.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
editor2.SetProperty( Actor::Property::SIZE, Vector2( 100.f, 100.f ) );
editor2.SetProperty( Actor::Property::POSITION, Vector2( 100.f, 100.f ));
- Stage::GetCurrent().Add( editor2 );
+ application.GetScene().Add( editor2 );
// Render and notify
application.SendNotification();
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( Actor::Property::SIZE, Vector2( 300.f, 50.f ) );
editor.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "This is a long text for the size of the text-editor." );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "Hello\nworl" );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "Hello\nworl" );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "Hello\nworld\nHello world" );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "Hello\nworld\nHello world" );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "DALi" );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::TEXT, "This is a long text for the size of the text-editor." );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
std::string underlineSettings1( "{\"enable\":\"true\",\"color\":\"red\",\"height\":\"1\"}" );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::UNDERLINE, underlineSettings1 );
DALI_TEST_EQUALS( editor.GetProperty<std::string>( TextEditor::Property::UNDERLINE ), underlineSettings1, TEST_LOCATION );
std::string shadowSettings( "{\"color\":\"green\",\"offset\":\"2 2\",\"blurRadius\":\"0\"}" );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::SHADOW, "{\"color\":\"green\",\"offset\":\"2 2\",\"blurRadius\":\"0\"}" );
std::string fontStyleSettings( "{\"weight\":\"bold\",\"width\":\"condensed\",\"slant\":\"italic\"}" );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::FONT_STYLE, "{\"weight\":\"bold\",\"width\":\"condensed\",\"slant\":\"italic\"}" );
editor.SetProperty( TextEditor::Property::TEXT,
"TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST TEST ");
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( Actor::Property::SIZE, Vector2( 100.f, 100.f ) );
lineCount = editor.GetProperty<int>( TextEditor::Property::LINE_COUNT );
TextEditor editor = TextEditor::New();
DALI_TEST_CHECK( editor );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::POINT_SIZE, 10.f );
editor.SetProperty( Actor::Property::SIZE, Vector2( 50.f, 50.f ) );
editor.SetProperty( Actor::Property::SIZE, Vector2( 150.0f, 300.f ) );
editor.SetProperty( TextEditor::Property::TEXT, "Hello world Hello world" );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
editor.SetProperty( TextEditor::Property::LINE_WRAP_MODE, "WORD" );
DALI_TEST_EQUALS( editor.GetProperty< int >( TextEditor::Property::LINE_WRAP_MODE ), static_cast< int >( Text::LineWrap::WORD ), TEST_LOCATION );
editor.SetProperty( Actor::Property::SIZE, Vector2( 300.f, 50.f ) );
editor.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
editor.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
application.SendNotification();
application.Render();
editor.SetProperty( Actor::Property::SIZE, Vector2( 300.f, 50.f ) );
editor.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
editor.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
application.SendNotification();
application.Render();
editor.SetProperty( Actor::Property::SIZE, Vector2( 300.f, 50.f ) );
editor.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
editor.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
application.SendNotification();
application.Render();
editor.SetProperty( Actor::Property::SIZE, Vector2( 300.f, 50.f ) );
editor.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
editor.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT );
- Stage::GetCurrent().Add( editor );
+ application.GetScene().Add( editor );
application.SendNotification();
application.Render();