Package: gtk

Interface gtk:scrollable

Superclasses

gobject:object, common-lisp:standard-object, common-lisp:t

Documented Subclasses

Direct Slots

hadjustment
The hadjustment property of type gtk:adjustment (Read / Write / Construct)
The horizontal adjustment of the scrollable widget. This adjustment is shared between the scrollable widget and its parent.
hscroll-policy
The hscroll-policy property of type gtk:scrollable-policy (Read / Write)
Determines whether horizontal scrolling should start once the scrollable widget is allocated less than its minimum width or less than its natural width.
Default value: :minimum
vadjustment
The vadjustment property of type gtk:adjustment (Read / Write / Construct)
The vertical adjustment of the scrollable widget. This adjustment is shared between the scrollable widget and its parent.
vscroll-policy
The vscroll-policy property of type gtk:scrollable-policy (Read / Write)
Determines whether vertical scrolling should start once the scrollable widget is allocated less than its minimum height or less than its natural height.
Default value: :minimum

Details

The gtk:scrollable interface is an interface that is implemented by widgets with native scrolling ability. To implement this interface you should override the hadjustment and vadjustment properties.

Creating a scrollable widget
All scrollable widgets should do the following:
  • When a parent widget sets the adjustments of the scrollable child widget the widget should populate the lower, upper, step-increment, page-increment and page-size properties of the adjustment and connect to the "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 GtkWidgetClass.size_allocate() function.
  • When the parent allocates space to the scrollable child widget, the widget should update the properties of the adjustments with new values.
  • When any of the adjustments emits the "value-changed" signal, the scrollable widget should scroll its contents.
 

Slot Access Functions

Inherited Slot Access Functions

See also

2023-8-6