diff options
author | Matthias Clasen <maclas@gmx.de> | 2004-02-18 01:05:41 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2004-02-18 01:05:41 +0000 |
commit | a6e4e43c0598c2a20fb0afb9f4a31b730c3e34b5 (patch) | |
tree | bc06362cdfcffd1e420ff3f3d17a536512f63411 /gtk/gtktextbuffer.c | |
parent | 1c51c48606930b3a784c0bbc99a5a8eb2188ca5f (diff) | |
download | gtk+-a6e4e43c0598c2a20fb0afb9f4a31b730c3e34b5.tar.gz |
Document some peculiarities of the ::delete_range signal. (#132135, Grant
Wed Feb 18 02:03:47 2004 Matthias Clasen <maclas@gmx.de>
* gtk/gtktextbuffer.c (gtk_text_buffer_class_init): Document some
peculiarities of the ::delete_range signal. (#132135, Grant Gayed)
Diffstat (limited to 'gtk/gtktextbuffer.c')
-rw-r--r-- | gtk/gtktextbuffer.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/gtk/gtktextbuffer.c b/gtk/gtktextbuffer.c index eeb98de1b6..3a72fc0544 100644 --- a/gtk/gtktextbuffer.c +++ b/gtk/gtktextbuffer.c @@ -219,6 +219,19 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass) GTK_TYPE_TEXT_ITER | G_SIGNAL_TYPE_STATIC_SCOPE, GTK_TYPE_TEXT_CHILD_ANCHOR); + /** + * GtkTextBuffer::delete_range: + * @buffer: the object which received the signal. + * @start: the start of the range to be deleted + * @end: the end of the range to be deleted + * + * The ::delete_range signal is emitted to delete a range from + * a #GtkTextBuffer. Note that your handler must not invalidate the + * @start and @end iters (or has to revalidate them), if it runs before the + * default handler. There is no need to keep the iters valid in handlers + * which run after the default handler (see g_signal_connect_after()), but + * those don't have access to the deleted text. + */ signals[DELETE_RANGE] = g_signal_new ("delete_range", G_OBJECT_CLASS_TYPE (object_class), @@ -1344,7 +1357,8 @@ gtk_text_buffer_delete_interactive (GtkTextBuffer *buffer, start_iter, TRUE); end_mark = gtk_text_buffer_create_mark (buffer, NULL, end_iter, FALSE); - iter = *start_iter; + + gtk_text_buffer_get_iter_at_mark (buffer, &iter, start_mark); current_state = gtk_text_iter_editable (&iter, default_editable); |