[gspell/wip/fix-constant-redrawing: 1/2] debug messages



commit 58c3647163988ee60f13105a7d95310532ced32b
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Sat Jul 9 13:18:33 2016 +0200

    debug messages

 gspell/gspell-inline-checker-text-buffer.c |   15 +++++++++++++++
 1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/gspell/gspell-inline-checker-text-buffer.c b/gspell/gspell-inline-checker-text-buffer.c
index 9849905..2da0e00 100644
--- a/gspell/gspell-inline-checker-text-buffer.c
+++ b/gspell/gspell-inline-checker-text-buffer.c
@@ -427,6 +427,10 @@ check_visible_region (GspellInlineCheckerTextBuffer *spell)
 static gboolean
 timeout_cb (GspellInlineCheckerTextBuffer *spell)
 {
+#if 0
+       static gint i = 0;
+       g_message ("%s() %d", G_STRFUNC, ++i);
+#endif
        check_visible_region (spell);
 
        spell->timeout_id = 0;
@@ -519,6 +523,8 @@ insert_text_after_cb (GtkTextBuffer                 *buffer,
        glong n_chars;
        GtkTextIter start;
        GtkTextIter end;
+       static gint i = 0;
+       g_message ("%s() %d", G_STRFUNC, ++i);
 
        n_chars = g_utf8_strlen (text, length);
 
@@ -639,6 +645,8 @@ delete_range_after_cb (GtkTextBuffer                 *buffer,
 {
        GtkTextIter start_adjusted;
        GtkTextIter end_adjusted;
+       static gint i = 0;
+       g_message ("%s() %d", G_STRFUNC, ++i);
 
        g_return_if_fail (gtk_text_iter_equal (start, end));
 
@@ -656,8 +664,11 @@ mark_set_after_cb (GtkTextBuffer                 *buffer,
                   GtkTextMark                   *mark,
                   GspellInlineCheckerTextBuffer *spell)
 {
+       static gint i = 0;
+
        if (mark == gtk_text_buffer_get_insert (buffer))
        {
+               g_message ("%s() %d", G_STRFUNC, ++i);
                spell->check_current_word = TRUE;
                install_timeout (spell, TIMEOUT_DURATION_BUFFER_MODIFIED);
        }
@@ -912,6 +923,8 @@ draw_cb (GtkWidget                     *text_view,
         cairo_t                       *cr,
         GspellInlineCheckerTextBuffer *spell)
 {
+       static gint i = 0;
+       g_message ("%s() %d", G_STRFUNC, ++i);
        install_timeout (spell, TIMEOUT_DURATION_DRAWING);
 
        return GDK_EVENT_PROPAGATE;
@@ -1035,6 +1048,8 @@ apply_or_remove_tag_cb (GtkTextBuffer                 *buffer,
        if (spell->no_spell_check_tag != NULL &&
            spell->no_spell_check_tag == tag)
        {
+               static gint i = 0;
+               g_message ("%s() %d", G_STRFUNC, ++i);
                add_subregion_to_scan (spell, start, end);
                install_timeout (spell, TIMEOUT_DURATION_BUFFER_MODIFIED);
        }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]