]> Pileus Git - ~andy/gtk/blobdiff - gtk/gtkviewport.c
Merge branch 'native-layout-incubator'
[~andy/gtk] / gtk / gtkviewport.c
index e57f75699f2c7ef92d8ff1e90486b98d7e39c485..248e17fa2ee4ec4c2f38f29e5994270f43ad0472 100644 (file)
 #include "gtkprivate.h"
 #include "gtkalias.h"
 
+/**
+ * SECTION:gtkviewport
+ * @Short_description: An adapter which makes widgets scrollable
+ * @Title: GtkViewport
+ * @See_also:#GtkScrolledWindow, #GtkAdjustment
+ *
+ * The #GtkViewport widget acts as an adaptor class, implementing
+ * scrollability for child widgets that lack their own scrolling
+ * capabilities. Use #GtkViewport to scroll child widgets such as
+ * #GtkTable, #GtkBox, and so on.
+ *
+ * If a widget has native scrolling abilities, such as #GtkTextView,
+ * #GtkTreeView or #GtkIconview, it can be added to a #GtkScrolledWindow
+ * with gtk_container_add(). If a widget does not, you must first add the
+ * widget to a #GtkViewport, then add the viewport to the scrolled window.
+ * The convenience function gtk_scrolled_window_add_with_viewport() does
+ * exactly this, so you can ignore the presence of the viewport.
+ */
+
 enum {
   PROP_0,
   PROP_HADJUSTMENT,