]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Bug NPAL16035: Pb with the history list of salome (GUI). Case when command length...
authorsln <sln@opencascade.com>
Tue, 29 May 2007 13:46:41 +0000 (13:46 +0000)
committersln <sln@opencascade.com>
Tue, 29 May 2007 13:46:41 +0000 (13:46 +0000)
src/PythonConsole/PythonConsole_PyEditor.cxx

index c585838c4d7612014c1d6c88a185acbc629fe2b1..e321f9322cdd59ee3b87d811168d3f91fe643685 100755 (executable)
@@ -818,7 +818,8 @@ void PythonConsole_PyEditor::scrollViewAfterHistoryUsing( const QString& command
       return;
     }
     
-    int aCommandLength = QFontMetrics( currentFont() ).width( command );
+    QFontMetrics aFM( currentFont() );
+    int aCommandLength = aFM.width( command ) + aFM.width( READY_PROMPT ) + 5;
     int aVisibleWidth = visibleWidth();
     QScrollBar* aBar = horizontalScrollBar();
     if ( aBar )