gtk_style_context_invalidate deprecated but required? Automatic style context invalidation does not work
Submitted by Robert Timm
Link to original bug (#781158)
Description
Created attachment 349631 minimal example program to present the problem
Hello,
The attached code presents a situation where a manual call to gtk_style_context_invalidate is required to apply the style defined font size on a GtkTextView. Without the call, the font size is updated on first user input, leading to a sudden unpleasant widget size and layout change. According to the docs, this call should not be required as style context invalidation is automatic.
"gtk_style_context_invalidate has been deprecated since version 3.12 and should not be used in newly-written code. Style contexts are invalidated automatically." https://developer.gnome.org/gtk3/stable/GtkStyleContext.html#gtk-style-context-invalidate
Am I missing something?
Any help on this is highly appreciated.
Thanks a lot, Best regards, Robert
Attachment 349631, "minimal example program to present the problem":
main.c
Version: 3.22.x