GNOME Bugzilla – Bug 350882
GtkCellRendererText style or style-set doesn't work
Last modified: 2018-02-10 04:37:29 UTC
Please describe the problem: The latest gtk-demo (Gtk 2.10.1) doesn't set italic style attribute in the left side of the main demo window. Usually, when a demo is double clicked, the demo name is highlighted. I also tried with a test and it doesn't work, i don't know specifically what's wrong in the code between Gtk 2.8 and 2.10 Steps to reproduce: 1. Open gtk-demo 2. Double click on a demo 3. The demo name won't have an italic style Actual results: Expected results: The name of the demo should have an italic style Does this happen every time? Yes Other information:
Are you sure that this has worked in 2.8 ?
I definitively see it working in 2.4, but I don't have the energy right now to figure out what broke it. Kris, do you have any idea how this worked in 2.4 ? What I am seeing in 2.10 is that the fontdescription in the cell renderer is initially "Italic", but then gets changed to "Normal" when the style-set property is unset, and of course, it never goes back to "Italic".
I remember it worked on 2.8.x, it doesn't work for me on 2.10.x eventough i recompiled all the Gtk stuff twice...
Looks pango the API of pang_font_description_unset_fields() changed. I just updated gtk-demo to work correctly again. Matthias, what should we do for GtkCellRendererText? Leave it as it is and update the docs? Or change it such that we don't use _unset_fields() anymore and cache the old value of the field ...
Yes it works now thanks... i think now the style set is better than before
*** Bug 355214 has been marked as a duplicate of this bug. ***
Note for myself: we've decided to just update the documentation of GtkCellRendererText here.
So basically we need to add a note that setting any <style>-set property to FALSE means that the current value of <style> is also cleared. Matthias, what would be the best place to add this note and what's a nice way of phrasing this?
*** Bug 497412 has been marked as a duplicate of this bug. ***
We're moving to gitlab! As part of this move, we are closing bugs that haven't seen activity in more than 5 years. If this issue is still imporant to you and still relevant with GTK+ 3.22 or master, please consider creating a gitlab issue for it.