Don't allocate space for "" in scale marks

Turns out GtkBuilder ends up creating marks with non-NULL
empty texts, so ignore those. Bug 614443, reported by Filippo Argiolas.
This commit is contained in:
Matthias Clasen 2010-08-04 21:47:54 -04:00
parent 3a34295b9c
commit 519eae8729

View File

@ -852,7 +852,7 @@ gtk_scale_get_mark_label_size (GtkScale *scale,
{
GtkScaleMark *mark = m->data;
if (mark->markup)
if (mark->markup && *mark->markup)
{
pango_layout_set_markup (layout, mark->markup, -1);
pango_layout_get_pixel_extents (layout, NULL, &logical_rect);