#endif
#include "wx/sizer.h"
+#include "wx/ioswrap.h"
#include "widgets.h"
{
public:
// ctor(s) and dtor
- TextWidgetsPage(wxBookCtrl *book, wxImageList *imaglist);
+ TextWidgetsPage(wxBookCtrlBase *book, wxImageList *imaglist);
virtual ~TextWidgetsPage(){};
virtual wxControl *GetWidget() const { return m_text; }
// TextWidgetsPage creation
// ----------------------------------------------------------------------------
-TextWidgetsPage::TextWidgetsPage(wxBookCtrl *book, wxImageList *imaglist)
+TextWidgetsPage::TextWidgetsPage(wxBookCtrlBase *book, wxImageList *imaglist)
: WidgetsPage(book)
{
imaglist->Add(wxBitmap(text_xpm));
wxTextCtrl *text = new wxTextCtrl(this, wxID_ANY, wxEmptyString,
wxDefaultPosition,
- wxSize(s_maxWidth, -1),
+ wxSize(s_maxWidth, wxDefaultCoord),
wxTE_READONLY);
return text;
}
void TextWidgetsPage::OnStreamRedirector(wxCommandEvent& WXUNUSED(event))
{
-// Note, NO_TEXT_WINDOW_STREAM is private flag of wxWidgets header
-// it's simpler to check it rather than duplicate whole
-#ifdef NO_TEXT_WINDOW_STREAM
- wxMessageBox(_T("This wxWidgets build does not support wxStreamToTextRedirector"));
-#else
+#if wxHAS_TEXT_WINDOW_STREAM
wxStreamToTextRedirector redirect(m_text);
wxString str( _T("Outputed to cout, appears in wxTextCtrl!") );
- cout << str << endl;
+ wxSTD cout << str << wxSTD endl;
+#else
+ wxMessageBox(_T("This wxWidgets build does not support wxStreamToTextRedirector"));
#endif
}