summaryrefslogtreecommitdiff
path: root/gtk/gtknotebook.c
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2000-12-04 23:04:17 +0000
committerHavoc Pennington <hp@src.gnome.org>2000-12-04 23:04:17 +0000
commit9365d0d7dc44e67a371590edf7b5f8744963e04c (patch)
tree72f57f594f861aafca4ddc4815b16d1969699ead /gtk/gtknotebook.c
parentd77144614bb39e62dc40cd9b8c510b4cfee04c62 (diff)
downloadgdk-pixbuf-9365d0d7dc44e67a371590edf7b5f8744963e04c.tar.gz
fix this to be sane
2000-12-04 Havoc Pennington <hp@redhat.com> * gtk/gtkpaned.c (gtk_paned_expose): fix this to be sane * gtk/gtkvpaned.c (gtk_vpaned_expose): Add an expose handler * gtk/gtkhpaned.c (gtk_hpaned_expose): Add an expose handler * gtk/gtknotebook.c (gtk_notebook_draw_tab): put in a temporary hack to avoid infinite loops (queue draw instead of draw) - Owen has more appropriate fixes in a branch he'll check in later. * gtk/gtktextiter.c (gtk_text_iter_ends_line): handle paragraph separator, CR, and CRLF as line ends * gtk/gtktextbtree.c (gtk_text_btree_insert): on insertion, break into lines using pango_find_paragraph_boundary(); other bits of the widget are still going to be broken if the boundary isn't '\n' though
Diffstat (limited to 'gtk/gtknotebook.c')
-rw-r--r--gtk/gtknotebook.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 87010ec8b..73f5a3529 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -2340,8 +2340,22 @@ gtk_notebook_draw_tab (GtkNotebook *notebook,
page->tab_label->allocation.width + 1,
page->tab_label->allocation.height + 1);
}
- if (gtk_widget_intersect (page->tab_label, area, &child_area))
- gtk_widget_draw (page->tab_label, &child_area);
+ if (gtk_widget_intersect (page->tab_label, area, &child_area) &&
+ GTK_WIDGET_DRAWABLE (page->tab_label))
+ {
+ GdkEventExpose expose_event;
+
+ /* This is a lame hack since all this code needs rewriting anyhow */
+
+ expose_event.window = page->tab_label->window;
+ expose_event.area = child_area;
+ expose_event.send_event = TRUE;
+ expose_event.type = GDK_EXPOSE;
+ expose_event.count = 0;
+
+ gtk_widget_event (page->tab_label,
+ (GdkEvent*)&expose_event);
+ }
}
}