[gedit/wip/adjustment-checks] view: check the GtkTextView's GtkAdjustments changes



commit 574c7be5a952ea7cf23e131e0d1618e30910dc0d
Author: Sébastien Wilmet <swilmet informatique-libre be>
Date:   Mon Jul 25 02:39:42 2022 +0200

    view: check the GtkTextView's GtkAdjustments changes

 gedit/gedit-view.c | 9 +++++++++
 1 file changed, 9 insertions(+)
---
diff --git a/gedit/gedit-view.c b/gedit/gedit-view.c
index 31e5ad579..ce272339a 100644
--- a/gedit/gedit-view.c
+++ b/gedit/gedit-view.c
@@ -240,6 +240,15 @@ gedit_view_constructed (GObject *object)
        g_settings_bind (editor_settings, GEDIT_SETTINGS_SMART_HOME_END,
                         view, "smart-home-end",
                         G_SETTINGS_BIND_GET);
+
+       {
+               GtkScrollable *scrollable = GTK_SCROLLABLE (view);
+               GtkAdjustment *hadjustment = gtk_scrollable_get_hadjustment (scrollable);
+               GtkAdjustment *vadjustment = gtk_scrollable_get_vadjustment (scrollable);
+
+               gedit_utils_check_adjustment_changes (hadjustment);
+               gedit_utils_check_adjustment_changes (vadjustment);
+       }
 }
 
 static GdkAtom


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