Details
-
Bug
-
Resolution: Done
-
P2: Important
-
None
-
6.2.0
-
None
-
Python 3.8
Qt 6.2.0 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 10.2.1 20201112 (Red Hat 10.2.1-8)) [limited API]
-
0c4b73611801c788849f0bcf93737c670b61ee03 (pyside/pyside-setup/dev) 706fc86ac231208894ff7e2e8b26bfe596f55a45 (pyside/pyside-setup/6.2)
Description
Hi,
QFont(family string) returns unexpected font.
In PySide6, QFont() handles string argument as character list unexpectedly.
By this problem, Iconic font cannot show expected icon.
# wget https://raw.githubusercontent.com/dovy/elusive-icons/master/fonts/elusiveicons-webfont.ttf family = "elusiveicons" font = QFont(family) print(f"input: {family}, font: family: {font.family()}, families: {font.families()}") # PySide2 input: elusiveicons, font: family: elusiveicons, families: [] # PySide6 input: elusiveicons, font: family: e, families: ['e', 'l', 'u', 's', 'i', 'v', 'e', 'i', 'c', 'o', 'n', 's']
I attached reproducible script, which shows address book symbol.
Please note https://raw.githubusercontent.com/dovy/elusive-icons/master/fonts/elusiveicons-webfont.ttf needs to be downloaded for executing the script.
"python3.8 pyside-qfont.py --pyside2" shows address book symbol as expected, but "python3.8 pyside-qfont.py --pyside6" shows alternative symbol unexpectedly.