Gajim crashes when using a specific font
Please first check if another issue has been opened for your problem
There were similar issues - they solved it by simply deleting the theme config - which is by no means a solution
Versions
Windows:
- OS: Windows
- Gajim version: 1.8.0
- GTK version: 3.24.38
- Python-nbxmpp version: 4.3.0
Linux:
- OS: void linux (rolling release, up to date)
- Gajim version: 1.8.0
- GTK version: 3.24.38
- Python-nbxmpp version: 4.3.0
Installed font to reproduce the issue : https://fonts.google.com/specimen/Source+Serif+4
Steps to reproduce the problem
- open Preferences > Style > Theme
- add your new theme, name it e.g myTheme
- edit theme, e.g. Add Setting -> Conversation: Text font
- Select font from the list (see above..), e.g. "Source Serif 4"
- Click Select - Error Window opens in the background
Traceback (most recent call last):
File "C:/msys64/home/appveyor/gajim/win/_build_root/mingw64/lib/python3.10/site-packages/gajim/gtk/themes.py", line 416, in _on_font_set
File "C:/msys64/home/appveyor/gajim/win/_build_root/mingw64/lib/python3.10/site-packages/gajim/gtk/css_config.py", line 356, in set_font
File "C:/msys64/home/appveyor/gajim/win/_build_root/mingw64/lib/python3.10/site-packages/gajim/gtk/css_config.py", line 290, in _write
File "C:/msys64/home/appveyor/gajim/win/_build_root/mingw64/lib/python3.10/site-packages/gajim/gtk/css_config.py", line 602, in _activate_theme
gi.repository.GLib.GError: gtk-css-provider-error-quark: <data>:2:30Junk at end of value for font-family (1)
Similar traceback appears with void linux.
Expected behavior
Gajim should accept the selected font
Actual behavior
Gajim crashes
Workaround / Possible fix??
Quit all gajim tasks, open your style.css in Userdata\Theme\myTheme.css
, enclose the font name with quotation marks.
Start Gajim - it'll show the right (selected) font with no issues
Workaround works for linux, too