You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
qta.load_font() checks corruption using ttf_filename as a key.
So, when users execute qta.load_font() with same ttf_filename as bundled,
the ttf binary is checked unexpectedly and raise exception if the ttf binary is different from the bundled.
This makes the use of newer font than bundled by users difficult.
$ python test.py
Traceback (most recent call last):
File "test.py", line 29, in <module>
main()
File "test.py", line 25, in main
_ = AwesomeExample()
File "test.py", line 11, in __init__
qta.load_font("new_msc", "codicon.ttf", "codicon-charmap.json", directory="./fonts/")
File "/home/.local/lib/python3.8/site-packages/qtawesome/__init__.py", line 216, in load_font
return _instance().load_font(prefix, ttf_filename, charmap_filename, directory)
File "/home/.local/lib/python3.8/site-packages/qtawesome/iconic_font.py", line 317, in load_font
raise FontError(u"Font is corrupt at: '{0}'".format(
qtawesome.iconic_font.FontError: Font is corrupt at: './fonts/codicon.ttf'
The text was updated successfully, but these errors were encountered:
kumattau
changed the title
Unexpected corruption check when qta.load() with same ttf_filename as bundled
Unexpected corruption check when qta.load_font() with same ttf_filename as bundled
Dec 19, 2021
qta.load_font() checks corruption using ttf_filename as a key.
So, when users execute qta.load_font() with same ttf_filename as bundled,
the ttf binary is checked unexpectedly and raise exception if the ttf binary is different from the bundled.
This makes the use of newer font than bundled by users difficult.
The text was updated successfully, but these errors were encountered: