From: asl Date: Mon, 12 Dec 2005 13:02:55 +0000 (+0000) Subject: When python console is created, her font must be set as in preferences X-Git-Tag: T_3_1_0pre~19 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=b2d96f00f9aaf1484407903838e95e4de0684807;p=modules%2Fgui.git When python console is created, her font must be set as in preferences --- diff --git a/src/LightApp/LightApp_Application.cxx b/src/LightApp/LightApp_Application.cxx index 614f604c5..88f104dbe 100644 --- a/src/LightApp/LightApp_Application.cxx +++ b/src/LightApp/LightApp_Application.cxx @@ -892,7 +892,15 @@ void LightApp_Application::addWindow( QWidget* wid, const int flag, const int st QFont f; if( wid->inherits( "PythonConsole" ) ) - f = ( ( PythonConsole* )wid )->font(); + { + if( resourceMgr()->hasValue( "PyConsole", "font" ) ) + f = resourceMgr()->fontValue( "PyConsole", "font" ); + else + { + f = ( ( PythonConsole* )wid )->font(); + resourceMgr()->setValue( "PyConsole", "font", f ); + } + } else f = wid->font();