From a54b7b9a1a35f6368d03a45931d1d517b595bb50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Minisini?= Date: Sun, 30 Jan 2011 18:03:24 +0000 Subject: [PATCH] [GB.GTK] * BUG: Setting TabStrip.Font property works like in gb.qt4 now. git-svn-id: svn://localhost/gambas/trunk@3517 867c0c6c-44f3-4631-809d-bfa615b0a4ec --- gb.gtk/src/gtabstrip.cpp | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/gb.gtk/src/gtabstrip.cpp b/gb.gtk/src/gtabstrip.cpp index ac1588040..21b031c3a 100644 --- a/gb.gtk/src/gtabstrip.cpp +++ b/gb.gtk/src/gtabstrip.cpp @@ -265,9 +265,18 @@ void gTabStripPage::updateColors() void gTabStripPage::updateFont() { - gFont *fnt = parent->textFont(); - gtk_widget_modify_font(widget, fnt ? fnt->desc() : NULL); - gtk_widget_modify_font(label, fnt ? fnt->desc() : NULL); + PangoFontDescription *desc = NULL; + gFont *fnt; + + fnt = parent->textFont(); + if (!fnt) + fnt = parent->font(); + + if (fnt) + desc = fnt->desc(); + + gtk_widget_modify_font(widget, desc); + gtk_widget_modify_font(label, desc); } void gTabStripPage::setText(char *text)