+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
+2002-02-06 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktextchild.c: Add warnings if you try to use a child
+ anchor that isn't inside a buffer. Really kind of lame;
+ we should separate the anchor from the buffer. But not worth
+ fixing for now. #70601
+
Wed Feb 6 18:25:24 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreemodelsort.c: rip out all the debugging ifdefs, as
#include "gtktextbtree.h"
#include "gtktextlayout.h"
+#define CHECK_IN_BUFFER(anchor) do { if ((anchor)->segment == NULL) g_warning ("%s: GtkTextChildAnchor hasn't been in a buffer yet", __FUNCTION__); } while (0)
+#define CHECK_IN_BUFFER_RETURN(anchor, val) do { if ((anchor)->segment == NULL) g_warning ("%s: GtkTextChildAnchor hasn't been in a buffer yet", __FUNCTION__); return (val); } while (0)
+
static GtkTextLineSegment *
pixbuf_segment_cleanup_func (GtkTextLineSegment *seg,
GtkTextLine *line)
GList *list = NULL;
GSList *iter;
+ CHECK_IN_BUFFER_RETURN (anchor, NULL);
+
g_return_val_if_fail (seg->type = >k_text_child_type, NULL);
iter = seg->body.child.widgets;
{
GtkTextLineSegment *seg = anchor->segment;
+ CHECK_IN_BUFFER_RETURN (anchor, TRUE);
+
g_return_val_if_fail (seg->type = >k_text_child_type, TRUE);
return seg->body.child.tree == NULL;
g_return_if_fail (GTK_IS_TEXT_CHILD_ANCHOR (anchor));
g_return_if_fail (GTK_IS_WIDGET (child));
+ CHECK_IN_BUFFER (anchor);
+
_gtk_anchored_child_set_layout (child, layout);
_gtk_widget_segment_add (anchor->segment, child);
g_return_if_fail (GTK_IS_TEXT_CHILD_ANCHOR (anchor));
g_return_if_fail (GTK_IS_WIDGET (child));
+ CHECK_IN_BUFFER (anchor);
+
if (_gtk_anchored_child_get_layout (child))
{
gtk_text_child_anchor_queue_resize (anchor,
g_return_if_fail (GTK_IS_TEXT_CHILD_ANCHOR (anchor));
g_return_if_fail (GTK_IS_TEXT_LAYOUT (layout));
+
+ CHECK_IN_BUFFER (anchor);
seg = anchor->segment;