From b7f5f3cc75e7f04ed51f1f0a96cc49d34311dd2a Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 22 Jun 2004 23:08:41 +0000 Subject: [PATCH] don't overwrite initial controls value, explaining what its style is git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27949 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- samples/text/text.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/samples/text/text.cpp b/samples/text/text.cpp index 1ff95544ce..a04b944b97 100644 --- a/samples/text/text.cpp +++ b/samples/text/text.cpp @@ -865,8 +865,8 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h ) // multi line text controls - m_horizontal = new MyTextCtrl( this, wxID_ANY, _T("Multiline text control with a horizontal scrollbar."), - wxPoint(10,170), wxSize(140,70), wxTE_MULTILINE | wxHSCROLL ); + m_horizontal = new MyTextCtrl( this, wxID_ANY, _T("Multiline text control with a horizontal scrollbar.\n"), + wxPoint(10,170), wxSize(140,70), wxTE_MULTILINE | wxHSCROLL); // a little hack to use the command line argument for encoding testing if ( wxTheApp->argc == 2 ) @@ -877,14 +877,14 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h ) m_horizontal->SetFont(wxFont(18, wxSWISS, wxNORMAL, wxNORMAL, false, _T(""), wxFONTENCODING_ISO8859_2)); - m_horizontal->SetValue(_T("®lu»ouèký kùò zbìsile èe¹tina «»")); + m_horizontal->AppendText(_T("®lu»ouèký kùò zbìsile èe¹tina «»")); break; case '1': m_horizontal->SetFont(wxFont(18, wxSWISS, wxNORMAL, wxNORMAL, false, _T(""), wxFONTENCODING_CP1251)); - m_horizontal->SetValue(_T("Ïðèâåò!")); + m_horizontal->AppendText(_T("Ïðèâåò!")); break; case '8': @@ -892,15 +892,15 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h ) false, _T(""), wxFONTENCODING_CP1251)); #if wxUSE_UNICODE - m_horizontal->SetValue(L"\x0412\x0430\x0434\x0438\x043c \x0426"); + m_horizontal->AppendText(L"\x0412\x0430\x0434\x0438\x043c \x0426"); #else - m_horizontal->SetValue("ËÁÖÅÔÓÑ ÕÄÁÞÎÙÍ"); + m_horizontal->AppendText("ËÁÖÅÔÓÑ ÕÄÁÞÎÙÍ"); #endif } } else { - m_horizontal->SetValue(_T("Text in default encoding")); + m_horizontal->AppendText(_T("Text in default encoding")); } m_multitext = new MyTextCtrl( this, wxID_ANY, _T("Multi line."), -- 2.45.2