sudipshil9862 / fonts-compare

fonts rendering and comparing
GNU General Public License v2.0
6 stars 2 forks source link

When font changed for a Gtk.Label from Gtk.FontButton, font size doesn't increase or decrease for the label text #28

Closed sudipshil9862 closed 1 year ago

sudipshil9862 commented 1 year ago

issue_fontbutton.webm

mike-fabian commented 1 year ago

This is because the change of the font family is done using Pango attributes and the change of the size in the menu is done using markup. This is inconsistent and the Pango markup wins.

mike-fabian commented 1 year ago

https://docs.gtk.org/gtk4/method.Label.set_attributes.html

says:

“While it is not recommended to mix markup strings with manually set attributes, if you must; know that the attributes will be applied to the label after the markup string is parsed.”