aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/text/e-text.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-05-07 05:28:21 +0800
committerChris Lahey <clahey@src.gnome.org>2000-05-07 05:28:21 +0800
commitd8c0b9eff5d53af5fe51cd6fd56eb2cacd5c99f4 (patch)
treef1ef7bc4fc453885b5b0a28d816b5e1d9509a120 /widgets/text/e-text.c
parent85a334557fb4cef0eb76fce2ba79529aaafe675c (diff)
downloadgsoc2013-evolution-d8c0b9eff5d53af5fe51cd6fd56eb2cacd5c99f4.tar.gz
gsoc2013-evolution-d8c0b9eff5d53af5fe51cd6fd56eb2cacd5c99f4.tar.zst
gsoc2013-evolution-d8c0b9eff5d53af5fe51cd6fd56eb2cacd5c99f4.zip
Added a "changed" signal that gets sent whenever the text changes.
2000-05-06 Christopher James Lahey <clahey@helixcode.com> * widgets/e-text/e-text.c, widgets/e-text/e-text.h: Added a "changed" signal that gets sent whenever the text changes. svn path=/trunk/; revision=2837
Diffstat (limited to 'widgets/text/e-text.c')
-rw-r--r--widgets/text/e-text.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/widgets/text/e-text.c b/widgets/text/e-text.c
index fbff51d728..eac1f42e08 100644
--- a/widgets/text/e-text.c
+++ b/widgets/text/e-text.c
@@ -31,7 +31,7 @@
#include "e-text-event-processor-emacs-like.h"
enum {
- E_TEXT_CHANGE,
+ E_TEXT_CHANGED,
E_TEXT_LAST_SIGNAL
};
@@ -194,11 +194,11 @@ e_text_class_init (ETextClass *klass)
parent_class = gtk_type_class (gnome_canvas_item_get_type ());
- e_text_signals[E_TEXT_CHANGE] =
- gtk_signal_new ("change",
+ e_text_signals[E_TEXT_CHANGED] =
+ gtk_signal_new ("changed",
GTK_RUN_LAST,
object_class->type,
- GTK_SIGNAL_OFFSET (ETextClass, change),
+ GTK_SIGNAL_OFFSET (ETextClass, changed),
gtk_marshal_NONE__NONE,
GTK_TYPE_NONE, 0);
@@ -269,7 +269,7 @@ e_text_class_init (ETextClass *klass)
- klass->change = NULL;
+ klass->changed = NULL;
object_class->destroy = e_text_destroy;
object_class->set_arg = e_text_set_arg;
@@ -418,6 +418,7 @@ e_text_text_model_changed (ETextModel *model, EText *text)
{
text->text = e_text_model_get_text(model);
e_text_free_lines(text);
+ gtk_signal_emit (GTK_OBJECT (text), e_text_signals[E_TEXT_CHANGED]);
text->needs_split_into_lines = 1;
e_canvas_item_request_reflow (GNOME_CANVAS_ITEM(text));
}