Commit 5eaff47e authored by Mirsal Ennaime's avatar Mirsal Ennaime Committed by Javier Jardón

Add accessors for GtkTextView adjustments

GtkTextView is missing accessors for its sealed hadjustment
and vadjustment members.
This patch adds gtk_text_view_get_hadjustment() and
gtk_text_view_get_vadjustment() to GtkTextView

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=616053
parent 41a07326
......@@ -4252,6 +4252,7 @@ gtk_text_view_get_buffer
gtk_text_view_get_cursor_visible
gtk_text_view_get_default_attributes
gtk_text_view_get_editable
gtk_text_view_get_hadjustment
gtk_text_view_get_indent
gtk_text_view_get_iter_at_location
gtk_text_view_get_iter_at_position
......@@ -4267,6 +4268,7 @@ gtk_text_view_get_pixels_inside_wrap
gtk_text_view_get_right_margin
gtk_text_view_get_tabs
gtk_text_view_get_type G_GNUC_CONST
gtk_text_view_get_vadjustment
gtk_text_view_get_visible_rect
gtk_text_view_get_window
gtk_text_view_get_window_type
......
......@@ -7037,6 +7037,42 @@ gtk_text_view_drag_data_received (GtkWidget *widget,
}
}
/**
* gtk_text_view_get_hadjustment:
* @text_view: a #GtkTextView
*
* Gets the horizontal-scrolling #GtkAdjustment.
*
* Returns: (transfer none): pointer to the horizontal #GtkAdjustment
*
* Since: 2.22
**/
GtkAdjustment*
gtk_text_view_get_hadjustment (GtkTextView *text_view)
{
g_return_val_if_fail (GTK_IS_TEXT_VIEW (text_view), NULL);
return get_hadjustment (text_view);
}
/**
* gtk_text_view_get_vadjustment:
* @text_view: a #GtkTextView
*
* Gets the vertical-scrolling #GtkAdjustment.
*
* Returns: (transfer none): pointer to the vertical #GtkAdjustment
*
* Since: 2.22
**/
GtkAdjustment*
gtk_text_view_get_vadjustment (GtkTextView *text_view)
{
g_return_val_if_fail (GTK_IS_TEXT_VIEW (text_view), NULL);
return get_vadjustment (text_view);
}
static GtkAdjustment*
get_hadjustment (GtkTextView *text_view)
{
......
......@@ -279,6 +279,9 @@ void gtk_text_view_window_to_buffer_coords (GtkTextView *text_view,
gint *buffer_x,
gint *buffer_y);
GtkAdjustment* gtk_text_view_get_hadjustment (GtkTextView *text_view);
GtkAdjustment* gtk_text_view_get_vadjustment (GtkTextView *text_view);
GdkWindow* gtk_text_view_get_window (GtkTextView *text_view,
GtkTextWindowType win);
GtkTextWindowType gtk_text_view_get_window_type (GtkTextView *text_view,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment