diff --git a/src/Gui/DlgGeneralImp.cpp b/src/Gui/DlgGeneralImp.cpp index 6fcdc2643a..bfb841753a 100644 --- a/src/Gui/DlgGeneralImp.cpp +++ b/src/Gui/DlgGeneralImp.cpp @@ -128,8 +128,9 @@ void DlgGeneralImp::saveSettings() RecentFiles->onSave(); SplashScreen->onSave(); PythonWordWrap->onSave(); - - PythonConsole* pcPython = new PythonConsole(this); + + QWidget* pc = DockWindowManager::instance()->getDockWindow("Python console"); + PythonConsole *pcPython = static_cast(pc); bool pythonWordWrap = App::GetApplication().GetUserParameter(). GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("General")->GetBool("PythonWordWrap", true);