diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2011-07-21 02:46:22 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2011-07-21 02:46:22 +0000 |
commit | bfbde319d3c708eb10031534725034c675dbe35a (patch) | |
tree | 4b7311fea781fc4838af5e66e8e8dbf9ef0e2f9e /src/textview.c | |
parent | e2a169b856d1954c5cd38c4dd47cbb7a68afe41c (diff) |
textview.c: use style colors for part widgets.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@2928 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src/textview.c')
-rw-r--r-- | src/textview.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/textview.c b/src/textview.c index bb8f8061..f8286455 100644 --- a/src/textview.c +++ b/src/textview.c @@ -743,7 +743,7 @@ static gboolean textview_part_widget_exposed(GtkWidget *widget, return FALSE; drawable = GDK_DRAWABLE(widget->window); - gc = widget->style->fg_gc[GTK_WIDGET_STATE(widget)]; + gc = widget->style->dark_gc[GTK_WIDGET_STATE(widget)]; gdk_gc_set_clip_rectangle(gc, &event->area); gdk_gc_set_line_attributes(gc, 1, GDK_LINE_SOLID, GDK_CAP_NOT_LAST, GDK_JOIN_MITER); @@ -852,6 +852,7 @@ static void textview_add_part_widget(TextView *textview, GtkTextIter *iter, GtkWidget *ebox; GtkWidget *label; GtkWidget *arrow; + GtkStyle *style; GdkColor bg = {0, 0xe000, 0xe500, 0xffff}; GdkColor fg = {0, 0x8000, 0x9800, 0xffff}; GdkColor bg2 = {0, 0xc000, 0xc800, 0xffff}; @@ -878,6 +879,13 @@ static void textview_add_part_widget(TextView *textview, GtkTextIter *iter, G_CALLBACK(textview_part_widget_left), textview); g_signal_connect_after(G_OBJECT(ebox), "expose_event", G_CALLBACK(textview_part_widget_exposed), textview); + + style = gtk_widget_get_style(label); + bg = style->bg[GTK_STATE_NORMAL]; + fg = style->fg[GTK_STATE_NORMAL]; + bg2 = style->bg[GTK_STATE_PRELIGHT]; + fg2 = style->fg[GTK_STATE_PRELIGHT]; + gtk_widget_modify_bg(ebox, GTK_STATE_NORMAL, &bg); gtk_widget_modify_fg(ebox, GTK_STATE_NORMAL, &fg); gtk_widget_modify_bg(ebox, GTK_STATE_PRELIGHT, &bg2); |