Made Redirect python output options True by default - fixes #2454

This commit is contained in:
Yorik van Havre
2016-02-26 13:43:51 -03:00
parent d428a04a56
commit 2254a4698d
2 changed files with 42 additions and 9 deletions

View File

@@ -231,8 +231,8 @@ void MacroManager::run(MacroType eType,const char *sName)
try {
ParameterGrp::handle hGrp = App::GetApplication().GetUserParameter()
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("OutputWindow");
PyObject* pyout = hGrp->GetBool("RedirectPythonOutput") ? new OutputStdout : 0;
PyObject* pyerr = hGrp->GetBool("RedirectPythonErrors") ? new OutputStderr : 0;
PyObject* pyout = hGrp->GetBool("RedirectPythonOutput",true) ? new OutputStdout : 0;
PyObject* pyerr = hGrp->GetBool("RedirectPythonErrors",true) ? new OutputStderr : 0;
PythonRedirector std_out("stdout",pyout);
PythonRedirector std_err("stderr",pyerr);
//The given path name is expected to be Utf-8