Gtk.Scrollable.Gtk_Scrollable is an interface that is implemented by widgets with native scrolling ability.
To implement this interface you should override the Gtk.Scrollable.Gtk_Scrollable:hadjustment and Gtk.Scrollable.Gtk_Scrollable:vadjustment properties.
## Creating a scrollable widget
All scrollable widgets should do the following.
When a parent widget sets the scrollable child widget's adjustments, the
widget should populate the adjustments' Gtk.Adjustment.Gtk_Adjustment:lower, Gtk.Adjustment.Gtk_Adjustment:upper, Gtk.Adjustment.Gtk_Adjustment:step-increment, Gtk.Adjustment.Gtk_Adjustment:page-increment and Gtk.Adjustment.Gtk_Adjustment:page-size properties and connect to the Gtk.Adjustment.Gtk_Adjustment::value-changed signal.
Because its preferred size is the size for a fully expanded widget, the
scrollable widget must be able to cope with underallocations. This means that it must accept any value passed to its Gtk.Widget.GObject_Class.size_allocate function.
When the parent allocates space to the scrollable child widget, the
widget should update the adjustments' properties with new values.
When any of the adjustments emits the
Gtk.Adjustment.Gtk_Adjustment::value-changed signal, the scrollable widget should scroll its contents.
<group>Interfaces</group>
function "+" (W : Gtk_Scrollable) return Gtk_Scrollable
function Get_Border
(Self : Gtk_Scrollable;
Border : access Gtk.Style.Gtk_Border) return Boolean
Returns the size of a non-scrolling border around the outside of the scrollable. An example for this would be treeview headers. GTK+ can use this information to display overlayed graphics, like the overshoot indication, at the right position. Since: gtk+ 3.16
return location for the results
True if Border has been set
function Get_Hadjustment
(Self : Gtk_Scrollable) return Gtk.Adjustment.Gtk_Adjustment
Retrieves the Gtk.Adjustment.Gtk_Adjustment used for horizontal scrolling. Since: gtk+ 3.0
horizontal Gtk.Adjustment.Gtk_Adjustment.
function Get_Hscroll_Policy
(Self : Gtk_Scrollable) return Gtk.Enums.Gtk_Scrollable_Policy
Gets the horizontal Gtk.Enums.Gtk_Scrollable_Policy. Since: gtk+ 3.0
The horizontal Gtk.Enums.Gtk_Scrollable_Policy.
function Get_Type return Glib.GType
function Get_Vadjustment
(Self : Gtk_Scrollable) return Gtk.Adjustment.Gtk_Adjustment
Retrieves the Gtk.Adjustment.Gtk_Adjustment used for vertical scrolling. Since: gtk+ 3.0
vertical Gtk.Adjustment.Gtk_Adjustment.
function Get_Vscroll_Policy
(Self : Gtk_Scrollable) return Gtk.Enums.Gtk_Scrollable_Policy
Gets the vertical Gtk.Enums.Gtk_Scrollable_Policy. Since: gtk+ 3.0
The vertical Gtk.Enums.Gtk_Scrollable_Policy.
type Gtk_Scrollable is new Glib.Types.GType_Interface;
Hadjustment_Property : constant Glib.Properties.Property_Object;
Type: Gtk.Adjustment.Gtk_Adjustment Horizontal Gtk.Adjustment.Gtk_Adjustment of the scrollable widget. This adjustment is shared between the scrollable widget and its parent.
Hscroll_Policy_Property : constant Gtk.Enums.Property_Gtk_Scrollable_Policy;
Determines whether horizontal scrolling should start once the scrollable widget is allocated less than its minimum width or less than its natural width.
Null_Gtk_Scrollable : constant Gtk_Scrollable;
subtype Scrollable_Interface_Descr is Glib.Object.Interface_Description;
procedure Set_Get_Border
(Self : Scrollable_Interface_Descr;
Handler : Virtual_Get_Border)
See Glib.Object.Add_Interface
procedure Set_Hadjustment
(Self : Gtk_Scrollable;
Hadjustment : access Gtk.Adjustment.Gtk_Adjustment_Record'Class)
Sets the horizontal adjustment of the Gtk.Scrollable.Gtk_Scrollable. Since: gtk+ 3.0
a Gtk.Adjustment.Gtk_Adjustment
procedure Set_Hscroll_Policy
(Self : Gtk_Scrollable;
Policy : Gtk.Enums.Gtk_Scrollable_Policy)
Sets the Gtk.Enums.Gtk_Scrollable_Policy to determine whether horizontal scrolling should start below the minimum width or below the natural width. Since: gtk+ 3.0
the horizontal Gtk.Enums.Gtk_Scrollable_Policy
procedure Set_Vadjustment
(Self : Gtk_Scrollable;
Vadjustment : access Gtk.Adjustment.Gtk_Adjustment_Record'Class)
Sets the vertical adjustment of the Gtk.Scrollable.Gtk_Scrollable. Since: gtk+ 3.0
a Gtk.Adjustment.Gtk_Adjustment
procedure Set_Vscroll_Policy
(Self : Gtk_Scrollable;
Policy : Gtk.Enums.Gtk_Scrollable_Policy)
Sets the Gtk.Enums.Gtk_Scrollable_Policy to determine whether vertical scrolling should start below the minimum height or below the natural height. Since: gtk+ 3.0
the vertical Gtk.Enums.Gtk_Scrollable_Policy
Vadjustment_Property : constant Glib.Properties.Property_Object;
Type: Gtk.Adjustment.Gtk_Adjustment Verical Gtk.Adjustment.Gtk_Adjustment of the scrollable widget. This adjustment is shared between the scrollable widget and its parent.
type Virtual_Get_Border is access function
(Self : Gtk_Scrollable;
Border : access Gtk.Style.Gtk_Border) return Glib.Gboolean;
Returns the size of a non-scrolling border around the outside of the scrollable. An example for this would be treeview headers. GTK+ can use this information to display overlayed graphics, like the overshoot indication, at the right position. Since: gtk+ 3.16
return location for the results
True if Border has been set
Vscroll_Policy_Property : constant Gtk.Enums.Property_Gtk_Scrollable_Policy;
Determines whether vertical scrolling should start once the scrollable widget is allocated less than its minimum height or less than its natural height.