i want to redirect cout,cerr and clog to 3 wxTextCtrl's.
I do it like this:
Code: Select all
wxTextCtrl *temp = new wxTextCtrl(this,-1,wxT(""), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_READONLY);
std::clog.rdbuf((std::streambuf*)temp);
AddPage(temp, wxT("Ausgabe"), true);
temp = new wxTextCtrl(this,-1,wxT(""), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_READONLY);
std::cerr.rdbuf((std::streambuf*)temp);
AddPage(temp, wxT("Fehler"), false);
temp = new wxTextCtrl(this,-1,wxT(""), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_READONLY);
std::cout.rdbuf((std::streambuf*)temp);
AddPage(temp, wxT("Log"), false);
Is there something i must think about under windows?
Thanks for help