Another PyQt6 oddity

Detlev Offenbach detlev at
Mon May 17 16:57:26 BST 2021

Am 17.05.21 um 17:10 schrieb Phil Thompson:
> On 17/05/2021 15:58, Detlev Offenbach wrote:
>> Hello,
>> I am in the process of porting eric to PyQt6. During this process I
>> observed, that the text of the PyQt6 variant of QScintilla is always
>> shown with a bold font (see attached screenshot) although only a few
>> style are configured to use bold font. The same applies to the line
>> numbers, which should be shown with a regular font. What am I doing
>> wrong?
>> Note: I checked the saved styles in the QSettings file and they are
>> all correct in there.
> The values of the QFont Weight enum have changed between Qt5 and Qt6 
> so if you are saving the numerical value (rather than a symbolic name) 
> in the settings then that might be the problem.
> Compare...

I am using the QsciLexer methods readSettings() and writeSettings() and 
the QSettings file looks good (e.g. Python3\style0\font=Hack, 9, 0, 0, 
0). According to the code the third parameter is 'bold').



Detlev Offenbach
detlev at

More information about the PyQt mailing list