After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 591495 - Use Pango markup attributes in GtkBuilder file
Use Pango markup attributes in GtkBuilder file
Status: RESOLVED FIXED
Product: hamster-applet
Classification: Deprecated
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: hamster-applet-maint
hamster-applet-maint
Depends on:
Blocks:
 
 
Reported: 2009-08-11 21:47 UTC by Philip Withnall
Modified: 2009-12-26 13:49 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Use Pango attributes in the GtkBuilder files (7.77 KB, patch)
2009-08-11 22:46 UTC, Philip Withnall
none Details | Review

Description Philip Withnall 2009-08-11 21:47:13 UTC
The Pango markup from the "input_description" and "label3" labels in applet.ui should use Pango attributes as part of the GtkLabel definition, rather than as part of the translatable label text. This makes it less likely that translators will introduce markup mistakes and consequently break the interface. See here: http://library.gnome.org/devel/gtk/stable/GtkLabel.html#GtkLabel-BUILDER-UI
Comment 1 Philip Withnall 2009-08-11 22:04:24 UTC
Also, "overview_label", "label7" and "label8" from stats.ui should make use of Pango attributes.
Comment 2 Philip Withnall 2009-08-11 22:05:36 UTC
"label3", "label7" and "label2" from preferences.ui also need some love.
Comment 3 Philip Withnall 2009-08-11 22:46:50 UTC
Created attachment 140493 [details] [review]
Use Pango attributes in the GtkBuilder files

This is untested. It should all work, though I'm not confident about the "Tell me more" pseudo-link in applet.ui. The best solution for this label would be to use  the label link functionality introduced in GTK+ 2.18.

Note that it bumps the GTK+ requirement from 2.12 to 2.14.
Comment 4 Toms Bauģis 2009-08-12 19:35:57 UTC
I'm somewhat concerned about bumping the gtk+ version - 2.14 is just a year ago.
Comment 5 Patryk Zawadzki 2009-08-12 19:39:00 UTC
Aren't we part of *this* years GNOME release? ;)
Comment 6 Toms Bauģis 2009-08-12 20:14:07 UTC
well then, let's try to get it in :)

patch as it is causes segmentation fault of hamster on my box.
i tried to adjust font size to small in the semi-button in applet dropdown using glade 3.6.3 and it does not seem to understand PANGO_SCALE_SMALL and the numeric values do not seem to have impact.
Comment 7 Philip Withnall 2009-08-20 22:09:17 UTC
(In reply to comment #6)
> patch as it is causes segmentation fault of hamster on my box.

What's the backtrace?
Comment 8 Philip Withnall 2009-08-30 18:15:43 UTC
I've just come across this in another module, and it's because PANGO_SCALE_* aren't defined in an enum (i.e. PangoScale doesn't exist). Accordingly, GtkBuilder can't parse PANGO_SCALE_SMALL. The patch should work if 0.83 is used instead.
Comment 9 Toms Bauģis 2009-12-26 13:49:13 UTC
Thanks Philip!
I think most of the git master now uses attributes instead of markup. hamster.ui is safe to ignore as it is something that is not accessible from the UI for now anyway.

thanks for report, i'm marking this as fixed now