aboutsummaryrefslogtreecommitdiff
path: root/src/headerview.c
diff options
context:
space:
mode:
authorhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-01-25 08:21:20 +0000
committerhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2005-01-25 08:21:20 +0000
commit80ce4c1f69c088289c3c67408c820a03d0b04055 (patch)
tree29890de80367bd066e731075d7be5965b0d43c22 /src/headerview.c
parentd97b4ce5ed25db02c5488c23bfdfa96ea3f5acd8 (diff)
improved font management.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@39 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src/headerview.c')
-rw-r--r--src/headerview.c23
1 files changed, 10 insertions, 13 deletions
diff --git a/src/headerview.c b/src/headerview.c
index 2a6d7369..ee730f37 100644
--- a/src/headerview.c
+++ b/src/headerview.c
@@ -139,20 +139,17 @@ void headerview_init(HeaderView *headerview)
{
static PangoFontDescription *boldfont = NULL;
- if (!boldfont && prefs_common.boldfont)
- boldfont = pango_font_description_from_string
- (prefs_common.boldfont);
-
-#define SET_FONT_STYLE(wid) \
-{ \
- if (boldfont) \
- gtk_widget_modify_font(headerview->wid, boldfont); \
-}
+ if (!boldfont) {
+ boldfont = pango_font_description_new();
+ pango_font_description_set_weight(boldfont, PANGO_WEIGHT_BOLD);
+ }
- SET_FONT_STYLE(from_header_label);
- SET_FONT_STYLE(to_header_label);
- SET_FONT_STYLE(ng_header_label);
- SET_FONT_STYLE(subject_header_label);
+ if (boldfont) {
+ gtk_widget_modify_font(headerview->from_header_label, boldfont);
+ gtk_widget_modify_font(headerview->to_header_label, boldfont);
+ gtk_widget_modify_font(headerview->ng_header_label, boldfont);
+ gtk_widget_modify_font(headerview->subject_header_label, boldfont);
+ }
headerview_clear(headerview);
headerview_set_visibility(headerview, prefs_common.display_header_pane);